From 7a5a0ef9eb13312b2ee8b0b3731dbddb4de7b669 Mon Sep 17 00:00:00 2001 From: Tom Clegg Date: Mon, 24 Jun 2024 14:43:46 -0400 Subject: [PATCH 1/1] 21703: Improve test failure reporting. Arvados-DCO-1.1-Signed-off-by: Tom Clegg --- services/api/test/functional/sys_controller_test.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/services/api/test/functional/sys_controller_test.rb b/services/api/test/functional/sys_controller_test.rb index 88603cbc2d..c3f13cf4b8 100644 --- a/services/api/test/functional/sys_controller_test.rb +++ b/services/api/test/functional/sys_controller_test.rb @@ -167,6 +167,8 @@ class SysControllerTest < ActionController::TestCase assert_equal true, ready.pop authorize_with :admin post :trash_sweep - assert_equal [[uuid_active]], ActiveRecord::Base.connection.exec_query("SELECT uuid FROM uuid_locks ORDER BY uuid", "", []).rows + rows = ActiveRecord::Base.connection.exec_query("SELECT uuid FROM uuid_locks ORDER BY uuid", "", []).rows + assert_includes(rows, [uuid_active], "row with active lock (still held by thread) should not have been deleted") + refute_includes(rows, [uuid_inactive], "row with inactive lock should have been deleted") end end -- 2.30.2