liferoad commented on code in PR #35881: URL: https://github.com/apache/beam/pull/35881#discussion_r2280883827
########## sdks/python/apache_beam/transforms/core_test.py: ########## @@ -162,6 +162,14 @@ class PartitionTest(unittest.TestCase): + def test_partition_with_bools(self): + with pytest.raises( + Exception, + match="PartitionFn yielded a 'bool' when it should only yields integers" + ): + with beam.testing.test_pipeline.TestPipeline() as p: + _ = (p | beam.Create([True]) | beam.Partition(lambda x, _: x, 2)) Review Comment: let us add another type like floats to test. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: github-unsubscr...@beam.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org