Example #1
0
    def test_eq__should_return_comparing_result(self, number, group):
        sdk = Mock()
        obj = Relay(sdk, RelayGroup.lock, 2)
        other_obj = Relay(sdk, group, number)
        expect = obj.number == other_obj.number and obj.group == other_obj.group

        assert obj.__eq__(other_obj) == expect
Example #2
0
    def test_eq__if_other_object_type__should_return_false(self, val):
        sdk = Mock()
        obj = Relay(sdk, RelayGroup.lock, 2)

        assert obj.__eq__(val) is False