tests/testthat/test_getOperatingSystem.R

context("getOperatingSystem")

test_that("getOperatingSystem", {
  x = getOperatingSystem()
  expect_true(is.character(x) && length(x) == 1 && nchar(x) > 0)
  x = isWindows()
  expect_true(is.logical(x) && length(x) == 1 && !is.na(x))
  x = isUnix()
  expect_true(is.logical(x) && length(x) == 1 && !is.na(x))
})

Try the BBmisc package in your browser

Any scripts or data that you put into this service are public.

BBmisc documentation built on Sept. 29, 2022, 5:12 p.m.