예제 #1
0
 def test_check_good_whitespaces_round_brackets(self):
     result = t.check_brackets('set = (1, 2)', 19)
     self.assertEqual(result, None)
예제 #2
0
 def test_check_good_whitespaces_square_brackets(self):
     result = t.check_brackets('arr = [1, 2]', 18)
     self.assertEqual(result, None)
예제 #3
0
 def test_check_whitespace_before_round_bracket(self):
     ex = 'line: 17, column: 12 whitespace before ")"'
     result = t.check_brackets('set = (1, 2 )', 17)
     self.assertEqual(result, ex)
예제 #4
0
 def test_check_whitespace_after_round_bracket(self):
     ex = 'line: 16, column: 6 whitespace after "("'
     result = t.check_brackets('set = ( 1, 2)', 16)
     self.assertEqual(result, ex)
예제 #5
0
 def test_check_whitespace_before_square_bracket(self):
     ex = 'line: 15, column: 12 whitespace before "]"'
     result = t.check_brackets('arr = [1, 2 ]', 15)
     self.assertEqual(result, ex)
예제 #6
0
 def test_check_whitespace_after_square_bracket(self):
     ex = 'line: 14, column: 6 whitespace after "["'
     result = t.check_brackets('arr = [ 1, 2]', 14)
     self.assertEqual(result, ex)