Пример #1
0
    def test_last_name_invalid(self):

        validation = FormValidation()

        self.assertFalse(validation.name('Johnson$'))
Пример #2
0
    def test_last_name_filled_three(self):

        validation = FormValidation()

        self.assertTrue(validation.name('Jo-Johnson'))
Пример #3
0
    def test_last_name_filled_four(self):

        validation = FormValidation()

        self.assertTrue(validation.name('Johnson 3rd'))
Пример #4
0
    def test_name_invalid(self):

        validation = FormValidation()

        self.assertFalse(validation.name('James!!'))
Пример #5
0
    def test_name_filled_four(self):

        validation = FormValidation()

        self.assertTrue(validation.name('James-Christopher 3'))
Пример #6
0
    def test_name_filled_two(self):

        validation = FormValidation()

        self.assertTrue(validation.name('James Christopher'))
Пример #7
0
    def test_name_filled(self):

        validation = FormValidation()

        self.assertTrue(validation.name('James'))
Пример #8
0
    def test_name_empty(self):

        validation = FormValidation()

        self.assertFalse(validation.name(''))