Learn R Programming

periscope2 (version 0.2.4)

downloadFile_ValidateTypes: Check passed file types against downloadFile module allowed file types list

Description

It is a downloadFile module helper to return periscope2 defined file types list and warns user if an invalid type is included

Usage

downloadFile_ValidateTypes(types)

Value

the list input given in types

Arguments

types

list of types to test

See Also

downloadFileButton

downloadFile

logViewerOutput

downloadablePlot

downloadableTableUI

downloadableTable

Examples

Run this code
  #inside console
  ## Check valid types
  result <- periscope2::downloadFile_AvailableTypes()
  identical(result, c("csv", "xlsx", "tsv", "txt", "png", "jpeg", "tiff", "bmp"))

  ## check invalid type
  testthat::expect_warning(downloadFile_ValidateTypes(types = "csv_invalid"),
                           "file download list contains an invalid type ")


Run the code above in your browser using DataLab