예제 #1
0
 def test_choices_not_valid_choice(self):
     self.expect_raises(valid.choice(valid.string, ('a', 'b', 'c')), 'd',
         errors=['The value is not a valid choice: d']
     )
예제 #2
0
 def test_choices_not_valid_choice(self):
     self.expect_raises(valid.choice(valid.string, ('a', 'b', 'c')), 'd',
         errors=['The value is not a valid choice: d']
     )
예제 #3
0
 def test_choices(self):
     self.expect(valid.choice(valid.string, ('a', 'b', 'c')), 'a')
예제 #4
0
 def test_choices(self):
     self.expect(valid.choice(valid.string, ('a', 'b', 'c')), 'a')