mirror of
https://github.com/XRPLF/clio.git
synced 2025-12-06 17:27:58 +00:00
@@ -58,7 +58,7 @@ TEST_F(RPCAccountCurrenciesHandlerTest, AccountNotExist)
|
||||
}})",
|
||||
ACCOUNT));
|
||||
auto const handler = AnyHandler{AccountCurrenciesHandler{mockBackendPtr}};
|
||||
runSpawn([&](auto& yield) {
|
||||
runSpawn([&](auto yield) {
|
||||
auto const output = handler.process(input, Context{std::ref(yield)});
|
||||
ASSERT_FALSE(output);
|
||||
auto const err = RPC::makeError(output.error());
|
||||
@@ -82,7 +82,7 @@ TEST_F(RPCAccountCurrenciesHandlerTest, LedgerNonExistViaIntSequence)
|
||||
}})",
|
||||
ACCOUNT));
|
||||
auto const handler = AnyHandler{AccountCurrenciesHandler{mockBackendPtr}};
|
||||
runSpawn([&](auto& yield) {
|
||||
runSpawn([&](auto yield) {
|
||||
auto const output = handler.process(input, Context{std::ref(yield)});
|
||||
ASSERT_FALSE(output);
|
||||
auto const err = RPC::makeError(output.error());
|
||||
@@ -109,7 +109,7 @@ TEST_F(RPCAccountCurrenciesHandlerTest, LedgerNonExistViaStringSequence)
|
||||
ACCOUNT,
|
||||
seq));
|
||||
auto const handler = AnyHandler{AccountCurrenciesHandler{mockBackendPtr}};
|
||||
runSpawn([&](auto& yield) {
|
||||
runSpawn([&](auto yield) {
|
||||
auto const output = handler.process(input, Context{std::ref(yield)});
|
||||
ASSERT_FALSE(output);
|
||||
auto const err = RPC::makeError(output.error());
|
||||
@@ -136,7 +136,7 @@ TEST_F(RPCAccountCurrenciesHandlerTest, LedgerNonExistViaHash)
|
||||
ACCOUNT,
|
||||
LEDGERHASH));
|
||||
auto const handler = AnyHandler{AccountCurrenciesHandler{mockBackendPtr}};
|
||||
runSpawn([&](auto& yield) {
|
||||
runSpawn([&](auto yield) {
|
||||
auto const output = handler.process(input, Context{std::ref(yield)});
|
||||
ASSERT_FALSE(output);
|
||||
auto const err = RPC::makeError(output.error());
|
||||
@@ -203,7 +203,7 @@ TEST_F(RPCAccountCurrenciesHandlerTest, DefaultParameter)
|
||||
}})",
|
||||
ACCOUNT));
|
||||
auto const handler = AnyHandler{AccountCurrenciesHandler{mockBackendPtr}};
|
||||
runSpawn([&](auto& yield) {
|
||||
runSpawn([&](auto yield) {
|
||||
auto const output = handler.process(input, Context{std::ref(yield)});
|
||||
ASSERT_TRUE(output);
|
||||
EXPECT_EQ(*output, json::parse(OUTPUT));
|
||||
@@ -243,7 +243,7 @@ TEST_F(RPCAccountCurrenciesHandlerTest, RequestViaLegderHash)
|
||||
ACCOUNT,
|
||||
LEDGERHASH));
|
||||
auto const handler = AnyHandler{AccountCurrenciesHandler{mockBackendPtr}};
|
||||
runSpawn([&](auto& yield) {
|
||||
runSpawn([&](auto yield) {
|
||||
auto const output = handler.process(input, Context{std::ref(yield)});
|
||||
ASSERT_TRUE(output);
|
||||
});
|
||||
@@ -284,7 +284,7 @@ TEST_F(RPCAccountCurrenciesHandlerTest, RequestViaLegderSeq)
|
||||
ACCOUNT,
|
||||
ledgerSeq));
|
||||
auto const handler = AnyHandler{AccountCurrenciesHandler{mockBackendPtr}};
|
||||
runSpawn([&](auto& yield) {
|
||||
runSpawn([&](auto yield) {
|
||||
auto const output = handler.process(input, Context{std::ref(yield)});
|
||||
ASSERT_TRUE(output);
|
||||
EXPECT_EQ((*output).as_object().at("ledger_index").as_uint64(), ledgerSeq);
|
||||
|
||||
Reference in New Issue
Block a user