def test_can_add_violation(self): item = ReviewDAO("uuid", "http://www.globo.com") item.add_violation('some.violation', 'value', 200) expect(item.violations).to_length(1) expect(item.violations[0]).to_be_like({ 'key': 'some.violation', 'value': 'value', 'points': 200 })