From 5009e5924ede6cb0762619413e72fbcea97ebb38 Mon Sep 17 00:00:00 2001 From: Jason Stephenson Date: Sun, 24 Oct 2021 14:38:52 -0400 Subject: [PATCH] LP1948594: Fix pgtap live test Fix the lp1145213_test_func_asset.merge_record_assets.pg pgtap live test by removing the COMMIT and adding a ROLLBACK at the end. This permits the test to run multiple times without requiring a database reload. To verify the bug: 1. Install the pgtap package appropriate for your PostgreSQL database version. 2. Load a fresh database with eg_db_config using the --load-all-sample option. 3. Create the pgtap extension in the evergreen database. 4. Run the Open-ILS/src/sql/Pg/live_t/ tests with pg_prove. 5. Repeat step 4, and if this patch has not been applied, then the lp1145213_test_func_asset.merge_record_assets.pg tests will fail on the second run. To test the fix, repeat steps 2 - 5, above, after pulling this commit. Step 5 should succeed. Signed-off-by: Jason Stephenson Signed-off-by: Galen Charlton --- .../Pg/live_t/lp1145213_test_func_asset.merge_record_assets.pg | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Open-ILS/src/sql/Pg/live_t/lp1145213_test_func_asset.merge_record_assets.pg b/Open-ILS/src/sql/Pg/live_t/lp1145213_test_func_asset.merge_record_assets.pg index 5eae39ef31..22bcb3a041 100644 --- a/Open-ILS/src/sql/Pg/live_t/lp1145213_test_func_asset.merge_record_assets.pg +++ b/Open-ILS/src/sql/Pg/live_t/lp1145213_test_func_asset.merge_record_assets.pg @@ -53,7 +53,6 @@ INSERT INTO asset.copy(id, circ_lib, creator, call_number, editor, copy_number, (907777, 6, 1, 1000001, 1, 1, 1, 1, '3copycopycopy'), (908888, 4, 1, 1000002, 1, 1, 1, 1, '4copycopycopy'); -COMMIT; ----------------------------------- -- Test asset.merge_record_assets() @@ -91,4 +90,4 @@ SELECT is( ); SELECT * FROM finish(); - +ROLLBACK; -- 2.43.2