MCPcopy Create free account
hub / github.com/ScrapeGraphAI/toonify / test_invalid_input

Method test_invalid_input

tests/test_pydantic.py:148–154  ·  view source on GitHub ↗

Test error handling for invalid input.

(self)

Source from the content-addressed store, hash-verified

146 assert 'tags: [tag1|tag2|tag3]' in toon_pipe
147
148 def test_invalid_input(self):
149 """Test error handling for invalid input."""
150 with pytest.raises(ValueError, match="Expected Pydantic BaseModel"):
151 encode_pydantic({'not': 'a model'})
152
153 with pytest.raises(ValueError, match="Expected Pydantic BaseModel"):
154 encode_pydantic("string")
155
156
157@pytest.mark.skipif(not PYDANTIC_AVAILABLE, reason="pydantic not installed")

Callers

nothing calls this directly

Calls 1

encode_pydanticFunction · 0.90

Tested by

no test coverage detected