From b6ad599614115440d1be1c79d145755e587e54a4 Mon Sep 17 00:00:00 2001 From: martinahansen Date: Tue, 3 Aug 2010 15:11:07 +0000 Subject: [PATCH] added more tests git-svn-id: http://biopieces.googlecode.com/svn/trunk@1026 74ccb610-7750-0410-82ae-013aeee3265d --- bp_test/in/lowercase_seq.in | 2 ++ bp_test/in/read_tab.in.1 | 5 +++++ bp_test/in/read_tab.in.2 | 5 +++++ bp_test/in/read_tab.in.3 | 5 +++++ bp_test/in/uppercase_seq.in | 2 ++ bp_test/out/lowercase_seq.out.1 | 2 ++ bp_test/out/read_tab.out.1 | 20 +++++++++++++++++++ bp_test/out/read_tab.out.2 | 16 +++++++++++++++ bp_test/out/read_tab.out.3 | 16 +++++++++++++++ bp_test/out/read_tab.out.4 | 12 +++++++++++ bp_test/out/read_tab.out.5 | 12 +++++++++++ bp_test/out/read_tab.out.6 | 16 +++++++++++++++ bp_test/out/read_tab.out.7 | 4 ++++ bp_test/out/read_tab.out.8 | 16 +++++++++++++++ bp_test/out/uppercase_seq.out.1 | 2 ++ bp_test/test/test_lowercase_seq | 7 +++++++ bp_test/test/test_read_tab | 35 +++++++++++++++++++++++++++++++++ bp_test/test/test_uppercase_seq | 7 +++++++ 18 files changed, 184 insertions(+) create mode 100644 bp_test/in/lowercase_seq.in create mode 100644 bp_test/in/read_tab.in.1 create mode 100644 bp_test/in/read_tab.in.2 create mode 100644 bp_test/in/read_tab.in.3 create mode 100644 bp_test/in/uppercase_seq.in create mode 100644 bp_test/out/lowercase_seq.out.1 create mode 100644 bp_test/out/read_tab.out.1 create mode 100644 bp_test/out/read_tab.out.2 create mode 100644 bp_test/out/read_tab.out.3 create mode 100644 bp_test/out/read_tab.out.4 create mode 100644 bp_test/out/read_tab.out.5 create mode 100644 bp_test/out/read_tab.out.6 create mode 100644 bp_test/out/read_tab.out.7 create mode 100644 bp_test/out/read_tab.out.8 create mode 100644 bp_test/out/uppercase_seq.out.1 create mode 100755 bp_test/test/test_lowercase_seq create mode 100755 bp_test/test/test_read_tab create mode 100755 bp_test/test/test_uppercase_seq diff --git a/bp_test/in/lowercase_seq.in b/bp_test/in/lowercase_seq.in new file mode 100644 index 0000000..bfa9ff1 --- /dev/null +++ b/bp_test/in/lowercase_seq.in @@ -0,0 +1,2 @@ +SEQ: ATCG +--- diff --git a/bp_test/in/read_tab.in.1 b/bp_test/in/read_tab.in.1 new file mode 100644 index 0000000..70aba61 --- /dev/null +++ b/bp_test/in/read_tab.in.1 @@ -0,0 +1,5 @@ +Organism Sequence Count +Human ATACGTCAG 23524 +Dog AGCATGAC 2442 +Mouse GACTG 234 +Cat AAATGCA 2342 diff --git a/bp_test/in/read_tab.in.2 b/bp_test/in/read_tab.in.2 new file mode 100644 index 0000000..28af0cb --- /dev/null +++ b/bp_test/in/read_tab.in.2 @@ -0,0 +1,5 @@ +#Organism Sequence Count +Human ATACGTCAG 23524 +Dog AGCATGAC 2442 +Mouse GACTG 234 +Cat AAATGCA 2342 diff --git a/bp_test/in/read_tab.in.3 b/bp_test/in/read_tab.in.3 new file mode 100644 index 0000000..6456ebd --- /dev/null +++ b/bp_test/in/read_tab.in.3 @@ -0,0 +1,5 @@ +#Organism;Sequence;Count +Human;ATACGTCAG;23524 +Dog;AGCATGAC;2442 +Mouse;GACTG;234 +Cat;AAATGCA;2342 diff --git a/bp_test/in/uppercase_seq.in b/bp_test/in/uppercase_seq.in new file mode 100644 index 0000000..b284b95 --- /dev/null +++ b/bp_test/in/uppercase_seq.in @@ -0,0 +1,2 @@ +SEQ: atcg +--- diff --git a/bp_test/out/lowercase_seq.out.1 b/bp_test/out/lowercase_seq.out.1 new file mode 100644 index 0000000..b284b95 --- /dev/null +++ b/bp_test/out/lowercase_seq.out.1 @@ -0,0 +1,2 @@ +SEQ: atcg +--- diff --git a/bp_test/out/read_tab.out.1 b/bp_test/out/read_tab.out.1 new file mode 100644 index 0000000..0ccc0a1 --- /dev/null +++ b/bp_test/out/read_tab.out.1 @@ -0,0 +1,20 @@ +V0: Organism +V2: Count +V1: Sequence +--- +V0: Human +V2: 23524 +V1: ATACGTCAG +--- +V0: Dog +V2: 2442 +V1: AGCATGAC +--- +V0: Mouse +V2: 234 +V1: GACTG +--- +V0: Cat +V2: 2342 +V1: AAATGCA +--- diff --git a/bp_test/out/read_tab.out.2 b/bp_test/out/read_tab.out.2 new file mode 100644 index 0000000..5cffc52 --- /dev/null +++ b/bp_test/out/read_tab.out.2 @@ -0,0 +1,16 @@ +V0: Human +V2: 23524 +V1: ATACGTCAG +--- +V0: Dog +V2: 2442 +V1: AGCATGAC +--- +V0: Mouse +V2: 234 +V1: GACTG +--- +V0: Cat +V2: 2342 +V1: AAATGCA +--- diff --git a/bp_test/out/read_tab.out.3 b/bp_test/out/read_tab.out.3 new file mode 100644 index 0000000..dc0f6c3 --- /dev/null +++ b/bp_test/out/read_tab.out.3 @@ -0,0 +1,16 @@ +SEQ: ATACGTCAG +ORGANISM: Human +COUNT: 23524 +--- +SEQ: AGCATGAC +ORGANISM: Dog +COUNT: 2442 +--- +SEQ: GACTG +ORGANISM: Mouse +COUNT: 234 +--- +SEQ: AAATGCA +ORGANISM: Cat +COUNT: 2342 +--- diff --git a/bp_test/out/read_tab.out.4 b/bp_test/out/read_tab.out.4 new file mode 100644 index 0000000..113db41 --- /dev/null +++ b/bp_test/out/read_tab.out.4 @@ -0,0 +1,12 @@ +V0: 23524 +V1: ATACGTCAG +--- +V0: 2442 +V1: AGCATGAC +--- +V0: 234 +V1: GACTG +--- +V0: 2342 +V1: AAATGCA +--- diff --git a/bp_test/out/read_tab.out.5 b/bp_test/out/read_tab.out.5 new file mode 100644 index 0000000..04520e6 --- /dev/null +++ b/bp_test/out/read_tab.out.5 @@ -0,0 +1,12 @@ +SEQ: ATACGTCAG +COUNT: 23524 +--- +SEQ: AGCATGAC +COUNT: 2442 +--- +SEQ: GACTG +COUNT: 234 +--- +SEQ: AAATGCA +COUNT: 2342 +--- diff --git a/bp_test/out/read_tab.out.6 b/bp_test/out/read_tab.out.6 new file mode 100644 index 0000000..00a3fdf --- /dev/null +++ b/bp_test/out/read_tab.out.6 @@ -0,0 +1,16 @@ +Organism: Human +Count: 23524 +Sequence: ATACGTCAG +--- +Organism: Dog +Count: 2442 +Sequence: AGCATGAC +--- +Organism: Mouse +Count: 234 +Sequence: GACTG +--- +Organism: Cat +Count: 2342 +Sequence: AAATGCA +--- diff --git a/bp_test/out/read_tab.out.7 b/bp_test/out/read_tab.out.7 new file mode 100644 index 0000000..5363c4a --- /dev/null +++ b/bp_test/out/read_tab.out.7 @@ -0,0 +1,4 @@ +Organism: Human +Count: 23524 +Sequence: ATACGTCAG +--- diff --git a/bp_test/out/read_tab.out.8 b/bp_test/out/read_tab.out.8 new file mode 100644 index 0000000..00a3fdf --- /dev/null +++ b/bp_test/out/read_tab.out.8 @@ -0,0 +1,16 @@ +Organism: Human +Count: 23524 +Sequence: ATACGTCAG +--- +Organism: Dog +Count: 2442 +Sequence: AGCATGAC +--- +Organism: Mouse +Count: 234 +Sequence: GACTG +--- +Organism: Cat +Count: 2342 +Sequence: AAATGCA +--- diff --git a/bp_test/out/uppercase_seq.out.1 b/bp_test/out/uppercase_seq.out.1 new file mode 100644 index 0000000..bfa9ff1 --- /dev/null +++ b/bp_test/out/uppercase_seq.out.1 @@ -0,0 +1,2 @@ +SEQ: ATCG +--- diff --git a/bp_test/test/test_lowercase_seq b/bp_test/test/test_lowercase_seq new file mode 100755 index 0000000..3f4ad21 --- /dev/null +++ b/bp_test/test/test_lowercase_seq @@ -0,0 +1,7 @@ +#!/bin/bash + +source "$BP_DIR/bp_test/lib/test.sh" + +run "$bp -I $in -O $tmp.1" +assert_no_diff $tmp.1 $out.1 +rm $tmp.1 diff --git a/bp_test/test/test_read_tab b/bp_test/test/test_read_tab new file mode 100755 index 0000000..f1c73c8 --- /dev/null +++ b/bp_test/test/test_read_tab @@ -0,0 +1,35 @@ +#!/bin/bash + +source "$BP_DIR/bp_test/lib/test.sh" + +run "$bp -i $in.1 -O $tmp.1" +assert_no_diff $tmp.1 $out.1 +rm $tmp.1 + +run "$bp -i $in.1 -s 1 -O $tmp.2" +assert_no_diff $tmp.2 $out.2 +rm $tmp.2 + +run "$bp -i $in.1 -s 1 -k ORGANISM,SEQ,COUNT -O $tmp.3" +assert_no_diff $tmp.3 $out.3 +rm $tmp.3 + +run "$bp -i $in.1 -s 1 -c 2,1 -O $tmp.4" +assert_no_diff $tmp.4 $out.4 +rm $tmp.4 + +run "$bp -i $in.1 -s 1 -c 2,1 -k COUNT,SEQ -O $tmp.5" +assert_no_diff $tmp.5 $out.5 +rm $tmp.5 + +run "$bp -i $in.2 -O $tmp.6" +assert_no_diff $tmp.6 $out.6 +rm $tmp.6 + +run "$bp -i $in.2 -n 1 -O $tmp.7" +assert_no_diff $tmp.7 $out.7 +rm $tmp.7 + +run "$bp -i $in.3 -d ';' -O $tmp.8" +assert_no_diff $tmp.8 $out.8 +rm $tmp.8 diff --git a/bp_test/test/test_uppercase_seq b/bp_test/test/test_uppercase_seq new file mode 100755 index 0000000..3f4ad21 --- /dev/null +++ b/bp_test/test/test_uppercase_seq @@ -0,0 +1,7 @@ +#!/bin/bash + +source "$BP_DIR/bp_test/lib/test.sh" + +run "$bp -I $in -O $tmp.1" +assert_no_diff $tmp.1 $out.1 +rm $tmp.1 -- 2.39.2