def test_postcall(self):
        """postcall hooks are called after API call"""
        hash_key = DynamoKey("id")
        self.dynamo.create_table("foobar", hash_key=hash_key)
        calls = []

        def hook(*args):
            """Log the call into a list"""
            calls.append(args)

        self.dynamo.subscribe("postcall", hook)
        self.dynamo.describe_table("foobar")
        self.assertEqual(len(calls), 1)
        args = calls[0]
        self.assertEqual(len(args), 4)
        conn, command, kwargs, response = args
        self.assertEqual(conn, self.dynamo)
        self.assertEqual(command, "describe_table")
        self.assertEqual(kwargs["TableName"], "foobar")
        self.assertEqual(response["Table"]["TableName"], "foobar")