

def test_tagging(self):
    o = RoutableSubmitSm(self.PDU, self.user, datetime.now())
    self.assertRaises(InvalidTagError, o.addTag, 'anything')
    self.assertRaises(InvalidTagError, o.hasTag, 'anything')
    self.assertRaises(InvalidTagError, o.removeTag, 'anything')
    o.addTag(23)
    self.assertTrue(o.hasTag(23))
    self.assertFalse(o.hasTag(30))
    self.assertRaises(TagNotFoundError, o.removeTag, 30)
    self.assertEqual([23], o.getTags())
    self.flushTags()
    self.assertEqual([], o.getTags())

dataset/ETHPy150Open jookies/jasmin/jasmin/routing/test/test_Routables.py RoutableSubmitSmTestCase.test_tagging/VarMisuse@127/165 `o`->`self`