tests/testthat/test_constructors.R

library(chords)
context("testing constructors")

test_that("constructors", {
  rds.object <- rdsObjectConstructor()
  expect_equal(length(rds.object),6)
  
  rds.example <- makeRDSExample()
  expect_equal(length(rds.example), 6)
  
  test.snowball <- makeSnowBall(rds.example$rds.sample, seeds=1)
  expect_equal(length(test.snowball$I.t), 400)
  
  rds.object2 <- initializeRdsObject(rds.example$rds.sample)
  expect_equal(length(rds.object2), 6)
})

Try the chords package in your browser

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

chords documentation built on May 30, 2017, 3:39 a.m.