test: wrote testcase for apnsrpc