tests/testthat/test-preprocessing-makewindows.R

## Data
exptabpath <- system.file("extdata", "exptab-preprocessing.csv", package="tepr")
gencodepath <- system.file("extdata", "gencode-chr13.gtf", package = "tepr")
windsize <- 200

## Necessary result to call makewindows
allannobed <- retrieveanno(exptabpath, gencodepath, verbose = FALSE)

## Calling the function to test
allwindowsbed <- makewindows(allannobed, windsize, verbose = FALSE)

## ---- Comparing to expected object ---- ##
expectedobj <- readRDS(system.file("extdata", "allwindowsbed.rds",
    package="tepr"))
test_that("makewindows works properly", {
    expect_equal(allwindowsbed, expectedobj)
})

Try the tepr package in your browser

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

tepr documentation built on June 8, 2025, 10:46 a.m.