def test_exception_reserved_invalid_name(self, value, expected): with pytest.raises(expected): validate_sqlite_table_name(value)
def test_normal_non_alphabet_first_char(self, value): validate_sqlite_table_name(value)
def test_exception_invalid_win_char(self, value): with pytest.raises(InvalidCharError): validate_sqlite_table_name(value)
def test_normal_ascii(self, value): validate_sqlite_table_name(value)
def test_normal_utf8(self, value): validate_sqlite_table_name(value)
def test_exception_reserved_invalid_name(self, value): try: validate_sqlite_table_name(value) except ValidationError as e: assert e.reason == ErrorReason.RESERVED_NAME assert e.reusable_name is False
def test_exception_invalid_win_char(self, value): try: validate_sqlite_table_name(value) except ValidationError as e: assert e.reason == ErrorReason.INVALID_CHARACTER