Repository: incubator-beam Updated Branches: refs/heads/python-sdk 3a69db0c5 -> 99a33ecdb
Add equality methods to range source. Project: http://git-wip-us.apache.org/repos/asf/incubator-beam/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-beam/commit/837c5aa3 Tree: http://git-wip-us.apache.org/repos/asf/incubator-beam/tree/837c5aa3 Diff: http://git-wip-us.apache.org/repos/asf/incubator-beam/diff/837c5aa3 Branch: refs/heads/python-sdk Commit: 837c5aa31dd170a9c7e1ba6559e77457bf4a9f7f Parents: 3a69db0 Author: Robert Bradshaw <[email protected]> Authored: Tue Oct 4 13:12:08 2016 -0700 Committer: Robert Bradshaw <[email protected]> Committed: Tue Oct 4 14:35:56 2016 -0700 ---------------------------------------------------------------------- sdks/python/apache_beam/io/concat_source_test.py | 8 ++++++++ 1 file changed, 8 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-beam/blob/837c5aa3/sdks/python/apache_beam/io/concat_source_test.py ---------------------------------------------------------------------- diff --git a/sdks/python/apache_beam/io/concat_source_test.py b/sdks/python/apache_beam/io/concat_source_test.py index 828bdb0..e4df472 100644 --- a/sdks/python/apache_beam/io/concat_source_test.py +++ b/sdks/python/apache_beam/io/concat_source_test.py @@ -70,6 +70,14 @@ class RangeSource(iobase.BoundedSource): return yield k + # For testing + def __eq__(self, other): + return (type(self) == type(other) + and self._start == other._start and self._end == other._end) + + def __ne__(self, other): + return not self == other + class ConcatSourceTest(unittest.TestCase):
