inst/unitTests/test_getReads.R

## Test unit 'testgetReads'

.setUp <-
function () {
	## Specific actions for svUnit: prepare context
	if ("package:svUnit" %in% search()) {
		.Log <- Log() ## Make sure .Log is created
		.Log$..Unit <- "inst/unitTests/runittestGenericGSM.R"
		.Log$..File <- ""
		.Log$..Obj <- ""
		.Log$..Tag <- ""
		.Log$..Msg <- ""
		rm(..Test, envir = .Log)
	}
}

.tearDown <-
function () {
	## Specific actions for svUnit: clean up context
	if ("package:svUnit" %in% search()) {
		.Log$..Unit <- ""
		.Log$..File <- ""
		.Log$..Obj <- ""
		.Log$..Tag <- ""
		.Log$..Msg <- ""
		rm(..Test, envir = .Log)
	}
}


"testgetReads" <-
function() {
    sra = getReads('SRR000123')
    checkEquals(Accession(sra),'SRR000123')
    checkEquals(nrow(Table(sra)),429380)
}
NCBI-Hackathons/SRA2R documentation built on May 7, 2019, 5:18 p.m.