def test_unregister(self): @API.register def dummy(): pass API.unregister(dummy) assert dummy not in API.CMDS
def test_register(self): @API.register def dummy(): pass assert dummy in API.CMDS API.unregister(dummy)
def test_unregister_unexisting(self): def dummy(): pass API.unregister(dummy) assert dummy not in API.CMDS