test case for invoke_a