Skip to content

Commit

Permalink
format lines that are too long
Browse files Browse the repository at this point in the history
  • Loading branch information
try-agaaain committed Mar 17, 2024
1 parent 21c6248 commit 6a569e8
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions tests/test_rest_rpc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,10 @@ TEST_CASE("test_client_sync_call") {
CHECK(r);
auto result = client.call<int>("add", 1, 2);
CHECK_EQ(result, 3);
CHECK_THROWS_WITH_AS(client.call<int>("add", 1, "2"), "unpack failed: Args not match!", std::logic_error);
CHECK_THROWS_WITH_AS(client.call<int>("Add", 1, 2), "unknown function: 3961593724", std::logic_error);
CHECK_THROWS_WITH_AS(client.call<int>("add", 1, "2"),
"unpack failed: Args not match!", std::logic_error);
CHECK_THROWS_WITH_AS(client.call<int>("Add", 1, 2),
"unknown function: 3961593724", std::logic_error);
}

TEST_CASE("test_client_sync_call_return_void") {
Expand Down Expand Up @@ -218,7 +220,8 @@ TEST_CASE("test_client_async_call") {
auto fu = client.async_call<FUTURE>("hello", "purecpp");
CHECK_NOTHROW(fu.get().as()); // no return
auto fu_err = client.async_call<FUTURE>("Hello", "purecpp");
CHECK_THROWS_WITH_AS(fu_err.get().as(), "unknown function: 2333776211", std::logic_error);
CHECK_THROWS_WITH_AS(fu_err.get().as(),
"unknown function: 2333776211", std::logic_error);
}
TEST_CASE("test_client_async_call_not_connect") {
rpc_client client("127.0.0.1", 9001);
Expand Down

0 comments on commit 6a569e8

Please sign in to comment.