@@ -39,7 +39,7 @@ def test_context_validation(self):
3939 from pydantic import ValidationError # pylint: disable=C0415
4040
4141 with pytest .raises (ValidationError ):
42- IDGeneratorContext (task_id = {"not" : "a string" }) # noqa
42+ IDGeneratorContext (task_id = {"not" : "a string" }) # noqa
4343
4444
4545class TestIDGenerator :
@@ -48,22 +48,24 @@ class TestIDGenerator:
4848 def test_cannot_instantiate_abstract_class (self ):
4949 """Test that IDGenerator cannot be instantiated directly."""
5050 with pytest .raises (TypeError ):
51- IDGenerator () # noqa pylint: disable=E0110
51+ IDGenerator () # noqa pylint: disable=E0110
5252
5353 def test_subclass_must_implement_generate (self ):
5454 """Test that subclasses must implement the generate method."""
5555
56- class IncompleteGenerator (IDGenerator ): # noqa pylint: disable=C0115,R0903
56+ class IncompleteGenerator (IDGenerator ): # noqa pylint: disable=C0115,R0903
5757 pass
5858
5959 with pytest .raises (TypeError ):
60- IncompleteGenerator () # noqa pylint: disable=E0110
60+ IncompleteGenerator () # noqa pylint: disable=E0110
6161
6262 def test_valid_subclass_implementation (self ):
6363 """Test that a valid subclass can be instantiated."""
64- class ValidGenerator (IDGenerator ): # pylint: disable=C0115,R0903
64+
65+ class ValidGenerator (IDGenerator ): # pylint: disable=C0115,R0903
6566 def generate (self , context : IDGeneratorContext ) -> str :
6667 return "test_id"
68+
6769 generator = ValidGenerator ()
6870 assert generator .generate (IDGeneratorContext ()) == "test_id"
6971
0 commit comments