tests/testthat/test-count_indel_contexts.R

context("test-count_indel_contexts")

## Get a GRangesList object with indel contexts.
grl_indel_context <- readRDS(system.file("states/blood_grl_indel_context.rds",
  package = "MutationalPatterns"
))

output <- count_indel_contexts(grl_indel_context)
expected <- readRDS(system.file("states/blood_indel_counts.rds",
  package = "MutationalPatterns"
))

test_that("Output has correct class", {
  expect_true(inherits(output, c("matrix")))
})

test_that("Output is identical to expected", {
  expect_identical(output, expected)
})

Try the MutationalPatterns package in your browser

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

MutationalPatterns documentation built on Nov. 14, 2020, 2:03 a.m.