예제 #1
0
파일: holes.py 프로젝트: OSUPychron/pychron
    def test_s1(self):
        s1 = '1-5'
        list1 = [1, 2, 3, 4, 5]
        list2 = parse_holestr(s1)

        self.assertListEqual(list1, list2)
예제 #2
0
파일: holes.py 프로젝트: OSUPychron/pychron
 def test_fail4(self):
     s1 = '-5'
     self.assertIsNone(parse_holestr(s1))
예제 #3
0
파일: holes.py 프로젝트: OSUPychron/pychron
 def test_fail5(self):
     s1 = '1-55-100'
     self.assertIsNone(parse_holestr(s1))
예제 #4
0
파일: holes.py 프로젝트: OSUPychron/pychron
    def test_s3(self):
        s1 = '1 -5, 7-10'
        list1 = [1, 2, 3, 4, 5, 7, 8, 9, 10]
        list2 = parse_holestr(s1)

        self.assertListEqual(list1, list2)
예제 #5
0
파일: holes.py 프로젝트: OSUPychron/pychron
 def test_fail3(self):
     s1 = '1-,'
     self.assertIsNone(parse_holestr(s1))
예제 #6
0
    def test_s1(self):
        s1 = '1-5'
        list1 = [1, 2, 3, 4, 5]
        list2 = parse_holestr(s1)

        self.assertListEqual(list1, list2)
예제 #7
0
파일: holes.py 프로젝트: OSUPychron/pychron
    def test_s2(self):
        s1 = '1,2,3'
        list1 = [1, 2, 3]
        list2 = parse_holestr(s1)

        self.assertListEqual(list1, list2)
예제 #8
0
 def test_fail5(self):
     s1 = '1-55-100'
     self.assertIsNone(parse_holestr(s1))
예제 #9
0
 def test_fail4(self):
     s1 = '-5'
     self.assertIsNone(parse_holestr(s1))
예제 #10
0
 def test_fail3(self):
     s1 = '1-,'
     self.assertIsNone(parse_holestr(s1))
예제 #11
0
    def test_s3(self):
        s1 = '1 -5, 7-10'
        list1 = [1, 2, 3, 4, 5, 7, 8, 9, 10]
        list2 = parse_holestr(s1)

        self.assertListEqual(list1, list2)
예제 #12
0
    def test_s2(self):
        s1 = '1,2,3'
        list1 = [1, 2, 3]
        list2 = parse_holestr(s1)

        self.assertListEqual(list1, list2)