Commit f4a5bd7a authored by Peter van 't Hof's avatar Peter van 't Hof

Adding separated outputDirs

parent 717a50df
...@@ -14,19 +14,20 @@ ...@@ -14,19 +14,20 @@
*/ */
package nl.lumc.sasc.biopet.pipelines.basty package nl.lumc.sasc.biopet.pipelines.basty
import java.io.{ File, FileOutputStream } import java.io.{File, FileOutputStream}
import com.google.common.io.Files import com.google.common.io.Files
import nl.lumc.sasc.biopet.extensions.{ Raxml, RunGubbins } import nl.lumc.sasc.biopet.extensions.{Raxml, RunGubbins}
import nl.lumc.sasc.biopet.extensions.gatk.{ BaseRecalibrator, IndelRealigner, PrintReads, RealignerTargetCreator } import nl.lumc.sasc.biopet.extensions.gatk.{BaseRecalibrator, IndelRealigner, PrintReads, RealignerTargetCreator}
import nl.lumc.sasc.biopet.extensions.picard.MarkDuplicates import nl.lumc.sasc.biopet.extensions.picard.MarkDuplicates
import nl.lumc.sasc.biopet.extensions.tools.{ BastyGenerateFasta, VcfStats } import nl.lumc.sasc.biopet.extensions.tools.{BastyGenerateFasta, VcfStats}
import nl.lumc.sasc.biopet.utils.{ ConfigUtils, Logging } import nl.lumc.sasc.biopet.utils.{ConfigUtils, Logging}
import nl.lumc.sasc.biopet.utils.config.Config import nl.lumc.sasc.biopet.utils.config.Config
import org.apache.commons.io.FileUtils
import org.broadinstitute.gatk.queue.QSettings import org.broadinstitute.gatk.queue.QSettings
import org.scalatest.Matchers import org.scalatest.Matchers
import org.scalatest.testng.TestNGSuite import org.scalatest.testng.TestNGSuite
import org.testng.annotations.{ DataProvider, Test } import org.testng.annotations.{AfterClass, DataProvider, Test}
/** /**
* Created by pjvanthof on 27/09/16. * Created by pjvanthof on 27/09/16.
...@@ -61,10 +62,14 @@ class BastyTest extends TestNGSuite with Matchers { ...@@ -61,10 +62,14 @@ class BastyTest extends TestNGSuite with Matchers {
def annotation = false def annotation = false
def bootRuns: Option[Int] = None def bootRuns: Option[Int] = None
private var dirs: List[File] = Nil
@Test(dataProvider = "bastyOptions") @Test(dataProvider = "bastyOptions")
def testBasty(f: String, sample1: Boolean, sample2: Boolean): Unit = { def testBasty(f: String, sample1: Boolean, sample2: Boolean): Unit = {
val outputDir = BastyTest.outputDir
dirs :+= outputDir
val map = { val map = {
var m: Map[String, Any] = BastyTest.config var m: Map[String, Any] = BastyTest.config(outputDir)
if (sample1) m = ConfigUtils.mergeMaps(BastyTest.sample1, m) if (sample1) m = ConfigUtils.mergeMaps(BastyTest.sample1, m)
if (sample2) m = ConfigUtils.mergeMaps(BastyTest.sample2, m) if (sample2) m = ConfigUtils.mergeMaps(BastyTest.sample2, m)
if (dbsnp) m = ConfigUtils.mergeMaps(Map("dbsnp_vcf" -> "test.vcf.gz"), m) if (dbsnp) m = ConfigUtils.mergeMaps(Map("dbsnp_vcf" -> "test.vcf.gz"), m)
...@@ -133,21 +138,26 @@ class BastyTest extends TestNGSuite with Matchers { ...@@ -133,21 +138,26 @@ class BastyTest extends TestNGSuite with Matchers {
pipeline.functions.count(_.isInstanceOf[RunGubbins]) shouldBe 2 pipeline.functions.count(_.isInstanceOf[RunGubbins]) shouldBe 2
} }
} }
// remove temporary run directory all tests in the class have been run
@AfterClass def removeTempOutputDir() = {
dirs.foreach(FileUtils.deleteDirectory)
}
} }
object BastyTest { object BastyTest {
val outputDir = Files.createTempDir() def outputDir = Files.createTempDir()
outputDir.deleteOnExit() val inputDir = Files.createTempDir()
new File(outputDir, "input").mkdirs()
def inputTouch(name: String): String = { def inputTouch(name: String): String = {
val file = new File(outputDir, "input" + File.separator + name) val file = new File(inputDir, name)
Files.touch(file) Files.touch(file)
file.getAbsolutePath file.getAbsolutePath
} }
private def copyFile(name: String): Unit = { private def copyFile(name: String): Unit = {
val is = getClass.getResourceAsStream("/" + name) val is = getClass.getResourceAsStream("/" + name)
val os = new FileOutputStream(new File(outputDir, name)) val os = new FileOutputStream(new File(inputDir, name))
org.apache.commons.io.IOUtils.copy(is, os) org.apache.commons.io.IOUtils.copy(is, os)
os.close() os.close()
} }
...@@ -156,14 +166,14 @@ object BastyTest { ...@@ -156,14 +166,14 @@ object BastyTest {
copyFile("ref.dict") copyFile("ref.dict")
copyFile("ref.fa.fai") copyFile("ref.fa.fai")
val config = Map( def config(outputDir: File) = Map(
"skip_write_dependencies" -> true, "skip_write_dependencies" -> true,
"name_prefix" -> "test", "name_prefix" -> "test",
"cache" -> true, "cache" -> true,
"dir" -> "test", "dir" -> "test",
"vep_script" -> "test", "vep_script" -> "test",
"output_dir" -> outputDir, "output_dir" -> outputDir,
"reference_fasta" -> (outputDir + File.separator + "ref.fa"), "reference_fasta" -> (inputDir + File.separator + "ref.fa"),
"gatk_jar" -> "test", "gatk_jar" -> "test",
"samtools" -> Map("exe" -> "test"), "samtools" -> Map("exe" -> "test"),
"bcftools" -> Map("exe" -> "test"), "bcftools" -> Map("exe" -> "test"),
......
...@@ -50,10 +50,14 @@ class CarpTest extends TestNGSuite with Matchers { ...@@ -50,10 +50,14 @@ class CarpTest extends TestNGSuite with Matchers {
for (s1 <- bool; s2 <- bool; s3 <- bool; t <- bool; c <- bool) yield Array("", s1, s2, s3, t, c) for (s1 <- bool; s2 <- bool; s3 <- bool; t <- bool; c <- bool) yield Array("", s1, s2, s3, t, c)
} }
private var dirs: List[File] = Nil
@Test(dataProvider = "carpOptions") @Test(dataProvider = "carpOptions")
def testCarp(f: String, sample1: Boolean, sample2: Boolean, sample3: Boolean, threatment: Boolean, control: Boolean): Unit = { def testCarp(f: String, sample1: Boolean, sample2: Boolean, sample3: Boolean, threatment: Boolean, control: Boolean): Unit = {
val outputDir = CarpTest.outputDir
dirs :+= outputDir
val map = { val map = {
var m = ConfigUtils.mergeMaps(Map("output_dir" -> CarpTest.outputDir var m = ConfigUtils.mergeMaps(Map("output_dir" -> outputDir
), CarpTest.executables) ), CarpTest.executables)
if (sample1) m = ConfigUtils.mergeMaps(CarpTest.sample1, m) if (sample1) m = ConfigUtils.mergeMaps(CarpTest.sample1, m)
...@@ -92,22 +96,23 @@ class CarpTest extends TestNGSuite with Matchers { ...@@ -92,22 +96,23 @@ class CarpTest extends TestNGSuite with Matchers {
// remove temporary run directory all tests in the class have been run // remove temporary run directory all tests in the class have been run
@AfterClass def removeTempOutputDir() = { @AfterClass def removeTempOutputDir() = {
FileUtils.deleteDirectory(CarpTest.outputDir) dirs.foreach(FileUtils.deleteDirectory)
} }
} }
object CarpTest { object CarpTest {
val outputDir = Files.createTempDir() def outputDir = Files.createTempDir()
new File(outputDir, "input").mkdirs() val inputDir = Files.createTempDir()
def inputTouch(name: String): String = { def inputTouch(name: String): String = {
val file = new File(outputDir, "input" + File.separator + name) val file = new File(inputDir, name)
Files.touch(file) Files.touch(file)
file.getAbsolutePath file.getAbsolutePath
} }
private def copyFile(name: String): Unit = { private def copyFile(name: String): Unit = {
val is = getClass.getResourceAsStream("/" + name) val is = getClass.getResourceAsStream("/" + name)
val os = new FileOutputStream(new File(outputDir, name)) val os = new FileOutputStream(new File(inputDir, name))
org.apache.commons.io.IOUtils.copy(is, os) org.apache.commons.io.IOUtils.copy(is, os)
os.close() os.close()
} }
...@@ -118,7 +123,7 @@ object CarpTest { ...@@ -118,7 +123,7 @@ object CarpTest {
val executables = Map( val executables = Map(
"skip_write_dependencies" -> true, "skip_write_dependencies" -> true,
"reference_fasta" -> (outputDir + File.separator + "ref.fa"), "reference_fasta" -> (inputDir + File.separator + "ref.fa"),
"fastqc" -> Map("exe" -> "test"), "fastqc" -> Map("exe" -> "test"),
"seqtk" -> Map("exe" -> "test"), "seqtk" -> Map("exe" -> "test"),
"sickle" -> Map("exe" -> "test"), "sickle" -> Map("exe" -> "test"),
......
...@@ -59,10 +59,14 @@ class FlexiprepTest extends TestNGSuite with Matchers { ...@@ -59,10 +59,14 @@ class FlexiprepTest extends TestNGSuite with Matchers {
) yield Array("", pair, skipTrim, skipClip, zip, abortOnCorruptFastq) ) yield Array("", pair, skipTrim, skipClip, zip, abortOnCorruptFastq)
} }
private var dirs: List[File] = Nil
@Test(dataProvider = "flexiprepOptions") @Test(dataProvider = "flexiprepOptions")
def testFlexiprep(f: String, paired: Boolean, skipTrim: Boolean, skipClip: Boolean, def testFlexiprep(f: String, paired: Boolean, skipTrim: Boolean, skipClip: Boolean,
zipped: Boolean, abortOnCorruptFastq: Boolean) = { zipped: Boolean, abortOnCorruptFastq: Boolean) = {
val map = ConfigUtils.mergeMaps(Map("output_dir" -> FlexiprepTest.outputDir, val outputDir = FlexiprepTest.outputDir
dirs :+= outputDir
val map = ConfigUtils.mergeMaps(Map("output_dir" -> outputDir,
"skip_trim" -> skipTrim, "skip_trim" -> skipTrim,
"skip_clip" -> skipClip, "skip_clip" -> skipClip,
"abort_on_corrupt_fastq" -> abortOnCorruptFastq "abort_on_corrupt_fastq" -> abortOnCorruptFastq
...@@ -85,8 +89,10 @@ class FlexiprepTest extends TestNGSuite with Matchers { ...@@ -85,8 +89,10 @@ class FlexiprepTest extends TestNGSuite with Matchers {
@Test @Test
def testNoSample: Unit = { def testNoSample: Unit = {
val outputDir = FlexiprepTest.outputDir
dirs :+= outputDir
val map = ConfigUtils.mergeMaps(Map( val map = ConfigUtils.mergeMaps(Map(
"output_dir" -> FlexiprepTest.outputDir "output_dir" -> outputDir
), Map(FlexiprepTest.executables.toSeq: _*)) ), Map(FlexiprepTest.executables.toSeq: _*))
val flexiprep: Flexiprep = initPipeline(map) val flexiprep: Flexiprep = initPipeline(map)
...@@ -97,22 +103,27 @@ class FlexiprepTest extends TestNGSuite with Matchers { ...@@ -97,22 +103,27 @@ class FlexiprepTest extends TestNGSuite with Matchers {
// remove temporary run directory all tests in the class have been run // remove temporary run directory all tests in the class have been run
@AfterClass def removeTempOutputDir() = { @AfterClass def removeTempOutputDir() = {
FileUtils.deleteDirectory(FlexiprepTest.outputDir) dirs.foreach(FileUtils.deleteDirectory)
} }
} }
object FlexiprepTest { object FlexiprepTest {
val outputDir = Files.createTempDir() def outputDir = Files.createTempDir()
new File(outputDir, "input").mkdirs()
val inputDir = Files.createTempDir()
val r1 = new File(outputDir, "input" + File.separator + "R1.fq") val r1 = new File(inputDir, "R1.fq")
Files.touch(r1) Files.touch(r1)
val r2 = new File(outputDir, "input" + File.separator + "R2.fq") r1.deleteOnExit()
val r2 = new File(inputDir, "R2.fq")
Files.touch(r2) Files.touch(r2)
val r1Zipped = new File(outputDir, "input" + File.separator + "R1.fq.gz") r2.deleteOnExit()
val r1Zipped = new File(inputDir, "R1.fq.gz")
Files.touch(r1Zipped) Files.touch(r1Zipped)
val r2Zipped = new File(outputDir, "input" + File.separator + "R2.fq.gz") r1Zipped.deleteOnExit()
val r2Zipped = new File(inputDir, "R2.fq.gz")
Files.touch(r2Zipped) Files.touch(r2Zipped)
r2Zipped.deleteOnExit()
val executables = Map( val executables = Map(
"skip_write_dependencies" -> true, "skip_write_dependencies" -> true,
......
...@@ -18,13 +18,14 @@ import java.io.File ...@@ -18,13 +18,14 @@ import java.io.File
import com.google.common.io.Files import com.google.common.io.Files
import nl.lumc.sasc.biopet.core.BiopetCommandLineFunction import nl.lumc.sasc.biopet.core.BiopetCommandLineFunction
import nl.lumc.sasc.biopet.extensions.centrifuge.{ Centrifuge, CentrifugeKreport } import nl.lumc.sasc.biopet.extensions.centrifuge.{Centrifuge, CentrifugeKreport}
import nl.lumc.sasc.biopet.extensions.kraken.{ Kraken, KrakenReport } import nl.lumc.sasc.biopet.extensions.kraken.{Kraken, KrakenReport}
import nl.lumc.sasc.biopet.extensions.picard.SamToFastq import nl.lumc.sasc.biopet.extensions.picard.SamToFastq
import nl.lumc.sasc.biopet.extensions.samtools.SamtoolsView import nl.lumc.sasc.biopet.extensions.samtools.SamtoolsView
import nl.lumc.sasc.biopet.extensions.tools.KrakenReportToJson import nl.lumc.sasc.biopet.extensions.tools.KrakenReportToJson
import nl.lumc.sasc.biopet.utils.{ ConfigUtils, Logging } import nl.lumc.sasc.biopet.utils.{ConfigUtils, Logging}
import nl.lumc.sasc.biopet.utils.config.Config import nl.lumc.sasc.biopet.utils.config.Config
import org.apache.commons.io.FileUtils
import org.broadinstitute.gatk.queue.QSettings import org.broadinstitute.gatk.queue.QSettings
import org.scalatest.Matchers import org.scalatest.Matchers
import org.scalatest.testng.TestNGSuite import org.scalatest.testng.TestNGSuite
...@@ -60,15 +61,19 @@ abstract class TestGearsSingle extends TestNGSuite with Matchers { ...@@ -60,15 +61,19 @@ abstract class TestGearsSingle extends TestNGSuite with Matchers {
def inputMode: Option[String] = Some("fastq") def inputMode: Option[String] = Some("fastq")
private var dirs: List[File] = Nil
@Test @Test
def testGears(): Unit = { def testGears(): Unit = {
val outputDir = TestGearsSingle.outputDir
dirs :+= outputDir
val map = ConfigUtils.mergeMaps(Map( val map = ConfigUtils.mergeMaps(Map(
"gears_use_qiime_rtax" -> qiimeRtax, "gears_use_qiime_rtax" -> qiimeRtax,
"gears_use_centrifuge" -> centrifuge, "gears_use_centrifuge" -> centrifuge,
"gears_use_qiime_closed" -> qiimeClosed, "gears_use_qiime_closed" -> qiimeClosed,
"gears_use_qiime_open" -> qiimeOpen, "gears_use_qiime_open" -> qiimeOpen,
"gears_use_seq_count" -> seqCount, "gears_use_seq_count" -> seqCount,
"output_dir" -> TestGearsSingle.outputDir "output_dir" -> outputDir
) ++ ) ++
kraken.map("gears_use_kraken" -> _) ++ kraken.map("gears_use_kraken" -> _) ++
downsample.map("downsample" -> _), downsample.map("downsample" -> _),
...@@ -134,6 +139,11 @@ abstract class TestGearsSingle extends TestNGSuite with Matchers { ...@@ -134,6 +139,11 @@ abstract class TestGearsSingle extends TestNGSuite with Matchers {
pipesJobs.count(_.isInstanceOf[CentrifugeKreport]) shouldBe (if (centrifuge) 2 else 0) pipesJobs.count(_.isInstanceOf[CentrifugeKreport]) shouldBe (if (centrifuge) 2 else 0)
} }
} }
@AfterClass
def removeDirs: Unit = {
dirs.foreach(FileUtils.deleteDirectory)
}
} }
class GearsSingleNoInputTest extends TestGearsSingle { class GearsSingleNoInputTest extends TestGearsSingle {
...@@ -219,17 +229,17 @@ class GearsSingleQiimeOpenDownsampleTest extends TestGearsSingle { ...@@ -219,17 +229,17 @@ class GearsSingleQiimeOpenDownsampleTest extends TestGearsSingle {
} }
object TestGearsSingle { object TestGearsSingle {
val outputDir = Files.createTempDir() def outputDir = Files.createTempDir()
outputDir.deleteOnExit()
new File(outputDir, "input").mkdirs() val inputDir = Files.createTempDir()
val r1 = new File(outputDir, "input" + File.separator + "R1.fq") val r1 = new File(inputDir, "R1.fq")
Files.touch(r1) Files.touch(r1)
r1.deleteOnExit() r1.deleteOnExit()
val r2 = new File(outputDir, "input" + File.separator + "R2.fq") val r2 = new File(inputDir, "R2.fq")
Files.touch(r2) Files.touch(r2)
r2.deleteOnExit() r2.deleteOnExit()
val bam = new File(outputDir, "input" + File.separator + "bamfile.bam") val bam = new File(inputDir, "bamfile.bam")
Files.touch(bam) Files.touch(bam)
bam.deleteOnExit() bam.deleteOnExit()
......
...@@ -17,12 +17,13 @@ package nl.lumc.sasc.biopet.pipelines.gears ...@@ -17,12 +17,13 @@ package nl.lumc.sasc.biopet.pipelines.gears
import java.io.File import java.io.File
import com.google.common.io.Files import com.google.common.io.Files
import nl.lumc.sasc.biopet.utils.{ ConfigUtils, Logging } import nl.lumc.sasc.biopet.utils.{ConfigUtils, Logging}
import nl.lumc.sasc.biopet.utils.config.Config import nl.lumc.sasc.biopet.utils.config.Config
import org.apache.commons.io.FileUtils
import org.broadinstitute.gatk.queue.QSettings import org.broadinstitute.gatk.queue.QSettings
import org.scalatest.Matchers import org.scalatest.Matchers
import org.scalatest.testng.TestNGSuite import org.scalatest.testng.TestNGSuite
import org.testng.annotations.{ DataProvider, Test } import org.testng.annotations.{AfterClass, DataProvider, Test}
/** /**
* Created by pjvanthof on 04/02/16. * Created by pjvanthof on 04/02/16.
...@@ -55,10 +56,14 @@ abstract class GearsTest extends TestNGSuite with Matchers { ...@@ -55,10 +56,14 @@ abstract class GearsTest extends TestNGSuite with Matchers {
) yield Array("", s1, s2) ) yield Array("", s1, s2)
} }
private var dirs: List[File] = Nil
@Test(dataProvider = "gearsOptions") @Test(dataProvider = "gearsOptions")
def testGears(dummy: String, sample1: Boolean, sample2: Boolean): Unit = { def testGears(dummy: String, sample1: Boolean, sample2: Boolean): Unit = {
val outputDir = GearsTest.outputDir
dirs :+= outputDir
val map = { val map = {
var m: Map[String, Any] = GearsTest.config var m: Map[String, Any] = GearsTest.config(outputDir)
if (sample1) m = ConfigUtils.mergeMaps(GearsTest.sample1, m) if (sample1) m = ConfigUtils.mergeMaps(GearsTest.sample1, m)
if (sample2) m = ConfigUtils.mergeMaps(GearsTest.sample2, m) if (sample2) m = ConfigUtils.mergeMaps(GearsTest.sample2, m)
ConfigUtils.mergeMaps(Map( ConfigUtils.mergeMaps(Map(
...@@ -82,6 +87,11 @@ abstract class GearsTest extends TestNGSuite with Matchers { ...@@ -82,6 +87,11 @@ abstract class GearsTest extends TestNGSuite with Matchers {
} }
} }
@AfterClass
def removeDirs: Unit = {
dirs.foreach(FileUtils.deleteDirectory)
}
} }
class GearsDefaultTest extends GearsTest class GearsDefaultTest extends GearsTest
...@@ -101,18 +111,21 @@ class GearsLibraryTest extends GearsTest { ...@@ -101,18 +111,21 @@ class GearsLibraryTest extends GearsTest {
} }
object GearsTest { object GearsTest {
val outputDir = Files.createTempDir() def outputDir = Files.createTempDir()
new File(outputDir, "input").mkdirs()
outputDir.deleteOnExit() val inputDir = Files.createTempDir()
val r1 = new File(outputDir, "input" + File.separator + "R1.fq") val r1 = new File(inputDir, "R1.fq")
Files.touch(r1) Files.touch(r1)
val r2 = new File(outputDir, "input" + File.separator + "R2.fq") r1.deleteOnExit()
val r2 = new File(inputDir, "R2.fq")
Files.touch(r2) Files.touch(r2)
val bam = new File(outputDir, "input" + File.separator + "bamfile.bam") r2.deleteOnExit()
val bam = new File(inputDir, "bamfile.bam")
Files.touch(bam) Files.touch(bam)
bam.deleteOnExit()
val config = Map( def config(outputDir: File) = Map(
"skip_write_dependencies" -> true, "skip_write_dependencies" -> true,
"output_dir" -> outputDir, "output_dir" -> outputDir,
"kraken" -> Map("exe" -> "test", "db" -> "test"), "kraken" -> Map("exe" -> "test", "db" -> "test"),
......
...@@ -14,21 +14,22 @@ ...@@ -14,21 +14,22 @@
*/ */
package nl.lumc.sasc.biopet.pipelines.gentrap package nl.lumc.sasc.biopet.pipelines.gentrap
import java.io.{ File, FileOutputStream } import java.io.{File, FileOutputStream}
import com.google.common.io.Files import com.google.common.io.Files
import nl.lumc.sasc.biopet.core.{ BiopetFifoPipe, BiopetPipe } import nl.lumc.sasc.biopet.core.{BiopetFifoPipe, BiopetPipe}
import nl.lumc.sasc.biopet.extensions._ import nl.lumc.sasc.biopet.extensions._
import nl.lumc.sasc.biopet.extensions.gmap.Gsnap import nl.lumc.sasc.biopet.extensions.gmap.Gsnap
import nl.lumc.sasc.biopet.extensions.hisat.Hisat2 import nl.lumc.sasc.biopet.extensions.hisat.Hisat2
import nl.lumc.sasc.biopet.extensions.tools.{ BaseCounter, WipeReads } import nl.lumc.sasc.biopet.extensions.tools.{BaseCounter, WipeReads}
import nl.lumc.sasc.biopet.utils.{ ConfigUtils, Logging } import nl.lumc.sasc.biopet.utils.{ConfigUtils, Logging}
import nl.lumc.sasc.biopet.utils.config.Config import nl.lumc.sasc.biopet.utils.config.Config
import nl.lumc.sasc.biopet.utils.camelize import nl.lumc.sasc.biopet.utils.camelize
import org.apache.commons.io.FileUtils
import org.broadinstitute.gatk.queue.QSettings import org.broadinstitute.gatk.queue.QSettings
import org.scalatest.Matchers import org.scalatest.Matchers
import org.scalatest.testng.TestNGSuite import org.scalatest.testng.TestNGSuite
import org.testng.annotations.{ DataProvider, Test } import org.testng.annotations.{AfterClass, DataProvider, Test}
abstract class GentrapTestAbstract(val expressionMeasures: List[String]) extends TestNGSuite with Matchers { abstract class GentrapTestAbstract(val expressionMeasures: List[String]) extends TestNGSuite with Matchers {
...@@ -58,11 +59,14 @@ abstract class GentrapTestAbstract(val expressionMeasures: List[String]) extends ...@@ -58,11 +59,14 @@ abstract class GentrapTestAbstract(val expressionMeasures: List[String]) extends
} yield Array(strandProtocol) } yield Array(strandProtocol)
} }
private var dirs: List[File] = Nil
@Test(dataProvider = "expMeasuresstrandProtocol") @Test(dataProvider = "expMeasuresstrandProtocol")
def testGentrap(strandProtocol: String) = { def testGentrap(strandProtocol: String) = {
val outputDir = GentrapTest.outputDir
dirs :+= outputDir
val settings = Map( val settings = Map(
"output_dir" -> GentrapTest.outputDir, "output_dir" -> outputDir,
"gsnap" -> Map("db" -> "test", "dir" -> "test"), "gsnap" -> Map("db" -> "test", "dir" -> "test"),
"expression_measures" -> expressionMeasures, "expression_measures" -> expressionMeasures,
"strand_protocol" -> strandProtocol "strand_protocol" -> strandProtocol
...@@ -145,6 +149,10 @@ abstract class GentrapTestAbstract(val expressionMeasures: List[String]) extends ...@@ -145,6 +149,10 @@ abstract class GentrapTestAbstract(val expressionMeasures: List[String]) extends
} }