tests/testthat/test-unsalt.R

library(anonymizer)
context("unsalt()")

test_that("Produces the correct output.", {
  expect_equal(unsalt(salt(letters, .seed = 1), .seed = 1), letters)
})

test_that("Produces the correct output type.", {
  expect_is(unsalt(salt(letters, .seed = 1), .seed = 1), "character")
})

test_that("Produces the correct errors.", {
})

Try the anonymizer package in your browser

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

anonymizer documentation built on May 29, 2017, 9:29 a.m.