From c4742c8dd7776a4eb22b4a8a0159d827e715dc28 Mon Sep 17 00:00:00 2001 From: Sander Bollen <a.h.b.bollen@lumc.nl> Date: Thu, 3 Sep 2015 15:51:04 +0200 Subject: [PATCH] More tests for VcfWithVcfTest --- .../src/test/resources/unvep_online.vcf.gz | Bin 0 -> 5727 bytes .../test/resources/unvep_online.vcf.gz.tbi | Bin 0 -> 101 bytes .../sasc/biopet/tools/VcfWithVcfTest.scala | 71 +++++++++++++++++- .../sasc/biopet/tools/VepNormalizerTest.scala | 16 ++-- 4 files changed, 78 insertions(+), 9 deletions(-) create mode 100644 public/biopet-framework/src/test/resources/unvep_online.vcf.gz create mode 100644 public/biopet-framework/src/test/resources/unvep_online.vcf.gz.tbi diff --git a/public/biopet-framework/src/test/resources/unvep_online.vcf.gz b/public/biopet-framework/src/test/resources/unvep_online.vcf.gz new file mode 100644 index 0000000000000000000000000000000000000000..f102295f99d0bc62e25de296b84dc6610930a683 GIT binary patch literal 5727 zcmV-l7NF@LiwFb&00000{{{d;LjnLo7VTW=Z`;U{|LplIhzu5+U>%t^DSNmJT9>t> zE284Oyg@)vWJ}^RMQTVYw&t(js^%$*mNlCbc={4c?CP%SI)Bw{<=0;qu16L@xVB>L zzSaFKHn?AY{WT;D5)$7g8V+AyU0pd=Y+bec_tMqxy{mjUx>{QCgE`;&jz>(sAziJO zT+{S}m9@Fr+L7HTzBd+D6kD+Pd*5BS#OV<~h<6(jwu1HA@|}U}6YaNtThliiZ#N~j z<+=0Firv7!yeDA<e>I`Oz2)96S;Z3P3-z*X#YB5$STXazTc6=XhLf))^_o?fR>znz zJj;o%E<2mRUTK`j@`|LWsv^nCWr^i@gB&95mE~LBE^;Fig{l#PasACUHc=tkAD@_L z6+Cvgo_A}l2W}K=3(JcL6B5e-bu2(XX5{`wG#^Nq%_{JTxeC^>?gxXRI(s0yWH7dt z+DK1k!s0Orae3E=51(Ppgor%Z-qs=g{ihj`8Ijlww;<U2QGYxtp07!`bp55K4+h1< zjpaD_kY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OUK z@kiGzY$OOrZ6u1Nz4OQRE*3U|Bz<(v+(v>59m+9ErC3v}Ya9y7l8uz3o-7tNQYD(m zT6fd&@M1DHF8b|@X{URk4`vtd-s^*lq+`6mliQ2r=<Z_g*OwRjKVrPt|J~#-SSBx2 zg=0njB8(txCCCN>chS0N=@+nbuEFsa6WuT_x;+j0%rNk8x@~RiKls6;f72UkqoD~l z7gf2z-}DBWp%2>}chj2C9~7`Rtsee73=sNFYouWbxfFN>{$T}~zvLjLz)0JeV0Ut( zw>17n?`n98Cfw*FO};7LJJG}jE2}r{+nYAf^Wsg{(71-c^EdRZwU+$NrVrm~GKc_w zSq=Zq7J17y09xL>YeSN1u)@uBqHEkGe=~ir={Nf?gpgJQKE`Z%le|^IO)1Tr^i_t| zHExOndF_4g@~(B!n_cVe>-OZj_wIT!xL~iiYsmIIcP&cS&E~ZVp~_yWYLkvY(d3%f zf{Y^yI5K-FvjU8;*AOZ2kAMU0B?p-udR*m~{{wJOSzUv1001A02m}BC000301^_}s R0stET0{{R300000008>47%2b% literal 0 HcmV?d00001 diff --git a/public/biopet-framework/src/test/resources/unvep_online.vcf.gz.tbi b/public/biopet-framework/src/test/resources/unvep_online.vcf.gz.tbi new file mode 100644 index 0000000000000000000000000000000000000000..bb43ff545f591dd276973e7158919e6d14c78f23 GIT binary patch literal 101 zcmb2|=3rp}f&Xj_PR>jW9t_-tpHfm%5)u-ak|cPUP6f;o?U-!b#dB~{sgr<f_@{-N lc+Mp$T<S>_;Spu%wr0?t^W@e~Mg|6XG=roWn8D_P2mqU58EpUn literal 0 HcmV?d00001 diff --git a/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/tools/VcfWithVcfTest.scala b/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/tools/VcfWithVcfTest.scala index b3c77eb41..f8116db2b 100644 --- a/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/tools/VcfWithVcfTest.scala +++ b/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/tools/VcfWithVcfTest.scala @@ -17,13 +17,16 @@ package nl.lumc.sasc.biopet.tools import java.io.File import java.nio.file.Paths +import java.util +import htsjdk.variant.vcf.VCFFileReader import org.scalatest.Matchers import org.scalatest.mock.MockitoSugar import org.scalatest.testng.TestNGSuite import org.testng.annotations.Test import scala.util.Random +import scala.collection.JavaConversions._ /** * Test class for [[VcfWithVcfTest]] @@ -38,7 +41,7 @@ class VcfWithVcfTest extends TestNGSuite with MockitoSugar with Matchers { } val veppedPath = resourcePath("/VEP_oneline.vcf.gz") - val unveppedPath = resourcePath("/unvepped.vcf.gz") + val unveppedPath = resourcePath("/unvep_online.vcf.gz") val rand = new Random() @Test def testOutputTypeVcf() = { @@ -91,4 +94,70 @@ class VcfWithVcfTest extends TestNGSuite with MockitoSugar with Matchers { thrown.getMessage should equal("Type of field CSQ is not numeric") } + @Test + def testFieldMap = { + val unvep_record = new VCFFileReader(new File(unveppedPath)).iterator().next() + + var fields = List(new Fields("FG", "FG")) + fields :::= List(new Fields("FD", "FD")) + fields :::= List(new Fields("GM", "GM")) + fields :::= List(new Fields("GL", "GL")) + fields :::= List(new Fields("CP", "CP")) + fields :::= List(new Fields("CG", "CG")) + fields :::= List(new Fields("CN", "CN")) + fields :::= List(new Fields("DSP", "DSP")) + fields :::= List(new Fields("AC", "AC")) + fields :::= List(new Fields("AF", "AF")) + fields :::= List(new Fields("AN", "AN")) + fields :::= List(new Fields("BaseQRankSum", "BaseQRankSum")) + fields :::= List(new Fields("DP", "DP")) + fields :::= List(new Fields("FS", "FS")) + fields :::= List(new Fields("MLEAC", "MLEAC")) + fields :::= List(new Fields("MLEAF", "MLEAF")) + fields :::= List(new Fields("MQ", "MQ")) + fields :::= List(new Fields("MQ0", "MQ0")) + fields :::= List(new Fields("MQRankSum", "MQRankSum")) + fields :::= List(new Fields("QD", "QD")) + fields :::= List(new Fields("RPA", "RPA")) + fields :::= List(new Fields("RU", "RU")) + fields :::= List(new Fields("ReadPosRankSum", "ReadPosRankSum")) + fields :::= List(new Fields("VQSLOD", "VQSLOD")) + fields :::= List(new Fields("culprit", "culprit")) + + + val fieldMap = createFieldMap(fields, List(unvep_record)) + + fieldMap("FG") shouldBe List("intron") + fieldMap("FD") shouldBe List("unknown") + fieldMap("GM") shouldBe List("NM_152486.2") + fieldMap("GL") shouldBe List("SAMD11") + fieldMap("CP") shouldBe List("0.000") + fieldMap("CG") shouldBe List("-1.630") + val cn = new util.ArrayList[String] + cn.addAll(List("2294", "3274", "30362", "112930")) + fieldMap("CN") shouldBe List(cn) + fieldMap("DSP") shouldBe List("107") + fieldMap("AC") shouldBe List("2") + fieldMap("AF") shouldBe List("0.333") + fieldMap("AN") shouldBe List("6") + fieldMap("DP") shouldBe List("124") + fieldMap("FS") shouldBe List("1.322") + fieldMap("MLEAC") shouldBe List("2") + fieldMap("MLEAF") shouldBe List("0.333") + fieldMap("MQ") shouldBe List("60.0") + fieldMap("MQ0") shouldBe List("0") + fieldMap("MQRankSum") shouldBe List("-0.197") + fieldMap("QD") shouldBe List("19.03") + val rpa = new util.ArrayList[String] + rpa.addAll(List("1", "2")) + fieldMap("RPA") shouldBe List(rpa) + fieldMap("RU") shouldBe List("A") + fieldMap("ReadPosRankSum") shouldBe List("-0.424") + fieldMap("VQSLOD") shouldBe List("0.079") + fieldMap("culprit") shouldBe List("FS") + + + + } + } diff --git a/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/tools/VepNormalizerTest.scala b/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/tools/VepNormalizerTest.scala index b2a063f98..5a12e9b57 100644 --- a/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/tools/VepNormalizerTest.scala +++ b/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/tools/VepNormalizerTest.scala @@ -47,37 +47,37 @@ class VepNormalizerTest extends TestNGSuite with MockitoSugar with Matchers { val rand = new Random() @Test def testGzOutputExplode(): Unit = { - val tmp_path = "/tmp/VepNorm_" + rand.nextString(10) + ".vcf.gz" - val arguments: Array[String] = Array("-I", vepped_path, "-O", tmp_path, "-m", "explode") + val tmpPath = File.createTempFile("VepNormalizer_", ".vcf.gz").getAbsolutePath + val arguments: Array[String] = Array("-I", vepped_path, "-O", tmpPath, "-m", "explode") main(arguments) } @Test def testVcfOutputExplode(): Unit = { - val tmp_path = "/tmp/VepNorm_" + rand.nextString(10) + ".vcf" - val arguments: Array[String] = Array("-I", vepped_path, "-O", tmp_path, "-m", "explode") + val tmpPath = File.createTempFile("VepNormalizer_", ".vcf").getAbsolutePath + val arguments: Array[String] = Array("-I", vepped_path, "-O", tmpPath, "-m", "explode") main(arguments) } @Test def testBcfOutputExplode(): Unit = { - val tmp_path = "/tmp/VepNorm_" + rand.nextString(10) + ".bcf" + val tmp_path = File.createTempFile("VepNormalizer_", ".bcf").getAbsolutePath val arguments: Array[String] = Array("-I", vepped_path, "-O", tmp_path, "-m", "explode") main(arguments) } @Test def testGzOutputStandard(): Unit = { - val tmp_path = "/tmp/VepNorm_" + rand.nextString(10) + ".vcf.gz" + val tmp_path = File.createTempFile("VepNormalizer_", ".vcf.gz").getAbsolutePath val arguments: Array[String] = Array("-I", vepped_path, "-O", tmp_path, "-m", "standard") main(arguments) } @Test def testVcfOutputStandard(): Unit = { - val tmp_path = "/tmp/VepNorm_" + rand.nextString(10) + ".vcf" + val tmp_path = File.createTempFile("VepNormalizer_", ".vcf").getAbsolutePath val arguments: Array[String] = Array("-I", vepped_path, "-O", tmp_path, "-m", "standard") main(arguments) } @Test def testBcfOutputStandard(): Unit = { - val tmp_path = "/tmp/VepNorm_" + rand.nextString(10) + ".bcf" + val tmp_path = File.createTempFile("VepNormalizer_", ".bcf").getAbsolutePath val arguments: Array[String] = Array("-I", vepped_path, "-O", tmp_path, "-m", "standard") main(arguments) } -- GitLab