tests/testthat/test-parse_spc.R

test_that("parse_spc accounts for uppercase arguments and spec", {
  
  text <- '
    SERIES{
    TITLE = "xyz"
    START = 2014.01
    PERIOD = 12
    SAVE = (A1 B1)
    PRINT = BRIEF
    NAME = "abc"
    FILE = "path/to/file.dat"
  }'
  
  expect_snapshot(parse_spc(text))
  
  pp.cap <- parse_spc(text)
  expect_false(is.null(pp.cap[['series']][['file']]))
  
})

Try the seasonal package in your browser

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

seasonal documentation built on Oct. 20, 2024, 1:08 a.m.