Beispiel #1
0
 def test_gc_bounds_error_rise(self):
     more_bounds = [20, 30, 40]
     seq = 'GCGCTATAGCGCTATA'
     # вот так можно проверить, кинет ли ошибку, когда надо ее кидать
     with self.assertRaises(ValueError):
         trimmomatic_clone.gc_bounds(seq, more_bounds)
Beispiel #2
0
 def test_gc_bounds_without_bounds(self):
     zero_bounds = []
     seq = 'GCGCTATAGCGCTATA'
     self.assertTrue(trimmomatic_clone.gc_bounds(seq, zero_bounds))
Beispiel #3
0
 def test_gc_bounds_two_bounds_with_bad_seq(self):
     bounds = [30, 60]
     seq = 'ATATATATATATAT'
     self.assertFalse(trimmomatic_clone.gc_bounds(seq, bounds))
Beispiel #4
0
 def test_gc_bounds_two_bounds_with_good_seq(self):
     bounds = [30, 60]
     seq = 'GCGCTATAGCGCTATA'
     self.assertTrue(trimmomatic_clone.gc_bounds(seq, bounds))
Beispiel #5
0
 def test_gc_bounds_one_bound_with_bad_seq(self):
     bound = [30]
     seq = 'ATATATATATATAT'
     self.assertFalse(trimmomatic_clone.gc_bounds(seq, bound))
Beispiel #6
0
 def test_gc_bounds_one_bound_with_good_seq(self):
     bound = [30]
     seq = 'GCGCTATAGCGCTATA'
     self.assertTrue(trimmomatic_clone.gc_bounds(seq, bound))