From 8f93ff04662000afdd3f0873888418b7b1d192ec Mon Sep 17 00:00:00 2001 From: Matt Witherspoon <32485495+spoonincode@users.noreply.github.com> Date: Tue, 14 Jan 2025 20:59:45 -0500 Subject: [PATCH] relax checktime_hashing_fail contract caching --- unittests/checktime_tests.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/unittests/checktime_tests.cpp b/unittests/checktime_tests.cpp index b26da087fd..591bf1dc0d 100644 --- a/unittests/checktime_tests.cpp +++ b/unittests/checktime_tests.cpp @@ -466,12 +466,8 @@ BOOST_AUTO_TEST_CASE_TEMPLATE(checktime_hashing_fail, T, validating_testers) { t chain.produce_block(); BOOST_TEST( !chain.is_code_cached("testapi"_n) ); - - //hit deadline exception, but cache the contract - BOOST_CHECK_EXCEPTION( call_test( chain, test_api_action{}, - 5000, 8, 8 ), - deadline_exception, is_deadline_exception ); - + //run a simple action to cache the contract + CALL_TEST_FUNCTION(chain, "test_checktime", "checktime_pass", {}); BOOST_TEST( chain.is_code_cached("testapi"_n) ); //the contract should be cached, now we should get deadline_exception because of calls to checktime() from hashing function