MCPcopy Create free account
hub / github.com/Bytez-com/docs / test_stream_false_does_not_stream

Method test_stream_false_does_not_stream

sdk/python/test.py:84–94  ·  view source on GitHub ↗

Test that `stream=False` does not return a stream.

(self)

Source from the content-addressed store, hash-verified

82 self.assertIsInstance(chunk, str, "streams output")
83
84 def test_stream_false_does_not_stream(self):
85 """Test that `stream=False` does not return a stream."""
86 result = model.run("Jack and jill", stream=False)
87
88 self.assertIsNone(result.error)
89 self.assertIsInstance(result.output, str, "returns output")
90
91 result = model.run("Jack and jill", {"max_length": 100}, stream=False)
92
93 self.assertIsNone(result.error)
94 self.assertIsInstance(result.output, str, "returns output")
95
96if __name__ == "__main__":
97 unittest.main()

Callers

nothing calls this directly

Calls 1

runMethod · 0.45

Tested by

no test coverage detected