From eaa477bcbf8e58cbb070c66cfe86e6e368a5f22c Mon Sep 17 00:00:00 2001 From: canepat <16927169+canepat@users.noreply.github.com> Date: Sat, 6 Apr 2024 21:32:13 +0200 Subject: [PATCH] run perf workflow on PR avoid clang tidy warning in test --- .github/workflows/rpc-performance-tests.yml | 7 +++++++ silkworm/rpc/core/evm_debug_test.cpp | 22 ++++++++++----------- 2 files changed, 18 insertions(+), 11 deletions(-) diff --git a/.github/workflows/rpc-performance-tests.yml b/.github/workflows/rpc-performance-tests.yml index 42b819ff72..49aab1af13 100644 --- a/.github/workflows/rpc-performance-tests.yml +++ b/.github/workflows/rpc-performance-tests.yml @@ -1,6 +1,13 @@ name: QA - RPC Performance Tests on: + pull_request: + branches: + - master + types: + - opened + - ready_for_review + - synchronize schedule: - cron: '0 0 * * *' # Run every day at 00:00 AM UTC diff --git a/silkworm/rpc/core/evm_debug_test.cpp b/silkworm/rpc/core/evm_debug_test.cpp index 51f513c750..3e0e20a429 100644 --- a/silkworm/rpc/core/evm_debug_test.cpp +++ b/silkworm/rpc/core/evm_debug_test.cpp @@ -69,7 +69,7 @@ class TestDebugExecutor : DebugExecutor { TestDebugExecutor(const TestDebugExecutor&) = delete; TestDebugExecutor& operator=(const TestDebugExecutor&) = delete; - Task execute(json::Stream& stream, const ChainStorage& storage, const silkworm::Block& block, const Call& call) { + Task exec(json::Stream& stream, const ChainStorage& storage, const silkworm::Block& block, const Call& call) { return DebugExecutor::execute(stream, storage, block, call); } }; @@ -150,7 +150,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute precompiled") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close()); @@ -305,7 +305,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute call 1") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close()); @@ -368,7 +368,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute call 1") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close()); @@ -479,7 +479,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute call 1") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close()); @@ -581,7 +581,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute call 1") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close()); @@ -688,7 +688,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute call 1") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close()); @@ -796,7 +796,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute call 1") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close()); @@ -891,7 +891,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute call 1") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close()); @@ -1102,7 +1102,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute call 2") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close()); @@ -1263,7 +1263,7 @@ TEST_CASE_METHOD(DebugExecutorTest, "DebugExecutor::execute call with error") { const RemoteChainStorage storage{db_reader, backend.get()}; stream.open_object(); - spawn_and_wait(executor.execute(stream, storage, block, call)); + spawn_and_wait(executor.exec(stream, storage, block, call)); stream.close_object(); spawn_and_wait(stream.close());