def test(): a, b = spawn(set_thing, b'a', 1), spawn(set_thing, b'b', 2) a.get(), b.get() a, b = spawn(delete_thing, b'a'), spawn(delete_thing, b'b') a.get(), b.get() a, b = spawn(get_thing, b'a'), spawn(get_thing, b'b') return (a.get(), b.get())
def test(): a = spawn(do_thing, 'a', '1') b = spawn(do_thing, 'b', '1') a.get(), b.get()
def test(): a, b = spawn(get_thing, 'a', 1), spawn(get_thing, 'b', 2) return a.get() + b.get()
def get_thing(t, v): a = spawn(self.client.delete, self.key_prefix + 'hi' + t) b = spawn(self.client.set, self.key_prefix + 'hi' + t, v) c = spawn(self.client.get, self.key_prefix + 'hi' + t) _, _, result = a.get(), b.get(), c.get() return int(result)
def test(): a, b = spawn(set_thing, b'a', 1), spawn(set_thing, b'b', 2) a.get(), b.get() a, b = spawn(get_thing, b'a'), spawn(get_thing, b'b') return a.get() + b.get()