def test_setattr(user_obj): dset = sn.setattr(user_obj, '_a', 5) assert 0 == user_obj._a sn.evaluate(dset) assert 5 == user_obj._a
def test_setattr(self): dset = sn.setattr(self, '_a', 5) self.assertEqual(0, self._a) evaluate(dset) self.assertEqual(5, self._a)
def test_setattr(self): dset = sn.setattr(self, '_a', 5) assert 0 == self._a sn.evaluate(dset) assert 5 == self._a