示例#1
0
    def test_equality_fail(self, override):
        """Should return False if core attribs do not match."""
        kwargs = dict(name="foo",
                      description="bar",
                      uid="uid",
                      entries=[1, 2, 3])

        rep_1 = report.Report(**kwargs)
        rep_2 = report.Report(dict(kwargs, **override))

        # need to set this explicitly
        rep_2.logs = rep_1.logs

        assert rep_1 != rep_2
示例#2
0
    def test_equality(self):
        """Should return True if core attribs match."""
        kwargs = dict(name="foo",
                      description="bar",
                      uid="uid",
                      entries=[1, 2, 3])

        rep_1 = report.Report(**kwargs)
        rep_2 = report.Report(**kwargs)

        # need to set this explicitly
        rep_2.logs = rep_1.logs

        assert rep_1 == rep_2