From b3973d09a7d111e85b5e8a6c4904e1e1e28b35d1 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 29 Nov 2019 22:54:35 +0000 Subject: [PATCH 001/887] Fixed test dependency on user running them. Resolves #969 --- test/ut3_tester/core/test_ut_suite.pkb | 14 +++--- test/ut3_tester/core/test_ut_test.pkb | 60 +++++++++++++------------- test/ut3_tester_helper/run_helper.pkb | 6 +-- 3 files changed, 40 insertions(+), 40 deletions(-) diff --git a/test/ut3_tester/core/test_ut_suite.pkb b/test/ut3_tester/core/test_ut_suite.pkb index 3ea323a6d..9c52df9e5 100644 --- a/test/ut3_tester/core/test_ut_suite.pkb +++ b/test/ut3_tester/core/test_ut_suite.pkb @@ -19,11 +19,11 @@ create or replace package body test_ut_suite is l_suite ut3.ut_suite; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); + l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; l_suite.disabled_flag := ut3.ut_utils.boolean_to_int(true); - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'UT_EXAMPLE_TESTS', 'set_g_number_0', ut3.ut_utils.gc_before_all)); - l_suite.after_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'UT_EXAMPLE_TESTS', 'add_1_to_g_number', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'set_g_number_0', ut3.ut_utils.gc_before_all)); + l_suite.after_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'add_1_to_g_number', ut3.ut_utils.gc_before_all)); l_suite.items.extend; l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'add_1_to_g_number', a_line_no=> 1); l_suite.items.extend; @@ -44,9 +44,9 @@ create or replace package body test_ut_suite is l_suite ut3.ut_suite; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); + l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'UT_EXAMPLE_TESTS', 'failing_procedure', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'failing_procedure', ut3.ut_utils.gc_before_all)); l_suite.items.extend; l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'set_g_number_0', a_line_no=> 1); --Act @@ -65,9 +65,9 @@ create or replace package body test_ut_suite is l_suite ut3.ut_suite; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); + l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; - l_suite.after_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'UT_EXAMPLE_TESTS', 'failing_procedure', ut3.ut_utils.gc_after_all)); + l_suite.after_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'failing_procedure', ut3.ut_utils.gc_after_all)); l_suite.items.extend; l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'set_g_number_0', a_line_no=> 1); diff --git a/test/ut3_tester/core/test_ut_test.pkb b/test/ut3_tester/core/test_ut_test.pkb index 2a85a323f..b4dcc2536 100644 --- a/test/ut3_tester/core/test_ut_test.pkb +++ b/test/ut3_tester/core/test_ut_test.pkb @@ -12,7 +12,7 @@ create or replace package body test_ut_test is --Arrange l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); l_suite.items.extend; l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); @@ -38,11 +38,11 @@ create or replace package body test_ut_test is --Arrange l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); l_test := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); - l_test.before_test_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_before_test)); - l_test.after_test_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_after_test)); + l_test.before_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_before_test)); + l_test.after_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_after_test)); l_suite.items.extend; l_suite.items(l_suite.items.last) := l_test; l_suite.items.extend; @@ -65,10 +65,10 @@ create or replace package body test_ut_test is begin --Arrange l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); l_test := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); - l_test.before_each_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_before_each)); - l_test.after_each_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_after_each)); + l_test.before_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_before_each)); + l_test.after_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_after_each)); l_suite.items.extend; l_suite.items(l_suite.items.last) := l_test; l_suite.items.extend; @@ -90,11 +90,11 @@ create or replace package body test_ut_test is l_test ut3.ut_test; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'ut_example_tests', a_line_no=> 1); - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); + l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); + l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); l_test := ut3.ut_test(a_object_owner =>'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); - l_test.before_test_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_before_test)); - l_test.after_test_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_test)); + l_test.before_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_before_test)); + l_test.after_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_test)); l_suite.items.extend; l_suite.items(l_suite.items.last) := l_test; l_suite.items.extend; @@ -116,15 +116,15 @@ create or replace package body test_ut_test is l_test ut3.ut_test; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'ut_example_tests', a_line_no=> 1); - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); - l_test := ut3.ut_test(a_object_owner => USER,a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); - l_test.before_each_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_before_each)); - l_test.after_each_list := ut3.ut_executables(ut3.ut_executable(USER, 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_each)); + l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); + l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); + l_test := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_test.before_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_before_each)); + l_test.after_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_each)); l_suite.items.extend; l_suite.items(l_suite.items.last) := l_test; l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => USER,a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); --Act l_suite.do_execute(); --Assert @@ -148,8 +148,8 @@ create or replace package body test_ut_test is begin l_test.after_each_list := ut3.ut_executables( ut3.ut_executable( - user, - 'UT_EXAMPLE_TESTS', + 'ut3_tester_helper', + 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_each ) @@ -171,7 +171,7 @@ create or replace package body test_ut_test is ); begin l_test.after_each_list := ut3.ut_executables( - ut3.ut_executable(user, 'ut_example_tests', 'invalid setup name', ut3.ut_utils.gc_after_each) + ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid setup name', ut3.ut_utils.gc_after_each) ); --Act l_test.do_execute(); @@ -190,7 +190,7 @@ create or replace package body test_ut_test is ); begin l_test.after_each_list := ut3.ut_executables( - ut3.ut_executable(user, 'ut_example_tests', null, ut3.ut_utils.gc_after_each) + ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3.ut_utils.gc_after_each) ); --Act l_test.do_execute(); @@ -325,7 +325,7 @@ create or replace package body test_ut_test is a_line_no => null ); begin - l_test.before_each_list := ut3.ut_executables(ut3.ut_executable(user, 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_each)); + l_test.before_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_each)); --Act l_test.do_execute(); --Assert @@ -344,7 +344,7 @@ create or replace package body test_ut_test is ); begin l_test.before_each_list := ut3.ut_executables( - ut3.ut_executable(user, 'ut_example_tests', 'invalid setup name', ut3.ut_utils.gc_before_each) + ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid setup name', ut3.ut_utils.gc_before_each) ); --Act l_test.do_execute(); @@ -363,7 +363,7 @@ create or replace package body test_ut_test is ); begin l_test.before_each_list := ut3.ut_executables( - ut3.ut_executable(user, 'ut_example_tests', null, ut3.ut_utils.gc_before_each) + ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3.ut_utils.gc_before_each) ); --Act l_test.do_execute(); @@ -529,7 +529,7 @@ create or replace package body test_ut_test is a_line_no => null ); begin - l_test.before_test_list := ut3.ut_executables(ut3.ut_executable(user, 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_test)); + l_test.before_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_test)); --Act l_test.do_execute(); --Assert @@ -547,7 +547,7 @@ create or replace package body test_ut_test is ); begin l_test.before_test_list := ut3.ut_executables( - ut3.ut_executable(user, 'ut_example_tests', 'invalid setup name', ut3.ut_utils.gc_before_test) + ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid setup name', ut3.ut_utils.gc_before_test) ); --Act l_test.do_execute(); @@ -566,7 +566,7 @@ create or replace package body test_ut_test is ); begin l_test.before_test_list := ut3.ut_executables( - ut3.ut_executable(user, 'ut_example_tests', null, ut3.ut_utils.gc_before_test) + ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3.ut_utils.gc_before_test) ); --Act l_test.do_execute(); @@ -584,7 +584,7 @@ create or replace package body test_ut_test is a_line_no => null ); begin - l_test.after_test_list := ut3.ut_executables(ut3.ut_executable(user, 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_test)); + l_test.after_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_test)); --Act l_test.do_execute(); --Assert @@ -602,7 +602,7 @@ create or replace package body test_ut_test is ); begin l_test.after_test_list := ut3.ut_executables( - ut3.ut_executable(user, 'ut_example_tests', 'invalid procedure name', ut3.ut_utils.gc_after_test) + ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid procedure name', ut3.ut_utils.gc_after_test) ); --Act l_test.do_execute(); @@ -621,7 +621,7 @@ create or replace package body test_ut_test is ); begin l_test.after_test_list := ut3.ut_executables( - ut3.ut_executable(user, 'ut_example_tests', null, ut3.ut_utils.gc_after_test) + ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3.ut_utils.gc_after_test) ); --Act l_test.do_execute(); diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index ef6528e04..9a9c8587f 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -550,11 +550,11 @@ create or replace package body run_helper is begin --Arrange execute immediate 'delete from ut$test_table'; - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'UT_TRANSACTION_CONTROL', a_line_no=> 1); + l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_TRANSACTION_CONTROL', a_line_no=> 1); l_suite.path := 'ut_transaction_control'; - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'UT_TRANSACTION_CONTROL', 'setup', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_TRANSACTION_CONTROL', 'setup', ut3.ut_utils.gc_before_all)); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => USER, a_object_name => 'ut_transaction_control',a_name => a_procedure_name, a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_transaction_control',a_name => a_procedure_name, a_line_no=> 1); l_suite.set_rollback_type(a_rollback_type); --Act From 39d144ae7f55cf13cd22d5d313f96c742980b305 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 30 Nov 2019 00:59:11 +0000 Subject: [PATCH 002/887] Changed how savepoint name is generated. Resolves #982 --- source/core/coverage/proftab.sql | 2 +- source/core/ut_savepoint_seq.sql | 15 --------------- source/core/ut_utils.pkb | 2 +- source/install.sql | 1 - source/uninstall_objects.sql | 2 -- 5 files changed, 2 insertions(+), 20 deletions(-) delete mode 100644 source/core/ut_savepoint_seq.sql diff --git a/source/core/coverage/proftab.sql b/source/core/coverage/proftab.sql index 62c69dc9a..a5d09f43d 100644 --- a/source/core/coverage/proftab.sql +++ b/source/core/coverage/proftab.sql @@ -37,7 +37,7 @@ begin if l_tab_exist = 0 then execute immediate q'[create table plsql_profiler_units ( - runid number references plsql_profiler_runs, + runid number(18) references plsql_profiler_runs, unit_number number, -- internally generated library unit # unit_type varchar2(128), -- library unit type unit_owner varchar2(128), -- library unit owner name diff --git a/source/core/ut_savepoint_seq.sql b/source/core/ut_savepoint_seq.sql deleted file mode 100644 index e1d80f452..000000000 --- a/source/core/ut_savepoint_seq.sql +++ /dev/null @@ -1,15 +0,0 @@ -create sequence ut_savepoint_seq - /* - utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - http://www.apache.org/licenses/LICENSE-2.0 - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - */ - start with 1 cache 20; \ No newline at end of file diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 83d519811..d593f0a65 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -59,7 +59,7 @@ create or replace package body ut_utils is function gen_savepoint_name return varchar2 is begin - return 's'||trim(to_char(ut_savepoint_seq.nextval,'0000000000000000000000000000')); + return 's'||to_char(systimestamp,'yyyymmddhh24missff9'); end; procedure debug_log(a_message varchar2) is diff --git a/source/install.sql b/source/install.sql index 1f9913b0a..5a4f1449c 100644 --- a/source/install.sql +++ b/source/install.sql @@ -59,7 +59,6 @@ end; @@install_component.sql 'core/types/ut_reporters_info.tps' @@install_component.sql 'core/ut_utils.pks' @@install_component.sql 'core/ut_metadata.pks' -@@install_component.sql 'core/ut_savepoint_seq.sql' @@install_component.sql 'core/ut_utils.pkb' @@install_component.sql 'core/ut_metadata.pkb' @@install_component.sql 'reporters/ut_ansiconsole_helper.pks' diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index c905153f4..d540efbbb 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -243,8 +243,6 @@ end; drop package ut_utils; -drop sequence ut_savepoint_seq; - drop type ut_documentation_reporter force; drop type ut_debug_reporter force; From 4bb7a951ef5bac19ec98233e979d093c3bef9bc8 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 30 Nov 2019 16:55:24 +0000 Subject: [PATCH 003/887] Added a hash of owner to the generated savepoint name. Resolves #982 --- source/core/coverage/proftab.sql | 2 +- source/core/ut_savepoint_seq.sql | 15 +++++++++++++++ source/core/ut_utils.pkb | 3 ++- source/install.sql | 1 + source/uninstall_objects.sql | 2 ++ 5 files changed, 21 insertions(+), 2 deletions(-) create mode 100644 source/core/ut_savepoint_seq.sql diff --git a/source/core/coverage/proftab.sql b/source/core/coverage/proftab.sql index a5d09f43d..62c69dc9a 100644 --- a/source/core/coverage/proftab.sql +++ b/source/core/coverage/proftab.sql @@ -37,7 +37,7 @@ begin if l_tab_exist = 0 then execute immediate q'[create table plsql_profiler_units ( - runid number(18) references plsql_profiler_runs, + runid number references plsql_profiler_runs, unit_number number, -- internally generated library unit # unit_type varchar2(128), -- library unit type unit_owner varchar2(128), -- library unit owner name diff --git a/source/core/ut_savepoint_seq.sql b/source/core/ut_savepoint_seq.sql new file mode 100644 index 000000000..b87d18e6d --- /dev/null +++ b/source/core/ut_savepoint_seq.sql @@ -0,0 +1,15 @@ +create sequence ut_savepoint_seq + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + http://www.apache.org/licenses/LICENSE-2.0 + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + start with 1 cache 20 minvalue 1 maxvalue 99999999999999999 cycle; \ No newline at end of file diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index d593f0a65..8ebb50f53 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -22,6 +22,7 @@ create or replace package body ut_utils is gc_invalid_first_xml_char constant varchar2(50) := '[^_a-zA-Z]'; gc_invalid_xml_char constant varchar2(50) := '[^_a-zA-Z0-9\.-]'; gc_full_valid_xml_name constant varchar2(50) := '^([_a-zA-Z])([_a-zA-Z0-9\.-])*$'; + gc_owner_hash constant integer(11) := dbms_utility.get_hash_value( ut_owner(), 0, power(2,31)-1); function surround_with(a_value varchar2, a_quote_char varchar2) return varchar2 is begin @@ -59,7 +60,7 @@ create or replace package body ut_utils is function gen_savepoint_name return varchar2 is begin - return 's'||to_char(systimestamp,'yyyymmddhh24missff9'); + return 's'||gc_owner_hash||trim(to_char(ut_savepoint_seq.nextval,'00000000000000000')); end; procedure debug_log(a_message varchar2) is diff --git a/source/install.sql b/source/install.sql index 5a4f1449c..1f9913b0a 100644 --- a/source/install.sql +++ b/source/install.sql @@ -59,6 +59,7 @@ end; @@install_component.sql 'core/types/ut_reporters_info.tps' @@install_component.sql 'core/ut_utils.pks' @@install_component.sql 'core/ut_metadata.pks' +@@install_component.sql 'core/ut_savepoint_seq.sql' @@install_component.sql 'core/ut_utils.pkb' @@install_component.sql 'core/ut_metadata.pkb' @@install_component.sql 'reporters/ut_ansiconsole_helper.pks' diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index d540efbbb..c905153f4 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -243,6 +243,8 @@ end; drop package ut_utils; +drop sequence ut_savepoint_seq; + drop type ut_documentation_reporter force; drop type ut_debug_reporter force; From 42053b4c5bd3badb964176e83571b4c42791b734 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sat, 30 Nov 2019 18:39:06 +0000 Subject: [PATCH 004/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 6a2b49ced..439a68670 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 2d04c1cb8..e0c634bf8 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index c535b514d..31192f201 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index db847e339..7a5f97899 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index efe13d2df..56f7877ca 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 4693d3db4..634c51837 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index d7dc12567..293977ac1 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index c9286f55b..2cbdf83f0 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 8ea9d9df7..53b4622c7 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 813485e9b..89d1f290f 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 161e87a87..4f983ee3a 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index e39989fc8..47d3803ae 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 7c50c0138..d1a35e5be 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 421b7fab3..d52fdbc87 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 5d588a634..91ebd0ced 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 5ce154fa9..9a727b56e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index d94dd2b56..29af9c353 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3274--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 8ebb50f53..9d002b4ad 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -767,7 +767,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3274-develop + * secion v3.1.10.3282-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index e3802e1f5..950b84216 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3274-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3282-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From d654cccee281ac28c4c437fdf6be9e5aa8e96287 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 1 Dec 2019 14:01:29 +0000 Subject: [PATCH 005/887] Changed the target location for published documentation. Now it's published into main utplsql.gihub.io repository. --- .travis.yml | 6 +- ..._gh_pages.sh => push_docs_to_github_io.sh} | 62 +++++++++---------- .travis/update_project_version.sh | 2 + 3 files changed, 33 insertions(+), 37 deletions(-) rename .travis/{push_docs_to_gh_pages.sh => push_docs_to_github_io.sh} (67%) mode change 100755 => 100644 diff --git a/.travis.yml b/.travis.yml index b48adb107..7ac28e41f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -30,7 +30,6 @@ env: - CURRENT_BRANCH=${TRAVIS_BRANCH} - UTPLSQL_REPO="utPLSQL/utPLSQL" - UTPLSQL_BUILD_NO="${TRAVIS_BUILD_NUMBER:-0}" - - UTPLSQL_VERSION_PATTERN="v?([0-9]+\.){3}[0-9]+[^']*" - UTPLSQL_VERSION=$(. .travis/get_project_version.sh) - UTPLSQL_BUILD_VERSION=$(. .travis/get_project_build_version.sh) - UTPLSQL_SOURCES_DIR='source' @@ -115,16 +114,15 @@ jobs: - pip install mkdocs before_script: skip script: - - if [[ ($TRAVIS_BRANCH == develop) && ($TRAVIS_PULL_REQUEST == false) ]]; then bash .travis/trigger_travis.sh $TRAVIS_ACCESS_TOKEN; fi - - #The update_project_version.sh needs to be done before pushing changes to develop branch - bash .travis/update_project_version.sh - git config --global user.email "builds@travis-ci.com" - git config --global user.name "${UTPLSQL_BUILD_USER_NAME}" - git remote rm origin - git remote add origin https://${github_api_token}@github.com/${UTPLSQL_REPO} - if [[ ! $TRAVIS_TAG ]]; then bash .travis/push_release_version.sh; fi + - bash .travis/push_docs_to_github_io.sh - bash .travis/build_docs.sh - - bash .travis/push_docs_to_gh_pages.sh + - if [[ ($TRAVIS_BRANCH == develop) && ($TRAVIS_PULL_REQUEST == false) ]]; then bash .travis/trigger_travis.sh $TRAVIS_ACCESS_TOKEN; fi before_deploy: - bash .travis/build_release_archive.sh deploy: diff --git a/.travis/push_docs_to_gh_pages.sh b/.travis/push_docs_to_github_io.sh old mode 100755 new mode 100644 similarity index 67% rename from .travis/push_docs_to_gh_pages.sh rename to .travis/push_docs_to_github_io.sh index d2c5a685c..add63aa1b --- a/.travis/push_docs_to_gh_pages.sh +++ b/.travis/push_docs_to_github_io.sh @@ -1,6 +1,6 @@ #!/bin/bash -# Many aspects of this came from https://gist.github.com/domenic/ec8b0fc8ab45f39403dd +# Based on `push_docs_to_gh_pages.sh` # Significant alterations # - Support for multiple copies of documentation, # - only clearing out develop @@ -13,59 +13,55 @@ # - File: "docs/index.md" with that contains develop docs # Required ENV Variables -PAGES_TARGET_BRANCH="gh-pages" LATEST_DOCS_BRANCH="develop" +GITHUB_IO_REPO='jgebal/jgebal.github.io' +GITHUB_IO_BRANCH='master' + # TRAVIS_* variables are set by travis directly and only need to be if testing externally -# We don't want a pull request automatically updating the repository +# We deploy only when building on develop branch or on TAG (release) if [ "$TRAVIS_PULL_REQUEST" == "false" ] && { [ "${CURRENT_BRANCH}" == "${LATEST_DOCS_BRANCH}" ] || [ -n "${TRAVIS_TAG}" ]; }; then # ENV Variable checks are to help with configuration troubleshooting, they silently exit with unique message. # Anyone one of them not set can be used to turn off this functionality. # If a version of the project is not defined - [[ -n "${UTPLSQL_VERSION}" ]] || { echo "variable UTPLSQL_VERSION is not defines or missing value"; exit 0; } + [[ -n "${UTPLSQL_VERSION}" ]] || { echo "variable UTPLSQL_VERSION is not defines or missing value"; exit 1; } # Fail if the markdown documentation is not present. [[ -f ./docs/index.md ]] || { echo "file docs/index.md not found"; exit 1; } - # Save some useful information + # Store latest commit SHA to be used when committing and pushing to github.io repo SHA=`git rev-parse --verify HEAD` - # clone the repository and switch to PAGES_TARGET_BRANCH branch + # clone the repository and switch to GITHUB_IO_BRANCH branch mkdir pages - cd pages - git clone https://${github_api_token}@github.com/${UTPLSQL_REPO} . - - PAGES_BRANCH_EXISTS=$(git ls-remote --heads origin ${PAGES_TARGET_BRANCH}) + cd ./pages + git clone --depth 1 https://${github_api_token}@github.com/${GITHUB_IO_REPO} -b ${GITHUB_IO_BRANCH} . - if [ -n "$PAGES_BRANCH_EXISTS" ] ; then - echo "Pages Branch Found" - git checkout ${PAGES_TARGET_BRANCH} - else - echo "Creating Pages Branch" - git checkout --orphan ${PAGES_TARGET_BRANCH} - git rm -rf . - fi + mkdir -p utPLSQL + cd ./utPLSQL #clear out develop documentation directory and copy docs contents to it. - echo "updating 'develop' directory" - mkdir -p develop - rm -rf develop/**./* || exit 0 - cp -a ../docs/. ./develop + echo "updating 'develop' documentation directory" + mkdir -p ./develop + rm -rf ./develop/**./* || exit 0 + cp -a ../../docs/. ./develop + # If a Tagged Build then copy to it's own directory as well and to the 'latest' release directory if [ -n "$TRAVIS_TAG" ]; then - echo "Creating ${UTPLSQL_VERSION}" - mkdir -p ${UTPLSQL_VERSION} - rm -rf ${UTPLSQL_VERSION}/**./* || exit 0 - cp -a ../docs/. ${UTPLSQL_VERSION} - echo "Populating 'latest' directory" - mkdir -p latest - rm -rf latest/**./* || exit 0 - cp -a ../docs/. latest + echo "Creating directory ./${UTPLSQL_VERSION}" + mkdir -p ./${UTPLSQL_VERSION} + rm -rf ./${UTPLSQL_VERSION}/**./* || exit 0 + cp -a ../../docs/. ./${UTPLSQL_VERSION} + echo "Populating 'latest' directory" + mkdir -p ./latest + rm -rf ./latest/**./* || exit 0 + cp -a ../../docs/. ./latest fi # Stage changes for commit git add . + #Check if there are doc changes, if none exit the script - if [[ -z `git diff HEAD --exit-code` ]] && [ -n "${PAGES_BRANCH_EXISTS}" ] ; then + if [[ -z `git diff HEAD --exit-code` ]]; then echo "No changes to docs detected." exit 0 fi @@ -75,7 +71,7 @@ if [ "$TRAVIS_PULL_REQUEST" == "false" ] && { [ "${CURRENT_BRANCH}" == "${LATEST echo "---" >>index.md echo "layout: default" >>index.md echo "---" >>index.md - echo "" >>index.md + echo "" >>index.md echo "# Documentation versions" >>index.md echo "" >>index.md echo "" >>index.md #- 7th line - placeholder for latest release doc @@ -96,6 +92,6 @@ if [ "$TRAVIS_PULL_REQUEST" == "false" ] && { [ "${CURRENT_BRANCH}" == "${LATEST git add . git commit -m "Deploy to gh-pages branch: base commit ${SHA}" # Now that we're all set up, we can push. - git push --quiet origin HEAD:${PAGES_TARGET_BRANCH} + git push --quiet origin HEAD:${GITHUB_IO_BRANCH} fi diff --git a/.travis/update_project_version.sh b/.travis/update_project_version.sh index 3f162fb78..c4540eef8 100755 --- a/.travis/update_project_version.sh +++ b/.travis/update_project_version.sh @@ -1,5 +1,7 @@ #!/usr/bin/env bash +UTPLSQL_VERSION_PATTERN="v?([0-9]+\.){3}[0-9]+[^']*" + echo Current branch is "${CURRENT_BRANCH}" echo Update version in project source files From 090b74c083cdec6530e37958466277040157d34d Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 1 Dec 2019 14:12:54 +0000 Subject: [PATCH 006/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 439a68670..2ba4aff9a 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index e0c634bf8..33c552f78 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 31192f201..52c21c740 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 7a5f97899..e851d6ae5 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 56f7877ca..f17d3848c 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 634c51837..4f39ca713 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 293977ac1..db061005f 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 2cbdf83f0..ea7b3e50f 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 53b4622c7..95c1dadcf 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 89d1f290f..4f3375f85 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 4f983ee3a..c1995e1bc 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 47d3803ae..30fe6fcda 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index d1a35e5be..ba3f6735a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d52fdbc87..35455a6cd 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 91ebd0ced..21f36e1a4 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 9a727b56e..22cf5cb5e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 29af9c353..13135431c 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3282--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 9d002b4ad..0553f0343 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -767,7 +767,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3282-develop + * secion v3.1.10.3290-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 950b84216..79bcc5107 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3282-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3290-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From e8f453291b58f90bde2fbac6a6b8562757997905 Mon Sep 17 00:00:00 2001 From: pesse Date: Thu, 19 Dec 2019 15:38:07 +0100 Subject: [PATCH 007/887] Skip as many %endcontext as nested %context annotations We need to make sure to calculate the corrent %endcontext annotation, not just the first that is greater than the next nested %context. To operate correctly during recursion we also need information about the parent %endcontext position Fixes #1034 --- source/core/ut_suite_builder.pkb | 56 ++++++++++++++--- test/ut3_tester/core/test_suite_builder.pkb | 68 +++++++++++++++++++++ test/ut3_tester/core/test_suite_builder.pks | 5 ++ 3 files changed, 119 insertions(+), 10 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index c7e968467..f40d2f2a1 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -708,15 +708,49 @@ create or replace package body ut_suite_builder is a_context_ann_pos t_annotation_position, a_package_annotations in out nocopy tt_annotations_by_name ) return t_annotation_position is - l_result t_annotation_position; + l_next_endcontext_pos t_annotation_position; + l_next_context_pos t_annotation_position; + l_open_count integer := 0; begin if a_package_annotations.exists(gc_endcontext) then - l_result := a_package_annotations(gc_endcontext).first; - while l_result <= a_context_ann_pos loop - l_result := a_package_annotations(gc_endcontext).next(l_result); + l_next_endcontext_pos := a_package_annotations(gc_endcontext).first; + while l_next_endcontext_pos <= a_context_ann_pos loop + l_next_endcontext_pos := a_package_annotations(gc_endcontext).next(l_next_endcontext_pos); end loop; + + l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); + loop + -- Get all the %context annotations between start and first %endcontext + while l_next_context_pos is not null and l_next_context_pos < l_next_endcontext_pos loop + l_open_count := l_open_count+1; + l_next_context_pos := a_package_annotations(gc_context).next(l_next_context_pos); + end loop; + -- Skip as many %endcontexts as we had additional contexts open + while l_open_count > 0 loop + l_open_count := l_open_count-1; + l_next_endcontext_pos := a_package_annotations(gc_endcontext).next(l_next_endcontext_pos); + end loop; + -- Repeat until the next %context is later than next %endcontext + exit when l_next_context_pos is null or l_next_context_pos > l_next_endcontext_pos; + end loop; end if; - return l_result; + return l_next_endcontext_pos; + end; + + function has_nested_context( + a_context_ann_pos t_annotation_position, + a_package_annotations in out nocopy tt_annotations_by_name + ) return boolean is + l_next_endcontext_pos t_annotation_position; + begin + if ( a_package_annotations.exists(gc_endcontext) and a_package_annotations.exists(gc_context)) then + l_next_endcontext_pos := a_package_annotations(gc_endcontext).first; + while l_next_endcontext_pos <= a_context_ann_pos loop + l_next_endcontext_pos := a_package_annotations(gc_endcontext).next(l_next_endcontext_pos); + end loop; + return l_next_endcontext_pos > a_package_annotations(gc_context).next(a_context_ann_pos); + end if; + return false; end; function get_annotations_in_context( @@ -753,7 +787,8 @@ create or replace package body ut_suite_builder is a_parent in out nocopy ut_suite, a_annotations in out nocopy t_annotations_info, a_suite_items out nocopy ut_suite_items, - a_parent_context_pos in integer := 0 + a_parent_context_pos in integer := 0, + a_parent_end_context_pos in integer default null ) is l_context_pos t_annotation_position; l_next_context_pos t_annotation_position; @@ -802,7 +837,6 @@ create or replace package body ut_suite_builder is l_default_context_name := 'nested_context_#'||l_context_no; l_context_name := null; l_end_context_pos := get_endcontext_position(l_context_pos, a_annotations.by_name ); - l_next_context_pos := a_annotations.by_name(gc_context).next(l_context_pos); if a_annotations.by_name.exists(gc_name) then l_context_name := @@ -841,9 +875,8 @@ create or replace package body ut_suite_builder is l_context.parse_time := a_annotations.parse_time; --if nested context found - if l_next_context_pos < l_end_context_pos or l_end_context_pos is null then - get_context_items( l_context, a_annotations, l_context_items, l_context_pos ); - l_end_context_pos := get_endcontext_position(l_context_pos, a_annotations.by_name ); + if has_nested_context(l_context_pos, a_annotations.by_name) then + get_context_items( l_context, a_annotations, l_context_items, l_context_pos, l_end_context_pos ); else l_context_items := ut_suite_items(); end if; @@ -870,6 +903,9 @@ create or replace package body ut_suite_builder is exit when not a_annotations.by_name.exists( gc_context); l_context_pos := a_annotations.by_name( gc_context).next( l_context_pos); + if ( a_parent_end_context_pos is not null and a_parent_end_context_pos <= l_context_pos ) then + l_context_pos := null; + end if; l_context_no := l_context_no + 1; end loop; end; diff --git a/test/ut3_tester/core/test_suite_builder.pkb b/test/ut3_tester/core/test_suite_builder.pkb index a204a04e6..8250eb96e 100644 --- a/test/ut3_tester/core/test_suite_builder.pkb +++ b/test/ut3_tester/core/test_suite_builder.pkb @@ -767,6 +767,74 @@ create or replace package body test_suite_builder is ); end; + procedure nested_contexts_2 is + l_actual clob; + l_annotations ut3.ut_annotations; + begin + --Arrange + l_annotations := ut3.ut_annotations( + ut3.ut_annotation( 1, 'suite','Cool', null), + ut3.ut_annotation( 2, 'suitepath','path', null), + ut3.ut_annotation( 3, 'context','Level 1', null), + ut3.ut_annotation( 4, 'name','context_1', null), + ut3.ut_annotation( 5, 'context','Level 1.1', null), + ut3.ut_annotation( 6, 'name','context_1_1', null), + ut3.ut_annotation( 7, 'test', 'Test 1.1.1', 'test_1_1_1'), + ut3.ut_annotation( 8, 'test', 'Test 1.1.2', 'test_1_1_2'), + ut3.ut_annotation( 9, 'endcontext', null, null), + ut3.ut_annotation(10, 'endcontext', null, null), + ut3.ut_annotation(11, 'context','Level 2', null), + ut3.ut_annotation(12, 'name','context_2', null), + ut3.ut_annotation(13, 'test', 'Test 2.1', 'test_2_1'), + ut3.ut_annotation(14, 'endcontext',null, null) + ); + --Act + l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); + --Assert + ut.expect(l_actual).to_be_like( + ''|| + '' || + '%%' || + '' || + '%context_1Level 1path.some_package.context_1' || + '%' || + '' || + '%context_1_1Level 1.1path.some_package.context_1.context_1_1' || + '%' || + '' || + '%test_1_1_1Test 1.1.1path.some_package.context_1.context_1_1.test_1_1_1' || + '%' || + '' || + '%test_1_1_2Test 1.1.2path.some_package.context_1.context_1_1.test_1_1_2' || + '%' || + '' || + '%' || + '%' || + '' || + '%' || + '%' || + '%'|| + '' + ); + -- Test both contexts separately due to ordering + ut.expect(l_actual).to_be_like( + ''|| + '' || + '%%' || + '' || + '%context_2Level 2path.some_package.context_2' || + '%' || + '' || + '%test_2_1Test 2.1path.some_package.context_2.test_2_1' || + '%' || + '%' || + '%' || + '%' || + '%'|| + '' + ); + end; + procedure before_after_in_context is l_actual clob; diff --git a/test/ut3_tester/core/test_suite_builder.pks b/test/ut3_tester/core/test_suite_builder.pks index 7a85cb946..98a61171e 100644 --- a/test/ut3_tester/core/test_suite_builder.pks +++ b/test/ut3_tester/core/test_suite_builder.pks @@ -3,6 +3,7 @@ create or replace package test_suite_builder is --%suitepath(utplsql.ut3_tester.core) --%context(--%suite annotation) + --%name(suite) --%test(Sets suite name from package name and leaves description empty) procedure no_suite_description; @@ -105,6 +106,7 @@ create or replace package test_suite_builder is --%endcontext --%context(--%context annotation) + --%name(context) --%test(Creates nested suite for content between context/endcontext annotations) procedure suite_from_context; @@ -112,6 +114,9 @@ create or replace package test_suite_builder is --%test(Creates nested contexts inside a context) procedure nested_contexts; + --%test(Creates multiple nested contexts inside a context) + procedure nested_contexts_2; + --%test(Associates before/after all/each to tests in context only) procedure before_after_in_context; From 8df3f7d5d505f463d8ca5162e1bc608e0d8997b3 Mon Sep 17 00:00:00 2001 From: pesse Date: Thu, 19 Dec 2019 15:49:06 +0100 Subject: [PATCH 008/887] Refactoring: Extract function, add variables for readability --- source/core/ut_suite_builder.pkb | 36 ++++++++++++++++++++++---------- 1 file changed, 25 insertions(+), 11 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index f40d2f2a1..a4a1da7ee 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -704,6 +704,22 @@ create or replace package body ut_suite_builder is set_seq_no(a_suite.after_all_list); end; + function get_next_annotation_of_type( + a_start_position t_annotation_position, + a_annotation_type varchar2, + a_package_annotations in out nocopy tt_annotations_by_name + ) return t_annotation_position is + l_result t_annotation_position; + begin + if a_package_annotations.exists(a_annotation_type) then + l_result := a_package_annotations(a_annotation_type).first; + while l_result <= a_start_position loop + l_result := a_package_annotations(a_annotation_type).next(l_result); + end loop; + end if; + return l_result; + end; + function get_endcontext_position( a_context_ann_pos t_annotation_position, a_package_annotations in out nocopy tt_annotations_by_name @@ -712,13 +728,10 @@ create or replace package body ut_suite_builder is l_next_context_pos t_annotation_position; l_open_count integer := 0; begin - if a_package_annotations.exists(gc_endcontext) then - l_next_endcontext_pos := a_package_annotations(gc_endcontext).first; - while l_next_endcontext_pos <= a_context_ann_pos loop - l_next_endcontext_pos := a_package_annotations(gc_endcontext).next(l_next_endcontext_pos); - end loop; + if a_package_annotations.exists(gc_endcontext) and a_package_annotations.exists(gc_context) then + l_next_endcontext_pos := get_next_annotation_of_type(a_context_ann_pos, gc_endcontext, a_package_annotations); + l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); - l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); loop -- Get all the %context annotations between start and first %endcontext while l_next_context_pos is not null and l_next_context_pos < l_next_endcontext_pos loop @@ -742,13 +755,14 @@ create or replace package body ut_suite_builder is a_package_annotations in out nocopy tt_annotations_by_name ) return boolean is l_next_endcontext_pos t_annotation_position; + l_next_context_pos t_annotation_position; begin if ( a_package_annotations.exists(gc_endcontext) and a_package_annotations.exists(gc_context)) then - l_next_endcontext_pos := a_package_annotations(gc_endcontext).first; - while l_next_endcontext_pos <= a_context_ann_pos loop - l_next_endcontext_pos := a_package_annotations(gc_endcontext).next(l_next_endcontext_pos); - end loop; - return l_next_endcontext_pos > a_package_annotations(gc_context).next(a_context_ann_pos); + l_next_endcontext_pos := get_next_annotation_of_type(a_context_ann_pos, gc_endcontext, a_package_annotations); + l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); + if ( l_next_context_pos < l_next_endcontext_pos ) then + return true; + end if; end if; return false; end; From a4d92dea60e98246ec21db6bbc0dfa9a3fa46971 Mon Sep 17 00:00:00 2001 From: pesse Date: Thu, 19 Dec 2019 15:51:12 +0100 Subject: [PATCH 009/887] Refactoring: Add clarifying comment --- source/core/ut_suite_builder.pkb | 1 + 1 file changed, 1 insertion(+) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index a4a1da7ee..810da27ab 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -917,6 +917,7 @@ create or replace package body ut_suite_builder is exit when not a_annotations.by_name.exists( gc_context); l_context_pos := a_annotations.by_name( gc_context).next( l_context_pos); + -- don't go on when the next context is outside the parent's context boundaries if ( a_parent_end_context_pos is not null and a_parent_end_context_pos <= l_context_pos ) then l_context_pos := null; end if; From 4d1500f9ac2c89aed17471bddf871ecdaceb200f Mon Sep 17 00:00:00 2001 From: pesse Date: Thu, 19 Dec 2019 21:04:21 +0100 Subject: [PATCH 010/887] Refactoring: Move responsibility to get context name completely to get_context_name --- source/core/ut_suite_builder.pkb | 53 ++++++++++++++++---------------- 1 file changed, 26 insertions(+), 27 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 810da27ab..d013c107e 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -817,26 +817,35 @@ create or replace package body ut_suite_builder is l_default_context_name t_object_name; function get_context_name( a_parent in out nocopy ut_suite, - a_context_names in tt_annotation_texts, - a_start_position binary_integer, - a_end_position binary_integer + a_start_position binary_integer ) return varchar2 is l_result t_annotation_name; l_found boolean; + l_end_position binary_integer; l_annotation_pos binary_integer; + l_context_names tt_annotation_texts; begin - l_annotation_pos := a_context_names.first; - while l_annotation_pos is not null loop - if l_annotation_pos > a_start_position and l_annotation_pos < a_end_position then - if l_found then - add_annotation_ignored_warning(a_parent, gc_name,'Duplicate annotation %%%.', l_annotation_pos); - else - l_result := a_context_names(l_annotation_pos); - end if; - l_found := true; - end if; - l_annotation_pos := a_context_names.next(l_annotation_pos); - end loop; + if a_annotations.by_name.exists(gc_name) then + l_context_names := a_annotations.by_name( gc_name ); + l_end_position := + least( + coalesce( get_endcontext_position(a_start_position, a_annotations.by_name), a_annotations.by_line.last ), + coalesce( a_annotations.by_name(gc_context).next(a_start_position), a_annotations.by_line.last ) + ); + l_annotation_pos := l_context_names.first; + + while l_annotation_pos is not null loop + if l_annotation_pos > a_start_position and l_annotation_pos < l_end_position then + if l_found then + add_annotation_ignored_warning(a_parent, gc_name,'Duplicate annotation %%%.', l_annotation_pos); + else + l_result := l_context_names(l_annotation_pos); + end if; + l_found := true; + end if; + l_annotation_pos := l_context_names.next(l_annotation_pos); + end loop; + end if; return l_result; end; begin @@ -852,18 +861,8 @@ create or replace package body ut_suite_builder is l_context_name := null; l_end_context_pos := get_endcontext_position(l_context_pos, a_annotations.by_name ); l_next_context_pos := a_annotations.by_name(gc_context).next(l_context_pos); - if a_annotations.by_name.exists(gc_name) then - l_context_name := - get_context_name( - a_parent, - a_annotations.by_name( gc_name ), - l_context_pos, - least( - coalesce( l_end_context_pos, a_annotations.by_line.last ), - coalesce( l_next_context_pos, a_annotations.by_line.last ) - ) - ); - end if; + l_context_name := get_context_name(a_parent, l_context_pos); + if not regexp_like( l_context_name, '^(\w|[$#])+$' ) or l_context_name is null then if not regexp_like( l_context_name, '^(\w|[$#])+$' ) then a_parent.put_warning( From 3c547ecd57d96101b81ca21e70003500e80a99b8 Mon Sep 17 00:00:00 2001 From: pesse Date: Fri, 20 Dec 2019 08:22:23 +0100 Subject: [PATCH 011/887] Fix intendation --- source/core/ut_suite_builder.pkb | 76 ++++++++++++++++---------------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index d013c107e..0c0730c4b 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -15,7 +15,7 @@ create or replace package body ut_suite_builder is See the License for the specific language governing permissions and limitations under the License. */ - + subtype t_annotation_text is varchar2(4000); subtype t_annotation_name is varchar2(4000); subtype t_object_name is varchar2(500); @@ -315,13 +315,13 @@ create or replace package body ut_suite_builder is l_annotation_pos := a_throws_ann_text.next(l_annotation_pos); end loop; end; - + procedure add_tags_to_suite_item( a_suite in out nocopy ut_suite, a_tags_ann_text tt_annotation_texts, a_list in out nocopy ut_varchar2_rows, a_procedure_name t_object_name := null - ) is + ) is l_annotation_pos binary_integer; l_tags_list ut_varchar2_list := ut_varchar2_list(); l_tag_items ut_varchar2_list; @@ -354,7 +354,7 @@ create or replace package body ut_suite_builder is --remove empty strings from table list e.g. tag1,,tag2 and convert to rows a_list := ut_utils.convert_collection( ut_utils.filter_list(set(l_tags_list),ut_utils.gc_word_no_space) ); end; - + procedure set_seq_no( a_list in out nocopy ut_executables ) is @@ -533,16 +533,16 @@ create or replace package body ut_suite_builder is ); set_seq_no(l_test.after_test_list); end if; - + if l_proc_annotations.exists( gc_tags) then add_tags_to_suite_item(a_suite, l_proc_annotations( gc_tags), l_test.tags, a_procedure_name); end if; - + if l_proc_annotations.exists( gc_throws) then add_to_throws_numbers_list(a_suite, l_test.expected_error_codes, a_procedure_name, l_proc_annotations( gc_throws)); end if; l_test.disabled_flag := ut_utils.boolean_to_int( l_proc_annotations.exists( gc_disabled)); - + a_suite_items.extend; a_suite_items( a_suite_items.last ) := l_test; @@ -687,7 +687,7 @@ create or replace package body ut_suite_builder is if a_annotations.by_name.exists(gc_aftereach) then l_after_each_list := add_executables( a_suite.object_owner, a_suite.object_name, a_annotations.by_name(gc_aftereach), gc_aftereach ); end if; - + if a_annotations.by_name.exists(gc_tags) then add_tags_to_suite_item(a_suite, a_annotations.by_name(gc_tags),a_suite.tags); end if; @@ -730,22 +730,22 @@ create or replace package body ut_suite_builder is begin if a_package_annotations.exists(gc_endcontext) and a_package_annotations.exists(gc_context) then l_next_endcontext_pos := get_next_annotation_of_type(a_context_ann_pos, gc_endcontext, a_package_annotations); - l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); + l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); loop - -- Get all the %context annotations between start and first %endcontext + -- Get all the %context annotations between start and first %endcontext while l_next_context_pos is not null and l_next_context_pos < l_next_endcontext_pos loop - l_open_count := l_open_count+1; - l_next_context_pos := a_package_annotations(gc_context).next(l_next_context_pos); - end loop; - -- Skip as many %endcontexts as we had additional contexts open - while l_open_count > 0 loop - l_open_count := l_open_count-1; - l_next_endcontext_pos := a_package_annotations(gc_endcontext).next(l_next_endcontext_pos); - end loop; - -- Repeat until the next %context is later than next %endcontext - exit when l_next_context_pos is null or l_next_context_pos > l_next_endcontext_pos; - end loop; + l_open_count := l_open_count+1; + l_next_context_pos := a_package_annotations(gc_context).next(l_next_context_pos); + end loop; + -- Skip as many %endcontexts as we had additional contexts open + while l_open_count > 0 loop + l_open_count := l_open_count-1; + l_next_endcontext_pos := a_package_annotations(gc_endcontext).next(l_next_endcontext_pos); + end loop; + -- Repeat until the next %context is later than next %endcontext + exit when l_next_context_pos is null or l_next_context_pos > l_next_endcontext_pos; + end loop; end if; return l_next_endcontext_pos; end; @@ -758,11 +758,11 @@ create or replace package body ut_suite_builder is l_next_context_pos t_annotation_position; begin if ( a_package_annotations.exists(gc_endcontext) and a_package_annotations.exists(gc_context)) then - l_next_endcontext_pos := get_next_annotation_of_type(a_context_ann_pos, gc_endcontext, a_package_annotations); - l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); - if ( l_next_context_pos < l_next_endcontext_pos ) then - return true; - end if; + l_next_endcontext_pos := get_next_annotation_of_type(a_context_ann_pos, gc_endcontext, a_package_annotations); + l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); + if ( l_next_context_pos < l_next_endcontext_pos ) then + return true; + end if; end if; return false; end; @@ -834,17 +834,17 @@ create or replace package body ut_suite_builder is ); l_annotation_pos := l_context_names.first; - while l_annotation_pos is not null loop - if l_annotation_pos > a_start_position and l_annotation_pos < l_end_position then - if l_found then - add_annotation_ignored_warning(a_parent, gc_name,'Duplicate annotation %%%.', l_annotation_pos); - else - l_result := l_context_names(l_annotation_pos); - end if; - l_found := true; - end if; - l_annotation_pos := l_context_names.next(l_annotation_pos); - end loop; + while l_annotation_pos is not null loop + if l_annotation_pos > a_start_position and l_annotation_pos < l_end_position then + if l_found then + add_annotation_ignored_warning(a_parent, gc_name,'Duplicate annotation %%%.', l_annotation_pos); + else + l_result := l_context_names(l_annotation_pos); + end if; + l_found := true; + end if; + l_annotation_pos := l_context_names.next(l_annotation_pos); + end loop; end if; return l_result; end; @@ -918,7 +918,7 @@ create or replace package body ut_suite_builder is l_context_pos := a_annotations.by_name( gc_context).next( l_context_pos); -- don't go on when the next context is outside the parent's context boundaries if ( a_parent_end_context_pos is not null and a_parent_end_context_pos <= l_context_pos ) then - l_context_pos := null; + l_context_pos := null; end if; l_context_no := l_context_no + 1; end loop; From b4c1d7235481048da76c1d8d937e0c5129c67375 Mon Sep 17 00:00:00 2001 From: pesse Date: Fri, 20 Dec 2019 08:25:27 +0100 Subject: [PATCH 012/887] Refactoring: Use just one return to improve readability --- source/core/ut_suite_builder.pkb | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 0c0730c4b..32c12c7e5 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -754,17 +754,14 @@ create or replace package body ut_suite_builder is a_context_ann_pos t_annotation_position, a_package_annotations in out nocopy tt_annotations_by_name ) return boolean is - l_next_endcontext_pos t_annotation_position; - l_next_context_pos t_annotation_position; + l_next_endcontext_pos t_annotation_position := 0; + l_next_context_pos t_annotation_position := 0; begin if ( a_package_annotations.exists(gc_endcontext) and a_package_annotations.exists(gc_context)) then l_next_endcontext_pos := get_next_annotation_of_type(a_context_ann_pos, gc_endcontext, a_package_annotations); l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); - if ( l_next_context_pos < l_next_endcontext_pos ) then - return true; - end if; end if; - return false; + return ( l_next_context_pos < l_next_endcontext_pos ); end; function get_annotations_in_context( From 86185a87599e71f65d27c4bba10848b74fc01937 Mon Sep 17 00:00:00 2001 From: pesse Date: Fri, 20 Dec 2019 09:02:34 +0100 Subject: [PATCH 013/887] Rewrite get_endcontext_position to be much easier to understand Using simple parenthesis counter and annotations_by_line --- source/core/ut_suite_builder.pkb | 44 +++++++++++++------------------- 1 file changed, 18 insertions(+), 26 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 32c12c7e5..0b00801b8 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -722,32 +722,25 @@ create or replace package body ut_suite_builder is function get_endcontext_position( a_context_ann_pos t_annotation_position, - a_package_annotations in out nocopy tt_annotations_by_name + a_package_annotations in tt_annotations_by_line ) return t_annotation_position is - l_next_endcontext_pos t_annotation_position; - l_next_context_pos t_annotation_position; - l_open_count integer := 0; + l_result t_annotation_position; + l_open_count integer := 1; + l_idx t_annotation_position := a_package_annotations.next(a_context_ann_pos); begin - if a_package_annotations.exists(gc_endcontext) and a_package_annotations.exists(gc_context) then - l_next_endcontext_pos := get_next_annotation_of_type(a_context_ann_pos, gc_endcontext, a_package_annotations); - l_next_context_pos := a_package_annotations(gc_context).next(a_context_ann_pos); - - loop - -- Get all the %context annotations between start and first %endcontext - while l_next_context_pos is not null and l_next_context_pos < l_next_endcontext_pos loop - l_open_count := l_open_count+1; - l_next_context_pos := a_package_annotations(gc_context).next(l_next_context_pos); - end loop; - -- Skip as many %endcontexts as we had additional contexts open - while l_open_count > 0 loop - l_open_count := l_open_count-1; - l_next_endcontext_pos := a_package_annotations(gc_endcontext).next(l_next_endcontext_pos); - end loop; - -- Repeat until the next %context is later than next %endcontext - exit when l_next_context_pos is null or l_next_context_pos > l_next_endcontext_pos; - end loop; + while l_open_count > 0 and l_idx is not null loop + if ( a_package_annotations(l_idx).name = gc_context ) then + l_open_count := l_open_count+1; + elsif ( a_package_annotations(l_idx).name = gc_endcontext ) then + l_open_count := l_open_count-1; + l_result := l_idx; + end if; + l_idx := a_package_annotations.next(l_idx); + end loop; + if ( l_open_count > 0 ) then + l_result := null; end if; - return l_next_endcontext_pos; + return l_result; end; function has_nested_context( @@ -826,7 +819,7 @@ create or replace package body ut_suite_builder is l_context_names := a_annotations.by_name( gc_name ); l_end_position := least( - coalesce( get_endcontext_position(a_start_position, a_annotations.by_name), a_annotations.by_line.last ), + coalesce( get_endcontext_position(a_start_position, a_annotations.by_line), a_annotations.by_line.last ), coalesce( a_annotations.by_name(gc_context).next(a_start_position), a_annotations.by_line.last ) ); l_annotation_pos := l_context_names.first; @@ -856,10 +849,9 @@ create or replace package body ut_suite_builder is while l_context_pos is not null loop l_default_context_name := 'nested_context_#'||l_context_no; l_context_name := null; - l_end_context_pos := get_endcontext_position(l_context_pos, a_annotations.by_name ); + l_end_context_pos := get_endcontext_position(l_context_pos, a_annotations.by_line ); l_next_context_pos := a_annotations.by_name(gc_context).next(l_context_pos); l_context_name := get_context_name(a_parent, l_context_pos); - if not regexp_like( l_context_name, '^(\w|[$#])+$' ) or l_context_name is null then if not regexp_like( l_context_name, '^(\w|[$#])+$' ) then a_parent.put_warning( From 89df1ddbda8f1521c58483672315b0e41d1eb6dc Mon Sep 17 00:00:00 2001 From: pesse Date: Fri, 20 Dec 2019 09:09:31 +0100 Subject: [PATCH 014/887] Clarify intention of end-position, make it more visible how it's defined --- source/core/ut_suite_builder.pkb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 0b00801b8..0b4551765 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -817,10 +817,11 @@ create or replace package body ut_suite_builder is begin if a_annotations.by_name.exists(gc_name) then l_context_names := a_annotations.by_name( gc_name ); + -- Maximum end-position to look for %name annotation is either the next %context or the next %endcontext annotation l_end_position := least( - coalesce( get_endcontext_position(a_start_position, a_annotations.by_line), a_annotations.by_line.last ), - coalesce( a_annotations.by_name(gc_context).next(a_start_position), a_annotations.by_line.last ) + coalesce( get_next_annotation_of_type(a_start_position, gc_endcontext, a_annotations.by_name), a_annotations.by_line.last ), + coalesce( get_next_annotation_of_type(a_start_position, gc_context, a_annotations.by_name), a_annotations.by_line.last ) ); l_annotation_pos := l_context_names.first; From c61abfaed5ce0e6d1d95596400486660f49abfc7 Mon Sep 17 00:00:00 2001 From: pesse Date: Fri, 20 Dec 2019 09:12:55 +0100 Subject: [PATCH 015/887] Get rid of several `in out nocopy` params where `in` would be sufficient --- source/core/ut_suite_builder.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 0b4551765..a44e73919 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -707,7 +707,7 @@ create or replace package body ut_suite_builder is function get_next_annotation_of_type( a_start_position t_annotation_position, a_annotation_type varchar2, - a_package_annotations in out nocopy tt_annotations_by_name + a_package_annotations in tt_annotations_by_name ) return t_annotation_position is l_result t_annotation_position; begin @@ -745,7 +745,7 @@ create or replace package body ut_suite_builder is function has_nested_context( a_context_ann_pos t_annotation_position, - a_package_annotations in out nocopy tt_annotations_by_name + a_package_annotations in tt_annotations_by_name ) return boolean is l_next_endcontext_pos t_annotation_position := 0; l_next_context_pos t_annotation_position := 0; From 35acf1438280a5714c26929b4ea17c6132c81e0d Mon Sep 17 00:00:00 2001 From: pesse Date: Fri, 20 Dec 2019 09:15:33 +0100 Subject: [PATCH 016/887] Not necessary to check for IS NOT NULL --- source/core/ut_suite_builder.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index a44e73919..5f468f756 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -907,7 +907,7 @@ create or replace package body ut_suite_builder is l_context_pos := a_annotations.by_name( gc_context).next( l_context_pos); -- don't go on when the next context is outside the parent's context boundaries - if ( a_parent_end_context_pos is not null and a_parent_end_context_pos <= l_context_pos ) then + if (a_parent_end_context_pos <= l_context_pos ) then l_context_pos := null; end if; l_context_no := l_context_no + 1; From 3327fc371f8a5f3b5be9baea1745fce2dbd8b08d Mon Sep 17 00:00:00 2001 From: pesse Date: Fri, 20 Dec 2019 09:55:20 +0100 Subject: [PATCH 017/887] Fix intendation --- test/ut3_tester/core/test_suite_builder.pkb | 2 +- test/ut3_tester/core/test_suite_builder.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/ut3_tester/core/test_suite_builder.pkb b/test/ut3_tester/core/test_suite_builder.pkb index 8250eb96e..86d86032a 100644 --- a/test/ut3_tester/core/test_suite_builder.pkb +++ b/test/ut3_tester/core/test_suite_builder.pkb @@ -767,7 +767,7 @@ create or replace package body test_suite_builder is ); end; - procedure nested_contexts_2 is + procedure nested_contexts_2 is l_actual clob; l_annotations ut3.ut_annotations; begin diff --git a/test/ut3_tester/core/test_suite_builder.pks b/test/ut3_tester/core/test_suite_builder.pks index 98a61171e..7c7fc77f6 100644 --- a/test/ut3_tester/core/test_suite_builder.pks +++ b/test/ut3_tester/core/test_suite_builder.pks @@ -106,7 +106,7 @@ create or replace package test_suite_builder is --%endcontext --%context(--%context annotation) - --%name(context) + --%name(context) --%test(Creates nested suite for content between context/endcontext annotations) procedure suite_from_context; From cef109b90206705f16a897688056f7185cfc0c03 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Fri, 20 Dec 2019 20:28:20 +0000 Subject: [PATCH 018/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 2ba4aff9a..f607f7562 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 33c552f78..adfd52a46 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 52c21c740..971e9462e 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index e851d6ae5..82c0ce2af 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index f17d3848c..23f63009b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 4f39ca713..16ec10576 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index db061005f..a62afed04 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index ea7b3e50f..b5f8a37cd 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 95c1dadcf..c12ec9e73 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 4f3375f85..e5f816f15 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c1995e1bc..24e0f8f9d 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 30fe6fcda..14a440173 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ba3f6735a..39baf4a18 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 35455a6cd..66e69d48b 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 21f36e1a4..bfe4523a9 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 22cf5cb5e..4b6e83db4 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 13135431c..53d30e474 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3290--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 0553f0343..33ab46b38 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -767,7 +767,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3290-develop + * secion v3.1.10.3297-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 79bcc5107..9da213a3b 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3290-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3297-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ad0f99d9fd2cc34383eabd284e7d8006d4aec286 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 22 Dec 2019 15:27:47 +0000 Subject: [PATCH 019/887] Fixed repo for publishing github docs. --- .travis/push_docs_to_github_io.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis/push_docs_to_github_io.sh b/.travis/push_docs_to_github_io.sh index add63aa1b..e29f1c88c 100644 --- a/.travis/push_docs_to_github_io.sh +++ b/.travis/push_docs_to_github_io.sh @@ -14,7 +14,7 @@ # Required ENV Variables LATEST_DOCS_BRANCH="develop" -GITHUB_IO_REPO='jgebal/jgebal.github.io' +GITHUB_IO_REPO='utPLSQL/utPLSQL.github.io' GITHUB_IO_BRANCH='master' # TRAVIS_* variables are set by travis directly and only need to be if testing externally From 33f5152e99e4cbcc6150d3a86e606f3156db6029 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 22 Dec 2019 15:37:53 +0000 Subject: [PATCH 020/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index f607f7562..205fbef66 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index adfd52a46..923dd5b7d 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 971e9462e..260e05ede 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 82c0ce2af..6ff3b41be 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 23f63009b..fc2718b3f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 16ec10576..184866b7b 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index a62afed04..12ccc8a30 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b5f8a37cd..0f0682924 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index c12ec9e73..4853bfca1 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e5f816f15..ba4313743 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 24e0f8f9d..612b59444 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 14a440173..31988dcfe 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 39baf4a18..6de351376 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 66e69d48b..346de3cb9 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index bfe4523a9..7a8f10af6 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 4b6e83db4..7babf9366 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 53d30e474..cd6e8b065 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3297--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 33ab46b38..096761d0a 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -767,7 +767,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3297-develop + * secion v3.1.10.3298-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 9da213a3b..671312a9f 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3297-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3298-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 8e43a089a67e26d951a929b5f285065938b10c3c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 29 Dec 2019 15:53:09 +0000 Subject: [PATCH 021/887] Moved validation of `--%throws` annotation values. Now the validation is executed at runtime, when the tests is executed. This resolves issues related to the fact that some package constants may not exist or be valid at suite parse time. In such scenario, the annotations continued to be ignored despite the fact that package constants were valid at test runtime. With this change, tests can now have `--throws` annotations referencing constants that are undefined at compile time. Resolves #1033 --- source/core/types/ut_executable_test.tpb | 114 ++++- source/core/types/ut_executable_test.tps | 4 +- source/core/types/ut_suite_cache_row.tps | 2 +- source/core/types/ut_suite_item.tpb | 10 + source/core/types/ut_suite_item.tps | 3 +- source/core/types/ut_test.tpb | 2 +- source/core/types/ut_test.tps | 4 +- source/core/ut_suite_builder.pkb | 178 +------- source/core/ut_suite_cache_manager.pkb | 2 +- .../test_annot_throws_exception.pkb | 430 ++++++++++-------- .../test_annot_throws_exception.pks | 8 +- test/ut3_tester/core/test_suite_builder.pkb | 18 - test/ut3_tester/core/test_suite_builder.pks | 3 - 13 files changed, 390 insertions(+), 388 deletions(-) diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index a11797a54..89ab16dab 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -31,7 +31,7 @@ create or replace type body ut_executable_test as member procedure do_execute( self in out nocopy ut_executable_test, a_item in out nocopy ut_suite_item, - a_expected_error_codes in ut_integer_list + a_expected_error_codes in ut_varchar2_rows ) is l_completed_without_errors boolean; begin @@ -40,10 +40,114 @@ create or replace type body ut_executable_test as member function do_execute( self in out nocopy ut_executable_test, a_item in out nocopy ut_suite_item, - a_expected_error_codes in ut_integer_list + a_expected_error_codes in ut_varchar2_rows ) return boolean is l_expected_except_message varchar2(4000); + l_expected_error_numbers ut_integer_list; + function build_exception_numbers_list( + a_item in out nocopy ut_suite_item, + a_expected_error_codes in ut_varchar2_rows + ) return ut_integer_list is + l_exception_number integer; + l_exception_number_list ut_integer_list := ut_integer_list(); + c_regexp_for_exception_no constant varchar2(30) := '^-?[[:digit:]]{1,5}$'; + + c_integer_exception constant varchar2(1) := 'I'; + c_named_exception constant varchar2(1) := 'N'; + + function is_valid_qualified_name (a_name varchar2) return boolean is + l_name varchar2(500); + begin + l_name := dbms_assert.qualified_sql_name(a_name); + return true; + exception when others then + return false; + end; + + function check_exception_type(a_exception_name in varchar2) return varchar2 is + l_exception_type varchar2(50); + begin + --check if it is a predefined exception + begin + execute immediate 'begin null; exception when '||a_exception_name||' then null; end;'; + l_exception_type := c_named_exception; + exception + when others then + if dbms_utility.format_error_stack() like '%PLS-00485%' then + declare + e_invalid_number exception; + pragma exception_init ( e_invalid_number, -6502 ); + begin + execute immediate 'declare x integer := '||a_exception_name||'; begin null; end;'; + l_exception_type := c_integer_exception; + exception + when others then + null; + end; + end if; + end; + return l_exception_type; + end; + + function get_exception_number (a_exception_var in varchar2) return integer is + l_exc_no integer; + l_exc_type varchar2(50); + function remap_no_data_found (a_number integer) return integer is + begin + return case a_number when 100 then -1403 else a_number end; + end; + begin + l_exc_type := check_exception_type(a_exception_var); + + execute immediate + case l_exc_type + when c_integer_exception then + 'declare l_exception number; begin :l_exception := '||a_exception_var||'; end;' + when c_named_exception then + 'begin raise '||a_exception_var||'; exception when others then :l_exception := sqlcode; end;' + else + 'begin :l_exception := null; end;' + end + using out l_exc_no; + + return remap_no_data_found(l_exc_no); + end; + + begin + if a_expected_error_codes is not empty then + for i in 1 .. a_expected_error_codes.count loop + /** + * Check if its a valid qualified name and if so try to resolve name to an exception number + */ + if is_valid_qualified_name(a_expected_error_codes(i)) then + l_exception_number := get_exception_number(a_expected_error_codes(i)); + elsif regexp_like(a_expected_error_codes(i), c_regexp_for_exception_no) then + l_exception_number := a_expected_error_codes(i); + end if; + + if l_exception_number is null then + a_item.put_warning( + 'Invalid parameter value "'||a_expected_error_codes(i)||'" for "--%throws" annotation. Parameter ignored.', + self.procedure_name, + a_item.line_no + ); + elsif l_exception_number >= 0 then + a_item.put_warning( + 'Invalid parameter value "'||a_expected_error_codes(i)||'" for "--%throws" annotation. Exception value must be a negative integer. Parameter ignored.', + self.procedure_name, + a_item.line_no + ); + else + l_exception_number_list.extend; + l_exception_number_list(l_exception_number_list.last) := l_exception_number; + end if; + l_exception_number := null; + end loop; + end if; + + return l_exception_number_list; + end; function failed_expec_errnum_message(a_expected_error_codes in ut_integer_list) return varchar is l_actual_error_no integer; l_expected_error_codes varchar2(4000); @@ -72,9 +176,9 @@ create or replace type body ut_executable_test as begin --Create a ut_executable object and call do_execute after that get the data to know the test's execution result self.do_execute(a_item); - - if a_expected_error_codes is not null and a_expected_error_codes is not empty then - l_expected_except_message := failed_expec_errnum_message(a_expected_error_codes); + l_expected_error_numbers := build_exception_numbers_list(a_item, a_expected_error_codes); + if l_expected_error_numbers is not null and l_expected_error_numbers is not empty then + l_expected_except_message := failed_expec_errnum_message( l_expected_error_numbers ); if l_expected_except_message is not null then ut_expectation_processor.add_expectation_result( diff --git a/source/core/types/ut_executable_test.tps b/source/core/types/ut_executable_test.tps index 2772720de..88500c9be 100644 --- a/source/core/types/ut_executable_test.tps +++ b/source/core/types/ut_executable_test.tps @@ -22,12 +22,12 @@ create or replace type ut_executable_test authid current_user under ut_executabl member procedure do_execute( self in out nocopy ut_executable_test, a_item in out nocopy ut_suite_item, - a_expected_error_codes in ut_integer_list + a_expected_error_codes in ut_varchar2_rows ), member function do_execute( self in out nocopy ut_executable_test, a_item in out nocopy ut_suite_item, - a_expected_error_codes in ut_integer_list + a_expected_error_codes in ut_varchar2_rows ) return boolean ) final; diff --git a/source/core/types/ut_suite_cache_row.tps b/source/core/types/ut_suite_cache_row.tps index 6817be5ec..fb4a8bb9f 100644 --- a/source/core/types/ut_suite_cache_row.tps +++ b/source/core/types/ut_suite_cache_row.tps @@ -33,7 +33,7 @@ create type ut_suite_cache_row as object ( before_test_list ut_executables, after_each_list ut_executables, after_test_list ut_executables, - expected_error_codes ut_integer_list, + expected_error_codes ut_varchar2_rows, tags ut_varchar2_rows, item ut_executable_test ) diff --git a/source/core/types/ut_suite_item.tpb b/source/core/types/ut_suite_item.tpb index 6478d5c82..9b939727a 100644 --- a/source/core/types/ut_suite_item.tpb +++ b/source/core/types/ut_suite_item.tpb @@ -97,6 +97,16 @@ create or replace type body ut_suite_item as self.results_count.increase_warning_count; end; + member procedure put_warning(self in out nocopy ut_suite_item, a_message varchar2, a_procedure_name varchar2, a_line_no integer) is + l_result varchar2(1000); + begin + l_result := self.object_owner || '.' || self.object_name ; + if a_procedure_name is not null then + l_result := l_result || '.' || a_procedure_name ; + end if; + put_warning( a_message || chr( 10 ) || 'at package "' || upper(l_result) || '", line ' || a_line_no ); + end; + member function get_transaction_invalidators return ut_varchar2_list is begin return transaction_invalidators; diff --git a/source/core/types/ut_suite_item.tps b/source/core/types/ut_suite_item.tps index 53c59a2ea..87f577459 100644 --- a/source/core/types/ut_suite_item.tps +++ b/source/core/types/ut_suite_item.tps @@ -84,7 +84,8 @@ create or replace type ut_suite_item force under ut_event_item ( not instantiable member procedure mark_as_errored(self in out nocopy ut_suite_item, a_error_stack_trace varchar2), not instantiable member function get_error_stack_traces return ut_varchar2_list, not instantiable member function get_serveroutputs return clob, - member procedure put_warning(self in out nocopy ut_suite_item, a_message varchar2) + member procedure put_warning(self in out nocopy ut_suite_item, a_message varchar2), + member procedure put_warning(self in out nocopy ut_suite_item, a_message varchar2, a_procedure_name varchar2, a_line_no integer) ) not final not instantiable / diff --git a/source/core/types/ut_test.tpb b/source/core/types/ut_test.tpb index 9fbcf9269..4ed3f665e 100644 --- a/source/core/types/ut_test.tpb +++ b/source/core/types/ut_test.tpb @@ -18,7 +18,7 @@ create or replace type body ut_test as constructor function ut_test( self in out nocopy ut_test, a_object_owner varchar2 := null, a_object_name varchar2, a_name varchar2, - a_line_no integer, a_expected_error_codes ut_integer_list := null, a_tags ut_varchar2_rows := null + a_line_no integer, a_expected_error_codes ut_varchar2_rows := null, a_tags ut_varchar2_rows := null ) return self as result is begin self.self_type := $$plsql_unit; diff --git a/source/core/types/ut_test.tps b/source/core/types/ut_test.tps index fcf565671..85caf7380 100644 --- a/source/core/types/ut_test.tps +++ b/source/core/types/ut_test.tps @@ -54,10 +54,10 @@ create or replace type ut_test force under ut_suite_item ( /** *Holds the expected error codes list when the user use the annotation throws */ - expected_error_codes ut_integer_list, + expected_error_codes ut_varchar2_rows, constructor function ut_test( self in out nocopy ut_test, a_object_owner varchar2 := null, a_object_name varchar2, a_name varchar2, - a_line_no integer, a_expected_error_codes ut_integer_list := null, a_tags ut_varchar2_rows := null + a_line_no integer, a_expected_error_codes ut_varchar2_rows := null, a_tags ut_varchar2_rows := null ) return self as result, overriding member procedure mark_as_skipped(self in out nocopy ut_test), overriding member function do_execute(self in out nocopy ut_test) return boolean, diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 5f468f756..d13cbaed9 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -62,9 +62,6 @@ create or replace package body ut_suite_builder is gc_endcontext ); - gc_integer_exception constant varchar2(1) := 'I'; - gc_named_exception constant varchar2(1) := 'N'; - type tt_executables is table of ut_executables index by t_annotation_position; type t_annotation is record( @@ -97,27 +94,6 @@ create or replace package body ut_suite_builder is by_name tt_annotations_by_name ); - function get_qualified_object_name( - a_suite ut_suite_item, a_procedure_name t_object_name - ) return varchar2 is - l_result varchar2(1000); - begin - if a_suite is not null then - l_result := upper( a_suite.object_owner || '.' || a_suite.object_name ); - if a_procedure_name is not null then - l_result := l_result || upper( '.' || a_procedure_name ); - end if; - end if; - return l_result; - end; - - function get_object_reference( - a_suite ut_suite_item, a_procedure_name t_object_name, a_line_no binary_integer - ) return varchar2 is - begin - return chr( 10 ) || 'at package "' || get_qualified_object_name(a_suite, a_procedure_name) || '", line ' || a_line_no; - end; - procedure delete_annotations_range( a_annotations in out nocopy t_annotations_info, a_start_pos t_annotation_position, @@ -163,8 +139,9 @@ create or replace package body ut_suite_builder is ) is begin a_suite.put_warning( - replace(a_message,'%%%','"--%'||a_annotation||'"') - || ' Annotation ignored.' || get_object_reference( a_suite, a_procedure_name, a_line_no ) + replace(a_message,'%%%','"--%'||a_annotation||'"')|| ' Annotation ignored.', + a_procedure_name, + a_line_no ); end; @@ -181,136 +158,26 @@ create or replace package body ut_suite_builder is procedure add_to_throws_numbers_list( a_suite in out nocopy ut_suite, - a_list in out nocopy ut_integer_list, + a_list in out nocopy ut_varchar2_rows, a_procedure_name t_object_name, a_throws_ann_text tt_annotation_texts ) is l_annotation_pos binary_integer; - function is_valid_qualified_name (a_name varchar2) return boolean is - l_name varchar2(500); - begin - l_name := dbms_assert.qualified_sql_name(a_name); - return true; - exception when others then - return false; - end; - - function check_exception_type(a_exception_name in varchar2) return varchar2 is - l_exception_type varchar2(50); - begin - --check if it is a predefined exception - begin - execute immediate 'begin null; exception when '||a_exception_name||' then null; end;'; - l_exception_type := gc_named_exception; - exception - when others then - if dbms_utility.format_error_stack() like '%PLS-00485%' then - begin - execute immediate 'declare x positiven := -('||a_exception_name||'); begin null; end;'; - l_exception_type := gc_integer_exception; - exception - when others then - --invalid exception number (positive) - --TODO add warning for this value - null; - end; - end if; - end; - return l_exception_type; - end; - - function get_exception_number (a_exception_var in varchar2) return integer is - l_exc_no integer; - l_exc_type varchar2(50); - function remap_no_data_found (a_number integer) return integer is - begin - return case a_number when 100 then -1403 else a_number end; - end; - begin - l_exc_type := check_exception_type(a_exception_var); - - if l_exc_type is not null then - - execute immediate - case l_exc_type - when gc_integer_exception then - 'declare - l_exception number; - begin - :l_exception := '||a_exception_var||'; ' - when gc_named_exception then - 'begin - raise '||a_exception_var||'; - exception - when others then - :l_exception := sqlcode; ' - end || - 'end;' - using out l_exc_no; - - end if; - return remap_no_data_found(l_exc_no); - end; - - function build_exception_numbers_list( - a_suite in out nocopy ut_suite, - a_procedure_name t_object_name, - a_line_no integer, - a_annotation_text in varchar2 - ) return ut_integer_list is - l_throws_list ut_varchar2_list; - l_exception_number integer; - l_exception_number_list ut_integer_list := ut_integer_list(); - c_regexp_for_exception_no constant varchar2(30) := '^-?[[:digit:]]{1,5}$'; - begin - --the a_expected_error_codes is converted to a ut_varchar2_list after that is trimmed and filtered to left only valid exception numbers - l_throws_list := ut_utils.trim_list_elements(ut_utils.string_to_table(a_annotation_text, ',', 'Y')); - - for i in 1 .. l_throws_list.count - loop - /** - * Check if its a valid qualified name and if so try to resolve name to an exception number - */ - if is_valid_qualified_name(l_throws_list(i)) then - l_exception_number := get_exception_number(l_throws_list(i)); - elsif regexp_like(l_throws_list(i), c_regexp_for_exception_no) then - l_exception_number := l_throws_list(i); - end if; - - if l_exception_number is null then - a_suite.put_warning( - 'Invalid parameter value "'||l_throws_list(i) - ||'" for "--%throws" annotation. Parameter ignored.'||get_object_reference( a_suite, a_procedure_name, a_line_no ) - ); - else - l_exception_number_list.extend; - l_exception_number_list(l_exception_number_list.last) := l_exception_number; - end if; - l_exception_number := null; - end loop; - - return l_exception_number_list; - end; - begin - a_list := ut_integer_list(); l_annotation_pos := a_throws_ann_text.first; while l_annotation_pos is not null loop if a_throws_ann_text(l_annotation_pos) is null then a_suite.put_warning( - '"--%throws" annotation requires a parameter. Annotation ignored.' - || get_object_reference( a_suite, a_procedure_name, l_annotation_pos ) + '"--%throws" annotation requires a parameter. Annotation ignored.', + a_procedure_name, + l_annotation_pos ); else - a_list := - a_list multiset union - build_exception_numbers_list( - a_suite, - a_procedure_name, - l_annotation_pos, - a_throws_ann_text(l_annotation_pos) - ); + ut_utils.append_to_list( + a_list, + ut_utils.convert_collection( ut_utils.trim_list_elements ( ut_utils.string_to_table( a_throws_ann_text(l_annotation_pos), ',' ) ) ) + ); end if; l_annotation_pos := a_throws_ann_text.next(l_annotation_pos); end loop; @@ -330,8 +197,9 @@ create or replace package body ut_suite_builder is while l_annotation_pos is not null loop if a_tags_ann_text(l_annotation_pos) is null then a_suite.put_warning( - '"--%tags" annotation requires a tag value populated. Annotation ignored.' - || get_object_reference( a_suite, a_procedure_name, l_annotation_pos ) + '"--%tags" annotation requires a tag value populated. Annotation ignored.', + a_procedure_name, + l_annotation_pos ); else l_tag_items := ut_utils.trim_list_elements(ut_utils.string_to_table(a_tags_ann_text(l_annotation_pos),',')); @@ -342,8 +210,9 @@ create or replace package body ut_suite_builder is l_tags_list(l_tags_list.last) := l_tag_items(i); else a_suite.put_warning( - 'Invalid value "'||l_tag_items(i)||'" for "--%tags" annotation. See documentation for details on valid tag values. Annotation value ignored.' - || get_object_reference( a_suite, a_procedure_name, l_annotation_pos ) + 'Invalid value "'||l_tag_items(i)||'" for "--%tags" annotation. See documentation for details on valid tag values. Annotation value ignored.', + a_procedure_name, + l_annotation_pos ); end if; end loop; @@ -857,9 +726,10 @@ create or replace package body ut_suite_builder is if not regexp_like( l_context_name, '^(\w|[$#])+$' ) then a_parent.put_warning( 'Invalid value "'||l_context_name||'" for context name.' || - ' Context name ignored and fallback to auto-name "'||l_default_context_name||'" ' || - get_object_reference( a_parent, null, l_context_pos ) - ); + ' Context name ignored and fallback to auto-name "'||l_default_context_name||'" ', + null, + l_context_pos + ); end if; l_context_name := l_default_context_name; end if; @@ -886,8 +756,10 @@ create or replace package body ut_suite_builder is if l_end_context_pos is null then a_parent.put_warning( - 'Missing "--%endcontext" annotation for a "--%context" annotation. The end of package is considered end of context.'|| get_object_reference( a_parent, null, l_context_pos ) - ); + 'Missing "--%endcontext" annotation for a "--%context" annotation. The end of package is considered end of context.', + null, + l_context_pos + ); l_end_context_pos := a_annotations.by_line.last; end if; diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index f52d15bf7..509b28498 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -57,7 +57,7 @@ create or replace package body ut_suite_cache_manager is select 'UT_LOGICAL_SUITE' as self_type, p.path, p.object_owner, upper( substr(p.path, instr( p.path, '.', -1 ) + 1 ) ) as object_name, cast(null as ut_executables) as x, - cast(null as ut_integer_list) as y, + cast(null as ut_varchar2_rows) as y, cast(null as ut_executable_test) as z from suitepath_part p where p.path diff --git a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb index 1ad4f19a5..04e65a6c2 100644 --- a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb +++ b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb @@ -20,212 +20,230 @@ is c_e_diff_exc constant number := -20204; c_e_mix_list constant number := -20205; c_e_mix_missin constant number := -20206; - + c_e_positive constant number := 20207; + e_some_exception exception; pragma exception_init(e_some_exception, -20207); end;]'; l_package_spec := ' - create package annotated_package_with_throws is - --%suite(Dummy package to test annotation throws) - - --%test(Throws same annotated exception) - --%throws(-20145) - procedure raised_same_exception; - - --%test(Throws one of the listed exceptions) - --%throws(-20145,-20146, -20189 ,-20563) - procedure raised_one_listed_exception; - - --%test(Leading zero is ignored in exception list) - --%throws(-01476) - procedure leading_0_exception_no; - - --%test(Throws diff exception) - --%throws(-20144) - procedure raised_diff_exception; - - --%test(Throws empty) - --%throws() - procedure empty_throws; - - --%test(Ignores annotation and fails when exception was thrown) - --%throws(hello,784#,0-=234,,u1234) - procedure bad_paramters_with_except; - - --%test(Ignores annotation and succeeds when no exception thrown) - --%throws(hello,784#,0-=234,,u1234) - procedure bad_paramters_without_except; - - --%test(Detects a valid exception number within many invalid ones) - --%throws(7894562, operaqk, -=1, -1, pow74d, posdfk3) - procedure one_valid_exception_number; - - --%test(Gives failure when a exception is expected and nothing is thrown) - --%throws(-20459, -20136, -20145) - procedure nothing_thrown; - - --%test(Single exception defined as a constant number in package) - --%throws(exc_pkg.c_e_single_exc) - procedure single_exc_const_pkg; - - --%test(Gives success when one of annotated exception using constant is thrown) - --%throws(exc_pkg.c_e_list_1,exc_pkg.c_e_list_2) - procedure list_of_exc_constant; - - --%test(Gives failure when the raised exception is different that the annotated one using variable) - --%throws(exc_pkg.c_e_diff_exc) - procedure fail_not_match_exc; - - --%test(Success when one of exception from mixed list of number and constant is thrown) - --%throws(exc_pkg.c_e_mix_list,-20105) - procedure mixed_exc_list; - - --%test(Success when match exception even if other variable on list dont exists) - --%throws(exc_pkg.c_e_mix_missin,utter_rubbish) - procedure mixed_list_notexi; - - --%test(Success resolve and match named exception defined in pragma exception init) - --%throws(exc_pkg.e_some_exception) - procedure named_exc_pragma; - - --%test(Success resolve and match oracle named exception) - --%throws(NO_DATA_FOUND) - procedure named_exc_ora; - - --%test(Success resolve and match oracle named exception dup val index) - --%throws(DUP_VAL_ON_INDEX) - procedure named_exc_ora_dup_ind; - - --%test(Success map no data 100 to -1403) - --%throws(-1403) - procedure nodata_exc_ora; - - --%test(Success for exception defined as varchar) - --%throws(exc_pkg.c_e_varch_exc) - procedure defined_varchar_exc; - - --%test(Non existing constant exception) - --%throws(dummy.c_dummy); - procedure non_existing_const; - - --%test(Bad exception constant) - --%throws(exc_pkg.c_e_dummy); - procedure bad_exc_const; - - end; + create package annotated_package_with_throws is + --%suite(Dummy package to test annotation throws) + + --%test(Throws same annotated exception) + --%throws(-20145) + procedure raised_same_exception; + + --%test(Throws one of the listed exceptions) + --%throws(-20145,-20146, -20189 ,-20563) + procedure raised_one_listed_exception; + + --%test(Leading zero is ignored in exception list) + --%throws(-01476) + procedure leading_0_exception_no; + + --%test(Throws diff exception) + --%throws(-20144) + procedure raised_diff_exception; + + --%test(Throws empty) + --%throws() + procedure empty_throws; + + --%test(Ignores annotation and fails when exception was thrown) + --%throws(hello,784#,0-=234,,u1234) + procedure bad_paramters_with_except; + + --%test(Ignores annotation and succeeds when no exception thrown) + --%throws(hello,784#,0-=234,,u1234) + procedure bad_paramters_without_except; + + --%test(Ignores annotation for positive exception number value) + --%throws(20001) + procedure positive_exception_number; + + --%test(Ignores annotation for positive exception number variable) + --%throws(exc_pkg.c_e_positive) + procedure positive_exception_number_var; + + --%test(Detects a valid exception number within many invalid ones) + --%throws(7894562, operaqk, -=1, -1, pow74d, posdfk3) + procedure one_valid_exception_number; + + --%test(Gives failure when a exception is expected and nothing is thrown) + --%throws(-20459, -20136, -20145) + procedure nothing_thrown; + + --%test(Single exception defined as a constant number in package) + --%throws(exc_pkg.c_e_single_exc) + procedure single_exc_const_pkg; + + --%test(Gives success when one of annotated exception using constant is thrown) + --%throws(exc_pkg.c_e_list_1,exc_pkg.c_e_list_2) + procedure list_of_exc_constant; + + --%test(Gives failure when the raised exception is different that the annotated one using variable) + --%throws(exc_pkg.c_e_diff_exc) + procedure fail_not_match_exc; + + --%test(Success when one of exception from mixed list of number and constant is thrown) + --%throws(exc_pkg.c_e_mix_list,-20105) + procedure mixed_exc_list; + + --%test(Success when match exception even if other variable on list dont exists) + --%throws(exc_pkg.c_e_mix_missin,utter_rubbish) + procedure mixed_list_notexi; + + --%test(Success resolve and match named exception defined in pragma exception init) + --%throws(exc_pkg.e_some_exception) + procedure named_exc_pragma; + + --%test(Success resolve and match oracle named exception) + --%throws(NO_DATA_FOUND) + procedure named_exc_ora; + + --%test(Success resolve and match oracle named exception dup val index) + --%throws(DUP_VAL_ON_INDEX) + procedure named_exc_ora_dup_ind; + + --%test(Success map no data 100 to -1403) + --%throws(-1403) + procedure nodata_exc_ora; + + --%test(Success for exception defined as varchar) + --%throws(exc_pkg.c_e_varch_exc) + procedure defined_varchar_exc; + + --%test(Non existing constant exception) + --%throws(dummy.c_dummy); + procedure non_existing_const; + + --%test(Bad exception constant) + --%throws(exc_pkg.c_e_dummy); + procedure bad_exc_const; + end; '; l_package_body := ' - create package body annotated_package_with_throws is - procedure raised_same_exception is - begin - raise_application_error(-20145, ''Test error''); - end; - - procedure raised_one_listed_exception is - begin - raise_application_error(-20189, ''Test error''); - end; - - procedure leading_0_exception_no is - x integer; - begin - x := 1 / 0; - end; - - procedure raised_diff_exception is - begin - raise_application_error(-20143, ''Test error''); - end; - - procedure empty_throws is - begin - raise_application_error(-20143, ''Test error''); - end; - - procedure bad_paramters_with_except is - begin - raise_application_error(-20143, ''Test error''); - end; - - procedure bad_paramters_without_except is - begin - null; - end; - - procedure one_valid_exception_number is - begin - raise dup_val_on_index; - end; - - procedure nothing_thrown is - begin - null; - end; - - procedure single_exc_const_pkg is - begin - raise_application_error(exc_pkg.c_e_single_exc,''Test''); - end; - - procedure list_of_exc_constant is - begin - raise_application_error(exc_pkg.c_e_list_1,''Test''); - end; - - procedure fail_not_match_exc is - begin - raise NO_DATA_FOUND; - end; - - procedure mixed_exc_list is - begin - raise_application_error(exc_pkg.c_e_mix_list,''Test''); - end; - - procedure mixed_list_notexi is - begin - raise_application_error(exc_pkg.c_e_mix_missin,''Test''); - end; - - procedure named_exc_pragma is - begin - raise exc_pkg.e_some_exception; - end; - - procedure named_exc_ora is - begin - raise NO_DATA_FOUND; - end; - - procedure named_exc_ora_dup_ind is - begin - raise DUP_VAL_ON_INDEX; - end; - - procedure nodata_exc_ora is - begin - raise NO_DATA_FOUND; - end; - - procedure defined_varchar_exc is - begin - raise_application_error(exc_pkg.c_e_varch_exc,''Test''); - end; - - procedure non_existing_const is - begin - raise_application_error(-20143, ''Test error''); - end; - - procedure bad_exc_const is - begin - raise_application_error(-20143, ''Test error''); - end; - + create package body annotated_package_with_throws is + procedure raised_same_exception is + begin + raise_application_error(-20145, ''Test error''); + end; + + procedure raised_one_listed_exception is + begin + raise_application_error(-20189, ''Test error''); + end; + + procedure leading_0_exception_no is + x integer; + begin + x := 1 / 0; + end; + + procedure raised_diff_exception is + begin + raise_application_error(-20143, ''Test error''); + end; + + procedure empty_throws is + begin + raise_application_error(-20143, ''Test error''); + end; + + procedure bad_paramters_with_except is + begin + raise_application_error(-20143, ''Test error''); + end; + + procedure bad_paramters_without_except is + begin + null; + end; + + procedure positive_exception_number is + begin + null; + end; + + procedure positive_exception_number_var is + begin + null; + end; + + procedure one_valid_exception_number is + begin + raise dup_val_on_index; + end; + + procedure nothing_thrown is + begin + null; + end; + + procedure single_exc_const_pkg is + begin + raise_application_error(exc_pkg.c_e_single_exc,''Test''); + end; + + procedure list_of_exc_constant is + begin + raise_application_error(exc_pkg.c_e_list_1,''Test''); + end; + + procedure fail_not_match_exc is + begin + raise NO_DATA_FOUND; + end; + + procedure mixed_exc_list is + begin + raise_application_error(exc_pkg.c_e_mix_list,''Test''); + end; + + procedure mixed_list_notexi is + begin + raise_application_error(exc_pkg.c_e_mix_missin,''Test''); + end; + + procedure named_exc_pragma is + begin + raise exc_pkg.e_some_exception; + end; + + procedure named_exc_ora is + begin + raise NO_DATA_FOUND; + end; + + procedure named_exc_ora_dup_ind is + begin + raise DUP_VAL_ON_INDEX; + end; + + procedure nodata_exc_ora is + begin + raise NO_DATA_FOUND; + end; + + procedure defined_varchar_exc is + begin + raise_application_error(exc_pkg.c_e_varch_exc,''Test''); + end; + + procedure non_existing_const is + begin + raise_application_error(-20143, ''Test error''); end; + + procedure bad_exc_const is + begin + raise_application_error(-20143, ''Test error''); + end; + + end; '; execute immediate l_exception_spec; @@ -277,13 +295,25 @@ is procedure bad_paramters_without_except is begin ut.expect(g_tests_results).to_match('^\s*Ignores annotation and succeeds when no exception thrown \[[,\.0-9]+ sec\]\s*$','m'); - ut.expect(g_tests_results).not_to_match('bad_paramters_without_except'); + ut.expect(g_tests_results).to_match('bad_paramters_without_except\s*Invalid parameter value ".*" for "--%throws" annotation. Parameter ignored.','m'); + end; + + procedure positive_exception_number is + begin + ut.expect(g_tests_results).to_match('^\s*Ignores annotation for positive exception number value \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect(g_tests_results).to_match('positive_exception_number\s*Invalid parameter value "20001" for "--%throws" annotation. Exception value must be a negative integer. Parameter ignored.','m'); + end; + + procedure positive_exception_number_var is + begin + ut.expect(g_tests_results).to_match('^\s*Ignores annotation for positive exception number variable \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect(g_tests_results).to_match('positive_exception_number_var\s*Invalid parameter value ".*" for "--%throws" annotation. Exception value must be a negative integer. Parameter ignored.','m'); end; procedure one_valid_exception_number is begin ut.expect(g_tests_results).to_match('^\s*Detects a valid exception number within many invalid ones \[[\.0-9]+ sec\]\s*$','m'); - ut.expect(g_tests_results).not_to_match('one_valid_exception_number'); + ut.expect(g_tests_results).to_match('one_valid_exception_number\s*Invalid parameter value ".*" for "--%throws" annotation. Parameter ignored.','m'); end; procedure nothing_thrown is @@ -319,13 +349,13 @@ is procedure mixed_list_notexi is begin ut.expect(g_tests_results).to_match('^\s*Success when match exception even if other variable on list dont exists \[[,\.0-9]+ sec\]\s*$','m'); - ut.expect(g_tests_results).not_to_match('mixed_list_notexi'); + ut.expect(g_tests_results).to_match('mixed_list_notexi\s*Invalid parameter value "utter_rubbish" for "--%throws" annotation. Parameter ignored.','m'); end; procedure named_exc_pragma is begin ut.expect(g_tests_results).to_match('^\s*Success resolve and match named exception defined in pragma exception init \[[,\.0-9]+ sec\]\s*$','m'); - ut.expect(g_tests_results).not_to_match('mixed_list_notexi'); + ut.expect(g_tests_results).not_to_match('named_exc_pragma'); end; procedure named_exc_ora is diff --git a/test/ut3_tester/core/annotations/test_annot_throws_exception.pks b/test/ut3_tester/core/annotations/test_annot_throws_exception.pks index ce2e6ba7a..a9d20183d 100644 --- a/test/ut3_tester/core/annotations/test_annot_throws_exception.pks +++ b/test/ut3_tester/core/annotations/test_annot_throws_exception.pks @@ -26,7 +26,13 @@ is --%test(Ignores when only bad parameters are passed, the test does not raise a exception and it shows successful test) procedure bad_paramters_without_except; - + + --%test(Ignores annotation for positive exception number value) + procedure positive_exception_number; + + --%test(Ignores annotation for positive exception number variable) + procedure positive_exception_number_var; + --%test(Detects a valid exception number within many invalid ones) procedure one_valid_exception_number; diff --git a/test/ut3_tester/core/test_suite_builder.pkb b/test/ut3_tester/core/test_suite_builder.pkb index 86d86032a..00d914413 100644 --- a/test/ut3_tester/core/test_suite_builder.pkb +++ b/test/ut3_tester/core/test_suite_builder.pkb @@ -1386,24 +1386,6 @@ create or replace package body test_suite_builder is ); end; - procedure throws_value_invalid is - l_actual clob; - l_annotations ut3.ut_annotations; - begin - --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(3, 'test','A test with invalid throws annotation', 'A_TEST_PROCEDURE'), - ut3.ut_annotation(3, 'throws',' -20145 , bad_variable_name ', 'A_TEST_PROCEDURE') - ); - --Act - l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); - --Assert - ut.expect(l_actual).to_be_like( - '%%Invalid parameter value "bad_variable_name" for "--%throws" annotation. Parameter ignored.%%' - ); - end; - procedure before_aftertest_multi is l_actual clob; diff --git a/test/ut3_tester/core/test_suite_builder.pks b/test/ut3_tester/core/test_suite_builder.pks index 7c7fc77f6..4b49e606f 100644 --- a/test/ut3_tester/core/test_suite_builder.pks +++ b/test/ut3_tester/core/test_suite_builder.pks @@ -161,9 +161,6 @@ create or replace package test_suite_builder is --%test(Gives warning if --%throws annotation has no value) procedure throws_value_empty; - --%test(Gives warning if --%throws annotation has invalid value) - procedure throws_value_invalid; - --%endcontext --%context(--%beforetest/aftertest annotation) From d33bd80f4a1b5c7e1c5188fa04ac5fcdfde9bf73 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 2 Jan 2020 19:11:57 +0000 Subject: [PATCH 022/887] Updated documentation for whitespace vs null compare. Updated tests o represent the issue more clearly. Closes #880 --- docs/userguide/expectations.md | 3 +- .../expectations/test_expectations_cursor.pkb | 56 +++++++------------ .../expectations/test_expectations_cursor.pks | 36 ++++++------ 3 files changed, 39 insertions(+), 56 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 612b59444..9cd665314 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1114,7 +1114,8 @@ utPLSQL is capable of comparing compound data-types including: - It is possible to compare PL/SQL records, collections, varrays and associative arrays. To compare this types of data, use cursor comparison feature of utPLSQL and TABLE operator in SQL query - On Oracle 11g Release 2 - pipelined table functions are needed (see section [Implicit (Shadow) Types in this artcile](https://oracle-base.com/articles/misc/pipelined-table-functions)) - On Oracle 12c and above - use [TABLE function on nested tables/varrays/associative arrays of PL/SQL records](https://oracle-base.com/articles/12c/using-the-table-operator-with-locally-defined-types-in-plsql-12cr1) - +- utPLSQL is not able to distinguish a NULL column/attribute from a column/attribute containing whitespace-only when comparing compound data. This is due to Oracle limitation on of XMLType., utPLSQL is not able to distinguish between + See [issue #880](https://github.com/utPLSQL/utPLSQL/issues/880) for details. *Note: This behavior might be fixed in future relreases, when utPLSQL is no longer depending on XMLType for compound data comparison.* utPLSQL offers advanced data-comparison options, for comparing compound data-types. The options allow you to: - define columns/attributes to exclude from comparison diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index 1c6f46532..054c65e17 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -2639,7 +2639,7 @@ Check the query and data for errors.'; end; - procedure insginificant_whitespace1 is + procedure space_only_vs_empty is l_actual sys_refcursor; l_expected sys_refcursor; begin @@ -2650,79 +2650,65 @@ Check the query and data for errors.'; select column_value t1 from table(ut_varchar2_list(' ')); --Assert ut3.ut.expect( l_actual ).to_equal( l_expected ); - ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; - procedure insginificant_whitespace2 is + procedure tab_only_vs_empty is l_actual sys_refcursor; l_expected sys_refcursor; begin open l_expected for - select ' t ' t1 from dual; - + select column_value t1 from table(ut_varchar2_list('')); + open l_actual for - select 't' t1 from dual; + select column_value t1 from table(ut_varchar2_list(chr(9))); --Assert ut3.ut.expect( l_actual ).to_equal( l_expected ); - ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); - end; - - procedure insginificant_whitespace3 is - l_actual sys_refcursor; - l_expected sys_refcursor; - begin - open l_expected for - select 't ' t1 from dual; - - open l_actual for - select 't' t1 from dual; - --Assert - ut3.ut.expect( l_actual ).to_equal( l_expected ); - ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; - - procedure insginificant_whitespace4 is + + procedure insignificant_start_end_space is l_actual sys_refcursor; l_expected sys_refcursor; begin open l_expected for - select ' t' t1 from dual; + select ' t ' t1 from dual; open l_actual for select 't' t1 from dual; --Assert ut3.ut.expect( l_actual ).to_equal( l_expected ); - ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); - end; + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); + end; - procedure insginificant_whitespace5 is + procedure double_vs_single_start_end_ws is l_actual sys_refcursor; l_expected sys_refcursor; begin open l_expected for - select ' ' t1 from dual; + select ' t ' t1 from dual; open l_actual for - select '' t1 from dual; + select ' t ' t1 from dual; --Assert ut3.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); - end; + end; - procedure nulltowhitespace is + procedure leading_tab_vs_space is l_actual sys_refcursor; l_expected sys_refcursor; begin open l_expected for - select cast(null as varchar2(2)) t1 from dual; + select ' t' t1 from dual; open l_actual for - select ' ' t1 from dual; + select chr(9)||'t' t1 from dual; --Assert ut3.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); - end; - + end; + procedure number_from_dual is l_actual sys_refcursor; l_expected sys_refcursor; diff --git a/test/ut3_user/expectations/test_expectations_cursor.pks b/test/ut3_user/expectations/test_expectations_cursor.pks index d3dbeb9a7..0ed249a49 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pks +++ b/test/ut3_user/expectations/test_expectations_cursor.pks @@ -417,31 +417,27 @@ create or replace package test_expectations_cursor is --%test(Check that column name accept non xml characters fix #902) procedure nonxmlchar_part_of_colname; - - - /*Oracle Bug not readin properly in xmltable */ - --%test ( Compare insiginificant whitespaces scenario 1 ) + + + /*Oracle Bug not reading properly in XMLTable - See - Issue #880 */ + --%disabled + --%test ( Space-only string is not equal empty string ) + procedure space_only_vs_empty; + + /*Oracle Bug not reading properly in XMLTable - See - Issue #880 */ --%disabled - procedure insginificant_whitespace1; + --%test ( Tab-only string is not equal empty string ) + procedure tab_only_vs_empty; - --%test ( Compare insiginificant whitespaces scenario 2 ) - procedure insginificant_whitespace2; + --%test ( Insignificant start/end whitespaces are considered ) + procedure insignificant_start_end_space; - --%test ( Compare insiginificant whitespaces scenario 3 ) - procedure insginificant_whitespace3; + --%test ( Double and single leading/trailing space is distinguished ) + procedure double_vs_single_start_end_ws; - --%test ( Compare insiginificant whitespaces scenario 4 ) - procedure insginificant_whitespace4; + --%test ( Leading Tab vs. Space is distinguished ) + procedure leading_tab_vs_space; - /*Oracle Bug not readin properly in xmltable */ - --%test ( Compare insiginificant whitespaces scenario 5 ) - --%disabled - procedure insginificant_whitespace5; - - /*Oracle Bug not readin properly in xmltable */ - --%test ( Compare null to whitespace ) - --%disabled - procedure nulltowhitespace; --%test(Check precision of number from dual #907) procedure number_from_dual; From 5510555c3b6cea45f273cb4135e811e959ce1877 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 3 Jan 2020 05:23:44 +0000 Subject: [PATCH 023/887] Fixed documentation. --- docs/userguide/expectations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 9cd665314..9f2842e2f 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1114,7 +1114,7 @@ utPLSQL is capable of comparing compound data-types including: - It is possible to compare PL/SQL records, collections, varrays and associative arrays. To compare this types of data, use cursor comparison feature of utPLSQL and TABLE operator in SQL query - On Oracle 11g Release 2 - pipelined table functions are needed (see section [Implicit (Shadow) Types in this artcile](https://oracle-base.com/articles/misc/pipelined-table-functions)) - On Oracle 12c and above - use [TABLE function on nested tables/varrays/associative arrays of PL/SQL records](https://oracle-base.com/articles/12c/using-the-table-operator-with-locally-defined-types-in-plsql-12cr1) -- utPLSQL is not able to distinguish a NULL column/attribute from a column/attribute containing whitespace-only when comparing compound data. This is due to Oracle limitation on of XMLType., utPLSQL is not able to distinguish between +- utPLSQL is not able to distinguish between a NULL and whitespace-only column/attribute from when comparing compound data. This is due to Oracle limitation on of XMLType. See [issue #880](https://github.com/utPLSQL/utPLSQL/issues/880) for details. *Note: This behavior might be fixed in future relreases, when utPLSQL is no longer depending on XMLType for compound data comparison.* utPLSQL offers advanced data-comparison options, for comparing compound data-types. The options allow you to: From d02ac9470627e0896922bdf37d03c89125b1422c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 29 Dec 2019 00:58:47 +0000 Subject: [PATCH 024/887] Changed ordering of tests for suites with context Resolves #1036 --- source/core/ut_suite_cache_manager.pkb | 20 ++-- test/ut3_tester/core/test_suite_builder.pkb | 118 ++++++++++---------- test/ut3_tester/core/test_suite_builder.pks | 2 +- 3 files changed, 74 insertions(+), 66 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 509b28498..759f55278 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -162,14 +162,20 @@ create or replace package body ut_suite_cache_manager is return case when a_random_seed is null then q'[ replace( - case - when c.obj.self_type in ( 'UT_TEST' ) - then substr(c.obj.path, 1, instr(c.obj.path, '.', -1) ) - else c.obj.path - end, '.', chr(0) + substr( c.obj.path, 1, instr( c.obj.path, lower(c.obj.object_name), -1 ) + length(c.obj.object_name) ), + '.', + chr(0) ) desc nulls last, - c.obj.object_name desc, - c.obj.line_no, + case when c.obj.self_type = 'UT_SUITE_CONTEXT' then + ( select max( x.line_no ) + 1 + from ut_suite_cache x + where c.obj.object_owner = x.object_owner and c.obj.object_name = x.object_name and + x.path like c.obj.path || '.%' + ) + else + c.obj.line_no + end, + regexp_count(c.obj.path,'\.') desc, :a_random_seed]' else ' ut_runner.hash_suite_path( diff --git a/test/ut3_tester/core/test_suite_builder.pkb b/test/ut3_tester/core/test_suite_builder.pkb index 00d914413..8eedc1142 100644 --- a/test/ut3_tester/core/test_suite_builder.pkb +++ b/test/ut3_tester/core/test_suite_builder.pkb @@ -649,6 +649,9 @@ create or replace package body test_suite_builder is '' || '%' || '%' || + '' || + '%suite_level_testIn suitesome_package.suite_level_test' || + '%' || '' || '%a_contextA contextsome_package.a_context' || '%' || @@ -661,9 +664,6 @@ create or replace package body test_suite_builder is '%' || '' || '' || - '' || - '%suite_level_testIn suitesome_package.suite_level_test' || - '%' || '' || '' || '%some_packagesuite_level_beforeall' || @@ -710,26 +710,14 @@ create or replace package body test_suite_builder is '' || '%' || '%' || + '' || + '%suite_level_testIn suitesome_package.suite_level_test' || + '%' || '' || '%a_contextA contextsome_package.a_context' || '%' || '' || - '%nested_context_2nested_context_2some_package.a_context.nested_context_2' || - '%' || - '' || - '%nested_context_#1a_nested_context_3some_package.a_context.nested_context_2.nested_context_#1' || - '%' || - '' || - '%test_in_nested_context_3Test in nested contextsome_package.a_context.nested_context_2.nested_context_#1.test_in_nested_context_3' || - '%' || - '' || - '' || - '%' || - '' || - '%test_in_nested_context_2Test in nested contextsome_package.a_context.nested_context_2.test_in_nested_context_2' || - '%' || - '' || - '' || + '%first_test_in_a_contextFirst test in contextsome_package.a_context.first_test_in_a_context' || '%' || '' || '%a_nested_contextA nested contextsome_package.a_context.a_nested_context' || @@ -743,7 +731,22 @@ create or replace package body test_suite_builder is '%' || '%' || '' || - '%first_test_in_a_contextFirst test in contextsome_package.a_context.first_test_in_a_context' || + '%nested_context_2nested_context_2some_package.a_context.nested_context_2' || + '%' || + '' || + '%test_in_nested_context_2Test in nested contextsome_package.a_context.nested_context_2.test_in_nested_context_2' || + '%' || + '' || + '%nested_context_#1a_nested_context_3some_package.a_context.nested_context_2.nested_context_#1' || + '%' || + '' || + '%test_in_nested_context_3Test in nested contextsome_package.a_context.nested_context_2.nested_context_#1.test_in_nested_context_3' || + '%' || + '' || + '' || + '%' || + '' || + '' || '%' || '' || '%second_test_in_a_contextSecond test in contextsome_package.a_context.second_test_in_a_context' || @@ -754,9 +757,6 @@ create or replace package body test_suite_builder is '%' || '' || '' || - '' || - '%suite_level_testIn suitesome_package.suite_level_test' || - '%' || '' || '' || '%some_packagesuite_level_beforeall' || @@ -859,6 +859,10 @@ create or replace package body test_suite_builder is ''|| '' || '%' || + '%' || + '%suite_level_test' || + '%%suite_level_test%' || + '%' || '%' || '%nested_context_#1A contextsome_package.nested_context_#1' || '%' || @@ -872,10 +876,6 @@ create or replace package body test_suite_builder is '%%context_beforeall%' || '%%context_afterall%' || '%' || - '%' || - '%suite_level_test' || - '%%suite_level_test%' || - '%' || '%' || '%'|| '' @@ -909,6 +909,12 @@ create or replace package body test_suite_builder is ''|| '' || '%' || + '%' || + '%suite_level_test' || + '%%suite_level_beforeeach%' || + '%%suite_level_test%' || + '%%suite_level_aftereach%' || + '%' || '%' || '%nested_context_#1nested_context_#1some_package.nested_context_#1' || '%' || @@ -920,12 +926,6 @@ create or replace package body test_suite_builder is '%' || '%' || '%' || - '%' || - '%suite_level_test' || - '%%suite_level_beforeeach%' || - '%%suite_level_test%' || - '%%suite_level_aftereach%' || - '%' || '%' || '%%suite_level_beforeall%' || '%%suite_level_afterall%' || @@ -961,18 +961,20 @@ create or replace package body test_suite_builder is ''|| '' || '%' || - '%a_contextSome contextsome_package.a_context' || - '%' || - '' || - '%test_in_a_contextIn contextsome_package.a_context.test_in_a_context' || - '%' || - '' || - '' || - '%some_packagecontext_setup' || - '%' || '%' || '%suite_level_testIn suitesome_package.suite_level_test' || '%' || + '%' || + '%a_contextSome contextsome_package.a_context' || + '%' || + '' || + '%test_in_a_contextIn contextsome_package.a_context.test_in_a_context' || + '%' || + '' || + '' || + '%some_packagecontext_setup' || + '%' || + '%' || '' || '' || '%some_packagesuite_level_beforeall' || @@ -1010,6 +1012,9 @@ create or replace package body test_suite_builder is ''|| '' || '%' || + '' || + '%suite_level_testIn suitesome_package.suite_level_test' || + '%' || '' || '%a_contextA contextsome_package.a_context' || '%' || @@ -1022,9 +1027,6 @@ create or replace package body test_suite_builder is '%' || '' || '' || - '' || - '%suite_level_testIn suitesome_package.suite_level_test' || - '%' || '' || '' || '%some_packagesuite_level_beforeall' || @@ -1067,32 +1069,32 @@ create or replace package body test_suite_builder is '' || '%' || '' || - '%nested_context_#2A contextsome_package.nested_context_#2' || + '%suite_level_testIn suitesome_package.suite_level_test' || + '%' || + '' || + '%a_contextA contextsome_package.a_context' || '%' || '' || - '%test_in_duplicated_contextIn duplicated contextsome_package.nested_context_#2.test_in_duplicated_context' || + '%test_in_a_contextIn contextsome_package.a_context.test_in_a_context' || '%' || '' || '' || - '%some_packagesetup_in_duplicated_context' || + '%some_packagecontext_setup' || '%' || '' || '' || '' || - '%a_contextA contextsome_package.a_context' || + '%nested_context_#2A contextsome_package.nested_context_#2' || '%' || '' || - '%test_in_a_contextIn contextsome_package.a_context.test_in_a_context' || + '%test_in_duplicated_contextIn duplicated contextsome_package.nested_context_#2.test_in_duplicated_context' || '%' || '' || '' || - '%some_packagecontext_setup' || + '%some_packagesetup_in_duplicated_context' || '%' || '' || '' || - '' || - '%suite_level_testIn suitesome_package.suite_level_test' || - '%' || '' || '' || '%some_packagesuite_level_beforeall' || @@ -1341,20 +1343,20 @@ create or replace package body test_suite_builder is '' || '%' || '' || - '%nested_context_#2A contextsome_package.nested_context_#2' || + '%nested_context_#1A contextsome_package.nested_context_#1' || '%' || '' || - '%test_in_a_context2In context2some_package.nested_context_#2.test_in_a_context2' || + '%test_in_a_context1In context1some_package.nested_context_#1.test_in_a_context1' || '%' || '' || '' || '' || '' || '' || - '%nested_context_#1A contextsome_package.nested_context_#1' || + '%nested_context_#2A contextsome_package.nested_context_#2' || '%' || '' || - '%test_in_a_context1In context1some_package.nested_context_#1.test_in_a_context1' || + '%test_in_a_context2In context2some_package.nested_context_#2.test_in_a_context2' || '%' || '' || '' || diff --git a/test/ut3_tester/core/test_suite_builder.pks b/test/ut3_tester/core/test_suite_builder.pks index 4b49e606f..e451563e5 100644 --- a/test/ut3_tester/core/test_suite_builder.pks +++ b/test/ut3_tester/core/test_suite_builder.pks @@ -151,7 +151,7 @@ create or replace package test_suite_builder is --%test(Is ignored when name value is empty) procedure name_empty_value; - --%test(Is ignored when name value is empty) + --%test(Is is applied to corresponding context when multiple contexts used) procedure multiple_contexts; --%endcontext From 0a4edaf1812ea8207d2124613e50fecb7233c4d6 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 29 Dec 2019 01:03:06 +0000 Subject: [PATCH 025/887] Test name fix --- test/ut3_tester/core/test_suite_builder.pks | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_tester/core/test_suite_builder.pks b/test/ut3_tester/core/test_suite_builder.pks index e451563e5..4cbfcad74 100644 --- a/test/ut3_tester/core/test_suite_builder.pks +++ b/test/ut3_tester/core/test_suite_builder.pks @@ -151,7 +151,7 @@ create or replace package test_suite_builder is --%test(Is ignored when name value is empty) procedure name_empty_value; - --%test(Is is applied to corresponding context when multiple contexts used) + --%test(Is applied to corresponding context when multiple contexts used) procedure multiple_contexts; --%endcontext From 326e055007b38fc3ec3380aaae86483f6cb21579 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 3 Jan 2020 05:33:03 +0000 Subject: [PATCH 026/887] Added documenting comments for ordering of data from suite_cache. Fixed SQL formatting. --- source/core/ut_suite_cache_manager.pkb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 759f55278..05984da3f 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -162,19 +162,23 @@ create or replace package body ut_suite_cache_manager is return case when a_random_seed is null then q'[ replace( + --suite path until objects name (excluding contexts and test path) with trailing dot (full stop) substr( c.obj.path, 1, instr( c.obj.path, lower(c.obj.object_name), -1 ) + length(c.obj.object_name) ), '.', + --'.' replaced with chr(0) to assure that child elements come before parent when sorting in descending oder chr(0) ) desc nulls last, case when c.obj.self_type = 'UT_SUITE_CONTEXT' then ( select max( x.line_no ) + 1 from ut_suite_cache x - where c.obj.object_owner = x.object_owner and c.obj.object_name = x.object_name and - x.path like c.obj.path || '.%' + where c.obj.object_owner = x.object_owner + and c.obj.object_name = x.object_name + and x.path like c.obj.path || '.%' ) else c.obj.line_no end, + --assures that child contexts come before parent contexts regexp_count(c.obj.path,'\.') desc, :a_random_seed]' else From a25b8b7c57c5928d38764b2997af0f1385561f2c Mon Sep 17 00:00:00 2001 From: Travis CI Date: Fri, 3 Jan 2020 05:54:05 +0000 Subject: [PATCH 027/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 205fbef66..19adafe88 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 923dd5b7d..95fb477ff 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 260e05ede..a715c2ef6 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 6ff3b41be..1cde4188e 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index fc2718b3f..2e44c6ba1 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 184866b7b..423f50ee2 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 12ccc8a30..5d1efaa62 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0f0682924..6092231de 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4853bfca1..978a7d3e1 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index ba4313743..4c33cbed9 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 612b59444..2947e55b8 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 31988dcfe..944ecb385 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 6de351376..4a165913f 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 346de3cb9..9093bdffe 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 7a8f10af6..32721d647 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 7babf9366..c1f7733ce 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index cd6e8b065..e97253135 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 096761d0a..d6d65a826 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -767,7 +767,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3298-develop + * secion v3.1.10.3311-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 671312a9f..aa074190e 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3298-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3311-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From d708443346b73a92fed3310605d4fa2a93ad914c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 4 Jan 2020 10:45:23 +0000 Subject: [PATCH 028/887] Fixed documentation typos. --- docs/userguide/expectations.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 9f2842e2f..6410fc6f1 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1114,8 +1114,8 @@ utPLSQL is capable of comparing compound data-types including: - It is possible to compare PL/SQL records, collections, varrays and associative arrays. To compare this types of data, use cursor comparison feature of utPLSQL and TABLE operator in SQL query - On Oracle 11g Release 2 - pipelined table functions are needed (see section [Implicit (Shadow) Types in this artcile](https://oracle-base.com/articles/misc/pipelined-table-functions)) - On Oracle 12c and above - use [TABLE function on nested tables/varrays/associative arrays of PL/SQL records](https://oracle-base.com/articles/12c/using-the-table-operator-with-locally-defined-types-in-plsql-12cr1) -- utPLSQL is not able to distinguish between a NULL and whitespace-only column/attribute from when comparing compound data. This is due to Oracle limitation on of XMLType. - See [issue #880](https://github.com/utPLSQL/utPLSQL/issues/880) for details. *Note: This behavior might be fixed in future relreases, when utPLSQL is no longer depending on XMLType for compound data comparison.* +- utPLSQL is not able to distinguish between NULL and whitespace-only column/attribute value when comparing compound data. This is due to Oracle limitation on of XMLType. + See [issue #880](https://github.com/utPLSQL/utPLSQL/issues/880) for details. *Note: This behavior might be fixed in future releases, when utPLSQL is no longer depending on XMLType for compound data comparison.* utPLSQL offers advanced data-comparison options, for comparing compound data-types. The options allow you to: - define columns/attributes to exclude from comparison From 101bcbf8f09bafecb151ba4d281e76c801236cd2 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sat, 4 Jan 2020 12:43:38 +0000 Subject: [PATCH 029/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 19adafe88..b526f0c8e 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 95fb477ff..207e0bae1 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index a715c2ef6..32346fa8a 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 1cde4188e..832a12eba 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 2e44c6ba1..b5615a2ed 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 423f50ee2..f5d78ea92 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 5d1efaa62..ddb939b76 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 6092231de..4bffbddfc 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 978a7d3e1..5ae210e58 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 4c33cbed9..3eeb45b45 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index dfbcc8651..374d35a62 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 944ecb385..1dab9dd0e 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 4a165913f..37d099545 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 9093bdffe..cd3a78dca 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 32721d647..8ff52311e 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c1f7733ce..9ea158190 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e97253135..f73c5a073 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3311--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index d6d65a826..dc49b6baf 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -767,7 +767,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3311-develop + * secion v3.1.10.3319-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index aa074190e..299ff2181 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3311-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3319-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 1b0b8f8c616356a211005f11a8960eac5300a57c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 15 Feb 2020 14:46:26 +0000 Subject: [PATCH 030/887] Refactored expectations on compound data With this change the reporting of differences is unified across: `unordered`, `ordered` and `join_by` comparison. --- .../data_values/ut_compound_data_helper.pkb | 131 +++++++++++------- .../expectations/test_expectation_anydata.pkb | 6 +- .../expectations/test_expectations_cursor.pkb | 22 ++- 3 files changed, 90 insertions(+), 69 deletions(-) diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index d7c0aab76..6a6b30a50 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -417,39 +417,78 @@ create or replace package body ut_compound_data_helper is l_join_xpath varchar2(32767) := ut_utils.to_xpath(a_join_by_list); l_results tt_row_diffs; l_sql varchar2(32767); + l_column_order varchar2(100); begin + if a_enforce_column_order then + l_column_order := 'col_no'; + else + l_column_order := 'col_name'; + end if; l_sql := q'[ - with exp as ( + with + exp_rows as( + select + exp_data_id, extract( exp_item_data, :column_path ) exp_item_data, item_no, diff_id + from ut_compound_data_diff_tmp + where diff_id = :diff_id + and exp_data_id = :self_guid + ), + act_rows as ( + select + act_data_id, extract( act_item_data, :column_path ) act_item_data, item_no, diff_id + from ut_compound_data_diff_tmp ucd + where diff_id = :diff_id + and ucd.act_data_id = :other_guid + ), + exp_cols as ( select - exp_item_data, exp_data_id, item_no rn, rownum col_no, pk_value, + exp_item_data, exp_data_id, item_no rn, rownum col_no, diff_id, s.column_value col, s.column_value.getRootElement() col_name, nvl(s.column_value.getclobval(),empty_clob()) col_val - from ( - select - exp_data_id, extract( ucd.exp_item_data, :column_path ) exp_item_data, item_no, - replace( extract( ucd.exp_item_data, :join_by ).getclobval(), chr(10) ) pk_value - from ut_compound_data_diff_tmp ucd - where diff_id = :diff_id - and ucd.exp_data_id = :self_guid - ) i, - table( xmlsequence( extract(i.exp_item_data,:extract_path) ) ) s + from exp_rows i, + table( xmlsequence( extract( i.exp_item_data, :extract_path ) ) ) s ), - act as ( + act_cols as ( select - act_item_data, act_data_id, item_no rn, rownum col_no, pk_value, + act_item_data, act_data_id, item_no rn, rownum col_no, diff_id, s.column_value col, s.column_value.getRootElement() col_name, nvl(s.column_value.getclobval(),empty_clob()) col_val + from act_rows i, + table( xmlsequence( extract( i.act_item_data, :extract_path ) ) ) s + ), + data_diff as ( + select rn, diff_type, xmlserialize(content data_item no indent) diffed_row, null pk_value, col_name, diff_id from ( - select - act_data_id, extract( ucd.act_item_data, :column_path ) act_item_data, item_no, - replace( extract( ucd.act_item_data, :join_by ).getclobval(), chr(10) ) pk_value - from ut_compound_data_diff_tmp ucd - where diff_id = :diff_id - and ucd.act_data_id = :other_guid - ) i, - table( xmlsequence( extract(i.act_item_data,:extract_path) ) ) s + select nvl(exp.rn, act.rn) rn, + exp.diff_id diff_id, + xmlagg(exp.col order by exp.col_no) exp_item, + xmlagg(act.col order by nvl(exp.col_no, act.col_no)) act_item, + max(nvl(exp.col_name,act.col_name)) col_name + from exp_cols exp + join act_cols act + on exp.rn = act.rn and exp.col_name = act.col_name + where dbms_lob.compare(exp.col_val, act.col_val) != 0 + group by nvl(exp.rn, act.rn), exp.diff_id + ) + unpivot ( data_item for diff_type in (exp_item as 'Expected:', act_item as 'Actual:') ) + ), + unordered_diff as ( + select rn, diff_type, xmlserialize(content data_item no indent) diffed_row, null pk_value, col_name, diff_id + from ( + select nvl(exp.rn, act.rn) rn, + exp.diff_id diff_id, + xmlagg(exp.col order by exp.col_name) exp_item, + xmlagg(act.col order by act.col_name) act_item, + max(nvl(exp.col_name,act.col_name)) col_name + from exp_cols exp + join act_cols act + on exp.rn = act.rn and exp.col_name = act.col_name + where dbms_lob.compare(exp.col_val, act.col_val) != 0 + group by nvl(exp.rn, act.rn), exp.diff_id + ) + unpivot ( data_item for diff_type in (exp_item as 'Expected:', act_item as 'Actual:') ) ) - select rn, diff_type, diffed_row, pk_value pk_value + select rn, diff_type, diffed_row, pk_value from ( select rn, diff_type, diffed_row, pk_value, case when diff_type = 'Actual:' then 1 else 2 end rnk, @@ -457,33 +496,20 @@ create or replace package body ut_compound_data_helper is col_name from ( ]' || case when a_unordered then q'[ - select rn, diff_type, xmlserialize(content data_item no indent) diffed_row, pk_value, col_name - from ( - select nvl(exp.rn, act.rn) rn, - nvl(exp.pk_value, act.pk_value) pk_value, - exp.col exp_item, - act.col act_item, - nvl(exp.col_name,act.col_name) col_name - from exp - join act - on exp.rn = act.rn and exp.col_name = act.col_name - where dbms_lob.compare(exp.col_val, act.col_val) != 0 - ) - unpivot ( data_item for diff_type in (exp_item as 'Expected:', act_item as 'Actual:') ) ]' + select u.rn, u.diff_type, u.diffed_row, + replace( + extract( case when i.exp_data_id is null then i.act_item_data else i.exp_item_data end, :join_by ).getclobval(), + chr(10) + ) pk_value, + u.col_name + from data_diff u + join ut_compound_data_diff_tmp i + on i.diff_id = u.diff_id + and i.item_no = u.rn]' else q'[ - select rn, diff_type, xmlserialize(content data_item no indent) diffed_row, null pk_value, col_name - from ( - select nvl(exp.rn, act.rn) rn, - xmlagg(exp.col order by exp.col_no) exp_item, - xmlagg(act.col order by act.col_no) act_item, - max(nvl(exp.col_name,act.col_name)) col_name - from exp exp - join act act - on exp.rn = act.rn and exp.col_name = act.col_name - where dbms_lob.compare(exp.col_val, act.col_val) != 0 - group by (exp.rn, act.rn) - ) - unpivot ( data_item for diff_type in (exp_item as 'Expected:', act_item as 'Actual:') ) ]' + select rn, diff_type, diffed_row, pk_value, col_name + from data_diff + where :join_by is null ]' end ||q'[ ) union all @@ -522,14 +548,13 @@ create or replace package body ut_compound_data_helper is case when final_order = 1 then to_char(rn) else col_name end, case when final_order = 1 then to_char(rnk) else col_name end ]' - else - null end; execute immediate l_sql bulk collect into l_results - using l_exp_extract_xpath, l_join_xpath, a_diff_id, a_expected_dataset_guid,a_extract_path, - l_act_extract_xpath, l_join_xpath, a_diff_id, a_actual_dataset_guid,a_extract_path, - l_join_xpath, l_join_xpath, a_diff_id; + using l_exp_extract_xpath, a_diff_id, a_expected_dataset_guid, + l_act_extract_xpath, a_diff_id, a_actual_dataset_guid, + a_extract_path, a_extract_path, + l_join_xpath, l_join_xpath, l_join_xpath, a_diff_id; return l_results; end; diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index f94b0efc0..ece5457a7 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -864,10 +864,8 @@ Rows: [ 60 differences, showing first 20 ] l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_object_list [ count = 2 ] was expected to equal: ut3_tester_helper.test_dummy_object_list [ count = 2 ] %Diff: %Rows: [ 3 differences ] -%PK 2 - Actual: Something 2 -%PK 2 - Actual: 2 -%PK 2 - Expected: Something 1 -%PK 2 - Expected: 1 +%PK 2 - Actual: Something 22 +%PK 2 - Expected: Something 11 %PK 1 - Extra: 1Something 11 %PK 4 - Missing: 4Something 22]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index 054c65e17..5a0b68f2f 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -371,7 +371,7 @@ create or replace package body test_expectations_cursor is l_expected_message := q'[Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ] %Diff: %Rows: [ 1 differences ] -%Row No. 1 - Actual: 4030 +%Row No. 1 - Actual: 3040 %Row No. 1 - Expected: 34]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); --Assert @@ -394,7 +394,7 @@ create or replace package body test_expectations_cursor is l_expected_message := q'[Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ] %Diff: %Rows: [ 1 differences ] -%Row No. 1 - Actual: 4030 +%Row No. 1 - Actual: 3040 %Row No. 1 - Expected: 34]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); --Assert @@ -860,9 +860,9 @@ Columns: Rows: [ 4 differences ] Row No. 1 - Actual: 25000 Row No. 1 - Expected: 10000 - Row No. 2 - Actual: TONYSTARK3100000 + Row No. 2 - Actual: 3TONYSTARK100000 Row No. 2 - Expected: 2LUKESKYWALKER1000 - Row No. 3 - Actual: JESSICAJONES42345 + Row No. 3 - Actual: 4JESSICAJONES2345 Row No. 3 - Expected: 3TONYSTARK100000 Row No. 4 - Extra: MLUKESKYWALKER21000]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -896,9 +896,9 @@ Columns: Rows: [ 4 differences ] Row No. 1 - Actual: 25000 Row No. 1 - Expected: 10000 - Row No. 2 - Actual: TONYSTARK3100000 + Row No. 2 - Actual: 3TONYSTARK100000 Row No. 2 - Expected: 2LUKESKYWALKER1000 - Row No. 3 - Actual: JESSICAJONES42345 + Row No. 3 - Actual: 4JESSICAJONES2345 Row No. 3 - Expected: 3TONYSTARK100000 Row No. 4 - Extra: MLUKESKYWALKER21000]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -1237,10 +1237,8 @@ Rows: [ 4 differences ] l_expected_message := q'[Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ] %Diff: %Rows: [ 1 differences ] -%PK 1 - Actual: 30 -%PK 1 - Expected: 3 -%PK 1 - Actual: 40 -%PK 1 - Expected: 4]'; +%PK 1 - Actual: 3040 +%PK 1 - Expected: 34]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); @@ -2511,7 +2509,7 @@ Diff:% begin l_exp_message :='ORA-20218: SQL exception thrown when fetching data from cursor: ORA-01476: divisor is equal to zero -at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line 2522 ut3.ut.expect(l_actual).to_equal(l_expected);% +at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line % ut3.ut.expect(l_actual).to_equal(l_expected);% Check the query and data for errors.'; open l_actual for @@ -2536,7 +2534,7 @@ Check the query and data for errors.'; l_exp_message :='ORA-20218: SQL exception thrown when fetching data from cursor: ORA-01476: divisor is equal to zero -at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line 2547 ut3.ut.expect(l_actual).to_equal(l_expected);% +at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line % ut3.ut.expect(l_actual).to_equal(l_expected);% Check the query and data for errors.'; open l_expected for From 8eac19e41a7b20d9b443901cae90cd3429310835 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 15 Feb 2020 15:03:34 +0000 Subject: [PATCH 031/887] Changed maven repo url. --- .travis/maven_cfg.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis/maven_cfg.sh b/.travis/maven_cfg.sh index ef2348099..b24e56582 100755 --- a/.travis/maven_cfg.sh +++ b/.travis/maven_cfg.sh @@ -7,7 +7,7 @@ cd $(dirname $(readlink -f $0)) # Download wagon-http recommended by Oracle. # On maven latest version this is not needed, but travis doesn't have it. if [ ! -f $CACHE_DIR/wagon-http-2.8-shaded.jar ]; then - curl -L -O "http://central.maven.org/maven2/org/apache/maven/wagon/wagon-http/2.8/wagon-http-2.8-shaded.jar" + curl -L -O "https://repo1.maven.org/maven2/org/apache/maven/wagon/wagon-http/2.8/wagon-http-2.8-shaded.jar" mv wagon-http-2.8-shaded.jar $CACHE_DIR/ sudo cp $CACHE_DIR/wagon-http-2.8-shaded.jar $MAVEN_HOME/lib/ext/ else From d84a6845b2275ec77fdc48a083c8deaae05ad752 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 15 Feb 2020 15:32:30 +0000 Subject: [PATCH 032/887] Removing maven step for obtaining Oracle jdbc drivers - those are now available as part of `utPLSQL-cli` since version `3.1.8` --- .travis.yml | 2 -- .travis/maven_cfg.sh | 18 ------------- .travis/pom.xml | 62 -------------------------------------------- .travis/settings.xml | 51 ------------------------------------ 4 files changed, 133 deletions(-) delete mode 100755 .travis/maven_cfg.sh delete mode 100644 .travis/pom.xml delete mode 100644 .travis/settings.xml diff --git a/.travis.yml b/.travis.yml index 7ac28e41f..6d2514c1b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -80,8 +80,6 @@ before_install: install: #- unzip utPLSQL.zip - unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli - # Get ojdbc via maven - - bash .travis/maven_cfg.sh - bash .travis/install_sqlcl.sh - sudo mkdir -p /dev/pdbs - sudo chmod -R 777 /dev/pdbs diff --git a/.travis/maven_cfg.sh b/.travis/maven_cfg.sh deleted file mode 100755 index b24e56582..000000000 --- a/.travis/maven_cfg.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/bash -set -ev -cp .travis/settings.xml $MAVEN_CFG/settings.xml - -cd $(dirname $(readlink -f $0)) - -# Download wagon-http recommended by Oracle. -# On maven latest version this is not needed, but travis doesn't have it. -if [ ! -f $CACHE_DIR/wagon-http-2.8-shaded.jar ]; then - curl -L -O "https://repo1.maven.org/maven2/org/apache/maven/wagon/wagon-http/2.8/wagon-http-2.8-shaded.jar" - mv wagon-http-2.8-shaded.jar $CACHE_DIR/ - sudo cp $CACHE_DIR/wagon-http-2.8-shaded.jar $MAVEN_HOME/lib/ext/ -else - echo "Using cached wagon-http..." - sudo cp $CACHE_DIR/wagon-http-2.8-shaded.jar $MAVEN_HOME/lib/ext/ -fi - -mvn dependency:copy-dependencies -DoutputDirectory=../utPLSQL-cli/lib \ No newline at end of file diff --git a/.travis/pom.xml b/.travis/pom.xml deleted file mode 100644 index 706bd79bb..000000000 --- a/.travis/pom.xml +++ /dev/null @@ -1,62 +0,0 @@ - - - 4.0.0 - org.utplsql - utplsql - 3.0.4-SNAPSHOT - jar - - utPLSQL - https://github.com/utPLSQL/utPLSQL - - - UTF-8 - - - - - com.oracle.jdbc - ojdbc8 - 12.2.0.1 - compile - - - com.oracle.jdbc - orai18n - 12.2.0.1 - compile - - - - - - maven.oracle.com - - true - - - false - - https://maven.oracle.com - default - - - - - - maven.oracle.com - https://maven.oracle.com - - - - - - - io.packagecloud.maven.wagon - maven-packagecloud-wagon - 0.0.6 - - - - diff --git a/.travis/settings.xml b/.travis/settings.xml deleted file mode 100644 index 731ef5298..000000000 --- a/.travis/settings.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - - - maven.oracle.com - ${env.ORACLE_OTN_USER} - ${env.ORACLE_OTN_PASSWORD} - - - ANY - ANY - OAM 11g - - - - - - http.protocol.allow-circular-redirects - %b,true - - - - - - - - - From 02ba32b6c660ceb8fdc58094943a4bc37e49a9ab Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 15 Feb 2020 15:34:22 +0000 Subject: [PATCH 033/887] Removing `/dev/pdbs` directory We do not use it since we switched to `small` databases. --- .travis.yml | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/.travis.yml b/.travis.yml index 6d2514c1b..018038144 100644 --- a/.travis.yml +++ b/.travis.yml @@ -50,10 +50,10 @@ env: - MAVEN_CFG=$HOME/.m2 matrix: - ORACLE_VERSION="${DOCKER_TAG_11G:-11g-r2-xe}" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_OPTIONS='--shm-size=1g' - - ORACLE_VERSION="${DOCKER_TAG_12C:-12c-r1-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' DOCKER_OPTIONS="-v /dev/pdbs:/opt/oracle/oradata/pdbs" - - ORACLE_VERSION="${DOCKER_TAG_12C2:-12c-r2-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' DOCKER_OPTIONS="-v /dev/pdbs:/opt/oracle/oradata/pdbs" - - ORACLE_VERSION="${DOCKER_TAG_18:-18c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' DOCKER_OPTIONS="-v /dev/pdbs:/opt/oracle/oradata/pdbs" - - ORACLE_VERSION="${DOCKER_TAG_19:-19c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' DOCKER_OPTIONS="-v /dev/pdbs:/opt/oracle/oradata/pdbs" + - ORACLE_VERSION="${DOCKER_TAG_12C:-12c-r1-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="${DOCKER_TAG_12C2:-12c-r2-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="${DOCKER_TAG_18:-18c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="${DOCKER_TAG_19:-19c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' cache: pip: true @@ -81,8 +81,6 @@ install: #- unzip utPLSQL.zip - unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli - bash .travis/install_sqlcl.sh - - sudo mkdir -p /dev/pdbs - - sudo chmod -R 777 /dev/pdbs - if [[ ! $TRAVIS_TAG ]]; then bash .travis/start_db.sh; fi before_script: From 15d24afa58bc29a79fc7e0a80bfa31e6c363406c Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sat, 15 Feb 2020 16:21:50 +0000 Subject: [PATCH 034/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index b526f0c8e..245d8504c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 207e0bae1..5f5295da8 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 32346fa8a..73498a628 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 832a12eba..34f990b6f 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b5615a2ed..c15e45936 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index f5d78ea92..d357cbd8c 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index ddb939b76..4c398a4a4 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 4bffbddfc..87f4f9519 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 5ae210e58..e1a9e09d1 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 3eeb45b45..624dba1ee 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 374d35a62..93b0f1258 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 1dab9dd0e..e37920255 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 37d099545..0a7a04b35 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index cd3a78dca..b6ef0def6 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 8ff52311e..3399c5c72 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 9ea158190..3ce5daace 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index f73c5a073..66617cb2e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3319--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index dc49b6baf..13f64d1bd 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -767,7 +767,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3319-develop + * secion v3.1.10.3327-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 299ff2181..3b23edad0 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3319-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3327-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ba90abf5be5ba05b44a9080349f9edd54fe7a62b Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 5 Aug 2019 02:44:42 +0100 Subject: [PATCH 035/887] Cleanup and refactoring of annotation cache. Added ability to refresh annotation cache with DDL trigger enabled if schema was not full-scanned. Resolves: #975 --- .../annotations/ut_annotation_cache_info.sql | 7 +- .../ut_annotation_cache_manager.pkb | 123 ++++---- .../ut_annotation_cache_manager.pks | 19 +- .../ut_annotation_cache_schema.sql | 8 +- .../annotations/ut_annotation_manager.pkb | 230 +++++++-------- .../annotations/ut_annotation_manager.pks | 15 +- .../core/annotations/ut_annotation_parser.pkb | 15 +- .../core/annotations/ut_annotation_parser.pks | 2 +- source/core/annotations/ut_trigger_check.pkb | 4 +- source/core/types/ut_suite_cache_row.tps | 40 +-- source/core/ut_suite_cache_manager.pkb | 23 +- source/core/ut_utils.pkb | 10 +- .../annotations/test_annotation_manager.pkb | 263 +++++++++++------- .../annotations/test_annotation_manager.pks | 37 ++- test/ut3_tester/core/test_suite_manager.pkb | 4 +- test/ut3_tester_helper/run_helper.pkb | 2 +- test/ut3_tester_helper/run_helper.pks | 2 +- 17 files changed, 453 insertions(+), 351 deletions(-) diff --git a/source/core/annotations/ut_annotation_cache_info.sql b/source/core/annotations/ut_annotation_cache_info.sql index e8dc2bfdb..e0781cab7 100644 --- a/source/core/annotations/ut_annotation_cache_info.sql +++ b/source/core/annotations/ut_annotation_cache_info.sql @@ -17,7 +17,10 @@ create table ut_annotation_cache_info ( object_name varchar2(250) not null, object_type varchar2(250) not null, parse_time timestamp not null, - constraint ut_annotation_cache_info_pk primary key(cache_id), - constraint ut_annotation_cache_info_uk unique (object_owner, object_type, object_name) + is_annotated varchar2(1) not null, + constraint ut_annotation_cache_info_ck1 check(is_annotated in ('Y','N')), + constraint ut_annotation_cache_info_pk primary key(cache_id) using index, + constraint ut_annotation_cache_info_uk unique (object_owner, object_type, object_name) using index, + constraint ut_annotation_cache_info_fk foreign key(object_owner, object_type) references ut_annotation_cache_schema(object_owner, object_type) on delete cascade ) organization index; diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index eb60ac3dd..6060d6a21 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -17,15 +17,26 @@ create or replace package body ut_annotation_cache_manager as */ procedure update_cache(a_object ut_annotated_object) is - l_cache_id integer; - l_new_objects_count integer := 0; + l_cache_id integer; + l_timestamp timestamp := systimestamp; pragma autonomous_transaction; begin + update ut_annotation_cache_schema s + set s.max_parse_time = l_timestamp + where s.object_type = a_object.object_type and s.object_owner = a_object.object_owner; + + if sql%rowcount = 0 then + insert into ut_annotation_cache_schema s + (object_owner, object_type, max_parse_time) + values (a_object.object_owner, a_object.object_type, l_timestamp); + end if; + -- if not in trigger, or object has annotations if ora_sysevent is null or a_object.annotations is not null and a_object.annotations.count > 0 then update ut_annotation_cache_info i - set i.parse_time = systimestamp + set i.parse_time = l_timestamp, + i.is_annotated = case when a_object.annotations is not empty then 'Y' else 'N' end where (i.object_owner, i.object_name, i.object_type) in ((a_object.object_owner, a_object.object_name, a_object.object_type)) returning cache_id into l_cache_id; @@ -33,24 +44,15 @@ create or replace package body ut_annotation_cache_manager as if sql%rowcount = 0 then insert into ut_annotation_cache_info - (cache_id, object_owner, object_name, object_type, parse_time) - values (ut_annotation_cache_seq.nextval, a_object.object_owner, a_object.object_name, a_object.object_type, systimestamp) + (cache_id, object_owner, object_name, object_type, parse_time, is_annotated) + values (ut_annotation_cache_seq.nextval, a_object.object_owner, a_object.object_name, a_object.object_type, l_timestamp, + case when a_object.annotations is not empty then 'Y' else 'N' end + ) returning cache_id into l_cache_id; - l_new_objects_count := 1; end if; end if; - update ut_annotation_cache_schema s - set s.object_count = s.object_count + l_new_objects_count, s.max_parse_time = systimestamp - where s.object_type = a_object.object_type and s.object_owner = a_object.object_owner; - - if sql%rowcount = 0 then - insert into ut_annotation_cache_schema s - (object_owner, object_type, object_count, max_parse_time) - values (a_object.object_owner, a_object.object_type, l_new_objects_count, systimestamp); - end if; - delete from ut_annotation_cache c where cache_id = l_cache_id; if a_object.annotations is not null and a_object.annotations.count > 0 then @@ -63,7 +65,8 @@ create or replace package body ut_annotation_cache_manager as end; - procedure cleanup_cache(a_objects ut_annotation_objs_cache_info) is + procedure reset_objects_cache(a_objects ut_annotation_objs_cache_info) is + l_timestamp timestamp := systimestamp; pragma autonomous_transaction; begin @@ -77,21 +80,39 @@ create or replace package body ut_annotation_cache_manager as and o.object_owner = i.object_owner ); + update ut_annotation_cache_schema s + set s.max_parse_time = l_timestamp + where (s.object_owner, s.object_type) + in ( + select o.object_owner, o.object_type + from table(a_objects) o + ); + + if sql%rowcount = 0 then + insert into ut_annotation_cache_schema s + (object_owner, object_type, max_parse_time) + select distinct o.object_owner, o.object_type, l_timestamp + from table(a_objects) o; + end if; + merge into ut_annotation_cache_info i using (select o.object_name, o.object_type, o.object_owner from table(a_objects) o ) o on (o.object_name = i.object_name and o.object_type = i.object_type and o.object_owner = i.object_owner) - when matched then update set parse_time = systimestamp + when matched then + update + set parse_time = l_timestamp, + is_annotated = 'N' when not matched then insert - (cache_id, object_owner, object_name, object_type, parse_time) - values (ut_annotation_cache_seq.nextval, o.object_owner, o.object_name, o.object_type, systimestamp); + (cache_id, object_owner, object_name, object_type, parse_time, is_annotated) + values (ut_annotation_cache_seq.nextval, o.object_owner, o.object_name, o.object_type, l_timestamp, 'N'); commit; end; - function get_annotations_objects_info(a_object_owner varchar2, a_object_type varchar2) return ut_annotation_objs_cache_info is + function get_cached_objects_list(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return ut_annotation_objs_cache_info is l_result ut_annotation_objs_cache_info; begin select ut_annotation_obj_cache_info( @@ -104,7 +125,8 @@ create or replace package body ut_annotation_cache_manager as bulk collect into l_result from ut_annotation_cache_info i where i.object_owner = a_object_owner - and i.object_type = a_object_type; + and i.object_type = a_object_type + and (i.parse_time > a_parsed_after or a_parsed_after is null); return l_result; end; @@ -123,6 +145,16 @@ create or replace package body ut_annotation_cache_manager as return l_result; end; + procedure set_fully_refreshed(a_object_owner varchar2, a_object_type varchar2) is + pragma autonomous_transaction; + begin + update ut_annotation_cache_schema s + set s.full_refresh_time = s.max_parse_time + where s.object_owner = a_object_owner + and s.object_type = a_object_type; + commit; + end; + procedure remove_from_cache(a_objects ut_annotation_objs_cache_info) is pragma autonomous_transaction; begin @@ -138,10 +170,10 @@ create or replace package body ut_annotation_cache_manager as commit; end; - function get_annotations_for_objects(a_cached_objects ut_annotation_objs_cache_info, a_parse_time timestamp) return sys_refcursor is - l_results sys_refcursor; + function get_annotations_parsed_since(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp) return sys_refcursor is + l_results sys_refcursor; begin - open l_results for q'[ + open l_results for select ut_annotated_object( i.object_owner, i.object_name, i.object_type, i.parse_time, cast( @@ -151,14 +183,12 @@ create or replace package body ut_annotation_cache_manager as ) order by c.annotation_position ) as ut_annotations ) - ) - from table(:a_cached_objects) o - join ut_annotation_cache_info i - on o.object_owner = i.object_owner and o.object_name = i.object_name and o.object_type = i.object_type + ) as annotated_object + from ut_annotation_cache_info i join ut_annotation_cache c on i.cache_id = c.cache_id - where ]'|| case when a_parse_time is null then ':a_parse_date is null' else 'i.parse_time > :a_parse_time' end ||q'[ - group by i.object_owner, i.object_name, i.object_type, i.parse_time]' - using a_cached_objects, a_parse_time; + where i.object_owner = a_object_owner and i.object_type = a_object_type + and (i.parse_time > a_parsed_after or a_parsed_after is null) + group by i.object_owner, i.object_type, i.object_name, i.parse_time; return l_results; end; @@ -168,35 +198,24 @@ create or replace package body ut_annotation_cache_manager as pragma autonomous_transaction; begin if a_object_owner is null and a_object_type is null then - l_cache_filter := ':a_object_owner is null and :a_object_type is null'; - l_filter := l_cache_filter; + l_filter := ':a_object_owner is null and :a_object_type is null'; + l_cache_filter := l_filter; else - l_filter := - case when a_object_owner is null then ':a_object_owner is null' else 'object_owner = :a_object_owner' end || ' - and '||case when a_object_type is null then ':a_object_type is null' else 'object_type = :a_object_type' end; - l_cache_filter := ' c.cache_id - in (select i.cache_id - from ut_annotation_cache_info i - where '|| l_filter || ' - )'; + l_filter := case when a_object_owner is null then ':a_object_owner is null' else 'object_owner = :a_object_owner' end; + l_filter := l_filter || ' and ' || case when a_object_type is null then ':a_object_type is null' else 'object_type = :a_object_type' end; + l_cache_filter := ' c.cache_id in (select i.cache_id from ut_annotation_cache_info i where ' || l_filter || ' )'; end if; - execute immediate ' - delete from ut_annotation_cache c - where '||l_cache_filter + execute immediate 'delete from ut_annotation_cache c where ' || l_cache_filter using a_object_owner, a_object_type; - execute immediate ' - delete from ut_annotation_cache_info i - where ' || l_filter + execute immediate ' delete from ut_annotation_cache_info i where ' || l_filter using a_object_owner, a_object_type; - execute immediate ' - delete from ut_annotation_cache_schema s - where ' || l_filter + execute immediate ' delete from ut_annotation_cache_schema s where ' || l_filter using a_object_owner, a_object_type; commit; end; -end ut_annotation_cache_manager; +end; / diff --git a/source/core/annotations/ut_annotation_cache_manager.pks b/source/core/annotations/ut_annotation_cache_manager.pks index 2a1d60f1e..e4ba6dd7a 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pks +++ b/source/core/annotations/ut_annotation_cache_manager.pks @@ -16,6 +16,7 @@ create or replace package ut_annotation_cache_manager authid definer as limitations under the License. */ subtype t_cache_schema_info is ut_annotation_cache_schema%rowtype; + /** * Populates cache with information about object and it's annotations * Cache information for individual object is modified by this code @@ -30,21 +31,27 @@ create or replace package ut_annotation_cache_manager authid definer as * Returns a ref_cursor containing `ut_annotated_object` as result * Range of data returned is limited by the input collection o cache object info * - * @param a_cached_objects a `ut_annotation_objs_cache_info` list with information about objects to get from cache + * @param a_cached_objects - list of `ut_annotation_objs_cache_info` containing objects to get from cache + * @param a_min_parse_time - limit results to annotations parsed after specified time only, + * if null - all cached annotations for given objects are returned */ - function get_annotations_for_objects(a_cached_objects ut_annotation_objs_cache_info, a_parse_time timestamp) return sys_refcursor; - + function get_annotations_parsed_since(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp) return sys_refcursor; - function get_annotations_objects_info(a_object_owner varchar2, a_object_type varchar2) return ut_annotation_objs_cache_info; + procedure set_fully_refreshed(a_object_owner varchar2, a_object_type varchar2); function get_cache_schema_info(a_object_owner varchar2, a_object_type varchar2) return t_cache_schema_info; /** - * Removes cached information about annotations for objects on the list and updates parse_time in cache info table. + * Returns information about all objects stored in annotation cache + */ + function get_cached_objects_list(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return ut_annotation_objs_cache_info; + + /** + * Resets cached information about annotations for objects on the list and updates parse_time in cache info table. * * @param a_objects a `ut_annotation_objs_cache_info` list with information about objects to remove annotations for */ - procedure cleanup_cache(a_objects ut_annotation_objs_cache_info); + procedure reset_objects_cache(a_objects ut_annotation_objs_cache_info); /** * Removes information about objects on the list diff --git a/source/core/annotations/ut_annotation_cache_schema.sql b/source/core/annotations/ut_annotation_cache_schema.sql index abab7385e..b8f908e84 100644 --- a/source/core/annotations/ut_annotation_cache_schema.sql +++ b/source/core/annotations/ut_annotation_cache_schema.sql @@ -12,10 +12,10 @@ create table ut_annotation_cache_schema ( See the License for the specific language governing permissions and limitations under the License. */ - object_owner varchar2(250) not null, - object_type varchar2(250) not null, - object_count integer not null, - max_parse_time date not null, + object_owner varchar2(250) not null, + object_type varchar2(250) not null, + max_parse_time date not null, + full_refresh_time timestamp, constraint ut_annotation_cache_schema_pk primary key(object_owner, object_type) ) organization index; diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index fd2997632..a37391d37 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -19,86 +19,85 @@ create or replace package body ut_annotation_manager as ------------------------------ --private definitions - function get_missing_objects(a_object_owner varchar2, a_object_type varchar2) return ut_annotation_objs_cache_info is - l_rows sys_refcursor; - l_ut_owner varchar2(250) := ut_utils.ut_owner; - l_objects_view varchar2(200) := ut_metadata.get_objects_view_name(); - l_cursor_text varchar2(32767); - l_data ut_annotation_objs_cache_info; - l_result ut_annotation_objs_cache_info; - l_card natural; + function user_can_see_whole_schema( a_schema_name varchar2 ) return boolean is begin - l_data := ut_annotation_cache_manager.get_annotations_objects_info(a_object_owner, a_object_type); - l_card := ut_utils.scale_cardinality(cardinality(l_data)); - - l_cursor_text := - 'select /*+ cardinality(i '||l_card||') */ - value(i) - from table( cast( :l_data as '||l_ut_owner||'.ut_annotation_objs_cache_info ) ) i - where - not exists ( - select 1 from '||l_objects_view||q'[ o - where o.owner = i.object_owner - and o.object_name = i.object_name - and o.object_type = i.object_type - and o.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' - and o.object_type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' - )]'; - open l_rows for l_cursor_text using l_data; - fetch l_rows bulk collect into l_result limit ut_utils.gc_max_objects_fetch_limit; - close l_rows; - return l_result; + return sys_context('userenv','current_schema') = a_schema_name + or ut_metadata.user_has_execute_any_proc() + or ut_metadata.is_object_visible('dba_objects'); end; - function get_annotation_objs_info( - a_object_owner varchar2, - a_object_type varchar2, - a_parse_date timestamp := null, - a_full_scan boolean := true - ) return ut_annotation_objs_cache_info is - l_rows sys_refcursor; - l_ut_owner varchar2(250) := ut_utils.ut_owner; - l_objects_view varchar2(200) := ut_metadata.get_objects_view_name(); - l_cursor_text varchar2(32767); - l_data ut_annotation_objs_cache_info; - l_result ut_annotation_objs_cache_info; + function get_non_existing_objects( a_object_owner varchar2, a_object_type varchar2 ) return ut_annotation_objs_cache_info is + l_objects_view varchar2(200) := ut_metadata.get_objects_view_name(); + l_object_to_delete ut_annotation_objs_cache_info := ut_annotation_objs_cache_info(); + l_cached_objects ut_annotation_objs_cache_info; begin - ut_event_manager.trigger_event( - 'get_annotation_objs_info - start ( a_full_scan = ' || ut_utils.to_string(a_full_scan) || ' )' - ); + l_cached_objects := ut_annotation_cache_manager.get_cached_objects_list( a_object_owner, a_object_type ); + + if l_cached_objects is not empty then + execute immediate 'select /*+ cardinality(i '||ut_utils.scale_cardinality(cardinality(l_cached_objects))||') */ + value(i) + from table( :l_data ) i + where + not exists ( + select 1 from '||l_objects_view||q'[ o + where o.owner = i.object_owner + and o.object_name = i.object_name + and o.object_type = i.object_type + and o.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' + and o.object_type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' + )]' + bulk collect into l_object_to_delete + using l_cached_objects; + end if; + return l_object_to_delete; + end; - l_data := ut_annotation_cache_manager.get_annotations_objects_info(a_object_owner, a_object_type); + function get_objects_to_refresh( + a_object_owner varchar2, + a_object_type varchar2, + a_modified_after timestamp + ) return ut_annotation_objs_cache_info is + l_ut_owner varchar2(250) := ut_utils.ut_owner; + l_refresh_needed boolean; + l_objects_view varchar2(200) := ut_metadata.get_objects_view_name(); + l_cached_objects ut_annotation_objs_cache_info; + l_result ut_annotation_objs_cache_info; + begin + ut_event_manager.trigger_event( 'get_objects_to_refresh - start' ); - if not a_full_scan then - l_result := l_data; - else - l_cursor_text := - 'select /*+ cardinality(i '||ut_utils.scale_cardinality(cardinality(l_data))||') */ - '||l_ut_owner||q'[.ut_annotation_obj_cache_info( - object_owner => o.owner, - object_name => o.object_name, - object_type => o.object_type, - needs_refresh => case when o.last_ddl_time < cast(i.parse_time as date) then 'N' else 'Y' end, - parse_time => i.parse_time - ) - from ]'||l_objects_view||' o - left join table( cast(:l_data as '||l_ut_owner||q'[.ut_annotation_objs_cache_info ) ) i - on o.owner = i.object_owner - and o.object_name = i.object_name - and o.object_type = i.object_type - where o.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' - and o.object_type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' - and ]' + l_refresh_needed := ( ut_trigger_check.is_alive() = false ) or a_modified_after is null; + l_cached_objects := ut_annotation_cache_manager.get_cached_objects_list( a_object_owner, a_object_type, a_modified_after ); + if l_refresh_needed then + --limit the list to objects that exist and are visible to the invoking user + --enrich the list by info about cache validity + execute immediate + 'select /*+ cardinality(i '||ut_utils.scale_cardinality(cardinality(l_cached_objects))||') */ + '||l_ut_owner||q'[.ut_annotation_obj_cache_info( + object_owner => o.owner, + object_name => o.object_name, + object_type => o.object_type, + needs_refresh => 'Y', + parse_time => c.parse_time + ) + from ]'||l_objects_view||' o + left join table( cast(:l_cached_objects as '||l_ut_owner||q'[.ut_annotation_objs_cache_info ) ) c + on o.owner = c.object_owner + and o.object_name = c.object_name + and o.object_type = c.object_type + where o.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' + and o.object_type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' + and case when o.last_ddl_time < cast(c.parse_time as date) then 'N' else 'Y' end = 'Y' + and ]' || case - when a_parse_date is null - then ':a_parse_date is null' - else 'o.last_ddl_time >= cast(:a_parse_date as date)' - end; - open l_rows for l_cursor_text using l_data, a_parse_date; - fetch l_rows bulk collect into l_result limit ut_utils.gc_max_objects_fetch_limit; - close l_rows; + when a_modified_after is null + then ':a_modified_after is null' + else 'o.last_ddl_time >= cast(:a_modified_after as date)' + end + bulk collect into l_result using l_cached_objects, a_modified_after; + else + l_result := l_cached_objects; end if; - ut_event_manager.trigger_event('get_annotation_objs_info - end (count='||l_result.count||')'); + ut_event_manager.trigger_event('get_objects_to_refresh - end (count='||l_result.count||')'); return l_result; end; @@ -109,24 +108,24 @@ create or replace package body ut_annotation_manager as begin l_card := ut_utils.scale_cardinality(cardinality(a_objects_to_refresh)); open l_result for - q'[select s.name, s.text + q'[select x.name, x.text from (select /*+ cardinality( r ]'||l_card||q'[ )*/ s.name, s.text, s.line, max(case when s.text like '%--%\%%' escape '\' - and regexp_like(s.text,'--\s*%') + and regexp_like(s.text,'^\s*--\s*%') then 'Y' else 'N' end ) over(partition by s.name) is_annotated from table(:a_objects_to_refresh) r join ]'||l_sources_view||q'[ s - on s.name = r.object_name + on s.name = r.object_name and s.owner = r.object_owner - and s.type = r.object_type - where s.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' - and s.type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' - ) s - where s.is_annotated = 'Y' - order by s.name, s.line]' + and s.type = r.object_type + where s.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' + and s.type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' + ) x + where x.is_annotated = 'Y' + order by x.name, x.line]' using a_objects_to_refresh; return l_result; @@ -174,47 +173,57 @@ create or replace package body ut_annotation_manager as end; - procedure refresh_annotation_cache( - a_object_owner varchar2, - a_object_type varchar2, - a_info_rows ut_annotation_objs_cache_info + procedure validate_annotation_cache( + a_object_owner varchar2, + a_object_type varchar2, + a_modified_after timestamp := null ) is - l_objects_to_parse ut_annotation_objs_cache_info; + l_objects_to_refresh ut_annotation_objs_cache_info; + l_modified_after timestamp := a_modified_after; begin - select value(x) - bulk collect into l_objects_to_parse - from table(a_info_rows) x where x.needs_refresh = 'Y'; + if ut_annotation_cache_manager.get_cache_schema_info(a_object_owner, a_object_type).full_refresh_time is null then + l_modified_after := null; + end if; - ut_event_manager.trigger_event('rebuild_annotation_cache - start (l_objects_to_parse.count = '||l_objects_to_parse.count||')'); - ut_annotation_cache_manager.cleanup_cache(l_objects_to_parse); + l_objects_to_refresh := get_objects_to_refresh(a_object_owner, a_object_type, l_modified_after); - if sys_context('userenv','current_schema') = a_object_owner - or ut_metadata.user_has_execute_any_proc() - or ut_metadata.is_object_visible('dba_objects') - then - ut_annotation_cache_manager.remove_from_cache( - get_missing_objects(a_object_owner, a_object_type) - ); + ut_event_manager.trigger_event('validate_annotation_cache - start (l_objects_to_refresh.count = '||l_objects_to_refresh.count||')'); + + + if user_can_see_whole_schema( a_object_owner ) then + --Remove non existing objects from cache only when user can see whole schema + ut_annotation_cache_manager.remove_from_cache( get_non_existing_objects( a_object_owner, a_object_type ) ); end if; --if some source needs parsing and putting into cache - if l_objects_to_parse.count > 0 then + if l_objects_to_refresh.count > 0 then + --Delete annotations for objects that are to be refreshed + ut_annotation_cache_manager.reset_objects_cache(l_objects_to_refresh); + --Rebuild cache from objects source build_annot_cache_for_sources( a_object_owner, a_object_type, - get_sources_to_annotate(a_object_owner, a_object_type, l_objects_to_parse) + get_sources_to_annotate(a_object_owner, a_object_type, l_objects_to_refresh) ); end if; - ut_event_manager.trigger_event('rebuild_annotation_cache - end'); + + if l_modified_after is null then + if user_can_see_whole_schema( a_object_owner ) then + ut_annotation_cache_manager.set_fully_refreshed( a_object_owner, a_object_type ); + else + -- if user cannot see full schema - we dont mark it as fully refreshed + -- it will get refreshed each time until someone with proper privs will refresh it + null; + end if; + end if; + ut_event_manager.trigger_event('validate_annotation_cache - end'); end; ------------------------------------------------------------ --public definitions ------------------------------------------------------------ procedure rebuild_annotation_cache(a_object_owner varchar2, a_object_type varchar2) is - l_annotation_objs_info ut_annotation_objs_cache_info; begin - l_annotation_objs_info := get_annotation_objs_info(a_object_owner, a_object_type, null, true); - refresh_annotation_cache( a_object_owner, a_object_type, l_annotation_objs_info ); + validate_annotation_cache( a_object_owner, a_object_type ); end; procedure trigger_obj_annotation_rebuild is @@ -295,17 +304,14 @@ create or replace package body ut_annotation_manager as end if; end; - function get_annotated_objects(a_object_owner varchar2, a_object_type varchar2, a_parse_date timestamp := null) return sys_refcursor is - l_annotation_objs_info ut_annotation_objs_cache_info; + function get_annotated_objects(a_object_owner varchar2, a_object_type varchar2, a_modified_after timestamp) return sys_refcursor is l_cursor sys_refcursor; - l_full_scan_needed boolean := not ut_trigger_check.is_alive(); begin - ut_event_manager.trigger_event('get_annotated_objects - start'); - l_annotation_objs_info := get_annotation_objs_info(a_object_owner, a_object_type, a_parse_date, l_full_scan_needed); - refresh_annotation_cache(a_object_owner, a_object_type, l_annotation_objs_info); + ut_event_manager.trigger_event('get_annotated_objects - start: a_modified_after='||ut_utils.to_string(a_modified_after)); + validate_annotation_cache(a_object_owner, a_object_type, a_modified_after); --pipe annotations from cache - l_cursor := ut_annotation_cache_manager.get_annotations_for_objects(l_annotation_objs_info, a_parse_date); + l_cursor := ut_annotation_cache_manager.get_annotations_parsed_since(a_object_owner, a_object_type, a_modified_after); ut_event_manager.trigger_event('get_annotated_objects - end'); return l_cursor; end; @@ -315,5 +321,5 @@ create or replace package body ut_annotation_manager as ut_annotation_cache_manager.purge_cache(a_object_owner, a_object_type); end; -end ut_annotation_manager; +end; / diff --git a/source/core/annotations/ut_annotation_manager.pks b/source/core/annotations/ut_annotation_manager.pks index 1d6bd3d71..70257afac 100644 --- a/source/core/annotations/ut_annotation_manager.pks +++ b/source/core/annotations/ut_annotation_manager.pks @@ -23,18 +23,17 @@ create or replace package ut_annotation_manager authid current_user as /** * Gets annotations for all objects of a specified type for database schema. * Annotations that are stale or missing are parsed and placed in persistent cache. - * After placing in cache, annotation data is returned as pipelined table data. + * After placing in cache, annotation data is returned as ref_cursor. * - * @param a_object_owner owner of objects to get annotations for - * @param a_object_type type of objects to get annotations for - * @param a_parse_date date when object was last parsed - * @return array containing annotated objects along with annotations for each object (nested) + * @param a_object_owner owner of objects to get annotations for + * @param a_object_type type of objects to get annotations for + * @param a_modified_after return only objects modified after thr timestamp + * @return cursor containing annotated objects along with annotations for each object (nested) */ - function get_annotated_objects(a_object_owner varchar2, a_object_type varchar2, a_parse_date timestamp := null) return sys_refcursor; + function get_annotated_objects(a_object_owner varchar2, a_object_type varchar2, a_modified_after timestamp) return sys_refcursor; /** * Rebuilds annotation cache for a specified schema and object type. - * The procedure is called internally by `get_annotated_objects` function. * It can be used to speedup initial execution of utPLSQL on a given schema * if it is executed before any call is made to `ut.run` or `ut_runner.run` procedure. * @@ -57,5 +56,5 @@ create or replace package ut_annotation_manager authid current_user as procedure purge_cache(a_object_owner varchar2, a_object_type varchar2); -end ut_annotation_manager; +end; / diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index bbe58a667..6248f36b9 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -212,14 +212,6 @@ create or replace package body ut_annotation_parser as select value(x) bulk collect into l_result from table(l_annotations) x order by x.position; - -- printing out parsed structure for debugging - $if $$ut_trace $then - print_parse_results(l_result); - dbms_output.put_line('Annotations count: ' || l_result.count); - for i in 1 .. l_result.count loop - dbms_output.put_line(xmltype(l_result(i)).getclobval()); - end loop; - $end return l_result; end parse_object_annotations; @@ -229,7 +221,8 @@ create or replace package body ut_annotation_parser as l_annotations ut_annotations := ut_annotations(); ex_package_is_wrapped exception; pragma exception_init(ex_package_is_wrapped, -24241); - + source_text_is_empty exception; + pragma exception_init(source_text_is_empty, -24236); begin if a_source_lines.count > 0 then --convert to post-processed source clob @@ -248,12 +241,12 @@ create or replace package body ut_annotation_parser as l_annotations := parse_object_annotations(l_source); dbms_lob.freetemporary(l_source); exception - when ex_package_is_wrapped then + when ex_package_is_wrapped or source_text_is_empty then null; end; end if; return l_annotations; end; -end ut_annotation_parser; +end; / diff --git a/source/core/annotations/ut_annotation_parser.pks b/source/core/annotations/ut_annotation_parser.pks index b0a61e576..0368811db 100644 --- a/source/core/annotations/ut_annotation_parser.pks +++ b/source/core/annotations/ut_annotation_parser.pks @@ -40,5 +40,5 @@ create or replace package ut_annotation_parser authid current_user as */ function parse_object_annotations(a_source clob) return ut_annotations; -end ut_annotation_parser; +end; / diff --git a/source/core/annotations/ut_trigger_check.pkb b/source/core/annotations/ut_trigger_check.pkb index e07acd3b2..76d3aa11c 100644 --- a/source/core/annotations/ut_trigger_check.pkb +++ b/source/core/annotations/ut_trigger_check.pkb @@ -22,9 +22,7 @@ create or replace package body ut_trigger_check is function is_alive return boolean is pragma autonomous_transaction; begin - if not g_is_trigger_live then - execute immediate 'create or replace synonym '||ut_utils.ut_owner||'.'||gc_check_object_name||' for no_object'; - end if; + execute immediate 'create or replace synonym '||ut_utils.ut_owner||'.'||gc_check_object_name||' for no_object'; return g_is_trigger_live; end; diff --git a/source/core/types/ut_suite_cache_row.tps b/source/core/types/ut_suite_cache_row.tps index fb4a8bb9f..d9f542de3 100644 --- a/source/core/types/ut_suite_cache_row.tps +++ b/source/core/types/ut_suite_cache_row.tps @@ -15,26 +15,26 @@ create type ut_suite_cache_row as object ( See the License for the specific language governing permissions and limitations under the License. */ - id number(22,0), - self_type varchar2(250 byte), - path varchar2(1000 byte), - object_owner varchar2(250 byte), - object_name varchar2(250 byte), - name varchar2(250 byte), - line_no number, - parse_time timestamp (6), - description varchar2(4000 byte), - rollback_type number, - disabled_flag number, - warnings ut_varchar2_rows, - before_all_list ut_executables, - after_all_list ut_executables, - before_each_list ut_executables, - before_test_list ut_executables, - after_each_list ut_executables, - after_test_list ut_executables, + id number(22,0), + self_type varchar2(250 byte), + path varchar2(1000 byte), + object_owner varchar2(250 byte), + object_name varchar2(250 byte), + name varchar2(250 byte), + line_no number, + parse_time timestamp (6), + description varchar2(4000 byte), + rollback_type number, + disabled_flag number, + warnings ut_varchar2_rows, + before_all_list ut_executables, + after_all_list ut_executables, + before_each_list ut_executables, + before_test_list ut_executables, + after_each_list ut_executables, + after_test_list ut_executables, expected_error_codes ut_varchar2_rows, - tags ut_varchar2_rows, - item ut_executable_test + tags ut_varchar2_rows, + item ut_executable_test ) / \ No newline at end of file diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 05984da3f..7c4b1ee93 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -23,7 +23,7 @@ create or replace package body ut_suite_cache_manager is gc_get_cache_suite_sql constant varchar2(32767) := q'[with suite_items as ( - select /*+ cardinality(c 100) */ value(c) as obj + select /*+ cardinality(c 500) */ value(c) as obj from ut_suite_cache c where 1 = 1 and c.object_owner = :l_object_owner @@ -87,7 +87,7 @@ create or replace package body ut_suite_cache_manager is l_result ut_varchar2_rows; l_data ut_annotation_objs_cache_info; begin - l_data := ut_annotation_cache_manager.get_annotations_objects_info(a_object_owner, 'PACKAGE'); + l_data := ut_annotation_cache_manager.get_cached_objects_list(a_object_owner, 'PACKAGE'); select i.object_name bulk collect into l_result @@ -258,7 +258,7 @@ create or replace package body ut_suite_cache_manager is select min(t.parse_time) into l_cache_parse_time from ut_suite_cache_schema t - where object_owner = a_schema_name; + where object_owner = upper(a_schema_name); return l_cache_parse_time; end; @@ -380,13 +380,16 @@ create or replace package body ut_suite_cache_manager is pragma autonomous_transaction; begin l_objects := get_missing_cache_objects(a_schema_name); - delete from ut_suite_cache i - where i.object_owner = a_schema_name - and i.object_name in ( select column_value from table (l_objects) ); - delete from ut_suite_cache_package i - where i.object_owner = a_schema_name - and i.object_name in ( select column_value from table (l_objects) ); + if l_objects is not empty then + delete from ut_suite_cache i + where i.object_owner = a_schema_name + and i.object_name in ( select column_value from table (l_objects) ); + + delete from ut_suite_cache_package i + where i.object_owner = a_schema_name + and i.object_name in ( select column_value from table (l_objects) ); + end if; commit; end; @@ -459,5 +462,5 @@ create or replace package body ut_suite_cache_manager is return l_count > 0; end; -end ut_suite_cache_manager; +end; / diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 13f64d1bd..26de41e0e 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -512,9 +512,11 @@ create or replace package body ut_utils is procedure flush_lines(a_lines ut_varchar2_rows, a_offset integer) is begin - insert into ut_dbms_output_cache (seq_no,text) - select rownum+a_offset, column_value - from table(a_lines); + if a_lines is not empty then + insert into ut_dbms_output_cache (seq_no,text) + select rownum+a_offset, column_value + from table(a_lines); + end if; end; begin loop @@ -534,7 +536,7 @@ create or replace package body ut_utils is procedure read_cache_to_dbms_output is l_lines_data sys_refcursor; l_lines ut_varchar2_rows; - c_lines_limit constant integer := 1000; + c_lines_limit constant integer := 10000; pragma autonomous_transaction; begin open l_lines_data for select text from ut_dbms_output_cache order by seq_no; diff --git a/test/ut3_tester/core/annotations/test_annotation_manager.pkb b/test/ut3_tester/core/annotations/test_annotation_manager.pkb index d564e5d57..15bbee21a 100644 --- a/test/ut3_tester/core/annotations/test_annotation_manager.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_manager.pkb @@ -1,45 +1,45 @@ create or replace package body test_annotation_manager is - procedure disable_ddl_trigger is + procedure exec_autonomous(a_sql varchar2) is pragma autonomous_transaction; begin - execute immediate 'alter trigger ut3.ut_trigger_annotation_parsing disable'; - execute immediate 'begin ut3.ut_trigger_check.is_alive(); end;'; + execute immediate a_sql; + end; + + procedure disable_ddl_trigger is + begin + exec_autonomous('alter trigger ut3.ut_trigger_annotation_parsing disable'); + exec_autonomous('begin ut3.ut_trigger_check.is_alive(); end;'); end; procedure enable_ddl_trigger is - pragma autonomous_transaction; begin - execute immediate 'alter trigger ut3.ut_trigger_annotation_parsing enable'; + exec_autonomous('alter trigger ut3.ut_trigger_annotation_parsing enable'); end; procedure create_dummy_package is - pragma autonomous_transaction; begin - execute immediate q'[create or replace package dummy_package as + exec_autonomous(q'[create or replace package dummy_package as procedure some_dummy_procedure; - end;]'; + end;]'); end; procedure drop_dummy_package is - pragma autonomous_transaction; begin - execute immediate q'[drop package dummy_package]'; + exec_autonomous(q'[drop package dummy_package]'); exception when others then null; end; procedure recompile_dummy_package is - pragma autonomous_transaction; begin - execute immediate q'[alter package dummy_package compile]'; + exec_autonomous(q'[alter package dummy_package compile]'); end; procedure create_dummy_test_package is - pragma autonomous_transaction; begin - execute immediate q'[ + exec_autonomous(q'[ /* * Some multiline comments before package spec create or replace package dummy_test_package dummy comment to prove that we pick the right piece of code @@ -55,34 +55,31 @@ create or replace package body test_annotation_manager is --%test(dummy_test) --%beforetest(some_procedure) procedure some_dummy_test_procedure; - end;]'; - execute immediate q'[grant execute on dummy_test_package to public]'; + end;]'); + exec_autonomous(q'[grant execute on dummy_test_package to public]'); end; procedure modify_dummy_test_package is - pragma autonomous_transaction; begin - execute immediate q'[create or replace package dummy_test_package as + exec_autonomous(q'[create or replace package dummy_test_package as --%suite(dummy_test_suite) --%test(dummy_test) procedure some_dummy_test_procedure; - end;]'; + end;]'); end; procedure drop_dummy_test_package is - pragma autonomous_transaction; begin - execute immediate q'[drop package dummy_test_package]'; + exec_autonomous(q'[drop package dummy_test_package]'); exception when others then null; end; procedure recompile_dummy_test_package is - pragma autonomous_transaction; begin - execute immediate q'[alter package dummy_test_package compile]'; + exec_autonomous(q'[alter package dummy_test_package compile]'); end; procedure create_parse_proc_as_ut3$user# is @@ -128,35 +125,31 @@ create or replace package body test_annotation_manager is ut.expect(l_actual).to_be_empty(); end; - procedure assert_dummy_test_package(a_start_date date) is + procedure assert_dummy_test_package(a_start_time timestamp) is l_actual_cache_id integer; + l_data ut3.ut_annotated_objects; + l_result sys_refcursor; l_actual sys_refcursor; l_expected sys_refcursor; begin - select max(cache_id) - into l_actual_cache_id - from ut3.ut_annotation_cache_info - where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_TEST_PACKAGE' - and parse_time >= a_start_date; - ut.expect(l_actual_cache_id).to_be_not_null; - - open l_actual for - select annotation_position, annotation_name, annotation_text, subobject_name - from ut3.ut_annotation_cache where cache_id = l_actual_cache_id - order by annotation_position; - open l_expected for - select 2 as annotation_position, 'suite' as annotation_name, - 'dummy_test_suite' as annotation_text, '' as subobject_name - from dual union all - select 3, 'rollback' , 'manual', '' as subobject_name - from dual union all - select 7, 'test' , 'dummy_test', 'some_dummy_test_procedure' as subobject_name - from dual union all - select 8, 'beforetest' , 'some_procedure', 'some_dummy_test_procedure' as subobject_name - from dual; - - ut.expect(l_actual).to_equal(l_expected); + select + ut3.ut_annotated_object( + sys_context('USERENV', 'CURRENT_USER'), + 'DUMMY_TEST_PACKAGE', 'PACKAGE', a_start_time, + ut3.ut_annotations( + ut3.ut_annotation( 2, 'suite', 'dummy_test_suite', null ), + ut3.ut_annotation( 3, 'rollback', 'manual', null ), + ut3.ut_annotation( 7, 'test', 'dummy_test', 'some_dummy_test_procedure' ), + ut3.ut_annotation( 8, 'beforetest', 'some_procedure', 'some_dummy_test_procedure' ) + ) + ) annotated_object + from dual; + + l_result := ut3.ut_annotation_manager.get_annotated_objects(sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE', a_start_time); + fetch l_result bulk collect into l_data; + open l_actual for select value(x) as annotated_object from table(l_data) x where object_name = 'DUMMY_TEST_PACKAGE'; + ut.expect(l_actual).to_equal(l_expected).exclude('ANNOTATED_OBJECT/PARSE_TIME').join_by('ANNOTATED_OBJECT/OBJECT_NAME'); end; @@ -259,74 +252,123 @@ create or replace package body test_annotation_manager is end; - --%test(Updates annotation cache when package recompiled) - procedure trg_update_modified_package is + procedure trg_populate_cache_after_purge is + l_start_date date; begin - null; + --Arrange + create_dummy_test_package(); + l_start_date := sysdate; + ut3.ut_annotation_manager.purge_cache(sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE'); + --Act & Assert + assert_dummy_test_package(l_start_date); end; - procedure add_new_package is - l_actual_cache_id integer; - l_actual sys_refcursor; - l_start_date date; + procedure add_annotated_package is + l_start_time timestamp := systimestamp; begin + --Arrange + create_dummy_test_package(); + --Act & Assert + assert_dummy_test_package( l_start_time ); + end; + + procedure remove_annotated_package is + l_start_time timestamp := systimestamp; + begin + --Arrange + create_dummy_test_package(); + assert_dummy_test_package( l_start_time ); + --Act - l_start_date := sysdate; - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); + drop_dummy_test_package(); + --Assert - select max(cache_id) - into l_actual_cache_id - from ut3.ut_annotation_cache_info - where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_PACKAGE' - and parse_time >= l_start_date; + ut.expect( + ut3.ut_annotation_manager.get_annotated_objects( + sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time + ), + 'Annotations are empty after package was dropped' + ).to_be_empty(); + end; - ut.expect(l_actual_cache_id).to_be_not_null; + procedure add_not_annotated_package is + l_start_time timestamp := systimestamp; + begin + --Arrange + create_dummy_package(); + --Act & Assert + ut.expect( + ut3.ut_annotation_manager.get_annotated_objects( + sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time + ), + 'Annotations are empty for not annotated package' + ).to_be_empty(); + end; - open l_actual for - select * - from ut3.ut_annotation_cache - where cache_id = l_actual_cache_id; + procedure remove_not_annotated_package is + l_start_time timestamp := systimestamp; + begin + --Arrange + create_dummy_package(); + ut.expect( + ut3.ut_annotation_manager.get_annotated_objects( + sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time + ), + 'Annotations are empty for non annotated package' + ).to_be_empty(); - ut.expect(l_actual).to_be_empty(); + --Act + drop_dummy_package(); + --Assert + ut.expect( + ut3.ut_annotation_manager.get_annotated_objects( + sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time + ), + 'Annotations are empty after non annoteted package was dropped' + ).to_be_empty(); end; - procedure update_modified_package is - l_actual integer; - l_start_date date; + procedure remove_annotations_from_pkg is + l_start_time timestamp := systimestamp; begin --Arrange - l_start_date := sysdate; - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); - recompile_dummy_package(); - l_start_date := sysdate; - $if dbms_db_version.version >= 18 $then - dbms_session.sleep(1); - $else - dbms_lock.sleep(1); - $end + create_dummy_test_package(); + assert_dummy_test_package( l_start_time ); --Act - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); + exec_autonomous(q'[create or replace package dummy_test_package as + procedure some_dummy_test_procedure; + end;]'); + --Assert - assert_dummy_package(l_start_date); + ut.expect( + ut3.ut_annotation_manager.get_annotated_objects( + sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time + ) + ).to_be_empty(); end; - - procedure add_new_test_package is - l_actual sys_refcursor; - l_expected sys_refcursor; - l_start_date date; + procedure add_annotations_to_package is + l_start_time timestamp := systimestamp; begin --Arrange - l_start_date := sysdate; + exec_autonomous(q'[create or replace package dummy_test_package as + procedure some_dummy_test_procedure; + end;]'); + ut.expect( + ut3.ut_annotation_manager.get_annotated_objects( + sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time + ) + ).to_be_empty(); + --Act - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); + create_dummy_test_package(); + --Assert - assert_dummy_test_package(l_start_date); + assert_dummy_test_package( l_start_time ); end; - procedure update_modified_test_package is l_actual_cache_id integer; l_actual sys_refcursor; @@ -365,29 +407,35 @@ create or replace package body test_annotation_manager is procedure keep_dropped_data_in_cache is - l_actual sys_refcursor; - l_expected sys_refcursor; - l_start_date date; + l_cache_count integer; + l_start_date date; begin - parse_dummy_test_as_ut3$user#(); l_start_date := sysdate; + parse_dummy_test_as_ut3$user#(); drop_dummy_test_package(); --Act parse_dummy_test_as_ut3$user#(); --Assert - assert_dummy_test_package(l_start_date); + select count(1) + into l_cache_count + from ut3.ut_annotation_cache_info + where object_owner = sys_context('USERENV', 'CURRENT_USER') + and object_type = 'PACKAGE' + and object_name = 'DUMMY_TEST_PACKAGE' + and parse_time > l_start_date; + ut.expect( l_cache_count ).to_equal(1); end; procedure no_data_for_dropped_object is - l_result sys_refcursor; - l_data ut3.ut_annotated_objects; - l_actual sys_refcursor; + l_result sys_refcursor; + l_data ut3.ut_annotated_objects; + l_actual sys_refcursor; + l_start_time timestamp := systimestamp; begin --Arrange - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); drop_dummy_test_package(); --Act - l_result := ut3.ut_annotation_manager.get_annotated_objects(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); + l_result := ut3.ut_annotation_manager.get_annotated_objects( sys_context('USERENV', 'CURRENT_USER'),'PACKAGE', l_start_time ); fetch l_result bulk collect into l_data; open l_actual for select object_name from table(l_data) where object_name = 'DUMMY_TEST_PACKAGE'; --Assert @@ -396,13 +444,9 @@ create or replace package body test_annotation_manager is procedure cleanup_dropped_data_in_cache is l_cache_count integer; - l_actual sys_refcursor; - l_expected sys_refcursor; - l_start_date date; begin --Arrange ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); - l_start_date := sysdate; drop_dummy_test_package(); --Act ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); @@ -418,5 +462,16 @@ create or replace package body test_annotation_manager is end; + procedure populate_cache_after_purge is + l_start_date date; + begin + --Arrange + create_dummy_test_package(); + l_start_date := sysdate; + ut3.ut_annotation_manager.purge_cache(sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE'); + --Act & Assert + assert_dummy_test_package(l_start_date); + end; + end test_annotation_manager; / diff --git a/test/ut3_tester/core/annotations/test_annotation_manager.pks b/test/ut3_tester/core/annotations/test_annotation_manager.pks index fd5bc3410..cb0b85104 100644 --- a/test/ut3_tester/core/annotations/test_annotation_manager.pks +++ b/test/ut3_tester/core/annotations/test_annotation_manager.pks @@ -45,12 +45,13 @@ create or replace package test_annotation_manager is --%beforetest(create_dummy_test_package) procedure trg_no_data_for_dropped_object; - --%test(Updates annotation cache when package recompiled) - procedure trg_update_modified_package; + --%disabled(TODO) + --%test(Objects are populated on scan after cache was purged) + procedure trg_populate_cache_after_purge; --%endcontext - --%context(Without DDL trigger enabled) + --%context(Without DDL trigger) --%beforeall(disable_ddl_trigger) @@ -59,16 +60,29 @@ create or replace package test_annotation_manager is --%beforeeach(create_dummy_package) --%aftereach(drop_dummy_package) - --%test(Adds new package to annotation cache info when it is not unit test package) - procedure add_new_package; + --%test(Returns annotations when annotated package was created) + --%aftertest(drop_dummy_test_package) + procedure add_annotated_package; + + --%test(Doesn't return annotations when annotated package was removed) + --%aftertest(drop_dummy_test_package) + procedure remove_annotated_package; - --%test(Updates annotation cache info for modified package) - procedure update_modified_package; + --%test(Doesn't return annotations when package doesn't contain annotations) + --%aftertest(drop_dummy_package) + procedure add_not_annotated_package; - --%test(Adds annotations to cache for unit test package) - --%beforetest(create_dummy_test_package) + --%test(Doesn't return annotations when package without annotations was dropped) + --%aftertest(drop_dummy_package) + procedure remove_not_annotated_package; + + --%test(Doesn't return annotations when annotations removed from package) + --%aftertest(drop_dummy_test_package) + procedure remove_annotations_from_pkg; + + --%test(Returns annotations when annotations were added to package) --%aftertest(drop_dummy_test_package) - procedure add_new_test_package; + procedure add_annotations_to_package; --%test(Updates annotations in cache for modified test package) procedure update_modified_test_package; @@ -84,6 +98,9 @@ create or replace package test_annotation_manager is --%test(Remove object from cache when object dropped and user can see whole schema) procedure cleanup_dropped_data_in_cache; + --%test(Objects are populated on scan after cache was purged) + procedure populate_cache_after_purge; + --%endcontext end test_annotation_manager; diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index e693771b4..fd35adc70 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -1437,7 +1437,7 @@ end;]'; l_expected := ut3.ut_object_names( ut3.ut_object_name('UT3','SOME_TEST_PACKAGE') ); - l_actual := ut3_tester_helper.run_helper.get_object_name('UT3'); + l_actual := ut3_tester_helper.run_helper.get_schema_ut_packages('UT3'); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); end; @@ -1458,7 +1458,7 @@ end;]'; l_expected_message varchar2(500); begin l_expected_message := q'[ORA-20217: 'Suitepath exceeds 1000 CHAR on: UT3.DUMMY_LONG_TEST_PACKAGE,UT3.DUMMY_LONG_TEST_PACKAGE1'%]'; - l_actual := ut3_tester_helper.run_helper.get_object_name('UT3'); + l_actual := ut3_tester_helper.run_helper.get_schema_ut_packages('UT3'); ut.fail('Expected exception for suitpaths over 1k for two packages'); exception when others then diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index 9a9c8587f..70695977b 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -614,7 +614,7 @@ create or replace package body run_helper is execute immediate q'[drop package ut3.some_test_package]'; end; - function get_object_name(a_owner in varchar2) return ut3.ut_object_names is + function get_schema_ut_packages(a_owner in varchar2) return ut3.ut_object_names is begin return ut3.ut_suite_manager.get_schema_ut_packages(ut3.ut_varchar2_rows(a_owner)); end; diff --git a/test/ut3_tester_helper/run_helper.pks b/test/ut3_tester_helper/run_helper.pks index 0f5e5a925..03eb314a7 100644 --- a/test/ut3_tester_helper/run_helper.pks +++ b/test/ut3_tester_helper/run_helper.pks @@ -59,7 +59,7 @@ create or replace package run_helper is procedure drop_dummy_long_test_package; procedure create_ut3_suite; procedure drop_ut3_suite; - function get_object_name(a_owner in varchar2) return ut3.ut_object_names; + function get_schema_ut_packages(a_owner in varchar2) return ut3.ut_object_names; function ut_output_buffer_tmp return t_out_buff_tab pipelined; procedure delete_buffer; From 335e420f7a70eb60aed97909122da2c5ad91ef1a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 12 Nov 2019 01:09:13 +0000 Subject: [PATCH 036/887] Fixed loophole in privilege check. --- source/core/types/ut_executable_test.tpb | 2 +- source/core/ut_metadata.pkb | 2 +- source/core/ut_suite_manager.pkb | 5 ++++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index 89ab16dab..6f25ea1c8 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -160,7 +160,7 @@ create or replace type body ut_executable_test as l_fail_message := 'Expected one of exceptions ('||l_expected_error_codes||') but nothing was raised.'; else l_actual_error_no := regexp_substr(self.error_stack, '^[a-zA-Z]{3}(-[0-9]+)', subexpression=>1); - if not l_actual_error_no member of a_expected_error_codes then + if not l_actual_error_no member of a_expected_error_codes or l_actual_error_no is null then l_fail_message := 'Actual: '||l_actual_error_no||' was expected to '; if cardinality(a_expected_error_codes) > 1 then l_fail_message := l_fail_message || 'be one of: ('||l_expected_error_codes||')'; diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index 7859d6b3f..5448f1b5f 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -123,7 +123,7 @@ create or replace package body ut_metadata as function user_has_execute_any_proc return boolean is l_ut_owner varchar2(250) := ut_utils.ut_owner; begin - return is_object_visible(l_ut_owner||'.ut_utils'); + return is_object_visible(l_ut_owner||'.ut_utils') and sys_context('userenv','current_schema') != l_ut_owner; end; function is_object_visible(a_object_name varchar2) return boolean is diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index e71a51dc8..30bcd4db2 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -373,7 +373,10 @@ create or replace package body ut_suite_manager is a_owner_name varchar2 ) return boolean is begin - return sys_context( 'userenv', 'current_schema' ) = a_owner_name or ut_metadata.user_has_execute_any_proc() or ut_trigger_check.is_alive(); + return sys_context( 'userenv', 'current_schema' ) = a_owner_name or ut_metadata.user_has_execute_any_proc() + or ( ut_trigger_check.is_alive() + and ut_annotation_cache_manager.get_cache_schema_info(a_owner_name, 'PACKAGE').full_refresh_time is not null + ); end; procedure build_and_cache_suites( From 054c39fb522fd456aeb39545d395bb840296db7c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 16 Feb 2020 00:02:29 +0000 Subject: [PATCH 037/887] Fixed issues with new cursor-results compare query on 11g --- .../data_values/ut_compound_data_helper.pkb | 50 +++++++++---------- 1 file changed, 24 insertions(+), 26 deletions(-) diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 6a6b30a50..69ba90811 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -119,8 +119,6 @@ create or replace package body ut_compound_data_helper is || case when a_order_enforced then q'[ --column position is not matching (both when excluded extra/missing columns as well as when they are included) or (a_pos_nn != e_pos_nn and exp_col_pos != act_col_pos)]' - else - null end ||q'[ order by exp_col_pos, act_col_pos]' bulk collect into l_results using a_expected, a_actual; @@ -426,34 +424,34 @@ create or replace package body ut_compound_data_helper is end if; l_sql := q'[ with - exp_rows as( - select - exp_data_id, extract( exp_item_data, :column_path ) exp_item_data, item_no, diff_id - from ut_compound_data_diff_tmp - where diff_id = :diff_id - and exp_data_id = :self_guid - ), - act_rows as ( - select - act_data_id, extract( act_item_data, :column_path ) act_item_data, item_no, diff_id - from ut_compound_data_diff_tmp ucd - where diff_id = :diff_id - and ucd.act_data_id = :other_guid - ), exp_cols as ( select - exp_item_data, exp_data_id, item_no rn, rownum col_no, diff_id, + i.exp_item_data, i.exp_data_id, i.item_no rn, rownum col_no, i.diff_id, s.column_value col, s.column_value.getRootElement() col_name, - nvl(s.column_value.getclobval(),empty_clob()) col_val - from exp_rows i, + nvl( s.column_value.getclobval(), empty_clob() ) col_val + from ( + select + ucd.exp_data_id, extract( ucd.exp_item_data, :column_path ) exp_item_data, + ucd.item_no, ucd.diff_id + from ut_compound_data_diff_tmp ucd + where ucd.diff_id = :diff_id + and ucd.exp_data_id = :self_guid + ) i, table( xmlsequence( extract( i.exp_item_data, :extract_path ) ) ) s ), act_cols as ( select - act_item_data, act_data_id, item_no rn, rownum col_no, diff_id, + i.act_item_data, i.act_data_id, i.item_no rn, rownum col_no, i.diff_id, s.column_value col, s.column_value.getRootElement() col_name, - nvl(s.column_value.getclobval(),empty_clob()) col_val - from act_rows i, + nvl( s.column_value.getclobval(), empty_clob() ) col_val + from ( + select + ucd.act_data_id, extract( ucd.act_item_data, :column_path ) act_item_data, + ucd.item_no, ucd.diff_id + from ut_compound_data_diff_tmp ucd + where ucd.diff_id = :diff_id + and ucd.act_data_id = :other_guid + ) i, table( xmlsequence( extract( i.act_item_data, :extract_path ) ) ) s ), data_diff as ( @@ -496,7 +494,8 @@ create or replace package body ut_compound_data_helper is col_name from ( ]' || case when a_unordered then q'[ - select u.rn, u.diff_type, u.diffed_row, + select /*+ no_unnest */ + u.rn, u.diff_type, u.diffed_row, replace( extract( case when i.exp_data_id is null then i.act_item_data else i.exp_item_data end, :join_by ).getclobval(), chr(10) @@ -551,9 +550,8 @@ create or replace package body ut_compound_data_helper is end; execute immediate l_sql bulk collect into l_results - using l_exp_extract_xpath, a_diff_id, a_expected_dataset_guid, - l_act_extract_xpath, a_diff_id, a_actual_dataset_guid, - a_extract_path, a_extract_path, + using l_exp_extract_xpath, a_diff_id, a_expected_dataset_guid, a_extract_path, + l_act_extract_xpath, a_diff_id, a_actual_dataset_guid, a_extract_path, l_join_xpath, l_join_xpath, l_join_xpath, a_diff_id; return l_results; end; From b39c5be19044b75f112ad5c150e209c923c6dacb Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 17 Feb 2020 00:11:13 +0000 Subject: [PATCH 038/887] Added additional tests for annotation cache refresh with/without DDL trigger. Fixed issues found while testing the code. --- .travis/install.sh | 35 +- development/cleanup.sh | 5 + docs/userguide/install.md | 7 - .../ut_annotation_cache_manager.pkb | 9 +- source/core/ut_suite_manager.pkb | 11 +- test/install_ut3_tester_helper.sql | 4 + test/install_ut3_tester_tests.sql | 4 +- .../annotations/test_annotation_cache.pkb | 503 ++++++++++++++++++ .../annotations/test_annotation_cache.pks | 273 ++++++++++ .../annotations/test_annotation_manager.pkb | 23 +- .../annotations/test_annotation_manager.pks | 15 +- .../annotation_cache_helper.pkb | 167 ++++++ .../annotation_cache_helper.pks | 21 + 13 files changed, 1027 insertions(+), 50 deletions(-) create mode 100644 test/ut3_tester/core/annotations/test_annotation_cache.pkb create mode 100644 test/ut3_tester/core/annotations/test_annotation_cache.pks create mode 100644 test/ut3_tester_helper/annotation_cache_helper.pkb create mode 100644 test/ut3_tester_helper/annotation_cache_helper.pks diff --git a/.travis/install.sh b/.travis/install.sh index 4806105b1..dfcf63efb 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -74,12 +74,6 @@ PROMPT Creating $UT3_TESTER - Power-user for testing internal framework code create user $UT3_TESTER identified by "$UT3_TESTER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; grant create session, create procedure, create type, create table to $UT3_TESTER; -PROMPT Additional grants for disabling DDL trigger and testing parser without trigger enabled/present - -grant alter any trigger to $UT3_TESTER; -grant administer database trigger to $UT3_TESTER; -grant execute on dbms_lock to $UT3_TESTER; - PROMPT Granting $UT3_OWNER code to $UT3_TESTER begin @@ -98,7 +92,7 @@ end; PROMPT Granting $UT3_OWNER tables to $UT3_TESTER begin - for i in ( select table_name from all_tables t where owner = 'UT3' and nested = 'NO' and IOT_NAME is NULL) + for i in ( select table_name from all_tables t where owner = 'UT3' and nested = 'NO' and iot_name is null) loop execute immediate 'grant select on UT3.'||i.table_name||' to UT3_TESTER'; end loop; @@ -124,8 +118,33 @@ grant create public database link to $UT3_TESTER_HELPER; grant drop public database link to $UT3_TESTER_HELPER; PROMPT Grants for testing coverage outside of main UT3 schema. -grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type, select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table, select any dictionary, create any synonym, drop any synonym to $UT3_TESTER_HELPER; +grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type, + select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table, + select any dictionary, create any synonym, drop any synonym, + grant any object privilege, grant any privilege + to $UT3_TESTER_HELPER; + grant create job to $UT3_TESTER_HELPER; +PROMPT Additional grants for disabling DDL trigger and testing parser without trigger enabled/present + +grant alter any trigger to $UT3_TESTER_HELPER; +grant administer database trigger to $UT3_TESTER_HELPER; +grant execute on dbms_lock to $UT3_TESTER_HELPER; + +create user ut3_cache_test_owner identified by ut3; +grant create session, create procedure to ut3_cache_test_owner; + +create user ut3_no_extra_priv_user identified by ut3; +grant create session, create procedure to ut3_no_extra_priv_user; + +create user ut3_select_catalog_user identified by ut3; +grant create session, create procedure, select_catalog_role to ut3_select_catalog_user; + +create user ut3_select_any_table_user identified by ut3; +grant create session, create procedure, select any table to ut3_select_any_table_user; + +create user ut3_execute_any_proc_user identified by ut3; +grant create session, create procedure, execute any procedure to ut3_execute_any_proc_user; exit SQL diff --git a/development/cleanup.sh b/development/cleanup.sh index 313e382ca..4df1e43f5 100755 --- a/development/cleanup.sh +++ b/development/cleanup.sh @@ -23,6 +23,11 @@ drop user ${UT3_RELEASE_VERSION_SCHEMA} cascade; drop user ${UT3_TESTER} cascade; drop user ${UT3_TESTER_HELPER} cascade; drop user ${UT3_USER} cascade; +drop user ut3_cache_test_owner cascade; +drop user ut3_no_extra_priv_user cascade; +drop user ut3_select_catalog_user cascade; +drop user ut3_select_any_table_user cascade; +drop user ut3_execute_any_proc_user cascade; begin for i in ( diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 0a7a04b35..dd80f98ee 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -138,13 +138,6 @@ cd source sqlplus sys/sys_pass@db as sysdba @install_headless_with_trigger.sql utp3 my_verySecret_password utp3_tablespace ``` -**Note:** ->When installing utPLSQL into database with existing unit test packages, utPLSQL will not be able to already-existing unit test packages. When utPSLQL was installed with DDL trigger, you have to do one of: ->- Recompile existing Unit Test packages to make utPLSQL aware of their existence ->- Invoke `exec ut_runner.rebuild_annotation_cache(a_object_owner=> ... );` for every schema containing unit tests in your database -> -> Steps above are required to assure annotation cache is populated properly from existing objects. Rebuilding annotation cache might be faster than code recompilation. - # Recommended Schema It is highly recommended to install utPLSQL in it's own schema. You are free to choose any name for this schema. Installing uPLSQL into shared schema is really not recommended as you loose isolation of framework. diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index 6060d6a21..377dc4492 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -78,6 +78,7 @@ create or replace package body ut_annotation_cache_manager as on o.object_name = i.object_name and o.object_type = i.object_type and o.object_owner = i.object_owner + and o.needs_refresh = 'Y' ); update ut_annotation_cache_schema s @@ -86,18 +87,22 @@ create or replace package body ut_annotation_cache_manager as in ( select o.object_owner, o.object_type from table(a_objects) o + where o.needs_refresh = 'Y' ); if sql%rowcount = 0 then insert into ut_annotation_cache_schema s (object_owner, object_type, max_parse_time) select distinct o.object_owner, o.object_type, l_timestamp - from table(a_objects) o; + from table(a_objects) o + where o.needs_refresh = 'Y'; end if; merge into ut_annotation_cache_info i using (select o.object_name, o.object_type, o.object_owner - from table(a_objects) o ) o + from table(a_objects) o + where o.needs_refresh = 'Y' + ) o on (o.object_name = i.object_name and o.object_type = i.object_type and o.object_owner = i.object_owner) diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 30bcd4db2..ee5063105 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -363,7 +363,8 @@ create or replace package body ut_suite_manager is where a.object_name = c.object_name and a.owner = c.object_owner and a.object_type = 'PACKAGE' - ); + ) + or c.self_type = 'UT_LOGICAL_SUITE'; end if; return l_result; @@ -373,10 +374,7 @@ create or replace package body ut_suite_manager is a_owner_name varchar2 ) return boolean is begin - return sys_context( 'userenv', 'current_schema' ) = a_owner_name or ut_metadata.user_has_execute_any_proc() - or ( ut_trigger_check.is_alive() - and ut_annotation_cache_manager.get_cache_schema_info(a_owner_name, 'PACKAGE').full_refresh_time is not null - ); + return sys_context( 'userenv', 'current_schema' ) = a_owner_name or ut_metadata.user_has_execute_any_proc(); end; procedure build_and_cache_suites( @@ -611,6 +609,7 @@ create or replace package body ut_suite_manager is and a.owner = c.object_owner and a.object_type = 'PACKAGE' ) + or c.item_type = 'UT_LOGICAL_SUITE' order by c.object_owner, c.object_name, c.item_line_no; end if; return l_result; @@ -630,7 +629,7 @@ create or replace package body ut_suite_manager is refresh_cache(l_owner_name); l_item_exists := ut_suite_cache_manager.suite_item_exists( l_owner_name, l_package_name, l_procedure_name ); - if not can_skip_all_objects_scan( l_owner_name ) then + if not can_skip_all_objects_scan( l_owner_name ) and l_package_name is not null then select count(1) into l_count from dual c diff --git a/test/install_ut3_tester_helper.sql b/test/install_ut3_tester_helper.sql index c6244fd39..c0c20634e 100644 --- a/test/install_ut3_tester_helper.sql +++ b/test/install_ut3_tester_helper.sql @@ -26,6 +26,10 @@ alter session set plsql_optimize_level=0; @@ut3_tester_helper/expectations_helper.pkb @@ut3_tester_helper/ut_example_tests.pkb +@@ut3_tester_helper/annotation_cache_helper.pks +@@ut3_tester_helper/annotation_cache_helper.pkb +create or replace synonym ut3_tester.annotation_cache_helper for ut3_tester_helper.annotation_cache_helper; + set linesize 200 set define on set verify off diff --git a/test/install_ut3_tester_tests.sql b/test/install_ut3_tester_tests.sql index 6b3a5356c..9548d5148 100644 --- a/test/install_ut3_tester_tests.sql +++ b/test/install_ut3_tester_tests.sql @@ -13,6 +13,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core/annotations/test_annotation_parser.pks @@ut3_tester/core/annotations/test_annot_throws_exception.pks @@ut3_tester/core/annotations/test_annotation_manager.pks +@@ut3_tester/core/annotations/test_annotation_cache.pks @@ut3_tester/core/expectations/test_expectation_processor.pks @@ut3_tester/core/test_ut_utils.pks @@ut3_tester/core/test_ut_test.pks @@ -27,9 +28,10 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core.pkb @@ut3_tester/core/annotations/test_before_after_annotations.pkb @@ut3_tester/core/annotations/test_annotation_parser.pkb -@@ut3_tester/core/expectations/test_expectation_processor.pkb @@ut3_tester/core/annotations/test_annotation_manager.pkb @@ut3_tester/core/annotations/test_annot_throws_exception.pkb +@@ut3_tester/core/annotations/test_annotation_cache.pkb +@@ut3_tester/core/expectations/test_expectation_processor.pkb @@ut3_tester/core/test_ut_utils.pkb @@ut3_tester/core/test_ut_test.pkb @@ut3_tester/core/test_ut_suite.pkb diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pkb b/test/ut3_tester/core/annotations/test_annotation_cache.pkb new file mode 100644 index 000000000..983004eeb --- /dev/null +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pkb @@ -0,0 +1,503 @@ +create or replace package body test_annotation_cache is + + procedure cache_populated_for_packages(a_packages ut_varchar2_rows) is + l_actual_cache_info sys_refcursor; + l_expected_cache_info sys_refcursor; + begin + open l_actual_cache_info for + select * + from ut3.ut_annotation_cache_info + where object_owner = 'UT3_CACHE_TEST_OWNER'; + open l_expected_cache_info for + select 'UT3_CACHE_TEST_OWNER' as object_owner, upper( column_value ) as object_name, 'Y' as is_annotated + from table (a_packages) x; + ut.expect( l_actual_cache_info ).to_equal( l_expected_cache_info ).exclude( 'CACHE_ID,PARSE_TIME,OBJECT_TYPE' ).JOIN_BY('OBJECT_NAME'); + end; + + procedure can_run_one_package(a_user varchar2) is + l_actual clob; + l_current_time date := sysdate; + pragma autonomous_transaction; + begin + --Act + l_actual := annotation_cache_helper.run_tests_as( a_user ); + + --Assert - only granted_test_suite is invoked + ut.expect( l_actual ).to_be_like( 'granted_test_suite%2 tests, 0 failed%' ); + rollback; + end; + + procedure can_run_new_package(a_user varchar2) is + l_actual clob; + l_current_time date := sysdate; + pragma autonomous_transaction; + begin + --Arrange + l_actual := annotation_cache_helper.run_tests_as( a_user ); + annotation_cache_helper.add_new_suite( ); + --Act + l_actual := annotation_cache_helper.run_tests_as( a_user ); + --Assert -Both granted_test_suite and new_suite are invoked + ut.expect( l_actual ).to_be_like( 'granted_test_suite%new_suite%4 tests, 0 failed%' ); + rollback; + end ; + + procedure cant_run_revoked_package(a_user varchar2) is + l_actual clob; + l_current_time date := sysdate; + pragma autonomous_transaction; + begin + --Arrange + l_actual := annotation_cache_helper.run_tests_as( a_user ); + annotation_cache_helper.add_new_suite( ); + annotation_cache_helper.revoke_granted_suite( ); + + --Act + l_actual := annotation_cache_helper.run_tests_as( a_user ); + --Assert -Only new_suite gets invoked + ut.expect( l_actual ).to_be_like( 'new_suite%2 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s)%' ); + ut.expect( l_actual ).not_to_be_like( '%granted_test_suite%' ); + rollback; + end; + + procedure cant_run_dropped_package(a_user varchar2) is + l_actual clob; + l_current_time date := sysdate; + pragma autonomous_transaction; + begin + --Arrange + l_actual := annotation_cache_helper.run_tests_as( a_user ); + annotation_cache_helper.add_new_suite( ); + l_actual := annotation_cache_helper.run_tests_as( a_user ); + annotation_cache_helper.revoke_granted_suite( ); + annotation_cache_helper.cleanup_new_suite( ); + + --Act + l_actual := annotation_cache_helper.run_tests_as( a_user ); + --Assert - no test suites are invoked + ut.expect( l_actual ).to_be_like( '%0 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s)%' ); + ut.expect( l_actual ).not_to_be_like( '%new_suite%' ); + ut.expect( l_actual ).not_to_be_like( '%granted_test_suite%' ); + rollback; + end; + + procedure can_run_all_packages(a_user varchar2) is + l_actual clob; + l_current_time date := sysdate; + pragma autonomous_transaction; + begin + --Act + l_actual := annotation_cache_helper.run_tests_as( a_user ); + + --Assert - only granted_test_suite is invoked + ut.expect( l_actual ).to_be_like( 'granted_test_suite%not_granted_test_suite%4 tests, 0 failed%' ); + rollback; + end; + + procedure can_run_all_new_packages(a_user varchar2) is + l_actual clob; + l_current_time date := sysdate; + pragma autonomous_transaction; + begin + --Arrange + l_actual := annotation_cache_helper.run_tests_as( a_user ); + annotation_cache_helper.add_new_suite( ); + --Act + l_actual := annotation_cache_helper.run_tests_as( a_user ); + + --Assert - only granted_test_suite is invoked + ut.expect( l_actual ).to_be_like( 'granted_test_suite%new_suite%not_granted_test_suite% tests, 0 failed%' ); + rollback; + end; + + procedure can_run_revoked_packages(a_user varchar2) is + l_actual clob; + l_current_time date := sysdate; + pragma autonomous_transaction; + begin + --Arrange + l_actual := annotation_cache_helper.run_tests_as( a_user ); + annotation_cache_helper.add_new_suite( ); + annotation_cache_helper.revoke_granted_suite( ); + --Act + l_actual := annotation_cache_helper.run_tests_as( a_user ); + + --Assert - only granted_test_suite is invoked + ut.expect( l_actual ).to_be_like( 'granted_test_suite%new_suite%not_granted_test_suite% tests, 0 failed%' ); + rollback; + end; + + procedure can_run_all_but_dropped(a_user varchar2) is + l_actual clob; + l_current_time date := sysdate; + pragma autonomous_transaction; + begin + --Arrange + l_actual := annotation_cache_helper.run_tests_as( a_user ); + annotation_cache_helper.add_new_suite( ); + l_actual := annotation_cache_helper.run_tests_as( a_user ); + annotation_cache_helper.revoke_granted_suite( ); + annotation_cache_helper.cleanup_new_suite( ); + + --Act + l_actual := annotation_cache_helper.run_tests_as( a_user ); + --Assert - no test suites are invoked + ut.expect( l_actual ).to_be_like( 'granted_test_suite%not_granted_test_suite%4 tests, 0 failed%' ); + ut.expect( l_actual ).not_to_be_like( '%new_suite%' ); + rollback; + end; + + + procedure user_can_run_one_package is + begin + can_run_one_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE' ) ); + end; + + procedure user_can_run_new_package is + begin + can_run_new_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure user_cant_run_revoked_package is + begin + cant_run_revoked_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure user_cant_run_dropped_package is + begin + cant_run_dropped_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure sel_cat_user_can_run_one is + begin + can_run_one_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE' ) ); + end; + + procedure sel_cat_user_can_run_new is + begin + can_run_new_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure sel_cat_user_cant_run_revoked is + begin + cant_run_revoked_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure sel_cat_user_cant_run_dropped is + begin + cant_run_dropped_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure sel_any_user_can_run_one is + begin + can_run_one_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE' ) ); + end; + + procedure sel_any_user_can_run_new is + begin + can_run_new_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure sel_any_user_cant_run_revoked is + begin + cant_run_revoked_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure sel_any_user_cant_run_dropped is + begin + cant_run_dropped_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure exe_any_user_can_run_all is + begin + can_run_all_packages( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure exe_any_user_can_run_new is + begin + can_run_all_new_packages( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure exe_any_user_can_run_revoked is + begin + can_run_revoked_packages('ut3_execute_any_proc_user'); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure exe_any_user_cant_run_dropped is + begin + can_run_all_but_dropped('ut3_execute_any_proc_user'); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure owner_user_can_run_all is + begin + can_run_all_packages( 'ut3_cache_test_owner' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + + procedure owner_user_can_run_new is + begin + can_run_all_new_packages( 'ut3_cache_test_owner' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure owner_user_cant_run_dropped is + begin + can_run_all_but_dropped('ut3_cache_test_owner'); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + + procedure t_user_can_run_one_package is + begin + can_run_one_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_user_can_run_new_package is + begin + can_run_new_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_user_cant_run_revoked_pkg is + begin + cant_run_revoked_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_user_cant_run_dropped_pkg is + begin + cant_run_dropped_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_sel_cat_user_can_run_one is + begin + can_run_one_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_sel_cat_user_can_run_new is + begin + can_run_new_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_sel_cat_user_cant_run_revokd is + begin + cant_run_revoked_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_sel_cat_user_cant_run_dropd is + begin + cant_run_dropped_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + + procedure t_sel_any_user_can_run_one is + begin + can_run_one_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_sel_any_user_can_run_new is + begin + can_run_new_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_sel_any_user_cant_run_revokd is + begin + cant_run_revoked_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_sel_any_user_cant_run_dropd is + begin + cant_run_dropped_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + + procedure t_exe_any_user_can_run_all is + begin + can_run_all_packages( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_exe_any_user_can_run_new is + begin + can_run_all_new_packages( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_exe_any_user_can_run_revokd is + begin + can_run_revoked_packages( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_exe_any_user_cant_run_dropd is + begin + can_run_all_but_dropped( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_owner_user_can_run_all is + begin + can_run_all_packages( 'ut3_cache_test_owner' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_owner_user_can_run_new is + begin + can_run_all_new_packages( 'ut3_cache_test_owner' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure t_owner_user_cant_run_dropd is + begin + can_run_all_but_dropped( 'ut3_cache_test_owner' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + + + + procedure p_user_can_run_one_package is + begin + can_run_one_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE' ) ); + end; + + procedure p_user_can_run_new_package is + begin + can_run_new_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure p_user_cant_run_revoked_pack is + begin + cant_run_revoked_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure p_user_cant_run_dropped_pack is + begin + cant_run_dropped_package( 'ut3_no_extra_priv_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE' ) ); + end; + + + + procedure p_sel_cat_user_can_run_one is + begin + can_run_one_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE' ) ); + end; + + procedure p_sel_cat_user_can_run_new is + begin + can_run_new_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure p_sel_cat_user_cant_run_revokd is + begin + cant_run_revoked_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure p_sel_cat_user_cant_run_dropd is + begin + cant_run_dropped_package( 'ut3_select_catalog_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE' ) ); + end; + + procedure p_sel_any_user_can_run_one is + begin + can_run_one_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE' ) ); + end; + + procedure p_sel_any_user_can_run_new is + begin + can_run_new_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure p_sel_any_user_cant_run_revokd is + begin + cant_run_revoked_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE' ) ); + end; + + procedure p_sel_any_user_cant_run_dropd is + begin + cant_run_dropped_package( 'ut3_select_any_table_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE' ) ); + end; + + procedure p_exe_any_user_can_run_all is + begin + can_run_all_packages( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure p_exe_any_user_can_run_new is + begin + can_run_all_new_packages( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure p_exe_any_user_can_run_revokd is + begin + can_run_revoked_packages( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure p_exe_any_user_cant_run_dropd is + begin + can_run_all_but_dropped( 'ut3_execute_any_proc_user' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure p_owner_user_can_run_all is + begin + can_run_all_packages( 'ut3_cache_test_owner' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure p_owner_user_can_run_new is + begin + can_run_all_new_packages( 'ut3_cache_test_owner' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NEW_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + + procedure p_owner_user_cant_run_dropped is + begin + can_run_all_but_dropped( 'ut3_cache_test_owner' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; + +end; +/ diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pks b/test/ut3_tester/core/annotations/test_annotation_cache.pks new file mode 100644 index 000000000..f44b816e1 --- /dev/null +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pks @@ -0,0 +1,273 @@ +create or replace package test_annotation_cache is + + --%suite(annotation cache) + --%suitepath(utplsql.ut3_tester.core.annotations) + --%beforeall(annotation_cache_helper.create_run_function_for_users) + --%afterall(annotation_cache_helper.drop_run_function_for_users) + + --%context(With DDL trigger enabled) + + --%beforeall(annotation_cache_helper.enable_ddl_trigger) + --%beforeeach(annotation_cache_helper.setup_two_suites) + --%aftereach(annotation_cache_helper.cleanup_new_suite) + --%afterall(annotation_cache_helper.cleanup_two_suites) + + --%context(User without elevated privileges) + + --%test(Can only execute granted packages) + procedure t_user_can_run_one_package; + + --%test(Can see newly created packages as they are added) + procedure t_user_can_run_new_package; + + --%test(Cannot execute revoked packages) + procedure t_user_cant_run_revoked_pkg; + + --%test(Cannot execute dropped unit test packages) + procedure t_user_cant_run_dropped_pkg; + + --%endcontext + + --%context(User with select_catalog_role) + + --%test(Can only execute granted packages) + procedure t_sel_cat_user_can_run_one; + + --%test(Can see newly created packages as they are added) + procedure t_sel_cat_user_can_run_new; + + --%test(Cannot execute revoked packages) + procedure t_sel_cat_user_cant_run_revokd; + + --%test(Cannot execute dropped unit test packages) + procedure t_sel_cat_user_cant_run_dropd; + + --%endcontext + + --%context(User with select any table privilege) + + --%test(Can only execute granted packages) + procedure t_sel_any_user_can_run_one; + + --%test(Can see newly created packages as they are added) + procedure t_sel_any_user_can_run_new; + + --%test(Cannot execute revoked packages) + procedure t_sel_any_user_cant_run_revokd; + + --%test(Cannot execute dropped unit test packages) + procedure t_sel_any_user_cant_run_dropd; + + --%endcontext + + --%context(User with execute any procedure) + + --%test(Can execute and see all unit test packages) + procedure t_exe_any_user_can_run_all; + + --%test(Can see newly created packages as they are added) + procedure t_exe_any_user_can_run_new; + + --%test(Can execute revoked packages) + procedure t_exe_any_user_can_run_revokd; + + --%test(Cannot execute dropped unit test packages) + procedure t_exe_any_user_cant_run_dropd; + + --%endcontext + + --%context(User owning test packages) + + --%test(Can execute and see all unit test packages) + procedure t_owner_user_can_run_all; + + --%test(Can see newly created packages as they are added) + procedure t_owner_user_can_run_new; + + --%test(Cannot execute dropped unit test packages) + procedure t_owner_user_cant_run_dropd; + + --%endcontext + + --%endcontext + + --%context(With DDL trigger disabled) + + --%beforeall(annotation_cache_helper.disable_ddl_trigger) + --%beforeeach(annotation_cache_helper.setup_two_suites) + --%beforeeach(annotation_cache_helper.purge_annotation_cache) + --%aftereach(annotation_cache_helper.cleanup_new_suite) + --%afterall(annotation_cache_helper.enable_ddl_trigger) + --%afterall(annotation_cache_helper.cleanup_two_suites) + + --%context(User without elevated privileges) + + --%test(Can only execute granted packages) + procedure user_can_run_one_package; + + --%test(Can see newly created packages as they are added) + procedure user_can_run_new_package; + + --%test(Cannot execute revoked packages) + procedure user_cant_run_revoked_package; + + --%test(Cannot execute dropped unit test packages) + procedure user_cant_run_dropped_package; + + --%endcontext + + --%context(User with select_catalog_role) + + --%test(Can only execute granted packages) + procedure sel_cat_user_can_run_one; + + --%test(Can see newly created packages as they are added) + procedure sel_cat_user_can_run_new; + + --%test(Cannot execute revoked packages) + procedure sel_cat_user_cant_run_revoked; + + --%test(Cannot execute dropped unit test packages) + procedure sel_cat_user_cant_run_dropped; + + --%endcontext + + --%context(User with select any table privilege) + + --%test(Can only execute granted packages) + procedure sel_any_user_can_run_one; + + --%test(Can see newly created packages as they are added) + procedure sel_any_user_can_run_new; + + --%test(Cannot execute revoked packages) + procedure sel_any_user_cant_run_revoked; + + --%test(Cannot execute dropped unit test packages) + procedure sel_any_user_cant_run_dropped; + + --%endcontext + + --%context(User with execute any procedure) + + --%test(Can execute and see all unit test packages) + procedure exe_any_user_can_run_all; + + --%test(Can see newly created packages as they are added) + procedure exe_any_user_can_run_new; + + --%test(Can execute revoked packages) + procedure exe_any_user_can_run_revoked; + + --%test(Cannot execute dropped unit test packages) + procedure exe_any_user_cant_run_dropped; + + --%endcontext + + --%context(User owning test packages) + + --%test(Can execute and see all unit test packages) + procedure owner_user_can_run_all; + + --%test(Can see newly created packages as they are added) + procedure owner_user_can_run_new; + + --%test(Cannot execute dropped unit test packages) + procedure owner_user_cant_run_dropped; + + --%endcontext + + --%endcontext + + --%context(With DDL trigger enabled and cache purged) + + --%beforeall(annotation_cache_helper.enable_ddl_trigger) + + --%beforeeach(annotation_cache_helper.setup_two_suites) + --%beforeeach(annotation_cache_helper.purge_annotation_cache) + + --%aftereach(annotation_cache_helper.cleanup_new_suite) + --%aftereach(annotation_cache_helper.cleanup_two_suites) + + --%context(User without elevated privileges) + + --%test(Can only execute granted packages) + procedure p_user_can_run_one_package; + + --%test(Can see newly created packages as they are added) + procedure p_user_can_run_new_package; + + --%test(Cannot execute revoked packages) + procedure p_user_cant_run_revoked_pack; + + --%test(Cannot execute dropped unit test packages) + procedure p_user_cant_run_dropped_pack; + + --%endcontext + + --%context(User with select_catalog_role) + + --%test(Can only execute granted packages) + procedure p_sel_cat_user_can_run_one; + + --%test(Can see newly created packages as they are added) + procedure p_sel_cat_user_can_run_new; + + --%test(Cannot execute revoked packages) + procedure p_sel_cat_user_cant_run_revokd; + + --%test(Cannot execute dropped unit test packages) + procedure p_sel_cat_user_cant_run_dropd; + + --%endcontext + + --%context(User with select any table privilege) + + --%test(Can only execute granted packages) + procedure p_sel_any_user_can_run_one; + + --%test(Can see newly created packages as they are added) + procedure p_sel_any_user_can_run_new; + + --%test(Cannot execute revoked packages) + procedure p_sel_any_user_cant_run_revokd; + + --%test(Cannot execute dropped unit test packages) + procedure p_sel_any_user_cant_run_dropd; + + --%endcontext + + --%context(User with execute any procedure) + + --%test(Can execute and see all unit test packages) + procedure p_exe_any_user_can_run_all; + + --%test(Can see newly created packages as they are added) + procedure p_exe_any_user_can_run_new; + + --%test(Can execute revoked packages) + procedure p_exe_any_user_can_run_revokd; + + --%test(Cannot execute dropped unit test packages) + procedure p_exe_any_user_cant_run_dropd; + + --%endcontext + + --%context(User owning test packages) + + --%test(Can execute and see all unit test packages) + procedure p_owner_user_can_run_all; + + --%test(Can see newly created packages as they are added) + procedure p_owner_user_can_run_new; + + --%test(Cannot execute dropped unit test packages) + procedure p_owner_user_cant_run_dropped; + + --%endcontext + + + --%endcontext + +end; +/ diff --git a/test/ut3_tester/core/annotations/test_annotation_manager.pkb b/test/ut3_tester/core/annotations/test_annotation_manager.pkb index 15bbee21a..8a3efc508 100644 --- a/test/ut3_tester/core/annotations/test_annotation_manager.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_manager.pkb @@ -6,17 +6,6 @@ create or replace package body test_annotation_manager is execute immediate a_sql; end; - procedure disable_ddl_trigger is - begin - exec_autonomous('alter trigger ut3.ut_trigger_annotation_parsing disable'); - exec_autonomous('begin ut3.ut_trigger_check.is_alive(); end;'); - end; - - procedure enable_ddl_trigger is - begin - exec_autonomous('alter trigger ut3.ut_trigger_annotation_parsing enable'); - end; - procedure create_dummy_package is begin exec_autonomous(q'[create or replace package dummy_package as @@ -157,10 +146,10 @@ create or replace package body test_annotation_manager is l_actual_cache_id integer; begin --Arrange - disable_ddl_trigger(); + annotation_cache_helper.disable_ddl_trigger(); create_dummy_test_package(); --Act - enable_ddl_trigger(); + annotation_cache_helper.enable_ddl_trigger(); --Assert select max(cache_id) into l_actual_cache_id @@ -175,10 +164,10 @@ create or replace package body test_annotation_manager is l_start_date date; begin --Arrange - disable_ddl_trigger(); + annotation_cache_helper.disable_ddl_trigger(); create_dummy_test_package(); --Act - enable_ddl_trigger(); + annotation_cache_helper.enable_ddl_trigger(); l_start_date := sysdate; recompile_dummy_test_package(); --Assert @@ -190,11 +179,11 @@ create or replace package body test_annotation_manager is l_start_date date; begin --Arrange - disable_ddl_trigger(); + annotation_cache_helper.disable_ddl_trigger(); create_dummy_test_package(); create_dummy_package(); --Act - enable_ddl_trigger(); + annotation_cache_helper.enable_ddl_trigger(); l_start_date := sysdate; ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); --Assert diff --git a/test/ut3_tester/core/annotations/test_annotation_manager.pks b/test/ut3_tester/core/annotations/test_annotation_manager.pks index cb0b85104..5d7464fd2 100644 --- a/test/ut3_tester/core/annotations/test_annotation_manager.pks +++ b/test/ut3_tester/core/annotations/test_annotation_manager.pks @@ -3,13 +3,11 @@ create or replace package test_annotation_manager is --%suite(ut_annotation_manager) --%suitepath(utplsql.ut3_tester.core.annotations) + --%afterall(drop_dummy_test_package) + --%aftereach procedure cleanup_annotation_cache; - procedure disable_ddl_trigger; - - procedure enable_ddl_trigger; - procedure create_dummy_package; procedure drop_dummy_package; @@ -45,17 +43,18 @@ create or replace package test_annotation_manager is --%beforetest(create_dummy_test_package) procedure trg_no_data_for_dropped_object; - --%disabled(TODO) --%test(Objects are populated on scan after cache was purged) + --%beforetest(annotation_cache_helper.disable_ddl_trigger) + --%aftertest(annotation_cache_helper.enable_ddl_trigger) procedure trg_populate_cache_after_purge; --%endcontext --%context(Without DDL trigger) - --%beforeall(disable_ddl_trigger) + --%beforeall(annotation_cache_helper.disable_ddl_trigger) - --%afterall(enable_ddl_trigger) + --%afterall(annotation_cache_helper.enable_ddl_trigger) --%beforeeach(create_dummy_package) --%aftereach(drop_dummy_package) @@ -69,11 +68,9 @@ create or replace package test_annotation_manager is procedure remove_annotated_package; --%test(Doesn't return annotations when package doesn't contain annotations) - --%aftertest(drop_dummy_package) procedure add_not_annotated_package; --%test(Doesn't return annotations when package without annotations was dropped) - --%aftertest(drop_dummy_package) procedure remove_not_annotated_package; --%test(Doesn't return annotations when annotations removed from package) diff --git a/test/ut3_tester_helper/annotation_cache_helper.pkb b/test/ut3_tester_helper/annotation_cache_helper.pkb new file mode 100644 index 000000000..0d56823df --- /dev/null +++ b/test/ut3_tester_helper/annotation_cache_helper.pkb @@ -0,0 +1,167 @@ +create or replace package body annotation_cache_helper as + + procedure setup_two_suites is + pragma autonomous_transaction; + begin + execute immediate + 'create or replace package ut3_cache_test_owner.granted_test_suite is + --%suite + + --%test + procedure test1; + --%test + procedure test2; + end;'; + + execute immediate + 'create or replace package body ut3_cache_test_owner.granted_test_suite is + procedure test1 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; + procedure test2 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; + end;'; + execute immediate + 'create or replace package ut3_cache_test_owner.not_granted_test_suite is + --%suite + + --%test + procedure test1; + --%test + procedure test2; + end;'; + execute immediate + 'create or replace package body ut3_cache_test_owner.not_granted_test_suite is + procedure test1 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; + procedure test2 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; + end;'; + + execute immediate + 'grant execute on ut3_cache_test_owner.granted_test_suite to + ut3_execute_any_proc_user, ut3_select_any_table_user, ut3_select_catalog_user, ut3_no_extra_priv_user'; + end; + + procedure revoke_granted_suite is + pragma autonomous_transaction; + begin + execute immediate + 'revoke execute on ut3_cache_test_owner.granted_test_suite from + ut3_execute_any_proc_user, ut3_select_any_table_user, ut3_select_catalog_user, ut3_no_extra_priv_user'; + exception + when others then + null; + end; + + + procedure add_new_suite is + pragma autonomous_transaction; + begin + execute immediate + 'create or replace package ut3_cache_test_owner.new_suite is + --%suite + + --%test + procedure test1; + --%test + procedure test2; + end;'; + + execute immediate + 'create or replace package body ut3_cache_test_owner.new_suite is + procedure test1 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; + procedure test2 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; + end;'; + execute immediate + 'grant execute on ut3_cache_test_owner.new_suite to + ut3_execute_any_proc_user, ut3_select_any_table_user, ut3_select_catalog_user, ut3_no_extra_priv_user'; + end; + + procedure cleanup_two_suites is + pragma autonomous_transaction; + begin + begin + execute immediate 'drop package ut3_cache_test_owner.not_granted_test_suite'; + exception + when others then + null; + end; + begin + execute immediate 'drop package ut3_cache_test_owner.granted_test_suite'; + exception + when others then + null; + end; + end; + + procedure cleanup_new_suite is + pragma autonomous_transaction; + begin + execute immediate 'drop package ut3_cache_test_owner.new_suite'; + exception + when others then + null; + end; + + procedure purge_annotation_cache is + begin + ut3.ut_runner.purge_cache( 'UT3_CACHE_TEST_OWNER' ); + end; + + + procedure disable_ddl_trigger is + pragma autonomous_transaction; + begin + execute immediate 'alter trigger ut3.ut_trigger_annotation_parsing disable'; + execute immediate 'begin ut3.ut_trigger_check.is_alive( ); end;'; + end; + + procedure enable_ddl_trigger is + pragma autonomous_transaction; + begin + execute immediate 'alter trigger ut3.ut_trigger_annotation_parsing enable'; + end; + + procedure create_run_function_for_user(a_user varchar2) is + pragma autonomous_transaction; + begin + execute immediate + 'create or replace function ' || a_user || '.ut_run return clob is + l_data ut3.ut_varchar2_list; + l_results clob; + begin + select * bulk collect into l_data from table (ut3.ut.run( ''ut3_cache_test_owner'' )); + return ut3_tester_helper.main_helper.table_to_clob( l_data ); + end; + '; + execute immediate 'grant execute on ' || a_user || '.ut_run to public '; + end; + + procedure drop_run_function_for_user(a_user varchar2) is + pragma autonomous_transaction; + begin + execute immediate 'drop function ' || a_user || '.ut_run'; + end; + + procedure create_run_function_for_users is + begin + create_run_function_for_user( 'ut3_no_extra_priv_user' ); + create_run_function_for_user( 'ut3_select_catalog_user' ); + create_run_function_for_user( 'ut3_select_any_table_user' ); + create_run_function_for_user( 'ut3_execute_any_proc_user' ); + create_run_function_for_user( 'ut3_cache_test_owner' ); + end; + + procedure drop_run_function_for_users is + begin + drop_run_function_for_user( 'ut3_no_extra_priv_user' ); + drop_run_function_for_user( 'ut3_select_catalog_user' ); + drop_run_function_for_user( 'ut3_select_any_table_user' ); + drop_run_function_for_user( 'ut3_execute_any_proc_user' ); + drop_run_function_for_user( 'ut3_cache_test_owner' ); + end; + + function run_tests_as(a_user varchar2) return clob is + l_results clob; + begin + execute immediate 'begin :x := '||a_user||'.ut_run; end;' using out l_results; + return l_results; + end; +end; +/ \ No newline at end of file diff --git a/test/ut3_tester_helper/annotation_cache_helper.pks b/test/ut3_tester_helper/annotation_cache_helper.pks new file mode 100644 index 000000000..d6ab1f8e2 --- /dev/null +++ b/test/ut3_tester_helper/annotation_cache_helper.pks @@ -0,0 +1,21 @@ +create or replace package annotation_cache_helper as + + procedure setup_two_suites; + procedure add_new_suite; + procedure revoke_granted_suite; + + procedure cleanup_two_suites; + procedure cleanup_new_suite; + + procedure purge_annotation_cache; + + procedure disable_ddl_trigger; + procedure enable_ddl_trigger; + + procedure create_run_function_for_users; + procedure drop_run_function_for_users; + + function run_tests_as(a_user varchar2) return clob; + +end; +/ \ No newline at end of file From 5eab4aaf4d06e8e9fb914690a6bd42a05f33e75b Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 18 Feb 2020 01:08:18 +0000 Subject: [PATCH 039/887] Fixed Teamcity reporting of errors Resolves #1045 --- source/reporters/ut_teamcity_reporter.tpb | 4 ++-- test/ut3_user/reporters/test_teamcity_reporter.pkb | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/source/reporters/ut_teamcity_reporter.tpb b/source/reporters/ut_teamcity_reporter.tpb index ee0a53098..9475c0a90 100644 --- a/source/reporters/ut_teamcity_reporter.tpb +++ b/source/reporters/ut_teamcity_reporter.tpb @@ -74,7 +74,7 @@ create or replace type body ut_teamcity_reporter is begin l_idx := a_executables.first; while l_idx is not null loop - l_message := l_message || add_error_message(a_executables(l_idx).error_backtrace, a_message_name); + l_message := l_message || add_error_message( a_executables(l_idx).get_error_stack_trace(), a_message_name ); l_idx := a_executables.next(l_idx); end loop; return l_message; @@ -92,7 +92,7 @@ create or replace type body ut_teamcity_reporter is if a_test.result = ut_utils.gc_error then l_std_err_msg := l_std_err_msg || add_error_messages(a_test.before_each_list, 'Before each exception:'); l_std_err_msg := l_std_err_msg || add_error_messages(a_test.before_test_list, 'Before test exception:'); - l_std_err_msg := l_std_err_msg || add_error_message(a_test.item.error_backtrace, 'Test exception:'); + l_std_err_msg := l_std_err_msg || add_error_message(a_test.item.get_error_stack_trace(), 'Test exception:'); l_std_err_msg := l_std_err_msg || add_error_messages(a_test.after_test_list, 'After test exception:'); l_std_err_msg := l_std_err_msg || add_error_messages(a_test.after_each_list, 'After each exception:'); diff --git a/test/ut3_user/reporters/test_teamcity_reporter.pkb b/test/ut3_user/reporters/test_teamcity_reporter.pkb index 71d2f857d..032399aee 100644 --- a/test/ut3_user/reporters/test_teamcity_reporter.pkb +++ b/test/ut3_user/reporters/test_teamcity_reporter.pkb @@ -63,8 +63,8 @@ create or replace package body test_teamcity_reporter as -%##teamcity[testStdErr timestamp='%' name='ut3$user#.test_reporters.erroring_test' out='Test exception:|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|n|n'] -%##teamcity[testFailed timestamp='%' details='Test exception:|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|n|n' message='Error occured' name='ut3$user#.test_reporters.erroring_test'] +%##teamcity[testStdErr timestamp='%' name='ut3$user#.test_reporters.erroring_test' out='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|nORA-06512: at %|n'] +%##teamcity[testFailed timestamp='%' details='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|nORA-06512: at %|n' message='Error occured' name='ut3$user#.test_reporters.erroring_test'] %##teamcity[testFinished timestamp='%' duration='%' name='ut3$user#.test_reporters.erroring_test'] %##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3$user#.test_reporters.disabled_test'] %##teamcity[testIgnored timestamp='%' name='ut3$user#.test_reporters.disabled_test'] From 641b3b460798012207fc4a2433b1b937d895d21c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 18 Feb 2020 01:30:09 +0000 Subject: [PATCH 040/887] Update install.sh --- .travis/install.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.travis/install.sh b/.travis/install.sh index dfcf63efb..2e96ebfb2 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -74,6 +74,8 @@ PROMPT Creating $UT3_TESTER - Power-user for testing internal framework code create user $UT3_TESTER identified by "$UT3_TESTER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; grant create session, create procedure, create type, create table to $UT3_TESTER; +grant execute on dbms_lock to $UT3_TESTER; + PROMPT Granting $UT3_OWNER code to $UT3_TESTER begin From 67c4e7816b453824722391d79bcee634af5bfda4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 18 Feb 2020 01:33:23 +0000 Subject: [PATCH 041/887] Update test_teamcity_reporter.pkb --- test/ut3_user/reporters/test_teamcity_reporter.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/ut3_user/reporters/test_teamcity_reporter.pkb b/test/ut3_user/reporters/test_teamcity_reporter.pkb index 032399aee..a5261d7f9 100644 --- a/test/ut3_user/reporters/test_teamcity_reporter.pkb +++ b/test/ut3_user/reporters/test_teamcity_reporter.pkb @@ -63,8 +63,8 @@ create or replace package body test_teamcity_reporter as -%##teamcity[testStdErr timestamp='%' name='ut3$user#.test_reporters.erroring_test' out='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|nORA-06512: at %|n'] -%##teamcity[testFailed timestamp='%' details='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|nORA-06512: at %|n' message='Error occured' name='ut3$user#.test_reporters.erroring_test'] +%##teamcity[testStdErr timestamp='%' name='ut3$user#.test_reporters.erroring_test' out='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|n'] +%##teamcity[testFailed timestamp='%' details='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|n' message='Error occured' name='ut3$user#.test_reporters.erroring_test'] %##teamcity[testFinished timestamp='%' duration='%' name='ut3$user#.test_reporters.erroring_test'] %##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3$user#.test_reporters.disabled_test'] %##teamcity[testIgnored timestamp='%' name='ut3$user#.test_reporters.disabled_test'] From 3c0351f25bbb5692dab42c49b5be1e17813dbfb7 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 18 Feb 2020 08:51:02 +0000 Subject: [PATCH 042/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 245d8504c..e1bcfa633 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 5f5295da8..97c065fe2 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 73498a628..6c2b47ac0 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 34f990b6f..92b0ca1d4 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index c15e45936..4a7e105b7 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index d357cbd8c..431ec1493 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 4c398a4a4..dc61b998c 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 87f4f9519..2ad5aa9cb 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index e1a9e09d1..4f0ba15ec 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 624dba1ee..a0fc1981b 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 93b0f1258..c9b2bf362 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index e37920255..8df1d7aa2 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 0a7a04b35..823426318 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index b6ef0def6..cdd7d5230 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3399c5c72..a046affea 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 3ce5daace..f050c9417 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 66617cb2e..c7e566681 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3327--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 13f64d1bd..4b7747dfa 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -767,7 +767,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3327-develop + * secion v3.1.10.3342-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 3b23edad0..6a3c2cebd 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3327-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3342-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 29b6db484f1b042b91cf18496fcbd18e5c2d35c3 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 18 Feb 2020 09:27:06 +0000 Subject: [PATCH 043/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index e1bcfa633..da8a160ba 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 97c065fe2..92742a4a4 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 6c2b47ac0..4df80bc5c 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 92b0ca1d4..f009b0c32 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 4a7e105b7..f1253349b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 431ec1493..4cb07e043 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index dc61b998c..e606a4caf 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 2ad5aa9cb..592eae131 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4f0ba15ec..00c568012 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a0fc1981b..9f06ff7c0 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c9b2bf362..8842461eb 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8df1d7aa2..df5f8d9d1 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 823426318..3a292a670 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index cdd7d5230..a2e4856e7 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index a046affea..bc642b035 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index f050c9417..295df814e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index c7e566681..6aeee036d 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 4b7747dfa..2986a3707 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -767,7 +767,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3342-develop + * secion v3.1.10.3343-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6a3c2cebd..73884bdca 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3342-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3343-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 5d4c33c8c74bcf2479e16a961a2b39f7e430b04f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 22 Feb 2020 14:16:44 +0000 Subject: [PATCH 044/887] Removed unneeded `is_annotated` column --- .../annotations/ut_annotation_cache_info.sql | 2 -- .../annotations/ut_annotation_cache_manager.pkb | 16 ++++++---------- .../core/annotations/test_annotation_cache.pkb | 2 +- 3 files changed, 7 insertions(+), 13 deletions(-) diff --git a/source/core/annotations/ut_annotation_cache_info.sql b/source/core/annotations/ut_annotation_cache_info.sql index e0781cab7..7bbf99e00 100644 --- a/source/core/annotations/ut_annotation_cache_info.sql +++ b/source/core/annotations/ut_annotation_cache_info.sql @@ -17,8 +17,6 @@ create table ut_annotation_cache_info ( object_name varchar2(250) not null, object_type varchar2(250) not null, parse_time timestamp not null, - is_annotated varchar2(1) not null, - constraint ut_annotation_cache_info_ck1 check(is_annotated in ('Y','N')), constraint ut_annotation_cache_info_pk primary key(cache_id) using index, constraint ut_annotation_cache_info_uk unique (object_owner, object_type, object_name) using index, constraint ut_annotation_cache_info_fk foreign key(object_owner, object_type) references ut_annotation_cache_schema(object_owner, object_type) on delete cascade diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index 377dc4492..4882108fc 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -35,8 +35,7 @@ create or replace package body ut_annotation_cache_manager as if ora_sysevent is null or a_object.annotations is not null and a_object.annotations.count > 0 then update ut_annotation_cache_info i - set i.parse_time = l_timestamp, - i.is_annotated = case when a_object.annotations is not empty then 'Y' else 'N' end + set i.parse_time = l_timestamp where (i.object_owner, i.object_name, i.object_type) in ((a_object.object_owner, a_object.object_name, a_object.object_type)) returning cache_id into l_cache_id; @@ -44,10 +43,8 @@ create or replace package body ut_annotation_cache_manager as if sql%rowcount = 0 then insert into ut_annotation_cache_info - (cache_id, object_owner, object_name, object_type, parse_time, is_annotated) - values (ut_annotation_cache_seq.nextval, a_object.object_owner, a_object.object_name, a_object.object_type, l_timestamp, - case when a_object.annotations is not empty then 'Y' else 'N' end - ) + (cache_id, object_owner, object_name, object_type, parse_time) + values (ut_annotation_cache_seq.nextval, a_object.object_owner, a_object.object_name, a_object.object_type, l_timestamp) returning cache_id into l_cache_id; end if; @@ -108,11 +105,10 @@ create or replace package body ut_annotation_cache_manager as and o.object_owner = i.object_owner) when matched then update - set parse_time = l_timestamp, - is_annotated = 'N' + set parse_time = l_timestamp when not matched then insert - (cache_id, object_owner, object_name, object_type, parse_time, is_annotated) - values (ut_annotation_cache_seq.nextval, o.object_owner, o.object_name, o.object_type, l_timestamp, 'N'); + (cache_id, object_owner, object_name, object_type, parse_time) + values (ut_annotation_cache_seq.nextval, o.object_owner, o.object_name, o.object_type, l_timestamp); commit; end; diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pkb b/test/ut3_tester/core/annotations/test_annotation_cache.pkb index 983004eeb..372fec890 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pkb @@ -9,7 +9,7 @@ create or replace package body test_annotation_cache is from ut3.ut_annotation_cache_info where object_owner = 'UT3_CACHE_TEST_OWNER'; open l_expected_cache_info for - select 'UT3_CACHE_TEST_OWNER' as object_owner, upper( column_value ) as object_name, 'Y' as is_annotated + select 'UT3_CACHE_TEST_OWNER' as object_owner, upper( column_value ) as object_name from table (a_packages) x; ut.expect( l_actual_cache_info ).to_equal( l_expected_cache_info ).exclude( 'CACHE_ID,PARSE_TIME,OBJECT_TYPE' ).JOIN_BY('OBJECT_NAME'); end; From 8e548733cc2c672e189630b646c19722762ae54f Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 23 Feb 2020 14:05:14 +0000 Subject: [PATCH 045/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index da8a160ba..3f583531c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 92742a4a4..5de382e0a 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 4df80bc5c..64b28b164 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index f009b0c32..e36040752 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index f1253349b..74398a481 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 4cb07e043..c1a1bd4a0 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e606a4caf..c46406ee8 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 592eae131..56a469d69 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 00c568012..cd81dda4c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 9f06ff7c0..0e9510ddb 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 8842461eb..0f4684306 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index df5f8d9d1..1a7d45224 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 98be5fb6b..78368ab0a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index a2e4856e7..01b4d597b 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index bc642b035..677ea9493 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 295df814e..55d58eb2b 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 6aeee036d..bb4b24fca 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3343--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 4aa6850af..65452ee2e 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3343-develop + * secion v3.1.10.3346-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 73884bdca..097078d81 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3343-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3346-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From a2d163802ba4699b14f0241c46eae10787f8760a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 23 Feb 2020 15:45:37 +0000 Subject: [PATCH 046/887] Update `releasing.md` file --- development/releasing.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/development/releasing.md b/development/releasing.md index 3e9ac64fa..93634018d 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -1,9 +1,10 @@ -The release process is semi-automated. +## Release process With every build, the build process on Travis updates files with an appropriate version number before deployment into the database. This step is performed, to confirm that the update of versions works properly. -To create a release: +## To create a release + - create release branch from development branch and make sure to name the release branch: `release/vX.Y.Z` - update, commit and push at least one file change in the release branch, to kickoff a Travis build - wait for th build to complete successfully From 903425084daee1ec84b8dbda4dcb102a27fe7d58 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 23 Feb 2020 16:02:01 +0000 Subject: [PATCH 047/887] Updated project version after build [skip ci] --- VERSION | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 21 files changed, 21 insertions(+), 21 deletions(-) diff --git a/VERSION b/VERSION index 8961ff4ac..04c455c73 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.10-develop +v3.1.10 diff --git a/docs/about/authors.md b/docs/about/authors.md index 3f583531c..3ed66a43f 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 5de382e0a..31072519e 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 64b28b164..10ce84eb1 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index e36040752..2c9fcb98d 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 74398a481..3d48c47e6 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index c1a1bd4a0..feb521f69 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index c46406ee8..bb56ab4ef 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 56a469d69..89aa004ac 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index cd81dda4c..115678802 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 0e9510ddb..14cded7c6 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0f4684306..7876c7a79 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 1a7d45224..290419986 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 78368ab0a..520533cae 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 01b4d597b..d07c4836c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 677ea9493..8b3033539 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 55d58eb2b..4d7882852 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index bb4b24fca..924e80d17 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3346--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index 62c8f808f..7ab61df28 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -2,7 +2,7 @@ sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.10-develop +sonar.projectVersion=v3.1.10 # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 65452ee2e..87a14763c 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3346-develop + * secion v3.1.10.3347 */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 097078d81..bd017020a 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3346-develop'; + gc_version constant varchar2(50) := 'v3.1.10.3347'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 532073bfc4d8f7eabb9a67c9668836a01cc1b255 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 23 Feb 2020 16:46:06 +0000 Subject: [PATCH 048/887] Updated version to 3.1.11 --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 04c455c73..021c7c624 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.10 +v3.1.11 From 1b00d2759104ce7371c9417a3a0308bdf06825a7 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 23 Feb 2020 16:57:36 +0000 Subject: [PATCH 049/887] Updated project version after build [skip ci] --- VERSION | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 21 files changed, 21 insertions(+), 21 deletions(-) diff --git a/VERSION b/VERSION index 021c7c624..571f2ad11 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.11 +v3.1.11-develop diff --git a/docs/about/authors.md b/docs/about/authors.md index 3ed66a43f..8fb7b1928 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 31072519e..f5f26f2d2 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 10ce84eb1..3f14e0b9c 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 2c9fcb98d..0f3a92f1a 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 3d48c47e6..b53ed957f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index feb521f69..66035803b 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index bb56ab4ef..7d8f127f6 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 89aa004ac..4c5a6cbe1 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 115678802..69e5d41c7 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 14cded7c6..077527813 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 7876c7a79..a0db755d7 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 290419986..bbe051b15 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 520533cae..ee1de1d80 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d07c4836c..8c3349d72 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 8b3033539..320bf797a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 4d7882852..c263c58ab 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 924e80d17..126f92011 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.10.3347-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index 7ab61df28..ddd794a91 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -2,7 +2,7 @@ sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.10 +sonar.projectVersion=v3.1.11-develop # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 87a14763c..0ad70d5a1 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.10.3347 + * secion v3.1.11.3350-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index bd017020a..ebdff001f 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.10.3347'; + gc_version constant varchar2(50) := 'v3.1.11.3350-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 63f17a288c75c29fe0fb7da2435dea27ba12356c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 12 Mar 2020 23:16:46 +0000 Subject: [PATCH 050/887] Improved the way utPLSQL checks if user has the `execute any procedure` privilege. Added additional test to assure that invoking tests from utPLSQL owner doesn't break annotation Resolves #1051 --- .travis/install.sh | 4 ++-- .../annotations/ut_annotation_manager.pkb | 2 +- source/core/ut_metadata.pkb | 21 +++++++++++++++++-- source/core/ut_suite_manager.pkb | 2 +- .../annotations/test_annotation_cache.pkb | 18 ++++++++++++++++ .../annotations/test_annotation_cache.pks | 7 +++++++ .../annotation_cache_helper.pkb | 10 +++++---- 7 files changed, 54 insertions(+), 10 deletions(-) diff --git a/.travis/install.sh b/.travis/install.sh index 2e96ebfb2..dd21c4fbc 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -86,7 +86,7 @@ begin and generated = 'N' and object_name not like 'SYS%') loop - execute immediate 'grant execute on ut3."'||i.object_name||'" to UT3_TESTER'; + execute immediate 'grant execute on $UT3_OWNER."'||i.object_name||'" to $UT3_TESTER'; end loop; end; / @@ -96,7 +96,7 @@ PROMPT Granting $UT3_OWNER tables to $UT3_TESTER begin for i in ( select table_name from all_tables t where owner = 'UT3' and nested = 'NO' and iot_name is null) loop - execute immediate 'grant select on UT3.'||i.table_name||' to UT3_TESTER'; + execute immediate 'grant select on $UT3_OWNER.'||i.table_name||' to $UT3_TESTER'; end loop; end; / diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index a37391d37..f8ca03326 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -21,7 +21,7 @@ create or replace package body ut_annotation_manager as function user_can_see_whole_schema( a_schema_name varchar2 ) return boolean is begin - return sys_context('userenv','current_schema') = a_schema_name + return sys_context('userenv','current_user') = a_schema_name or ut_metadata.user_has_execute_any_proc() or ut_metadata.is_object_visible('dba_objects'); end; diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index 5448f1b5f..727dd6318 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -121,9 +121,26 @@ create or replace package body ut_metadata as end; function user_has_execute_any_proc return boolean is - l_ut_owner varchar2(250) := ut_utils.ut_owner; + l_has_execute_any varchar2(1); begin - return is_object_visible(l_ut_owner||'.ut_utils') and sys_context('userenv','current_schema') != l_ut_owner; + select decode( count( 1 ), 0, 'N', 'Y' ) + into l_has_execute_any + from dual + where + exists( + select 1 + from + role_sys_privs + join session_roles + using ( role ) + where privilege = 'EXECUTE ANY PROCEDURE' + ) or + exists( + select 1 + from user_sys_privs + where privilege = 'EXECUTE ANY PROCEDURE' + ); + return l_has_execute_any = 'Y'; end; function is_object_visible(a_object_name varchar2) return boolean is diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index ee5063105..789255f99 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -374,7 +374,7 @@ create or replace package body ut_suite_manager is a_owner_name varchar2 ) return boolean is begin - return sys_context( 'userenv', 'current_schema' ) = a_owner_name or ut_metadata.user_has_execute_any_proc(); + return sys_context( 'userenv', 'current_user' ) = a_owner_name or ut_metadata.user_has_execute_any_proc(); end; procedure build_and_cache_suites( diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pkb b/test/ut3_tester/core/annotations/test_annotation_cache.pkb index 372fec890..1faa7ce09 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pkb @@ -14,6 +14,19 @@ create or replace package body test_annotation_cache is ut.expect( l_actual_cache_info ).to_equal( l_expected_cache_info ).exclude( 'CACHE_ID,PARSE_TIME,OBJECT_TYPE' ).JOIN_BY('OBJECT_NAME'); end; + procedure cant_run_any_packages(a_user varchar2) is + l_actual clob; + l_current_time date := sysdate; + pragma autonomous_transaction; + begin + --Act + l_actual := annotation_cache_helper.run_tests_as( a_user ); + + --Assert - no suites are + ut.expect( l_actual ).to_be_like( '%0 tests, 0 failed%' ); + rollback; + end; + procedure can_run_one_package(a_user varchar2) is l_actual clob; l_current_time date := sysdate; @@ -380,6 +393,11 @@ create or replace package body test_annotation_cache is cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); end; + procedure t_ut_owner_cannot_run_tests is + begin + cant_run_any_packages( 'ut3' ); + cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); + end; diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pks b/test/ut3_tester/core/annotations/test_annotation_cache.pks index f44b816e1..5a3fdd8ca 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pks +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pks @@ -89,6 +89,13 @@ create or replace package test_annotation_cache is --%endcontext + --%context(utPLSQL framework owner) + + --%test(Cannot see any tests and doesn't impact annotation cache ) + procedure t_ut_owner_cannot_run_tests; + + --%endcontext + --%endcontext --%context(With DDL trigger disabled) diff --git a/test/ut3_tester_helper/annotation_cache_helper.pkb b/test/ut3_tester_helper/annotation_cache_helper.pkb index 0d56823df..c61c797fc 100644 --- a/test/ut3_tester_helper/annotation_cache_helper.pkb +++ b/test/ut3_tester_helper/annotation_cache_helper.pkb @@ -122,7 +122,7 @@ create or replace package body annotation_cache_helper as pragma autonomous_transaction; begin execute immediate - 'create or replace function ' || a_user || '.ut_run return clob is + 'create or replace function ' || a_user || '.call_ut_run return clob is l_data ut3.ut_varchar2_list; l_results clob; begin @@ -130,13 +130,13 @@ create or replace package body annotation_cache_helper as return ut3_tester_helper.main_helper.table_to_clob( l_data ); end; '; - execute immediate 'grant execute on ' || a_user || '.ut_run to public '; + execute immediate 'grant execute on ' || a_user || '.call_ut_run to public '; end; procedure drop_run_function_for_user(a_user varchar2) is pragma autonomous_transaction; begin - execute immediate 'drop function ' || a_user || '.ut_run'; + execute immediate 'drop function ' || a_user || '.call_ut_run'; end; procedure create_run_function_for_users is @@ -146,6 +146,7 @@ create or replace package body annotation_cache_helper as create_run_function_for_user( 'ut3_select_any_table_user' ); create_run_function_for_user( 'ut3_execute_any_proc_user' ); create_run_function_for_user( 'ut3_cache_test_owner' ); + create_run_function_for_user( 'ut3' ); end; procedure drop_run_function_for_users is @@ -155,12 +156,13 @@ create or replace package body annotation_cache_helper as drop_run_function_for_user( 'ut3_select_any_table_user' ); drop_run_function_for_user( 'ut3_execute_any_proc_user' ); drop_run_function_for_user( 'ut3_cache_test_owner' ); + drop_run_function_for_user( 'ut3' ); end; function run_tests_as(a_user varchar2) return clob is l_results clob; begin - execute immediate 'begin :x := '||a_user||'.ut_run; end;' using out l_results; + execute immediate 'begin :x := '||a_user||'.call_ut_run; end;' using out l_results; return l_results; end; end; From 4979cf924df78137e31d40f8d24cff1cb8191776 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 12 Mar 2020 23:18:02 +0000 Subject: [PATCH 051/887] Added check for sys grants added via role when installing utPLSQL framework. Resolves #1050 --- source/check_sys_grants.sql | 33 ++++++++++++++++++++++----------- 1 file changed, 22 insertions(+), 11 deletions(-) diff --git a/source/check_sys_grants.sql b/source/check_sys_grants.sql index 7b1644952..79b657328 100644 --- a/source/check_sys_grants.sql +++ b/source/check_sys_grants.sql @@ -12,18 +12,29 @@ begin end if; end loop; end if; + + with + x as ( + select '' as remove from dual + union all + select ' ANY' as remove from dual + ) select listagg(' - '||privilege,CHR(10)) within group(order by privilege) - into l_missing_grants - from ( - select column_value as privilege - from table(l_expected_grants) - minus - (select privilege - from user_sys_privs - union all - select replace(privilege,' ANY') privilege - from user_sys_privs) - ); + into l_missing_grants + from ( + select column_value as privilege + from table(l_expected_grants) + minus ( + select replace(p.privilege, x.remove) as privilege + from role_sys_privs p + join session_roles r using (role) + cross join x + union all + select replace(p.privilege, x.remove) as privilege + from user_sys_privs p + cross join x + ) + ); if l_missing_grants is not null then raise_application_error( -20000 From 4d865ae171636df012b8288bdfdf61aa0e7bbbf6 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 14 Mar 2020 17:41:09 +0000 Subject: [PATCH 052/887] Fixed flay tests that can fail on occasion when a second flips during test execution. --- .../expectations/test_expectations_cursor.pkb | 32 +++++++++---------- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index 5a0b68f2f..4f9cd72d6 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -419,13 +419,12 @@ create or replace package body test_expectations_cursor is as l_expected sys_refcursor; l_actual sys_refcursor; - l_date date := sysdate; - l_second number := 1/24/60/60; + c_second constant number := 1/24/60/60; begin --Arrange ut3.ut.set_nls; - open l_actual for select l_date as some_date from dual; - open l_expected for select l_date-l_second some_date from dual; + open l_actual for select gc_date as some_date from dual; + open l_expected for select gc_date - c_second some_date from dual; --Act ut3.ut.expect( l_actual ).to_equal( l_expected ); --Assert @@ -439,8 +438,8 @@ create or replace package body test_expectations_cursor is l_expected sys_refcursor; begin --Arrange - open l_actual for select sysdate as some_date from dual; - open l_expected for select to_date(to_char(sysdate)) as some_date from dual; + open l_actual for select gc_date as some_date from dual; + open l_expected for select to_date(to_char(gc_date)) as some_date from dual; --Act ut3.ut.expect(l_actual).to_equal(l_expected); --Assert @@ -1970,10 +1969,10 @@ Diff:% l_actual_tab some_object; l_expected_tab some_object; begin - select some_object( user,'TEST', sysdate, some_items( some_item(1,'test'), some_item(2,'test') ) ) + select some_object( user,'TEST', gc_date, some_items( some_item(1,'test'), some_item(2,'test') ) ) into l_actual_tab from dual; - select some_object( user,'TEST', sysdate, some_items( some_item(1,'test'), some_item(2,'test') ) ) + select some_object( user,'TEST', gc_date, some_items( some_item(1,'test'), some_item(2,'test') ) ) into l_expected_tab from dual; --Arrange @@ -1994,10 +1993,10 @@ Diff:% l_actual_tab some_object; l_expected_tab some_object; begin - select some_object( user,'TEST', sysdate, some_items( some_item(1,'test'), some_item(2,'test') ) ) + select some_object( user,'TEST', gc_date, some_items( some_item(1,'test'), some_item(2,'test') ) ) into l_actual_tab from dual; - select some_object( user,'TEST', sysdate, some_items( some_item(1,'test'), some_item(2,'test') ) ) + select some_object( user,'TEST', gc_date, some_items( some_item(1,'test'), some_item(2,'test') ) ) into l_expected_tab from dual; --Arrange @@ -2018,10 +2017,10 @@ Diff:% l_actual_tab some_object; l_expected_tab some_object; begin - select some_object( user,'TEST', sysdate, some_items( some_item(1,'test'), some_item(2,'test') ) ) + select some_object( user,'TEST', gc_date, some_items( some_item(1,'test'), some_item(2,'test') ) ) into l_actual_tab from dual; - select some_object( user,'TEST', sysdate, some_items( some_item(1,'test'), some_item(2,'test') ) ) + select some_object( user,'TEST', gc_date, some_items( some_item(1,'test'), some_item(2,'test') ) ) into l_expected_tab from dual; --Arrange @@ -2043,12 +2042,11 @@ Diff:% l_expected_tab some_object; l_expected_message varchar2(32767); l_actual_message varchar2(32767); - l_date date := sysdate; begin - select some_object( 'TEST','TEST', l_date, some_items( some_item(1,'BAD'), some_item(2,'test') ) ) + select some_object( 'TEST','TEST', gc_date, some_items( some_item(1,'BAD'), some_item(2,'test') ) ) into l_actual_tab from dual; - select some_object( 'TEST','TEST', l_date, some_items( some_item(1,'TEST'), some_item(2,'test') ) ) + select some_object( 'TEST','TEST', gc_date, some_items( some_item(1,'TEST'), some_item(2,'test') ) ) into l_expected_tab from dual; --Arrange @@ -2080,10 +2078,10 @@ Diff:% l_expected_message varchar2(32767); l_actual_message varchar2(32767); begin - select some_object( 'TEST','TEST', sysdate, some_items( some_item(1,'BAD'), some_item(2,'test') ) ) + select some_object( 'TEST','TEST', gc_date, some_items( some_item(1,'BAD'), some_item(2,'test') ) ) into l_actual_tab from dual; - select some_object( 'TEST','TEST', sysdate, some_items( some_item(1,'TEST'), some_item(2,'test') ) ) + select some_object( 'TEST','TEST', gc_date, some_items( some_item(1,'TEST'), some_item(2,'test') ) ) into l_expected_tab from dual; --Arrange From 8d375915b5dff7da7095a535802473bc6919405f Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sat, 14 Mar 2020 18:33:22 +0000 Subject: [PATCH 053/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 8fb7b1928..2fe5655e8 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index f5f26f2d2..576f861d1 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 3f14e0b9c..e868fecd0 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 0f3a92f1a..8df21fea3 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b53ed957f..f641c25ae 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 66035803b..d6fc7bcd0 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 7d8f127f6..8f4acbd3a 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 4c5a6cbe1..6046a2241 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 69e5d41c7..022fce376 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 077527813..a10554155 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index a0db755d7..111a95ff7 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index bbe051b15..5dcf6c056 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ee1de1d80..b2048a75c 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 8c3349d72..f4fcb065e 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 320bf797a..f2a86cf5d 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c263c58ab..490a21c1c 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 126f92011..5e33365af 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3350--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 0ad70d5a1..6f92f7901 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3350-develop + * secion v3.1.11.3357-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index ebdff001f..2ecbbc095 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3350-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3357-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 725d367c4e28226e4fc206937e46f5105e23b9fe Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 15 Mar 2020 22:01:51 +0000 Subject: [PATCH 054/887] Refactored and fixed code to use be fully schema-independent. --- .travis.yml | 11 ++++---- .travis/install.sh | 41 +++++++++++++++++------------- .travis/install_utplsql_release.sh | 8 +++--- .travis/run_examples.sh | 2 +- development/cleanup.sh | 4 +-- development/install.sh | 2 +- development/refresh_ut3.sh | 4 +-- development/template.env.sh | 11 ++++---- docs/userguide/install.md | 2 +- source/core/ut_suite_manager.pkb | 13 +++++----- source/create_utplsql_owner.sql | 18 ++++++------- 11 files changed, 62 insertions(+), 54 deletions(-) diff --git a/.travis.yml b/.travis.yml index 018038144..265fc0888 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,14 +16,15 @@ services: env: global: - - UT3_OWNER=ut3 - - UT3_OWNER_PASSWORD=ut3 - - UT3_RELEASE_VERSION_SCHEMA=UT3_LATEST_RELEASE + - UT3_DEVELOP_SCHEMA=UT3_DEVELOP + - UT3_DEVELOP_SCHEMA_PASSWORD=ut3 + - UT3_RELEASE_VERSION_SCHEMA=UT3 + - UT3_RELEASE_VERSION_SCHEMA_PASSWORD=ut3 - UT3_USER="UT3\$USER#" - UT3_USER_PASSWORD=ut3 - - UT3_TESTER=ut3_tester + - UT3_TESTER=UT3_TESTER - UT3_TESTER_PASSWORD=ut3 - - UT3_TESTER_HELPER=ut3_tester_helper + - UT3_TESTER_HELPER=UT3_TESTER_HELPER - UT3_TESTER_HELPER_PASSWORD=ut3 - UT3_TABLESPACE=users # Environment for building a release diff --git a/.travis/install.sh b/.travis/install.sh index dd21c4fbc..99c88c79b 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -3,6 +3,11 @@ cd source set -ev +INSTALL_FILE="install_headless_with_trigger.sql" +if [[ ! -f "${INSTALL_FILE}" ]]; then + INSTALL_FILE="install_headless.sql" +fi + #install core of utplsql time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL whenever sqlerror exit failure rollback @@ -11,14 +16,14 @@ set verify off --alter session set plsql_warnings = 'ENABLE:ALL', 'DISABLE:(5004,5018,6000,6001,6003,6009,6010,7206)'; alter session set plsql_optimize_level=0; -@install_headless_with_trigger.sql $UT3_OWNER $UT3_OWNER_PASSWORD +@${INSTALL_FILE} $UT3_DEVELOP_SCHEMA $UT3_DEVELOP_SCHEMA_PASSWORD SQL #Run this step only on second child job (12.1 - at it's fastest) if [[ "${TRAVIS_JOB_NUMBER}" =~ \.2$ ]]; then #check code-style for errors - time "$SQLCLI" $UT3_OWNER/$UT3_OWNER_PASSWORD@//$CONNECTION_STR @../development/utplsql_style_check.sql + time "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @../development/utplsql_style_check.sql #test install/uninstall process time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL @@ -26,7 +31,7 @@ if [[ "${TRAVIS_JOB_NUMBER}" =~ \.2$ ]]; then set verify off whenever sqlerror exit failure rollback - @uninstall_all.sql $UT3_OWNER + @uninstall_all.sql $UT3_DEVELOP_SCHEMA whenever sqlerror exit failure rollback declare v_leftover_objects_count integer; @@ -34,10 +39,10 @@ if [[ "${TRAVIS_JOB_NUMBER}" =~ \.2$ ]]; then select sum(cnt) into v_leftover_objects_count from ( - select count(1) cnt from dba_objects where owner = '$UT3_OWNER' + select count(1) cnt from dba_objects where owner = '$UT3_DEVELOP_SCHEMA' where object_name not like 'PLSQL_PROFILER%' and object_name not like 'DBMSPCC_%' union all - select count(1) cnt from dba_synonyms where table_owner = '$UT3_OWNER' + select count(1) cnt from dba_synonyms where table_owner = '$UT3_DEVELOP_SCHEMA' where table_name not like 'PLSQL_PROFILER%' and table_name not like 'DBMSPCC_%' ); if v_leftover_objects_count > 0 then @@ -52,9 +57,9 @@ SQL set verify off alter session set plsql_optimize_level=0; - @install.sql $UT3_OWNER - @install_ddl_trigger.sql $UT3_OWNER - @create_synonyms_and_grants_for_public.sql $UT3_OWNER + @install.sql $UT3_DEVELOP_SCHEMA + @install_ddl_trigger.sql $UT3_DEVELOP_SCHEMA + @create_synonyms_and_grants_for_public.sql $UT3_DEVELOP_SCHEMA SQL fi @@ -65,8 +70,8 @@ set feedback off whenever sqlerror exit failure rollback -------------------------------------------------------------------------------- -PROMPT Adding back create-trigger privilege to $UT3_OWNER for testing -grant administer database trigger to $UT3_OWNER; +PROMPT Adding back create-trigger privilege to $UT3_DEVELOP_SCHEMA for testing +grant administer database trigger to $UT3_DEVELOP_SCHEMA; -------------------------------------------------------------------------------- PROMPT Creating $UT3_TESTER - Power-user for testing internal framework code @@ -76,27 +81,27 @@ grant create session, create procedure, create type, create table to $UT3_TESTER grant execute on dbms_lock to $UT3_TESTER; -PROMPT Granting $UT3_OWNER code to $UT3_TESTER +PROMPT Granting $UT3_DEVELOP_SCHEMA code to $UT3_TESTER begin for i in ( select object_name from all_objects t where t.object_type in ('PACKAGE','TYPE') - and owner = 'UT3' + and owner = '$UT3_DEVELOP_SCHEMA' and generated = 'N' and object_name not like 'SYS%') loop - execute immediate 'grant execute on $UT3_OWNER."'||i.object_name||'" to $UT3_TESTER'; + execute immediate 'grant execute on $UT3_DEVELOP_SCHEMA."'||i.object_name||'" to $UT3_TESTER'; end loop; end; / -PROMPT Granting $UT3_OWNER tables to $UT3_TESTER +PROMPT Granting $UT3_DEVELOP_SCHEMA tables to $UT3_TESTER begin - for i in ( select table_name from all_tables t where owner = 'UT3' and nested = 'NO' and iot_name is null) + for i in ( select table_name from all_tables t where owner = '$UT3_DEVELOP_SCHEMA' and nested = 'NO' and iot_name is null) loop - execute immediate 'grant select on $UT3_OWNER.'||i.table_name||' to $UT3_TESTER'; + execute immediate 'grant select on $UT3_DEVELOP_SCHEMA.'||i.table_name||' to $UT3_TESTER'; end loop; end; / @@ -119,11 +124,11 @@ PROMPT Grants for testing distributed transactions grant create public database link to $UT3_TESTER_HELPER; grant drop public database link to $UT3_TESTER_HELPER; -PROMPT Grants for testing coverage outside of main UT3 schema. +PROMPT Grants for testing coverage outside of main $UT3_DEVELOP_SCHEMA schema. grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type, select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table, select any dictionary, create any synonym, drop any synonym, - grant any object privilege, grant any privilege + grant any object privilege, grant any privilege, create public synonym, drop public synonym to $UT3_TESTER_HELPER; grant create job to $UT3_TESTER_HELPER; diff --git a/.travis/install_utplsql_release.sh b/.travis/install_utplsql_release.sh index 3e608b08f..12ec50118 100755 --- a/.travis/install_utplsql_release.sh +++ b/.travis/install_utplsql_release.sh @@ -11,7 +11,7 @@ set trimspool on declare i integer := 0; begin - dbms_output.put_line('Dropping synonyms pointing to schema '||upper('${UT3_OWNER}')); + dbms_output.put_line('Dropping synonyms pointing to schema '||upper('${UT3_DEVELOP_SCHEMA}')); for syn in ( select case when owner = 'PUBLIC' @@ -19,7 +19,7 @@ begin else 'synonym ' || owner || '.' end || synonym_name as syn_name, table_owner||'.'||table_name as for_object from all_synonyms s - where table_owner = upper('${UT3_OWNER}') and table_owner != owner + where table_owner = upper('${UT3_DEVELOP_SCHEMA}') and table_owner != owner ) loop i := i + 1; @@ -28,7 +28,7 @@ begin dbms_output.put_line('Dropped '||syn.syn_name||' for object '||syn.for_object); exception when others then - dbms_output.put_line('FAILED to drop '||syn.syn_name||' for object '||syn.for_object); + dbms_output.put_line('FAILED to drop '||syn.syn_name||' for object '||syn.for_object||' with error '||sqlerrm); end; end loop; dbms_output.put_line(i||' synonyms dropped'); @@ -45,7 +45,7 @@ fi alter session set plsql_optimize_level=0; alter session set plsql_ccflags = 'SELF_TESTING_INSTALL:TRUE'; -@${INSTALL_FILE} ${UT3_RELEASE_VERSION_SCHEMA} +@${INSTALL_FILE} ${UT3_RELEASE_VERSION_SCHEMA} ${UT3_RELEASE_VERSION_SCHEMA_PASSWORD} exit SQL diff --git a/.travis/run_examples.sh b/.travis/run_examples.sh index 967b621c7..2f05b101b 100755 --- a/.travis/run_examples.sh +++ b/.travis/run_examples.sh @@ -2,7 +2,7 @@ set -ev -"$SQLCLI" $UT3_OWNER/$UT3_OWNER_PASSWORD@//$CONNECTION_STR < Date: Sun, 15 Mar 2020 22:16:36 +0000 Subject: [PATCH 055/887] Refactored tests to comply with new schema layout --- test/run_tests.sh | 2 +- .../test_annot_throws_exception.pkb | 6 +- .../annotations/test_annotation_cache.pkb | 4 +- .../annotations/test_annotation_manager.pkb | 66 +- .../annotations/test_annotation_parser.pkb | 218 ++--- .../test_before_after_annotations.pkb | 4 +- .../test_expectation_processor.pkb | 56 +- test/ut3_tester/core/test_file_mapper.pkb | 30 +- test/ut3_tester/core/test_output_buffer.pkb | 34 +- test/ut3_tester/core/test_suite_builder.pkb | 896 +++++++++--------- test/ut3_tester/core/test_suite_manager.pkb | 544 +++++------ test/ut3_tester/core/test_ut_executable.pkb | 34 +- test/ut3_tester/core/test_ut_suite.pkb | 74 +- test/ut3_tester/core/test_ut_test.pkb | 226 ++--- test/ut3_tester/core/test_ut_utils.pkb | 130 +-- .../annotation_cache_helper.pkb | 28 +- test/ut3_tester_helper/coverage_helper.pkb | 100 +- test/ut3_tester_helper/coverage_helper.pks | 2 +- .../ut3_tester_helper/expectations_helper.pkb | 6 +- test/ut3_tester_helper/main_helper.pkb | 58 +- test/ut3_tester_helper/main_helper.pks | 18 +- test/ut3_tester_helper/run_helper.pkb | 140 +-- test/ut3_tester_helper/run_helper.pks | 52 +- test/ut3_user/api/test_ut_run.pkb | 194 ++-- test/ut3_user/api/test_ut_runner.pkb | 168 ++-- test/ut3_user/expectations.pkb | 12 +- .../binary/test_be_greater_or_equal.pkb | 2 +- .../binary/test_be_greater_than.pkb | 2 +- .../binary/test_be_less_or_equal.pkb | 2 +- .../expectations/binary/test_equal.pkb | 2 +- .../binary/test_expect_to_be_less_than.pkb | 2 +- .../expectations/test_expectation_anydata.pkb | 160 ++-- .../expectations/test_expectations_cursor.pkb | 380 ++++---- .../expectations/test_expectations_json.pkb | 46 +- test/ut3_user/expectations/test_matchers.pkb | 22 +- .../unary/test_expect_to_be_empty.pkb | 50 +- .../unary/test_expect_to_be_true_false.pkb | 32 +- .../unary/test_expect_to_have_count.pkb | 34 +- test/ut3_user/reporters.pkb | 24 +- test/ut3_user/reporters.pks | 4 +- .../test_cov_cobertura_reporter.pkb | 30 +- .../test_coverage_sonar_reporter.pkb | 16 +- .../test_coverage/test_coveralls_reporter.pkb | 26 +- .../test_html_extended_reporter.pkb | 14 +- .../test_html_proftab_reporter.pkb | 14 +- .../reporters/test_debug_reporter.pkb | 6 +- .../reporters/test_documentation_reporter.pkb | 2 +- .../reporters/test_extended_coverage.pkb | 40 +- .../reporters/test_junit_reporter.pkb | 52 +- .../reporters/test_proftab_coverage.pkb | 68 +- .../reporters/test_realtime_reporter.pkb | 40 +- .../reporters/test_sonar_test_reporter.pkb | 12 +- .../reporters/test_teamcity_reporter.pkb | 16 +- .../reporters/test_tfs_junit_reporter.pkb | 34 +- 54 files changed, 2117 insertions(+), 2117 deletions(-) diff --git a/test/run_tests.sh b/test/run_tests.sh index 29086f5f7..0edc4d96d 100755 --- a/test/run_tests.sh +++ b/test/run_tests.sh @@ -5,7 +5,7 @@ set -ev git rev-parse && cd "$(git rev-parse --show-cdup)" time utPLSQL-cli/bin/utplsql run ${UT3_TESTER_HELPER}/${UT3_TESTER_HELPER_PASSWORD}@${CONNECTION_STR} \ --source_path=source -owner=ut3 \ +-source_path=source -owner=ut3_develop \ -p='ut3_tester,ut3$user#' \ -test_path=test -c \ -f=ut_coverage_sonar_reporter -o=coverage.xml \ diff --git a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb index 04e65a6c2..ac51d3a49 100644 --- a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb +++ b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb @@ -8,7 +8,7 @@ is l_package_spec varchar2(32737); l_package_body varchar2(32737); l_exception_spec varchar2(32737); - l_test_results ut3.ut_varchar2_list; + l_test_results ut3_develop.ut_varchar2_list; begin l_exception_spec := q'[ create or replace package exc_pkg is @@ -251,9 +251,9 @@ is execute immediate l_package_body; - select * bulk collect into l_test_results from table(ut3.ut.run(('annotated_package_with_throws'))); + select * bulk collect into l_test_results from table(ut3_develop.ut.run(('annotated_package_with_throws'))); - g_tests_results := ut3.ut_utils.table_to_clob(l_test_results); + g_tests_results := ut3_develop.ut_utils.table_to_clob(l_test_results); end; procedure throws_same_annotated_except is diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pkb b/test/ut3_tester/core/annotations/test_annotation_cache.pkb index 1faa7ce09..eefaf8800 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pkb @@ -6,7 +6,7 @@ create or replace package body test_annotation_cache is begin open l_actual_cache_info for select * - from ut3.ut_annotation_cache_info + from ut3_develop.ut_annotation_cache_info where object_owner = 'UT3_CACHE_TEST_OWNER'; open l_expected_cache_info for select 'UT3_CACHE_TEST_OWNER' as object_owner, upper( column_value ) as object_name @@ -395,7 +395,7 @@ create or replace package body test_annotation_cache is procedure t_ut_owner_cannot_run_tests is begin - cant_run_any_packages( 'ut3' ); + cant_run_any_packages( 'ut3_develop' ); cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); end; diff --git a/test/ut3_tester/core/annotations/test_annotation_manager.pkb b/test/ut3_tester/core/annotations/test_annotation_manager.pkb index 8a3efc508..a5503f841 100644 --- a/test/ut3_tester/core/annotations/test_annotation_manager.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_manager.pkb @@ -101,14 +101,14 @@ create or replace package body test_annotation_manager is begin select max(cache_id) into l_actual_cache_id - from ut3.ut_annotation_cache_info + from ut3_develop.ut_annotation_cache_info where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_PACKAGE' and parse_time >= a_start_date; ut.expect(l_actual_cache_id).to_be_not_null; open l_actual for select annotation_position, annotation_name, annotation_text, subobject_name - from ut3.ut_annotation_cache where cache_id = l_actual_cache_id + from ut3_develop.ut_annotation_cache where cache_id = l_actual_cache_id order by annotation_position; ut.expect(l_actual).to_be_empty(); @@ -116,26 +116,26 @@ create or replace package body test_annotation_manager is procedure assert_dummy_test_package(a_start_time timestamp) is l_actual_cache_id integer; - l_data ut3.ut_annotated_objects; + l_data ut3_develop.ut_annotated_objects; l_result sys_refcursor; l_actual sys_refcursor; l_expected sys_refcursor; begin open l_expected for select - ut3.ut_annotated_object( + ut3_develop.ut_annotated_object( sys_context('USERENV', 'CURRENT_USER'), 'DUMMY_TEST_PACKAGE', 'PACKAGE', a_start_time, - ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', 'dummy_test_suite', null ), - ut3.ut_annotation( 3, 'rollback', 'manual', null ), - ut3.ut_annotation( 7, 'test', 'dummy_test', 'some_dummy_test_procedure' ), - ut3.ut_annotation( 8, 'beforetest', 'some_procedure', 'some_dummy_test_procedure' ) + ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', 'dummy_test_suite', null ), + ut3_develop.ut_annotation( 3, 'rollback', 'manual', null ), + ut3_develop.ut_annotation( 7, 'test', 'dummy_test', 'some_dummy_test_procedure' ), + ut3_develop.ut_annotation( 8, 'beforetest', 'some_procedure', 'some_dummy_test_procedure' ) ) ) annotated_object from dual; - l_result := ut3.ut_annotation_manager.get_annotated_objects(sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE', a_start_time); + l_result := ut3_develop.ut_annotation_manager.get_annotated_objects(sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE', a_start_time); fetch l_result bulk collect into l_data; open l_actual for select value(x) as annotated_object from table(l_data) x where object_name = 'DUMMY_TEST_PACKAGE'; ut.expect(l_actual).to_equal(l_expected).exclude('ANNOTATED_OBJECT/PARSE_TIME').join_by('ANNOTATED_OBJECT/OBJECT_NAME'); @@ -153,7 +153,7 @@ create or replace package body test_annotation_manager is --Assert select max(cache_id) into l_actual_cache_id - from ut3.ut_annotation_cache_info + from ut3_develop.ut_annotation_cache_info where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_TEST_PACKAGE'; ut.expect(l_actual_cache_id).to_be_null; @@ -185,7 +185,7 @@ create or replace package body test_annotation_manager is --Act annotation_cache_helper.enable_ddl_trigger(); l_start_date := sysdate; - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); --Assert assert_dummy_test_package(l_start_date); assert_dummy_package(l_start_date); @@ -197,7 +197,7 @@ create or replace package body test_annotation_manager is --Arrange open l_actual for select * - from ut3.ut_annotation_cache_info + from ut3_develop.ut_annotation_cache_info where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_PACKAGE'; ut.expect(l_actual).to_be_empty(); @@ -207,7 +207,7 @@ create or replace package body test_annotation_manager is --Assert open l_actual for select * - from ut3.ut_annotation_cache_info + from ut3_develop.ut_annotation_cache_info where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_PACKAGE'; ut.expect(l_actual).to_be_empty(); @@ -233,7 +233,7 @@ create or replace package body test_annotation_manager is --Assert open l_actual for select * - from ut3.ut_annotation_cache_info + from ut3_develop.ut_annotation_cache_info where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_TEST_PACKAGE'; @@ -247,7 +247,7 @@ create or replace package body test_annotation_manager is --Arrange create_dummy_test_package(); l_start_date := sysdate; - ut3.ut_annotation_manager.purge_cache(sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE'); + ut3_develop.ut_annotation_manager.purge_cache(sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE'); --Act & Assert assert_dummy_test_package(l_start_date); end; @@ -273,7 +273,7 @@ create or replace package body test_annotation_manager is --Assert ut.expect( - ut3.ut_annotation_manager.get_annotated_objects( + ut3_develop.ut_annotation_manager.get_annotated_objects( sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time ), 'Annotations are empty after package was dropped' @@ -287,7 +287,7 @@ create or replace package body test_annotation_manager is create_dummy_package(); --Act & Assert ut.expect( - ut3.ut_annotation_manager.get_annotated_objects( + ut3_develop.ut_annotation_manager.get_annotated_objects( sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time ), 'Annotations are empty for not annotated package' @@ -300,7 +300,7 @@ create or replace package body test_annotation_manager is --Arrange create_dummy_package(); ut.expect( - ut3.ut_annotation_manager.get_annotated_objects( + ut3_develop.ut_annotation_manager.get_annotated_objects( sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time ), 'Annotations are empty for non annotated package' @@ -311,7 +311,7 @@ create or replace package body test_annotation_manager is --Assert ut.expect( - ut3.ut_annotation_manager.get_annotated_objects( + ut3_develop.ut_annotation_manager.get_annotated_objects( sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time ), 'Annotations are empty after non annoteted package was dropped' @@ -332,7 +332,7 @@ create or replace package body test_annotation_manager is --Assert ut.expect( - ut3.ut_annotation_manager.get_annotated_objects( + ut3_develop.ut_annotation_manager.get_annotated_objects( sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time ) ).to_be_empty(); @@ -346,7 +346,7 @@ create or replace package body test_annotation_manager is procedure some_dummy_test_procedure; end;]'); ut.expect( - ut3.ut_annotation_manager.get_annotated_objects( + ut3_develop.ut_annotation_manager.get_annotated_objects( sys_context( 'USERENV', 'CURRENT_USER' ), 'PACKAGE', l_start_time ) ).to_be_empty(); @@ -365,15 +365,15 @@ create or replace package body test_annotation_manager is l_start_date date; begin --Arrange - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); l_start_date := sysdate; modify_dummy_test_package(); --Act - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); --Assert select max(cache_id) into l_actual_cache_id - from ut3.ut_annotation_cache_info + from ut3_develop.ut_annotation_cache_info where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_TEST_PACKAGE' and parse_time >= l_start_date; @@ -381,7 +381,7 @@ create or replace package body test_annotation_manager is open l_actual for select annotation_position, annotation_name, annotation_text, subobject_name - from ut3.ut_annotation_cache where cache_id = l_actual_cache_id + from ut3_develop.ut_annotation_cache where cache_id = l_actual_cache_id order by annotation_position; open l_expected for @@ -407,7 +407,7 @@ create or replace package body test_annotation_manager is --Assert select count(1) into l_cache_count - from ut3.ut_annotation_cache_info + from ut3_develop.ut_annotation_cache_info where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_TEST_PACKAGE' @@ -417,14 +417,14 @@ create or replace package body test_annotation_manager is procedure no_data_for_dropped_object is l_result sys_refcursor; - l_data ut3.ut_annotated_objects; + l_data ut3_develop.ut_annotated_objects; l_actual sys_refcursor; l_start_time timestamp := systimestamp; begin --Arrange drop_dummy_test_package(); --Act - l_result := ut3.ut_annotation_manager.get_annotated_objects( sys_context('USERENV', 'CURRENT_USER'),'PACKAGE', l_start_time ); + l_result := ut3_develop.ut_annotation_manager.get_annotated_objects( sys_context('USERENV', 'CURRENT_USER'),'PACKAGE', l_start_time ); fetch l_result bulk collect into l_data; open l_actual for select object_name from table(l_data) where object_name = 'DUMMY_TEST_PACKAGE'; --Assert @@ -435,14 +435,14 @@ create or replace package body test_annotation_manager is l_cache_count integer; begin --Arrange - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); drop_dummy_test_package(); --Act - ut3.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache(sys_context('USERENV', 'CURRENT_USER'),'PACKAGE'); --Assert select count(1) into l_cache_count - from ut3.ut_annotation_cache_info + from ut3_develop.ut_annotation_cache_info where object_owner = sys_context('USERENV', 'CURRENT_USER') and object_type = 'PACKAGE' and object_name = 'DUMMY_TEST_PACKAGE'; @@ -457,7 +457,7 @@ create or replace package body test_annotation_manager is --Arrange create_dummy_test_package(); l_start_date := sysdate; - ut3.ut_annotation_manager.purge_cache(sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE'); + ut3_develop.ut_annotation_manager.purge_cache(sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE'); --Act & Assert assert_dummy_test_package(l_start_date); end; diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pkb b/test/ut3_tester/core/annotations/test_annotation_parser.pkb index c4c90c046..bc789c377 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pkb @@ -2,8 +2,8 @@ create or replace package body test_annotation_parser is procedure test_proc_comments is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS @@ -18,16 +18,16 @@ create or replace package body test_annotation_parser is END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation(2,'suite',null, null), - ut3.ut_annotation(3,'displayname','Name of suite',null), - ut3.ut_annotation(4,'suitepath','all.globaltests',null), - ut3.ut_annotation(6,'ann1','Name of suite',null), - ut3.ut_annotation(8,'ann2','some_value','foo') + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2,'suite',null, null), + ut3_develop.ut_annotation(3,'displayname','Name of suite',null), + ut3_develop.ut_annotation(4,'suitepath','all.globaltests',null), + ut3_develop.ut_annotation(6,'ann1','Name of suite',null), + ut3_develop.ut_annotation(8,'ann2','some_value','foo') ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -35,8 +35,8 @@ create or replace package body test_annotation_parser is procedure include_floating_annotations is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS -- %suite @@ -57,19 +57,19 @@ create or replace package body test_annotation_parser is END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', null, null ), - ut3.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), - ut3.ut_annotation( 6, 'ann1', 'Name of suite', null ), - ut3.ut_annotation( 7, 'ann2', 'all.globaltests', null ), - ut3.ut_annotation( 9, 'test', null, 'foo'), - ut3.ut_annotation( 12, 'ann3', 'Name of suite', null ), - ut3.ut_annotation( 13, 'ann4', 'all.globaltests', null ), - ut3.ut_annotation( 15, 'test', null, 'bar') + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), + ut3_develop.ut_annotation( 6, 'ann1', 'Name of suite', null ), + ut3_develop.ut_annotation( 7, 'ann2', 'all.globaltests', null ), + ut3_develop.ut_annotation( 9, 'test', null, 'foo'), + ut3_develop.ut_annotation( 12, 'ann3', 'Name of suite', null ), + ut3_develop.ut_annotation( 13, 'ann4', 'all.globaltests', null ), + ut3_develop.ut_annotation( 15, 'test', null, 'bar') ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -78,8 +78,8 @@ create or replace package body test_annotation_parser is procedure parse_complex_with_functions is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS @@ -110,17 +110,17 @@ create or replace package body test_annotation_parser is END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', null, null ), - ut3.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), - ut3.ut_annotation( 6, 'test', null, 'foo' ), - ut3.ut_annotation( 10, 'beforeeach', null,'foo2' ), - ut3.ut_annotation( 20, 'beforeeach', 'key=testval','foo3' ), - ut3.ut_annotation( 23, 'all', null,'foo4' ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), + ut3_develop.ut_annotation( 6, 'test', null, 'foo' ), + ut3_develop.ut_annotation( 10, 'beforeeach', null,'foo2' ), + ut3_develop.ut_annotation( 20, 'beforeeach', 'key=testval','foo3' ), + ut3_develop.ut_annotation( 23, 'all', null,'foo4' ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -129,8 +129,8 @@ create or replace package body test_annotation_parser is procedure no_procedure_annotation is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS @@ -142,13 +142,13 @@ create or replace package body test_annotation_parser is END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', null, null ), - ut3.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -157,8 +157,8 @@ create or replace package body test_annotation_parser is procedure parse_accessible_by is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt accessible by (foo) AS @@ -170,13 +170,13 @@ create or replace package body test_annotation_parser is END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', null, null ), - ut3.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -185,8 +185,8 @@ create or replace package body test_annotation_parser is procedure complex_package_declaration is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt @@ -201,13 +201,13 @@ create or replace package body test_annotation_parser is END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 5, 'suite', null, null ), - ut3.ut_annotation( 6, 'displayname', 'Name of suite', null ), - ut3.ut_annotation( 7, 'suitepath', 'all.globaltests', null ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 5, 'suite', null, null ), + ut3_develop.ut_annotation( 6, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 7, 'suitepath', 'all.globaltests', null ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -216,8 +216,8 @@ create or replace package body test_annotation_parser is procedure complex_text is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS @@ -229,13 +229,13 @@ create or replace package body test_annotation_parser is END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', null, null ), - ut3.ut_annotation( 3, 'displayname', 'name = Name of suite', null ), - ut3.ut_annotation( 4, 'suitepath', 'key=all.globaltests,key2=foo,"--%some text"', null ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'name = Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'key=all.globaltests,key2=foo,"--%some text"', null ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -244,8 +244,8 @@ create or replace package body test_annotation_parser is procedure ignore_annotations_in_comments is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS @@ -262,13 +262,13 @@ create or replace package body test_annotation_parser is END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 7, 'suite', null, null ), - ut3.ut_annotation( 8, 'displayname', 'Name of suite', null ), - ut3.ut_annotation( 9, 'suitepath', 'all.globaltests', null ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 7, 'suite', null, null ), + ut3_develop.ut_annotation( 8, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 9, 'suitepath', 'all.globaltests', null ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -277,7 +277,7 @@ create or replace package body test_annotation_parser is procedure ignore_wrapped_package is l_source dbms_preprocessor.source_lines_t; - l_actual ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; begin --Arrange l_source(1) := 'create or replace PACKAGE tst_wrapped_pck wrapped @@ -305,7 +305,7 @@ v58yvbLAXLi9gYHwoIvAgccti+Cmpg0DKLY= -- %some_annotation_like_text '; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source,'PACKAGE'); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source,'PACKAGE'); --Assert ut.expect(anydata.convertCollection(l_actual)).to_be_empty(); end; @@ -313,19 +313,19 @@ v58yvbLAXLi9gYHwoIvAgccti+Cmpg0DKLY= procedure brackets_in_desc is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS -- %suite(Name of suite (including some brackets) and some more text) END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', 'Name of suite (including some brackets) and some more text', null ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', 'Name of suite (including some brackets) and some more text', null ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -333,8 +333,8 @@ END;'; procedure test_space_before_annot_params is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS @@ -349,12 +349,12 @@ END;'; END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 6, 'suite', null, null ), - ut3.ut_annotation( 7, 'suitepath', 'all.globaltests', null ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 6, 'suite', null, null ), + ut3_develop.ut_annotation( 7, 'suitepath', 'all.globaltests', null ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -363,8 +363,8 @@ END;'; procedure test_windows_newline as l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS -- %suite @@ -373,13 +373,13 @@ END;'; END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', null, null ), - ut3.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -388,8 +388,8 @@ END;'; procedure test_annot_very_long_name as l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it AS -- %suite @@ -401,14 +401,14 @@ END;'; END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', null, null ), - ut3.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), - ut3.ut_annotation( 6, 'test', null, 'very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it' ) + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), + ut3_develop.ut_annotation( 6, 'test', null, 'very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it' ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -416,8 +416,8 @@ END;'; procedure test_upper_annot is l_source clob; - l_actual ut3.ut_annotations; - l_expected ut3.ut_annotations; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin l_source := 'PACKAGE test_tt AS -- %SUITE @@ -438,19 +438,19 @@ END;'; END;'; --Act - l_actual := ut3.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); --Assert - l_expected := ut3.ut_annotations( - ut3.ut_annotation( 2, 'suite', null, null ), - ut3.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), - ut3.ut_annotation( 6, 'ann1', 'Name of suite', null ), - ut3.ut_annotation( 7, 'ann2', 'all.globaltests', null ), - ut3.ut_annotation( 9, 'test', null, 'foo'), - ut3.ut_annotation( 12, 'ann3', 'Name of suite', null ), - ut3.ut_annotation( 13, 'ann4', 'all.globaltests', null ), - ut3.ut_annotation( 15, 'test', null, 'bar') + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), + ut3_develop.ut_annotation( 6, 'ann1', 'Name of suite', null ), + ut3_develop.ut_annotation( 7, 'ann2', 'all.globaltests', null ), + ut3_develop.ut_annotation( 9, 'test', null, 'foo'), + ut3_develop.ut_annotation( 12, 'ann3', 'Name of suite', null ), + ut3_develop.ut_annotation( 13, 'ann4', 'all.globaltests', null ), + ut3_develop.ut_annotation( 15, 'test', null, 'bar') ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); diff --git a/test/ut3_tester/core/annotations/test_before_after_annotations.pkb b/test/ut3_tester/core/annotations/test_before_after_annotations.pkb index e2f34e847..75bbadcc0 100644 --- a/test/ut3_tester/core/annotations/test_before_after_annotations.pkb +++ b/test/ut3_tester/core/annotations/test_before_after_annotations.pkb @@ -28,7 +28,7 @@ create or replace package body test_before_after_annotations is l_dummy_utility_pkg_body varchar2(32737); l_test_package_spec varchar2(32737); l_test_package_body varchar2(32737); - l_test_results ut3.ut_varchar2_list; + l_test_results ut3_develop.ut_varchar2_list; begin l_dummy_utility_pkg_spec := q'[ @@ -200,7 +200,7 @@ create or replace package body test_before_after_annotations is execute immediate l_test_package_body; --Execute the tests and collect the results - select * bulk collect into l_test_results from table(ut3.ut.run(('ut3_tester.dummy_before_after_test'))); + select * bulk collect into l_test_results from table(ut3_develop.ut.run(('ut3_tester.dummy_before_after_test'))); execute immediate 'drop package dummy_before_after_test'; execute immediate 'drop package shared_test_package'; diff --git a/test/ut3_tester/core/expectations/test_expectation_processor.pkb b/test/ut3_tester/core/expectations/test_expectation_processor.pkb index c061e55d4..63ce3c791 100644 --- a/test/ut3_tester/core/expectations/test_expectation_processor.pkb +++ b/test/ut3_tester/core/expectations/test_expectation_processor.pkb @@ -33,7 +33,7 @@ cba24bfad0 75 SCH_TEST.UT_LOGICAL_SUITE 20be951ab0 320 package body SCH_TEST.UT ]'; ut.expect( - ut3.ut_expectation_processor.who_called_expectation(l_stack_trace) + ut3_develop.ut_expectation_processor.who_called_expectation(l_stack_trace) ).to_equal('at "'||gc_user||'.TEST_EXPECTATION_PROCESSOR", line 7 l_source_line varchar2(4000); at "'||gc_user||'.TEST_EXPECTATION_PROCESSOR", line 12 at "'||gc_user||'.TEST_EXPECTATION_PROCESSOR", line 24'); @@ -47,24 +47,24 @@ at "'||gc_user||'.TEST_EXPECTATION_PROCESSOR", line 24'); l_stack_trace := q'[----- PL/SQL Call Stack ----- object line object handle number name -0x80e701d8 26 UT3.UT_EXPECTATION_RESULT -0x85e10150 112 UT3.UT_EXPECTATION -0x8b54bad8 21 UT3.UT_EXPECTATION_NUMBER -0x85cfd238 20 package body UT3.UT_EXAMPLETEST +0x80e701d8 26 UT3_DEVELOP.UT_EXPECTATION_RESULT +0x85e10150 112 UT3_DEVELOP.UT_EXPECTATION +0x8b54bad8 21 UT3_DEVELOP.UT_EXPECTATION_NUMBER +0x85cfd238 20 package body UT3_DEVELOP.UT_EXAMPLETEST 0x85def380 6 anonymous block 0x85e93750 1825 package body SYS.DBMS_SQL -0x80f4f608 129 UT3.UT_EXECUTABLE -0x80f4f608 65 UT3.UT_EXECUTABLE -0x8a116010 76 UT3.UT_TEST -0x8a3348a0 48 UT3.UT_SUITE_ITEM -0x887e9948 67 UT3.UT_LOGICAL_SUITE -0x8a26de20 59 UT3.UT_RUN -0x8a3348a0 48 UT3.UT_SUITE_ITEM +0x80f4f608 129 UT3_DEVELOP.UT_EXECUTABLE +0x80f4f608 65 UT3_DEVELOP.UT_EXECUTABLE +0x8a116010 76 UT3_DEVELOP.UT_TEST +0x8a3348a0 48 UT3_DEVELOP.UT_SUITE_ITEM +0x887e9948 67 UT3_DEVELOP.UT_LOGICAL_SUITE +0x8a26de20 59 UT3_DEVELOP.UT_RUN +0x8a3348a0 48 UT3_DEVELOP.UT_SUITE_ITEM 0x838d17c0 28 anonymous block ]'; ut.expect( - ut3.ut_expectation_processor.who_called_expectation(l_stack_trace) - ).to_be_like('at "UT3.UT_EXAMPLETEST", line 20 %'); + ut3_develop.ut_expectation_processor.who_called_expectation(l_stack_trace) + ).to_be_like('at "UT3_DEVELOP.UT_EXAMPLETEST", line 20 %'); end; procedure who_call_expectation_win_stack is @@ -82,22 +82,22 @@ handle number name 00007FF81FF207B0 345 type body SCOTT.TEST_BETWNSTR.BASIC_USAGE_TYP 00007FF8544B21B8 6 anonymous block 00007FF8267FBFC8 1721 package body SYS.DBMS_SQL.EXECUTE -00007FF852BCFC68 142 type body UT3.UT_EXECUTABLE.DO_EXECUTE -00007FF852BCFC68 44 type body UT3.UT_EXECUTABLE.DO_EXECUTE -00007FF8512F9A90 74 type body UT3.UT_EXECUTABLE_TEST.DO_EXECUTE -00007FF8512F9A90 38 type body UT3.UT_EXECUTABLE_TEST.DO_EXECUTE -00007FF8231A2088 79 type body UT3.UT_TEST.DO_EXECUTE -00007FF81FF207B0 49 type body UT3.UT_SUITE_ITEM.DO_EXECUTE -00007FF852C83270 66 type body UT3.UT_SUITE.DO_EXECUTE -00007FF82165F3B0 67 type body UT3.UT_RUN.DO_EXECUTE -00007FF81FF207B0 49 type body UT3.UT_SUITE_ITEM.DO_EXECUTE -00007FF8266285C0 172 package body UT3.UT_RUNNER.RUN -00007FF854710538 134 package body UT3.UT.RUN_AUTONOMOUS -00007FF854710538 488 package body UT3.UT.RUN -00007FF854710538 623 package body UT3.UT.RUN +00007FF852BCFC68 142 type body UT3_DEVELOP.UT_EXECUTABLE.DO_EXECUTE +00007FF852BCFC68 44 type body UT3_DEVELOP.UT_EXECUTABLE.DO_EXECUTE +00007FF8512F9A90 74 type body UT3_DEVELOP.UT_EXECUTABLE_TEST.DO_EXECUTE +00007FF8512F9A90 38 type body UT3_DEVELOP.UT_EXECUTABLE_TEST.DO_EXECUTE +00007FF8231A2088 79 type body UT3_DEVELOP.UT_TEST.DO_EXECUTE +00007FF81FF207B0 49 type body UT3_DEVELOP.UT_SUITE_ITEM.DO_EXECUTE +00007FF852C83270 66 type body UT3_DEVELOP.UT_SUITE.DO_EXECUTE +00007FF82165F3B0 67 type body UT3_DEVELOP.UT_RUN.DO_EXECUTE +00007FF81FF207B0 49 type body UT3_DEVELOP.UT_SUITE_ITEM.DO_EXECUTE +00007FF8266285C0 172 package body UT3_DEVELOP.UT_RUNNER.RUN +00007FF854710538 134 package body UT3_DEVELOP.UT.RUN_AUTONOMOUS +00007FF854710538 488 package body UT3_DEVELOP.UT.RUN +00007FF854710538 623 package body UT3_DEVELOP.UT.RUN 00007FF81CFFA388 1 anonymous block]'; ut.expect( - ut3.ut_expectation_processor.who_called_expectation(l_stack_trace) + ut3_develop.ut_expectation_processor.who_called_expectation(l_stack_trace) ).to_be_like('at "SCOTT.TEST_BETWNSTR.BASIC_USAGE", line 7 %'); end; diff --git a/test/ut3_tester/core/test_file_mapper.pkb b/test/ut3_tester/core/test_file_mapper.pkb index 3813c9450..fccc487bd 100644 --- a/test/ut3_tester/core/test_file_mapper.pkb +++ b/test/ut3_tester/core/test_file_mapper.pkb @@ -1,17 +1,17 @@ create or replace package body test_file_mapper is procedure default_mappings is - l_actual ut3.ut_file_mappings; - l_expected ut3.ut_file_mappings; + l_actual ut3_develop.ut_file_mappings; + l_expected ut3_develop.ut_file_mappings; begin --Arrange - l_expected := ut3.ut_file_mappings( - ut3.ut_file_mapping('C:\tests\helpers\core.pkb',sys_context('USERENV', 'CURRENT_USER'),'CORE','PACKAGE BODY'), - ut3.ut_file_mapping('tests/helpers/test_file_mapper.pkb',sys_context('USERENV', 'CURRENT_USER'),'TEST_FILE_MAPPER','PACKAGE BODY') + l_expected := ut3_develop.ut_file_mappings( + ut3_develop.ut_file_mapping('C:\tests\helpers\core.pkb',sys_context('USERENV', 'CURRENT_USER'),'CORE','PACKAGE BODY'), + ut3_develop.ut_file_mapping('tests/helpers/test_file_mapper.pkb',sys_context('USERENV', 'CURRENT_USER'),'TEST_FILE_MAPPER','PACKAGE BODY') ); --Act - l_actual := ut3.ut_file_mapper.build_file_mappings( - ut3.ut_varchar2_list( + l_actual := ut3_develop.ut_file_mapper.build_file_mappings( + ut3_develop.ut_varchar2_list( 'C:\tests\helpers\core.pkb', 'tests/helpers/test_file_mapper.pkb' ) @@ -21,18 +21,18 @@ create or replace package body test_file_mapper is end; procedure specific_owner is - l_actual ut3.ut_file_mappings; - l_expected ut3.ut_file_mappings; + l_actual ut3_develop.ut_file_mappings; + l_expected ut3_develop.ut_file_mappings; begin --Arrange - l_expected := ut3.ut_file_mappings( - ut3.ut_file_mapping('C:\source\core\types\ut_file_mapping.tpb','UT3','UT_FILE_MAPPING','TYPE BODY'), - ut3.ut_file_mapping('source/core/ut_file_mapper.pkb','UT3','UT_FILE_MAPPER','PACKAGE BODY') + l_expected := ut3_develop.ut_file_mappings( + ut3_develop.ut_file_mapping('C:\source\core\types\ut_file_mapping.tpb','UT3_DEVELOP','UT_FILE_MAPPING','TYPE BODY'), + ut3_develop.ut_file_mapping('source/core/ut_file_mapper.pkb','UT3_DEVELOP','UT_FILE_MAPPER','PACKAGE BODY') ); --Act - l_actual := ut3.ut_file_mapper.build_file_mappings( - 'UT3', - ut3.ut_varchar2_list( + l_actual := ut3_develop.ut_file_mapper.build_file_mappings( + 'UT3_DEVELOP', + ut3_develop.ut_varchar2_list( 'C:\source\core\types\ut_file_mapping.tpb', 'source/core/ut_file_mapper.pkb' ) diff --git a/test/ut3_tester/core/test_output_buffer.pkb b/test/ut3_tester/core/test_output_buffer.pkb index 7aab6f389..a552cc567 100644 --- a/test/ut3_tester/core/test_output_buffer.pkb +++ b/test/ut3_tester/core/test_output_buffer.pkb @@ -6,10 +6,10 @@ create or replace package body test_output_buffer is l_remaining integer; l_expected_text clob; l_expected_item_type varchar2(1000); - l_buffer ut3.ut_output_buffer_base; + l_buffer ut3_develop.ut_output_buffer_base; begin --Arrange - l_buffer := ut3.ut_output_clob_table_buffer(); + l_buffer := ut3_develop.ut_output_clob_table_buffer(); l_expected_text := to_clob(lpad('a text', 31000, ',a text')) || chr(10) || to_clob(lpad('a text', 31000, ',a text')) || chr(13) || to_clob(lpad('a text', 31000, ',a text')) @@ -36,7 +36,7 @@ create or replace package body test_output_buffer is procedure test_doesnt_send_on_null_text is l_cur sys_refcursor; l_result integer; - l_buffer ut3.ut_output_buffer_base := ut3.ut_output_table_buffer(); + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); begin ut3_tester_helper.run_helper.delete_buffer(); --Act @@ -50,14 +50,14 @@ create or replace package body test_output_buffer is procedure test_doesnt_send_on_null_elem is l_cur sys_refcursor; l_result integer; - l_buffer ut3.ut_output_buffer_base := ut3.ut_output_table_buffer(); + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); l_message_id varchar2(255); l_text varchar2(4000); begin ut3_tester_helper.run_helper.delete_buffer(); --Act - l_buffer.send_lines(ut3.ut_varchar2_rows(null)); - l_buffer.send_lines(ut3.ut_varchar2_rows('test')); + l_buffer.send_lines(ut3_develop.ut_varchar2_rows(null)); + l_buffer.send_lines(ut3_develop.ut_varchar2_rows('test')); select message_id, text into l_message_id, l_text from table(ut3_tester_helper.run_helper.ut_output_buffer_tmp); ut.expect(l_message_id).to_equal('1'); @@ -67,7 +67,7 @@ create or replace package body test_output_buffer is procedure test_send_line is l_result varchar2(4000); c_expected constant varchar2(4000) := lpad('a text',4000,',a text'); - l_buffer ut3.ut_output_buffer_base := ut3.ut_output_table_buffer(); + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); begin l_buffer.send_line(c_expected); @@ -80,7 +80,7 @@ create or replace package body test_output_buffer is l_result clob; l_remaining integer; l_expected clob; - l_buffer ut3.ut_output_buffer_base := ut3.ut_output_table_buffer(); + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); l_start timestamp; l_duration interval day to second; begin @@ -99,7 +99,7 @@ create or replace package body test_output_buffer is --Fetches data from output ut.expect(l_result).to_equal(l_expected); --Throws a timeout exception - ut.expect(dbms_utility.format_error_stack()).to_match('ORA'||ut3.ut_utils.gc_out_buffer_timeout); + ut.expect(dbms_utility.format_error_stack()).to_match('ORA'||ut3_develop.ut_utils.gc_out_buffer_timeout); --Waited for one second ut.expect(l_duration).to_be_greater_than(interval '0.99' second); end; @@ -110,10 +110,10 @@ create or replace package body test_output_buffer is end; - procedure test_purge(a_buffer ut3.ut_output_buffer_base ) is - l_stale_buffer ut3.ut_output_buffer_base := a_buffer; - l_fresh_buffer ut3.ut_output_buffer_base; - l_buffer ut3.ut_output_buffer_base; + procedure test_purge(a_buffer ut3_develop.ut_output_buffer_base ) is + l_stale_buffer ut3_develop.ut_output_buffer_base := a_buffer; + l_fresh_buffer ut3_develop.ut_output_buffer_base; + l_buffer ut3_develop.ut_output_buffer_base; begin --Arrange l_stale_buffer.start_date := sysdate - 2; @@ -122,12 +122,12 @@ create or replace package body test_output_buffer is l_stale_buffer.send_line('some text'); l_stale_buffer.close(); - l_fresh_buffer := ut3.ut_output_table_buffer(); + l_fresh_buffer := ut3_develop.ut_output_table_buffer(); l_fresh_buffer.send_line('some text'); l_fresh_buffer.close(); --Act - purge is performed on new buffer create - l_buffer := ut3.ut_output_table_buffer(); + l_buffer := ut3_develop.ut_output_table_buffer(); --Assert -- Data in "fresh" buffer remains @@ -138,12 +138,12 @@ create or replace package body test_output_buffer is procedure test_purge_text_buffer is begin - test_purge(ut3.ut_output_table_buffer()); + test_purge(ut3_develop.ut_output_table_buffer()); end; procedure test_purge_clob_buffer is begin - test_purge(ut3.ut_output_clob_table_buffer()); + test_purge(ut3_develop.ut_output_clob_table_buffer()); end; end test_output_buffer; diff --git a/test/ut3_tester/core/test_suite_builder.pkb b/test/ut3_tester/core/test_suite_builder.pkb index 8eedc1142..570d86a0d 100644 --- a/test/ut3_tester/core/test_suite_builder.pkb +++ b/test/ut3_tester/core/test_suite_builder.pkb @@ -1,29 +1,29 @@ create or replace package body test_suite_builder is function invoke_builder_for_annotations( - a_annotations ut3.ut_annotations, + a_annotations ut3_develop.ut_annotations, a_package_name varchar2 := 'TEST_SUITE_BUILDER_PACKAGE' ) return clob is - l_suites ut3.ut_suite_items; - l_suite ut3.ut_logical_suite; + l_suites ut3_develop.ut_suite_items; + l_suite ut3_develop.ut_logical_suite; l_cursor sys_refcursor; l_type_cursor sys_refcursor; l_ctx dbms_xmlgen.ctxhandle; l_xml xmltype; begin open l_cursor for select value(x) from table( - ut3.ut_annotated_objects( - ut3.ut_annotated_object('UT3_TESTER', a_package_name, 'PACKAGE', systimestamp, a_annotations) + ut3_develop.ut_annotated_objects( + ut3_develop.ut_annotated_object('UT3_TESTER', a_package_name, 'PACKAGE', systimestamp, a_annotations) ) ) x; - l_suites := ut3.ut_suite_manager.build_suites_from_annotations( + l_suites := ut3_develop.ut_suite_manager.build_suites_from_annotations( a_owner_name => 'UT3_TESTER', a_annotated_objects => l_cursor, a_path => null, a_object_name => a_package_name, a_skip_all_objects => true ); - l_suite := treat( l_suites(l_suites.first) as ut3.ut_logical_suite); + l_suite := treat( l_suites(l_suites.first) as ut3_develop.ut_logical_suite); open l_type_cursor for select l_suite as "UT_LOGICAL_SUITE" from dual; l_ctx := dbms_xmlgen.newcontext(l_type_cursor); @@ -43,11 +43,11 @@ create or replace package body test_suite_builder is procedure no_suite_description is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -59,12 +59,12 @@ create or replace package body test_suite_builder is procedure suite_description_from_suite is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Some description', null), - ut3.ut_annotation(2, 'suite','Another description', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Some description', null), + ut3_develop.ut_annotation(2, 'suite','Another description', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -76,13 +76,13 @@ create or replace package body test_suite_builder is procedure suitepath_from_non_empty_path is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite',null, null), - ut3.ut_annotation(2, 'suitepath','org.utplsql.some', null), - ut3.ut_annotation(3, 'suitepath','dummy.utplsql.some', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite',null, null), + ut3_develop.ut_annotation(2, 'suitepath','org.utplsql.some', null), + ut3_develop.ut_annotation(3, 'suitepath','dummy.utplsql.some', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -94,14 +94,14 @@ create or replace package body test_suite_builder is procedure suite_descr_from_displayname is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Some description', null), - ut3.ut_annotation(2, 'suite','Another description', null), - ut3.ut_annotation(3, 'displayname','New description', null), - ut3.ut_annotation(4, 'displayname','Newest description', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Some description', null), + ut3_develop.ut_annotation(2, 'suite','Another description', null), + ut3_develop.ut_annotation(3, 'displayname','New description', null), + ut3_develop.ut_annotation(4, 'displayname','Newest description', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -113,31 +113,31 @@ create or replace package body test_suite_builder is procedure rollback_type_valid is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite',null, null), - ut3.ut_annotation(2, 'rollback','manual', null), - ut3.ut_annotation(3, 'rollback','bad', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite',null, null), + ut3_develop.ut_annotation(2, 'rollback','manual', null), + ut3_develop.ut_annotation(3, 'rollback','bad', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); --Assert ut.expect(l_actual).to_be_like( - '%'||ut3.ut_utils.gc_rollback_manual||'%' + '%'||ut3_develop.ut_utils.gc_rollback_manual||'%' ); end; procedure rollback_type_duplicated is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite',null, null), - ut3.ut_annotation(2, 'rollback','manual', null), - ut3.ut_annotation(3, 'rollback','bad', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite',null, null), + ut3_develop.ut_annotation(2, 'rollback','manual', null), + ut3_develop.ut_annotation(3, 'rollback','bad', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -149,12 +149,12 @@ create or replace package body test_suite_builder is procedure suite_annot_duplicated is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','Cool', null), - ut3.ut_annotation(8, 'suite','bad', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','Cool', null), + ut3_develop.ut_annotation(8, 'suite','bad', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -166,12 +166,12 @@ create or replace package body test_suite_builder is procedure test_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','Cool', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','Cool', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -185,13 +185,13 @@ create or replace package body test_suite_builder is procedure test_annot_duplicated is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','Cool', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'test','Dup', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','Cool', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'test','Dup', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -203,13 +203,13 @@ create or replace package body test_suite_builder is procedure beforeall_annot_duplicated is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','Cool', null), - ut3.ut_annotation(8, 'beforeall', null, 'test_procedure'), - ut3.ut_annotation(9, 'beforeall', null, 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','Cool', null), + ut3_develop.ut_annotation(8, 'beforeall', null, 'test_procedure'), + ut3_develop.ut_annotation(9, 'beforeall', null, 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -221,13 +221,13 @@ create or replace package body test_suite_builder is procedure beforeeach_annot_duplicated is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','Cool', null), - ut3.ut_annotation(8, 'beforeeach', null, 'test_procedure'), - ut3.ut_annotation(9, 'beforeeach', null, 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','Cool', null), + ut3_develop.ut_annotation(8, 'beforeeach', null, 'test_procedure'), + ut3_develop.ut_annotation(9, 'beforeeach', null, 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -239,13 +239,13 @@ create or replace package body test_suite_builder is procedure afterall_annot_duplicated is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','Cool', null), - ut3.ut_annotation(8, 'afterall', null, 'test_procedure'), - ut3.ut_annotation(9, 'afterall', null, 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','Cool', null), + ut3_develop.ut_annotation(8, 'afterall', null, 'test_procedure'), + ut3_develop.ut_annotation(9, 'afterall', null, 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -257,13 +257,13 @@ create or replace package body test_suite_builder is procedure aftereach_annot_duplicated is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','Cool', null), - ut3.ut_annotation(8, 'aftereach', null, 'test_procedure'), - ut3.ut_annotation(9, 'aftereach', null, 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','Cool', null), + ut3_develop.ut_annotation(8, 'aftereach', null, 'test_procedure'), + ut3_develop.ut_annotation(9, 'aftereach', null, 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -275,13 +275,13 @@ create or replace package body test_suite_builder is procedure suitepath_annot_duplicated is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','Cool', null), - ut3.ut_annotation(3, 'suitepath','dummy.utplsql.some', null), - ut3.ut_annotation(4, 'suitepath','org.utplsql.some', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','Cool', null), + ut3_develop.ut_annotation(3, 'suitepath','dummy.utplsql.some', null), + ut3_develop.ut_annotation(4, 'suitepath','org.utplsql.some', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -293,13 +293,13 @@ create or replace package body test_suite_builder is procedure displayname_annot_duplicated is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','Cool', null), - ut3.ut_annotation(4, 'displayname','New description', null), - ut3.ut_annotation(5, 'displayname','Newest description', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','Cool', null), + ut3_develop.ut_annotation(4, 'displayname','New description', null), + ut3_develop.ut_annotation(5, 'displayname','Newest description', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -311,12 +311,12 @@ create or replace package body test_suite_builder is procedure suitepath_annot_empty is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(3, 'suitepath',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(3, 'suitepath',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -328,12 +328,12 @@ create or replace package body test_suite_builder is procedure suitepath_annot_invalid_path is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'suitepath','path with spaces', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'suitepath','path with spaces', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -345,12 +345,12 @@ create or replace package body test_suite_builder is procedure displayname_annot_empty is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(3, 'displayname',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(3, 'displayname',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -362,12 +362,12 @@ create or replace package body test_suite_builder is procedure rollback_type_empty is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(3, 'rollback',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(3, 'rollback',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -379,12 +379,12 @@ create or replace package body test_suite_builder is procedure rollback_type_invalid is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'rollback','bad', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'rollback','bad', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -396,24 +396,24 @@ create or replace package body test_suite_builder is procedure multiple_before_after is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall',null, 'first_before_all'), - ut3.ut_annotation(3, 'beforeall',null, 'another_before_all'), - ut3.ut_annotation(4, 'beforeeach',null, 'first_before_each'), - ut3.ut_annotation(5, 'beforeeach',null, 'another_before_each'), - ut3.ut_annotation(6, 'aftereach',null, 'first_after_each'), - ut3.ut_annotation(7, 'aftereach',null, 'another_after_each'), - ut3.ut_annotation(8, 'afterall',null, 'first_after_all'), - ut3.ut_annotation(9, 'afterall',null, 'another_after_all'), - ut3.ut_annotation(14, 'test','A test', 'some_test'), - ut3.ut_annotation(15, 'beforetest','before_test_proc', 'some_test'), - ut3.ut_annotation(16, 'beforetest','before_test_proc2', 'some_test'), - ut3.ut_annotation(18, 'aftertest','after_test_proc', 'some_test'), - ut3.ut_annotation(20, 'aftertest','after_test_proc2', 'some_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall',null, 'first_before_all'), + ut3_develop.ut_annotation(3, 'beforeall',null, 'another_before_all'), + ut3_develop.ut_annotation(4, 'beforeeach',null, 'first_before_each'), + ut3_develop.ut_annotation(5, 'beforeeach',null, 'another_before_each'), + ut3_develop.ut_annotation(6, 'aftereach',null, 'first_after_each'), + ut3_develop.ut_annotation(7, 'aftereach',null, 'another_after_each'), + ut3_develop.ut_annotation(8, 'afterall',null, 'first_after_all'), + ut3_develop.ut_annotation(9, 'afterall',null, 'another_after_all'), + ut3_develop.ut_annotation(14, 'test','A test', 'some_test'), + ut3_develop.ut_annotation(15, 'beforetest','before_test_proc', 'some_test'), + ut3_develop.ut_annotation(16, 'beforetest','before_test_proc2', 'some_test'), + ut3_develop.ut_annotation(18, 'aftertest','after_test_proc', 'some_test'), + ut3_develop.ut_annotation(20, 'aftertest','after_test_proc2', 'some_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -450,24 +450,24 @@ create or replace package body test_suite_builder is procedure multiple_standalone_bef_aft is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall', 'some_package.first_before_all',null), - ut3.ut_annotation(3, 'beforeall', 'different_package.another_before_all',null), - ut3.ut_annotation(4, 'beforeeach', 'first_before_each',null), - ut3.ut_annotation(5, 'beforeeach', 'different_owner.different_package.another_before_each',null), - ut3.ut_annotation(6, 'aftereach', 'first_after_each',null), - ut3.ut_annotation(7, 'aftereach', 'another_after_each,different_owner.different_package.one_more_after_each',null), - ut3.ut_annotation(8, 'afterall', 'first_after_all',null), - ut3.ut_annotation(9, 'afterall', 'another_after_all',null), - ut3.ut_annotation(14, 'test','A test', 'some_test'), - ut3.ut_annotation(15, 'beforetest','before_test_proc', 'some_test'), - ut3.ut_annotation(16, 'beforetest','before_test_proc2', 'some_test'), - ut3.ut_annotation(18, 'aftertest','after_test_proc', 'some_test'), - ut3.ut_annotation(20, 'aftertest','after_test_proc2', 'some_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall', 'some_package.first_before_all',null), + ut3_develop.ut_annotation(3, 'beforeall', 'different_package.another_before_all',null), + ut3_develop.ut_annotation(4, 'beforeeach', 'first_before_each',null), + ut3_develop.ut_annotation(5, 'beforeeach', 'different_owner.different_package.another_before_each',null), + ut3_develop.ut_annotation(6, 'aftereach', 'first_after_each',null), + ut3_develop.ut_annotation(7, 'aftereach', 'another_after_each,different_owner.different_package.one_more_after_each',null), + ut3_develop.ut_annotation(8, 'afterall', 'first_after_all',null), + ut3_develop.ut_annotation(9, 'afterall', 'another_after_all',null), + ut3_develop.ut_annotation(14, 'test','A test', 'some_test'), + ut3_develop.ut_annotation(15, 'beforetest','before_test_proc', 'some_test'), + ut3_develop.ut_annotation(16, 'beforetest','before_test_proc2', 'some_test'), + ut3_develop.ut_annotation(18, 'aftertest','after_test_proc', 'some_test'), + ut3_develop.ut_annotation(20, 'aftertest','after_test_proc2', 'some_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -505,16 +505,16 @@ create or replace package body test_suite_builder is procedure before_after_on_single_proc is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall',null, 'do_stuff'), - ut3.ut_annotation(3, 'beforeeach',null, 'do_stuff'), - ut3.ut_annotation(4, 'aftereach',null, 'do_stuff'), - ut3.ut_annotation(5, 'afterall',null, 'do_stuff'), - ut3.ut_annotation(6, 'test','A test', 'some_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall',null, 'do_stuff'), + ut3_develop.ut_annotation(3, 'beforeeach',null, 'do_stuff'), + ut3_develop.ut_annotation(4, 'aftereach',null, 'do_stuff'), + ut3_develop.ut_annotation(5, 'afterall',null, 'do_stuff'), + ut3_develop.ut_annotation(6, 'test','A test', 'some_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -539,27 +539,27 @@ create or replace package body test_suite_builder is procedure multiple_mixed_bef_aft is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall', null,'first_before_all'), - ut3.ut_annotation(3, 'beforeall', 'different_package.another_before_all',null), - ut3.ut_annotation(4, 'beforeeach', 'first_before_each',null), - ut3.ut_annotation(5, 'beforeeach', 'different_owner.different_package.another_before_each',null), - ut3.ut_annotation(6, 'aftereach', null, 'first_after_each'), - ut3.ut_annotation(7, 'aftereach', 'another_after_each,different_owner.different_package.one_more_after_each',null), - ut3.ut_annotation(8, 'afterall', 'first_after_all',null), - ut3.ut_annotation(9, 'afterall', 'another_after_all',null), - ut3.ut_annotation(14, 'test','A test', 'some_test'), - ut3.ut_annotation(15, 'beforetest','before_test_proc', 'some_test'), - ut3.ut_annotation(16, 'beforetest','before_test_proc2', 'some_test'), - ut3.ut_annotation(18, 'aftertest','after_test_proc', 'some_test'), - ut3.ut_annotation(20, 'aftertest','after_test_proc2', 'some_test'), - ut3.ut_annotation(21, 'beforeall', null,'last_before_all'), - ut3.ut_annotation(22, 'aftereach', null, 'last_after_each'), - ut3.ut_annotation(23, 'afterall', null, 'last_after_all') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall', null,'first_before_all'), + ut3_develop.ut_annotation(3, 'beforeall', 'different_package.another_before_all',null), + ut3_develop.ut_annotation(4, 'beforeeach', 'first_before_each',null), + ut3_develop.ut_annotation(5, 'beforeeach', 'different_owner.different_package.another_before_each',null), + ut3_develop.ut_annotation(6, 'aftereach', null, 'first_after_each'), + ut3_develop.ut_annotation(7, 'aftereach', 'another_after_each,different_owner.different_package.one_more_after_each',null), + ut3_develop.ut_annotation(8, 'afterall', 'first_after_all',null), + ut3_develop.ut_annotation(9, 'afterall', 'another_after_all',null), + ut3_develop.ut_annotation(14, 'test','A test', 'some_test'), + ut3_develop.ut_annotation(15, 'beforetest','before_test_proc', 'some_test'), + ut3_develop.ut_annotation(16, 'beforetest','before_test_proc2', 'some_test'), + ut3_develop.ut_annotation(18, 'aftertest','after_test_proc', 'some_test'), + ut3_develop.ut_annotation(20, 'aftertest','after_test_proc2', 'some_test'), + ut3_develop.ut_annotation(21, 'beforeall', null,'last_before_all'), + ut3_develop.ut_annotation(22, 'aftereach', null, 'last_after_each'), + ut3_develop.ut_annotation(23, 'afterall', null, 'last_after_all') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -601,16 +601,16 @@ create or replace package body test_suite_builder is procedure before_after_mixed_with_test is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall',null, 'do_stuff'), - ut3.ut_annotation(3, 'beforeeach',null, 'do_stuff'), - ut3.ut_annotation(4, 'aftereach',null, 'do_stuff'), - ut3.ut_annotation(5, 'afterall',null, 'do_stuff'), - ut3.ut_annotation(6, 'test','A test', 'do_stuff') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall',null, 'do_stuff'), + ut3_develop.ut_annotation(3, 'beforeeach',null, 'do_stuff'), + ut3_develop.ut_annotation(4, 'aftereach',null, 'do_stuff'), + ut3_develop.ut_annotation(5, 'afterall',null, 'do_stuff'), + ut3_develop.ut_annotation(6, 'test','A test', 'do_stuff') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -628,18 +628,18 @@ create or replace package body test_suite_builder is procedure suite_from_context is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), - ut3.ut_annotation(3, 'test','In suite', 'suite_level_test'), - ut3.ut_annotation(4, 'context','A context', null), - ut3.ut_annotation(5, 'name','a_context', null), - ut3.ut_annotation(6, 'beforeall',null, 'context_setup'), - ut3.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(8, 'endcontext',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), + ut3_develop.ut_annotation(3, 'test','In suite', 'suite_level_test'), + ut3_develop.ut_annotation(4, 'context','A context', null), + ut3_develop.ut_annotation(5, 'name','a_context', null), + ut3_develop.ut_annotation(6, 'beforeall',null, 'context_setup'), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(8, 'endcontext',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -676,31 +676,31 @@ create or replace package body test_suite_builder is procedure nested_contexts is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation( 1, 'suite','Cool', null), - ut3.ut_annotation( 2, 'beforeall',null, 'suite_level_beforeall'), - ut3.ut_annotation( 3, 'test','In suite', 'suite_level_test'), - ut3.ut_annotation( 4, 'context','A context', null), - ut3.ut_annotation( 5, 'name','a_context', null), - ut3.ut_annotation( 6, 'beforeall',null, 'context_setup'), - ut3.ut_annotation( 7, 'test', 'First test in context', 'first_test_in_a_context'), - ut3.ut_annotation( 8, 'context','A nested context', null), - ut3.ut_annotation( 9, 'name','a_nested_context', null), - ut3.ut_annotation(10, 'beforeall',null, 'nested_context_setup'), - ut3.ut_annotation(11, 'test', 'Test in nested context', 'test_in_nested_context'), - ut3.ut_annotation(12, 'endcontext',null, null), - ut3.ut_annotation(13, 'context',null, null), - ut3.ut_annotation(14, 'name','nested_context_2', null), - ut3.ut_annotation(15, 'test', 'Test in nested context', 'test_in_nested_context_2'), - ut3.ut_annotation(16, 'context','a_nested_context_3', null), - ut3.ut_annotation(17, 'test', 'Test in nested context', 'test_in_nested_context_3'), - ut3.ut_annotation(18, 'endcontext',null, null), - ut3.ut_annotation(19, 'endcontext',null, null), - ut3.ut_annotation(20, 'test', 'Second test in context', 'second_test_in_a_context'), - ut3.ut_annotation(21, 'endcontext',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 1, 'suite','Cool', null), + ut3_develop.ut_annotation( 2, 'beforeall',null, 'suite_level_beforeall'), + ut3_develop.ut_annotation( 3, 'test','In suite', 'suite_level_test'), + ut3_develop.ut_annotation( 4, 'context','A context', null), + ut3_develop.ut_annotation( 5, 'name','a_context', null), + ut3_develop.ut_annotation( 6, 'beforeall',null, 'context_setup'), + ut3_develop.ut_annotation( 7, 'test', 'First test in context', 'first_test_in_a_context'), + ut3_develop.ut_annotation( 8, 'context','A nested context', null), + ut3_develop.ut_annotation( 9, 'name','a_nested_context', null), + ut3_develop.ut_annotation(10, 'beforeall',null, 'nested_context_setup'), + ut3_develop.ut_annotation(11, 'test', 'Test in nested context', 'test_in_nested_context'), + ut3_develop.ut_annotation(12, 'endcontext',null, null), + ut3_develop.ut_annotation(13, 'context',null, null), + ut3_develop.ut_annotation(14, 'name','nested_context_2', null), + ut3_develop.ut_annotation(15, 'test', 'Test in nested context', 'test_in_nested_context_2'), + ut3_develop.ut_annotation(16, 'context','a_nested_context_3', null), + ut3_develop.ut_annotation(17, 'test', 'Test in nested context', 'test_in_nested_context_3'), + ut3_develop.ut_annotation(18, 'endcontext',null, null), + ut3_develop.ut_annotation(19, 'endcontext',null, null), + ut3_develop.ut_annotation(20, 'test', 'Second test in context', 'second_test_in_a_context'), + ut3_develop.ut_annotation(21, 'endcontext',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -769,24 +769,24 @@ create or replace package body test_suite_builder is procedure nested_contexts_2 is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation( 1, 'suite','Cool', null), - ut3.ut_annotation( 2, 'suitepath','path', null), - ut3.ut_annotation( 3, 'context','Level 1', null), - ut3.ut_annotation( 4, 'name','context_1', null), - ut3.ut_annotation( 5, 'context','Level 1.1', null), - ut3.ut_annotation( 6, 'name','context_1_1', null), - ut3.ut_annotation( 7, 'test', 'Test 1.1.1', 'test_1_1_1'), - ut3.ut_annotation( 8, 'test', 'Test 1.1.2', 'test_1_1_2'), - ut3.ut_annotation( 9, 'endcontext', null, null), - ut3.ut_annotation(10, 'endcontext', null, null), - ut3.ut_annotation(11, 'context','Level 2', null), - ut3.ut_annotation(12, 'name','context_2', null), - ut3.ut_annotation(13, 'test', 'Test 2.1', 'test_2_1'), - ut3.ut_annotation(14, 'endcontext',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 1, 'suite','Cool', null), + ut3_develop.ut_annotation( 2, 'suitepath','path', null), + ut3_develop.ut_annotation( 3, 'context','Level 1', null), + ut3_develop.ut_annotation( 4, 'name','context_1', null), + ut3_develop.ut_annotation( 5, 'context','Level 1.1', null), + ut3_develop.ut_annotation( 6, 'name','context_1_1', null), + ut3_develop.ut_annotation( 7, 'test', 'Test 1.1.1', 'test_1_1_1'), + ut3_develop.ut_annotation( 8, 'test', 'Test 1.1.2', 'test_1_1_2'), + ut3_develop.ut_annotation( 9, 'endcontext', null, null), + ut3_develop.ut_annotation(10, 'endcontext', null, null), + ut3_develop.ut_annotation(11, 'context','Level 2', null), + ut3_develop.ut_annotation(12, 'name','context_2', null), + ut3_develop.ut_annotation(13, 'test', 'Test 2.1', 'test_2_1'), + ut3_develop.ut_annotation(14, 'endcontext',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -838,19 +838,19 @@ create or replace package body test_suite_builder is procedure before_after_in_context is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite', 'Cool', null), - ut3.ut_annotation(2, 'test', 'In suite', 'suite_level_test'), - ut3.ut_annotation(3, 'context', 'A context', null), - ut3.ut_annotation(4, 'beforeall', 'context_beforeall', null), - ut3.ut_annotation(5, 'beforeeach', null, 'context_beforeeach'), - ut3.ut_annotation(6, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(7, 'aftereach', 'context_aftereach' ,null), - ut3.ut_annotation(8, 'afterall', null, 'context_afterall'), - ut3.ut_annotation(9, 'endcontext', null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite', 'Cool', null), + ut3_develop.ut_annotation(2, 'test', 'In suite', 'suite_level_test'), + ut3_develop.ut_annotation(3, 'context', 'A context', null), + ut3_develop.ut_annotation(4, 'beforeall', 'context_beforeall', null), + ut3_develop.ut_annotation(5, 'beforeeach', null, 'context_beforeeach'), + ut3_develop.ut_annotation(6, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(7, 'aftereach', 'context_aftereach' ,null), + ut3_develop.ut_annotation(8, 'afterall', null, 'context_afterall'), + ut3_develop.ut_annotation(9, 'endcontext', null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -888,19 +888,19 @@ create or replace package body test_suite_builder is procedure before_after_out_of_context is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), - ut3.ut_annotation(3, 'beforeeach',null, 'suite_level_beforeeach'), - ut3.ut_annotation(4, 'test','In suite', 'suite_level_test'), - ut3.ut_annotation(5, 'context',null, null), - ut3.ut_annotation(6, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(7, 'endcontext',null, null), - ut3.ut_annotation(8, 'aftereach',null, 'suite_level_aftereach'), - ut3.ut_annotation(9, 'afterall',null, 'suite_level_afterall') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), + ut3_develop.ut_annotation(3, 'beforeeach',null, 'suite_level_beforeeach'), + ut3_develop.ut_annotation(4, 'test','In suite', 'suite_level_test'), + ut3_develop.ut_annotation(5, 'context',null, null), + ut3_develop.ut_annotation(6, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(7, 'endcontext',null, null), + ut3_develop.ut_annotation(8, 'aftereach',null, 'suite_level_aftereach'), + ut3_develop.ut_annotation(9, 'afterall',null, 'suite_level_afterall') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -938,17 +938,17 @@ create or replace package body test_suite_builder is procedure context_without_endcontext is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), - ut3.ut_annotation(3, 'test','In suite', 'suite_level_test'), - ut3.ut_annotation(4, 'context','Some context', null), - ut3.ut_annotation(5, 'name','a_context', null), - ut3.ut_annotation(6, 'beforeall',null, 'context_setup'), - ut3.ut_annotation(7, 'test', 'In context', 'test_in_a_context') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), + ut3_develop.ut_annotation(3, 'test','In suite', 'suite_level_test'), + ut3_develop.ut_annotation(4, 'context','Some context', null), + ut3_develop.ut_annotation(5, 'name','a_context', null), + ut3_develop.ut_annotation(6, 'beforeall',null, 'context_setup'), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -987,19 +987,19 @@ create or replace package body test_suite_builder is procedure endcontext_without_context is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), - ut3.ut_annotation(3, 'test','In suite', 'suite_level_test'), - ut3.ut_annotation(4, 'context','A context', null), - ut3.ut_annotation(5, 'name','a_context', null), - ut3.ut_annotation(6, 'beforeall',null, 'context_setup'), - ut3.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(8, 'endcontext',null, null), - ut3.ut_annotation(9, 'endcontext',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), + ut3_develop.ut_annotation(3, 'test','In suite', 'suite_level_test'), + ut3_develop.ut_annotation(4, 'context','A context', null), + ut3_develop.ut_annotation(5, 'name','a_context', null), + ut3_develop.ut_annotation(6, 'beforeall',null, 'context_setup'), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(8, 'endcontext',null, null), + ut3_develop.ut_annotation(9, 'endcontext',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1039,23 +1039,23 @@ create or replace package body test_suite_builder is procedure duplicate_context_name is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), - ut3.ut_annotation(3, 'test','In suite', 'suite_level_test'), - ut3.ut_annotation(4, 'context','A context', null), - ut3.ut_annotation(5, 'name','a_context', null), - ut3.ut_annotation(6, 'beforeall',null, 'context_setup'), - ut3.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(8, 'endcontext',null, null), - ut3.ut_annotation(9, 'context','A context', null), - ut3.ut_annotation(10, 'name','a_context', null), - ut3.ut_annotation(11, 'beforeall',null, 'setup_in_duplicated_context'), - ut3.ut_annotation(12, 'test', 'In duplicated context', 'test_in_duplicated_context'), - ut3.ut_annotation(13, 'endcontext',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), + ut3_develop.ut_annotation(3, 'test','In suite', 'suite_level_test'), + ut3_develop.ut_annotation(4, 'context','A context', null), + ut3_develop.ut_annotation(5, 'name','a_context', null), + ut3_develop.ut_annotation(6, 'beforeall',null, 'context_setup'), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(8, 'endcontext',null, null), + ut3_develop.ut_annotation(9, 'context','A context', null), + ut3_develop.ut_annotation(10, 'name','a_context', null), + ut3_develop.ut_annotation(11, 'beforeall',null, 'setup_in_duplicated_context'), + ut3_develop.ut_annotation(12, 'test', 'In duplicated context', 'test_in_duplicated_context'), + ut3_develop.ut_annotation(13, 'endcontext',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1107,17 +1107,17 @@ create or replace package body test_suite_builder is procedure hard_stop_in_ctx_name is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; l_bad_name varchar2(100); begin --Arrange l_bad_name := 'ctx_with_dot.in_it'; - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(4, 'context',null, null), - ut3.ut_annotation(5, 'name',l_bad_name, null), - ut3.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(13, 'endcontext',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(4, 'context',null, null), + ut3_develop.ut_annotation(5, 'name',l_bad_name, null), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(13, 'endcontext',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1145,17 +1145,17 @@ create or replace package body test_suite_builder is procedure name_with_spaces_invalid is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; l_bad_name varchar2(100); begin --Arrange l_bad_name := 'context name with spaces'; - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(4, 'context',null, null), - ut3.ut_annotation(5, 'name',l_bad_name, null), - ut3.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(13, 'endcontext',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(4, 'context',null, null), + ut3_develop.ut_annotation(5, 'name',l_bad_name, null), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(13, 'endcontext',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1183,17 +1183,17 @@ create or replace package body test_suite_builder is procedure duplicate_name_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(4, 'context','A context', null), - ut3.ut_annotation(5, 'name','a_context_name', null), - ut3.ut_annotation(6, 'name','a_newer_context_name', null), - ut3.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(8, 'endcontext',null, null), - ut3.ut_annotation(12, 'test', 'In suite', 'suite_level_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(4, 'context','A context', null), + ut3_develop.ut_annotation(5, 'name','a_context_name', null), + ut3_develop.ut_annotation(6, 'name','a_newer_context_name', null), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(8, 'endcontext',null, null), + ut3_develop.ut_annotation(12, 'test', 'In suite', 'suite_level_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1229,16 +1229,16 @@ create or replace package body test_suite_builder is procedure name_outside_of_context is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(3, 'name','a_context_name', null), - ut3.ut_annotation(4, 'context','A context', null), - ut3.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(8, 'endcontext',null, null), - ut3.ut_annotation(12, 'test', 'In suite', 'suite_level_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(3, 'name','a_context_name', null), + ut3_develop.ut_annotation(4, 'context','A context', null), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(8, 'endcontext',null, null), + ut3_develop.ut_annotation(12, 'test', 'In suite', 'suite_level_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1274,16 +1274,16 @@ create or replace package body test_suite_builder is procedure name_empty_value is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(4, 'context','A context', null), - ut3.ut_annotation(5, 'name',null, null), - ut3.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), - ut3.ut_annotation(8, 'endcontext',null, null), - ut3.ut_annotation(12, 'test', 'In suite', 'suite_level_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(4, 'context','A context', null), + ut3_develop.ut_annotation(5, 'name',null, null), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(8, 'endcontext',null, null), + ut3_develop.ut_annotation(12, 'test', 'In suite', 'suite_level_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1319,17 +1319,17 @@ create or replace package body test_suite_builder is procedure multiple_contexts is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(4, 'context','A context', null), - ut3.ut_annotation(6, 'test', 'In context1', 'test_in_a_context1'), - ut3.ut_annotation(7, 'endcontext',null, null), - ut3.ut_annotation(8, 'context','A context', null), - ut3.ut_annotation(10, 'test', 'In context2', 'test_in_a_context2'), - ut3.ut_annotation(11, 'endcontext',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(4, 'context','A context', null), + ut3_develop.ut_annotation(6, 'test', 'In context1', 'test_in_a_context1'), + ut3_develop.ut_annotation(7, 'endcontext',null, null), + ut3_develop.ut_annotation(8, 'context','A context', null), + ut3_develop.ut_annotation(10, 'test', 'In context2', 'test_in_a_context2'), + ut3_develop.ut_annotation(11, 'endcontext',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1372,13 +1372,13 @@ create or replace package body test_suite_builder is procedure throws_value_empty is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(3, 'test','A test with empty throws annotation', 'A_TEST_PROCEDURE'), - ut3.ut_annotation(3, 'throws',null, 'A_TEST_PROCEDURE') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(3, 'test','A test with empty throws annotation', 'A_TEST_PROCEDURE'), + ut3_develop.ut_annotation(3, 'throws',null, 'A_TEST_PROCEDURE') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1391,16 +1391,16 @@ create or replace package body test_suite_builder is procedure before_aftertest_multi is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(14, 'test','A test', 'some_test'), - ut3.ut_annotation(15, 'beforetest','before_test_proc', 'some_test'), - ut3.ut_annotation(16, 'beforetest','before_test_proc2', 'some_test'), - ut3.ut_annotation(18, 'aftertest','after_test_proc', 'some_test'), - ut3.ut_annotation(20, 'aftertest','after_test_proc2', 'some_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(14, 'test','A test', 'some_test'), + ut3_develop.ut_annotation(15, 'beforetest','before_test_proc', 'some_test'), + ut3_develop.ut_annotation(16, 'beforetest','before_test_proc2', 'some_test'), + ut3_develop.ut_annotation(18, 'aftertest','after_test_proc', 'some_test'), + ut3_develop.ut_annotation(20, 'aftertest','after_test_proc2', 'some_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1421,16 +1421,16 @@ create or replace package body test_suite_builder is procedure before_aftertest_twice is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(14, 'test','A test', 'some_test'), - ut3.ut_annotation(15, 'beforetest','before_test_proc, before_test_proc2', 'some_test'), - ut3.ut_annotation(16, 'beforetest','before_test_proc3', 'some_test'), - ut3.ut_annotation(18, 'aftertest','after_test_proc,after_test_proc2', 'some_test'), - ut3.ut_annotation(20, 'aftertest','after_test_proc3', 'some_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(14, 'test','A test', 'some_test'), + ut3_develop.ut_annotation(15, 'beforetest','before_test_proc, before_test_proc2', 'some_test'), + ut3_develop.ut_annotation(16, 'beforetest','before_test_proc3', 'some_test'), + ut3_develop.ut_annotation(18, 'aftertest','after_test_proc,after_test_proc2', 'some_test'), + ut3_develop.ut_annotation(20, 'aftertest','after_test_proc3', 'some_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1453,14 +1453,14 @@ create or replace package body test_suite_builder is procedure before_aftertest_pkg_proc is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(14, 'test','A test', 'some_test'), - ut3.ut_annotation(15, 'beforetest','external_package.before_test_proc', 'some_test'), - ut3.ut_annotation(18, 'aftertest','external_package.after_test_proc', 'some_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(14, 'test','A test', 'some_test'), + ut3_develop.ut_annotation(15, 'beforetest','external_package.before_test_proc', 'some_test'), + ut3_develop.ut_annotation(18, 'aftertest','external_package.after_test_proc', 'some_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1479,14 +1479,14 @@ create or replace package body test_suite_builder is procedure before_aftertest_mixed_syntax is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(14, 'test','A test', 'some_test'), - ut3.ut_annotation(15, 'beforetest','external_package.before_test_proc, before_test_proc2', 'some_test'), - ut3.ut_annotation(18, 'aftertest','external_package.after_test_proc, after_test_proc2', 'some_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(14, 'test','A test', 'some_test'), + ut3_develop.ut_annotation(15, 'beforetest','external_package.before_test_proc, before_test_proc2', 'some_test'), + ut3_develop.ut_annotation(18, 'aftertest','external_package.after_test_proc, after_test_proc2', 'some_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1507,14 +1507,14 @@ create or replace package body test_suite_builder is procedure test_annotation_ordering is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(4, 'test','B test', 'b_test'), - ut3.ut_annotation(10, 'test','Z test', 'z_test'), - ut3.ut_annotation(14, 'test','A test', 'a_test') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(4, 'test','B test', 'b_test'), + ut3_develop.ut_annotation(10, 'test','Z test', 'z_test'), + ut3_develop.ut_annotation(14, 'test','A test', 'a_test') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1531,13 +1531,13 @@ create or replace package body test_suite_builder is procedure test_bad_procedure_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(2, 'bad_procedure_annotation',null, 'some_procedure'), - ut3.ut_annotation(6, 'test','A test', 'do_stuff') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'bad_procedure_annotation',null, 'some_procedure'), + ut3_develop.ut_annotation(6, 'test','A test', 'do_stuff') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1547,13 +1547,13 @@ create or replace package body test_suite_builder is procedure test_bad_package_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(1, 'suite','Cool', null), - ut3.ut_annotation(17, 'bad_package_annotation',null, null), - ut3.ut_annotation(24, 'test','A test', 'do_stuff') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(17, 'bad_package_annotation',null, null), + ut3_develop.ut_annotation(24, 'test','A test', 'do_stuff') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1563,13 +1563,13 @@ create or replace package body test_suite_builder is procedure test_tag_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'tags','testtag', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'tags','testtag', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1585,12 +1585,12 @@ create or replace package body test_suite_builder is procedure suite_tag_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(3, 'tags','suitetag', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(3, 'tags','suitetag', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1606,13 +1606,13 @@ create or replace package body test_suite_builder is procedure test_tags_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'tags','testtag,testtag2,testtag3', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'tags','testtag,testtag2,testtag3', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1628,12 +1628,12 @@ create or replace package body test_suite_builder is procedure suite_tags_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(3, 'tags','suitetag,suitetag1,suitetag2', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(3, 'tags','suitetag,suitetag1,suitetag2', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1649,14 +1649,14 @@ create or replace package body test_suite_builder is procedure test_2line_tags_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'tags','testtag', 'test_procedure'), - ut3.ut_annotation(10, 'tags','testtag2', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'tags','testtag', 'test_procedure'), + ut3_develop.ut_annotation(10, 'tags','testtag2', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1672,13 +1672,13 @@ create or replace package body test_suite_builder is procedure suite_2line_tags_annotation is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(3, 'tags','suitetag', null), - ut3.ut_annotation(4, 'tags','suitetag1', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(3, 'tags','suitetag', null), + ut3_develop.ut_annotation(4, 'tags','suitetag1', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1694,12 +1694,12 @@ create or replace package body test_suite_builder is procedure test_empty_tag is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'tags',null, 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'tags',null, 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1713,12 +1713,12 @@ create or replace package body test_suite_builder is procedure suite_empty_tag is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(3, 'tags',null, null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(3, 'tags',null, null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1732,14 +1732,14 @@ create or replace package body test_suite_builder is procedure test_duplicate_tag is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'tags','testtag,testtag1,testtag', 'test_procedure'), - ut3.ut_annotation(10, 'tags',' testtag,testtag1,testtag2', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'tags','testtag,testtag1,testtag', 'test_procedure'), + ut3_develop.ut_annotation(10, 'tags',' testtag,testtag1,testtag2', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1755,13 +1755,13 @@ create or replace package body test_suite_builder is procedure suite_duplicate_tag is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(3, 'tags','suitetag,suitetag1,suitetag', null), - ut3.ut_annotation(4, 'tags',' suitetag1,suitetag2', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(3, 'tags','suitetag,suitetag1,suitetag', null), + ut3_develop.ut_annotation(4, 'tags',' suitetag1,suitetag2', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1777,13 +1777,13 @@ create or replace package body test_suite_builder is procedure test_empty_tag_between is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'tags','testtag,, ,testtag1', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'tags','testtag,, ,testtag1', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1799,12 +1799,12 @@ create or replace package body test_suite_builder is procedure suite_empty_tag_between is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(3, 'tags','suitetag,, ,suitetag1', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(3, 'tags','suitetag,, ,suitetag1', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1820,13 +1820,13 @@ create or replace package body test_suite_builder is procedure test_special_char_tag is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'tags','#?$%^&*!|\/@][', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'tags','#?$%^&*!|\/@][', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1842,12 +1842,12 @@ create or replace package body test_suite_builder is procedure suite_special_char_tag is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(3, 'tags','#?$%^&*!|\/@][', null) + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(3, 'tags','#?$%^&*!|\/@][', null) ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1863,14 +1863,14 @@ create or replace package body test_suite_builder is procedure test_spaces_in_tag is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(3, 'tags',' good_tag , bad tag , good-tag ', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'tags',' good_tag , bad tag , good-tag ', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(3, 'tags',' good_tag , bad tag , good-tag ', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'tags',' good_tag , bad tag , good-tag ', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); @@ -1893,14 +1893,14 @@ create or replace package body test_suite_builder is procedure test_minus_in_tag is l_actual clob; - l_annotations ut3.ut_annotations; + l_annotations ut3_develop.ut_annotations; begin --Arrange - l_annotations := ut3.ut_annotations( - ut3.ut_annotation(2, 'suite','testsuite', null), - ut3.ut_annotation(3, 'tags',' good_tag , -invalid_tag , good-tag ', null), - ut3.ut_annotation(8, 'test','Some test', 'test_procedure'), - ut3.ut_annotation(9, 'tags',' good_tag , -invalid_tag , good-tag ', 'test_procedure') + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2, 'suite','testsuite', null), + ut3_develop.ut_annotation(3, 'tags',' good_tag , -invalid_tag , good-tag ', null), + ut3_develop.ut_annotation(8, 'test','Some test', 'test_procedure'), + ut3_develop.ut_annotation(9, 'tags',' good_tag , -invalid_tag , good-tag ', 'test_procedure') ); --Act l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index fd35adc70..11cc7acfe 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -292,15 +292,15 @@ end test_package_with_ctx;]'; procedure test_schema_run is c_path constant varchar2(100) := sys_context('USERENV', 'CURRENT_USER'); - l_objects_to_run ut3.ut_suite_items := ut3.ut_suite_items(); - l_all_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items := ut3_develop.ut_suite_items(); + l_all_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; begin --Act - l_all_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_all_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); for i in 1..l_all_objects_to_run.count loop if l_all_objects_to_run(i).name in ('tests', 'tests2') then @@ -313,21 +313,21 @@ end test_package_with_ctx;]'; ut.expect(l_objects_to_run.count).to_equal(2); for i in 1 .. 2 loop - l_test0_suite := treat(l_objects_to_run(i) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(i) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name in ('tests', 'tests2')).to_be_true; - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); case l_test0_suite.name when 'tests' then ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(3); - ut.expect(l_test1_suite.rollback_type).to_equal(ut3.ut_utils.gc_rollback_manual); - l_test2_suite := treat(l_test1_suite.items(1) as ut3.ut_logical_suite); + ut.expect(l_test1_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test2_suite.name).to_equal('test_package_2'); ut.expect(l_test2_suite.items.count).to_equal(3); - ut.expect(l_test2_suite.rollback_type).to_equal(ut3.ut_utils.gc_rollback_manual); + ut.expect(l_test2_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); when 'tests2' then ut.expect(l_test1_suite.name).to_equal('test_package_3'); ut.expect(l_test1_suite.items.count).to_equal(3); @@ -339,84 +339,84 @@ end test_package_with_ctx;]'; procedure test_top2_by_name is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(1); - ut.expect(l_test1_suite.rollback_type).to_equal(ut3.ut_utils.gc_rollback_manual); - l_test2_suite := treat(l_test1_suite.items(1) as ut3.ut_logical_suite); + ut.expect(l_test1_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test2_suite.name).to_equal('test_package_2'); - ut.expect(l_test2_suite.rollback_type).to_equal(ut3.ut_utils.gc_rollback_manual); + ut.expect(l_test2_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); ut.expect(l_test2_suite.items.count).to_equal(3); end; procedure test_top2_bt_name_cur_user is c_path varchar2(100) := 'test_package_2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(1); - ut.expect(l_test1_suite.rollback_type).to_equal(ut3.ut_utils.gc_rollback_manual); - l_test2_suite := treat(l_test1_suite.items(1) as ut3.ut_logical_suite); + ut.expect(l_test1_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test2_suite.name).to_equal('test_package_2'); - ut.expect(l_test2_suite.rollback_type).to_equal(ut3.ut_utils.gc_rollback_manual); + ut.expect(l_test2_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); ut.expect(l_test2_suite.items.count).to_equal(3); end; procedure test_by_path_to_subsuite is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':tests.test_package_1.test_package_2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(1); - l_test2_suite := treat(l_test1_suite.items(1) as ut3.ut_logical_suite); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test2_suite.name).to_equal('test_package_2'); ut.expect(l_test2_suite.items.count).to_equal(3); @@ -424,26 +424,26 @@ end test_package_with_ctx;]'; procedure test_by_path_to_subsuite_cu is c_path varchar2(100) := ':tests.test_package_1.test_package_2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(1); - l_test2_suite := treat(l_test1_suite.items(1) as ut3.ut_logical_suite); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test2_suite.name).to_equal('test_package_2'); ut.expect(l_test2_suite.items.count).to_equal(3); @@ -451,36 +451,36 @@ end test_package_with_ctx;]'; procedure test_subsute_proc_by_path is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':tests.test_package_1.test_package_2.test2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; - l_test_proc ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); - ut.expect(l_test1_suite.rollback_type).to_equal(ut3.ut_utils.gc_rollback_manual); + ut.expect(l_test1_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); ut.expect(l_test1_suite.items.count).to_equal(1); - l_test2_suite := treat(l_test1_suite.items(1) as ut3.ut_logical_suite); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test2_suite.name).to_equal('test_package_2'); - ut.expect(l_test2_suite.rollback_type).to_equal(ut3.ut_utils.gc_rollback_manual); + ut.expect(l_test2_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); ut.expect(l_test2_suite.items.count).to_equal(1); - l_test_proc := treat(l_test2_suite.items(1) as ut3.ut_test); + l_test_proc := treat(l_test2_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test_proc.name).to_equal('test2'); - ut.expect(l_test_proc.rollback_type).to_equal(ut3.ut_utils.gc_rollback_manual); + ut.expect(l_test_proc.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); ut.expect(l_test_proc.before_test_list.count).to_be_greater_than(0); ut.expect(l_test_proc.after_test_list.count).to_be_greater_than(0); @@ -488,32 +488,32 @@ end test_package_with_ctx;]'; procedure test_subsute_proc_by_path_cu is c_path varchar2(100) := ':tests.test_package_1.test_package_2.test2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; - l_test_proc ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(1); - l_test2_suite := treat(l_test1_suite.items(1) as ut3.ut_logical_suite); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test2_suite.name).to_equal('test_package_2'); ut.expect(l_test2_suite.items.count).to_equal(1); - l_test_proc := treat(l_test2_suite.items(1) as ut3.ut_test); + l_test_proc := treat(l_test2_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test_proc.name).to_equal('test2'); ut.expect(l_test_proc.before_test_list.count).to_be_greater_than(0); ut.expect(l_test_proc.after_test_list.count).to_be_greater_than(0); @@ -521,101 +521,101 @@ end test_package_with_ctx;]'; procedure test_top_pack_by_name is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_1'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_suite; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_suite; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(2); ut.expect(l_test1_suite.items(1).name).to_equal('test1'); ut.expect(l_test1_suite.items(1).description).to_equal('Test1 from test package 1'); - ut.expect(treat(l_test1_suite.items(1) as ut3.ut_test).before_test_list.count).to_equal(0); - ut.expect(treat(l_test1_suite.items(1) as ut3.ut_test).after_test_list.count).to_equal(0); - ut.expect(treat(l_test1_suite.items(1) as ut3.ut_test).before_each_list.count).to_be_greater_than(0); - ut.expect(treat(l_test1_suite.items(1) as ut3.ut_test).disabled_flag).to_equal(0); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).before_test_list.count).to_equal(0); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).after_test_list.count).to_equal(0); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).before_each_list.count).to_be_greater_than(0); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(0); ut.expect(l_test1_suite.items(2).name).to_equal('test2'); ut.expect(l_test1_suite.items(2).description).to_equal('Test2 from test package 1'); - ut.expect(treat(l_test1_suite.items(2) as ut3.ut_test).before_test_list.count).to_be_greater_than(0); - ut.expect(treat(l_test1_suite.items(2) as ut3.ut_test).after_test_list.count).to_be_greater_than(0); - ut.expect(treat(l_test1_suite.items(2) as ut3.ut_test).before_each_list.count).to_be_greater_than(0); - ut.expect(treat(l_test1_suite.items(2) as ut3.ut_test).disabled_flag).to_equal(0); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).before_test_list.count).to_be_greater_than(0); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).after_test_list.count).to_be_greater_than(0); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).before_each_list.count).to_be_greater_than(0); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(0); end; procedure test_top_pack_by_name_cu is c_path varchar2(100) := 'test_package_1'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_suite; - l_test2_suite ut3.ut_suite; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_suite; + l_test2_suite ut3_develop.ut_suite; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(2); ut.expect(l_test1_suite.items(1).name).to_equal('test1'); ut.expect(l_test1_suite.items(1).description).to_equal('Test1 from test package 1'); - ut.expect(treat(l_test1_suite.items(1) as ut3.ut_test).before_test_list.count).to_equal(0); - ut.expect(treat(l_test1_suite.items(1) as ut3.ut_test).after_test_list.count).to_equal(0); - ut.expect(treat(l_test1_suite.items(1) as ut3.ut_test).before_each_list.count).to_be_greater_than(0); - ut.expect(treat(l_test1_suite.items(1) as ut3.ut_test).disabled_flag).to_equal(0); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).before_test_list.count).to_equal(0); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).after_test_list.count).to_equal(0); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).before_each_list.count).to_be_greater_than(0); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(0); ut.expect(l_test1_suite.items(2).name).to_equal('test2'); ut.expect(l_test1_suite.items(2).description).to_equal('Test2 from test package 1'); - ut.expect(treat(l_test1_suite.items(2) as ut3.ut_test).before_test_list.count).to_be_greater_than(0); - ut.expect(treat(l_test1_suite.items(2) as ut3.ut_test).after_test_list.count).to_be_greater_than(0); - ut.expect(treat(l_test1_suite.items(2) as ut3.ut_test).before_each_list.count).to_be_greater_than(0); - ut.expect(treat(l_test1_suite.items(2) as ut3.ut_test).disabled_flag).to_equal(0); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).before_test_list.count).to_be_greater_than(0); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).after_test_list.count).to_be_greater_than(0); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).before_each_list.count).to_be_greater_than(0); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(0); end; procedure test_top_pack_by_path is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':tests'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(3); - l_test2_suite := treat(l_test1_suite.items(1) as ut3.ut_logical_suite); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test2_suite.name).to_equal('test_package_2'); ut.expect(l_test2_suite.items.count).to_equal(3); @@ -623,26 +623,26 @@ end test_package_with_ctx;]'; procedure test_top_pack_by_path_cu is c_path varchar2(100) := ':tests'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(3); - l_test2_suite := treat(l_test1_suite.items(1) as ut3.ut_logical_suite); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test2_suite.name).to_equal('test_package_2'); ut.expect(l_test2_suite.items.count).to_equal(3); @@ -650,27 +650,27 @@ end test_package_with_ctx;]'; procedure test_top_pck_proc_by_path is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':tests.test_package_1.test2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; - l_test_proc ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(1); - l_test_proc := treat(l_test1_suite.items(1) as ut3.ut_test); + l_test_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test_proc.name).to_equal('test2'); ut.expect(l_test_proc.description).to_equal('Test2 from test package 1'); @@ -680,27 +680,27 @@ end test_package_with_ctx;]'; procedure test_top_pck_proc_by_path_cu is c_path varchar2(100) := ':tests.test_package_1.test2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test2_suite ut3.ut_logical_suite; - l_test_proc ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(1); - l_test_proc := treat(l_test1_suite.items(1) as ut3.ut_test); + l_test_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test_proc.name).to_equal('test2'); ut.expect(l_test_proc.description).to_equal('Test2 from test package 1'); @@ -710,27 +710,27 @@ end test_package_with_ctx;]'; procedure test_top_pkc_proc_by_name is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_1.test2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test_proc ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(1); - l_test_proc := treat(l_test1_suite.items(1) as ut3.ut_test); + l_test_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test_proc.name).to_equal('test2'); ut.expect(l_test_proc.before_test_list.count).to_be_greater_than(0); ut.expect(l_test_proc.after_test_list.count).to_be_greater_than(0); @@ -738,27 +738,27 @@ end test_package_with_ctx;]'; procedure test_top_pkc_proc_by_name_cu is c_path varchar2(100) := 'test_package_1.test2'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test_proc ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_1'); ut.expect(l_test1_suite.items.count).to_equal(1); - l_test_proc := treat(l_test1_suite.items(1) as ut3.ut_test); + l_test_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test_proc.name).to_equal('test2'); ut.expect(l_test_proc.before_test_list.count).to_be_greater_than(0); ut.expect(l_test_proc.after_test_list.count).to_be_greater_than(0); @@ -766,139 +766,139 @@ end test_package_with_ctx;]'; procedure test_top_pkc_nosub_by_name is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_3'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test1 ut3.ut_test; - l_test3 ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1 ut3_develop.ut_test; + l_test3 ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests2'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_3'); ut.expect(l_test1_suite.items.count).to_equal(3); - l_test1 := treat(l_test1_suite.items(1) as ut3.ut_test); + l_test1 := treat(l_test1_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test1.name).to_equal('test1'); ut.expect(l_test1.DISABLED_FLAG).to_equal(0); - l_test3 := treat(l_test1_suite.items(3) as ut3.ut_test); + l_test3 := treat(l_test1_suite.items(3) as ut3_develop.ut_test); ut.expect(l_test3.name).to_equal('disabled_test'); ut.expect(l_test3.DISABLED_FLAG).to_equal(1); end; procedure test_top_pkc_nosub_by_name_cu is c_path varchar2(100) := 'test_package_3'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test1 ut3.ut_test; - l_test3 ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1 ut3_develop.ut_test; + l_test3 ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests2'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_3'); ut.expect(l_test1_suite.items.count).to_equal(3); - l_test1 := treat(l_test1_suite.items(1) as ut3.ut_test); + l_test1 := treat(l_test1_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test1.name).to_equal('test1'); ut.expect(l_test1.DISABLED_FLAG).to_equal(0); - l_test3 := treat(l_test1_suite.items(3) as ut3.ut_test); + l_test3 := treat(l_test1_suite.items(3) as ut3_develop.ut_test); ut.expect(l_test3.name).to_equal('disabled_test'); ut.expect(l_test3.DISABLED_FLAG).to_equal(1); end; procedure test_top_subpck_by_path is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':tests2.test_package_3'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test1 ut3.ut_test; - l_test3 ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1 ut3_develop.ut_test; + l_test3 ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests2'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_3'); ut.expect(l_test1_suite.items.count).to_equal(3); - l_test1 := treat(l_test1_suite.items(1) as ut3.ut_test); + l_test1 := treat(l_test1_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test1.name).to_equal('test1'); ut.expect(l_test1.DISABLED_FLAG).to_equal(0); - l_test3 := treat(l_test1_suite.items(3) as ut3.ut_test); + l_test3 := treat(l_test1_suite.items(3) as ut3_develop.ut_test); ut.expect(l_test3.name).to_equal('disabled_test'); ut.expect(l_test3.DISABLED_FLAG).to_equal(1); end; procedure test_top_subpck_by_path_cu is c_path varchar2(100) := ':tests2.test_package_3'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test0_suite ut3.ut_logical_suite; - l_test1_suite ut3.ut_logical_suite; - l_test1 ut3.ut_test; - l_test3 ut3.ut_test; + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1 ut3_develop.ut_test; + l_test3 ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test0_suite.name).to_equal('tests2'); ut.expect(l_test0_suite.items.count).to_equal(1); - l_test1_suite := treat(l_test0_suite.items(1) as ut3.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_test1_suite.name).to_equal('test_package_3'); ut.expect(l_test1_suite.items.count).to_equal(3); - l_test1 := treat(l_test1_suite.items(1) as ut3.ut_test); + l_test1 := treat(l_test1_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test1.name).to_equal('test1'); ut.expect(l_test1.DISABLED_FLAG).to_equal(0); - l_test3 := treat(l_test1_suite.items(3) as ut3.ut_test); + l_test3 := treat(l_test1_suite.items(3) as ut3_develop.ut_test); ut.expect(l_test3.name).to_equal('disabled_test'); ut.expect(l_test3.DISABLED_FLAG).to_equal(1); end; procedure test_search_invalid_pck is - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; begin - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('failing_invalid_spec')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('failing_invalid_spec')); - ut3.ut.expect(l_objects_to_run.count).to_be_greater_than(0); - ut3.ut.expect(l_objects_to_run(l_objects_to_run.first).object_name).to_equal('failing_invalid_spec'); + ut3_develop.ut.expect(l_objects_to_run.count).to_be_greater_than(0); + ut3_develop.ut.expect(l_objects_to_run(l_objects_to_run.first).object_name).to_equal('failing_invalid_spec'); end; procedure compile_invalid_package is @@ -936,9 +936,9 @@ end;]'; end; procedure test_search_nonexisting_pck is - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; begin - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('ut3.failing_non_existing')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('ut3_develop.failing_non_existing')); ut.fail('Non existing package did not raise exception'); exception when others then @@ -946,9 +946,9 @@ end;]'; end; procedure test_search_nonexist_sch_pck is - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; begin - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('failing_non_existing')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('failing_non_existing')); ut.fail('Non existing package without schema did not raise exception'); exception when others then @@ -956,27 +956,27 @@ end;]'; end; procedure test_desc_with_comma is - l_objects_to_run ut3.ut_suite_items; - l_suite ut3.ut_suite; - l_test ut3.ut_test; + l_objects_to_run ut3_develop.ut_suite_items; + l_suite ut3_develop.ut_suite; + l_test ut3_develop.ut_test; begin - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('tst_package_to_be_dropped')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('tst_package_to_be_dropped')); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_suite := treat(l_objects_to_run(1) as ut3.ut_suite); + l_suite := treat(l_objects_to_run(1) as ut3_develop.ut_suite); ut.expect(l_suite.name).to_equal('tst_package_to_be_dropped'); ut.expect(l_suite.description).to_equal('A suite description, though with comma, is assigned by suite_manager'); ut.expect(l_suite.items.count).to_equal(2); - l_test := treat(l_suite.items(1) as ut3.ut_test); + l_test := treat(l_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test.name).to_equal('test1'); ut.expect(l_test.description).to_equal('A test description, though with comma, is assigned by suite_manager'); --- l_test := treat(l_suite.items(2) as ut3.ut_test); +-- l_test := treat(l_suite.items(2) as ut3_develop.ut_test); -- -- ut.expect(l_test.name).to_equal('test2'); -- ut.expect(l_test.description).to_equal('A test description, though with comma, is assigned by suite_manager'); @@ -1013,16 +1013,16 @@ end;'; end; procedure test_inv_cache_on_drop is - l_test_report ut3.ut_varchar2_list; + l_test_report ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_test_report from table(ut3.ut.run(sys_context('USERENV', 'CURRENT_USER')||'.tst_package_to_be_dropped')); + select * bulk collect into l_test_report from table(ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER')||'.tst_package_to_be_dropped')); -- drop package clean_inv_cache_on_drop; begin - select * bulk collect into l_test_report from table(ut3.ut.run(sys_context('USERENV', 'CURRENT_USER') || '.tst_package_to_be_dropped')); + select * bulk collect into l_test_report from table(ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER') || '.tst_package_to_be_dropped')); ut.fail('Cache not invalidated on package drop'); exception when others then @@ -1056,15 +1056,15 @@ end;'; end; procedure test_inv_pck_bodies is - l_test_report ut3.ut_varchar2_list; + l_test_report ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_test_report from table(ut3.ut.run(sys_context('USERENV', 'CURRENT_USER')||'.test_dependencies')); + select * bulk collect into l_test_report from table(ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER')||'.test_dependencies')); ut.expect(l_test_report(l_test_report.count-1)).to_be_like('1 test_, 0 failed, 0 errored, 0 disabled, 0 warning(s)'); - --execute immediate 'select * from table(ut3.ut.run(''UT3.test_dependencies'', ut3.utplsql_test_reporter()))' into l_result; + --execute immediate 'select * from table(ut3_develop.ut.run(''UT3_DEVELOP.test_dependencies'', ut3_develop.utplsql_test_reporter()))' into l_result; --- ut.expect(l_result).to_equal(ut3.ut_utils.gc_success); +-- ut.expect(l_result).to_equal(ut3_develop.ut_utils.gc_success); end; procedure setup_inv_pck_bodies is pragma autonomous_transaction; @@ -1092,16 +1092,16 @@ end;'; end; procedure test_pck_with_dollar is - l_objects_to_run ut3.ut_suite_items; - l_suite ut3.ut_suite; + l_objects_to_run ut3_develop.ut_suite_items; + l_suite ut3_develop.ut_suite; begin --act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('tst_package_with$dollar')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('tst_package_with$dollar')); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_suite := treat(l_objects_to_run(1) as ut3.ut_suite); + l_suite := treat(l_objects_to_run(1) as ut3_develop.ut_suite); ut.expect(l_suite.name).to_equal('tst_package_with$dollar'); end; procedure setup_pck_with_dollar is @@ -1127,16 +1127,16 @@ end;'; procedure test_pck_with_hash is - l_objects_to_run ut3.ut_suite_items; - l_suite ut3.ut_suite; + l_objects_to_run ut3_develop.ut_suite_items; + l_suite ut3_develop.ut_suite; begin --act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('tst_package_with#hash')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('tst_package_with#hash')); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_suite := treat(l_objects_to_run(1) as ut3.ut_suite); + l_suite := treat(l_objects_to_run(1) as ut3_develop.ut_suite); ut.expect(l_suite.name).to_equal('tst_package_with#hash'); end; procedure setup_pck_with_hash is @@ -1162,22 +1162,22 @@ end;'; procedure test_test_with_dollar is - l_objects_to_run ut3.ut_suite_items; - l_suite ut3.ut_suite; - l_test ut3.ut_test; + l_objects_to_run ut3_develop.ut_suite_items; + l_suite ut3_develop.ut_suite; + l_test ut3_develop.ut_test; begin --act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('tst_package_with_dollar_test.test$1')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('tst_package_with_dollar_test.test$1')); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_suite := treat(l_objects_to_run(1) as ut3.ut_suite); + l_suite := treat(l_objects_to_run(1) as ut3_develop.ut_suite); ut.expect(l_suite.name).to_equal('tst_package_with_dollar_test'); ut.expect(l_suite.items.count).to_equal(1); - l_test := treat(l_suite.items(1) as ut3.ut_test); + l_test := treat(l_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test.name).to_equal('test$1'); @@ -1203,22 +1203,22 @@ end;'; end; procedure test_test_with_hash is - l_objects_to_run ut3.ut_suite_items; - l_suite ut3.ut_suite; - l_test ut3.ut_test; + l_objects_to_run ut3_develop.ut_suite_items; + l_suite ut3_develop.ut_suite; + l_test ut3_develop.ut_test; begin --act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('tst_package_with_hash_test.test#1')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('tst_package_with_hash_test.test#1')); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_suite := treat(l_objects_to_run(1) as ut3.ut_suite); + l_suite := treat(l_objects_to_run(1) as ut3_develop.ut_suite); ut.expect(l_suite.name).to_equal('tst_package_with_hash_test'); ut.expect(l_suite.items.count).to_equal(1); - l_test := treat(l_suite.items(1) as ut3.ut_test); + l_test := treat(l_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test.name).to_equal('test#1'); @@ -1244,17 +1244,17 @@ end;'; end; procedure test_empty_suite_path is - l_objects_to_run ut3.ut_suite_items; - l_suite ut3.ut_suite; + l_objects_to_run ut3_develop.ut_suite_items; + l_suite ut3_develop.ut_suite; begin --act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('tst_empty_suite_path')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('tst_empty_suite_path')); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_suite := treat(l_objects_to_run(1) as ut3.ut_suite); + l_suite := treat(l_objects_to_run(1) as ut3_develop.ut_suite); ut.expect(l_suite.name).to_equal('tst_empty_suite_path'); end; @@ -1281,25 +1281,25 @@ end;'; end; procedure test_pck_with_same_path is - l_objects_to_run ut3.ut_suite_items; - l_suite1 ut3.ut_logical_suite; - l_suite2 ut3.ut_logical_suite; - l_suite3 ut3.ut_suite; + l_objects_to_run ut3_develop.ut_suite_items; + l_suite1 ut3_develop.ut_logical_suite; + l_suite2 ut3_develop.ut_logical_suite; + l_suite3 ut3_develop.ut_suite; begin - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(':test1.test2$.test_package_same_1')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(':test1.test2$.test_package_same_1')); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_suite1 := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_suite1 := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_suite1.name).to_equal('test1'); ut.expect(l_suite1.items.count).to_equal(1); - l_suite2 := treat(l_suite1.items(1) as ut3.ut_logical_suite); + l_suite2 := treat(l_suite1.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_suite2.name).to_equal('test2$'); ut.expect(l_suite2.items.count).to_equal(1); - l_suite3 := treat(l_suite2.items(1) as ut3.ut_suite); + l_suite3 := treat(l_suite2.items(1) as ut3_develop.ut_suite); ut.expect(l_suite3.name).to_equal('test_package_same_1'); end; @@ -1359,17 +1359,17 @@ end;]'; end; procedure disable_suite_floating_annot is - l_objects_to_run ut3.ut_suite_items; - l_suite ut3.ut_suite; + l_objects_to_run ut3_develop.ut_suite_items; + l_suite ut3_develop.ut_suite; begin --Arrange setup_disabled_pck; --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list('test_disabled_floating')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('test_disabled_floating')); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_suite := treat(l_objects_to_run(1) as ut3.ut_suite); + l_suite := treat(l_objects_to_run(1) as ut3_develop.ut_suite); ut.expect(l_suite.name).to_equal('test_disabled_floating'); ut.expect(l_suite.get_disabled_flag()).to_be_true(); @@ -1378,66 +1378,66 @@ end;]'; procedure pck_proc_in_ctx_by_name is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_with_ctx.test1'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test_suite ut3.ut_logical_suite; - l_ctx_suite ut3.ut_logical_suite; - l_test_proc ut3.ut_test; + l_test_suite ut3_develop.ut_logical_suite; + l_ctx_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test_suite.name).to_equal('test_package_with_ctx'); ut.expect(l_test_suite.items.count).to_equal(1); - l_ctx_suite := treat(l_test_suite.items(1) as ut3.ut_logical_suite); + l_ctx_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_ctx_suite.name).to_equal('some_context'); ut.expect(l_ctx_suite.description).to_equal('Some context description'); ut.expect(l_ctx_suite.items.count).to_equal(1); - l_test_proc := treat(l_ctx_suite.items(1) as ut3.ut_test); + l_test_proc := treat(l_ctx_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test_proc.name).to_equal('test1'); end; procedure pck_proc_in_ctx_by_path is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':test_package_with_ctx.some_context.test1'; - l_objects_to_run ut3.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; - l_test_suite ut3.ut_logical_suite; - l_ctx_suite ut3.ut_logical_suite; - l_test_proc ut3.ut_test; + l_test_suite ut3_develop.ut_logical_suite; + l_ctx_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; begin --Act - l_objects_to_run := ut3.ut_suite_manager.configure_execution_by_path(ut3.ut_varchar2_list(c_path)); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); --Assert ut.expect(l_objects_to_run.count).to_equal(1); - l_test_suite := treat(l_objects_to_run(1) as ut3.ut_logical_suite); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); ut.expect(l_test_suite.name).to_equal('test_package_with_ctx'); ut.expect(l_test_suite.items.count).to_equal(1); - l_ctx_suite := treat(l_test_suite.items(1) as ut3.ut_logical_suite); + l_ctx_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); ut.expect(l_ctx_suite.name).to_equal('some_context'); ut.expect(l_ctx_suite.description).to_equal('Some context description'); ut.expect(l_ctx_suite.items.count).to_equal(1); - l_test_proc := treat(l_ctx_suite.items(1) as ut3.ut_test); + l_test_proc := treat(l_ctx_suite.items(1) as ut3_develop.ut_test); ut.expect(l_test_proc.name).to_equal('test1'); end; procedure test_get_schema_ut_packages is - l_expected ut3.ut_object_names; - l_actual ut3.ut_object_names; + l_expected ut3_develop.ut_object_names; + l_actual ut3_develop.ut_object_names; begin - l_expected := ut3.ut_object_names( - ut3.ut_object_name('UT3','SOME_TEST_PACKAGE') + l_expected := ut3_develop.ut_object_names( + ut3_develop.ut_object_name('UT3_DEVELOP','SOME_TEST_PACKAGE') ); - l_actual := ut3_tester_helper.run_helper.get_schema_ut_packages('UT3'); + l_actual := ut3_tester_helper.run_helper.get_schema_ut_packages('UT3_DEVELOP'); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); end; @@ -1454,16 +1454,16 @@ end;]'; end; procedure add_new_long_test_package is - l_actual ut3.ut_object_names; + l_actual ut3_develop.ut_object_names; l_expected_message varchar2(500); begin - l_expected_message := q'[ORA-20217: 'Suitepath exceeds 1000 CHAR on: UT3.DUMMY_LONG_TEST_PACKAGE,UT3.DUMMY_LONG_TEST_PACKAGE1'%]'; - l_actual := ut3_tester_helper.run_helper.get_schema_ut_packages('UT3'); + l_expected_message := q'[ORA-20217: 'Suitepath exceeds 1000 CHAR on: UT3_DEVELOP.DUMMY_LONG_TEST_PACKAGE,UT3_DEVELOP.DUMMY_LONG_TEST_PACKAGE1'%]'; + l_actual := ut3_tester_helper.run_helper.get_schema_ut_packages('UT3_DEVELOP'); ut.fail('Expected exception for suitpaths over 1k for two packages'); exception when others then ut.expect(dbms_utility.format_error_stack()).to_be_like(l_expected_message); - ut.expect(SQLCODE).to_equal(ut3.ut_utils.gc_value_too_large); + ut.expect(SQLCODE).to_equal(ut3_develop.ut_utils.gc_value_too_large); end; end test_suite_manager; diff --git a/test/ut3_tester/core/test_ut_executable.pkb b/test/ut3_tester/core/test_ut_executable.pkb index 92420de47..337095607 100644 --- a/test/ut3_tester/core/test_ut_executable.pkb +++ b/test/ut3_tester/core/test_ut_executable.pkb @@ -3,13 +3,13 @@ create or replace package body test_ut_executable is g_dbms_output_text varchar2(30) := 'Some output from procedure'; procedure exec_schema_package_proc is - l_executable ut3.ut_executable; - l_test ut3.ut_test; + l_executable ut3_develop.ut_executable; + l_test ut3_develop.ut_test; l_result boolean; begin --Arrange - l_test := ut3.ut_test(a_object_name => 'test_ut_executable',a_name => 'test_ut_executable', a_line_no=> 1); - l_executable := ut3.ut_executable_test( null, 'test_ut_executable', 'passing_proc', ut3.ut_utils.gc_test_execute ); + l_test := ut3_develop.ut_test(a_object_name => 'test_ut_executable',a_name => 'test_ut_executable', a_line_no=> 1); + l_executable := ut3_develop.ut_executable_test( null, 'test_ut_executable', 'passing_proc', ut3_develop.ut_utils.gc_test_execute ); --Act l_result := l_executable.do_execute(l_test); --Assert @@ -19,14 +19,14 @@ create or replace package body test_ut_executable is end; procedure exec_package_proc_output is - l_executable ut3.ut_executable; - l_test ut3.ut_test; + l_executable ut3_develop.ut_executable; + l_test ut3_develop.ut_test; l_result boolean; begin --Arrange - l_test := ut3.ut_test(a_object_owner => 'ut3_tester', a_object_name => 'test_ut_executable',a_name => 'test_ut_executable', a_line_no=> 1); - l_executable := ut3.ut_executable_test( a_owner => 'ut3_tester', a_package => 'test_ut_executable', - a_procedure_name => 'output_proc', a_executable_type => ut3.ut_utils.gc_test_execute ); + l_test := ut3_develop.ut_test(a_object_owner => 'ut3_tester', a_object_name => 'test_ut_executable',a_name => 'test_ut_executable', a_line_no=> 1); + l_executable := ut3_develop.ut_executable_test( a_owner => 'ut3_tester', a_package => 'test_ut_executable', + a_procedure_name => 'output_proc', a_executable_type => ut3_develop.ut_utils.gc_test_execute ); --Act l_result := l_executable.do_execute(l_test); --Assert @@ -36,13 +36,13 @@ create or replace package body test_ut_executable is end; procedure exec_failing_proc is - l_executable ut3.ut_executable; - l_test ut3.ut_test; + l_executable ut3_develop.ut_executable; + l_test ut3_develop.ut_test; l_result boolean; begin --Arrange - l_test := ut3.ut_test(a_object_owner => 'ut3_tester', a_object_name => 'test_ut_executable',a_name => 'test_ut_executable', a_line_no=> 1); - l_executable := ut3.ut_executable_test( 'ut3_tester', 'test_ut_executable', 'throwing_proc', ut3.ut_utils.gc_test_execute ); + l_test := ut3_develop.ut_test(a_object_owner => 'ut3_tester', a_object_name => 'test_ut_executable',a_name => 'test_ut_executable', a_line_no=> 1); + l_executable := ut3_develop.ut_executable_test( 'ut3_tester', 'test_ut_executable', 'throwing_proc', ut3_develop.ut_utils.gc_test_execute ); --Act l_result := l_executable.do_execute(l_test); --Assert @@ -83,10 +83,10 @@ create or replace package body test_ut_executable is procedure form_name is begin - ut.expect(ut3.ut_executable_test( user, ' package ', 'proc', null ).form_name()).to_equal(user||'.package.proc'); - ut.expect(ut3.ut_executable_test( null, 'package', ' proc ', null ).form_name()).to_equal('package.proc'); - ut.expect(ut3.ut_executable_test( null, 'proc', null, null ).form_name()).to_equal('proc'); - ut.expect(ut3.ut_executable_test( ' '||user||' ', 'proc', null, null ).form_name()).to_equal(user||'.proc'); + ut.expect(ut3_develop.ut_executable_test( user, ' package ', 'proc', null ).form_name()).to_equal(user||'.package.proc'); + ut.expect(ut3_develop.ut_executable_test( null, 'package', ' proc ', null ).form_name()).to_equal('package.proc'); + ut.expect(ut3_develop.ut_executable_test( null, 'proc', null, null ).form_name()).to_equal('proc'); + ut.expect(ut3_develop.ut_executable_test( ' '||user||' ', 'proc', null, null ).form_name()).to_equal(user||'.proc'); end; procedure passing_proc is diff --git a/test/ut3_tester/core/test_ut_suite.pkb b/test/ut3_tester/core/test_ut_suite.pkb index 9c52df9e5..7cb9121f6 100644 --- a/test/ut3_tester/core/test_ut_suite.pkb +++ b/test/ut3_tester/core/test_ut_suite.pkb @@ -16,23 +16,23 @@ create or replace package body test_ut_suite is end; procedure disabled_suite is - l_suite ut3.ut_suite; + l_suite ut3_develop.ut_suite; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; - l_suite.disabled_flag := ut3.ut_utils.boolean_to_int(true); - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'set_g_number_0', ut3.ut_utils.gc_before_all)); - l_suite.after_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'add_1_to_g_number', ut3.ut_utils.gc_before_all)); + l_suite.disabled_flag := ut3_develop.ut_utils.boolean_to_int(true); + l_suite.before_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'set_g_number_0', ut3_develop.ut_utils.gc_before_all)); + l_suite.after_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'add_1_to_g_number', ut3_develop.ut_utils.gc_before_all)); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'add_1_to_g_number', a_line_no=> 1); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'add_1_to_g_number', a_line_no=> 1); --Act l_suite.do_execute(); --Assert ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_be_null; - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_disabled); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_disabled); ut.expect(l_suite.results_count.disabled_count).to_equal(2); ut.expect(l_suite.results_count.warnings_count).to_equal(0); ut.expect(l_suite.results_count.success_count).to_equal(0); @@ -41,19 +41,19 @@ create or replace package body test_ut_suite is end; procedure beforeall_errors is - l_suite ut3.ut_suite; + l_suite ut3_develop.ut_suite; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'failing_procedure', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'failing_procedure', ut3_develop.ut_utils.gc_before_all)); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'set_g_number_0', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'set_g_number_0', a_line_no=> 1); --Act l_suite.do_execute(); --Assert ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_be_null; - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(l_suite.results_count.disabled_count).to_equal(0); ut.expect(l_suite.results_count.warnings_count).to_equal(0); ut.expect(l_suite.results_count.success_count).to_equal(0); @@ -62,22 +62,22 @@ create or replace package body test_ut_suite is end; procedure aftereall_errors is - l_suite ut3.ut_suite; + l_suite ut3_develop.ut_suite; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; - l_suite.after_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'failing_procedure', ut3.ut_utils.gc_after_all)); + l_suite.after_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'UT_EXAMPLE_TESTS', 'failing_procedure', ut3_develop.ut_utils.gc_after_all)); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'set_g_number_0', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'set_g_number_0', a_line_no=> 1); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_EXAMPLE_TESTS',a_name => 'add_1_to_g_number', a_line_no=> 1); --Act l_suite.do_execute(); --Assert ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(1); - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_success); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_success); ut.expect(l_suite.results_count.disabled_count).to_equal(0); ut.expect(l_suite.results_count.warnings_count).to_equal(1); ut.expect(l_suite.results_count.success_count).to_equal(2); @@ -86,42 +86,42 @@ create or replace package body test_ut_suite is end; procedure package_without_body is - l_suite ut3.ut_suite; + l_suite ut3_develop.ut_suite; begin - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'UT_WITHOUT_BODY', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => USER, a_object_name => 'UT_WITHOUT_BODY', a_line_no=> 1); l_suite.path := 'UT_WITHOUT_BODY'; l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_name => 'ut_without_body',a_name => 'test1', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_name => 'ut_without_body',a_name => 'test1', a_line_no=> 1); --Act l_suite.do_execute(); --Assert - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_error); end; procedure package_with_invalid_body is - l_suite ut3.ut_suite; + l_suite ut3_develop.ut_suite; begin - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'UT_WITH_INVALID_BODY', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => USER, a_object_name => 'UT_WITH_INVALID_BODY', a_line_no=> 1); l_suite.path := 'UT_WITH_INVALID_BODY'; l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_name => 'ut_with_invalid_body',a_name => 'test1', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_name => 'ut_with_invalid_body',a_name => 'test1', a_line_no=> 1); --Act l_suite.do_execute(); --Assert - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_error); end; procedure rollback_auto is - l_suite ut3.ut_suite; + l_suite ut3_develop.ut_suite; begin --Arrange execute immediate 'delete from ut3_tester_helper.ut$test_table'; - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'UT_TRANSACTION_CONTROL', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => USER, a_object_name => 'UT_TRANSACTION_CONTROL', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_transaction_control'; - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable(USER, 'UT_TRANSACTION_CONTROL', 'setup', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable(USER, 'UT_TRANSACTION_CONTROL', 'setup', ut3_develop.ut_utils.gc_before_all)); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => USER, a_object_name => 'ut_transaction_control',a_name => 'test', a_line_no=> 1); - l_suite.set_rollback_type(ut3.ut_utils.gc_rollback_auto); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => USER, a_object_name => 'ut_transaction_control',a_name => 'test', a_line_no=> 1); + l_suite.set_rollback_type(ut3_develop.ut_utils.gc_rollback_auto); --Act l_suite.do_execute(); @@ -133,24 +133,24 @@ create or replace package body test_ut_suite is procedure rollback_auto_on_failure is begin - ut3_tester_helper.run_helper.test_rollback_type('test_failure', ut3.ut_utils.gc_rollback_auto, equal(0) ); + ut3_tester_helper.run_helper.test_rollback_type('test_failure', ut3_develop.ut_utils.gc_rollback_auto, equal(0) ); end; procedure rollback_manual is begin - ut3_tester_helper.run_helper.test_rollback_type('test', ut3.ut_utils.gc_rollback_manual, be_greater_than(0) ); + ut3_tester_helper.run_helper.test_rollback_type('test', ut3_develop.ut_utils.gc_rollback_manual, be_greater_than(0) ); end; procedure rollback_manual_on_failure is begin - ut3_tester_helper.run_helper.test_rollback_type('test_failure', ut3.ut_utils.gc_rollback_manual, be_greater_than(0) ); + ut3_tester_helper.run_helper.test_rollback_type('test_failure', ut3_develop.ut_utils.gc_rollback_manual, be_greater_than(0) ); end; procedure trim_transaction_invalidators is - l_suite ut3.ut_suite; + l_suite ut3_develop.ut_suite; begin --arrange - l_suite := ut3.ut_suite(a_object_owner => USER, a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => USER, a_object_name => 'UT_EXAMPLE_TESTS', a_line_no=> 1); for i in 1 .. 100 loop l_suite.add_transaction_invalidator('schema_name.package_name.procedure_name'||i); end loop; diff --git a/test/ut3_tester/core/test_ut_test.pkb b/test/ut3_tester/core/test_ut_test.pkb index b4dcc2536..f6f59df08 100644 --- a/test/ut3_tester/core/test_ut_test.pkb +++ b/test/ut3_tester/core/test_ut_test.pkb @@ -6,24 +6,24 @@ create or replace package body test_ut_test is end; procedure disabled_test is - l_suite ut3.ut_suite; - l_test ut3.ut_test; + l_suite ut3_develop.ut_suite; + l_test ut3_develop.ut_test; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3_develop.ut_utils.gc_before_all)); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 2); - l_suite.items(l_suite.items.last).disabled_flag := ut3.ut_utils.boolean_to_int(true); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 2); + l_suite.items(l_suite.items.last).disabled_flag := ut3_develop.ut_utils.boolean_to_int(true); --Act l_suite.do_execute(); --Assert ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(1); - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_success); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_success); ut.expect(l_suite.results_count.disabled_count).to_equal(1); ut.expect(l_suite.results_count.warnings_count).to_equal(0); ut.expect(l_suite.results_count.success_count).to_equal(1); @@ -32,26 +32,26 @@ create or replace package body test_ut_test is end; procedure aftertest_errors is - l_suite ut3.ut_suite; - l_test ut3.ut_test; + l_suite ut3_develop.ut_suite; + l_test ut3_develop.ut_test; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); l_suite.path := 'ut3_tester_helper.ut_example_tests'; - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3_develop.ut_utils.gc_before_all)); - l_test := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); - l_test.before_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_before_test)); - l_test.after_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_after_test)); + l_test := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_test.before_test_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3_develop.ut_utils.gc_before_test)); + l_test.after_test_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3_develop.ut_utils.gc_after_test)); l_suite.items.extend; l_suite.items(l_suite.items.last) := l_test; l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); --Act l_suite.do_execute(); --Assert ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(3); - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(l_suite.results_count.disabled_count).to_equal(0); ut.expect(l_suite.results_count.warnings_count).to_equal(0); ut.expect(l_suite.results_count.success_count).to_equal(1); @@ -60,24 +60,24 @@ create or replace package body test_ut_test is end; procedure aftereach_errors is - l_suite ut3.ut_suite; - l_test ut3.ut_test; + l_suite ut3_develop.ut_suite; + l_test ut3_develop.ut_test; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); - l_test := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); - l_test.before_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_before_each)); - l_test.after_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_after_each)); + l_suite := ut3_develop.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); + l_suite.before_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3_develop.ut_utils.gc_before_all)); + l_test := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_test.before_each_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3_develop.ut_utils.gc_before_each)); + l_test.after_each_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3_develop.ut_utils.gc_after_each)); l_suite.items.extend; l_suite.items(l_suite.items.last) := l_test; l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); --Act l_suite.do_execute(); --Assert ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(3); - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(l_suite.results_count.disabled_count).to_equal(0); ut.expect(l_suite.results_count.warnings_count).to_equal(0); ut.expect(l_suite.results_count.success_count).to_equal(1); @@ -86,24 +86,24 @@ create or replace package body test_ut_test is end; procedure beforetest_errors is - l_suite ut3.ut_suite; - l_test ut3.ut_test; + l_suite ut3_develop.ut_suite; + l_test ut3_develop.ut_test; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); - l_test := ut3.ut_test(a_object_owner =>'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); - l_test.before_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_before_test)); - l_test.after_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_test)); + l_suite := ut3_develop.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); + l_suite.before_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3_develop.ut_utils.gc_before_all)); + l_test := ut3_develop.ut_test(a_object_owner =>'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_test.before_test_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3_develop.ut_utils.gc_before_test)); + l_test.after_test_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3_develop.ut_utils.gc_after_test)); l_suite.items.extend; l_suite.items(l_suite.items.last) := l_test; l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner =>'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner =>'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); --Act l_suite.do_execute(); --Assert ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(2); - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(l_suite.results_count.disabled_count).to_equal(0); ut.expect(l_suite.results_count.warnings_count).to_equal(0); ut.expect(l_suite.results_count.success_count).to_equal(1); @@ -112,24 +112,24 @@ create or replace package body test_ut_test is end; procedure beforeeach_errors is - l_suite ut3.ut_suite; - l_test ut3.ut_test; + l_suite ut3_develop.ut_suite; + l_test ut3_develop.ut_test; begin --Arrange - l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_all)); - l_test := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); - l_test.before_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3.ut_utils.gc_before_each)); - l_test.after_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_each)); + l_suite := ut3_develop.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_line_no=> 1); + l_suite.before_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3_develop.ut_utils.gc_before_all)); + l_test := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_test.before_each_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'failing_procedure', ut3_develop.ut_utils.gc_before_each)); + l_test.after_each_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3_develop.ut_utils.gc_after_each)); l_suite.items.extend; l_suite.items(l_suite.items.last) := l_test; l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper',a_object_name => 'ut_example_tests',a_name => 'add_1_to_g_number', a_line_no=> 1); --Act l_suite.do_execute(); --Assert ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(2); - ut.expect(l_suite.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_suite.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(l_suite.results_count.disabled_count).to_equal(0); ut.expect(l_suite.results_count.warnings_count).to_equal(0); ut.expect(l_suite.results_count.success_count).to_equal(1); @@ -139,63 +139,63 @@ create or replace package body test_ut_test is procedure after_each_executed is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.after_each_list := ut3.ut_executables( - ut3.ut_executable( + l_test.after_each_list := ut3_develop.ut_executables( + ut3_develop.ut_executable( 'ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', - ut3.ut_utils.gc_after_each + ut3_develop.ut_utils.gc_after_each ) ); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_success); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_success); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(1); end; procedure after_each_proc_name_invalid is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.after_each_list := ut3.ut_executables( - ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid setup name', ut3.ut_utils.gc_after_each) + l_test.after_each_list := ut3_develop.ut_executables( + ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid setup name', ut3_develop.ut_utils.gc_after_each) ); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(0); end; procedure after_each_procedure_name_null is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.after_each_list := ut3.ut_executables( - ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3.ut_utils.gc_after_each) + l_test.after_each_list := ut3_develop.ut_executables( + ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3_develop.ut_utils.gc_after_each) ); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(0); end; @@ -292,7 +292,7 @@ create or replace package body test_ut_test is end; procedure application_info_on_execution is - l_output_data ut3.ut_varchar2_list; + l_output_data ut3_develop.ut_varchar2_list; l_output clob; function get_test_value(a_variable_name varchar2) return varchar2 is l_result varchar2(4000); @@ -303,8 +303,8 @@ create or replace package body test_ut_test is begin --act select * bulk collect into l_output_data - from table(ut3.ut.run('ut_output_tests')); - l_output := ut3.ut_utils.table_to_clob(l_output_data); + from table(ut3_develop.ut.run('ut_output_tests')); + l_output := ut3_develop.ut_utils.table_to_clob(l_output_data); --assert ut.expect(get_test_value('gv_before_all_client_info')).to_equal('beforeall'); @@ -318,80 +318,80 @@ create or replace package body test_ut_test is procedure before_each_executed is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'add_1_to_g_number', a_line_no => null ); begin - l_test.before_each_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_each)); + l_test.before_each_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3_develop.ut_utils.gc_before_each)); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_success); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_success); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(1); end; procedure before_each_proc_name_invalid is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.before_each_list := ut3.ut_executables( - ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid setup name', ut3.ut_utils.gc_before_each) + l_test.before_each_list := ut3_develop.ut_executables( + ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid setup name', ut3_develop.ut_utils.gc_before_each) ); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_be_null; end; procedure before_each_proc_name_null is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.before_each_list := ut3.ut_executables( - ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3.ut_utils.gc_before_each) + l_test.before_each_list := ut3_develop.ut_executables( + ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3_develop.ut_utils.gc_before_each) ); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_be_null; end; procedure ignore_savepoint_exception is pragma autonomous_transaction; --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'ut_commit_test', a_line_no => null ); begin - l_test.rollback_type := ut3.ut_utils.gc_rollback_auto; + l_test.rollback_type := ut3_develop.ut_utils.gc_rollback_auto; --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_success); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_success); end; procedure owner_name_invalid is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'invalid owner name', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', @@ -401,7 +401,7 @@ create or replace package body test_ut_test is --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); end; procedure create_synonym is @@ -416,7 +416,7 @@ create or replace package body test_ut_test is procedure owner_name_null is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null @@ -425,7 +425,7 @@ create or replace package body test_ut_test is --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_success); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_success); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(0); end; @@ -450,7 +450,7 @@ create or replace package body test_ut_test is procedure package_in_invalid_state is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_name => 'invalid_package', a_name => 'ut_exampletest', a_line_no => null @@ -459,12 +459,12 @@ create or replace package body test_ut_test is --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); end; procedure package_name_invalid is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_name => 'invalid package name', a_name => 'set_g_number_0', a_line_no => null @@ -473,12 +473,12 @@ create or replace package body test_ut_test is --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); end; procedure package_name_null is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_name => null, a_name => 'set_g_number_0', a_line_no => null @@ -487,12 +487,12 @@ create or replace package body test_ut_test is --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); end; procedure procedure_name_invalid is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'invalid procedure name', @@ -502,12 +502,12 @@ create or replace package body test_ut_test is --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); end; procedure procedure_name_null is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => null, @@ -517,116 +517,116 @@ create or replace package body test_ut_test is --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); end; procedure before_test_executed is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'add_1_to_g_number', a_line_no => null ); begin - l_test.before_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3.ut_utils.gc_before_test)); + l_test.before_test_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'set_g_number_0', ut3_develop.ut_utils.gc_before_test)); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_success); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_success); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(1); end; procedure before_test_proc_name_invalid is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.before_test_list := ut3.ut_executables( - ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid setup name', ut3.ut_utils.gc_before_test) + l_test.before_test_list := ut3_develop.ut_executables( + ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid setup name', ut3_develop.ut_utils.gc_before_test) ); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_be_null; end; procedure before_test_proc_name_null is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.before_test_list := ut3.ut_executables( - ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3.ut_utils.gc_before_test) + l_test.before_test_list := ut3_develop.ut_executables( + ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3_develop.ut_utils.gc_before_test) ); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_be_null; end; procedure after_test_executed is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.after_test_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3.ut_utils.gc_after_test)); + l_test.after_test_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'add_1_to_g_number', ut3_develop.ut_utils.gc_after_test)); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_success); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_success); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(1); end; procedure after_test_proce_name_invalid is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.after_test_list := ut3.ut_executables( - ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid procedure name', ut3.ut_utils.gc_after_test) + l_test.after_test_list := ut3_develop.ut_executables( + ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', 'invalid procedure name', ut3_develop.ut_utils.gc_after_test) ); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(0); end; procedure after_test_proc_name_null is --Arrange - l_test ut3.ut_test := ut3.ut_test( + l_test ut3_develop.ut_test := ut3_develop.ut_test( a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_example_tests', a_name => 'set_g_number_0', a_line_no => null ); begin - l_test.after_test_list := ut3.ut_executables( - ut3.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3.ut_utils.gc_after_test) + l_test.after_test_list := ut3_develop.ut_executables( + ut3_develop.ut_executable('ut3_tester_helper', 'ut_example_tests', null, ut3_develop.ut_utils.gc_after_test) ); --Act l_test.do_execute(); --Assert - ut.expect(l_test.result).to_equal(ut3.ut_utils.gc_error); + ut.expect(l_test.result).to_equal(ut3_develop.ut_utils.gc_error); ut.expect(ut3_tester_helper.ut_example_tests.g_number).to_equal(0); end; @@ -711,12 +711,12 @@ create or replace package body test_ut_test is end; procedure test_output_gathering is - l_output_data ut3.ut_varchar2_list; + l_output_data ut3_develop.ut_varchar2_list; l_output clob; begin select * bulk collect into l_output_data - from table(ut3.ut.run('ut_output_tests')); - l_output := ut3.ut_utils.table_to_clob(l_output_data); + from table(ut3_develop.ut.run('ut_output_tests')); + l_output := ut3_develop.ut_utils.table_to_clob(l_output_data); ut.expect(l_output).to_be_like( '%%%%%%%%1 tests, 0 failed, 0 errored%' ); diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 31e1520d2..a3ed605f9 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -33,17 +33,17 @@ create or replace package body test_ut_utils is end; - procedure common_clob_to_table_exec(p_clob varchar2, p_delimiter varchar2, p_expected_list ut3.ut_varchar2_list, p_limit number) is + procedure common_clob_to_table_exec(p_clob varchar2, p_delimiter varchar2, p_expected_list ut3_develop.ut_varchar2_list, p_limit number) is begin execute immediate 'declare l_clob clob := '''||p_clob||'''; l_delimiter varchar2(1) := '''||p_delimiter||'''; - l_expected ut3.ut_varchar2_list := :p_expected_list; - l_result ut3.ut_varchar2_list; + l_expected ut3_develop.ut_varchar2_list := :p_expected_list; + l_result ut3_develop.ut_varchar2_list; l_limit integer := '||p_limit||q'[; l_result_str varchar2(32767); l_errors integer := 0; - function compare_element(a_element_id integer, a_expected ut3.ut_varchar2_list, a_actual ut3.ut_varchar2_list) return integer is + function compare_element(a_element_id integer, a_expected ut3_develop.ut_varchar2_list, a_actual ut3_develop.ut_varchar2_list) return integer is begin if a_expected.exists(a_element_id) and a_actual.exists(a_element_id) then if a_expected(a_element_id) = a_actual(a_element_id) or a_expected(a_element_id) is null and a_actual(a_element_id) is null then @@ -63,7 +63,7 @@ create or replace package body test_ut_utils is end; begin --Act - select column_value bulk collect into l_result from table( ut3.ut_utils.clob_to_table(l_clob, l_limit, l_delimiter) ); + select column_value bulk collect into l_result from table( ut3_develop.ut_utils.clob_to_table(l_clob, l_limit, l_delimiter) ); for i in 1 .. l_result.count loop l_result_str := l_result_str||''''||l_result(i)||''''||l_delimiter; end loop; @@ -78,68 +78,68 @@ end;]' using p_expected_list; procedure test_clob_to_table is begin - common_clob_to_table_exec('a,b,c,d', ',', ut3.ut_varchar2_list('a','b','c','d'), 1000); - common_clob_to_table_exec( '', ',', ut3.ut_varchar2_list(), 1000); - common_clob_to_table_exec( '1,b,c,d', '', ut3.ut_varchar2_list('1,b,','c,d'), 4); - common_clob_to_table_exec( 'abcdefg,hijk,axa,a', ',', ut3.ut_varchar2_list('abc','def','g','hij','k','axa','a'), 3); - common_clob_to_table_exec( ',a,,c,d,', ',', ut3.ut_varchar2_list('','a','','c','d',''), 1000); + common_clob_to_table_exec('a,b,c,d', ',', ut3_develop.ut_varchar2_list('a','b','c','d'), 1000); + common_clob_to_table_exec( '', ',', ut3_develop.ut_varchar2_list(), 1000); + common_clob_to_table_exec( '1,b,c,d', '', ut3_develop.ut_varchar2_list('1,b,','c,d'), 4); + common_clob_to_table_exec( 'abcdefg,hijk,axa,a', ',', ut3_develop.ut_varchar2_list('abc','def','g','hij','k','axa','a'), 3); + common_clob_to_table_exec( ',a,,c,d,', ',', ut3_develop.ut_varchar2_list('','a','','c','d',''), 1000); end; procedure test_test_result_to_char is begin - ut.expect(ut3.ut_utils.test_result_to_char(-1),'test unknown').to_equal('Unknown(-1)'); - ut.expect(ut3.ut_utils.test_result_to_char(null),'test unknown').to_equal('Unknown(NULL)'); - ut.expect(ut3.ut_utils.test_result_to_char(ut3.ut_utils.gc_success),'test unknown').to_equal(ut3.ut_utils.gc_success_char); + ut.expect(ut3_develop.ut_utils.test_result_to_char(-1),'test unknown').to_equal('Unknown(-1)'); + ut.expect(ut3_develop.ut_utils.test_result_to_char(null),'test unknown').to_equal('Unknown(NULL)'); + ut.expect(ut3_develop.ut_utils.test_result_to_char(ut3_develop.ut_utils.gc_success),'test unknown').to_equal(ut3_develop.ut_utils.gc_success_char); end; procedure to_string_emptyblob is begin - ut.expect(ut3.ut_data_value_blob(empty_blob()).to_string()).to_equal('EMPTY'); + ut.expect(ut3_develop.ut_data_value_blob(empty_blob()).to_string()).to_equal('EMPTY'); end; procedure to_string_emptyclob is begin - ut.expect(ut3.ut_data_value_clob(empty_clob()).to_string()).to_equal('EMPTY'); + ut.expect(ut3_develop.ut_data_value_clob(empty_clob()).to_string()).to_equal('EMPTY'); end; procedure to_string_nullblob is begin - ut.expect(ut3.ut_data_value_blob(null).to_string()).to_equal('NULL'); + ut.expect(ut3_develop.ut_data_value_blob(null).to_string()).to_equal('NULL'); end; procedure to_string_nullclob is begin - ut.expect(ut3.ut_data_value_clob(null).to_string()).to_equal('NULL'); + ut.expect(ut3_develop.ut_data_value_clob(null).to_string()).to_equal('NULL'); end; procedure to_string_nulldate is begin - ut.expect(ut3.ut_data_value_date(null).to_string()).to_equal('NULL'); + ut.expect(ut3_develop.ut_data_value_date(null).to_string()).to_equal('NULL'); end; procedure to_string_nullnumber is begin - ut.expect(ut3.ut_data_value_number(null).to_string()).to_equal('NULL'); + ut.expect(ut3_develop.ut_data_value_number(null).to_string()).to_equal('NULL'); end; procedure to_string_nulltimestamp is begin - ut.expect(ut3.ut_data_value_timestamp(null).to_string()).to_equal('NULL'); + ut.expect(ut3_develop.ut_data_value_timestamp(null).to_string()).to_equal('NULL'); end; procedure to_string_nulltimestamp_ltz is begin - ut.expect(ut3.ut_data_value_timestamp_ltz(null).to_string()).to_equal('NULL'); + ut.expect(ut3_develop.ut_data_value_timestamp_ltz(null).to_string()).to_equal('NULL'); end; procedure to_string_nulltimestamp_tz is begin - ut.expect(ut3.ut_data_value_timestamp_tz(null).to_string()).to_equal('NULL'); + ut.expect(ut3_develop.ut_data_value_timestamp_tz(null).to_string()).to_equal('NULL'); end; procedure to_string_nullvarchar2 is begin - ut.expect(ut3.ut_data_value_varchar2(null).to_string()).to_equal('NULL'); + ut.expect(ut3_develop.ut_data_value_varchar2(null).to_string()).to_equal('NULL'); end; procedure to_string_blob is @@ -147,49 +147,49 @@ end;]' using p_expected_list; l_value blob := utl_raw.cast_to_raw(l_text); l_expected varchar2(32767) := ''''||rawtohex(l_value)||''''; begin - ut.expect(ut3.ut_data_value_blob(l_value).to_string()).to_equal(l_expected); + ut.expect(ut3_develop.ut_data_value_blob(l_value).to_string()).to_equal(l_expected); end; procedure to_string_clob is l_value clob := 'A test char'; l_expected varchar2(32767) := ''''||l_value||''''; begin - ut.expect(ut3.ut_data_value_clob(l_value).to_string()).to_equal(l_expected); + ut.expect(ut3_develop.ut_data_value_clob(l_value).to_string()).to_equal(l_expected); end; procedure to_string_date is l_value date := to_date('2016-12-31 23:59:59', 'yyyy-mm-dd hh24:mi:ss'); l_expected varchar2(100) := '2016-12-31T23:59:59'; begin - ut.expect(ut3.ut_data_value_date(l_value).to_string()).to_equal(l_expected); + ut.expect(ut3_develop.ut_data_value_date(l_value).to_string()).to_equal(l_expected); end; procedure to_string_timestamp is l_value timestamp(9) := to_timestamp('2016-12-31 23:59:59.123456789', 'yyyy-mm-dd hh24:mi:ss.ff'); l_expected varchar2(100) := '2016-12-31T23:59:59'||gc_delimiter||'123456789'; begin - ut.expect(ut3.ut_data_value_timestamp(l_value).to_string()).to_equal(l_expected); + ut.expect(ut3_develop.ut_data_value_timestamp(l_value).to_string()).to_equal(l_expected); end; procedure to_string_timestamp_ltz is l_value timestamp(9) with local time zone := to_timestamp('2016-12-31 23:59:59.123456789', 'yyyy-mm-dd hh24:mi:ss.ff'); l_expected varchar2(100) := '2016-12-31T23:59:59'||gc_delimiter||'123456789'; begin - ut.expect(ut3.ut_data_value_timestamp_ltz(l_value).to_string()).to_equal(l_expected); + ut.expect(ut3_develop.ut_data_value_timestamp_ltz(l_value).to_string()).to_equal(l_expected); end; procedure to_string_timestamp_tz is l_value timestamp(9) with time zone := to_timestamp_tz('2016-12-31 23:59:59.123456789 -8:00', 'yyyy-mm-dd hh24:mi:ss.ff tzh:tzm'); l_expected varchar2(100) := '2016-12-31T23:59:59'||gc_delimiter||'123456789 -08:00'; begin - ut.expect(ut3.ut_data_value_timestamp_tz(l_value).to_string()).to_equal(l_expected); + ut.expect(ut3_develop.ut_data_value_timestamp_tz(l_value).to_string()).to_equal(l_expected); end; procedure to_string_varchar2 is l_value varchar2(20) := 'A test char'; l_expected varchar2(100) := ''''||l_value||''''; begin - ut.expect(ut3.ut_data_value_varchar2(l_value).to_string()).to_equal(l_expected); + ut.expect(ut3_develop.ut_data_value_varchar2(l_value).to_string()).to_equal(l_expected); end; procedure to_string_verybigblob is @@ -197,53 +197,53 @@ end;]' using p_expected_list; l_value blob; begin l_value := clob_to_blob(l_text); - ut.expect(length(ut3.ut_data_value_blob(l_value).to_string())).to_equal(ut3.ut_utils.gc_max_output_string_length); - ut.expect(ut3.ut_data_value_blob(l_value).to_string()).to_be_like('%'||ut3.ut_utils.gc_more_data_string); + ut.expect(length(ut3_develop.ut_data_value_blob(l_value).to_string())).to_equal(ut3_develop.ut_utils.gc_max_output_string_length); + ut.expect(ut3_develop.ut_data_value_blob(l_value).to_string()).to_be_like('%'||ut3_develop.ut_utils.gc_more_data_string); end; procedure to_string_verybigclob is l_value clob := lpad('A test char',32767,'1')||lpad('1',32767,'1'); begin - ut.expect(length(ut3.ut_data_value_clob(l_value).to_string())).to_equal(ut3.ut_utils.gc_max_output_string_length); - ut.expect(ut3.ut_data_value_clob(l_value).to_string()).to_be_like('%'||ut3.ut_utils.gc_more_data_string); + ut.expect(length(ut3_develop.ut_data_value_clob(l_value).to_string())).to_equal(ut3_develop.ut_utils.gc_max_output_string_length); + ut.expect(ut3_develop.ut_data_value_clob(l_value).to_string()).to_be_like('%'||ut3_develop.ut_utils.gc_more_data_string); end; procedure to_string_verybignumber is l_value number := 1234567890123456789012345678901234567890; l_expected varchar2(100) := '1234567890123456789012345678901234567890'; begin - ut.expect(ut3.ut_data_value_number(l_value).to_string()).to_equal(l_expected); + ut.expect(ut3_develop.ut_data_value_number(l_value).to_string()).to_equal(l_expected); end; procedure to_string_verybigvarchar2 is l_value varchar2(32767) := lpad('A test char',32767,'1'); l_result varchar2(32767); begin - ut.expect(length(ut3.ut_data_value_varchar2(l_value).to_string())).to_equal(ut3.ut_utils.gc_max_output_string_length); - ut.expect(ut3.ut_data_value_varchar2(l_value).to_string()).to_be_like('%'||ut3.ut_utils.gc_more_data_string); + ut.expect(length(ut3_develop.ut_data_value_varchar2(l_value).to_string())).to_equal(ut3_develop.ut_utils.gc_max_output_string_length); + ut.expect(ut3_develop.ut_data_value_varchar2(l_value).to_string()).to_be_like('%'||ut3_develop.ut_utils.gc_more_data_string); end; procedure to_string_verysmallnumber is l_value number := 0.123456789012345678901234567890123456789; l_expected varchar2(100) := gc_delimiter||'123456789012345678901234567890123456789'; begin - ut.expect(ut3.ut_data_value_number(l_value).to_string()).to_equal(l_expected); + ut.expect(ut3_develop.ut_data_value_number(l_value).to_string()).to_equal(l_expected); end; procedure test_table_to_clob is - procedure exec_table_to_clob(a_list ut3.ut_varchar2_list, a_delimiter varchar2, a_expected clob) is + procedure exec_table_to_clob(a_list ut3_develop.ut_varchar2_list, a_delimiter varchar2, a_expected clob) is l_result clob; begin - l_result := ut3.ut_utils.table_to_clob(a_list, a_delimiter); + l_result := ut3_develop.ut_utils.table_to_clob(a_list, a_delimiter); ut.expect(l_result).to_equal(a_expected, a_nulls_are_equal => true); end; begin exec_table_to_clob(null, ',', ''); - exec_table_to_clob(ut3.ut_varchar2_list(), ',', ''); - exec_table_to_clob(ut3.ut_varchar2_list('a', 'b', 'c', 'd'), ',', 'a,b,c,d'); - exec_table_to_clob(ut3.ut_varchar2_list('1,b,', 'c,d'), ',', '1,b,,c,d'); - exec_table_to_clob(ut3.ut_varchar2_list('', 'a', '', 'c', 'd', ''), ',', ',a,,c,d,'); + exec_table_to_clob(ut3_develop.ut_varchar2_list(), ',', ''); + exec_table_to_clob(ut3_develop.ut_varchar2_list('a', 'b', 'c', 'd'), ',', 'a,b,c,d'); + exec_table_to_clob(ut3_develop.ut_varchar2_list('1,b,', 'c,d'), ',', '1,b,,c,d'); + exec_table_to_clob(ut3_develop.ut_varchar2_list('', 'a', '', 'c', 'd', ''), ',', ',a,,c,d,'); end; procedure test_append_with_multibyte is @@ -258,7 +258,7 @@ end;]' using p_expected_list; for i in 1..l_lines.count loop l_result := null; - ut3.ut_utils.append_to_clob(l_result, l_lines(i)); + ut3_develop.ut_utils.append_to_clob(l_result, l_lines(i)); --Assert ut.expect(dbms_lob.getlength(l_result),'Error for index '||i).to_equal(dbms_lob.getlength(l_lines(i))); @@ -289,21 +289,21 @@ end;'; l_singlebyte_string_max_size varchar2(32767 char) := rpad('x',l_varchar2_byte_limit,'x'); l_twobyte_character char(1 char) := '�?'; l_clob_multibyte clob := l_twobyte_character||l_singlebyte_string_max_size; --here we have 32769(2+32767) bytes and 32768 chars - l_expected ut3.ut_varchar2_list := ut3.ut_varchar2_list(); - l_result ut3.ut_varchar2_list; + l_expected ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list(); + l_result ut3_develop.ut_varchar2_list; begin l_expected.extend(1); l_expected(1) := l_twobyte_character||substr(l_singlebyte_string_max_size,1,l_workaround_byte_limit-1); --Act - l_result := ut3.ut_utils.clob_to_table(l_clob_multibyte); + l_result := ut3_develop.ut_utils.clob_to_table(l_clob_multibyte); --Assert ut.expect(l_result(1)).to_equal(l_expected(1)); end; procedure test_to_version_split is - l_version ut3.ut_utils.t_version; + l_version ut3_develop.ut_utils.t_version; begin - l_version := ut3.ut_utils.to_version('v034.0.0456.0333'); + l_version := ut3_develop.ut_utils.to_version('v034.0.0456.0333'); ut.expect(l_version.major).to_equal(34); ut.expect(l_version.minor).to_equal(0); ut.expect(l_version.bugfix).to_equal(456); @@ -312,62 +312,62 @@ end;'; procedure test_trim_list_elements is - l_list_to_be_equal ut3.ut_varchar2_list := ut3.ut_varchar2_list('hello', 'world', 'okay'); - l_list ut3.ut_varchar2_list := ut3.ut_varchar2_list(' hello ', chr(9)||'world ', 'okay'); + l_list_to_be_equal ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list('hello', 'world', 'okay'); + l_list ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list(' hello ', chr(9)||'world ', 'okay'); begin --Act - l_list := ut3.ut_utils.trim_list_elements(l_list); + l_list := ut3_develop.ut_utils.trim_list_elements(l_list); --Assert ut.expect(anydata.convertcollection(l_list)).to_equal(anydata.convertcollection(l_list_to_be_equal)); end; procedure trim_list_elemts_null_collect is - l_list_to_be_null ut3.ut_varchar2_list; + l_list_to_be_null ut3_develop.ut_varchar2_list; begin --Act - l_list_to_be_null := ut3.ut_utils.trim_list_elements(l_list_to_be_null); + l_list_to_be_null := ut3_develop.ut_utils.trim_list_elements(l_list_to_be_null); --Assert ut.expect(anydata.convertcollection(l_list_to_be_null)).to_be_null; end; procedure trim_list_elemts_empty_collect is - l_list_to_be_empty ut3.ut_varchar2_list := ut3.ut_varchar2_list(); + l_list_to_be_empty ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list(); begin --Act - l_list_to_be_empty := ut3.ut_utils.trim_list_elements(l_list_to_be_empty); + l_list_to_be_empty := ut3_develop.ut_utils.trim_list_elements(l_list_to_be_empty); --Assert ut.expect(anydata.convertcollection(l_list_to_be_empty)).to_be_empty; end; procedure test_filter_list is - l_list_to_be_equal ut3.ut_varchar2_list := ut3.ut_varchar2_list('-12458', '8956', '789'); - l_list ut3.ut_varchar2_list := ut3.ut_varchar2_list('-12458', '8956', 'okay', null,'458963', '789'); + l_list_to_be_equal ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list('-12458', '8956', '789'); + l_list ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list('-12458', '8956', 'okay', null,'458963', '789'); begin --Act - l_list := ut3.ut_utils.filter_list(l_list, '^-?[[:digit:]]{1,5}$'); + l_list := ut3_develop.ut_utils.filter_list(l_list, '^-?[[:digit:]]{1,5}$'); --Assert ut.expect(anydata.convertcollection(l_list)).to_equal(anydata.convertcollection(l_list_to_be_equal)); end; procedure filter_list_null_collection is - l_list_to_be_null ut3.ut_varchar2_list; + l_list_to_be_null ut3_develop.ut_varchar2_list; begin --Act - l_list_to_be_null := ut3.ut_utils.filter_list(l_list_to_be_null, '^-?[[:digit:]]{1,5}$'); + l_list_to_be_null := ut3_develop.ut_utils.filter_list(l_list_to_be_null, '^-?[[:digit:]]{1,5}$'); --Assert ut.expect(anydata.convertcollection(l_list_to_be_null)).to_be_null; end; procedure filter_list_empty_collection is - l_list_to_be_empty ut3.ut_varchar2_list := ut3.ut_varchar2_list(); + l_list_to_be_empty ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list(); begin --Act - l_list_to_be_empty := ut3.ut_utils.filter_list(l_list_to_be_empty, '^-?[[:digit:]]{1,5}$'); + l_list_to_be_empty := ut3_develop.ut_utils.filter_list(l_list_to_be_empty, '^-?[[:digit:]]{1,5}$'); --Assert ut.expect(anydata.convertcollection(l_list_to_be_empty)).to_be_empty; end; @@ -428,7 +428,7 @@ create or replace package dummy as end; ]'; --Act - l_actual := ut3.ut_utils.replace_multiline_comments(l_source); + l_actual := ut3_develop.ut_utils.replace_multiline_comments(l_source); --Assert ut.expect(l_actual).to_equal(l_expected); end; diff --git a/test/ut3_tester_helper/annotation_cache_helper.pkb b/test/ut3_tester_helper/annotation_cache_helper.pkb index c61c797fc..1a52faade 100644 --- a/test/ut3_tester_helper/annotation_cache_helper.pkb +++ b/test/ut3_tester_helper/annotation_cache_helper.pkb @@ -15,8 +15,8 @@ create or replace package body annotation_cache_helper as execute immediate 'create or replace package body ut3_cache_test_owner.granted_test_suite is - procedure test1 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; - procedure test2 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; + procedure test1 is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; + procedure test2 is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; end;'; execute immediate 'create or replace package ut3_cache_test_owner.not_granted_test_suite is @@ -29,8 +29,8 @@ create or replace package body annotation_cache_helper as end;'; execute immediate 'create or replace package body ut3_cache_test_owner.not_granted_test_suite is - procedure test1 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; - procedure test2 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; + procedure test1 is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; + procedure test2 is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; end;'; execute immediate @@ -65,8 +65,8 @@ create or replace package body annotation_cache_helper as execute immediate 'create or replace package body ut3_cache_test_owner.new_suite is - procedure test1 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; - procedure test2 is begin ut3.ut.expect( 1 ).to_equal( 1 ); end; + procedure test1 is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; + procedure test2 is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; end;'; execute immediate 'grant execute on ut3_cache_test_owner.new_suite to @@ -101,21 +101,21 @@ create or replace package body annotation_cache_helper as procedure purge_annotation_cache is begin - ut3.ut_runner.purge_cache( 'UT3_CACHE_TEST_OWNER' ); + ut3_develop.ut_runner.purge_cache( 'UT3_CACHE_TEST_OWNER' ); end; procedure disable_ddl_trigger is pragma autonomous_transaction; begin - execute immediate 'alter trigger ut3.ut_trigger_annotation_parsing disable'; - execute immediate 'begin ut3.ut_trigger_check.is_alive( ); end;'; + execute immediate 'alter trigger ut3_develop.ut_trigger_annotation_parsing disable'; + execute immediate 'begin ut3_develop.ut_trigger_check.is_alive( ); end;'; end; procedure enable_ddl_trigger is pragma autonomous_transaction; begin - execute immediate 'alter trigger ut3.ut_trigger_annotation_parsing enable'; + execute immediate 'alter trigger ut3_develop.ut_trigger_annotation_parsing enable'; end; procedure create_run_function_for_user(a_user varchar2) is @@ -123,10 +123,10 @@ create or replace package body annotation_cache_helper as begin execute immediate 'create or replace function ' || a_user || '.call_ut_run return clob is - l_data ut3.ut_varchar2_list; + l_data ut3_develop.ut_varchar2_list; l_results clob; begin - select * bulk collect into l_data from table (ut3.ut.run( ''ut3_cache_test_owner'' )); + select * bulk collect into l_data from table (ut3_develop.ut.run( ''ut3_cache_test_owner'' )); return ut3_tester_helper.main_helper.table_to_clob( l_data ); end; '; @@ -146,7 +146,7 @@ create or replace package body annotation_cache_helper as create_run_function_for_user( 'ut3_select_any_table_user' ); create_run_function_for_user( 'ut3_execute_any_proc_user' ); create_run_function_for_user( 'ut3_cache_test_owner' ); - create_run_function_for_user( 'ut3' ); + create_run_function_for_user( 'ut3_develop' ); end; procedure drop_run_function_for_users is @@ -156,7 +156,7 @@ create or replace package body annotation_cache_helper as drop_run_function_for_user( 'ut3_select_any_table_user' ); drop_run_function_for_user( 'ut3_execute_any_proc_user' ); drop_run_function_for_user( 'ut3_cache_test_owner' ); - drop_run_function_for_user( 'ut3' ); + drop_run_function_for_user( 'ut3_develop' ); end; function run_tests_as(a_user varchar2) return clob is diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 1db078a8b..e86a155fa 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -1,6 +1,6 @@ create or replace package body coverage_helper is - g_run_ids ut3.ut_coverage.tt_coverage_id_arr; + g_run_ids ut3_develop.ut_coverage.tt_coverage_id_arr; g_profiler_run_id integer; g_block_run_id integer; @@ -8,7 +8,7 @@ create or replace package body coverage_helper is v_result integer; begin select nvl(min(runid),0) - 1 into v_result - from ut3.plsql_profiler_runs; + from ut3_develop.plsql_profiler_runs; return v_result; end; @@ -16,16 +16,16 @@ create or replace package body coverage_helper is v_result integer; begin select nvl(min(run_id),0) - 1 into v_result - from ut3.dbmspcc_runs; + from ut3_develop.dbmspcc_runs; return v_result; end; procedure setup_mock_coverage_ids(a_profiler_run_id integer, a_block_run_id integer) is - l_coverage_ids ut3.ut_coverage.tt_coverage_id_arr; + l_coverage_ids ut3_develop.ut_coverage.tt_coverage_id_arr; begin - l_coverage_ids(ut3.ut_coverage.gc_proftab_coverage) := a_profiler_run_id; - l_coverage_ids(ut3.ut_coverage.gc_block_coverage) := a_block_run_id; - ut3.ut_coverage.mock_coverage_id(l_coverage_ids); + l_coverage_ids(ut3_develop.ut_coverage.gc_proftab_coverage) := a_profiler_run_id; + l_coverage_ids(ut3_develop.ut_coverage.gc_block_coverage) := a_block_run_id; + ut3_develop.ut_coverage.mock_coverage_id(l_coverage_ids); end; procedure setup_mock_coverage_id is @@ -54,13 +54,13 @@ create or replace package body coverage_helper is procedure mock_coverage_data(a_user in varchar2) is c_unit_id constant integer := 1; begin - insert into ut3.plsql_profiler_runs ( runid, run_owner, run_date, run_comment) + insert into ut3_develop.plsql_profiler_runs ( runid, run_owner, run_date, run_comment) values(g_profiler_run_id, a_user, sysdate, 'unit testing utPLSQL'); - insert into ut3.plsql_profiler_units ( runid, unit_number, unit_type, unit_owner, unit_name) - values(g_profiler_run_id, c_unit_id, 'PACKAGE BODY', 'UT3', 'DUMMY_COVERAGE'); + insert into ut3_develop.plsql_profiler_units ( runid, unit_number, unit_type, unit_owner, unit_name) + values(g_profiler_run_id, c_unit_id, 'PACKAGE BODY', 'UT3_DEVELOP', 'DUMMY_COVERAGE'); - insert into ut3.plsql_profiler_data ( runid, unit_number, line#, total_occur, total_time) + insert into ut3_develop.plsql_profiler_data ( runid, unit_number, line#, total_occur, total_time) select g_profiler_run_id, c_unit_id, 4, 1, 1 from dual union all select g_profiler_run_id, c_unit_id, 5, 0, 0 from dual union all select g_profiler_run_id, c_unit_id, 7, 1, 1 from dual; @@ -69,17 +69,17 @@ create or replace package body coverage_helper is procedure cleanup_dummy_coverage(a_run_id in integer) is pragma autonomous_transaction; begin - delete from ut3.plsql_profiler_data where runid = a_run_id; - delete from ut3.plsql_profiler_units where runid = a_run_id; - delete from ut3.plsql_profiler_runs where runid = a_run_id; + delete from ut3_develop.plsql_profiler_data where runid = a_run_id; + delete from ut3_develop.plsql_profiler_units where runid = a_run_id; + delete from ut3_develop.plsql_profiler_runs where runid = a_run_id; commit; end; procedure cleanup_dummy_coverage(a_block_id in integer, a_prof_id in integer) is pragma autonomous_transaction; begin - begin execute immediate q'[drop package ut3.test_block_dummy_coverage]'; exception when others then null; end; - begin execute immediate q'[drop package ut3.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.test_block_dummy_coverage]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long]'; exception when others then null; end; delete from dbmspcc_blocks where run_id = a_block_id; delete from dbmspcc_units where run_id = a_block_id; delete from dbmspcc_runs where run_id = a_block_id; @@ -98,12 +98,12 @@ create or replace package body coverage_helper is procedure create_dummy_coverage_package is pragma autonomous_transaction; begin - execute immediate q'[create or replace package UT3.DUMMY_COVERAGE is + execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE is procedure do_stuff; procedure grant_myself; end;]'; - execute immediate q'[create or replace package body UT3.DUMMY_COVERAGE is + execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE is procedure do_stuff is begin if 1 = 2 then @@ -115,7 +115,7 @@ create or replace package body coverage_helper is procedure grant_myself is begin - execute immediate 'grant debug,execute on UT3.DUMMY_COVERAGE to ut3$user#'; + execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE to ut3$user#'; end; end;]'; @@ -124,7 +124,7 @@ create or replace package body coverage_helper is procedure create_dummy_coverage_test is pragma autonomous_transaction; begin - execute immediate q'[create or replace package UT3.TEST_DUMMY_COVERAGE is + execute immediate q'[create or replace package UT3_DEVELOP.TEST_DUMMY_COVERAGE is --%suite(dummy coverage test) --%suitepath(coverage_testing) @@ -133,7 +133,7 @@ create or replace package body coverage_helper is procedure grant_myself; end;]'; - execute immediate q'[create or replace package body UT3.TEST_DUMMY_COVERAGE is + execute immediate q'[create or replace package body UT3_DEVELOP.TEST_DUMMY_COVERAGE is procedure test_do_stuff is begin dummy_coverage.do_stuff; @@ -141,7 +141,7 @@ create or replace package body coverage_helper is procedure grant_myself is begin - execute immediate 'grant debug,execute on UT3.TEST_DUMMY_COVERAGE to ut3$user#'; + execute immediate 'grant debug,execute on UT3_DEVELOP.TEST_DUMMY_COVERAGE to ut3$user#'; end; end;]'; @@ -150,26 +150,26 @@ create or replace package body coverage_helper is procedure grant_exec_on_cov is pragma autonomous_transaction; begin - execute immediate 'begin UT3.DUMMY_COVERAGE.grant_myself(); end;'; - execute immediate 'begin UT3.TEST_DUMMY_COVERAGE.grant_myself(); end;'; + execute immediate 'begin UT3_DEVELOP.DUMMY_COVERAGE.grant_myself(); end;'; + execute immediate 'begin UT3_DEVELOP.TEST_DUMMY_COVERAGE.grant_myself(); end;'; end; procedure drop_dummy_coverage_pkg is pragma autonomous_transaction; begin - begin execute immediate q'[drop package ut3.test_dummy_coverage]'; exception when others then null; end; - begin execute immediate q'[drop package ut3.dummy_coverage]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.test_dummy_coverage]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.dummy_coverage]'; exception when others then null; end; end; procedure create_dummy_coverage_test_1 is pragma autonomous_transaction; begin - execute immediate q'[create or replace package UT3.DUMMY_COVERAGE_1 is + execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE_1 is procedure do_stuff; procedure grant_myself; end;]'; - execute immediate q'[create or replace package body UT3.DUMMY_COVERAGE_1 is + execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE_1 is procedure do_stuff is begin if 1 = 2 then @@ -181,11 +181,11 @@ create or replace package body coverage_helper is procedure grant_myself is begin - execute immediate 'grant debug,execute on UT3.DUMMY_COVERAGE_1 to ut3$user#'; + execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE_1 to ut3$user#'; end; end;]'; - execute immediate q'[create or replace package UT3.TEST_DUMMY_COVERAGE_1 is + execute immediate q'[create or replace package UT3_DEVELOP.TEST_DUMMY_COVERAGE_1 is --%suite(dummy coverage test 1) --%suitepath(coverage_testing) @@ -194,7 +194,7 @@ create or replace package body coverage_helper is procedure grant_myself; end;]'; - execute immediate q'[create or replace package body UT3.TEST_DUMMY_COVERAGE_1 is + execute immediate q'[create or replace package body UT3_DEVELOP.TEST_DUMMY_COVERAGE_1 is procedure test_do_stuff is begin dummy_coverage_1.do_stuff; @@ -202,31 +202,31 @@ create or replace package body coverage_helper is procedure grant_myself is begin - execute immediate 'grant debug,execute on UT3.TEST_DUMMY_COVERAGE_1 to ut3$user#'; + execute immediate 'grant debug,execute on UT3_DEVELOP.TEST_DUMMY_COVERAGE_1 to ut3$user#'; end; end;]'; - execute immediate 'begin UT3.DUMMY_COVERAGE_1.grant_myself(); end;'; - execute immediate 'begin UT3.TEST_DUMMY_COVERAGE_1.grant_myself(); end;'; + execute immediate 'begin UT3_DEVELOP.DUMMY_COVERAGE_1.grant_myself(); end;'; + execute immediate 'begin UT3_DEVELOP.TEST_DUMMY_COVERAGE_1.grant_myself(); end;'; end; procedure drop_dummy_coverage_test_1 is pragma autonomous_transaction; begin - execute immediate q'[drop package UT3.DUMMY_COVERAGE_1]'; - execute immediate q'[drop package UT3.TEST_DUMMY_COVERAGE_1]'; + execute immediate q'[drop package UT3_DEVELOP.DUMMY_COVERAGE_1]'; + execute immediate q'[drop package UT3_DEVELOP.TEST_DUMMY_COVERAGE_1]'; end; --12.2 Setup procedure create_dummy_12_2_cov_pck is pragma autonomous_transaction; begin - execute immediate q'[create or replace package UT3.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is + execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is procedure do_stuff(i_input in number); procedure grant_myself; end;]'; - execute immediate q'[create or replace package body UT3.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is + execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is procedure do_stuff(i_input in number) is begin if i_input = 2 then @@ -238,7 +238,7 @@ create or replace package body coverage_helper is procedure grant_myself is begin - execute immediate 'grant debug,execute on UT3.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG to ut3$user#'; + execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG to ut3$user#'; end; end;]'; @@ -247,7 +247,7 @@ create or replace package body coverage_helper is procedure create_dummy_12_2_cov_test is pragma autonomous_transaction; begin - execute immediate q'[create or replace package UT3.TEST_BLOCK_DUMMY_COVERAGE is + execute immediate q'[create or replace package UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is --%suite(dummy coverage test) --%suitepath(coverage_testing) @@ -257,7 +257,7 @@ create or replace package body coverage_helper is procedure grant_myself; end;]'; - execute immediate q'[create or replace package body UT3.TEST_BLOCK_DUMMY_COVERAGE is + execute immediate q'[create or replace package body UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is procedure test_do_stuff is begin dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.do_stuff(1); @@ -266,7 +266,7 @@ create or replace package body coverage_helper is procedure grant_myself is begin - execute immediate 'grant debug,execute on UT3.TEST_BLOCK_DUMMY_COVERAGE to ut3$user#'; + execute immediate 'grant debug,execute on UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE to ut3$user#'; end; end;]'; end; @@ -278,7 +278,7 @@ create or replace package body coverage_helper is values(a_run_id, a_user, sysdate, 'unit testing utPLSQL'); insert into dbmspcc_units ( run_id, object_id, type, owner, name,last_ddl_time) - values(a_run_id, c_unit_id, 'PACKAGE BODY', 'UT3', 'DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG',sysdate); + values(a_run_id, c_unit_id, 'PACKAGE BODY', 'UT3_DEVELOP', 'DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG',sysdate); insert into dbmspcc_blocks ( run_id, object_id, line,block,col,covered,not_feasible) select a_run_id, c_unit_id,4,1,1,1,0 from dual union all @@ -290,13 +290,13 @@ create or replace package body coverage_helper is procedure mock_profiler_coverage_data(a_run_id integer,a_user in varchar2) is c_unit_id constant integer := 1; begin - insert into ut3.plsql_profiler_runs ( runid, run_owner, run_date, run_comment) + insert into ut3_develop.plsql_profiler_runs ( runid, run_owner, run_date, run_comment) values(a_run_id, a_user, sysdate, 'unit testing utPLSQL'); - insert into ut3.plsql_profiler_units ( runid, unit_number, unit_type, unit_owner, unit_name) - values(a_run_id, c_unit_id, 'PACKAGE BODY', 'UT3', 'DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG'); + insert into ut3_develop.plsql_profiler_units ( runid, unit_number, unit_type, unit_owner, unit_name) + values(a_run_id, c_unit_id, 'PACKAGE BODY', 'UT3_DEVELOP', 'DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG'); - insert into ut3.plsql_profiler_data ( runid, unit_number, line#, total_occur, total_time) + insert into ut3_develop.plsql_profiler_data ( runid, unit_number, line#, total_occur, total_time) select a_run_id, c_unit_id, 4, 1, 1 from dual union all select a_run_id, c_unit_id, 5, 0, 0 from dual union all select a_run_id, c_unit_id, 6, 1, 0 from dual union all @@ -306,13 +306,13 @@ create or replace package body coverage_helper is procedure grant_exec_on_12_2_cov is pragma autonomous_transaction; begin - execute immediate 'begin UT3.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG.grant_myself(); end;'; - execute immediate 'begin UT3.TEST_BLOCK_DUMMY_COVERAGE.grant_myself(); end;'; + execute immediate 'begin UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG.grant_myself(); end;'; + execute immediate 'begin UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE.grant_myself(); end;'; end; procedure set_develop_mode is begin - ut3.ut_coverage.set_develop_mode(true); + ut3_develop.ut_coverage.set_develop_mode(true); end; end; diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index 9e152707b..c240ed490 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -1,6 +1,6 @@ create or replace package coverage_helper is - type prof_runs_tab is table of ut3.plsql_profiler_runs%rowtype; + type prof_runs_tab is table of ut3_develop.plsql_profiler_runs%rowtype; function get_mock_proftab_run_id return integer; diff --git a/test/ut3_tester_helper/expectations_helper.pkb b/test/ut3_tester_helper/expectations_helper.pkb index cc86f18a6..c5c1f379f 100644 --- a/test/ut3_tester_helper/expectations_helper.pkb +++ b/test/ut3_tester_helper/expectations_helper.pkb @@ -12,7 +12,7 @@ create or replace package body expectations_helper is l_expected '||a_data_type||' := '||a_data_value||'; begin --act - execute the expectation - ut3.ut.expect(l_expected).'||a_matcher_name||'(); + ut3_develop.ut.expect(l_expected).'||a_matcher_name||'(); end;'; return l_execute; end; @@ -28,7 +28,7 @@ create or replace package body expectations_helper is declare l_object '||a_object_name||' := '||a_object_value||'; begin - ut3.ut.expect(anydata.convert'||a_object_type||'(l_object)).'||a_matcher_name||'(); + ut3_develop.ut.expect(anydata.convert'||a_object_type||'(l_object)).'||a_matcher_name||'(); end;'; end; @@ -48,7 +48,7 @@ create or replace package body expectations_helper is l_expected '||a_expected_data_type||' := '||a_expected_data||'; begin --act - execute the expectation - ut3.ut.expect( l_actual ).'||a_matcher_name||'(l_expected); + ut3_develop.ut.expect( l_actual ).'||a_matcher_name||'(l_expected); end;'; return l_execute; end; diff --git a/test/ut3_tester_helper/main_helper.pkb b/test/ut3_tester_helper/main_helper.pkb index c684054a1..5c3032b75 100644 --- a/test/ut3_tester_helper/main_helper.pkb +++ b/test/ut3_tester_helper/main_helper.pkb @@ -12,7 +12,7 @@ create or replace package body main_helper is end if; while l_status != 1 loop if l_line is not null then - ut3.ut_utils.append_to_clob(l_result, l_line||chr(10)); + ut3_develop.ut_utils.append_to_clob(l_result, l_line||chr(10)); end if; dbms_output.get_line(line => l_line, status => l_status); end loop; @@ -29,10 +29,10 @@ create or replace package body main_helper is end; function run_test(a_path varchar2) return clob is - l_lines ut3.ut_varchar2_list; + l_lines ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_lines from table(ut3.ut.run(a_path)); - return ut3.ut_utils.table_to_clob(l_lines); + select * bulk collect into l_lines from table(ut3_develop.ut.run(a_path)); + return ut3_develop.ut_utils.table_to_clob(l_lines); end; function get_value(a_variable varchar2) return integer is @@ -42,9 +42,9 @@ create or replace package body main_helper is return l_glob_val; end; - function get_failed_expectations return ut3.ut_varchar2_list is - l_expectations_result ut3.ut_expectation_results := ut3.ut_expectation_processor.get_failed_expectations(); - l_result ut3.ut_varchar2_list := ut3.ut_varchar2_list(); + function get_failed_expectations return ut3_develop.ut_varchar2_list is + l_expectations_result ut3_develop.ut_expectation_results := ut3_develop.ut_expectation_processor.get_failed_expectations(); + l_result ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list(); begin for i in 1..l_expectations_result.count loop l_result := l_result multiset union l_expectations_result(i).get_result_lines(); @@ -53,19 +53,19 @@ create or replace package body main_helper is end; function get_failed_expectations(a_pos in number) return varchar2 is - l_result varchar2(32767) := ut3.ut_expectation_processor.get_failed_expectations()(a_pos).message; + l_result varchar2(32767) := ut3_develop.ut_expectation_processor.get_failed_expectations()(a_pos).message; begin return l_result; end; function failed_expectations_data return anydata is begin - return anydata.convertCollection(ut3.ut_expectation_processor.get_failed_expectations()); + return anydata.convertCollection(ut3_develop.ut_expectation_processor.get_failed_expectations()); end; function get_failed_expectations_num return number is l_num_failed number; - l_results ut3.ut_expectation_results := ut3.ut_expectation_processor.get_failed_expectations(); + l_results ut3_develop.ut_expectation_results := ut3_develop.ut_expectation_processor.get_failed_expectations(); begin l_num_failed := l_results.count; return l_num_failed; @@ -73,33 +73,33 @@ create or replace package body main_helper is procedure clear_expectations is begin - ut3.ut_expectation_processor.clear_expectations(); + ut3_develop.ut_expectation_processor.clear_expectations(); end; - function table_to_clob(a_results in ut3.ut_varchar2_list) return clob is + function table_to_clob(a_results in ut3_develop.ut_varchar2_list) return clob is begin - return ut3.ut_utils.table_to_clob(a_results); + return ut3_develop.ut_utils.table_to_clob(a_results); end; - function get_warnings return ut3.ut_varchar2_rows is + function get_warnings return ut3_develop.ut_varchar2_rows is begin - return ut3.ut_expectation_processor.get_warnings(); + return ut3_develop.ut_expectation_processor.get_warnings(); end; procedure reset_nulls_equal is begin - ut3.ut_expectation_processor.nulls_Are_equal(ut3.ut_expectation_processor.gc_default_nulls_are_equal); + ut3_develop.ut_expectation_processor.nulls_Are_equal(ut3_develop.ut_expectation_processor.gc_default_nulls_are_equal); end; procedure nulls_are_equal(a_nulls_equal boolean := true) is begin - ut3.ut_expectation_processor.nulls_Are_equal(a_nulls_equal); + ut3_develop.ut_expectation_processor.nulls_Are_equal(a_nulls_equal); end; procedure cleanup_annotation_cache is pragma autonomous_transaction; begin - delete from ut3.ut_annotation_cache_info + delete from ut3_develop.ut_annotation_cache_info where object_owner = 'UT3_TESTER' and object_type = 'PACKAGE' and object_name in ('DUMMY_PACKAGE','DUMMY_TEST_PACKAGE'); commit; end; @@ -110,7 +110,7 @@ create or replace package body main_helper is execute immediate q'[ create or replace procedure ut3$user#.parse_annotations is begin - ut3.ut_runner.rebuild_annotation_cache('UT3_TESTER','PACKAGE'); + ut3_develop.ut_runner.rebuild_annotation_cache('UT3_TESTER','PACKAGE'); end;]'; end; @@ -134,34 +134,34 @@ create or replace package body main_helper is where srj.job_name = a_job_name; end; - procedure append_to_list(a_list in out nocopy ut3.ut_varchar2_list, a_item varchar2) is + procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_list, a_item varchar2) is begin - ut3.ut_utils.append_to_list(a_list,a_item); + ut3_develop.ut_utils.append_to_list(a_list,a_item); end; - procedure append_to_list(a_list in out nocopy ut3.ut_varchar2_rows, a_item varchar2) is + procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_rows, a_item varchar2) is begin - ut3.ut_utils.append_to_list(a_list,a_item); + ut3_develop.ut_utils.append_to_list(a_list,a_item); end; - procedure append_to_list(a_list in out nocopy ut3.ut_varchar2_rows, a_item clob) is + procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_rows, a_item clob) is begin - ut3.ut_utils.append_to_list(a_list,a_item); + ut3_develop.ut_utils.append_to_list(a_list,a_item); end; - procedure append_to_list(a_list in out nocopy ut3.ut_varchar2_rows, a_items ut3.ut_varchar2_rows) is + procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_rows, a_items ut3_develop.ut_varchar2_rows) is begin - ut3.ut_utils.append_to_list(a_list,a_items); + ut3_develop.ut_utils.append_to_list(a_list,a_items); end; procedure set_ut_run_context is begin - ut3.ut_session_context.set_context('RUN_PATHS',' '); + ut3_develop.ut_session_context.set_context('RUN_PATHS',' '); end; procedure clear_ut_run_context is begin - ut3.ut_session_context.clear_all_context; + ut3_develop.ut_session_context.clear_all_context; end; end; diff --git a/test/ut3_tester_helper/main_helper.pks b/test/ut3_tester_helper/main_helper.pks index 63c99936c..e675e267e 100644 --- a/test/ut3_tester_helper/main_helper.pks +++ b/test/ut3_tester_helper/main_helper.pks @@ -1,7 +1,7 @@ create or replace package main_helper is - gc_success number := ut3.ut_utils.gc_success; - gc_failure number := ut3.ut_utils.gc_failure; + gc_success number := ut3_develop.ut_utils.gc_success; + gc_failure number := ut3_develop.ut_utils.gc_failure; procedure execute_autonomous(a_sql varchar2); @@ -11,7 +11,7 @@ create or replace package main_helper is function get_dbms_output_as_clob return clob; - function get_failed_expectations return ut3.ut_varchar2_list; + function get_failed_expectations return ut3_develop.ut_varchar2_list; function get_failed_expectations(a_pos in number) return varchar2; @@ -19,9 +19,9 @@ create or replace package main_helper is procedure clear_expectations; - function table_to_clob(a_results in ut3.ut_varchar2_list) return clob; + function table_to_clob(a_results in ut3_develop.ut_varchar2_list) return clob; - function get_warnings return ut3.ut_varchar2_rows; + function get_warnings return ut3_develop.ut_varchar2_rows; procedure reset_nulls_equal; @@ -37,13 +37,13 @@ create or replace package main_helper is function get_job_count(a_job_name varchar2) return number; - procedure append_to_list(a_list in out nocopy ut3.ut_varchar2_list, a_item varchar2); + procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_list, a_item varchar2); - procedure append_to_list(a_list in out nocopy ut3.ut_varchar2_rows, a_item varchar2); + procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_rows, a_item varchar2); - procedure append_to_list(a_list in out nocopy ut3.ut_varchar2_rows, a_item clob); + procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_rows, a_item clob); - procedure append_to_list(a_list in out nocopy ut3.ut_varchar2_rows, a_items ut3.ut_varchar2_rows); + procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_rows, a_items ut3_develop.ut_varchar2_rows); procedure set_ut_run_context; diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index 70695977b..c2a50170e 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -141,15 +141,15 @@ create or replace package body run_helper is pragma autonomous_transaction; begin setup_cache_objects(); - ut3.ut_annotation_manager.rebuild_annotation_cache('UT3$USER#','PACKAGE'); - ut3.ut_annotation_manager.rebuild_annotation_cache('UT3$USER#','PROCEDURE'); - ut3.ut_annotation_manager.rebuild_annotation_cache('UT3_TESTER_HELPER','PROCEDURE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache('UT3$USER#','PACKAGE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache('UT3$USER#','PROCEDURE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache('UT3_TESTER_HELPER','PROCEDURE'); end; procedure cleanup_cache is pragma autonomous_transaction; begin - delete from ut3.ut_annotation_cache_info + delete from ut3_develop.ut_annotation_cache_info where object_type = 'PROCEDURE' and object_owner in ('UT3$USER#','UT3_TESTER_HELPER') or object_type = 'PACKAGE' and object_owner = user and object_name = 'DUMMY_TEST_PACKAGE'; execute immediate q'[drop package ut3$user#.dummy_test_package]'; @@ -199,7 +199,7 @@ create or replace package body run_helper is begin select 1 into a_value from dual@db_loopback; - ut3.ut.expect(a_value).to_be_null(); + ut3_develop.ut.expect(a_value).to_be_null(); end; end;]'; @@ -390,7 +390,7 @@ create or replace package body run_helper is procedure failing_stateful_test is begin - ut3.ut.expect(stateful_package.get_state@db_loopback).to_equal('abc'); + ut3_develop.ut.expect(stateful_package.get_state@db_loopback).to_equal('abc'); end; procedure rebuild_stateful_package is @@ -435,126 +435,126 @@ create or replace package body run_helper is execute immediate 'drop package ut_without_body'; end; - procedure run(a_reporter ut3.ut_reporter_base := null) is + procedure run(a_reporter ut3_develop.ut_reporter_base := null) is begin - ut3.ut.run(a_reporter); + ut3_develop.ut.run(a_reporter); end; - procedure run(a_path varchar2, a_reporter ut3.ut_reporter_base := null) is + procedure run(a_path varchar2, a_reporter ut3_develop.ut_reporter_base := null) is begin - ut3.ut.run(a_path, a_reporter); + ut3_develop.ut.run(a_path, a_reporter); end; - procedure run(a_paths ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base := null) is + procedure run(a_paths ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base := null) is begin - ut3.ut.run(a_paths, a_reporter); + ut3_develop.ut.run(a_paths, a_reporter); end; - procedure run(a_paths ut3.ut_varchar2_list, a_test_files ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base) is + procedure run(a_paths ut3_develop.ut_varchar2_list, a_test_files ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base) is begin - ut3.ut.run( + ut3_develop.ut.run( a_paths, a_reporter, - a_source_files => ut3.ut_varchar2_list(), + a_source_files => ut3_develop.ut_varchar2_list(), a_test_files => a_test_files ); end; - function run(a_reporter ut3.ut_reporter_base := null) return ut3.ut_varchar2_list is - l_results ut3.ut_varchar2_list; + function run(a_reporter ut3_develop.ut_reporter_base := null) return ut3_develop.ut_varchar2_list is + l_results ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_results from table (ut3.ut.run(a_reporter)); + select * bulk collect into l_results from table (ut3_develop.ut.run(a_reporter)); return l_results; end; - function run(a_paths ut3.ut_varchar2_list, a_test_files ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base) return ut3.ut_varchar2_list is - l_results ut3.ut_varchar2_list; + function run(a_paths ut3_develop.ut_varchar2_list, a_test_files ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base) return ut3_develop.ut_varchar2_list is + l_results ut3_develop.ut_varchar2_list; begin select * bulk collect into l_results from table ( - ut3.ut.run( + ut3_develop.ut.run( a_paths, - a_reporter, a_source_files => ut3.ut_varchar2_list(), + a_reporter, a_source_files => ut3_develop.ut_varchar2_list(), a_test_files => a_test_files )); return l_results; end; - function run(a_path varchar2, a_reporter ut3.ut_reporter_base := null) - return ut3.ut_varchar2_list is - l_results ut3.ut_varchar2_list; + function run(a_path varchar2, a_reporter ut3_develop.ut_reporter_base := null) + return ut3_develop.ut_varchar2_list is + l_results ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_results from table (ut3.ut.run(a_path, a_reporter)); + select * bulk collect into l_results from table (ut3_develop.ut.run(a_path, a_reporter)); return l_results; end; - function run(a_paths ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base := null) - return ut3.ut_varchar2_list is - l_results ut3.ut_varchar2_list; + function run(a_paths ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base := null) + return ut3_develop.ut_varchar2_list is + l_results ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_results from table (ut3.ut.run(a_paths, a_reporter)); + select * bulk collect into l_results from table (ut3_develop.ut.run(a_paths, a_reporter)); return l_results; end; - function run(a_test_files ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base) - return ut3.ut_varchar2_list is - l_results ut3.ut_varchar2_list; + function run(a_test_files ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base) + return ut3_develop.ut_varchar2_list is + l_results ut3_develop.ut_varchar2_list; begin select * bulk collect into l_results from table ( - ut3.ut.run( - a_reporter, a_source_files => ut3.ut_varchar2_list(), + ut3_develop.ut.run( + a_reporter, a_source_files => ut3_develop.ut_varchar2_list(), a_test_files => a_test_files )); return l_results; end; - procedure run(a_reporter ut3.ut_reporter_base := null,a_tags varchar2) is + procedure run(a_reporter ut3_develop.ut_reporter_base := null,a_tags varchar2) is begin - ut3.ut.run(a_reporter,a_tags => a_tags); + ut3_develop.ut.run(a_reporter,a_tags => a_tags); end; - procedure run(a_path varchar2, a_reporter ut3.ut_reporter_base := null,a_tags varchar2) is + procedure run(a_path varchar2, a_reporter ut3_develop.ut_reporter_base := null,a_tags varchar2) is begin - ut3.ut.run(a_path, a_reporter,a_tags => a_tags); + ut3_develop.ut.run(a_path, a_reporter,a_tags => a_tags); end; - procedure run(a_paths ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base := null, a_tags varchar2) is + procedure run(a_paths ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base := null, a_tags varchar2) is begin - ut3.ut.run(a_paths, a_reporter,a_tags => a_tags); + ut3_develop.ut.run(a_paths, a_reporter,a_tags => a_tags); end; - function run(a_reporter ut3.ut_reporter_base := null,a_tags varchar2) return ut3.ut_varchar2_list is - l_results ut3.ut_varchar2_list; + function run(a_reporter ut3_develop.ut_reporter_base := null,a_tags varchar2) return ut3_develop.ut_varchar2_list is + l_results ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_results from table (ut3.ut.run(a_reporter, a_tags => a_tags)); + select * bulk collect into l_results from table (ut3_develop.ut.run(a_reporter, a_tags => a_tags)); return l_results; end; - function run(a_path varchar2, a_reporter ut3.ut_reporter_base := null, a_tags varchar2) - return ut3.ut_varchar2_list is - l_results ut3.ut_varchar2_list; + function run(a_path varchar2, a_reporter ut3_develop.ut_reporter_base := null, a_tags varchar2) + return ut3_develop.ut_varchar2_list is + l_results ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_results from table (ut3.ut.run(a_path, a_reporter,a_tags => a_tags)); + select * bulk collect into l_results from table (ut3_develop.ut.run(a_path, a_reporter,a_tags => a_tags)); return l_results; end; - function run(a_paths ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base := null, a_tags varchar2) - return ut3.ut_varchar2_list is - l_results ut3.ut_varchar2_list; + function run(a_paths ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base := null, a_tags varchar2) + return ut3_develop.ut_varchar2_list is + l_results ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_results from table (ut3.ut.run(a_paths, a_reporter, a_tags => a_tags)); + select * bulk collect into l_results from table (ut3_develop.ut.run(a_paths, a_reporter, a_tags => a_tags)); return l_results; end; - procedure test_rollback_type(a_procedure_name varchar2, a_rollback_type integer, a_expectation ut3_latest_release.ut_matcher) is - l_suite ut3.ut_suite; + procedure test_rollback_type(a_procedure_name varchar2, a_rollback_type integer, a_expectation ut_matcher) is + l_suite ut3_develop.ut_suite; begin --Arrange execute immediate 'delete from ut$test_table'; - l_suite := ut3.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_TRANSACTION_CONTROL', a_line_no=> 1); + l_suite := ut3_develop.ut_suite(a_object_owner => 'ut3_tester_helper', a_object_name => 'UT_TRANSACTION_CONTROL', a_line_no=> 1); l_suite.path := 'ut_transaction_control'; - l_suite.before_all_list := ut3.ut_executables(ut3.ut_executable('ut3_tester_helper', 'UT_TRANSACTION_CONTROL', 'setup', ut3.ut_utils.gc_before_all)); + l_suite.before_all_list := ut3_develop.ut_executables(ut3_develop.ut_executable('ut3_tester_helper', 'UT_TRANSACTION_CONTROL', 'setup', ut3_develop.ut_utils.gc_before_all)); l_suite.items.extend; - l_suite.items(l_suite.items.last) := ut3.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_transaction_control',a_name => a_procedure_name, a_line_no=> 1); + l_suite.items(l_suite.items.last) := ut3_develop.ut_test(a_object_owner => 'ut3_tester_helper', a_object_name => 'ut_transaction_control',a_name => a_procedure_name, a_line_no=> 1); l_suite.set_rollback_type(a_rollback_type); --Act @@ -568,7 +568,7 @@ create or replace package body run_helper is procedure create_dummy_long_test_package is pragma autonomous_transaction; begin - execute immediate q'[create or replace package ut3.dummy_long_test_package as + execute immediate q'[create or replace package ut3_develop.dummy_long_test_package as --%suitepath(verylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtext) --%suite(dummy_test_suite) @@ -577,7 +577,7 @@ create or replace package body run_helper is procedure some_dummy_test_procedure; end;]'; - execute immediate q'[create or replace package ut3.dummy_long_test_package1 as + execute immediate q'[create or replace package ut3_develop.dummy_long_test_package1 as --%suitepath(verylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtext) --%suite(dummy_test_suite1) @@ -590,15 +590,15 @@ create or replace package body run_helper is procedure drop_dummy_long_test_package is pragma autonomous_transaction; begin - execute immediate q'[drop package ut3.dummy_long_test_package]'; - execute immediate q'[drop package ut3.dummy_long_test_package1]'; + execute immediate q'[drop package ut3_develop.dummy_long_test_package]'; + execute immediate q'[drop package ut3_develop.dummy_long_test_package1]'; end; procedure create_ut3_suite is pragma autonomous_transaction; begin execute immediate q'[ - create or replace package ut3.some_test_package + create or replace package ut3_develop.some_test_package as --%suite @@ -611,18 +611,18 @@ create or replace package body run_helper is procedure drop_ut3_suite is pragma autonomous_transaction; begin - execute immediate q'[drop package ut3.some_test_package]'; + execute immediate q'[drop package ut3_develop.some_test_package]'; end; - function get_schema_ut_packages(a_owner in varchar2) return ut3.ut_object_names is + function get_schema_ut_packages(a_owner in varchar2) return ut3_develop.ut_object_names is begin - return ut3.ut_suite_manager.get_schema_ut_packages(ut3.ut_varchar2_rows(a_owner)); + return ut3_develop.ut_suite_manager.get_schema_ut_packages(ut3_develop.ut_varchar2_rows(a_owner)); end; function ut_output_buffer_tmp return t_out_buff_tab pipelined is l_buffer_tab t_out_buff_tab; cursor get_buffer is - select * from ut3.ut_output_buffer_tmp; + select * from ut3_develop.ut_output_buffer_tmp; begin open get_buffer; fetch get_buffer bulk collect into l_buffer_tab; @@ -633,7 +633,7 @@ create or replace package body run_helper is procedure delete_buffer is begin - delete from ut3.ut_output_buffer_tmp; + delete from ut3_develop.ut_output_buffer_tmp; end; function get_annotation_cache_info_cur( @@ -643,7 +643,7 @@ create or replace package body run_helper is l_result sys_refcursor; begin open l_result for - select * from ut3.ut_annotation_cache_info + select * from ut3_develop.ut_annotation_cache_info where object_owner = a_owner and object_type = a_type; return l_result; @@ -658,8 +658,8 @@ create or replace package body run_helper is begin open l_result for select * - from ut3.ut_annotation_cache_info i - join ut3.ut_annotation_cache c on c.cache_id = i.cache_id + from ut3_develop.ut_annotation_cache_info i + join ut3_develop.ut_annotation_cache c on c.cache_id = i.cache_id where object_owner = a_owner and object_type = a_type and object_name = nvl( a_name, object_name ); return l_result; diff --git a/test/ut3_tester_helper/run_helper.pks b/test/ut3_tester_helper/run_helper.pks index 03eb314a7..88f55d961 100644 --- a/test/ut3_tester_helper/run_helper.pks +++ b/test/ut3_tester_helper/run_helper.pks @@ -2,8 +2,8 @@ create or replace package run_helper is g_run_id integer; - type t_out_buff_tab is table of ut3.ut_output_buffer_tmp%rowtype; - type prof_runs_tab is table of ut3.plsql_profiler_runs%rowtype; + type t_out_buff_tab is table of ut3_develop.ut_output_buffer_tmp%rowtype; + type prof_runs_tab is table of ut3_develop.plsql_profiler_runs%rowtype; procedure setup_cache_objects; procedure setup_cache_objectstag; @@ -29,37 +29,37 @@ create or replace package run_helper is procedure create_trans_control; procedure drop_trans_control; - procedure run(a_reporter ut3.ut_reporter_base := null); - procedure run(a_path varchar2, a_reporter ut3.ut_reporter_base := null); - procedure run(a_paths ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base := null); - procedure run(a_paths ut3.ut_varchar2_list, a_test_files ut3.ut_varchar2_list, - a_reporter ut3.ut_reporter_base); - function run(a_reporter ut3.ut_reporter_base := null) return ut3.ut_varchar2_list; - function run(a_paths ut3.ut_varchar2_list, a_test_files ut3.ut_varchar2_list, - a_reporter ut3.ut_reporter_base) return ut3.ut_varchar2_list; - function run(a_path varchar2, a_reporter ut3.ut_reporter_base := null) - return ut3.ut_varchar2_list; - function run(a_paths ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base := null) - return ut3.ut_varchar2_list; - function run(a_test_files ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base) - return ut3.ut_varchar2_list; + procedure run(a_reporter ut3_develop.ut_reporter_base := null); + procedure run(a_path varchar2, a_reporter ut3_develop.ut_reporter_base := null); + procedure run(a_paths ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base := null); + procedure run(a_paths ut3_develop.ut_varchar2_list, a_test_files ut3_develop.ut_varchar2_list, + a_reporter ut3_develop.ut_reporter_base); + function run(a_reporter ut3_develop.ut_reporter_base := null) return ut3_develop.ut_varchar2_list; + function run(a_paths ut3_develop.ut_varchar2_list, a_test_files ut3_develop.ut_varchar2_list, + a_reporter ut3_develop.ut_reporter_base) return ut3_develop.ut_varchar2_list; + function run(a_path varchar2, a_reporter ut3_develop.ut_reporter_base := null) + return ut3_develop.ut_varchar2_list; + function run(a_paths ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base := null) + return ut3_develop.ut_varchar2_list; + function run(a_test_files ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base) + return ut3_develop.ut_varchar2_list; - procedure run(a_reporter ut3.ut_reporter_base := null,a_tags varchar2); - procedure run(a_path varchar2, a_reporter ut3.ut_reporter_base := null,a_tags varchar2); - procedure run(a_paths ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base := null, a_tags varchar2); - function run(a_reporter ut3.ut_reporter_base := null,a_tags varchar2) return ut3.ut_varchar2_list; - function run(a_path varchar2, a_reporter ut3.ut_reporter_base := null, a_tags varchar2) - return ut3.ut_varchar2_list; - function run(a_paths ut3.ut_varchar2_list, a_reporter ut3.ut_reporter_base := null, a_tags varchar2) - return ut3.ut_varchar2_list; + procedure run(a_reporter ut3_develop.ut_reporter_base := null,a_tags varchar2); + procedure run(a_path varchar2, a_reporter ut3_develop.ut_reporter_base := null,a_tags varchar2); + procedure run(a_paths ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base := null, a_tags varchar2); + function run(a_reporter ut3_develop.ut_reporter_base := null,a_tags varchar2) return ut3_develop.ut_varchar2_list; + function run(a_path varchar2, a_reporter ut3_develop.ut_reporter_base := null, a_tags varchar2) + return ut3_develop.ut_varchar2_list; + function run(a_paths ut3_develop.ut_varchar2_list, a_reporter ut3_develop.ut_reporter_base := null, a_tags varchar2) + return ut3_develop.ut_varchar2_list; - procedure test_rollback_type(a_procedure_name varchar2, a_rollback_type integer, a_expectation ut3_latest_release.ut_matcher); + procedure test_rollback_type(a_procedure_name varchar2, a_rollback_type integer, a_expectation ut_matcher); procedure create_dummy_long_test_package; procedure drop_dummy_long_test_package; procedure create_ut3_suite; procedure drop_ut3_suite; - function get_schema_ut_packages(a_owner in varchar2) return ut3.ut_object_names; + function get_schema_ut_packages(a_owner in varchar2) return ut3_develop.ut_object_names; function ut_output_buffer_tmp return t_out_buff_tab pipelined; procedure delete_buffer; diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index feac3fe6e..8aed1d36e 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -24,13 +24,13 @@ create or replace package body test_ut_run is procedure ut_version is begin - ut.expect(ut3.ut.version()).to_match('^v\d+\.\d+\.\d+\.\d+(-\w+)?$'); + ut.expect(ut3_develop.ut.version()).to_match('^v\d+\.\d+\.\d+\.\d+(-\w+)?$'); end; procedure ut_fail is begin --Act - ut3.ut.fail('Testing failure message'); + ut3_develop.ut.fail('Testing failure message'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations(1)) .to_be_like('%Testing failure message%'); @@ -49,7 +49,7 @@ create or replace package body test_ut_run is l_results clob; begin --Act - ut3.ut.run('ut3_tester_helper',a_reporter => ut3.ut_documentation_reporter() ); + ut3_develop.ut.run('ut3_tester_helper',a_reporter => ut3_develop.ut_documentation_reporter() ); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert ut.expect( l_results ).to_be_like( '%test_package_1%test_package_2%test_package_3%' ); @@ -59,11 +59,11 @@ create or replace package body test_ut_run is l_results clob; begin --Act - ut3.ut.run( + ut3_develop.ut.run( 'ut3_tester_helper', - a_reporter => ut3.ut_sonar_test_reporter(), - a_source_files => ut3.ut_varchar2_list(), - a_test_files => ut3.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', + a_reporter => ut3_develop.ut_sonar_test_reporter(), + a_source_files => ut3_develop.ut_varchar2_list(), + a_test_files => ut3_develop.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', 'tests/ut3_tester_helper.test_package_2.pkb', 'tests/ut3_tester_helper.test_package_3.pkb') ); @@ -78,7 +78,7 @@ create or replace package body test_ut_run is procedure run_proc_pkg_name is l_results clob; begin - ut3.ut.run('ut3_tester_helper.test_package_1'); + ut3_develop.ut.run('ut3_tester_helper.test_package_1'); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert ut.expect( l_results ).to_be_like( '%test_package_1%' ); @@ -89,10 +89,10 @@ create or replace package body test_ut_run is procedure run_proc_pkg_name_file_list is l_results clob; begin - ut3.ut.run( + ut3_develop.ut.run( 'ut3_tester_helper.test_package_3', - ut3.ut_sonar_test_reporter(), a_source_files => ut3.ut_varchar2_list(), - a_test_files => ut3.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', + ut3_develop.ut_sonar_test_reporter(), a_source_files => ut3_develop.ut_varchar2_list(), + a_test_files => ut3_develop.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', 'tests/ut3_tester_helper.test_package_2.pkb', 'tests/ut3_tester_helper.test_package_3.pkb') ); @@ -106,7 +106,7 @@ create or replace package body test_ut_run is procedure run_proc_path_list is l_results clob; begin - ut3_tester_helper.run_helper.run(ut3.ut_varchar2_list(':tests.test_package_1',':tests')); + ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests')); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert ut.expect( l_results ).to_be_like( '%test_package_1%' ); @@ -118,9 +118,9 @@ create or replace package body test_ut_run is l_results clob; begin ut3_tester_helper.run_helper.run( - a_paths => ut3.ut_varchar2_list(':tests.test_package_1',':tests'), - a_reporter => ut3.ut_sonar_test_reporter(), - a_test_files => ut3.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', + a_paths => ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests'), + a_reporter => ut3_develop.ut_sonar_test_reporter(), + a_test_files => ut3_develop.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', 'tests/ut3_tester_helper.test_package_2.pkb', 'tests/ut3_tester_helper.test_package_3.pkb') ); @@ -135,7 +135,7 @@ create or replace package body test_ut_run is l_results clob; begin --Act - ut3.ut.run('ut3_tester_helper', cast(null as ut3.ut_reporter_base)); + ut3_develop.ut.run('ut3_tester_helper', cast(null as ut3_develop.ut_reporter_base)); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert ut.expect( l_results ).to_be_like( '%tests%test_package_1%test_package_2%tests2%test_package_3%' ); @@ -153,7 +153,7 @@ create or replace package body test_ut_run is procedure run_proc_null_path_list is l_results clob; - l_paths ut3.ut_varchar2_list; + l_paths ut3_develop.ut_varchar2_list; begin --Act ut3_tester_helper.run_helper.run(l_paths); @@ -166,7 +166,7 @@ create or replace package body test_ut_run is l_results clob; begin --Act - ut3_tester_helper.run_helper.run(ut3.ut_varchar2_list()); + ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list()); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert ut.expect( l_results ).to_be_like( '%test_package_1%test_package_2%test_package_3%' ); @@ -185,7 +185,7 @@ create or replace package body test_ut_run is execute immediate 'create or replace package body test_commit_warning is procedure does_commit is begin - ut3.ut.expect(1).to_equal(1); + ut3_develop.ut.expect(1).to_equal(1); commit; end; end;'; @@ -200,7 +200,7 @@ create or replace package body test_ut_run is procedure run_proc_warn_on_commit is l_results clob; begin - ut3.ut.run('test_commit_warning'); + ut3_develop.ut.run('test_commit_warning'); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); ut.expect(l_results).to_be_like( '%Unable to perform automatic rollback after test%'|| @@ -236,7 +236,7 @@ create or replace package body test_ut_run is execute immediate 'create or replace package body child_suite is procedure does_stuff is begin - ut3.ut.expect(1).to_equal(1); + ut3_develop.ut.expect(1).to_equal(1); end; end;'; end; @@ -251,7 +251,7 @@ create or replace package body test_ut_run is procedure run_proc_fail_child_suites is l_results clob; begin - ut3.ut.run('child_suite'); + ut3_develop.ut.run('child_suite'); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); ut.expect(l_results).to_be_like( '%1) does_stuff%' || @@ -314,7 +314,7 @@ create or replace package body test_ut_run is insert into transaction_test_table values (''1 - inside the test_ut_run.run_proc_keep_test_changes test'')'; --Act - ut3.ut.run('test_transaction.insert_row', a_force_manual_rollback => true); + ut3_develop.ut.run('test_transaction.insert_row', a_force_manual_rollback => true); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert @@ -339,7 +339,7 @@ create or replace package body test_ut_run is insert into transaction_test_table values (''1 - inside the test_ut_run.run_proc_keep_test_changes test'')'; --Act - ut3.ut.run('test_transaction.insert_and_raise', a_force_manual_rollback => true); + ut3_develop.ut.run('test_transaction.insert_and_raise', a_force_manual_rollback => true); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert @@ -364,7 +364,7 @@ create or replace package body test_ut_run is insert into transaction_test_table values (''1 - inside the test_ut_run.run_proc_keep_test_changes test'')'; --Act - ut3.ut.run('test_transaction.insert_row'); + ut3_develop.ut.run('test_transaction.insert_row'); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert @@ -377,7 +377,7 @@ create or replace package body test_ut_run is end; procedure run_func_no_params is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin l_results := ut3_tester_helper.run_helper.run(); --Assert @@ -385,23 +385,23 @@ create or replace package body test_ut_run is end; procedure run_func_specific_reporter is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Act - l_results := ut3_tester_helper.run_helper.run(ut3.ut_documentation_reporter()); + l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_documentation_reporter()); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%test_package_2%test_package_3%' ); end; procedure run_func_cov_file_list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Act select * bulk collect into l_results from table ( - ut3.ut.run('ut3_tester_helper', - ut3.ut_sonar_test_reporter(), - a_source_files => ut3.ut_varchar2_list(), - a_test_files => ut3.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', + ut3_develop.ut.run('ut3_tester_helper', + ut3_develop.ut_sonar_test_reporter(), + a_source_files => ut3_develop.ut_varchar2_list(), + a_test_files => ut3_develop.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', 'tests/ut3_tester_helper.test_package_2.pkb', 'tests/ut3_tester_helper.test_package_3.pkb') )); @@ -410,9 +410,9 @@ create or replace package body test_ut_run is end; procedure run_func_pkg_name is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_results from table (ut3.ut.run('ut3_tester_helper.test_package_1')); + select * bulk collect into l_results from table (ut3_develop.ut.run('ut3_tester_helper.test_package_1')); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2%' ); @@ -420,13 +420,13 @@ create or replace package body test_ut_run is end; procedure run_func_pkg_name_file_list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin select * bulk collect into l_results from table ( - ut3.ut.run('ut3_tester_helper.test_package_3', - ut3.ut_sonar_test_reporter(), - a_source_files => ut3.ut_varchar2_list(), - a_test_files => ut3.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', + ut3_develop.ut.run('ut3_tester_helper.test_package_3', + ut3_develop.ut_sonar_test_reporter(), + a_source_files => ut3_develop.ut_varchar2_list(), + a_test_files => ut3_develop.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', 'tests/ut3_tester_helper.test_package_2.pkb', 'tests/ut3_tester_helper.test_package_3.pkb') )); @@ -437,9 +437,9 @@ create or replace package body test_ut_run is end; procedure run_func_path_list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin - l_results := ut3_tester_helper.run_helper.run(ut3.ut_varchar2_list(':tests.test_package_1',':tests')); + l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests')); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2%' ); @@ -447,12 +447,12 @@ create or replace package body test_ut_run is end; procedure run_func_path_list_file_list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin l_results := ut3_tester_helper.run_helper.run( - a_paths => ut3.ut_varchar2_list(':tests.test_package_1',':tests'), - a_reporter => ut3.ut_sonar_test_reporter(), - a_test_files => ut3.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', + a_paths => ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests'), + a_reporter => ut3_develop.ut_sonar_test_reporter(), + a_test_files => ut3_develop.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', 'tests/ut3_tester_helper.test_package_2.pkb', 'tests/ut3_tester_helper.test_package_3.pkb') ); @@ -463,16 +463,16 @@ create or replace package body test_ut_run is end; procedure run_func_null_reporter is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Act - select * bulk collect into l_results from table (ut3.ut.run('ut3_tester_helper',cast(null as ut3.ut_reporter_base))); + select * bulk collect into l_results from table (ut3_develop.ut.run('ut3_tester_helper',cast(null as ut3_develop.ut_reporter_base))); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%tests%test_package_1%test_package_2%tests2%test_package_3%' ); end; procedure run_func_null_path is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Act l_results := ut3_tester_helper.run_helper.run(cast(null as varchar2)); @@ -481,8 +481,8 @@ create or replace package body test_ut_run is end; procedure run_func_null_path_list is - l_results ut3.ut_varchar2_list; - l_paths ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; + l_paths ut3_develop.ut_varchar2_list; begin --Act l_results := ut3_tester_helper.run_helper.run(l_paths); @@ -491,29 +491,29 @@ create or replace package body test_ut_run is end; procedure run_func_empty_path_list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Act - l_results := ut3_tester_helper.run_helper.run(ut3.ut_varchar2_list()); + l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list()); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%test_package_2%test_package_3%' ); end; procedure run_func_cov_file_lst_null_rep is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Act l_results := ut3_tester_helper.run_helper.run( - a_test_files => ut3.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', + a_test_files => ut3_develop.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', 'tests/ut3_tester_helper.test_package_2.pkb', 'tests/ut3_tester_helper.test_package_3.pkb'), - a_reporter => cast(null as ut3.ut_reporter_base)); + a_reporter => cast(null as ut3_develop.ut_reporter_base)); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%test_package_2%test_package_3%' ); end; procedure run_func_empty_suite is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected varchar2(32767); pragma autonomous_transaction; begin @@ -528,7 +528,7 @@ create or replace package body test_ut_run is end;]'; l_expected := '%empty_suite%0 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s)%'; --Act - select * bulk collect into l_results from table(ut3.ut.run('empty_suite')); + select * bulk collect into l_results from table(ut3_develop.ut.run('empty_suite')); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( l_expected ); @@ -538,7 +538,7 @@ create or replace package body test_ut_run is end; procedure raise_in_invalid_state is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin --Arrange @@ -554,7 +554,7 @@ Failures:% 1 tests, 0 failed, 1 errored, 0 disabled, 0 warning(s)%'; --Act - select * bulk collect into l_results from table(ut3.ut.run('ut3_tester_helper.test_stateful')); + select * bulk collect into l_results from table(ut3_develop.ut.run('ut3_tester_helper.test_stateful')); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( l_expected ); @@ -576,11 +576,11 @@ Failures:% end; procedure run_in_invalid_state is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; l_expected varchar2(32767); begin - select * bulk collect into l_results from table(ut3.ut.run('failing_invalid_spec')); + select * bulk collect into l_results from table(ut3_develop.ut.run('failing_invalid_spec')); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like('%Call params for % are not valid: package %FAILING_INVALID_SPEC% does not exist or is invalid.%'); @@ -618,7 +618,7 @@ Failures:% end; procedure run_and_revalidate_specs is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; l_is_invalid number; begin @@ -626,7 +626,7 @@ Failures:% and o.status = 'INVALID' and o.object_name= :object_name]' into l_is_invalid using 'UT3$USER#','INVALID_PCKAG_THAT_REVALIDATES'; - select * bulk collect into l_results from table(ut3.ut.run('invalid_pckag_that_revalidates')); + select * bulk collect into l_results from table(ut3_develop.ut.run('invalid_pckag_that_revalidates')); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(1).to_equal(l_is_invalid); @@ -681,11 +681,11 @@ Failures:% end; procedure run_and_report_warnings is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin - select * bulk collect into l_results from table(ut3.ut.run('bad_annotations')); + select * bulk collect into l_results from table(ut3_develop.ut.run('bad_annotations')); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like('%Missing "--%endcontext" annotation for a "--%context" annotation. The end of package is considered end of context.% @@ -733,12 +733,12 @@ Failures:% procedure savepoints_on_db_links is l_results clob; begin - ut3.ut.run('ut3_tester_helper.test_distributed_savepoint'); + ut3_develop.ut.run('ut3_tester_helper.test_distributed_savepoint'); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); ut.expect(l_results).to_be_like('%1 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s)%'); end; - procedure remove_time_from_results(a_results in out nocopy ut3.ut_varchar2_list) is + procedure remove_time_from_results(a_results in out nocopy ut3_develop.ut_varchar2_list) is begin for i in 1 .. a_results.count loop a_results(i) := regexp_replace(a_results(i),'\[[0-9]*[\.,][0-9]+ sec\]',''); @@ -747,11 +747,11 @@ Failures:% end; procedure run_schema_name_test is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected clob; begin select * bulk collect into l_results - from table ( ut3.ut.run( gc_owner||'.'||gc_owner ) ); + from table ( ut3_develop.ut.run( gc_owner||'.'||gc_owner ) ); l_expected := '%1 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s)%'; ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( l_expected ); end; @@ -781,16 +781,16 @@ Failures:% end; procedure run_with_random_order is - l_random_results ut3.ut_varchar2_list; - l_results ut3.ut_varchar2_list; + l_random_results ut3_develop.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin select * bulk collect into l_random_results - from table ( ut3.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 3 ) ) + from table ( ut3_develop.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 3 ) ) where trim(column_value) is not null and column_value not like 'Finished in %' and column_value not like '%Tests were executed with random order %'; select * bulk collect into l_results - from table ( ut3.ut.run( 'ut3_tester_helper.test_package_1' ) ) + from table ( ut3_develop.ut.run( 'ut3_tester_helper.test_package_1' ) ) --TODO this condition should be removed once issues with unordered compare and 'blank text rows' are resolved. where trim(column_value) is not null and column_value not like 'Finished in %'; @@ -802,23 +802,23 @@ Failures:% end; procedure run_and_report_random_ord_seed is - l_actual ut3.ut_varchar2_list; + l_actual ut3_develop.ut_varchar2_list; begin select * bulk collect into l_actual - from table ( ut3.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 123456789 ) ); + from table ( ut3_develop.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 123456789 ) ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_actual) ).to_be_like( q'[%Tests were executed with random order seed '123456789'.%]' ); end; procedure run_with_random_order_seed is - l_expected ut3.ut_varchar2_list; - l_actual ut3.ut_varchar2_list; + l_expected ut3_develop.ut_varchar2_list; + l_actual ut3_develop.ut_varchar2_list; begin select * bulk collect into l_expected - from table ( ut3.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 3 ) ); + from table ( ut3_develop.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 3 ) ); select * bulk collect into l_actual - from table ( ut3.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 3 ) ); + from table ( ut3_develop.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 3 ) ); remove_time_from_results(l_actual); remove_time_from_results(l_expected); @@ -948,7 +948,7 @@ Failures:% procedure run_proc_pkg_name_tag is l_results clob; begin - ut3.ut.run('ut3_tester_helper.test_package_1',a_tags => 'suite1test1'); + ut3_develop.ut.run('ut3_tester_helper.test_package_1',a_tags => 'suite1test1'); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert ut.expect( l_results ).to_be_like( '%test_package_1%' ); @@ -961,7 +961,7 @@ Failures:% procedure run_pkg_name_file_list_tag is l_results clob; begin - ut3.ut.run('ut3_tester_helper.test_package_1',a_tags => 'suite1test1'); + ut3_develop.ut.run('ut3_tester_helper.test_package_1',a_tags => 'suite1test1'); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert ut.expect( l_results ).to_be_like( '%test_package_1%' ); @@ -974,10 +974,10 @@ Failures:% procedure run_proc_path_list_tag is l_results clob; begin - ut3.ut.run( + ut3_develop.ut.run( 'ut3_tester_helper.test_package_1', - ut3.ut_sonar_test_reporter(), a_source_files => ut3.ut_varchar2_list(),a_tags => 'suite1', - a_test_files => ut3.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', + ut3_develop.ut_sonar_test_reporter(), a_source_files => ut3_develop.ut_varchar2_list(),a_tags => 'suite1', + a_test_files => ut3_develop.ut_varchar2_list('tests/ut3_tester_helper.test_package_1.pkb', 'tests/ut3_tester_helper.test_package_2.pkb', 'tests/ut3_tester_helper.test_package_3.pkb') ); @@ -989,7 +989,7 @@ Failures:% end; procedure tag_run_func_no_params is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin l_results := ut3_tester_helper.run_helper.run(a_tags => 'helper'); --Assert @@ -997,9 +997,9 @@ Failures:% end; procedure tag_run_func_pkg_name is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_results from table (ut3.ut.run('ut3_tester_helper.test_package_1', a_tags => 'suite1test1')); + select * bulk collect into l_results from table (ut3_develop.ut.run('ut3_tester_helper.test_package_1', a_tags => 'suite1test1')); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1.test1%executed%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); @@ -1008,9 +1008,9 @@ Failures:% end; procedure tag_run_func_path_list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin - l_results := ut3_tester_helper.run_helper.run(ut3.ut_varchar2_list(':tests.test_package_1',':tests'),a_tags => 'suite1test1,suite2test1'); + l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests'),a_tags => 'suite1test1,suite2test1'); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2%' ); @@ -1022,9 +1022,9 @@ Failures:% end; procedure tag_inc_exc_run_func_path_list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin - l_results := ut3_tester_helper.run_helper.run(ut3.ut_varchar2_list(':tests.test_package_1',':tests'),a_tags => 'suite1test1,suite2test1,-suite2'); + l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests'),a_tags => 'suite1test1,suite2test1,-suite2'); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2%' ); @@ -1034,9 +1034,9 @@ Failures:% end; procedure tag_exclude_run_func_path_list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin - l_results := ut3_tester_helper.run_helper.run(ut3.ut_varchar2_list(':tests,:tests2'),a_tags => '-suite1test2,-suite2test1,-test1suite3'); + l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests,:tests2'),a_tags => '-suite1test2,-suite2test1,-test1suite3'); --Assert ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2%' ); @@ -1050,7 +1050,7 @@ Failures:% end; procedure tag_include_exclude_run_func is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin l_results := ut3_tester_helper.run_helper.run(a_tags => 'suite1,-suite1test2,-suite2test1,-test1suite3'); --Assert @@ -1188,9 +1188,9 @@ Failures:% end; procedure run_context_test_suite is - l_lines ut3.ut_varchar2_list; + l_lines ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_lines from table(ut3.ut.run('check_context')); + select * bulk collect into l_lines from table(ut3_develop.ut.run('check_context')); g_context_test_results := ut3_tester_helper.main_helper.table_to_clob(l_lines); end; diff --git a/test/ut3_user/api/test_ut_runner.pkb b/test/ut3_user/api/test_ut_runner.pkb index e29bada11..2aa624ed8 100644 --- a/test/ut3_user/api/test_ut_runner.pkb +++ b/test/ut3_user/api/test_ut_runner.pkb @@ -45,7 +45,7 @@ end; execute immediate 'create or replace package body test_cache as procedure failing_test is begin - ut3.ut.expect('||a_number||').to_be_null; + ut3_develop.ut.expect('||a_number||').to_be_null; end; end;'; end; @@ -69,7 +69,7 @@ end;'; create_test_body(0); l_expected := dbms_transaction.local_transaction_id(true); --Act - ut3.ut.run('test_cache'); + ut3_develop.ut.run('test_cache'); dbms_output.get_lines( l_output_data, l_num_lines); --Assert ut.expect(dbms_transaction.local_transaction_id()).to_equal(l_expected); @@ -86,7 +86,7 @@ end;'; create_test_body(0); rollback; --Act - ut3.ut.run('test_cache'); + ut3_develop.ut.run('test_cache'); dbms_output.get_lines( l_output_data, l_num_lines); --Assert ut.expect(dbms_transaction.local_transaction_id()).to_be_null(); @@ -95,35 +95,35 @@ end;'; procedure version_comp_check_compare is begin - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0.0','v3.0.0.0') ).to_equal(1); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0.0','v3.0.123.0') ).to_equal(1); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0.0','v3.123.0.0') ).to_equal(1); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0.0','v3.13.31.0') ).to_equal(1); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.1.0','v3.0.0.0') ).to_equal(0); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.1.0.0','v3.0.0.0') ).to_equal(0); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0.0','v2.0.0.0') ).to_equal(0); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0.0','v4.0.0.0') ).to_equal(0); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0.0','v3.0.0.0') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0.0','v3.0.123.0') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0.0','v3.123.0.0') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0.0','v3.13.31.0') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.1.0','v3.0.0.0') ).to_equal(0); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.1.0.0','v3.0.0.0') ).to_equal(0); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0.0','v2.0.0.0') ).to_equal(0); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0.0','v4.0.0.0') ).to_equal(0); end; procedure version_comp_check_ignore is begin - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0.123','v3.0.0.0') ).to_equal(1); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0.0','v3.0.0.123') ).to_equal(1); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0','v3.0.0.0') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0.123','v3.0.0.0') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0.0','v3.0.0.123') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0','v3.0.0.0') ).to_equal(1); end; procedure version_comp_check_short is begin - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0.0','v3.0.0.0') ).to_equal(1); - ut.expect( ut3.ut_runner.version_compatibility_check('v3.0','v3.0.123.0') ).to_equal(1); - ut.expect( ut3.ut_runner.version_compatibility_check('v3','v3.123.0.0') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0.0','v3.0.0.0') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3.0','v3.0.123.0') ).to_equal(1); + ut.expect( ut3_develop.ut_runner.version_compatibility_check('v3','v3.123.0.0') ).to_equal(1); end; procedure version_comp_check_exception is procedure throws(a_requested varchar2, a_current varchar2) is l_compatible integer; begin - l_compatible := ut3.ut_runner.version_compatibility_check(a_requested,a_current); + l_compatible := ut3_develop.ut_runner.version_compatibility_check(a_requested,a_current); ut.fail('Expected exception but nothing was raised'); exception when others then @@ -135,7 +135,7 @@ end;'; end; procedure run_reset_package_body_cache is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; begin @@ -144,16 +144,16 @@ end;'; create_test_body(0); select * bulk collect into l_results - from table(ut3.ut.run('test_cache')); + from table(ut3_develop.ut.run('test_cache')); --Act create_test_body(1); select * bulk collect into l_results - from table(ut3.ut.run('test_cache')); + from table(ut3_develop.ut.run('test_cache')); --Assert l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); - l_expected := '%ut3.ut.expect(1).to_be_null;%'; + l_expected := '%ut3_develop.ut.expect(1).to_be_null;%'; ut.expect(l_actual).to_be_like(l_expected); drop_test_package(); end; @@ -161,7 +161,7 @@ end;'; procedure run_keep_dbms_output_buffer is l_expected dbmsoutput_linesarray; l_actual dbmsoutput_linesarray; - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_lines number := 10000; begin --Arrange @@ -185,7 +185,7 @@ end;'; --Act select * bulk collect into l_results - from table(ut3.ut.run('test_cache')); + from table(ut3_develop.ut.run('test_cache')); --Assert dbms_output.get_lines(lines => l_actual, numlines => l_lines); @@ -207,7 +207,7 @@ end;'; ut.expect(l_actual).not_to_be_empty(); --Act - ut3.ut_runner.purge_cache(sys_context('USERENV', 'CURRENT_USER'),'PROCEDURE'); + ut3_develop.ut_runner.purge_cache(sys_context('USERENV', 'CURRENT_USER'),'PROCEDURE'); --Assert @@ -238,7 +238,7 @@ end;'; l_actual sys_refcursor; begin --Act - ut3.ut_runner.rebuild_annotation_cache( sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE' ); + ut3_develop.ut_runner.rebuild_annotation_cache( sys_context('USERENV', 'CURRENT_USER'), 'PACKAGE' ); --Assert l_actual := ut3_tester_helper.run_helper.get_annotation_cache_cursor( a_owner => sys_context('USERENV', 'CURRENT_USER'), @@ -254,7 +254,7 @@ end;'; a_type => 'PACKAGE' ); - --Did not rebuild cache for ut3/procedures + --Did not rebuild cache for ut3_develop/procedures ut.expect(l_actual).to_have_count(0); end; @@ -285,7 +285,7 @@ end;'; 'some' path, 0 disabled_flag, null tags from dual; --Act - open l_actual for select * from table(ut3.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); + open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); --Assert ut.expect(l_actual).to_equal(l_expected); end; @@ -317,7 +317,7 @@ end;'; 'some' path, 0 disabled_flag, null tags from dual; --Act - open l_actual for select * from table(ut3.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); + open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); --Assert ut.expect(l_actual).to_equal(l_expected); end; @@ -339,7 +339,7 @@ end;'; 'dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag,'testtag1,testtag2' tags from dual; --Act - open l_actual for select * from table(ut3.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); + open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); --Assert ut.expect(l_actual).to_equal(l_expected); end; @@ -350,21 +350,21 @@ end;'; begin --Arrange open l_expected for - select 'UT3.UT_COVERAGE_COBERTURA_REPORTER' reporter_object_name, 'Y' is_output_reporter from dual union all - select 'UT3.UT_DEBUG_REPORTER', 'Y' from dual union all - select 'UT3.UT_COVERAGE_HTML_REPORTER', 'Y' from dual union all - select 'UT3.UT_COVERAGE_SONAR_REPORTER', 'Y' from dual union all - select 'UT3.UT_COVERALLS_REPORTER', 'Y' from dual union all - select 'UT3.UT_DOCUMENTATION_REPORTER', 'Y' from dual union all - select 'UT3.UT_JUNIT_REPORTER', 'Y' from dual union all - select 'UT3.UT_REALTIME_REPORTER', 'Y' from dual union all - select 'UT3.UT_SONAR_TEST_REPORTER', 'Y' from dual union all - select 'UT3.UT_TEAMCITY_REPORTER', 'Y' from dual union all - select 'UT3.UT_TFS_JUNIT_REPORTER', 'Y' from dual union all - select 'UT3.UT_XUNIT_REPORTER', 'Y' from dual + select 'UT3_DEVELOP.UT_COVERAGE_COBERTURA_REPORTER' reporter_object_name, 'Y' is_output_reporter from dual union all + select 'UT3_DEVELOP.UT_DEBUG_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_COVERAGE_HTML_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_COVERAGE_SONAR_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_COVERALLS_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_DOCUMENTATION_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_JUNIT_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_REALTIME_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_SONAR_TEST_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_TEAMCITY_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_TFS_JUNIT_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_XUNIT_REPORTER', 'Y' from dual order by 1; --Act - open l_actual for select * from table(ut3.ut_runner.GET_REPORTERS_LIST()) order by 1; + open l_actual for select * from table(ut3_develop.ut_runner.GET_REPORTERS_LIST()) order by 1; --Assert ut.expect(l_actual).to_equal(l_expected); end; @@ -382,13 +382,13 @@ end;'; end; procedure raises_20213_on_fail_link is - l_reporter ut3.ut_documentation_reporter := ut3.ut_documentation_reporter(); - l_lines ut3.ut_varchar2_list; + l_reporter ut3_develop.ut_documentation_reporter := ut3_develop.ut_documentation_reporter(); + l_lines ut3_develop.ut_varchar2_list; pragma autonomous_transaction; begin --Arrange --Act - ut3.ut_runner.run(ut3.ut_varchar2_list('test_db_link'), ut3.ut_reporters(l_reporter), a_fail_on_errors=> true); + ut3_develop.ut_runner.run(ut3_develop.ut_varchar2_list('test_db_link'), ut3_develop.ut_reporters(l_reporter), a_fail_on_errors=> true); ut.fail('Expected exception but nothing was raised'); exception when others then @@ -419,12 +419,12 @@ end;'; procedure one_is_one is begin - ut3.ut.expect(1).to_equal(1); + ut3_develop.ut.expect(1).to_equal(1); end; procedure two_is_two is begin - ut3.ut.expect(2).to_equal(2); + ut3_develop.ut.expect(2).to_equal(2); end; end; @@ -449,12 +449,12 @@ end;'; procedure one_is_one is begin - ut3.ut.expect(1).to_equal(1); + ut3_develop.ut.expect(1).to_equal(1); end; procedure two_is_two is begin - ut3.ut.expect(2).to_equal(2); + ut3_develop.ut.expect(2).to_equal(2); end; end; @@ -470,12 +470,12 @@ end;'; end; procedure pass_varchar2_name_list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin select * bulk collect into l_results - from table(ut3.ut.run(ut3.ut_varchar2_list('test_csl_names1','test_csl_names2'))); + from table(ut3_develop.ut.run(ut3_develop.ut_varchar2_list('test_csl_names1','test_csl_names2'))); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like('%Finished in % seconds @@ -483,12 +483,12 @@ end;'; end; procedure pass_varchar2_name is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin select * bulk collect into l_results - from table(ut3.ut.run('test_csl_names1')); + from table(ut3_develop.ut.run('test_csl_names1')); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like('%Finished in % seconds @@ -496,12 +496,12 @@ end;'; end; procedure pass_varchar2_suite_csl is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin select * bulk collect into l_results - from table(ut3.ut.run('test_csl_names1,test_csl_names2')); + from table(ut3_develop.ut.run('test_csl_names1,test_csl_names2')); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like('%Finished in % seconds @@ -509,12 +509,12 @@ end;'; end; procedure pass_varchar2_test_csl is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin select * bulk collect into l_results - from table(ut3.ut.run('test_csl_names1.one_is_one,test_csl_names2.one_is_one')); + from table(ut3_develop.ut.run('test_csl_names1.one_is_one,test_csl_names2.one_is_one')); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like('%Finished in % seconds @@ -522,12 +522,12 @@ end;'; end; procedure pass_varch_test_csl_spc is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin select * bulk collect into l_results - from table(ut3.ut.run('test_csl_names1.one_is_one, test_csl_names2.one_is_one')); + from table(ut3_develop.ut.run('test_csl_names1.one_is_one, test_csl_names2.one_is_one')); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like('%Finished in % seconds @@ -535,17 +535,17 @@ end;'; end; procedure pass_csl_with_srcfile is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin select * bulk collect into l_results from table( - ut3.ut.run( + ut3_develop.ut.run( a_path => 'test_csl_names1.one_is_one,test_csl_names2.one_is_one', - a_source_files => ut3.ut_varchar2_list('ut3.ut'), - a_test_files => ut3.ut_varchar2_list('ut3_tester.test_csl_names2') + a_source_files => ut3_develop.ut_varchar2_list('ut3_develop.ut'), + a_test_files => ut3_develop.ut_varchar2_list('ut3_tester.test_csl_names2') ) ); @@ -555,12 +555,12 @@ end;'; end; procedure pass_csl_within_var2list is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin select * bulk collect into l_results - from table(ut3.ut.run(ut3.ut_varchar2_list('test_csl_names1.one_is_one,test_csl_names2.one_is_one'))); + from table(ut3_develop.ut.run(ut3_develop.ut_varchar2_list('test_csl_names1.one_is_one,test_csl_names2.one_is_one'))); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like('%Finished in % seconds @@ -570,55 +570,55 @@ end;'; procedure is_test_true is begin ut.expect( - ut3.ut_runner.is_test( + ut3_develop.ut_runner.is_test( a_owner => 'UT3$USER#', a_package_name => 'DUMMY_TEST_PACKAGE', a_procedure_name => 'SOME_DUMMY_TEST_PROCEDURE' ) ).to_be_true(); - ut.expect( ut3.ut_runner.is_test( 'ut3$user#','dummy_test_package','some_dummy_test_procedure' ) ).to_be_true(); + ut.expect( ut3_develop.ut_runner.is_test( 'ut3$user#','dummy_test_package','some_dummy_test_procedure' ) ).to_be_true(); end; procedure is_test_false is begin - ut.expect( ut3.ut_runner.is_test( 'UT3$USER#','DUMMY_TEST_PACKAGE', 'BAD' ) ).to_be_false(); - ut.expect( ut3.ut_runner.is_test( 'UT3$USER#','BAD_TEST_PACKAGE', 'some_dummy_test_procedure' ) ).to_be_false(); - ut.expect( ut3.ut_runner.is_test( 'UT3$USER#','DUMMY_TEST_PACKAGE', null ) ).to_be_false(); - ut.expect( ut3.ut_runner.is_test( 'UT3$USER#',null,'some_dummy_test_procedure' ) ).to_be_false(); - ut.expect( ut3.ut_runner.is_test( null,'DUMMY_TEST_PACKAGE','some_dummy_test_procedure' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_test( 'UT3$USER#','DUMMY_TEST_PACKAGE', 'BAD' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_test( 'UT3$USER#','BAD_TEST_PACKAGE', 'some_dummy_test_procedure' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_test( 'UT3$USER#','DUMMY_TEST_PACKAGE', null ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_test( 'UT3$USER#',null,'some_dummy_test_procedure' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_test( null,'DUMMY_TEST_PACKAGE','some_dummy_test_procedure' ) ).to_be_false(); end; procedure is_suite_true is begin ut.expect( - ut3.ut_runner.is_suite( + ut3_develop.ut_runner.is_suite( a_owner => 'UT3$USER#', a_package_name => 'DUMMY_TEST_PACKAGE' ) ).to_be_true(); - ut.expect( ut3.ut_runner.is_suite( 'ut3$user#','dummy_test_package' ) ).to_be_true(); + ut.expect( ut3_develop.ut_runner.is_suite( 'ut3$user#','dummy_test_package' ) ).to_be_true(); end; procedure is_suite_false is begin - ut.expect( ut3.ut_runner.is_suite( 'UT3$USER#','BAD' ) ).to_be_false(); - ut.expect( ut3.ut_runner.is_suite( 'UT3$USER#', null ) ).to_be_false(); - ut.expect( ut3.ut_runner.is_suite( null,'DUMMY_TEST_PACKAGE' ) ).to_be_false(); - ut.expect( ut3.ut_runner.is_suite( 'UT3$USER#','bad_test_package' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_suite( 'UT3$USER#','BAD' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_suite( 'UT3$USER#', null ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_suite( null,'DUMMY_TEST_PACKAGE' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_suite( 'UT3$USER#','bad_test_package' ) ).to_be_false(); end; procedure has_suites_true is begin - ut.expect( ut3.ut_runner.has_suites( a_owner => 'UT3$USER#' ) ).to_be_true(); - ut.expect( ut3.ut_runner.has_suites( 'ut3$user#' ) ).to_be_true(); + ut.expect( ut3_develop.ut_runner.has_suites( a_owner => 'UT3$USER#' ) ).to_be_true(); + ut.expect( ut3_develop.ut_runner.has_suites( 'ut3$user#' ) ).to_be_true(); end; procedure has_suites_false is begin - ut.expect( ut3.ut_runner.has_suites( 'UT3_LATEST_RELEASE' ) ).to_be_false(); - ut.expect( ut3.ut_runner.has_suites( 'BAD' ) ).to_be_false(); - ut.expect( ut3.ut_runner.has_suites( null ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.has_suites( 'UT3' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.has_suites( 'BAD' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.has_suites( null ) ).to_be_false(); end; end; diff --git a/test/ut3_user/expectations.pkb b/test/ut3_user/expectations.pkb index 3f2ae543d..30af48a44 100644 --- a/test/ut3_user/expectations.pkb +++ b/test/ut3_user/expectations.pkb @@ -8,22 +8,22 @@ create or replace package body expectations as --Arrange --Act execute immediate 'begin some_pkg.some_procedure; end;'; - ut3.ut.expect(1).to_equal(0); - ut3.ut.expect(0).to_equal(0); + ut3_develop.ut.expect(1).to_equal(0); + ut3_develop.ut.expect(0).to_equal(0); --Assert l_actual := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); l_expected := q'[FAILURE Actual: 1 (number) was expected to equal: 0 (number) - at "UT3$USER#.SOME_PKG%", line 4 ut3.ut.expect(1).to_equal(0); + at "UT3$USER#.SOME_PKG%", line 4 ut3_develop.ut.expect(1).to_equal(0); at "anonymous block", line 1 at "UT3$USER#.EXPECTATIONS%", line 10 SUCCESS Actual: 0 (number) was expected to equal: 0 (number) FAILURE Actual: 1 (number) was expected to equal: 0 (number) - at "UT3$USER#.EXPECTATIONS%", line 11 ut3.ut.expect(1).to_equal(0); + at "UT3$USER#.EXPECTATIONS%", line 11 ut3_develop.ut.expect(1).to_equal(0); SUCCESS Actual: 0 (number) was expected to equal: 0 (number) ]'; @@ -44,8 +44,8 @@ SUCCESS create or replace package body some_pkg is procedure some_procedure is begin - ut3.ut.expect(1).to_equal(0); - ut3.ut.expect(0).to_equal(0); + ut3_develop.ut.expect(1).to_equal(0); + ut3_develop.ut.expect(0).to_equal(0); end; end;]'; end; diff --git a/test/ut3_user/expectations/binary/test_be_greater_or_equal.pkb b/test/ut3_user/expectations/binary/test_be_greater_or_equal.pkb index 5d99d07b6..3f92c84c7 100644 --- a/test/ut3_user/expectations/binary/test_be_greater_or_equal.pkb +++ b/test/ut3_user/expectations/binary/test_be_greater_or_equal.pkb @@ -254,7 +254,7 @@ create or replace package body test_be_greater_or_equal is procedure actual_clob is begin --Act - ut3.ut.expect(to_clob('3')).to_( ut3.be_greater_or_equal(3) ); + ut3_develop.ut.expect(to_clob('3')).to_( ut3_develop.be_greater_or_equal(3) ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; diff --git a/test/ut3_user/expectations/binary/test_be_greater_than.pkb b/test/ut3_user/expectations/binary/test_be_greater_than.pkb index 37e15f633..6724b5c41 100644 --- a/test/ut3_user/expectations/binary/test_be_greater_than.pkb +++ b/test/ut3_user/expectations/binary/test_be_greater_than.pkb @@ -254,7 +254,7 @@ create or replace package body test_be_greater_than is procedure actual_clob is begin --Act - ut3.ut.expect(to_clob('3')).to_( ut3.be_greater_than(2) ); + ut3_develop.ut.expect(to_clob('3')).to_( ut3_develop.be_greater_than(2) ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; diff --git a/test/ut3_user/expectations/binary/test_be_less_or_equal.pkb b/test/ut3_user/expectations/binary/test_be_less_or_equal.pkb index bf7632cc4..aefb58849 100644 --- a/test/ut3_user/expectations/binary/test_be_less_or_equal.pkb +++ b/test/ut3_user/expectations/binary/test_be_less_or_equal.pkb @@ -254,7 +254,7 @@ create or replace package body test_be_less_or_equal is procedure actual_clob is begin --Act - ut3.ut.expect(to_clob('3')).to_( ut3.be_less_or_equal(3) ); + ut3_develop.ut.expect(to_clob('3')).to_( ut3_develop.be_less_or_equal(3) ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; diff --git a/test/ut3_user/expectations/binary/test_equal.pkb b/test/ut3_user/expectations/binary/test_equal.pkb index 95fd594c7..735915348 100644 --- a/test/ut3_user/expectations/binary/test_equal.pkb +++ b/test/ut3_user/expectations/binary/test_equal.pkb @@ -26,7 +26,7 @@ create or replace package body test_equal is l_actual '||a_actual_type||' := '||a_actual||'; l_expected '||a_expected_type||' := '||a_expected||'; begin - ut3.ut.expect( l_actual ).'||a_matcher_name||'(l_expected, a_nulls_are_equal=>'||l_nulls_equal||'); + ut3_develop.ut.expect( l_actual ).'||a_matcher_name||'(l_expected, a_nulls_are_equal=>'||l_nulls_equal||'); end;'; end; diff --git a/test/ut3_user/expectations/binary/test_expect_to_be_less_than.pkb b/test/ut3_user/expectations/binary/test_expect_to_be_less_than.pkb index d7bf5533b..dbf6e30a4 100644 --- a/test/ut3_user/expectations/binary/test_expect_to_be_less_than.pkb +++ b/test/ut3_user/expectations/binary/test_expect_to_be_less_than.pkb @@ -254,7 +254,7 @@ create or replace package body test_expect_to_be_less_than is procedure actual_clob is begin --Act - ut3.ut.expect(to_clob('3')).to_( ut3.be_less_than(4) ); + ut3_develop.ut.expect(to_clob('3')).to_( ut3_develop.be_less_than(4) ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index ece5457a7..be666b284 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -23,7 +23,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( cast(null as ut3_tester_helper.test_dummy_object) ); g_test_actual := anydata.convertObject( cast(null as ut3_tester_helper.other_dummy_object) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_expected_message := q'[%Actual (ut3_tester_helper.other_dummy_object) cannot be compared to Expected (ut3_tester_helper.test_dummy_object) using matcher 'equal'.]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -39,7 +39,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, 'A', '0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.other_dummy_object(1, 'A', '0') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_expected_message := q'[%Actual (ut3_tester_helper.other_dummy_object) cannot be compared to Expected (ut3_tester_helper.test_dummy_object) using matcher 'equal'.]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -53,7 +53,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, 'A', '0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, null, '0') ); --Act - ut3.ut.expect( g_test_actual ).not_to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).not_to_equal( g_test_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -66,7 +66,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, 'A', '0') ); g_test_actual := anydata.convertObject( cast(null as ut3_tester_helper.test_dummy_object) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_object was expected to equal: ut3_tester_helper.test_dummy_object %Diff: @@ -86,7 +86,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, 'A', '0') ); g_test_actual := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list(ut3_tester_helper.test_dummy_object(1, 'A', '0')) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_expected_message := q'[%Actual (ut3_tester_helper.test_dummy_object_list) cannot be compared to Expected (ut3_tester_helper.test_dummy_object) using matcher 'equal'.]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -103,7 +103,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list() ); g_test_actual := anydata.convertCollection( l_null_list ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_object_list [ null ] was expected to equal: ut3_tester_helper.test_dummy_object_list [ count = 0 ]]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -121,7 +121,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list(ut3_tester_helper.test_dummy_object(1, 'A', '0')) ); g_test_actual := anydata.convertCollection( l_null_list ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_object_list [ null ] was expected to equal: ut3_tester_helper.test_dummy_object_list [ count = 1 ] %Diff: @@ -140,7 +140,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list(ut3_tester_helper.test_dummy_object(1, 'A', '0')) ); g_test_actual := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list() ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_object_list [ count = 0 ] was expected to equal: ut3_tester_helper.test_dummy_object_list [ count = 1 ] %Diff: @@ -161,7 +161,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list(l_obj) ); g_test_actual := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list(l_obj, l_obj) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_object_list [ count = 2 ] was expected to equal: ut3_tester_helper.test_dummy_object_list [ count = 1 ] %Diff: @@ -178,7 +178,7 @@ create or replace package body test_expectation_anydata is l_null_anydata anydata; begin --Act - ut3.ut.expect( l_null_anydata ).to_equal( l_null_anydata ); + ut3_develop.ut.expect( l_null_anydata ).to_equal( l_null_anydata ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -189,7 +189,7 @@ create or replace package body test_expectation_anydata is l_anydata anydata := anydata.convertObject(l_null_object); begin --Act - ut3.ut.expect( l_anydata ).to_equal( l_anydata ); + ut3_develop.ut.expect( l_anydata ).to_equal( l_anydata ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -200,7 +200,7 @@ create or replace package body test_expectation_anydata is l_anydata anydata := anydata.convertCollection(l_null_collection); begin --Act - ut3.ut.expect( l_anydata ).to_equal( l_anydata ); + ut3_develop.ut.expect( l_anydata ).to_equal( l_anydata ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -211,7 +211,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list(ut3_tester_helper.test_dummy_object(1, 'A', '0')) ); g_test_actual := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list(ut3_tester_helper.test_dummy_object(1, 'A', '0')) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -226,7 +226,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list(l_first_obj, l_second_obj) ); g_test_actual := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list(l_second_obj, l_first_obj) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -237,20 +237,20 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, 'A', '0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, 'A', '0') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; procedure exclude_attributes_as_list is - l_list ut3.ut_varchar2_list; + l_list ut3_develop.ut_varchar2_list; begin --Arrange - l_list := ut3.ut_varchar2_list('Value','/ID'); + l_list := ut3_develop.ut_varchar2_list('Value','/ID'); g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>3, "name"=>'A',"Value"=>'1') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected, a_exclude=> l_list ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected, a_exclude=> l_list ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -263,7 +263,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>2, "name"=>'A',"Value"=>'1') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected, a_exclude=> l_list ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected, a_exclude=> l_list ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -276,7 +276,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>2, "name"=>'A',"Value"=>'1') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected, a_exclude=> l_xpath ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected, a_exclude=> l_xpath ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -289,20 +289,20 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'0') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected, a_exclude=> l_exclude ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected, a_exclude=> l_exclude ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; procedure include_attributes_as_list is - l_list ut3.ut_varchar2_list; + l_list ut3_develop.ut_varchar2_list; begin --Arrange - l_list := ut3.ut_varchar2_list('Value','ID'); + l_list := ut3_develop.ut_varchar2_list('Value','ID'); g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'b',"Value"=>'0') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ).include( l_list ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ).include( l_list ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -315,7 +315,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'1') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ).include( l_xpath ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ).include( l_xpath ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -328,7 +328,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'1') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ).include( l_xpath ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ).include( l_xpath ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -341,7 +341,7 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'B',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'1') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ).include( l_include ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ).include( l_include ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -356,24 +356,24 @@ create or replace package body test_expectation_anydata is g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'B',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'1') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ).exclude( l_exclude ).include( l_include ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ).exclude( l_exclude ).include( l_include ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; procedure include_exclude_attrib_list is - l_exclude ut3.ut_varchar2_list; - l_include ut3.ut_varchar2_list; + l_exclude ut3_develop.ut_varchar2_list; + l_include ut3_develop.ut_varchar2_list; l_expected varchar2(32767); l_actual varchar2(32767); begin --Arrange - l_include := ut3.ut_varchar2_list('key','ID','Value'); - l_exclude := ut3.ut_varchar2_list('key','Value'); + l_include := ut3_develop.ut_varchar2_list('key','ID','Value'); + l_exclude := ut3_develop.ut_varchar2_list('key','Value'); g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'B',"Value"=>'0') ); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(id=>1, "name"=>'A',"Value"=>'1') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ).exclude( l_exclude ).include( l_include ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ).exclude( l_exclude ).include( l_include ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -391,7 +391,7 @@ Rows: [ 1 differences ] Row No. 1 - Actual: Row No. 1 - Expected: A]'; --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_actual := ut3_tester_helper.main_helper.get_failed_expectations(1); ut.expect(l_actual).to_be_like(l_expected); @@ -411,7 +411,7 @@ Diff: Rows: [ 1 differences ] Row No. 2 - Extra: 1A0]'; --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); --Assert l_actual := ut3_tester_helper.main_helper.get_failed_expectations(1); ut.expect(l_actual).to_be_like(l_expected); @@ -425,7 +425,7 @@ Rows: [ 1 differences ] procedure deprec_to_equal_excl_varch is begin --Act - ut3.ut.expect(get_anydata()).to_equal(get_anydata(), a_exclude => 'A_COLUMN,Some_Col'); + ut3_develop.ut.expect(get_anydata()).to_equal(get_anydata(), a_exclude => 'A_COLUMN,Some_Col'); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -434,7 +434,7 @@ Rows: [ 1 differences ] procedure deprec_to_equal_excl_list is begin --Act - ut3.ut.expect(get_anydata()).to_equal(get_anydata(), a_exclude => ut3.ut_varchar2_list('A_COLUMN','Some_Col')); + ut3_develop.ut.expect(get_anydata()).to_equal(get_anydata(), a_exclude => ut3_develop.ut_varchar2_list('A_COLUMN','Some_Col')); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -443,7 +443,7 @@ Rows: [ 1 differences ] procedure deprec_not_to_equal_excl_varch is begin --Act - ut3.ut.expect(get_anydata()).not_to_equal(get_anydata(), a_exclude => 'A_COLUMN,Some_Col'); + ut3_develop.ut.expect(get_anydata()).not_to_equal(get_anydata(), a_exclude => 'A_COLUMN,Some_Col'); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -452,7 +452,7 @@ Rows: [ 1 differences ] procedure deprec_not_to_equal_excl_list is begin --Act - ut3.ut.expect(get_anydata()).not_to_equal(get_anydata(), a_exclude => ut3.ut_varchar2_list('A_COLUMN','Some_Col')); + ut3_develop.ut.expect(get_anydata()).not_to_equal(get_anydata(), a_exclude => ut3_develop.ut_varchar2_list('A_COLUMN','Some_Col')); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -461,7 +461,7 @@ Rows: [ 1 differences ] procedure deprec_equal_excl_varch is begin --Act - ut3.ut.expect(get_anydata()).to_(ut3.equal(get_anydata(), a_exclude => 'A_COLUMN,Some_Col')); + ut3_develop.ut.expect(get_anydata()).to_(ut3_develop.equal(get_anydata(), a_exclude => 'A_COLUMN,Some_Col')); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -470,7 +470,7 @@ Rows: [ 1 differences ] procedure deprec_equal_excl_list is begin --Act - ut3.ut.expect(get_anydata()).to_(ut3.equal(get_anydata(), a_exclude => ut3.ut_varchar2_list('A_COLUMN','Some_Col'))); + ut3_develop.ut.expect(get_anydata()).to_(ut3_develop.equal(get_anydata(), a_exclude => ut3_develop.ut_varchar2_list('A_COLUMN','Some_Col'))); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -491,7 +491,7 @@ Rows: [ 1 differences ] from dual connect by level <=2 order by rownum desc; --Act - ut3.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); l_expected_message := q'[Actual: ut3_tester_helper.test_dummy_object_list [ count = 2 ] was expected to equal: ut3_tester_helper.test_dummy_object_list [ count = 2 ] Diff: @@ -521,7 +521,7 @@ Rows: [ 2 differences ] bulk collect into l_expected from dual connect by level <=110; --Act - ut3.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); l_expected_message := q'[Actual: ut3_tester_helper.test_dummy_object_list [ count = 100 ] was expected to equal: ut3_tester_helper.test_dummy_object_list [ count = 110 ] Diff: @@ -543,9 +543,9 @@ Rows: [ 60 differences, showing first 20 ] procedure collection_include_list is l_actual ut3_tester_helper.test_dummy_object_list; l_expected ut3_tester_helper.test_dummy_object_list; - l_list ut3.ut_varchar2_list; + l_list ut3_develop.ut_varchar2_list; begin - l_list := ut3.ut_varchar2_list('Value','ID'); + l_list := ut3_develop.ut_varchar2_list('Value','ID'); --Arrange select ut3_tester_helper.test_dummy_object( rownum, 'SomethingsDifferent '||rownum, rownum) bulk collect into l_actual @@ -554,7 +554,7 @@ Rows: [ 60 differences, showing first 20 ] bulk collect into l_expected from dual connect by level <=2; --Act - ut3.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).include( l_list ); + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).include( l_list ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -562,9 +562,9 @@ Rows: [ 60 differences, showing first 20 ] procedure collection_exclude_list is l_actual ut3_tester_helper.test_dummy_object_list; l_expected ut3_tester_helper.test_dummy_object_list; - l_list ut3.ut_varchar2_list; + l_list ut3_develop.ut_varchar2_list; begin - l_list := ut3.ut_varchar2_list('Value','ID'); + l_list := ut3_develop.ut_varchar2_list('Value','ID'); --Arrange select ut3_tester_helper.test_dummy_object( rownum*2, 'Something '||rownum, rownum*2) bulk collect into l_actual @@ -573,7 +573,7 @@ Rows: [ 60 differences, showing first 20 ] bulk collect into l_expected from dual connect by level <=2; --Act - ut3.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).exclude( l_list ); + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).exclude( l_list ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -581,11 +581,11 @@ Rows: [ 60 differences, showing first 20 ] procedure collection_include_list_fail is l_actual ut3_tester_helper.test_dummy_object_list; l_expected ut3_tester_helper.test_dummy_object_list; - l_list ut3.ut_varchar2_list; + l_list ut3_develop.ut_varchar2_list; l_actual_message varchar2(32767); l_expected_message varchar2(32767); begin - l_list := ut3.ut_varchar2_list('name'); + l_list := ut3_develop.ut_varchar2_list('name'); --Arrange select ut3_tester_helper.test_dummy_object( rownum, 'SomethingsDifferent '||rownum, rownum) bulk collect into l_actual @@ -594,7 +594,7 @@ Rows: [ 60 differences, showing first 20 ] bulk collect into l_expected from dual connect by level <=2; --Act - ut3.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).include( l_list ); + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).include( l_list ); l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_object_list [ count = 2 ] was expected to equal: ut3_tester_helper.test_dummy_object_list [ count = 2 ] %Diff: @@ -614,7 +614,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection( ut3_tester_helper.t_tab_varchar('A') ); g_test_actual := anydata.convertCollection( ut3_tester_helper.t_tab_varchar('A') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -626,7 +626,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection( ut3_tester_helper.t_tab_varchar('A') ); g_test_actual := anydata.convertCollection( ut3_tester_helper.t_tab_varchar('B') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); l_expected_message := q'[%Actual: ut3_tester_helper.t_tab_varchar [ count = 1 ] was expected to equal: ut3_tester_helper.t_tab_varchar [ count = 1 ] %Diff: %Rows: [ 1 differences ] @@ -640,7 +640,7 @@ Rows: [ 60 differences, showing first 20 ] procedure array_is_null is l_is_null ut3_tester_helper.t_tab_varchar ; begin - ut3.ut.expect( anydata.convertCollection( l_is_null ) ).to_be_null; + ut3_develop.ut.expect( anydata.convertCollection( l_is_null ) ).to_be_null; ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -648,7 +648,7 @@ Rows: [ 60 differences, showing first 20 ] l_is_null ut3_tester_helper.t_tab_varchar ; l_is_null_bis ut3_tester_helper.t_tab_varchar ; begin - ut3.ut.expect( anydata.convertCollection( l_is_null ) ).to_equal(anydata.convertCollection( l_is_null_bis )); + ut3_develop.ut.expect( anydata.convertCollection( l_is_null ) ).to_equal(anydata.convertCollection( l_is_null_bis )); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -661,7 +661,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection( l_is_null ); g_test_actual := anydata.convertCollection( ut3_tester_helper.t_tab_varchar('A') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); l_expected_message := q'[%Actual: ut3_tester_helper.t_tab_varchar [ count = 1 ] was expected to equal: ut3_tester_helper.t_tab_varchar [ null ] %Diff: %Rows: [ 1 differences ] @@ -673,7 +673,7 @@ Rows: [ 60 differences, showing first 20 ] procedure empty_array_have_zero_elem is begin - ut3.ut.expect( anydata.convertCollection(ut3_tester_helper.t_tab_varchar())).to_have_count(0); + ut3_develop.ut.expect( anydata.convertCollection(ut3_tester_helper.t_tab_varchar())).to_have_count(0); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -683,7 +683,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection(ut3_tester_helper.t_tab_varchar()); g_test_actual := anydata.convertCollection(ut3_tester_helper.t_tab_varchar()); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -696,7 +696,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection( ut3_tester_helper.t_tab_varchar() ); g_test_actual := anydata.convertCollection( ut3_tester_helper.t_tab_varchar('A') ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); l_expected_message := q'[%Actual: ut3_tester_helper.t_tab_varchar [ count = 1 ] was expected to equal: ut3_tester_helper.t_tab_varchar [ count = 0 ] %Diff: %Rows: [ 1 differences ] @@ -712,7 +712,7 @@ Rows: [ 60 differences, showing first 20 ] --Arrange g_test_actual := anydata.convertCollection( l_null_list ); --Act - ut3.ut.expect( g_test_actual ).to_be_null; + ut3_develop.ut.expect( g_test_actual ).to_be_null; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -722,7 +722,7 @@ Rows: [ 60 differences, showing first 20 ] --Arrange g_test_actual := anydata.convertCollection( ut3_tester_helper.test_dummy_object_list() ); --Act - ut3.ut.expect( g_test_actual ).to_have_count(0); + ut3_develop.ut.expect( g_test_actual ).to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -734,7 +734,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection( ut3_tester_helper.t_varray(1) ); g_test_actual := anydata.convertCollection( ut3_tester_helper.t_varray(1) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -746,7 +746,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection( ut3_tester_helper.t_varray(1) ); g_test_actual := anydata.convertCollection( ut3_tester_helper.t_varray(2) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); l_expected_message := q'[%Actual: ut3_tester_helper.t_varray [ count = 1 ] was expected to equal: ut3_tester_helper.t_varray [ count = 1 ] %Diff: %Rows: [ 1 differences ] @@ -760,7 +760,7 @@ Rows: [ 60 differences, showing first 20 ] procedure varray_is_null is l_is_null ut3_tester_helper.t_varray ; begin - ut3.ut.expect( anydata.convertCollection( l_is_null ) ).to_be_null; + ut3_develop.ut.expect( anydata.convertCollection( l_is_null ) ).to_be_null; ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -768,7 +768,7 @@ Rows: [ 60 differences, showing first 20 ] l_is_null ut3_tester_helper.t_varray ; l_is_null_bis ut3_tester_helper.t_varray ; begin - ut3.ut.expect( anydata.convertCollection( l_is_null ) ).to_equal(anydata.convertCollection( l_is_null_bis )); + ut3_develop.ut.expect( anydata.convertCollection( l_is_null ) ).to_equal(anydata.convertCollection( l_is_null_bis )); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -781,7 +781,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection( l_is_null ); g_test_actual := anydata.convertCollection( ut3_tester_helper.t_varray(1) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); l_expected_message := q'[%Actual: ut3_tester_helper.t_varray [ count = 1 ] was expected to equal: ut3_tester_helper.t_varray [ null ] %Diff: %Rows: [ 1 differences ] @@ -793,7 +793,7 @@ Rows: [ 60 differences, showing first 20 ] procedure empty_varray_have_zero_elem is begin - ut3.ut.expect( anydata.convertCollection(ut3_tester_helper.t_varray())).to_have_count(0); + ut3_develop.ut.expect( anydata.convertCollection(ut3_tester_helper.t_varray())).to_have_count(0); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -803,7 +803,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection(ut3_tester_helper.t_varray()); g_test_actual := anydata.convertCollection(ut3_tester_helper.t_varray()); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -816,7 +816,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertCollection( ut3_tester_helper.t_varray() ); g_test_actual := anydata.convertCollection( ut3_tester_helper.t_varray(1) ); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); l_expected_message := q'[%Actual: ut3_tester_helper.t_varray [ count = 1 ] was expected to equal: ut3_tester_helper.t_varray [ count = 0 ] %Diff: %Rows: [ 1 differences ] @@ -841,7 +841,7 @@ Rows: [ 60 differences, showing first 20 ] from dual connect by level <=2 order by rownum desc; --Act - ut3.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).join_by('ID'); + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).join_by('ID'); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -860,7 +860,7 @@ Rows: [ 60 differences, showing first 20 ] from dual connect by level <=2 order by rownum desc; --Act - ut3.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).join_by('ID'); + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).join_by('ID'); l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_object_list [ count = 2 ] was expected to equal: ut3_tester_helper.test_dummy_object_list [ count = 2 ] %Diff: %Rows: [ 3 differences ] @@ -886,7 +886,7 @@ Rows: [ 60 differences, showing first 20 ] from dual connect by level <=3 order by rownum desc; --Act - ut3.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).unordered; + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).unordered; ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -913,7 +913,7 @@ Rows: [ 60 differences, showing first 20 ] %Missing: 4Something 22 %Missing: 2Something 11]'; - ut3.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).unordered; + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)).unordered; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); @@ -926,7 +926,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, 'A', '0') ); --Act - ut3.ut.expect(g_test_actual).to_equal(g_test_expected).join_by('ID'); + ut3_develop.ut.expect(g_test_actual).to_equal(g_test_expected).join_by('ID'); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -936,7 +936,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, 'A', '0') ); --Act - ut3.ut.expect(g_test_actual).to_equal(g_test_expected).unordered; + ut3_develop.ut.expect(g_test_actual).to_equal(g_test_expected).unordered; ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -953,7 +953,7 @@ Rows: [ 60 differences, showing first 20 ] from dual connect by level <=2 order by rownum desc; --Act - ut3.ut.expect(anydata.convertCollection(l_actual)).to_contain(anydata.convertCollection(l_expected)); + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).to_contain(anydata.convertCollection(l_expected)); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -964,7 +964,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_object(1, 'A', '0') ); --Act - ut3.ut.expect(g_test_actual).to_contain(g_test_expected); + ut3_develop.ut.expect(g_test_actual).to_contain(g_test_expected); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -975,7 +975,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_actual := anydata.convertCollection(ut3_tester_helper.t_tab_varchar(null)); --Act - ut3.ut.expect( g_test_actual ).to_equal( g_test_expected ).unordered(); + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ).unordered(); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -987,7 +987,7 @@ Rows: [ 60 differences, showing first 20 ] g_test_actual := anydata.convertCollection(ut3_tester_helper.t_tab_varchar(' ')); --Act - ut3.ut.expect( g_test_actual ).not_to_equal( g_test_expected ).unordered(); + ut3_develop.ut.expect( g_test_actual ).not_to_equal( g_test_expected ).unordered(); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index 4f9cd72d6..f06132009 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -48,7 +48,7 @@ create or replace package body test_expectations_cursor is select 'Other test entry' as value from dual; open l_actual for 'select * from gtt_test_table'; --Act - execute the expectation on cursor opened on GTT - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); --Cleanup @@ -62,7 +62,7 @@ create or replace package body test_expectations_cursor is l_actual sys_refcursor; begin -- Arrange - ut3.ut.set_nls; + ut3_develop.ut.set_nls; open l_expected for select 1 as my_num, 'This is my test string' as my_string, @@ -76,10 +76,10 @@ create or replace package body test_expectations_cursor is to_date('1984-09-05', 'YYYY-MM-DD') as my_date from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); - ut3.ut.reset_nls; + ut3_develop.ut.reset_nls; end; procedure success_on_same_data_float @@ -88,7 +88,7 @@ create or replace package body test_expectations_cursor is l_actual sys_refcursor; begin -- Arrange - ut3.ut.set_nls; + ut3_develop.ut.set_nls; open l_expected for select cast(3.14 as binary_double) as pi_double, cast(3.14 as binary_float) as pi_float @@ -98,10 +98,10 @@ create or replace package body test_expectations_cursor is cast(3.14 as binary_float) as pi_float from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); - ut3.ut.reset_nls; + ut3_develop.ut.reset_nls; end; procedure success_on_empty @@ -113,7 +113,7 @@ create or replace package body test_expectations_cursor is open l_expected for select * from dual where 1=0; open l_actual for select * from dual where 1=0; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -124,7 +124,7 @@ create or replace package body test_expectations_cursor is l_actual sys_refcursor; begin --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -134,7 +134,7 @@ create or replace package body test_expectations_cursor is l_actual sys_refcursor; begin --Act - ut3.ut.expect( l_actual ).to_be_null(); + ut3_develop.ut.expect( l_actual ).to_be_null(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -144,7 +144,7 @@ create or replace package body test_expectations_cursor is l_actual sys_refcursor; begin --Act - ut3.ut.expect( l_actual ).not_to_be_not_null(); + ut3_develop.ut.expect( l_actual ).not_to_be_not_null(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -156,7 +156,7 @@ create or replace package body test_expectations_cursor is --Arrange open l_actual for select * from dual; --Act - ut3.ut.expect( l_actual ).to_be_not_null(); + ut3_develop.ut.expect( l_actual ).to_be_not_null(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -168,7 +168,7 @@ create or replace package body test_expectations_cursor is --Arrange open l_actual for select * from dual; --Act - ut3.ut.expect( l_actual ).to_be_not_null(); + ut3_develop.ut.expect( l_actual ).to_be_not_null(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -180,7 +180,7 @@ create or replace package body test_expectations_cursor is --Arrange open l_actual for select * from dual where 0=1; --Act - ut3.ut.expect( l_actual ).to_be_empty(); + ut3_develop.ut.expect( l_actual ).to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -192,7 +192,7 @@ create or replace package body test_expectations_cursor is --Arrange open l_actual for select * from dual; --Act - ut3.ut.expect( l_actual ).not_to_be_empty(); + ut3_develop.ut.expect( l_actual ).not_to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -204,7 +204,7 @@ create or replace package body test_expectations_cursor is --Arrange open l_actual for select * from dual; --Act - ut3.ut.expect( l_actual ).to_be_null(); + ut3_develop.ut.expect( l_actual ).to_be_null(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -214,7 +214,7 @@ create or replace package body test_expectations_cursor is l_actual sys_refcursor; begin --Act - ut3.ut.expect( l_actual ).not_to_be_null(); + ut3_develop.ut.expect( l_actual ).not_to_be_null(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -226,7 +226,7 @@ create or replace package body test_expectations_cursor is --Arrange open l_actual for select * from dual; --Act - ut3.ut.expect( l_actual ).to_be_empty(); + ut3_develop.ut.expect( l_actual ).to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -238,7 +238,7 @@ create or replace package body test_expectations_cursor is --Arrange open l_actual for select * from dual where 0=1; --Act - ut3.ut.expect( l_actual ).not_to_be_empty(); + ut3_develop.ut.expect( l_actual ).not_to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -251,7 +251,7 @@ create or replace package body test_expectations_cursor is --Arrange open l_expected for select * from dual where 1=0; --Act - ut3.ut.expect( l_actual ).not_to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).not_to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -265,7 +265,7 @@ create or replace package body test_expectations_cursor is open l_expected for select to_clob('This is an even longer test clob') as my_clob from dual; open l_actual for select to_clob('Another totally different story') as my_clob from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -279,7 +279,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as my_num from dual; open l_actual for select 1 as my_num from dual union all select 1 as my_num from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -293,7 +293,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as my_num from dual union all select 1 as my_num from dual; open l_actual for select 1 as my_num from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -307,7 +307,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as col_1 from dual; open l_actual for select 1 as col_2 from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -322,7 +322,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as col_1, 2 as col_2 from dual; open l_actual for select 2 as col_2, 1 as col_1 from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -336,7 +336,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as col_1, 2 as col_2 from dual; open l_actual for select 2 as col_2, 1 as col_1 from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ).unordered_columns; + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ).unordered_columns; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -350,7 +350,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as col_1, 2 as col_2 from dual; open l_actual for select 2 as col_2, 1 as col_1 from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ).uc; + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ).uc; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -366,7 +366,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as col_1, 2 as col_2,3 as col_3, 4 as col_4,5 col_5 from dual; open l_actual for select 2 as col_2, 1 as col_1,40 as col_4, 5 as col_5, 30 col_3 from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ).unordered_columns; + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ).unordered_columns; --Assert l_expected_message := q'[Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ] %Diff: @@ -389,7 +389,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as col_1, 2 as col_2,3 as col_3, 4 as col_4,5 col_5 from dual; open l_actual for select 2 as col_2, 1 as col_1,40 as col_4, 5 as col_5, 30 col_3 from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ).uc; + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ).uc; --Assert l_expected_message := q'[Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ] %Diff: @@ -410,7 +410,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as my_num from dual union all select 2 as my_num from dual; open l_actual for select 2 as my_num from dual union all select 1 as my_num from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -422,14 +422,14 @@ create or replace package body test_expectations_cursor is c_second constant number := 1/24/60/60; begin --Arrange - ut3.ut.set_nls; + ut3_develop.ut.set_nls; open l_actual for select gc_date as some_date from dual; open l_expected for select gc_date - c_second some_date from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); - ut3.ut.reset_nls; + ut3_develop.ut.reset_nls; end; procedure uses_default_nls_for_date @@ -441,7 +441,7 @@ create or replace package body test_expectations_cursor is open l_actual for select gc_date as some_date from dual; open l_expected for select to_date(to_char(gc_date)) as some_date from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -455,7 +455,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected, a_exclude=>ut3.ut_varchar2_list('A_COLUMN','Some_Col')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected, a_exclude=>ut3_develop.ut_varchar2_list('A_COLUMN','Some_Col')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -469,7 +469,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected, a_exclude=>'A_COLUMN,Some_Col'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected, a_exclude=>'A_COLUMN,Some_Col'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -482,7 +482,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected, a_exclude=>ut3.ut_varchar2_list('A_COLUMN','/ROW/Some_Col')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected, a_exclude=>ut3_develop.ut_varchar2_list('A_COLUMN','/ROW/Some_Col')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -495,7 +495,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected, a_exclude=>'A_COLUMN,/ROW/Some_Col'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected, a_exclude=>'A_COLUMN,/ROW/Some_Col'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -511,7 +511,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected, a_exclude=>'/ROW/A_COLUMN,\\//Some_Col'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected, a_exclude=>'/ROW/A_COLUMN,\\//Some_Col'); --Assert l_expected_message := q'[Actual: refcursor [ count = 3 ] was expected to equal: refcursor [ count = 3 ] %Diff: @@ -536,7 +536,7 @@ create or replace package body test_expectations_cursor is open l_actual for select 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual; open l_expected for select 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected, a_exclude=>'/ROW/A_COLUMN|/ROW/Some_Col'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected, a_exclude=>'/ROW/A_COLUMN|/ROW/Some_Col'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -550,7 +550,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'c' as A_COLUMN from dual a connect by level < 4; open l_expected for select rownum as rn, 'd' as A_COLUMN from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected, a_exclude=>ut3.ut_varchar2_list('A_COLUMN','non_existing_column')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected, a_exclude=>ut3_develop.ut_varchar2_list('A_COLUMN','non_existing_column')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -564,7 +564,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).include(ut3.ut_varchar2_list('RN','//A_Column','SOME_COL')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include(ut3_develop.ut_varchar2_list('RN','//A_Column','SOME_COL')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -578,7 +578,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).include('RN,//A_Column, SOME_COL'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include('RN,//A_Column, SOME_COL'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -592,7 +592,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).include('/ROW/RN|//A_Column|//SOME_COL'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include('/ROW/RN|//A_Column|//SOME_COL'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -606,7 +606,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'c' as A_COLUMN from dual a connect by level < 4; open l_expected for select rownum as rn, 'd' as A_COLUMN from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).include(ut3.ut_varchar2_list(' RN ',' non_existing_column ')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include(ut3_develop.ut_varchar2_list(' RN ',' non_existing_column ')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -620,7 +620,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).exclude('Some_Col').include('/ROW/RN|//Some_Col'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).exclude('Some_Col').include('/ROW/RN|//Some_Col'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -634,7 +634,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).exclude(ut3.ut_varchar2_list('A_COLUMN')).include(ut3.ut_varchar2_list('RN','A_Column','A_COLUMN')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).exclude(ut3_develop.ut_varchar2_list('A_COLUMN')).include(ut3_develop.ut_varchar2_list('RN','A_Column','A_COLUMN')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -650,7 +650,7 @@ create or replace package body test_expectations_cursor is open l_actual for select 1 rn from dual union all select 6 rn from dual; open l_expected for select rownum rn from dual connect by level <=3; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); l_expected_message := q'[Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 3 ] Diff: @@ -673,7 +673,7 @@ Rows: [ 2 differences ] open l_actual for select cast('a' as char(1)) a_column, 1 as id from dual; open l_expected for select cast('a' as varchar2(10)) a_column from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); l_expected_message := q'[Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ] Diff: Columns: @@ -695,7 +695,7 @@ Rows: [ 1 differences ] open l_actual for select to_char(rownum) rn, rownum another_rn from dual connect by level <=2; open l_expected for select rownum rn, rownum another_rn from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); l_expected_message := q'[Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ] Diff: @@ -718,7 +718,7 @@ Rows: [ all different ] open l_actual for select rownum rn, rownum bad_column_name from dual connect by level <=2; open l_expected for select rownum rn, rownum expected_column_name from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); l_expected_message := q'[Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ] Diff: @@ -740,7 +740,7 @@ Columns:% open l_actual for select rownum+1 col_1, rownum+2 col_2, rownum+3 col_3, rownum+4 col_4 from dual connect by level <=2; open l_expected for select rownum+1 col_1, rownum+4 col_4, rownum+2 col_2, rownum+3 col_3 from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); l_expected_message := q'[Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ] Diff: @@ -765,7 +765,7 @@ Rows: [ all different ] open l_actual for select rownum+1 col_1, rownum+2 col_2, rownum+3 col_3, rownum+4 col_4 from dual connect by level <=2; open l_expected for select rownum+1 col_1, rownum+4 col_4, rownum+2 col_2, rownum+3 col_3 from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).unordered_columns; + ut3_develop.ut.expect(l_actual).to_equal(l_expected).unordered_columns; ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -781,7 +781,7 @@ Rows: [ all different ] open l_actual for select rownum good_col, -rownum bad_col from dual connect by level <=2; open l_expected for select rownum good_col, rownum bad_col from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); l_expected_message := q'[Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ] Diff: @@ -809,7 +809,7 @@ Rows: [ 2 differences ] from dual connect by level <=100; open l_expected for select rownum bad_col, rownum good_col from dual connect by level <=110; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); l_expected_message := q'[Actual: refcursor [ count = 100 ] was expected to equal: refcursor [ count = 110 ] Diff: @@ -849,7 +849,7 @@ Rows: [ 60 differences, showing first 20 ] select 'F' AS GENDER, 'JESSICA' as FIRST_NAME, 'JONES' AS LAST_NAME, 4 as ID, '2345' AS SALARY from dual union all select 'M' AS GENDER, 'LUKE' as FIRST_NAME, 'SKYWALKER' AS LAST_NAME, 2 as ID, '1000' AS SALARY from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); l_expected_message := q'[Actual: refcursor [ count = 4 ] was expected to equal: refcursor [ count = 3 ] Diff: Columns: @@ -886,7 +886,7 @@ Rows: [ 4 differences ] select 'F' AS GENDER, 'JESSICA' as FIRST_NAME, 'JONES' AS LAST_NAME, 4 as ID, '2345' AS SALARY from dual union all select 'M' AS GENDER, 'LUKE' as FIRST_NAME, 'SKYWALKER' AS LAST_NAME, 2 as ID, '1000' AS SALARY from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).unordered_columns; + ut3_develop.ut.expect(l_actual).to_equal(l_expected).unordered_columns; l_expected_message := q'[Actual: refcursor [ count = 4 ] was expected to equal: refcursor [ count = 3 ] Diff: Columns: @@ -956,7 +956,7 @@ Rows: [ 4 differences ] from dual; open l_actual for q'[select * from test_table_for_cursors]'; --Act - ut3.ut.expect(l_expected).to_equal(l_actual); + ut3_develop.ut.expect(l_expected).to_equal(l_actual); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -968,7 +968,7 @@ Rows: [ 4 differences ] --Arrange open l_actual for select 1 as value from dual; --Act - ut3.ut.expect(l_actual).to_be_empty(); + ut3_develop.ut.expect(l_actual).to_be_empty(); --Assert ut.expect(l_actual%isopen).to_be_false(); end; @@ -981,7 +981,7 @@ Rows: [ 4 differences ] open l_actual for select 1/0 as value from dual; --Act begin - ut3.ut.expect(l_actual).to_be_empty(); + ut3_develop.ut.expect(l_actual).to_be_empty(); exception when others then null; @@ -996,7 +996,7 @@ Rows: [ 4 differences ] begin --Act open l_actual for select 1/0 as error_column from dual connect by level < 10; - ut3.ut.expect(l_actual).to_be_empty(); + ut3_develop.ut.expect(l_actual).to_be_empty(); ut.fail('Expected exception on cursor fetch'); exception @@ -1014,7 +1014,7 @@ Rows: [ 4 differences ] open l_actual for select * from dual; close l_actual; --Act - ut3.ut.expect( l_actual ).not_to_be_null; + ut3_develop.ut.expect( l_actual ).not_to_be_null; exception when others then --Assert @@ -1030,7 +1030,7 @@ Rows: [ 4 differences ] open l_actual for select rownum object_name from dual connect by level <=1100; open l_expected for select rownum object_name from dual connect by level <=1100; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -1046,7 +1046,7 @@ Rows: [ 4 differences ] procedure deprec_to_equal_excl_varch is begin --Act - ut3.ut.expect(get_cursor()).to_equal(get_cursor(), a_exclude => 'A_COLUMN,Some_Col'); + ut3_develop.ut.expect(get_cursor()).to_equal(get_cursor(), a_exclude => 'A_COLUMN,Some_Col'); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -1055,7 +1055,7 @@ Rows: [ 4 differences ] procedure deprec_to_equal_excl_list is begin --Act - ut3.ut.expect(get_cursor()).to_equal(get_cursor(), a_exclude => ut3.ut_varchar2_list('A_COLUMN','Some_Col')); + ut3_develop.ut.expect(get_cursor()).to_equal(get_cursor(), a_exclude => ut3_develop.ut_varchar2_list('A_COLUMN','Some_Col')); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -1064,7 +1064,7 @@ Rows: [ 4 differences ] procedure deprec_not_to_equal_excl_varch is begin --Act - ut3.ut.expect(get_cursor()).not_to_equal(get_cursor(), a_exclude => 'A_COLUMN,Some_Col'); + ut3_develop.ut.expect(get_cursor()).not_to_equal(get_cursor(), a_exclude => 'A_COLUMN,Some_Col'); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -1073,7 +1073,7 @@ Rows: [ 4 differences ] procedure deprec_not_to_equal_excl_list is begin --Act - ut3.ut.expect(get_cursor()).not_to_equal(get_cursor(), a_exclude => ut3.ut_varchar2_list('A_COLUMN','Some_Col')); + ut3_develop.ut.expect(get_cursor()).not_to_equal(get_cursor(), a_exclude => ut3_develop.ut_varchar2_list('A_COLUMN','Some_Col')); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -1082,7 +1082,7 @@ Rows: [ 4 differences ] procedure deprec_equal_excl_varch is begin --Act - ut3.ut.expect(get_cursor()).to_(ut3.equal(get_cursor(), a_exclude => 'A_COLUMN,Some_Col')); + ut3_develop.ut.expect(get_cursor()).to_(ut3_develop.equal(get_cursor(), a_exclude => 'A_COLUMN,Some_Col')); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -1091,7 +1091,7 @@ Rows: [ 4 differences ] procedure deprec_equal_excl_list is begin --Act - ut3.ut.expect(get_cursor()).to_(ut3.equal(get_cursor(), a_exclude => ut3.ut_varchar2_list('A_COLUMN','Some_Col'))); + ut3_develop.ut.expect(get_cursor()).to_(ut3_develop.equal(get_cursor(), a_exclude => ut3_develop.ut_varchar2_list('A_COLUMN','Some_Col'))); --Assert ut.expect(cardinality(ut3_tester_helper.main_helper.get_warnings())).to_equal(1); ut.expect(ut3_tester_helper.main_helper.get_warnings()(1)).to_be_like('The syntax: "%" is deprecated.%'); @@ -1107,7 +1107,7 @@ Rows: [ 4 differences ] open l_actual for select '1' , '2' from dual connect by level <=2; open l_expected for select rownum , rownum expected_column_name from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ] %Diff: @@ -1133,7 +1133,7 @@ Rows: [ 4 differences ] open l_actual for select '1' , rownum from dual connect by level <=2; open l_expected for select '1' , rownum from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1146,7 +1146,7 @@ Rows: [ 4 differences ] open l_actual for select username , user_id from all_users order by username asc; open l_expected for select username , user_id from all_users order by username desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).unordered; + ut3_develop.ut.expect(l_actual).to_equal(l_expected).unordered; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1159,7 +1159,7 @@ Rows: [ 4 differences ] open l_actual for select user_id, username from all_users order by username asc; open l_expected for select username , user_id from all_users order by username desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).unordered().uc(); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).unordered().uc(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1181,7 +1181,7 @@ Rows: [ 4 differences ] select 'test' username,-667 user_id from dual order by 1 desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).unordered; + ut3_develop.ut.expect(l_actual).to_equal(l_expected).unordered; l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ]% %Diff:% %Rows: [ 2 differences ]% @@ -1201,7 +1201,7 @@ Rows: [ 4 differences ] open l_expected for select object_id, owner, object_name,object_type from all_objects where owner = user; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('OBJECT_ID').uc(); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('OBJECT_ID').uc(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1215,7 +1215,7 @@ Rows: [ 4 differences ] open l_expected for select object_id, owner, object_name,object_type from all_objects where owner = user; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('OBJECT_ID'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('OBJECT_ID'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1231,7 +1231,7 @@ Rows: [ 4 differences ] open l_expected for select 1 as col_1, 2 as col_2,3 as col_3, 4 as col_4,5 col_5 from dual; open l_actual for select 2 as col_2, 1 as col_1,40 as col_4, 5 as col_5, 30 col_3 from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ).join_by('COL_1').unordered_columns; + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ).join_by('COL_1').unordered_columns; --Assert l_expected_message := q'[Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ] %Diff: @@ -1252,7 +1252,7 @@ Rows: [ 4 differences ] open l_expected for select object_id, owner, object_name,object_type from all_objects where owner = user; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by(ut3.ut_varchar2_list('OBJECT_ID,OBJECT_NAME')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by(ut3_develop.ut_varchar2_list('OBJECT_ID,OBJECT_NAME')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1268,7 +1268,7 @@ Rows: [ 4 differences ] open l_expected for select rownum as rn, 'x' SOME_COL from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('OWNER'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('OWNER'); --Assert l_expected_message := q'[%Actual: refcursor [ count = 3 ] was expected to equal: refcursor [ count = 3 ]% Diff:% @@ -1291,7 +1291,7 @@ Diff:% open l_expected for select rownum as rn, 'x' SOME_COL from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by(ut3.ut_varchar2_list('OWNER,USER_ID')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by(ut3_develop.ut_varchar2_list('OWNER,USER_ID')); --Assert l_expected_message := q'[%Actual: refcursor [ count = 3 ] was expected to equal: refcursor [ count = 3 ]% Diff:% @@ -1316,7 +1316,7 @@ Diff:% open l_expected for select rownum as rn, 'x' SOME_COL from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('SOME_COL').exclude('SOME_COL'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('SOME_COL').exclude('SOME_COL'); --Assert l_expected_message := q'[%Actual: refcursor [ count = 3 ] was expected to equal: refcursor [ count = 3 ]% Diff:% @@ -1339,7 +1339,7 @@ Diff:% open l_expected for select rownum as rn, 'x' SOME_COL from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by(ut3.ut_varchar2_list('RN,SOME_COL')).exclude('RN'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by(ut3_develop.ut_varchar2_list('RN,SOME_COL')).exclude('RN'); --Assert l_expected_message := q'[%Actual: refcursor [ count = 3 ] was expected to equal: refcursor [ count = 3 ]% Diff:% @@ -1362,7 +1362,7 @@ Diff:% open l_expected for select rownum as rn, 'x' SOME_COL from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('RNI'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('RNI'); --Assert l_expected_message := q'[%Actual: refcursor [ count = 3 ] was expected to equal: refcursor [ count = 3 ]% Diff:% @@ -1384,7 +1384,7 @@ Diff:% open l_expected for select rownum as rni, 'x' SOME_COL from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('RNI'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('RNI'); --Assert l_expected_message := q'[%Actual: refcursor [ count = 3 ] was expected to equal: refcursor [ count = 3 ]% Diff:% @@ -1403,7 +1403,7 @@ Diff:% open l_actual for select level object_id, level || '_TEST' object_name from dual connect by level <=1100; open l_expected for select level object_id, level || '_TEST' object_name from dual connect by level <=1100; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('OBJECT_ID'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('OBJECT_ID'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1416,7 +1416,7 @@ Diff:% open l_actual for select level object_id, level || '_TEST' object_name from dual connect by level <=1100; open l_expected for select level object_id, level || '_TEST' object_name from dual connect by level <=1100; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).unordered; + ut3_develop.ut.expect(l_actual).to_equal(l_expected).unordered; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1435,7 +1435,7 @@ Diff:% select 'TEST' username, -610 user_id from dual order by 1 asc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('USERNAME'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('USERNAME'); --Assert l_expected_message := q'[%Actual: refcursor [ count = % ] was expected to equal: refcursor [ count = % ] %Diff:% @@ -1461,7 +1461,7 @@ Diff:% select 'TEST' username, -610 user_id from dual order by 1 asc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by(ut3.ut_varchar2_list('USERNAME,USER_ID')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by(ut3_develop.ut_varchar2_list('USERNAME,USER_ID')); --Assert l_expected_message := q'[%Actual: refcursor [ count = % ] was expected to equal: refcursor [ count = % ] %Diff:% @@ -1487,7 +1487,7 @@ Diff:% select 'TEST' username, -610 user_id,'Y' is_valid from dual order by 1 asc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by(ut3.ut_varchar2_list('USERNAME,IS_VALID')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by(ut3_develop.ut_varchar2_list('USERNAME,IS_VALID')); --Assert l_expected_message := q'[%Actual: refcursor [ count = % ] was expected to equal: refcursor [ count = % ] %Diff:% @@ -1508,7 +1508,7 @@ Diff:% open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).include(ut3.ut_varchar2_list('RN','//A_Column','SOME_COL')).unordered; + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include(ut3_develop.ut_varchar2_list('RN','//A_Column','SOME_COL')).unordered; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1522,7 +1522,7 @@ Diff:% open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).include(ut3.ut_varchar2_list('RN','//A_Column','SOME_COL')).join_by('RN'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include(ut3_develop.ut_varchar2_list('RN','//A_Column','SOME_COL')).join_by('RN'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1536,7 +1536,7 @@ Diff:% open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).exclude(ut3.ut_varchar2_list('//Some_Col','A_COLUMN')).join_by('RN'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).exclude(ut3_develop.ut_varchar2_list('//Some_Col','A_COLUMN')).join_by('RN'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1550,7 +1550,7 @@ Diff:% open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).exclude(ut3.ut_varchar2_list('A_COLUMN|//Some_Col')).unordered; + ut3_develop.ut.expect(l_actual).to_equal(l_expected).exclude(ut3_develop.ut_varchar2_list('A_COLUMN|//Some_Col')).unordered; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1564,7 +1564,7 @@ Diff:% open l_actual for select rownum as rn, 'TEST' as A_COLUMN from dual a connect by level < 4; open l_expected for select rownum as rn, 1 as A_COLUMN from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).exclude(ut3.ut_varchar2_list('A_COLUMN')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).exclude(ut3_develop.ut_varchar2_list('A_COLUMN')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1578,7 +1578,7 @@ Diff:% open l_actual for select rownum as rn, 'TEST' as A_COLUMN from dual a connect by level < 4; open l_expected for select rownum as rn, 1 as A_COLUMN from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).include(ut3.ut_varchar2_list('RN')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include(ut3_develop.ut_varchar2_list('RN')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1592,7 +1592,7 @@ Diff:% open l_actual for select rownum as rn, 'TEST' as A_COLUMN from dual a connect by level < 4; open l_expected for select rownum as rn, 1 as A_COLUMN from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).include(ut3.ut_varchar2_list('RN')).exclude(ut3.ut_varchar2_list('A_COLUMN')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include(ut3_develop.ut_varchar2_list('RN')).exclude(ut3_develop.ut_varchar2_list('A_COLUMN')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1609,7 +1609,7 @@ Diff:% from dual connect by level <=2 order by rownum desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).unordered; + ut3_develop.ut.expect(l_actual).to_equal(l_expected).unordered; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1626,7 +1626,7 @@ Diff:% from dual connect by level <=2 order by rownum desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('COLVAL/ID'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('COLVAL/ID'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1645,7 +1645,7 @@ Diff:% from dual connect by level <=3 order by rownum desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).unordered; + ut3_develop.ut.expect(l_actual).to_equal(l_expected).unordered; l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 3 ]% Diff:% Rows: [ 5 differences% @@ -1671,7 +1671,7 @@ Rows: [ 5 differences% from dual connect by level <=2 order by rownum desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('COLVAL/ID'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('COLVAL/ID'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -1688,7 +1688,7 @@ Rows: [ 5 differences% from dual connect by level <=2 order by rownum desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by(ut3.ut_varchar2_list('RN,COLVAL/ID')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by(ut3_develop.ut_varchar2_list('RN,COLVAL/ID')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1707,7 +1707,7 @@ Rows: [ 5 differences% from dual connect by level <=2 order by rownum desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('COLVAL/IDS'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('COLVAL/IDS'); l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ]% Diff:% @@ -1722,16 +1722,16 @@ Diff:% procedure compare_nest_tab_col_jb is l_actual sys_refcursor; l_expected sys_refcursor; - l_actual_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); - l_expected_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); + l_actual_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); + l_expected_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); l_expected_message varchar2(32767); l_actual_message varchar2(32767); begin - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_actual_tab from dual connect by level <=2; - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_expected_tab from dual connect by level <=2; @@ -1743,7 +1743,7 @@ Diff:% from table(l_expected_tab) order by 1 desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('KEY'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('KEY'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -1752,16 +1752,16 @@ Diff:% procedure compare_nest_tab_col_jb_fail is l_actual sys_refcursor; l_expected sys_refcursor; - l_actual_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); - l_expected_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); + l_actual_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); + l_expected_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); l_expected_message varchar2(32767); l_actual_message varchar2(32767); begin - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_actual_tab from dual connect by level <=2; - select ut3.ut_key_value_pair(rownum,'Somethings '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Somethings '||rownum) bulk collect into l_expected_tab from dual connect by level <=2; @@ -1773,7 +1773,7 @@ Diff:% from table(l_expected_tab) order by 1 desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('KEY'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('KEY'); l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ]% %Diff:% %Rows: [ 2 differences ]% @@ -1789,16 +1789,16 @@ Diff:% procedure compare_nest_tab_cols_jb is l_actual sys_refcursor; l_expected sys_refcursor; - l_actual_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); - l_expected_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); + l_actual_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); + l_expected_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); l_expected_message varchar2(32767); l_actual_message varchar2(32767); begin - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_actual_tab from dual connect by level <=2; - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_expected_tab from dual connect by level <=2; @@ -1810,7 +1810,7 @@ Diff:% from table(l_expected_tab) order by 1 desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by(ut3.ut_varchar2_list('KEY,VALUE')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by(ut3_develop.ut_varchar2_list('KEY,VALUE')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -1819,16 +1819,16 @@ Diff:% procedure compare_nest_tab_cols_jb_fail is l_actual sys_refcursor; l_expected sys_refcursor; - l_actual_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); - l_expected_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); + l_actual_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); + l_expected_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); l_expected_message varchar2(32767); l_actual_message varchar2(32767); begin - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_actual_tab from dual connect by level <=2; - select ut3.ut_key_value_pair(rownum,'Somethings '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Somethings '||rownum) bulk collect into l_expected_tab from dual connect by level <=2; @@ -1840,7 +1840,7 @@ Diff:% from table(l_expected_tab) order by 1 desc; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by(ut3.ut_varchar2_list('KEY,VALUE')); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by(ut3_develop.ut_varchar2_list('KEY,VALUE')); l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ]% %Diff:% %Rows: [ 4 differences ]% @@ -1856,16 +1856,16 @@ Diff:% procedure compare_tabtype_as_cols_jb is l_actual sys_refcursor; l_expected sys_refcursor; - l_actual_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); - l_expected_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); + l_actual_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); + l_expected_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); l_expected_message varchar2(32767); l_actual_message varchar2(32767); begin - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_actual_tab from dual connect by level <=2; - select ut3.ut_key_value_pair(rownum,'Somethings '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Somethings '||rownum) bulk collect into l_expected_tab from dual connect by level <=2; @@ -1877,7 +1877,7 @@ Diff:% from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE'); --Assert l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ]% @@ -1896,16 +1896,16 @@ Diff:% procedure compare_tabtype_as_cols is l_actual sys_refcursor; l_expected sys_refcursor; - l_actual_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); - l_expected_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); + l_actual_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); + l_expected_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); l_expected_message varchar2(32767); l_actual_message varchar2(32767); begin - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_actual_tab from dual connect by level <=2 order by rownum asc; - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_expected_tab from dual connect by level <=2 order by rownum asc; @@ -1917,7 +1917,7 @@ Diff:% from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -1926,16 +1926,16 @@ Diff:% procedure compare_tabtype_as_cols_coll is l_actual sys_refcursor; l_expected sys_refcursor; - l_actual_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); - l_expected_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); + l_actual_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); + l_expected_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); l_expected_message varchar2(32767); l_actual_message varchar2(32767); begin - select ut3.ut_key_value_pair(rownum,'Apples '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Apples '||rownum) bulk collect into l_actual_tab from dual connect by level <=2; - select ut3.ut_key_value_pair(rownum,'Peaches '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Peaches '||rownum) bulk collect into l_expected_tab from dual connect by level <=2; @@ -1947,7 +1947,7 @@ Diff:% from dual connect by level <=2; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/UT_KEY_VALUE_PAIRS'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/UT_KEY_VALUE_PAIRS'); --Assert l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 2 ] @@ -1981,7 +1981,7 @@ Diff:% open l_expected for select l_expected_tab as nested_table from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -2005,7 +2005,7 @@ Diff:% open l_expected for select l_expected_tab as nested_table from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/OBJECT_OWNER'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/OBJECT_OWNER'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -2029,7 +2029,7 @@ Diff:% open l_expected for select l_expected_tab as nested_table from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/ITEMS'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/ITEMS'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -2057,7 +2057,7 @@ Diff:% from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/OBJECT_OWNER'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/OBJECT_OWNER'); --Assert l_expected_message := q'[%Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ] @@ -2090,7 +2090,7 @@ Diff:% open l_expected for select l_expected_tab as nested_table from dual; --Act - ut3.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/ITEMS/ID'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('NESTED_TABLE/ITEMS/ID'); --Assert l_expected_message := q'[%Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ]% @@ -2124,7 +2124,7 @@ Diff:% select 'Table' as name from dual; --Assert - ut3.ut.expect( l_actual ).to_equal( l_expected ).unordered(); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ).unordered(); --Assert l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to equal: refcursor [ count = 3 ] @@ -2148,7 +2148,7 @@ Diff:% and rownum < 20; --Act - ut3.ut.expect(l_actual).to_contain(l_expected); + ut3_develop.ut.expect(l_actual).to_contain(l_expected); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2164,7 +2164,7 @@ Diff:% and rownum < 20; --Act - ut3.ut.expect(l_actual).to_contain(l_expected).uc(); + ut3_develop.ut.expect(l_actual).to_contain(l_expected).uc(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2181,7 +2181,7 @@ Diff:% select rownum owner, rownum||'name' object_name,'PACKAGE' object_type from dual connect by level < 10; --Act - ut3.ut.expect(l_actual).to_contain(l_expected).unordered(); + ut3_develop.ut.expect(l_actual).to_contain(l_expected).unordered(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2197,7 +2197,7 @@ Diff:% open l_expected for select rownum owner,rownum object_name, 'PACKAGE' object_type from dual connect by level < 10; --Act - ut3.ut.expect(l_actual).to_contain(l_expected); + ut3_develop.ut.expect(l_actual).to_contain(l_expected); --Assert l_expected_message := q'[%Actual: refcursor [ count = 4 ] was expected to contain: refcursor [ count = 9 ] %Diff: @@ -2221,7 +2221,7 @@ Diff:% open l_expected for select username ,user_id from all_users where rownum < 5; --Act - ut3.ut.expect(l_actual).to_contain(l_expected).join_by('USERNAME'); + ut3_develop.ut.expect(l_actual).to_contain(l_expected).join_by('USERNAME'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2243,7 +2243,7 @@ Diff:% order by 1 asc; --Act - ut3.ut.expect(l_actual).to_contain(l_expected).join_by('USERNAME'); + ut3_develop.ut.expect(l_actual).to_contain(l_expected).join_by('USERNAME'); --Assert l_expected_message := q'[%Actual: refcursor [ count = % ] was expected to contain: refcursor [ count = % ] %Diff: @@ -2265,7 +2265,7 @@ Diff:% open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 6; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_contain(l_expected).include(ut3.ut_varchar2_list('RN','//A_Column','SOME_COL')); + ut3_develop.ut.expect(l_actual).to_contain(l_expected).include(ut3_develop.ut_varchar2_list('RN','//A_Column','SOME_COL')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2279,7 +2279,7 @@ Diff:% open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 10; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_contain(l_expected).include(ut3.ut_varchar2_list('RN','//A_Column','SOME_COL')).join_by('RN'); + ut3_develop.ut.expect(l_actual).to_contain(l_expected).include(ut3_develop.ut_varchar2_list('RN','//A_Column','SOME_COL')).join_by('RN'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2293,7 +2293,7 @@ Diff:% open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 10; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_contain(l_expected).exclude(ut3.ut_varchar2_list('//Some_Col','A_COLUMN')).join_by('RN'); + ut3_develop.ut.expect(l_actual).to_contain(l_expected).exclude(ut3_develop.ut_varchar2_list('//Some_Col','A_COLUMN')).join_by('RN'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2307,7 +2307,7 @@ Diff:% open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 10; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_contain(l_expected).exclude(ut3.ut_varchar2_list('A_COLUMN|//Some_Col')); + ut3_develop.ut.expect(l_actual).to_contain(l_expected).exclude(ut3_develop.ut_varchar2_list('A_COLUMN|//Some_Col')); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2324,7 +2324,7 @@ Diff:% select 'TEST1' username, -601 user_id from dual; --Act - ut3.ut.expect(l_actual).not_to_contain(l_expected); + ut3_develop.ut.expect(l_actual).not_to_contain(l_expected); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2343,7 +2343,7 @@ Diff:% select 'TEST' username, -600 user_id from dual; --Act - ut3.ut.expect(l_actual).not_to_contain(l_expected); + ut3_develop.ut.expect(l_actual).not_to_contain(l_expected); --Assert l_expected_message := q'[%Actual: (refcursor [ count = % ])% %Data-types:% @@ -2368,7 +2368,7 @@ Diff:% open l_expected for select username||to_char(rownum) username ,rownum user_id from all_users where rownum < 5; --Act - ut3.ut.expect(l_actual).not_to_contain(l_expected).join_by('USER_ID'); + ut3_develop.ut.expect(l_actual).not_to_contain(l_expected).join_by('USER_ID'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2381,7 +2381,7 @@ Diff:% open l_actual for select rownum as rn, 'b' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 10; open l_expected for select rownum * 20 rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).not_to_contain(l_expected).include(ut3.ut_varchar2_list('RN','//A_Column','SOME_COL')).join_by('RN'); + ut3_develop.ut.expect(l_actual).not_to_contain(l_expected).include(ut3_develop.ut_varchar2_list('RN','//A_Column','SOME_COL')).join_by('RN'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2394,7 +2394,7 @@ Diff:% open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'y' SOME_COL, 'd' "Some_Col" from dual a connect by level < 10; open l_expected for select rownum * 20 as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).not_to_contain(l_expected).exclude(ut3.ut_varchar2_list('//Some_Col','A_COLUMN')).join_by('RN'); + ut3_develop.ut.expect(l_actual).not_to_contain(l_expected).exclude(ut3_develop.ut_varchar2_list('//Some_Col','A_COLUMN')).join_by('RN'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2410,7 +2410,7 @@ Diff:% open l_expected for select rownum as rn from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_contain(l_expected); + ut3_develop.ut.expect(l_actual).to_contain(l_expected); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2427,7 +2427,7 @@ Diff:% union all select rownum as rn from dual a connect by level < 4; --Act - ut3.ut.expect(l_actual).to_contain(l_expected); + ut3_develop.ut.expect(l_actual).to_contain(l_expected); --Assert l_expected_message := q'[%Actual: refcursor [ count = 9 ] was expected to contain: refcursor [ count = 6 ] %Diff: @@ -2443,11 +2443,11 @@ Diff:% procedure udt_messg_format_eq is l_actual sys_refcursor; l_expected sys_refcursor; - l_expected_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); + l_expected_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); l_expected_message varchar2(32767); l_actual_message varchar2(32767); begin - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_expected_tab from dual connect by level <=2; @@ -2456,7 +2456,7 @@ Diff:% open l_expected for select value(x) as udt from table(l_expected_tab) x; --Act - ut3.ut.expect(l_actual).to_contain(l_expected); + ut3_develop.ut.expect(l_actual).to_contain(l_expected); --Assert l_expected_message := q'[%Actual: refcursor [ count = 2 ] was expected to contain: refcursor [ count = 2 ] %Diff: @@ -2474,11 +2474,11 @@ Diff:% procedure udt_messg_format_empt is l_actual sys_refcursor; - l_actual_tab ut3.ut_key_value_pairs := ut3.ut_key_value_pairs(); + l_actual_tab ut3_develop.ut_key_value_pairs := ut3_develop.ut_key_value_pairs(); l_actual_message varchar2(32767); l_expected_message varchar2(32767); begin - select ut3.ut_key_value_pair(rownum,'Something '||rownum) + select ut3_develop.ut_key_value_pair(rownum,'Something '||rownum) bulk collect into l_actual_tab from dual connect by level <=2; @@ -2486,7 +2486,7 @@ Diff:% open l_actual for select value(x) as udt from table(l_actual_tab) x; --Act - ut3.ut.expect(l_actual).to_be_empty(); + ut3_develop.ut.expect(l_actual).to_be_empty(); --Assert l_expected_message := q'[%Actual: (refcursor [ count = 2 ]) %Data-types: @@ -2507,7 +2507,7 @@ Diff:% begin l_exp_message :='ORA-20218: SQL exception thrown when fetching data from cursor: ORA-01476: divisor is equal to zero -at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line % ut3.ut.expect(l_actual).to_equal(l_expected);% +at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line % ut3_develop.ut.expect(l_actual).to_equal(l_expected);% Check the query and data for errors.'; open l_actual for @@ -2515,7 +2515,7 @@ Check the query and data for errors.'; open l_expected for select 1/0 as test from dual; - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); --Line that error relates to in expected messag ut.fail('Expected exception on cursor fetch'); @@ -2532,7 +2532,7 @@ Check the query and data for errors.'; l_exp_message :='ORA-20218: SQL exception thrown when fetching data from cursor: ORA-01476: divisor is equal to zero -at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line % ut3.ut.expect(l_actual).to_equal(l_expected);% +at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line % ut3_develop.ut.expect(l_actual).to_equal(l_expected);% Check the query and data for errors.'; open l_expected for @@ -2540,7 +2540,7 @@ Check the query and data for errors.'; open l_actual for select 1 as test from dual; - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); ut.fail('Expected exception on cursor fetch'); exception @@ -2552,7 +2552,7 @@ Check the query and data for errors.'; l_actual sys_refcursor; l_expected sys_refcursor; begin - ut3.ut.set_nls; + ut3_develop.ut.set_nls; open l_expected for select cast(3.14 as binary_double) as pi_double, cast(3.14 as binary_float) as pi_float, @@ -2569,10 +2569,10 @@ Check the query and data for errors.'; numtoyminterval(1.1, 'year') row_ym_interval from dual; --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); - ut3.ut.reset_nls; + ut3_develop.ut.reset_nls; end; @@ -2597,7 +2597,7 @@ Check the query and data for errors.'; OPEN l_exp_cur FOR SELECT l_exp.key, l_exp.value FROM dual; - ut3.ut.expect(l_act_cur).to_equal(l_exp_cur); + ut3_develop.ut.expect(l_act_cur).to_equal(l_exp_cur); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2613,7 +2613,7 @@ Check the query and data for errors.'; OPEN l_exp_cur FOR SELECT 1 as "$Test", 2 as "&Test" FROM dual; - ut3.ut.expect(l_act_cur).to_equal(l_exp_cur); + ut3_develop.ut.expect(l_act_cur).to_equal(l_exp_cur); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2629,7 +2629,7 @@ Check the query and data for errors.'; OPEN l_exp_cur FOR SELECT 1 as "", 2 as "_Test", 3 as ".Test>" FROM dual; - ut3.ut.expect(l_act_cur).to_equal(l_exp_cur); + ut3_develop.ut.expect(l_act_cur).to_equal(l_exp_cur); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2645,7 +2645,7 @@ Check the query and data for errors.'; open l_actual for select column_value t1 from table(ut_varchar2_list(' ')); --Assert - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -2659,7 +2659,7 @@ Check the query and data for errors.'; open l_actual for select column_value t1 from table(ut_varchar2_list(chr(9))); --Assert - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -2673,7 +2673,7 @@ Check the query and data for errors.'; open l_actual for select 't' t1 from dual; --Assert - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -2687,7 +2687,7 @@ Check the query and data for errors.'; open l_actual for select ' t ' t1 from dual; --Assert - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -2701,7 +2701,7 @@ Check the query and data for errors.'; open l_actual for select chr(9)||'t' t1 from dual; --Assert - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -2728,7 +2728,7 @@ Check the query and data for errors.'; 7456123.9 as n6, 7456123.89 as n7 from dual; - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2760,7 +2760,7 @@ Check the query and data for errors.'; ,-1 as col5 from dual; - ut3.ut.expect(l_actual).to_equal(a_expected => l_expected); + ut3_develop.ut.expect(l_actual).to_equal(a_expected => l_expected); l_expected_message := q'[%Actual: refcursor [ count = 1 ] was expected to equal: refcursor [ count = 1 ] %Diff: @@ -2783,7 +2783,7 @@ Check the query and data for errors.'; open v_actual for select 'ok' name, to_number(null) id from dual; - ut3.ut.expect(v_actual).to_equal(v_expected).exclude('ID'); + ut3_develop.ut.expect(v_actual).to_equal(v_expected).exclude('ID'); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2799,7 +2799,7 @@ Check the query and data for errors.'; open l_expected for select rownum as id, '1' some_column_with_a_pretty_long_enough_name from dual; - ut3.ut.expect(l_actual).to_equal(l_expected).include('ID,SOME_COLUMN_WITH_A_PRETTY_LONG_ENOUGH_NAME').join_by('ID'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include('ID,SOME_COLUMN_WITH_A_PRETTY_LONG_ENOUGH_NAME').join_by('ID'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); $else @@ -2816,9 +2816,9 @@ Check the query and data for errors.'; return l_result; end; begin - ut3.ut.expect(get_cursor()).to_equal(get_cursor()); - ut3.ut.expect(get_cursor()).to_equal(get_cursor()).unordered(); - ut3.ut.expect(get_cursor()).to_equal(get_cursor()).join_by('ITEM_DATA,DATA_ID,ITEM_NO,DUP_NO'); + ut3_develop.ut.expect(get_cursor()).to_equal(get_cursor()); + ut3_develop.ut.expect(get_cursor()).to_equal(get_cursor()).unordered(); + ut3_develop.ut.expect(get_cursor()).to_equal(get_cursor()).join_by('ITEM_DATA,DATA_ID,ITEM_NO,DUP_NO'); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -2829,10 +2829,10 @@ Check the query and data for errors.'; begin open l_actual for select rownum rn from dual connect by level < 5; open l_expected for select rownum rn from dual connect by level = 1; - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); open l_actual for select rownum rn from dual connect by level < 3; open l_expected for select * from (select rownum rn from dual connect by level < 3) order by 1 desc; - ut3.ut.expect(l_actual).to_equal(l_expected); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations(1)).to_equal( 'Actual: refcursor [ count = 4 ] was expected to equal: refcursor [ count = 1 ] Diff: diff --git a/test/ut3_user/expectations/test_expectations_json.pkb b/test/ut3_user/expectations/test_expectations_json.pkb index 6214d2237..670502c0d 100644 --- a/test/ut3_user/expectations/test_expectations_json.pkb +++ b/test/ut3_user/expectations/test_expectations_json.pkb @@ -49,7 +49,7 @@ create or replace package body test_expectations_json is }'); --Act - ut3.ut.expect( l_actual ).to_equal( l_actual ); + ut3_develop.ut.expect( l_actual ).to_equal( l_actual ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -66,7 +66,7 @@ create or replace package body test_expectations_json is l_actual := json_element_t.parse('{"Aidan Gillen": {"array": ["Game of Thron\"es","The Wire"],"string": "some string","int": 2,"aboolean": true, "boolean": true,"object": {"foo": "bar","object1": {"new prop1": "new prop value"},"object2": {"new prop1": "new prop value"},"object3": {"new prop1": "new prop value"},"object4": {"new prop1": "new prop value"}}},"Amy Ryan": {"one": "In Treatment","two": "The Wire"},"Annie Fitzgerald": ["Big Love","True Blood"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsgard": ["Generation Kill","True Blood"], "Clarke Peters": null}'); --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert l_expected_message := q'[%Diff: 20 differences found %3 incorrect types, 4 unequal values, 13 missing properties @@ -103,7 +103,7 @@ create or replace package body test_expectations_json is l_expected := cast (null as json_object_t ); --Act - ut3.ut.expect( l_expected ).to_be_null; + ut3_develop.ut.expect( l_expected ).to_be_null; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -116,7 +116,7 @@ create or replace package body test_expectations_json is l_expected := json_object_t(); --Act - ut3.ut.expect( l_expected ).not_to_be_null; + ut3_develop.ut.expect( l_expected ).not_to_be_null; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -131,7 +131,7 @@ create or replace package body test_expectations_json is l_expected := json_object_t('{ "t" : "1" }'); --Act - ut3.ut.expect( l_expected ).to_be_null; + ut3_develop.ut.expect( l_expected ).to_be_null; --Assert l_expected_message := q'[%Actual: (json) %'{"t":"1"}' @@ -151,7 +151,7 @@ create or replace package body test_expectations_json is l_expected := cast (null as json_object_t ); --Act - ut3.ut.expect( l_expected ).not_to_be_null; + ut3_develop.ut.expect( l_expected ).not_to_be_null; --Assert l_expected_message := q'[%Actual: NULL (json) was expected not to be null%]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -167,7 +167,7 @@ create or replace package body test_expectations_json is l_expected := json_object_t(); --Act - ut3.ut.expect( l_expected ).to_be_empty; + ut3_develop.ut.expect( l_expected ).to_be_empty; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -180,7 +180,7 @@ create or replace package body test_expectations_json is l_expected := json_object_t.parse('{ "name" : "test" }'); --Act - ut3.ut.expect( l_expected ).not_to_be_empty; + ut3_develop.ut.expect( l_expected ).not_to_be_empty; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -195,7 +195,7 @@ create or replace package body test_expectations_json is l_expected := json_object_t.parse('{ "name" : "test" }'); --Act - ut3.ut.expect( l_expected ).to_be_empty; + ut3_develop.ut.expect( l_expected ).to_be_empty; --Assert l_expected_message := q'[%Actual: (json) %'{"name":"test"}' @@ -215,7 +215,7 @@ create or replace package body test_expectations_json is l_expected := json_object_t(); --Act - ut3.ut.expect( l_expected ).not_to_be_empty; + ut3_develop.ut.expect( l_expected ).not_to_be_empty; --Assert l_expected_message := q'[%Actual: (json) %'{}' @@ -234,7 +234,7 @@ create or replace package body test_expectations_json is l_actual := json_element_t.parse('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); --Act - ut3.ut.expect( l_actual ).to_have_count( 6 ); + ut3_develop.ut.expect( l_actual ).to_have_count( 6 ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -251,7 +251,7 @@ create or replace package body test_expectations_json is l_actual := json_element_t.parse('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); --Act - ut3.ut.expect( l_actual ).to_have_count( 2 ); + ut3_develop.ut.expect( l_actual ).to_have_count( 2 ); --Assert l_expected_message := q'[%Actual: (json [ count = 6 ]) was expected to have [ count = 2 ]%]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -270,7 +270,7 @@ create or replace package body test_expectations_json is l_actual := json_element_t.parse('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); --Act - ut3.ut.expect( l_actual ).not_to_have_count( 7 ); + ut3_develop.ut.expect( l_actual ).not_to_have_count( 7 ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -285,7 +285,7 @@ create or replace package body test_expectations_json is l_actual := json_element_t.parse('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); --Act - ut3.ut.expect( l_actual ).not_to_have_count( 6 ); + ut3_develop.ut.expect( l_actual ).not_to_have_count( 6 ); --Assert l_expected_message := q'[%Actual: json [ count = 6 ] was expected not to have [ count = 6 ]%]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -303,7 +303,7 @@ create or replace package body test_expectations_json is l_actual := json_element_t.parse('["Game of Thrones","The Wire"]'); --Act - ut3.ut.expect( l_actual ).to_have_count( 2 ); + ut3_develop.ut.expect( l_actual ).to_have_count( 2 ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -371,7 +371,7 @@ create or replace package body test_expectations_json is --Act - ut3.ut.expect(json_array_t(json_query(l_actual.stringify,'$.Actors.children'))).to_equal(json_array_t(json_query(l_expected + ut3_develop.ut.expect(json_array_t(json_query(l_actual.stringify,'$.Actors.children'))).to_equal(json_array_t(json_query(l_expected .stringify,'$.Actors[1].children'))); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -442,7 +442,7 @@ create or replace package body test_expectations_json is --Act - ut3.ut.expect(json_array_t(json_query(l_actual.stringify,'$.Actors.children'))).to_equal(json_array_t(json_query(l_expected + ut3_develop.ut.expect(json_array_t(json_query(l_actual.stringify,'$.Actors.children'))).to_equal(json_array_t(json_query(l_expected .stringify,'$.Actors[1].children'))); --Assert l_expected_message := q'[%Actual: json was expected to equal: json @@ -732,7 +732,7 @@ create or replace package body test_expectations_json is ]'); --Act - ut3.ut.expect( l_actual ).to_equal( l_actual ); + ut3_develop.ut.expect( l_actual ).to_equal( l_actual ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -759,7 +759,7 @@ create or replace package body test_expectations_json is }'); --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1041,7 +1041,7 @@ create or replace package body test_expectations_json is ]'); --Act - ut3.ut.expect( l_actual ).to_equal( l_actual ); + ut3_develop.ut.expect( l_actual ).to_equal( l_actual ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1554,7 +1554,7 @@ create or replace package body test_expectations_json is ]'); --Act - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert l_expected_message := q'[%Diff: 133 differences found, showing first 20 %132 unequal values, 1 missing properties @@ -1590,7 +1590,7 @@ create or replace package body test_expectations_json is begin l_expected := json_object_t('{ "name" : "Bond", "proffesion" : "spy", "drink" : "martini"}'); l_actual := json_object_t('{ "proffesion" : "spy","name" : "Bond", "drink" : "martini"}'); - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -1600,7 +1600,7 @@ create or replace package body test_expectations_json is begin l_expected := json_array_t('[ {"name" : "Bond", "proffesion" : "spy", "drink" : "martini"} , {"name" : "Kloss", "proffesion" : "spy", "drink" : "beer"} ]'); l_actual := json_array_t('[ {"name" : "Bond", "proffesion" : "spy", "drink" : "martini"} , {"name" : "Kloss", "proffesion" : "spy", "drink" : "beer"} ]'); - ut3.ut.expect( l_actual ).to_equal( l_expected ); + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; diff --git a/test/ut3_user/expectations/test_matchers.pkb b/test/ut3_user/expectations/test_matchers.pkb index 88e25e8b1..e1d87d4cb 100644 --- a/test/ut3_user/expectations/test_matchers.pkb +++ b/test/ut3_user/expectations/test_matchers.pkb @@ -13,7 +13,7 @@ create or replace package body test_matchers is l_actual '||a_type||' := '||a_actual_value||'; l_expected '||a_type||' := '||a_expected_value||'; begin - ut3.ut.expect( l_actual ).'||a_prefix||'to_'||a_matcher||'( l_expected ); + ut3_develop.ut.expect( l_actual ).'||a_prefix||'to_'||a_matcher||'( l_expected ); end;'; execute immediate l_statement; if a_result = ut3_tester_helper.main_helper.gc_success then @@ -33,7 +33,7 @@ create or replace package body test_matchers is l_lower '||a_type||' := '||a_expected1_value||'; l_higher '||a_type||' := '||a_expected2_value||'; begin - ut3.ut.expect(l_actual_value).to_be_between(l_lower, l_higher); + ut3_develop.ut.expect(l_actual_value).to_be_between(l_lower, l_higher); end;'; execute immediate l_statement; if a_result = ut3_tester_helper.main_helper.gc_success then @@ -53,7 +53,7 @@ create or replace package body test_matchers is l_value1 '||a_type||' := '||a_expected1_value||'; l_value2 '||a_type||' := '||a_expected2_value||'; begin - ut3.ut.expect(l_actual_value).'||a_not_prefix||'to_be_between(l_value1, l_value2); + ut3_develop.ut.expect(l_actual_value).'||a_not_prefix||'to_be_between(l_value1, l_value2); end;'; execute immediate l_statement; if a_result = ut3_tester_helper.main_helper.gc_success then @@ -73,7 +73,7 @@ create or replace package body test_matchers is l_escape_char varchar2(32767) := :a_escape; l_result integer; begin - ut3.ut.expect( l_actual ).' || a_prefix ||q'[to_be_like(l_pattern, l_escape_char); + ut3_develop.ut.expect( l_actual ).' || a_prefix ||q'[to_be_like(l_pattern, l_escape_char); end;]' using a_pattern, a_escape; if a_result = ut3_tester_helper.main_helper.gc_success then @@ -94,7 +94,7 @@ create or replace package body test_matchers is l_modifiers varchar2(32767) := :a_modifiers; l_result integer; begin - ut3.ut.expect( l_actual ).'||a_not_prefix||'to_match(l_pattern, l_modifiers); + ut3_develop.ut.expect( l_actual ).'||a_not_prefix||'to_match(l_pattern, l_modifiers); end;'; execute immediate l_statement using a_pattern, a_modifiers; if a_result = ut3_tester_helper.main_helper.gc_success then @@ -245,8 +245,8 @@ create or replace package body test_matchers is l_value_lower timestamp := to_timestamp('1997-01-31 09:26:50.11','YYYY-MM-DD HH24.MI.SS.FF'); l_value_upper timestamp := to_timestamp('1997-01-31 09:26:50.14','YYYY-MM-DD HH24.MI.SS.FF'); begin - ut3.ut.expect(l_value).to_be_between(l_value_lower, l_value_upper); - ut3.ut.expect(l_value).not_to_be_between(l_value_upper, l_value_lower); + ut3_develop.ut.expect(l_value).to_be_between(l_value_lower, l_value_upper); + ut3_develop.ut.expect(l_value).not_to_be_between(l_value_upper, l_value_lower); end; procedure test_timestamp_ltz_between is @@ -254,8 +254,8 @@ create or replace package body test_matchers is l_value_lower timestamp with local time zone := to_timestamp_tz('1997-01-31 09:26:50.12 +03:00','YYYY-MM-DD HH24.MI.SS.FF TZR'); l_value_upper timestamp with local time zone := to_timestamp_tz('1997-01-31 09:26:50.12 +01:00','YYYY-MM-DD HH24.MI.SS.FF TZR'); begin - ut3.ut.expect(l_value).to_be_between(l_value_lower, l_value_upper); - ut3.ut.expect(l_value).not_to_be_between(l_value_upper, l_value_lower); + ut3_develop.ut.expect(l_value).to_be_between(l_value_lower, l_value_upper); + ut3_develop.ut.expect(l_value).not_to_be_between(l_value_upper, l_value_lower); end; procedure test_timestamp_tz_between is @@ -263,8 +263,8 @@ create or replace package body test_matchers is l_value_lower timestamp with time zone := to_timestamp_tz('1997-01-31 09:26:50.12 +03:00','YYYY-MM-DD HH24.MI.SS.FF TZR'); l_value_upper timestamp with time zone := to_timestamp_tz('1997-01-31 09:26:50.12 +01:00','YYYY-MM-DD HH24.MI.SS.FF TZR'); begin - ut3.ut.expect(l_value).to_be_between(l_value_lower, l_value_upper); - ut3.ut.expect(l_value).not_to_be_between(l_value_upper, l_value_lower); + ut3_develop.ut.expect(l_value).to_be_between(l_value_lower, l_value_upper); + ut3_develop.ut.expect(l_value).not_to_be_between(l_value_upper, l_value_lower); end; end test_matchers; diff --git a/test/ut3_user/expectations/unary/test_expect_to_be_empty.pkb b/test/ut3_user/expectations/unary/test_expect_to_be_empty.pkb index 1447bd1f0..931e24d10 100644 --- a/test/ut3_user/expectations/unary/test_expect_to_be_empty.pkb +++ b/test/ut3_user/expectations/unary/test_expect_to_be_empty.pkb @@ -10,7 +10,7 @@ create or replace package body test_expect_to_be_empty is --Arrange open l_cursor for select * from dual where 1 = 2; --Act - ut3.ut.expect(l_cursor).to_be_empty; + ut3_develop.ut.expect(l_cursor).to_be_empty; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -21,7 +21,7 @@ create or replace package body test_expect_to_be_empty is --Arrange open l_cursor for select * from dual; --Act - ut3.ut.expect(l_cursor).to_be_empty; + ut3_develop.ut.expect(l_cursor).to_be_empty; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -34,7 +34,7 @@ create or replace package body test_expect_to_be_empty is --Arrange open l_cursor for select * from dual; --Act - ut3.ut.expect(l_cursor).to_be_empty; + ut3_develop.ut.expect(l_cursor).to_be_empty; l_expected_message := q'[Actual: (refcursor [ count = 1 ])% X% @@ -51,7 +51,7 @@ create or replace package body test_expect_to_be_empty is --Arrange open l_cursor for select * from dual; --Act - ut3.ut.expect(l_cursor).not_to_be_empty; + ut3_develop.ut.expect(l_cursor).not_to_be_empty; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -62,7 +62,7 @@ create or replace package body test_expect_to_be_empty is --Arrange open l_cursor for select * from dual where 1 = 2; --Act - ut3.ut.expect(l_cursor).not_to_be_empty; + ut3_develop.ut.expect(l_cursor).not_to_be_empty; --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -73,7 +73,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertcollection(ora_mining_varchar2_nt()); -- Act - ut3.ut.expect(l_actual).to_be_empty(); + ut3_develop.ut.expect(l_actual).to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -84,7 +84,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertcollection(ora_mining_varchar2_nt('a')); -- Act - ut3.ut.expect(l_actual).to_be_empty(); + ut3_develop.ut.expect(l_actual).to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -95,7 +95,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertcollection(ora_mining_varchar2_nt('a')); -- Act - ut3.ut.expect(l_actual).not_to_be_empty(); + ut3_develop.ut.expect(l_actual).not_to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -106,7 +106,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertcollection(ora_mining_varchar2_nt()); -- Act - ut3.ut.expect(l_actual).not_to_be_empty(); + ut3_develop.ut.expect(l_actual).not_to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -118,7 +118,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertcollection(l_data); -- Act - ut3.ut.expect(l_actual).to_be_empty(); + ut3_develop.ut.expect(l_actual).to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -130,7 +130,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertcollection(l_data); -- Act - ut3.ut.expect(l_actual).not_to_be_empty(); + ut3_develop.ut.expect(l_actual).not_to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -141,7 +141,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertObject(ut3_tester_helper.test_dummy_number(1)); -- Act - ut3.ut.expect(l_actual).to_be_empty(); + ut3_develop.ut.expect(l_actual).to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -153,7 +153,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertObject(l_data); -- Act - ut3.ut.expect(l_actual).to_be_empty(); + ut3_develop.ut.expect(l_actual).to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -161,7 +161,7 @@ create or replace package body test_expect_to_be_empty is procedure fail_be_empty_number is begin -- Act - ut3.ut.expect( 1 ).to_( ut3.be_empty() ); + ut3_develop.ut.expect( 1 ).to_( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -176,7 +176,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertObject(ut3_tester_helper.test_dummy_number(1)); -- Act - ut3.ut.expect(l_actual).not_to_be_empty(); + ut3_develop.ut.expect(l_actual).not_to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -188,7 +188,7 @@ create or replace package body test_expect_to_be_empty is --Arrange l_actual := anydata.convertObject(l_data); -- Act - ut3.ut.expect(l_actual).not_to_be_empty(); + ut3_develop.ut.expect(l_actual).not_to_be_empty(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -196,7 +196,7 @@ create or replace package body test_expect_to_be_empty is procedure fail_not_be_empty_number is begin -- Act - ut3.ut.expect( 1 ).not_to( ut3.be_empty() ); + ut3_develop.ut.expect( 1 ).not_to( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -204,7 +204,7 @@ create or replace package body test_expect_to_be_empty is procedure success_be_empty_clob is begin -- Act - ut3.ut.expect( empty_clob() ).to_( ut3.be_empty() ); + ut3_develop.ut.expect( empty_clob() ).to_( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -212,7 +212,7 @@ create or replace package body test_expect_to_be_empty is procedure fail_be_empty_clob is begin -- Act - ut3.ut.expect( to_clob(' ') ).to_( ut3.be_empty() ); + ut3_develop.ut.expect( to_clob(' ') ).to_( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -220,7 +220,7 @@ create or replace package body test_expect_to_be_empty is procedure success_be_empty_blob is begin -- Act - ut3.ut.expect( empty_blob() ).to_( ut3.be_empty() ); + ut3_develop.ut.expect( empty_blob() ).to_( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -228,7 +228,7 @@ create or replace package body test_expect_to_be_empty is procedure fail_be_empty_blob is begin -- Act - ut3.ut.expect( to_blob('AA') ).to_( ut3.be_empty() ); + ut3_develop.ut.expect( to_blob('AA') ).to_( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -237,7 +237,7 @@ create or replace package body test_expect_to_be_empty is procedure fail_not_be_empty_clob is begin -- Act - ut3.ut.expect( empty_clob() ).not_to( ut3.be_empty() ); + ut3_develop.ut.expect( empty_clob() ).not_to( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -245,7 +245,7 @@ create or replace package body test_expect_to_be_empty is procedure success_not_be_empty_clob is begin -- Act - ut3.ut.expect( to_clob(' ') ).not_to( ut3.be_empty() ); + ut3_develop.ut.expect( to_clob(' ') ).not_to( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -253,7 +253,7 @@ create or replace package body test_expect_to_be_empty is procedure fail_not_be_empty_blob is begin -- Act - ut3.ut.expect( empty_blob() ).not_to( ut3.be_empty() ); + ut3_develop.ut.expect( empty_blob() ).not_to( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -261,7 +261,7 @@ create or replace package body test_expect_to_be_empty is procedure success_not_be_empty_blob is begin -- Act - ut3.ut.expect( to_blob('AA') ).not_to( ut3.be_empty() ); + ut3_develop.ut.expect( to_blob('AA') ).not_to( ut3_develop.be_empty() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; diff --git a/test/ut3_user/expectations/unary/test_expect_to_be_true_false.pkb b/test/ut3_user/expectations/unary/test_expect_to_be_true_false.pkb index 6a621c6b3..c1067044b 100644 --- a/test/ut3_user/expectations/unary/test_expect_to_be_true_false.pkb +++ b/test/ut3_user/expectations/unary/test_expect_to_be_true_false.pkb @@ -9,7 +9,7 @@ is procedure to_be_true_null_boolean is begin --Act - ut3.ut.expect( 1=null ).to_be_true(); + ut3_develop.ut.expect( 1=null ).to_be_true(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -17,7 +17,7 @@ is procedure to_be_true_success is begin --Act - ut3.ut.expect( 1=1 ).to_be_true(); + ut3_develop.ut.expect( 1=1 ).to_be_true(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -25,7 +25,7 @@ is procedure to_be_true_failure is begin --Act - ut3.ut.expect( 1=2 ).to_be_true(); + ut3_develop.ut.expect( 1=2 ).to_be_true(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -33,7 +33,7 @@ is procedure to_be_true_bad_type is begin --Act - ut3.ut.expect( 1 ).to_be_true(); + ut3_develop.ut.expect( 1 ).to_be_true(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -41,7 +41,7 @@ is procedure not_to_be_true_null_boolean is begin --Act - ut3.ut.expect( 1=null ).not_to_be_true(); + ut3_develop.ut.expect( 1=null ).not_to_be_true(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -49,7 +49,7 @@ is procedure not_to_be_true_success is begin --Act - ut3.ut.expect( 1=2 ).not_to_be_true(); + ut3_develop.ut.expect( 1=2 ).not_to_be_true(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -57,7 +57,7 @@ is procedure not_to_be_true_failure is begin --Act - ut3.ut.expect( 1=1 ).not_to_be_true(); + ut3_develop.ut.expect( 1=1 ).not_to_be_true(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -66,7 +66,7 @@ is procedure not_to_be_true_bad_type is begin --Act - ut3.ut.expect( 1 ).not_to_be_true(); + ut3_develop.ut.expect( 1 ).not_to_be_true(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -74,7 +74,7 @@ is procedure to_be_false_null_boolean is begin --Act - ut3.ut.expect( 1=null ).to_be_false(); + ut3_develop.ut.expect( 1=null ).to_be_false(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -82,7 +82,7 @@ is procedure to_be_false_success is begin --Act - ut3.ut.expect( 1=2 ).to_be_false(); + ut3_develop.ut.expect( 1=2 ).to_be_false(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -90,7 +90,7 @@ is procedure to_be_false_failure is begin --Act - ut3.ut.expect( 1=1 ).to_be_false(); + ut3_develop.ut.expect( 1=1 ).to_be_false(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -98,7 +98,7 @@ is procedure to_be_false_bad_type is begin --Act - ut3.ut.expect( 1 ).to_be_false(); + ut3_develop.ut.expect( 1 ).to_be_false(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -106,7 +106,7 @@ is procedure not_to_be_false_null_boolean is begin --Act - ut3.ut.expect( 1=null ).not_to_be_false(); + ut3_develop.ut.expect( 1=null ).not_to_be_false(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -114,7 +114,7 @@ is procedure not_to_be_false_success is begin --Act - ut3.ut.expect( 1=1 ).not_to_be_false(); + ut3_develop.ut.expect( 1=1 ).not_to_be_false(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -122,7 +122,7 @@ is procedure not_to_be_false_failure is begin --Act - ut3.ut.expect( 1=2 ).not_to_be_false(); + ut3_develop.ut.expect( 1=2 ).not_to_be_false(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -130,7 +130,7 @@ is procedure not_to_be_false_bad_type is begin --Act - ut3.ut.expect( 1 ).not_to_be_false(); + ut3_develop.ut.expect( 1 ).not_to_be_false(); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; diff --git a/test/ut3_user/expectations/unary/test_expect_to_have_count.pkb b/test/ut3_user/expectations/unary/test_expect_to_have_count.pkb index 327ced120..2167c44ef 100644 --- a/test/ut3_user/expectations/unary/test_expect_to_have_count.pkb +++ b/test/ut3_user/expectations/unary/test_expect_to_have_count.pkb @@ -11,7 +11,7 @@ create or replace package body test_expect_to_have_count is --Arrange open l_cursor for select * from dual connect by level <= 11; --Act - ut3.ut.expect(l_cursor).to_have_count(11); + ut3_develop.ut.expect(l_cursor).to_have_count(11); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -22,7 +22,7 @@ create or replace package body test_expect_to_have_count is --Arrange open l_cursor for select * from dual where 0=1; --Act - ut3.ut.expect(l_cursor).to_have_count(1); + ut3_develop.ut.expect(l_cursor).to_have_count(1); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -35,7 +35,7 @@ create or replace package body test_expect_to_have_count is --Arrange open l_cursor for select * from dual; --Act - ut3.ut.expect(l_cursor).to_have_count(2); + ut3_develop.ut.expect(l_cursor).to_have_count(2); l_expected_message := q'[Actual: (refcursor [ count = 1 ]) was expected to have [ count = 2 ]%]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -50,7 +50,7 @@ create or replace package body test_expect_to_have_count is --Arrange open l_cursor for select * from dual; --Act - ut3.ut.expect(l_cursor).not_to_have_count(2); + ut3_develop.ut.expect(l_cursor).not_to_have_count(2); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -61,7 +61,7 @@ create or replace package body test_expect_to_have_count is --Arrange open l_cursor for select * from dual where 1 = 2; --Act - ut3.ut.expect(l_cursor).not_to_have_count(0); + ut3_develop.ut.expect(l_cursor).not_to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -72,7 +72,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertcollection(ora_mining_varchar2_nt()); -- Act - ut3.ut.expect(l_actual).to_have_count(0); + ut3_develop.ut.expect(l_actual).to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -83,7 +83,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertcollection(ora_mining_varchar2_nt('a')); -- Act - ut3.ut.expect(l_actual).to_have_count(0); + ut3_develop.ut.expect(l_actual).to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -94,7 +94,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertcollection(ora_mining_varchar2_nt('a')); -- Act - ut3.ut.expect(l_actual).not_to_have_count(2); + ut3_develop.ut.expect(l_actual).not_to_have_count(2); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -105,7 +105,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertcollection(ora_mining_varchar2_nt()); -- Act - ut3.ut.expect(l_actual).not_to_have_count(0); + ut3_develop.ut.expect(l_actual).not_to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -117,7 +117,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertcollection(l_data); -- Act - ut3.ut.expect(l_actual).to_have_count(0); + ut3_develop.ut.expect(l_actual).to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -129,7 +129,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertcollection(l_data); -- Act - ut3.ut.expect(l_actual).not_to_have_count(0); + ut3_develop.ut.expect(l_actual).not_to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -140,7 +140,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertObject(ut3_tester_helper.test_dummy_number(1)); -- Act - ut3.ut.expect(l_actual).to_have_count(0); + ut3_develop.ut.expect(l_actual).to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -152,7 +152,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertObject(l_data); -- Act - ut3.ut.expect(l_actual).to_have_count(0); + ut3_develop.ut.expect(l_actual).to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -162,7 +162,7 @@ create or replace package body test_expect_to_have_count is l_actual_message varchar2(32767); begin -- Act - ut3.ut.expect( 1 ).to_( ut3.have_count(0) ); + ut3_develop.ut.expect( 1 ).to_( ut3_develop.have_count(0) ); --Assert l_expected_message := q'[%The matcher 'have count' cannot be used with data type (number).%]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -178,7 +178,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertObject(ut3_tester_helper.test_dummy_number(1)); -- Act - ut3.ut.expect(l_actual).not_to_have_count(0); + ut3_develop.ut.expect(l_actual).not_to_have_count(0); --Assert l_expected_message := q'[%The matcher 'have count' cannot be used with data type (ut3_tester_helper.test_dummy_number).%]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); @@ -193,7 +193,7 @@ create or replace package body test_expect_to_have_count is --Arrange l_actual := anydata.convertObject(l_data); -- Act - ut3.ut.expect(l_actual).not_to_have_count(0); + ut3_develop.ut.expect(l_actual).not_to_have_count(0); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; @@ -201,7 +201,7 @@ create or replace package body test_expect_to_have_count is procedure fail_not_have_count_number is begin -- Act - ut3.ut.expect( 1 ).not_to( ut3.have_count(0) ); + ut3_develop.ut.expect( 1 ).not_to( ut3_develop.have_count(0) ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; diff --git a/test/ut3_user/reporters.pkb b/test/ut3_user/reporters.pkb index 9f571a589..edd26189c 100644 --- a/test/ut3_user/reporters.pkb +++ b/test/ut3_user/reporters.pkb @@ -74,14 +74,14 @@ as is begin dbms_output.put_line(''); - ut3.ut.expect(1,'Test 1 Should Pass').to_equal(1); + ut3_develop.ut.expect(1,'Test 1 Should Pass').to_equal(1); end; procedure failing_test is begin dbms_output.put_line(''); - ut3.ut.expect('number [1] ','Fails as values are different').to_equal('number [2] '); + ut3_develop.ut.expect('number [1] ','Fails as values are different').to_equal('number [2] '); end; procedure erroring_test @@ -90,14 +90,14 @@ as begin dbms_output.put_line(''); l_variable := 'a string'; - ut3.ut.expect(l_variable).to_equal(1); + ut3_develop.ut.expect(l_variable).to_equal(1); end; procedure disabled_test is begin dbms_output.put_line(''); - ut3.ut.expect(1,'this should not execute').to_equal(1); + ut3_develop.ut.expect(1,'this should not execute').to_equal(1); end; procedure beforeall is @@ -124,7 +124,7 @@ end;]'; execute immediate q'[create or replace package body check_fail_escape is procedure fail_miserably is begin - ut3.ut.expect('test').to_equal(''); + ut3_develop.ut.expect('test').to_equal(''); end; end;]'; @@ -148,36 +148,36 @@ end;]'; end; procedure check_xml_encoding_included( - a_reporter ut3.ut_reporter_base, + a_reporter ut3_develop.ut_reporter_base, a_client_character_set varchar2 ) is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('test_reporters', a_reporter, a_client_character_set => a_client_character_set)); + from table(ut3_develop.ut.run('test_reporters', a_reporter, a_client_character_set => a_client_character_set)); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_be_like('%'); end; procedure check_xml_failure_escaped( - a_reporter ut3.ut_reporter_base + a_reporter ut3_develop.ut_reporter_base ) is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table( ut3.ut.run( 'check_fail_escape', a_reporter ) ); + from table( ut3_develop.ut.run( 'check_fail_escape', a_reporter ) ); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_be_like('%' (varchar2)%]' - ||q'[at "UT3$USER#.CHECK_FAIL_ESCAPE%", line % ut3.ut.expect('test').to_equal('');]' + ||q'[at "UT3$USER#.CHECK_FAIL_ESCAPE%", line % ut3_develop.ut.expect('test').to_equal('');]' ||'%]]>%' ); end; diff --git a/test/ut3_user/reporters.pks b/test/ut3_user/reporters.pks index d1ed8635f..c5ad72e22 100644 --- a/test/ut3_user/reporters.pks +++ b/test/ut3_user/reporters.pks @@ -10,12 +10,12 @@ create or replace package reporters is procedure reporters_cleanup; procedure check_xml_encoding_included( - a_reporter ut3.ut_reporter_base, + a_reporter ut3_develop.ut_reporter_base, a_client_character_set varchar2 ); procedure check_xml_failure_escaped( - a_reporter ut3.ut_reporter_base + a_reporter ut3_develop.ut_reporter_base ); end reporters; diff --git a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb index 183492eb7..7ae4b6f0d 100644 --- a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ -1,7 +1,7 @@ create or replace package body test_cov_cobertura_reporter is procedure report_on_file is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; begin @@ -11,11 +11,11 @@ create or replace package body test_cov_cobertura_reporter is -test/ut3.dummy_coverage.pkb +test/ut3_develop.dummy_coverage.pkb - + @@ -29,11 +29,11 @@ create or replace package body test_cov_cobertura_reporter is select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_dummy_coverage', - a_reporter=> ut3.ut_coverage_cobertura_reporter( ), - a_source_files => ut3.ut_varchar2_list( 'test/ut3.dummy_coverage.pkb' ), - a_test_files => ut3.ut_varchar2_list( ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_cobertura_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ) ) ); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); @@ -42,7 +42,7 @@ create or replace package body test_cov_cobertura_reporter is end; procedure report_zero_coverage is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; begin @@ -52,11 +52,11 @@ create or replace package body test_cov_cobertura_reporter is -ut3.dummy_coverage +ut3_develop.dummy_coverage - + @@ -84,10 +84,10 @@ create or replace package body test_cov_cobertura_reporter is select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_dummy_coverage', - a_reporter=> ut3.ut_coverage_cobertura_reporter( ), - a_include_objects => ut3.ut_varchar2_list('UT3.DUMMY_COVERAGE') + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_cobertura_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.DUMMY_COVERAGE') ) ); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb index 5cd53a093..b0cb05a5b 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb @@ -1,14 +1,14 @@ create or replace package body test_coverage_sonar_reporter is procedure report_on_file is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; begin --Arrange l_expected := ' - + @@ -18,11 +18,11 @@ create or replace package body test_coverage_sonar_reporter is select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_dummy_coverage', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_source_files => ut3.ut_varchar2_list( 'test/ut3.dummy_coverage.pkb' ), - a_test_files => ut3.ut_varchar2_list( ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ) ) ); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); @@ -32,7 +32,7 @@ create or replace package body test_coverage_sonar_reporter is procedure check_encoding_included is begin - reporters.check_xml_encoding_included(ut3.ut_coverage_sonar_reporter(), 'UTF-8'); + reporters.check_xml_encoding_included(ut3_develop.ut_coverage_sonar_reporter(), 'UTF-8'); end; end; diff --git a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb index 2d36d45cb..73dde1b78 100644 --- a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb @@ -1,13 +1,13 @@ create or replace package body test_coveralls_reporter is procedure report_on_file is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; begin --Arrange l_expected := q'[{"source_files":[ -{ "name": "test/ut3.dummy_coverage.pkb", +{ "name": "test/ut3_develop.dummy_coverage.pkb", "coverage": [ null, null, @@ -24,11 +24,11 @@ null, select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_dummy_coverage', - a_reporter=> ut3.ut_coveralls_reporter( ), - a_source_files => ut3.ut_varchar2_list( 'test/ut3.dummy_coverage.pkb' ), - a_test_files => ut3.ut_varchar2_list( ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coveralls_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ) ) ); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); @@ -37,14 +37,14 @@ null, end; procedure report_zero_coverage is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; pragma autonomous_transaction; begin --Arrange l_expected := q'[{"source_files":[ -{ "name": "ut3.dummy_coverage", +{ "name": "ut3_develop.dummy_coverage", "coverage": [ 0, 0, @@ -72,10 +72,10 @@ null, select * bulk collect into l_results from table( - ut3.ut.run( - 'ut3.test_dummy_coverage', - ut3.ut_coveralls_reporter(), - a_include_objects => ut3.ut_varchar2_list('UT3.DUMMY_COVERAGE') + ut3_develop.ut.run( + 'ut3_develop.test_dummy_coverage', + ut3_develop.ut_coveralls_reporter(), + a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.DUMMY_COVERAGE') ) ); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); diff --git a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb index 02b275020..8c6ae9e02 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb @@ -1,22 +1,22 @@ create or replace package body test_html_extended_reporter is procedure report_on_file is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected varchar2(32767); l_actual clob; l_charset varchar2(100) := 'ISO-8859-1'; begin --Arrange - l_expected := '%%

UT3.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG

%4 relevant lines. 3 lines covered (including 1 lines partially covered ) and 1 lines missed%'; + l_expected := '%%

UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG

%4 relevant lines. 3 lines covered (including 1 lines partially covered ) and 1 lines missed%'; select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_block_dummy_coverage', - a_reporter=> ut3.ut_coverage_html_reporter(), - a_source_files => ut3.ut_varchar2_list( 'test/ut3.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb' ), - a_test_files => ut3.ut_varchar2_list( ), + ut3_develop.ut.run( + a_path => 'ut3_develop.test_block_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_html_reporter(), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ), a_client_character_set => l_charset ) ); diff --git a/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb index 8daf36513..9f3fb90e5 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb @@ -1,22 +1,22 @@ create or replace package body test_html_proftab_reporter is procedure report_on_file is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_expected varchar2(32767); l_actual clob; l_charset varchar2(100) := 'ISO-8859-1'; begin --Arrange - l_expected := '%%

UT3.DUMMY_COVERAGE

%3 relevant lines. 2 lines covered and 1 lines missed%'; + l_expected := '%%

UT3_DEVELOP.DUMMY_COVERAGE

%3 relevant lines. 2 lines covered and 1 lines missed%'; --Act select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_dummy_coverage', - a_reporter=> ut3.ut_coverage_html_reporter(), - a_source_files => ut3.ut_varchar2_list( 'test/ut3.dummy_coverage.pkb' ), - a_test_files => ut3.ut_varchar2_list( ), + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_html_reporter(), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ), a_client_character_set => l_charset ) ); diff --git a/test/ut3_user/reporters/test_debug_reporter.pkb b/test/ut3_user/reporters/test_debug_reporter.pkb index f108ec577..ed7e14fcf 100644 --- a/test/ut3_user/reporters/test_debug_reporter.pkb +++ b/test/ut3_user/reporters/test_debug_reporter.pkb @@ -3,14 +3,14 @@ create or replace package body test_debug_reporter as g_actual clob; procedure run_reporter is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin select * bulk collect into l_results from table( - ut3.ut.run( + ut3_develop.ut.run( 'test_reporters', - ut3.ut_debug_reporter() + ut3_develop.ut_debug_reporter() ) ); g_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); diff --git a/test/ut3_user/reporters/test_documentation_reporter.pkb b/test/ut3_user/reporters/test_documentation_reporter.pkb index a1f895947..456fa86f9 100644 --- a/test/ut3_user/reporters/test_documentation_reporter.pkb +++ b/test/ut3_user/reporters/test_documentation_reporter.pkb @@ -1 +1 @@ -create or replace package body test_documentation_reporter as procedure report_produces_expected_out is l_results ut3.ut_varchar2_list; l_actual clob; l_expected varchar2(32767):=q'[%org utplsql tests helpers A suite for testing different outcomes from reporters A description of some context passing_test [% sec] a test with failing assertion [% sec] (FAILED - 1) a test raising unhandled exception [% sec] (FAILED - 2) a disabled test [0 sec] (DISABLED) % Failures: % 1) failing_test "Fails as values are different" Actual: 'number [1] ' (varchar2) was expected to equal: 'number [2] ' (varchar2)% at "UT3$USER#.TEST_REPORTERS%", line 36 ut3.ut.expect('number [1] ','Fails as values are different').to_equal('number [2] '); % % 2) erroring_test ORA-06502: PL/SQL: numeric or value error: character to number conversion error ORA-06512: at "UT3$USER#.TEST_REPORTERS", line 44% ORA-06512: at line 6 Finished in % seconds 4 tests, 1 failed, 1 errored, 1 disabled, 0 warning(s)%]'; begin select * bulk collect into l_results from table( ut3.ut.run( 'test_reporters', ut3.ut_documentation_reporter() ) ); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like(l_expected); end; end; / \ No newline at end of file +create or replace package body test_documentation_reporter as procedure report_produces_expected_out is l_results ut3_develop.ut_varchar2_list; l_actual clob; l_expected varchar2(32767):=q'[%org utplsql tests helpers A suite for testing different outcomes from reporters A description of some context passing_test [% sec] a test with failing assertion [% sec] (FAILED - 1) a test raising unhandled exception [% sec] (FAILED - 2) a disabled test [0 sec] (DISABLED) % Failures: % 1) failing_test "Fails as values are different" Actual: 'number [1] ' (varchar2) was expected to equal: 'number [2] ' (varchar2)% at "UT3$USER#.TEST_REPORTERS%", line 36 ut3_develop.ut.expect('number [1] ','Fails as values are different').to_equal('number [2] '); % % 2) erroring_test ORA-06502: PL/SQL: numeric or value error: character to number conversion error ORA-06512: at "UT3$USER#.TEST_REPORTERS", line 44% ORA-06512: at line 6 Finished in % seconds 4 tests, 1 failed, 1 errored, 1 disabled, 0 warning(s)%]'; begin select * bulk collect into l_results from table( ut3_develop.ut.run( 'test_reporters', ut3_develop.ut_documentation_reporter() ) ); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like(l_expected); end; end; / \ No newline at end of file diff --git a/test/ut3_user/reporters/test_extended_coverage.pkb b/test/ut3_user/reporters/test_extended_coverage.pkb index 33d42d9ef..28742aa70 100644 --- a/test/ut3_user/reporters/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_extended_coverage.pkb @@ -3,18 +3,18 @@ create or replace package body test_extended_coverage is procedure coverage_for_object is l_expected clob; l_actual clob; - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Arrange - l_expected := '%%%'; + l_expected := '%%%'; --Act select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_block_dummy_coverage', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_include_objects => ut3.ut_varchar2_list( 'ut3.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long' ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_block_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long' ) ) ); --Assert @@ -25,44 +25,44 @@ create or replace package body test_extended_coverage is procedure coverage_for_schema is l_expected clob; l_actual clob; - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Arrange - l_expected := '%%%'; + l_expected := '%%%'; --Act select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_block_dummy_coverage', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_coverage_schemes => ut3.ut_varchar2_list( 'ut3' ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_block_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_coverage_schemes => ut3_develop.ut_varchar2_list( 'ut3_develop' ) ) ); --Assert l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like(l_expected); - ut.expect(l_actual).to_be_like('%%%'); + ut.expect(l_actual).to_be_like('%%%'); end; procedure coverage_for_file is l_expected clob; l_actual clob; - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_file_path varchar2(250); begin --Arrange - l_file_path := lower('test/ut3.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb'); + l_file_path := lower('test/ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb'); l_expected := '%%%'; --Act select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_block_dummy_coverage', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_source_files => ut3.ut_varchar2_list( l_file_path ), - a_test_files => ut3.ut_varchar2_list( ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_block_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( l_file_path ), + a_test_files => ut3_develop.ut_varchar2_list( ) ) ); --Assert diff --git a/test/ut3_user/reporters/test_junit_reporter.pkb b/test/ut3_user/reporters/test_junit_reporter.pkb index e1b790156..f3cc6c6d2 100644 --- a/test/ut3_user/reporters/test_junit_reporter.pkb +++ b/test/ut3_user/reporters/test_junit_reporter.pkb @@ -13,8 +13,8 @@ create or replace package body test_junit_reporter as execute immediate q'[create or replace package body check_junit_reporting is procedure test_do_stuff is begin - ut3.ut.expect(1).to_equal(1); - ut3.ut.expect(1).to_equal(2); + ut3_develop.ut.expect(1).to_equal(1); + ut3_develop.ut.expect(1).to_equal(2); end; end;]'; @@ -31,7 +31,7 @@ create or replace package body test_junit_reporter as execute immediate q'[create or replace package body check_junit_rep_suitepath is procedure check_junit_rep_suitepath is begin - ut3.ut.expect(1).to_equal(1); + ut3_develop.ut.expect(1).to_equal(1); end; end;]'; @@ -76,13 +76,13 @@ create or replace package body test_junit_reporter as end; procedure escapes_special_chars is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_reporting',ut3.ut_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_reporting',ut3_develop.ut_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).not_to_be_like('%%'); @@ -90,13 +90,13 @@ create or replace package body test_junit_reporter as end; procedure reports_only_failed_or_errored is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_reporting',ut3.ut_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_reporting',ut3_develop.ut_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).not_to_be_like('%Actual: 1 (number) was expected to equal: 1 (number)%'); @@ -104,13 +104,13 @@ create or replace package body test_junit_reporter as end; procedure reports_xunit_only_fail_or_err is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_reporting',ut3.ut_xunit_reporter())); + from table(ut3_develop.ut.run('check_junit_reporting',ut3_develop.ut_xunit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).not_to_be_like('%Actual: 1 (number) was expected to equal: 1 (number)%'); @@ -118,20 +118,20 @@ create or replace package body test_junit_reporter as end; procedure check_classname_suite is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_reporting',ut3.ut_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_reporting',ut3_develop.ut_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_be_like('%testcase classname="check_junit_reporting" assertions="%" name="%"%'); end; procedure check_nls_number_formatting is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; l_nls_numeric_characters varchar2(30); begin @@ -143,7 +143,7 @@ create or replace package body test_junit_reporter as --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_reporting', ut3.ut_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_reporting', ut3_develop.ut_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_match('time="[0-9]*\.[0-9]{3,6}"'); @@ -152,20 +152,20 @@ create or replace package body test_junit_reporter as end; procedure check_classname_suitepath is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_rep_suitepath',ut3.ut_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_rep_suitepath',ut3_develop.ut_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_be_like('%testcase classname="core.check_junit_rep_suitepath" assertions="%" name="%"%'); end; procedure report_test_without_desc is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; l_expected varchar2(32767):= q'[ @@ -185,13 +185,13 @@ create or replace package body test_junit_reporter as begin select * bulk collect into l_results - from table(ut3.ut.run('tst_package_junit_nodesc',ut3.ut_junit_reporter())); + from table(ut3_develop.ut.run('tst_package_junit_nodesc',ut3_develop.ut_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like(l_expected); end; procedure report_suite_without_desc is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; l_expected varchar2(32767):= q'[ @@ -207,13 +207,13 @@ create or replace package body test_junit_reporter as begin select * bulk collect into l_results - from table(ut3.ut.run('tst_package_junit_nosuite',ut3.ut_junit_reporter())); + from table(ut3_develop.ut.run('tst_package_junit_nosuite',ut3_develop.ut_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like(l_expected); end; procedure reporort_produces_expected_out is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; l_expected varchar2(32767):=q'[ @@ -263,20 +263,20 @@ create or replace package body test_junit_reporter as begin select * bulk collect into l_results - from table(ut3.ut.run('test_reporters',ut3.ut_junit_reporter())); + from table(ut3_develop.ut.run('test_reporters',ut3_develop.ut_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like(l_expected); end; procedure check_failure_escaped is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin - reporters.check_xml_failure_escaped(ut3.ut_junit_reporter()); + reporters.check_xml_failure_escaped(ut3_develop.ut_junit_reporter()); end; procedure check_classname_is_populated is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; l_expected varchar2(32767):= q'[ @@ -292,14 +292,14 @@ create or replace package body test_junit_reporter as begin select * bulk collect into l_results - from table(ut3.ut.run('Tst_Fix_Case_Sensitive',ut3.ut_junit_reporter())); + from table(ut3_develop.ut.run('Tst_Fix_Case_Sensitive',ut3_develop.ut_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like(l_expected); end; procedure check_encoding_included is begin - reporters.check_xml_encoding_included(ut3.ut_junit_reporter(), 'UTF-8'); + reporters.check_xml_encoding_included(ut3_develop.ut_junit_reporter(), 'UTF-8'); end; procedure remove_test_package is diff --git a/test/ut3_user/reporters/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_proftab_coverage.pkb index 74a33772e..c132517a7 100644 --- a/test/ut3_user/reporters/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_proftab_coverage.pkb @@ -3,18 +3,18 @@ create or replace package body test_proftab_coverage is procedure coverage_for_object is l_expected clob; l_actual clob; - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Arrange - l_expected := '%%'; + l_expected := '%%'; --Act select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_dummy_coverage', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_include_objects => ut3.ut_varchar2_list( 'ut3.dummy_coverage' ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) ) ); --Assert @@ -25,18 +25,18 @@ create or replace package body test_proftab_coverage is procedure coverage_for_object_no_owner is l_expected clob; l_actual clob; - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Arrange - l_expected := '%%'; + l_expected := '%%'; --Act select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_dummy_coverage', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_include_objects => ut3.ut_varchar2_list( 'dummy_coverage' ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'dummy_coverage' ) ) ); --Assert @@ -47,19 +47,19 @@ create or replace package body test_proftab_coverage is procedure coverage_for_schema is l_expected clob; l_actual clob; - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Arrange - l_expected := ''; + l_expected := ''; l_expected := '%'||l_expected||'%'||l_expected||'%'; --Act select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_dummy_coverage', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_coverage_schemes => ut3.ut_varchar2_list( 'ut3' ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_coverage_schemes => ut3_develop.ut_varchar2_list( 'ut3_develop' ) ) ); --Assert @@ -70,21 +70,21 @@ create or replace package body test_proftab_coverage is procedure coverage_for_file is l_expected clob; l_actual clob; - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_file_path varchar2(100); begin --Arrange - l_file_path := lower('test/ut3.dummy_coverage.pkb'); + l_file_path := lower('test/ut3_develop.dummy_coverage.pkb'); l_expected := '%%'; --Act select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3.test_dummy_coverage', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_source_files => ut3.ut_varchar2_list( l_file_path ), - a_test_files => ut3.ut_varchar2_list( ) + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( l_file_path ), + a_test_files => ut3_develop.ut_varchar2_list( ) ) ); --Assert @@ -94,16 +94,16 @@ create or replace package body test_proftab_coverage is procedure coverage_tmp_data_refresh is l_actual clob; - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; begin --Arrange select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3:coverage_testing', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_include_objects => ut3.ut_varchar2_list( 'ut3.dummy_coverage' ) + ut3_develop.ut.run( + a_path => 'ut3_develop:coverage_testing', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) ) ); ut3_tester_helper.coverage_helper.cleanup_dummy_coverage(); @@ -114,10 +114,10 @@ create or replace package body test_proftab_coverage is select * bulk collect into l_results from table( - ut3.ut.run( - a_path => 'ut3:coverage_testing', - a_reporter=> ut3.ut_coverage_sonar_reporter( ), - a_include_objects => ut3.ut_varchar2_list( 'ut3.dummy_coverage' ) + ut3_develop.ut.run( + a_path => 'ut3_develop:coverage_testing', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) ) ); diff --git a/test/ut3_user/reporters/test_realtime_reporter.pkb b/test/ut3_user/reporters/test_realtime_reporter.pkb index 155925f0f..53a268ff4 100644 --- a/test/ut3_user/reporters/test_realtime_reporter.pkb +++ b/test/ut3_user/reporters/test_realtime_reporter.pkb @@ -23,12 +23,12 @@ create or replace package body test_realtime_reporter as execute immediate q'[create or replace package body check_realtime_reporting1 is procedure test_1_ok is begin - ut3.ut.expect(1).to_equal(1); + ut3_develop.ut.expect(1).to_equal(1); end; procedure test_2_nok is begin - ut3.ut.expect(1).to_equal(2); + ut3_develop.ut.expect(1).to_equal(2); end; end;]'; @@ -49,13 +49,13 @@ create or replace package body test_realtime_reporter as execute immediate q'[create or replace package body check_realtime_reporting2 is procedure test_3_ok is begin - ut3.ut.expect(2).to_equal(2); + ut3_develop.ut.expect(2).to_equal(2); end; procedure test_4_nok is begin - ut3.ut.expect(2).to_equal(3); - ut3.ut.expect(2).to_equal(4); + ut3_develop.ut.expect(2).to_equal(3); + ut3_develop.ut.expect(2).to_equal(4); end; procedure test_5 is @@ -82,13 +82,13 @@ create or replace package body test_realtime_reporter as l_actual integer; begin execute immediate 'select 6 from non_existing_table' into l_actual; - ut3.ut.expect(6).to_equal(l_actual); + ut3_develop.ut.expect(6).to_equal(l_actual); end; procedure test_7_with_serveroutput is begin dbms_output.put_line('before test 7'); - ut3.ut.expect(7).to_equal(7); + ut3_develop.ut.expect(7).to_equal(7); dbms_output.put_line('after test 7'); end; @@ -114,18 +114,18 @@ create or replace package body test_realtime_reporter as procedure test_8_with_warning is begin commit; -- this will raise a warning - ut3.ut.expect(8).to_equal(8); + ut3_develop.ut.expect(8).to_equal(8); end; end;]'; <> declare - l_reporter ut3.ut_realtime_reporter := ut3.ut_realtime_reporter(); + l_reporter ut3_develop.ut_realtime_reporter := ut3_develop.ut_realtime_reporter(); begin -- produce - ut3.ut_runner.run( - a_paths => ut3.ut_varchar2_list(':realtime_reporting'), - a_reporters => ut3.ut_reporters(l_reporter) + ut3_develop.ut_runner.run( + a_paths => ut3_develop.ut_varchar2_list(':realtime_reporting'), + a_reporters => ut3_develop.ut_reporters(l_reporter) ); -- consume select ut3_tester_helper.test_event_object(item_type, xmltype(text)) @@ -337,7 +337,7 @@ create or replace package body test_realtime_reporter as procedure serveroutput_of_test is l_actual clob; - l_expected_list ut3.ut_varchar2_list; + l_expected_list ut3_develop.ut_varchar2_list; l_expected clob; begin select t.event_doc.extract('//event/test/serverOutput/text()').getstringval() @@ -354,7 +354,7 @@ create or replace package body test_realtime_reporter as procedure serveroutput_of_testsuite is l_actual clob; - l_expected_list ut3.ut_varchar2_list; + l_expected_list ut3_develop.ut_varchar2_list; l_expected clob; begin select t.event_doc.extract('//event/suite/serverOutput/text()').getstringval() @@ -372,7 +372,7 @@ create or replace package body test_realtime_reporter as procedure error_stack_of_test is l_actual clob; - l_expected_list ut3.ut_varchar2_list; + l_expected_list ut3_develop.ut_varchar2_list; l_expected clob; begin select t.event_doc.extract('//event/test/errorStack/text()').getstringval() @@ -389,7 +389,7 @@ create or replace package body test_realtime_reporter as procedure error_stack_of_testsuite is l_actual clob; - l_expected_list ut3.ut_varchar2_list; + l_expected_list ut3_develop.ut_varchar2_list; l_expected clob; begin select t.event_doc.extract('//event/suite/errorStack/text()').getstringval() @@ -406,7 +406,7 @@ create or replace package body test_realtime_reporter as procedure warnings_of_test is l_actual clob; - l_expected_list ut3.ut_varchar2_list; + l_expected_list ut3_develop.ut_varchar2_list; l_expected clob; begin select t.event_doc.extract('//event/test/warnings/text()').getstringval() @@ -422,7 +422,7 @@ create or replace package body test_realtime_reporter as procedure warnings_of_testsuite is l_actual clob; - l_expected_list ut3.ut_varchar2_list; + l_expected_list ut3_develop.ut_varchar2_list; l_expected clob; begin select t.event_doc.extract('//event/suite/warnings/text()').getstringval() @@ -440,11 +440,11 @@ create or replace package body test_realtime_reporter as end warnings_of_testsuite; procedure get_description is - l_reporter ut3.ut_realtime_reporter; + l_reporter ut3_develop.ut_realtime_reporter; l_actual varchar2(4000); l_expected varchar2(80) := '%SQL Developer%'; begin - l_reporter := ut3.ut_realtime_reporter(); + l_reporter := ut3_develop.ut_realtime_reporter(); l_actual := l_reporter.get_description(); ut.expect(l_actual).to_be_like(l_expected); end get_description; diff --git a/test/ut3_user/reporters/test_sonar_test_reporter.pkb b/test/ut3_user/reporters/test_sonar_test_reporter.pkb index 357eff0a2..5821b2071 100644 --- a/test/ut3_user/reporters/test_sonar_test_reporter.pkb +++ b/test/ut3_user/reporters/test_sonar_test_reporter.pkb @@ -1,7 +1,7 @@ create or replace package body test_sonar_test_reporter as procedure report_produces_expected_out is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; l_expected varchar2(32767):=q'[ @@ -17,10 +17,10 @@ create or replace package body test_sonar_test_reporter as select * bulk collect into l_results from table( - ut3.ut.run( + ut3_develop.ut.run( 'test_reporters', - ut3.ut_sonar_test_reporter(), - a_test_file_mappings => ut3.ut_file_mapper.build_file_mappings( sys_context('USERENV', 'CURRENT_USER'), ut3.ut_varchar2_list('tests/helpers/test_reporters.pkb')) + ut3_develop.ut_sonar_test_reporter(), + a_test_file_mappings => ut3_develop.ut_file_mapper.build_file_mappings( sys_context('USERENV', 'CURRENT_USER'), ut3_develop.ut_varchar2_list('tests/helpers/test_reporters.pkb')) ) ); l_actual :=ut3_tester_helper.main_helper.table_to_clob(l_results); @@ -29,12 +29,12 @@ create or replace package body test_sonar_test_reporter as procedure check_encoding_included is begin - reporters.check_xml_encoding_included(ut3.ut_sonar_test_reporter(), 'UTF-8'); + reporters.check_xml_encoding_included(ut3_develop.ut_sonar_test_reporter(), 'UTF-8'); end; procedure check_failure_escaped is begin - reporters.check_xml_failure_escaped(ut3.ut_sonar_test_reporter()); + reporters.check_xml_failure_escaped(ut3_develop.ut_sonar_test_reporter()); end; end; diff --git a/test/ut3_user/reporters/test_teamcity_reporter.pkb b/test/ut3_user/reporters/test_teamcity_reporter.pkb index a5261d7f9..6d471b2b0 100644 --- a/test/ut3_user/reporters/test_teamcity_reporter.pkb +++ b/test/ut3_user/reporters/test_teamcity_reporter.pkb @@ -13,7 +13,7 @@ create or replace package body test_teamcity_reporter as execute immediate q'[create or replace package body check_escape_special_chars is procedure test_do_stuff is begin - ut3.ut.expect(' [ ' || chr(13) || chr(10) || ' ] ' ).to_be_null; + ut3_develop.ut.expect(' [ ' || chr(13) || chr(10) || ' ] ' ).to_be_null; end; end;]'; @@ -27,7 +27,7 @@ create or replace package body test_teamcity_reporter as execute immediate q'[create or replace package body check_trims_long_output is procedure long_output is begin - ut3.ut.expect(rpad('aVarchar',4000,'a')).to_be_null; + ut3_develop.ut.expect(rpad('aVarchar',4000,'a')).to_be_null; end; end;]'; @@ -35,7 +35,7 @@ create or replace package body test_teamcity_reporter as procedure report_produces_expected_out is - l_output_data ut3.ut_varchar2_list; + l_output_data ut3_develop.ut_varchar2_list; l_output clob; l_expected varchar2(32767); begin @@ -76,14 +76,14 @@ create or replace package body test_teamcity_reporter as --act select * bulk collect into l_output_data - from table(ut3.ut.run('test_reporters',ut3.ut_teamcity_reporter())); + from table(ut3_develop.ut.run('test_reporters',ut3_develop.ut_teamcity_reporter())); --assert ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); end; procedure escape_special_chars is - l_output_data ut3.ut_varchar2_list; + l_output_data ut3_develop.ut_varchar2_list; l_output clob; l_expected varchar2(32767); begin @@ -95,14 +95,14 @@ create or replace package body test_teamcity_reporter as --act select * bulk collect into l_output_data - from table(ut3.ut.run('check_escape_special_chars',ut3.ut_teamcity_reporter())); + from table(ut3_develop.ut.run('check_escape_special_chars',ut3_develop.ut_teamcity_reporter())); --assert ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); end; procedure trims_long_output is - l_output_data ut3.ut_varchar2_list; + l_output_data ut3_develop.ut_varchar2_list; l_output clob; l_expected varchar2(32767); begin @@ -114,7 +114,7 @@ create or replace package body test_teamcity_reporter as --act select * bulk collect into l_output_data - from table(ut3.ut.run('check_trims_long_output',ut3.ut_teamcity_reporter())); + from table(ut3_develop.ut.run('check_trims_long_output',ut3_develop.ut_teamcity_reporter())); --assert ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); diff --git a/test/ut3_user/reporters/test_tfs_junit_reporter.pkb b/test/ut3_user/reporters/test_tfs_junit_reporter.pkb index 196a2ec08..7eb4f8ab6 100644 --- a/test/ut3_user/reporters/test_tfs_junit_reporter.pkb +++ b/test/ut3_user/reporters/test_tfs_junit_reporter.pkb @@ -13,8 +13,8 @@ create or replace package body test_tfs_junit_reporter as execute immediate q'[create or replace package body check_junit_reporting is procedure test_do_stuff is begin - ut3.ut.expect(1).to_equal(1); - ut3.ut.expect(1).to_equal(2); + ut3_develop.ut.expect(1).to_equal(1); + ut3_develop.ut.expect(1).to_equal(2); end; end;]'; @@ -31,7 +31,7 @@ create or replace package body test_tfs_junit_reporter as execute immediate q'[create or replace package body check_junit_rep_suitepath is procedure check_junit_rep_suitepath is begin - ut3.ut.expect(1).to_equal(1); + ut3_develop.ut.expect(1).to_equal(1); end; end;]'; @@ -53,13 +53,13 @@ create or replace package body test_tfs_junit_reporter as procedure escapes_special_chars is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_reporting',ut3.ut_tfs_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_reporting',ut3_develop.ut_tfs_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).not_to_be_like('%%'); @@ -67,13 +67,13 @@ create or replace package body test_tfs_junit_reporter as end; procedure reports_only_failed_or_errored is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_reporting',ut3.ut_tfs_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_reporting',ut3_develop.ut_tfs_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).not_to_be_like('%Actual: 1 (number) was expected to equal: 1 (number)%'); @@ -81,26 +81,26 @@ create or replace package body test_tfs_junit_reporter as end; procedure check_classname_suite is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_reporting',ut3.ut_tfs_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_reporting',ut3_develop.ut_tfs_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_be_like('%testcase classname="check_junit_reporting"%'); end; procedure check_flatten_nested_suites is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_flat_suitepath',ut3.ut_tfs_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_flat_suitepath',ut3_develop.ut_tfs_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_be_like(' @@ -113,7 +113,7 @@ create or replace package body test_tfs_junit_reporter as end; procedure check_nls_number_formatting is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; l_nls_numeric_characters varchar2(30); begin @@ -125,7 +125,7 @@ create or replace package body test_tfs_junit_reporter as --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_reporting', ut3.ut_tfs_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_reporting', ut3_develop.ut_tfs_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_match('time="[0-9]*\.[0-9]{3,6}"'); @@ -135,17 +135,17 @@ create or replace package body test_tfs_junit_reporter as procedure check_failure_escaped is begin - reporters.check_xml_failure_escaped(ut3.ut_tfs_junit_reporter()); + reporters.check_xml_failure_escaped(ut3_develop.ut_tfs_junit_reporter()); end; procedure check_classname_suitepath is - l_results ut3.ut_varchar2_list; + l_results ut3_develop.ut_varchar2_list; l_actual clob; begin --Act select * bulk collect into l_results - from table(ut3.ut.run('check_junit_rep_suitepath',ut3.ut_tfs_junit_reporter())); + from table(ut3_develop.ut.run('check_junit_rep_suitepath',ut3_develop.ut_tfs_junit_reporter())); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_be_like('%testcase classname="core.check_junit_rep_suitepath"%'); @@ -160,7 +160,7 @@ create or replace package body test_tfs_junit_reporter as procedure check_encoding_included is begin - reporters.check_xml_encoding_included(ut3.ut_tfs_junit_reporter(), 'UTF-8'); + reporters.check_xml_encoding_included(ut3_develop.ut_tfs_junit_reporter(), 'UTF-8'); end; end; From 0d9eddc4debaa12154f259eeb76e165399d7f8b9 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 15 Mar 2020 22:43:56 +0000 Subject: [PATCH 056/887] Fixing examples run --- .travis/run_examples.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.travis/run_examples.sh b/.travis/run_examples.sh index 2f05b101b..6a9affde5 100755 --- a/.travis/run_examples.sh +++ b/.travis/run_examples.sh @@ -1,14 +1,17 @@ #!/bin/bash +cd "$(dirname "$(readlink -f "$0")")"/../examples + set -ev "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR < Date: Sun, 15 Mar 2020 22:51:20 +0000 Subject: [PATCH 057/887] Enabled echo and feedback for examples --- .travis/run_examples.sh | 4 ---- examples/RunAllExamples.sql | 4 ++-- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.travis/run_examples.sh b/.travis/run_examples.sh index 6a9affde5..935037245 100755 --- a/.travis/run_examples.sh +++ b/.travis/run_examples.sh @@ -5,10 +5,6 @@ cd "$(dirname "$(readlink -f "$0")")"/../examples set -ev "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR < Date: Sun, 15 Mar 2020 22:58:38 +0000 Subject: [PATCH 058/887] Enabled echo and feedback for examples --- examples/RunDeveloperExamples.sql | 4 ++-- examples/RunUserExamples.sql | 4 ++-- examples/between_string/run_betwnstr_test_coverage.sql | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/examples/RunDeveloperExamples.sql b/examples/RunDeveloperExamples.sql index d34914b58..eaf87c143 100644 --- a/examples/RunDeveloperExamples.sql +++ b/examples/RunDeveloperExamples.sql @@ -1,7 +1,7 @@ PROMPT Run developer examples Clear Screen -set echo off -set feedback off +set echo on +set feedback on set linesize 1000 exec ut_ansiconsole_helper.color_enabled(true); diff --git a/examples/RunUserExamples.sql b/examples/RunUserExamples.sql index 5323a07aa..702ccbce8 100644 --- a/examples/RunUserExamples.sql +++ b/examples/RunUserExamples.sql @@ -1,6 +1,6 @@ PROMPT Run user examples -set echo off -set feedback off +set echo on +set feedback on set linesize 1000 prompt Common examples from web diff --git a/examples/between_string/run_betwnstr_test_coverage.sql b/examples/between_string/run_betwnstr_test_coverage.sql index efbbb20fe..ab75872ce 100644 --- a/examples/between_string/run_betwnstr_test_coverage.sql +++ b/examples/between_string/run_betwnstr_test_coverage.sql @@ -11,7 +11,7 @@ set serveroutput on size unlimited format truncated set feedback off set termout off spool coverage.html -exec ut.run(user, ut_coverage_html_reporter(a_project_name=>'Demo of between string function tests', a_include_object_list=>ut_varchar2_list('ut3.betwnstr'))); +exec ut.run(user, ut_coverage_html_reporter(a_project_name=>'Demo of between string function tests', a_include_object_list=>ut_varchar2_list('betwnstr'))); spool off From eb5dad665e6b7a11fc44f42c24cb95a99edf1efb Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 15 Mar 2020 23:30:19 +0000 Subject: [PATCH 059/887] Changed the way session context is created. --- docs/userguide/annotations.md | 10 ++++++++-- source/core/session_context/ut_session_context.pkb | 4 ---- source/install.sql | 9 +-------- 3 files changed, 9 insertions(+), 14 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8f4acbd3a..355a03f7b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -2064,9 +2064,15 @@ When processing the test suite `test_employee_pkg` defined in [Example of annota ## sys_context -It is possible to access information about currently running suite, test and befire/after procedure form within PLSQL procedure using SYS_CONTEXT. - +It is possible to access information about currently running suite. The information is available by calling `sys_context( 'UT3_INFO', attribute )`. +It can be accessed from any procecure invoked as part of utPLSQL test execution. + +**Note:** +> Context name is derived from schema name where utPLSQL is installed. +> The context name in below examples represents the default install schema -> `UT3` +> If you install utPLSQL into another schema the context name will be different. +> For example if utPLSQL is installed into `HR` schema, the context name will be `HR_INFO` Following attributes are populated: - Always: diff --git a/source/core/session_context/ut_session_context.pkb b/source/core/session_context/ut_session_context.pkb index 427d722da..2364d8513 100644 --- a/source/core/session_context/ut_session_context.pkb +++ b/source/core/session_context/ut_session_context.pkb @@ -15,11 +15,7 @@ create or replace package body ut_session_context as See the License for the specific language governing permissions and limitations under the License. */ - $IF $$SELF_TESTING_INSTALL $THEN gc_context_name constant varchar2(30) := ut_utils.ut_owner()||'_INFO'; - $ELSE - gc_context_name constant varchar2(30) := 'UT3_INFO'; - $END procedure set_context(a_name varchar2, a_value varchar2) is begin diff --git a/source/install.sql b/source/install.sql index 1f9913b0a..253b13fb2 100644 --- a/source/install.sql +++ b/source/install.sql @@ -34,14 +34,7 @@ alter session set current_schema = &&ut3_owner; @@check_sys_grants.sql "'CREATE TYPE','CREATE VIEW','CREATE SYNONYM','CREATE SEQUENCE','CREATE PROCEDURE','CREATE TABLE', 'CREATE CONTEXT'" --set define off -begin - $if $$self_testing_install $then - execute immediate 'create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_context'; - $else - execute immediate 'create or replace context ut3_info using &&ut3_owner..ut_session_context'; - $end -end; -/ +create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_context; --dbms_output buffer cache table @@install_component.sql 'core/ut_dbms_output_cache.sql' From 22f0ec7f791e995fb249812eb806ad0358ae4940 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 16 Mar 2020 00:11:40 +0000 Subject: [PATCH 060/887] Fixed failing tests - wrong context name --- source/create_synonyms.sql | 2 +- test/ut3_user/api/test_ut_run.pkb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index 36dc465de..425ca57a6 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -36,7 +36,7 @@ set termout off spool params.sql.tmp select case - when upper('&&ut3_user') = 'PUBLIC' then q'[define action_type='public' + when upper('&&ut3_user') = 'PUBLIC' then q'[define action_type='or replace public' ]'||q'[define ut3_user='' ]'||q'[define grantee='PUBLIC']' else q'[define action_type='or replace' diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 8aed1d36e..5142b1770 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1120,7 +1120,7 @@ Failures:% begin select attribute||'='||value bulk collect into l_results - from session_context where namespace = 'UT3_INFO' + from session_context where namespace = 'UT3_DEVELOP_INFO' order by attribute; for i in 1 .. l_results.count loop dbms_output.put_line( upper(a_procedure_name) ||':'|| l_results(i) ); @@ -1393,7 +1393,7 @@ Failures:% begin open l_actual for select attribute||'='||value - from session_context where namespace = 'UT3_INFO'; + from session_context where namespace = 'UT3_DEVELOP_INFO'; ut.expect(l_actual).to_be_empty(); end; From 09b79bfc07e7fe679fc1986999f9ef8e5ee89581 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 17 Mar 2020 14:11:13 +0000 Subject: [PATCH 061/887] Removed copy of ojdbc jar files - no longed valid and no longer needed. --- development/refresh_sources.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/development/refresh_sources.sh b/development/refresh_sources.sh index 9474c3553..e051787a1 100755 --- a/development/refresh_sources.sh +++ b/development/refresh_sources.sh @@ -16,4 +16,3 @@ curl -Lk -o utPLSQL-cli.zip https://github.com/utPLSQL/utPLSQL-cli/releases/down # unzip utPLSQL-cli and remove the zip file unzip utPLSQL-cli.zip && chmod u+x utPLSQL-cli/bin/utplsql && rm utPLSQL-cli.zip -cp development/*.jar utPLSQL-cli/lib/ From 6e2a4b47f511e745bef7503e54b3443651ee35d6 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 17 Mar 2020 14:15:00 +0000 Subject: [PATCH 062/887] Updated documentation. No need to download OJDBC drivers anymore. --- CONTRIBUTING.md | 11 +++-------- docs/index.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/running-unit-tests.md | 1 - readme.md | 2 +- 5 files changed, 6 insertions(+), 12 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 6e4e8fe7c..895b53fb9 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -43,10 +43,11 @@ Your local environment can be of any flavor (Unix/Linux/Windows/Mac). At minimum you need to have Oracle database 11.2 XE accessible for the project and SYS account access to install and develop utPLSQL. We use four different database accounts (users) for development process. -* `ut3_latest_release` - holds latest released version of utPLSQL. This schema holds the testing framework used for self-testing of utPLSQL development. -* `ut3` - holds the version of utPLSQL of your current branch. This is the schema you will be working on. +* `ut3` - holds latest released version of utPLSQL. This schema holds the testing framework used for self-testing of utPLSQL development. +* `ut3_develop` - holds the version of utPLSQL of your current branch. This is the schema you will be working on. * `ut3_tester` - holds unit test packages for development of utPLSQL. * `ut3$user#` - used for testing accessibility to schema names with special characters. +* `ut3_tester_helper` - elevated privileges user, used for creating and dropping objects in other schemas during test run. @@ -89,12 +90,6 @@ export CONNECTION_STR=127.0.0.1:1521/xe # Adjust the connect string export ORACLE_PWD=oracle # Adjust your local SYS password ``` -### Download Oracle JDBC drivers - -Download `ojdbc8-xxx.jar` and `orai18n-xxx.jar` from [Oracle](https://www.oracle.com/technetwork/database/features/jdbc/jdbc-ucp-122-3110062.html). -Place them in `development` directory of the project. - - ### Download utPLSQL release sources and utplsq-cli The below script is fetching latest release version from utPLSQL repository. Latest release version is used for self-testing. diff --git a/docs/index.md b/docs/index.md index f641c25ae..84cf62691 100644 --- a/docs/index.md +++ b/docs/index.md @@ -57,7 +57,7 @@ Amongst many benefits they provide ability to: * use many reporting formats simultaneously and save reports to files (publish) * map your project source files and test files into database objects -Just download the [latest client](https://github.com/utPLSQL/utPLSQL-cli/releases/latest), download Oracle jdbc driver you are good to go. +Download the [latest client](https://github.com/utPLSQL/utPLSQL-cli/releases/latest) and you are good to go. See [project readme](https://github.com/utPLSQL/utPLSQL-cli/blob/develop/README.md) for details. # Coverage diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 022fce376..2b4189f38 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -243,7 +243,7 @@ By default, utPLSQL will convert file paths into database objects using the foll > This is done to simplify the syntax of regular expressions. Regular expression will always use '/' as a directory separator on a file path regardless of whether you're on a Windows or Unix system. **Note** -> Below examples assume that you have downloaded latest version of [utPLSQL-cli](https://github.com/utPLSQL/utPLSQL-cli/releases), extracted it into your projects root directory (my_project) and placed ojdbc8.jar and orai18n.jar files in utPLSQL-cli\lib directory. +> Below examples assume that you have downloaded latest version of [utPLSQL-cli](https://github.com/utPLSQL/utPLSQL-cli/releases) and extracted it into your projects root directory (my_project). > The examples assume that you run the utPLSQL-cli from `my_project` directory. Windows: diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 490a21c1c..63182f9ef 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -31,7 +31,6 @@ curl -Lk "${DOWNLOAD_URL}" -o utplsql-cli.zip unzip -q utplsql-cli.zip ``` -Keep in mind that you will need to download/provide Oracle JDBC driver separately, as it is not part of utPLSQL-cli due to licensing restrictions. # ut.run diff --git a/readme.md b/readme.md index 0d66152d0..c3429a07e 100644 --- a/readme.md +++ b/readme.md @@ -85,7 +85,7 @@ Amongst many benefits it provides ability to: * use many reporting formats simultaneously and save reports to files (publish) * map your project source files and test files into database objects -Just download the [latest client](https://github.com/utPLSQL/utPLSQL-cli/releases/latest), download Oracle jdbc driver you are good to go. +Download the [latest client](https://github.com/utPLSQL/utPLSQL-cli/releases/latest) and are good to go. See [project readme](https://github.com/utPLSQL/utPLSQL-cli/blob/develop/README.md) for details. From ea4c9fb851f00de72a97d8282283e1d0f84a6193 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 17 Mar 2020 21:00:59 +0000 Subject: [PATCH 063/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 2fe5655e8..b6522f218 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 576f861d1..1152fecd6 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index e868fecd0..56eaa0bb5 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 8df21fea3..8a71b3ae3 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 84cf62691..d4a394ab7 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index d6fc7bcd0..b049bc25e 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 355a03f7b..ea8ebce66 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 6046a2241..ae1023f06 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 2b4189f38..0279f2ff6 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a10554155..43ae9dbea 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 111a95ff7..a0fc5ea6c 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 5dcf6c056..8e4d9f5ef 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 4b42710a9..279b02213 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Downloading latest version of utPLSQL diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index f4fcb065e..8efdcfaa9 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index f2a86cf5d..1e820dc79 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 63182f9ef..a81807f7a 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 5e33365af..2c49ebe75 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3357--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 6f92f7901..e917c1288 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3357-develop + * secion v3.1.11.3367-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 2ecbbc095..441202df8 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3357-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3367-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From b8c028766a6e87b700f68b11c6f62cca1daa8f94 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 25 Mar 2020 00:22:00 +0000 Subject: [PATCH 064/887] Resolves issue #1060 with suites not properly built with GERMAN (non-standard) NLS_SORT --- source/core/ut_suite_cache_manager.pkb | 19 +++--- test/ut3_tester/core/test_suite_manager.pks | 5 +- test/ut3_user/api/test_ut_run.pkb | 68 +++++++++++++++++++++ test/ut3_user/api/test_ut_run.pks | 7 +++ 4 files changed, 88 insertions(+), 11 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 7c4b1ee93..06c4c76a5 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -161,13 +161,16 @@ create or replace package body ut_suite_cache_manager is begin return case when a_random_seed is null then q'[ - replace( - --suite path until objects name (excluding contexts and test path) with trailing dot (full stop) - substr( c.obj.path, 1, instr( c.obj.path, lower(c.obj.object_name), -1 ) + length(c.obj.object_name) ), - '.', - --'.' replaced with chr(0) to assure that child elements come before parent when sorting in descending oder - chr(0) - ) desc nulls last, + nlssort( + replace( + /*suite path until objects name (excluding contexts and test path) with trailing dot (full stop)*/ + substr( c.obj.path, 1, instr( c.obj.path, lower(c.obj.object_name), -1 ) + length(c.obj.object_name) ), + '.', + /*'.' replaced with chr(0) to assure that child elements come before parent when sorting in descending order*/ + chr(0) + ), + 'nls_sort=binary' + )desc nulls last, case when c.obj.self_type = 'UT_SUITE_CONTEXT' then ( select max( x.line_no ) + 1 from ut_suite_cache x @@ -178,7 +181,7 @@ create or replace package body ut_suite_cache_manager is else c.obj.line_no end, - --assures that child contexts come before parent contexts + /*assures that child contexts come before parent contexts*/ regexp_count(c.obj.path,'\.') desc, :a_random_seed]' else diff --git a/test/ut3_tester/core/test_suite_manager.pks b/test/ut3_tester/core/test_suite_manager.pks index ed318b890..90b589b9e 100644 --- a/test/ut3_tester/core/test_suite_manager.pks +++ b/test/ut3_tester/core/test_suite_manager.pks @@ -3,9 +3,6 @@ create or replace package test_suite_manager is --%suite(suite_manager) --%suitepath(utplsql.ut3_tester.core) - procedure create_dummy_long_test_package; - - procedure drop_dummy_long_test_package; --%beforeall procedure compile_dummy_packages; @@ -170,6 +167,8 @@ create or replace package test_suite_manager is --%beforetest(create_dummy_long_test_package) --%aftertest(drop_dummy_long_test_package) procedure add_new_long_test_package; + procedure create_dummy_long_test_package; + procedure drop_dummy_long_test_package; end test_suite_manager; / diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 5142b1770..e3af7c5ad 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -780,6 +780,74 @@ Failures:% execute immediate 'drop package '||gc_owner||'.'||gc_owner; end; + procedure create_suites_with_path is + pragma autonomous_transaction; + begin + execute immediate q'[create or replace package ut_abc is + -- %suite + -- %suitepath(main.abc) + + -- %test + procedure ut_test_01; + end ut_abc;]'; + + execute immediate q'[create or replace package body ut_abc + is + procedure ut_test_01 as begin ut.expect(true).to_be_true(); end; + end;]'; + + execute immediate q'[create or replace package ut_abc_def + is + -- %suite + -- %suitepath(main.abc_def) + + -- %test + procedure ut_test_01; + end ut_abc_def;]'; + + execute immediate q'[create or replace package body ut_abc_def + is + procedure ut_test_01 as begin ut.expect(true).to_be_true(); end; + end;]'; + + end; + + procedure drop_suites_with_path is + pragma autonomous_transaction; + begin + execute immediate q'[drop package ut_abc]'; + execute immediate q'[drop package ut_abc_def]'; + end; + + procedure run_suite_with_nls_sort is + L_current_sort varchar2(2000); + l_results ut3_develop.ut_varchar2_list; + l_expected clob; + begin + --Arrange + select value + into l_current_sort + from nls_session_parameters where parameter = 'NLS_SORT'; + + execute immediate 'alter session set nls_sort=GERMAN'; + + --Act + select * + bulk collect into l_results + from table ( ut3_develop.ut.run( gc_owner||':main' ) ); + --Assert + l_expected := q'[main% + abc_def% + ut_abc_def% + ut_test_01% + abc% + ut_abc% + ut_test_01%]'; + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( l_expected ); + + execute immediate 'alter session set nls_sort='||l_current_sort; + end; + procedure run_with_random_order is l_random_results ut3_develop.ut_varchar2_list; l_results ut3_develop.ut_varchar2_list; diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index ac2e50e25..753af79da 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -155,6 +155,13 @@ create or replace package test_ut_run is procedure create_schema_name_package; procedure drop_schema_name_package; + --%test(Runs properly formed suite hierarchy regardless of NLS_SORT settings - Issue #1060) + --%beforetest(create_suites_with_path) + --%aftertest(drop_suites_with_path) + procedure run_suite_with_nls_sort; + procedure create_suites_with_path; + procedure drop_suites_with_path; + --%endcontext --%context(random_order) From fa4c6b7ccaf4b55671ac7d3ea2e7f73b342d39a5 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 25 Mar 2020 21:21:56 +0000 Subject: [PATCH 065/887] Restructuring utPSLQL install guide. Resolves #1062 --- docs/userguide/install.md | 70 ++++++++++++++++++++++++--------------- 1 file changed, 43 insertions(+), 27 deletions(-) diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 279b02213..54d326160 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,10 +1,35 @@ ![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) -# Downloading latest version of utPLSQL +# Supported database versions + +utPLSQL is continuously tested against following versions of Oracle databases +* 11g R2 +* 12c +* 12c R2 +* 18c +* 19c + +We do our best to assure fill compatibility with supported versions of Oracle databases [See](http://www.oracle.com/us/support/library/lifetime-support-technology-069183.pdf#page=6) + +# Downloading utPLSQL + +## Manual download + +- Go to GitHub releases page for utPLSQL `https://github.com/utPLSQL/utPLSQL/releases` +- Download and one of files + - utPLSQL.tar.gz + - utPLSQL.zip + +The files have identical content but different compression (tar / zip ) so choose whichever you preref depending on your platform (Win/Mac/Unix/Linux) + -To download latest version of utPLSQL from github on both Unix/Linux as well as Windows machines use the below snippets. +## Scripted download of latest utPLSQL version -## Unix/Linux +The below snippets can be used to download latest version of utPLSQL from github releases. + +Installation instructions are outlined in next sections of this document. + +### Unix/Linux ```bash #!/bin/bash @@ -22,7 +47,7 @@ You may download with a one-liner if that is more convenient. curl -LOk $(curl --silent https://api.github.com/repos/utPLSQL/utPLSQL/releases/latest | awk '/browser_download_url/ { print $2 }' | grep ".zip\"" | sed 's/"//g') ``` -## Windows +### Windows To run the script on windows you will need [PowerShell 3.0](https://blogs.technet.microsoft.com/heyscriptingguy/2013/06/02/weekend-scripter-install-powershell-3-0-on-windows-7/) or above. You will also need .NET 4.0 Framework or above. @@ -51,29 +76,6 @@ foreach ($i in $urlList) { } ``` -# Checking environment and utPLSQL version - -To check the framework version execute the following query: -```sql -select substr(ut.version(),1,60) as ut_version from dual; -``` - -Additionally you may retrieve more information about your environment by executing the following query: -```sql -select - xmlserialize( content xmltype(ut_run_info()) as clob indent size = 2 ) - from dual; -``` - -# Supported database versions - -The utPLSQL may be installed on any supported version of Oracle Database [see](http://www.oracle.com/us/support/library/lifetime-support-technology-069183.pdf#page=6) -* 11g R2 -* 12c -* 12c R2 -* 18c -* 19c - # Headless installation utPLSQL can be installed with DDL trigger, to enable tracking of DDL changes to your unit test packages. @@ -235,6 +237,20 @@ The following tools that support the SQL*Plus commands can be used to run the in - [SQLcl](http://www.oracle.com/technetwork/developer-tools/sqlcl/overview/index.html) - [Oracle SQL Developer](http://www.oracle.com/technetwork/developer-tools/sql-developer/overview/index.html) +# Checking environment and utPLSQL version + +To check the framework version execute the following query: +```sql +select substr(ut.version(),1,60) as ut_version from dual; +``` + +Additionally you may retrieve more information about your environment by executing the following query: +```sql +select + xmlserialize( content xmltype(ut_run_info()) as clob indent size = 2 ) + from dual; +``` + # Additional requirements In order to use the Code Coverage functionality of utPLSQL, users executing the tests must have the CREATE privilege on the PLSQL code that the coverage is gathered on. From 62ef235a6559993ccd5896e6fff6ff3a60eb5785 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 26 Mar 2020 21:32:00 +0000 Subject: [PATCH 066/887] Fixed some typos --- docs/userguide/install.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 54d326160..2da512eaa 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -9,25 +9,26 @@ utPLSQL is continuously tested against following versions of Oracle databases * 18c * 19c -We do our best to assure fill compatibility with supported versions of Oracle databases [See](http://www.oracle.com/us/support/library/lifetime-support-technology-069183.pdf#page=6) +We do our best to assure full compatibility with supported versions of Oracle databases [See](http://www.oracle.com/us/support/library/lifetime-support-technology-069183.pdf#page=6) # Downloading utPLSQL ## Manual download -- Go to GitHub releases page for utPLSQL `https://github.com/utPLSQL/utPLSQL/releases` -- Download and one of files +- Go to GitHub releases page for utPLSQL [`https://github.com/utPLSQL/utPLSQL/releases`](https://github.com/utPLSQL/utPLSQL/releases) +- Choose the version to download - latest is always greatest +- Download one of files - utPLSQL.tar.gz - utPLSQL.zip -The files have identical content but different compression (tar / zip ) so choose whichever you preref depending on your platform (Win/Mac/Unix/Linux) +The files have identical content but use different compression (tar / zip ) so choose whichever you prefer depending on your platform (Win/Mac/Unix/Linux). ## Scripted download of latest utPLSQL version The below snippets can be used to download latest version of utPLSQL from github releases. -Installation instructions are outlined in next sections of this document. +After downloading follow the installation instructions in next sections of this document. ### Unix/Linux From 72a680988398e1952b5d1ea774be493473ac1e07 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Fri, 27 Mar 2020 22:55:04 +0000 Subject: [PATCH 067/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index b6522f218..a2fd028f0 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 1152fecd6..863f71804 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 56eaa0bb5..f823ebea9 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 8a71b3ae3..98c7bfd68 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index d4a394ab7..f3f6be050 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index b049bc25e..3dc0487a8 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index ea8ebce66..648a5c06f 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index ae1023f06..3dae9b813 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0279f2ff6..463a115d2 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 43ae9dbea..e81b24ead 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index a0fc5ea6c..b9f30abef 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8e4d9f5ef..498cf2338 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 2da512eaa..c9506c6af 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 8efdcfaa9..f43a63677 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 1e820dc79..afe851f2e 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a81807f7a..d35940acc 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 2c49ebe75..8d2b01bd8 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3367--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index e917c1288..95ada6e13 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3367-develop + * secion v3.1.11.3375-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 441202df8..6558cc8d7 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3367-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3375-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 83ee513ed61574f8e94cb3b61746441266ceb17e Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 29 Mar 2020 17:56:46 +0100 Subject: [PATCH 068/887] Added explicit requirements Resolves #1064 updated invite link for slack as the herokuapp invite solution doesn't since quite some time and Slack has it's own invite links now. --- .github/ISSUE_TEMPLATE/feature_request.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/userguide/install.md | 27 ++++++++++++++++++++++- readme.md | 6 ++--- 5 files changed, 32 insertions(+), 7 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index c54bff550..4cd72f51c 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -23,4 +23,4 @@ Add any other context or screenshots about the feature request here. > Please do not create issues for generic SQL or PL/SQL questions. There are other forums and communities to help you with those. See [ASKTom](https://asktom.oracle.com) for example. **Want to discuss** -If you want to discuss your issue, join [our SLACK chat](http://utplsql-slack-invite.herokuapp.com/). +If you want to discuss your issue, join [our SLACK chat](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA). diff --git a/docs/about/project-details.md b/docs/about/project-details.md index f823ebea9..fdc541be9 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -4,7 +4,7 @@ [![chat](http://img.shields.io/badge/GitHub_Project-Active-blue.svg)](https://github.com/utPLSQL/utPLSQL) [![license](http://img.shields.io/badge/license-apache%202.0-blue.svg)](https://www.apache.org/licenses/LICENSE-2.0) -[![chat](http://img.shields.io/badge/chat-slack-blue.svg)](http://utplsql-slack-invite.herokuapp.com/) +[![chat](http://img.shields.io/badge/chat-slack-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) diff --git a/docs/about/support.md b/docs/about/support.md index 98c7bfd68..237f22c3b 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -3,4 +3,4 @@ # How to get support - Feel free to post questions, bugs or issues in the [issues area of GitHub](https://github.com/utPLSQL/utPLSQL/issues) -- Join developers at the [utPLSQL team](http://utplsql-slack-invite.herokuapp.com) on [Slack](https://slack.com/) +- [Join](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) developers team on utPLSQL [Slack](https://utplsql.slack.com/) diff --git a/docs/userguide/install.md b/docs/userguide/install.md index c9506c6af..61550cf85 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -11,6 +11,31 @@ utPLSQL is continuously tested against following versions of Oracle databases We do our best to assure full compatibility with supported versions of Oracle databases [See](http://www.oracle.com/us/support/library/lifetime-support-technology-069183.pdf#page=6) +# Requirements + +## Licensed features required + +utPLSQL doesn't require any extra licensed features of Oracle database. It can be installed on any Standard Edition Oracle Database. + +In fact, it even supports Oracle 11g XE which is a free Oracle Database version with minimal features and storage limits. + +## Storage requirements + +utPLSQL will use tablespace for the following: +- storage of annotation cache +- storage of suite cache +- storage of profiler results +- storage for staging utPLSQL reports outputs + + +utPLSQL purges the staging storage for reports while fetching reports to screen / saving reports to files. + +Suite and annotation cache storage requirements are minimal and unless you have hundreds of thousands of tests, you'll probably not even notice the space used. + +Profiler results may require regular purging to assure low space consumption. +utPLSQl does not purge profiler tables as those tables can can be shared with other tools. + + # Downloading utPLSQL ## Manual download @@ -143,7 +168,7 @@ sqlplus sys/sys_pass@db as sysdba @install_headless_with_trigger.sql utp3 my_ver # Recommended Schema It is highly recommended to install utPLSQL in it's own schema. You are free to choose any name for this schema. -Installing uPLSQL into shared schema is really not recommended as you loose isolation of framework. +Installing uPLSQL into a shared schema is really not recommended as you loose isolation of framework. If the installing user and utPLSQL owner is one and the same, the user must have the following Oracle system permissions before you can proceed with the installation. diff --git a/readme.md b/readme.md index c3429a07e..715b87302 100644 --- a/readme.md +++ b/readme.md @@ -5,7 +5,7 @@ [![license](https://img.shields.io/github/license/utPLSQL/utPLSQL.svg)](https://www.apache.org/licenses/LICENSE-2.0) [![latest-release](https://img.shields.io/github/release/utPLSQL/utPLSQL.svg)](https://github.com/utPLSQL/utPLSQL/releases) [![Download statistics](https://img.shields.io/github/downloads/utPLSQL/utPLSQL/total.svg)](http://gra.caldis.me/?url=https://github.com/utPLSQL/utPLSQL) -[![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](http://utplsql-slack-invite.herokuapp.com/) +[![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) [![build](https://img.shields.io/travis/utPLSQL/utPLSQL/master.svg?label=master%20branch)](https://travis-ci.org/utPLSQL/utPLSQL) @@ -163,7 +163,7 @@ We welcome new developers to join our community and contribute to the utPLSQL pr If you are interested in helping please read our [guide to contributing](CONTRIBUTING.md) The best place to start is to read the documentation and get familiar with the existing code base. A [slack chat](https://utplsql.slack.com/) is the place to go if you want to talk with team members. -To sign up to the chat use [this link](http://utplsql-slack-invite.herokuapp.com/) +To sign up to the chat use [this link](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA). ---------- @@ -183,7 +183,7 @@ __Project Directories__ ---------- -If you have a great feature in mind, that you would like to see in utPLSQL v3 please create an [issue on GitHub](https://github.com/utPLSQL/utPLSQL/issues) or discuss it with us in the [Slack chat rooms](http://utplsql-slack-invite.herokuapp.com/). +If you have a great feature in mind, that you would like to see in utPLSQL v3 please create an [issue on GitHub](https://github.com/utPLSQL/utPLSQL/issues) or discuss it with us in the [slack chat rooms](https://utplsql.slack.com/). Use [invite link](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) to join the chat. # Version 2 to Version 3 Comparison From c5d53fbdd36fc08aff977c015ee7ab6330fe88b7 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 29 Mar 2020 20:34:32 +0100 Subject: [PATCH 069/887] Added explicit 11g release 2 requirement --- docs/userguide/install.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 61550cf85..e2fae2944 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -13,6 +13,8 @@ We do our best to assure full compatibility with supported versions of Oracle da # Requirements +utPLSQL will run on any Oracle Database version 11g relase 2 or above. + ## Licensed features required utPLSQL doesn't require any extra licensed features of Oracle database. It can be installed on any Standard Edition Oracle Database. From 789ad61af1ff2509ed737ae87428bda506a1d1b4 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Wed, 1 Apr 2020 12:09:46 +0000 Subject: [PATCH 070/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index a2fd028f0..dc1b0c36e 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 863f71804..48355af2e 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index fdc541be9..964b7a743 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 237f22c3b..27b9d0798 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index f3f6be050..73a257690 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 3dc0487a8..b46032a15 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 648a5c06f..c573f8858 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 3dae9b813..0ac1a14c8 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 463a115d2..b0fcab539 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e81b24ead..a7603da59 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b9f30abef..5924be80f 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 498cf2338..c528766ae 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index e2fae2944..a65943e81 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index f43a63677..32506007c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index afe851f2e..6eb5cf4d0 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index d35940acc..243026021 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 8d2b01bd8..7328451ef 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 95ada6e13..ba98763e0 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3375-develop + * secion v3.1.11.3380-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6558cc8d7..6ed6c4ac9 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3375-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3380-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 48abf1a83c36ca44c2f395eceea5473ac99a0221 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 1 Jun 2020 21:58:35 +0100 Subject: [PATCH 071/887] Initial checkin --- source/expectations/matchers/ut_equal.tpb | 7 +++++++ source/expectations/matchers/ut_equal.tps | 3 ++- source/expectations/matchers/ut_matcher.tps | 7 +++---- .../expectations/matchers/ut_matcher_base.tpb | 20 +++++++++++++++++++ .../expectations/matchers/ut_matcher_base.tps | 4 ++++ source/expectations/ut_expectation.tpb | 10 +++++----- source/expectations/ut_expectation.tps | 8 ++++---- .../expectations/ut_expectation_compound.tpb | 5 +++-- .../expectations/ut_expectation_compound.tps | 4 ++-- 9 files changed, 50 insertions(+), 18 deletions(-) create mode 100644 source/expectations/matchers/ut_matcher_base.tpb create mode 100644 source/expectations/matchers/ut_matcher_base.tps diff --git a/source/expectations/matchers/ut_equal.tpb b/source/expectations/matchers/ut_equal.tpb index afa2148f3..4f6fee119 100644 --- a/source/expectations/matchers/ut_equal.tpb +++ b/source/expectations/matchers/ut_equal.tpb @@ -172,6 +172,13 @@ create or replace type body ut_equal as return l_result; end; + member procedure include(self in ut_equal, a_items varchar2) is + --l_result ut_equal := self; + begin + null; + --l_result.expectation.to_(l_result ); + end; + member function exclude(a_items varchar2) return ut_equal is l_result ut_equal := self; begin diff --git a/source/expectations/matchers/ut_equal.tps b/source/expectations/matchers/ut_equal.tps index 1f42324d7..3a2ad6061 100644 --- a/source/expectations/matchers/ut_equal.tps +++ b/source/expectations/matchers/ut_equal.tps @@ -43,6 +43,7 @@ create or replace type ut_equal force under ut_comparison_matcher( constructor function ut_equal(self in out nocopy ut_equal, a_expected dsinterval_unconstrained, a_nulls_are_equal boolean := null) return self as result, constructor function ut_equal(self in out nocopy ut_equal, a_expected json_element_t, a_nulls_are_equal boolean := null) return self as result, member function include(a_items varchar2) return ut_equal, + member procedure include(self in ut_equal, a_items varchar2), member function include(a_items ut_varchar2_list) return ut_equal, member function exclude(a_items varchar2) return ut_equal, member function exclude(a_items ut_varchar2_list) return ut_equal, @@ -56,4 +57,4 @@ create or replace type ut_equal force under ut_comparison_matcher( member function uc return ut_equal ) not final -/ + diff --git a/source/expectations/matchers/ut_matcher.tps b/source/expectations/matchers/ut_matcher.tps index 34e1742df..b37c06741 100644 --- a/source/expectations/matchers/ut_matcher.tps +++ b/source/expectations/matchers/ut_matcher.tps @@ -1,4 +1,4 @@ -create or replace type ut_matcher authid current_user as object( +create or replace type ut_matcher force under ut_matcher_base( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -15,10 +15,9 @@ create or replace type ut_matcher authid current_user as object( See the License for the specific language governing permissions and limitations under the License. */ - self_type varchar2(250), is_errored integer, is_negated_flag number(1,0), - + expectation ut_expectation, /* function: run_matcher @@ -41,4 +40,4 @@ create or replace type ut_matcher authid current_user as object( member function negated return ut_matcher, member function is_negated return boolean ) not final not instantiable -/ + diff --git a/source/expectations/matchers/ut_matcher_base.tpb b/source/expectations/matchers/ut_matcher_base.tpb new file mode 100644 index 000000000..bf3d9a187 --- /dev/null +++ b/source/expectations/matchers/ut_matcher_base.tpb @@ -0,0 +1,20 @@ +create or replace type body ut_matcher_base as + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + +end; +/ diff --git a/source/expectations/matchers/ut_matcher_base.tps b/source/expectations/matchers/ut_matcher_base.tps new file mode 100644 index 000000000..7c18d35d7 --- /dev/null +++ b/source/expectations/matchers/ut_matcher_base.tps @@ -0,0 +1,4 @@ +create or replace type ut_matcher_base force authid current_user as object( + self_type varchar2(250) +) +not final not instantiable \ No newline at end of file diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index d8ed1f79a..b18e2f7b0 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -15,12 +15,12 @@ create or replace type body ut_expectation as See the License for the specific language governing permissions and limitations under the License. */ - member procedure to_(self in ut_expectation, a_matcher ut_matcher) is + member procedure to_(self in ut_expectation, a_matcher ut_matcher_base) is l_expectation_result boolean; - l_matcher ut_matcher := a_matcher; + l_matcher ut_matcher := treat(a_matcher as ut_matcher); l_message varchar2(32767); begin - if a_matcher.is_negated() then + if l_matcher.is_negated() then self.not_to( a_matcher ); else l_expectation_result := l_matcher.run_matcher( self.actual_data ); @@ -30,9 +30,9 @@ create or replace type body ut_expectation as end if; end; - member procedure not_to(self in ut_expectation, a_matcher ut_matcher) is + member procedure not_to(self in ut_expectation, a_matcher ut_matcher_base) is l_expectation_result boolean; - l_matcher ut_matcher := a_matcher; + l_matcher ut_matcher := treat(a_matcher as ut_matcher); l_message varchar2(32767); begin l_expectation_result := coalesce( l_matcher.run_matcher_negated( self.actual_data ), false ); diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index 37fefd085..ffaa73981 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation authid current_user as object( +create or replace type ut_expectation force authid current_user as object( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -19,8 +19,8 @@ create or replace type ut_expectation authid current_user as object( description varchar2(4000 char), --base matcher executors - member procedure to_(self in ut_expectation, a_matcher ut_matcher), - member procedure not_to(self in ut_expectation, a_matcher ut_matcher), + member procedure to_(self in ut_expectation, a_matcher ut_matcher_base), + member procedure not_to(self in ut_expectation, a_matcher ut_matcher_base), --shortcuts member procedure to_be_null(self in ut_expectation), @@ -172,4 +172,4 @@ create or replace type ut_expectation authid current_user as object( ) not final -/ + diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index 5e7268bd9..8fc67a5c9 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -48,11 +48,12 @@ create or replace type body ut_expectation_compound as return l_result; end; - member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_expectation_compound is + member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal is l_result ut_expectation_compound := self; begin l_result.matcher := ut_equal(a_expected, a_nulls_are_equal); - return l_result; + l_result.matcher.expectation := l_result; + return treat(l_result.matcher as ut_equal); end; member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_expectation_compound is diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index fc413e3fd..ea5f9d30a 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -24,7 +24,7 @@ create or replace type ut_expectation_compound force under ut_expectation( member function to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_expectation_compound, member function not_to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_expectation_compound, - member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_expectation_compound, + member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal, member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_expectation_compound, member function to_contain(a_expected sys_refcursor) return ut_expectation_compound, member function not_to_contain(a_expected sys_refcursor) return ut_expectation_compound, @@ -51,4 +51,4 @@ create or replace type ut_expectation_compound force under ut_expectation( member function uc return ut_expectation_compound, member procedure uc(self in ut_expectation_compound) ) -/ + From 70419127716a0a5e8ad4bad7847f0d16a79af4d7 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 2 Jun 2020 19:46:33 +0100 Subject: [PATCH 072/887] added expectation --- source/expectations/matchers/ut_equal.tpb | 5 ++--- source/expectations/matchers/ut_equal.tps | 4 ++-- source/expectations/matchers/ut_matcher.tps | 4 ++-- .../expectations/matchers/ut_matcher_base.tpb | 20 ------------------- .../expectations/matchers/ut_matcher_base.tps | 3 ++- source/expectations/ut_expectation.tps | 4 ++-- .../expectations/ut_expectation_compound.tpb | 10 +++++----- .../expectations/ut_expectation_compound.tps | 4 ++-- source/install.sql | 3 ++- 9 files changed, 19 insertions(+), 38 deletions(-) delete mode 100644 source/expectations/matchers/ut_matcher_base.tpb diff --git a/source/expectations/matchers/ut_equal.tpb b/source/expectations/matchers/ut_equal.tpb index 4f6fee119..1ac449cf6 100644 --- a/source/expectations/matchers/ut_equal.tpb +++ b/source/expectations/matchers/ut_equal.tpb @@ -173,10 +173,9 @@ create or replace type body ut_equal as end; member procedure include(self in ut_equal, a_items varchar2) is - --l_result ut_equal := self; + l_result ut_equal := self; begin - null; - --l_result.expectation.to_(l_result ); + l_result.expectation.to_(l_result ); end; member function exclude(a_items varchar2) return ut_equal is diff --git a/source/expectations/matchers/ut_equal.tps b/source/expectations/matchers/ut_equal.tps index 3a2ad6061..52f116715 100644 --- a/source/expectations/matchers/ut_equal.tps +++ b/source/expectations/matchers/ut_equal.tps @@ -1,4 +1,4 @@ -create or replace type ut_equal force under ut_comparison_matcher( +create or replace type ut_equal under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -57,4 +57,4 @@ create or replace type ut_equal force under ut_comparison_matcher( member function uc return ut_equal ) not final - +/ diff --git a/source/expectations/matchers/ut_matcher.tps b/source/expectations/matchers/ut_matcher.tps index b37c06741..16af94a1a 100644 --- a/source/expectations/matchers/ut_matcher.tps +++ b/source/expectations/matchers/ut_matcher.tps @@ -1,4 +1,4 @@ -create or replace type ut_matcher force under ut_matcher_base( +create or replace type ut_matcher under ut_matcher_base( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -40,4 +40,4 @@ create or replace type ut_matcher force under ut_matcher_base( member function negated return ut_matcher, member function is_negated return boolean ) not final not instantiable - +/ diff --git a/source/expectations/matchers/ut_matcher_base.tpb b/source/expectations/matchers/ut_matcher_base.tpb deleted file mode 100644 index bf3d9a187..000000000 --- a/source/expectations/matchers/ut_matcher_base.tpb +++ /dev/null @@ -1,20 +0,0 @@ -create or replace type body ut_matcher_base as - /* - utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project - - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - */ - -end; -/ diff --git a/source/expectations/matchers/ut_matcher_base.tps b/source/expectations/matchers/ut_matcher_base.tps index 7c18d35d7..ec37267a0 100644 --- a/source/expectations/matchers/ut_matcher_base.tps +++ b/source/expectations/matchers/ut_matcher_base.tps @@ -1,4 +1,5 @@ create or replace type ut_matcher_base force authid current_user as object( self_type varchar2(250) ) -not final not instantiable \ No newline at end of file +not final not instantiable +/ \ No newline at end of file diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index ffaa73981..95aeb9fce 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation force authid current_user as object( +create or replace type ut_expectation authid current_user as object( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -172,4 +172,4 @@ create or replace type ut_expectation force authid current_user as object( ) not final - +/ diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index 8fc67a5c9..674b468b2 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -48,12 +48,12 @@ create or replace type body ut_expectation_compound as return l_result; end; - member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal is - l_result ut_expectation_compound := self; + member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal is + l_result ut_matcher; begin - l_result.matcher := ut_equal(a_expected, a_nulls_are_equal); - l_result.matcher.expectation := l_result; - return treat(l_result.matcher as ut_equal); + l_result := ut_equal(a_expected, a_nulls_are_equal); + l_result.expectation := self; + return treat(l_result as ut_equal); end; member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_expectation_compound is diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index ea5f9d30a..4b2347859 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation_compound force under ut_expectation( +create or replace type ut_expectation_compound under ut_expectation( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -51,4 +51,4 @@ create or replace type ut_expectation_compound force under ut_expectation( member function uc return ut_expectation_compound, member procedure uc(self in ut_expectation_compound) ) - +/ diff --git a/source/install.sql b/source/install.sql index 253b13fb2..45a67f924 100644 --- a/source/install.sql +++ b/source/install.sql @@ -236,6 +236,8 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/data_values/ut_data_value_xmltype.tps' @@install_component.sql 'expectations/data_values/ut_compound_data_helper.pks' @@install_component.sql 'expectations/data_values/ut_data_value_json.tps' +@@install_component.sql 'expectations/ut_expectation.tps' +@@install_component.sql 'expectations/matchers/ut_matcher_base.tps' @@install_component.sql 'expectations/matchers/ut_matcher.tps' @@install_component.sql 'expectations/matchers/ut_comparison_matcher.tps' @@install_component.sql 'expectations/matchers/ut_be_false.tps' @@ -253,7 +255,6 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/matchers/ut_be_between.tps' @@install_component.sql 'expectations/matchers/ut_be_empty.tps' @@install_component.sql 'expectations/matchers/ut_match.tps' -@@install_component.sql 'expectations/ut_expectation.tps' @@install_component.sql 'expectations/data_values/ut_json_leaf.tpb' @@install_component.sql 'expectations/data_values/ut_json_tree_details.tpb' @@install_component.sql 'expectations/data_values/ut_cursor_column.tpb' From 13d86b6d74e7aee203625e719640edb04e80551b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 2 Jun 2020 21:11:00 +0100 Subject: [PATCH 073/887] Adding more methods --- source/expectations/matchers/ut_equal.tpb | 54 +++++++- source/expectations/matchers/ut_equal.tps | 14 +- .../expectations/ut_expectation_compound.tpb | 129 ++---------------- .../expectations/ut_expectation_compound.tps | 29 +--- 4 files changed, 83 insertions(+), 143 deletions(-) diff --git a/source/expectations/matchers/ut_equal.tpb b/source/expectations/matchers/ut_equal.tpb index 1ac449cf6..5eb256c22 100644 --- a/source/expectations/matchers/ut_equal.tpb +++ b/source/expectations/matchers/ut_equal.tpb @@ -173,8 +173,14 @@ create or replace type body ut_equal as end; member procedure include(self in ut_equal, a_items varchar2) is + begin + include( ut_varchar2_list( a_items ) ); + end; + + member procedure include(self in ut_equal, a_items ut_varchar2_list) is l_result ut_equal := self; begin + l_result.options.include.add_items(a_items); l_result.expectation.to_(l_result ); end; @@ -192,6 +198,18 @@ create or replace type body ut_equal as return l_result; end; + member procedure exclude(self in ut_equal, a_items varchar2) is + begin + exclude( ut_varchar2_list( a_items ) ); + end; + + member procedure exclude(self in ut_equal, a_items ut_varchar2_list) is + l_result ut_equal := self; + begin + l_result.options.exclude.add_items(a_items); + l_result.expectation.to_(l_result ); + end; + member function unordered return ut_equal is l_result ut_equal := self; begin @@ -199,6 +217,13 @@ create or replace type body ut_equal as return l_result; end; + member procedure unordered(self in ut_equal) is + l_result ut_equal := self; + begin + l_result.options.unordered(); + l_result.expectation.to_(l_result ); + end; + member function join_by(a_columns varchar2) return ut_equal is l_result ut_equal := self; begin @@ -215,18 +240,43 @@ create or replace type body ut_equal as return l_result; end; - member function uc return ut_equal is + member procedure join_by(self in ut_equal, a_columns varchar2) is begin - return unordered_columns; + join_by( ut_varchar2_list( a_columns ) ); end; + member procedure join_by(self in ut_equal, a_columns ut_varchar2_list) is + l_result ut_equal := self; + begin + l_result.options.unordered(); + l_result.options.join_by.add_items(a_columns); + l_result.expectation.to_(l_result ); + end; + member function unordered_columns return ut_equal is l_result ut_equal := self; begin l_result.options.unordered_columns(); return l_result; end; + + member procedure unordered_columns(self in ut_equal) is + l_result ut_equal := self; + begin + l_result.options.unordered_columns(); + l_result.expectation.to_(l_result ); + end; + + member function uc return ut_equal is + begin + return unordered_columns; + end; + member procedure uc(self in ut_equal) is + begin + unordered_columns; + end; + overriding member function run_matcher(self in out nocopy ut_equal, a_actual ut_data_value) return boolean is l_result boolean; begin diff --git a/source/expectations/matchers/ut_equal.tps b/source/expectations/matchers/ut_equal.tps index 52f116715..8701fca94 100644 --- a/source/expectations/matchers/ut_equal.tps +++ b/source/expectations/matchers/ut_equal.tps @@ -1,4 +1,4 @@ -create or replace type ut_equal under ut_comparison_matcher( +create or replace type ut_equal force under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -43,18 +43,26 @@ create or replace type ut_equal under ut_comparison_matcher( constructor function ut_equal(self in out nocopy ut_equal, a_expected dsinterval_unconstrained, a_nulls_are_equal boolean := null) return self as result, constructor function ut_equal(self in out nocopy ut_equal, a_expected json_element_t, a_nulls_are_equal boolean := null) return self as result, member function include(a_items varchar2) return ut_equal, + member function include(a_items ut_varchar2_list) return ut_equal, member procedure include(self in ut_equal, a_items varchar2), - member function include(a_items ut_varchar2_list) return ut_equal, + member procedure include(self in ut_equal, a_items ut_varchar2_list), member function exclude(a_items varchar2) return ut_equal, member function exclude(a_items ut_varchar2_list) return ut_equal, + member procedure exclude(self in ut_equal, a_items varchar2), + member procedure exclude(self in ut_equal, a_items ut_varchar2_list), member function unordered return ut_equal, + member procedure unordered(self in ut_equal), member function join_by(a_columns varchar2) return ut_equal, member function join_by(a_columns ut_varchar2_list) return ut_equal, + member procedure join_by(self in ut_equal, a_columns varchar2), + member procedure join_by(self in ut_equal, a_columns ut_varchar2_list), overriding member function run_matcher(self in out nocopy ut_equal, a_actual ut_data_value) return boolean, overriding member function failure_message(a_actual ut_data_value) return varchar2, overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2, member function unordered_columns return ut_equal, - member function uc return ut_equal + member procedure unordered_columns(self in ut_equal), + member function uc return ut_equal, + member procedure uc(self in ut_equal) ) not final / diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index 674b468b2..365272b21 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -34,18 +34,20 @@ create or replace type body ut_expectation_compound as end; - member function to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_expectation_compound is - l_result ut_expectation_compound := self; + member function to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_equal is + l_result ut_matcher; begin - l_result.matcher := ut_equal(a_expected, a_nulls_are_equal); - return l_result; + l_result := ut_equal(a_expected, a_nulls_are_equal); + l_result.expectation := self; + return treat(l_result as ut_equal); end; - member function not_to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_expectation_compound is - l_result ut_expectation_compound := self; + member function not_to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_equal is + l_result ut_matcher; begin - l_result.matcher := ut_equal(a_expected, a_nulls_are_equal).negated(); - return l_result; + l_result := ut_equal(a_expected, a_nulls_are_equal).negated(); + l_result.expectation := self; + return treat(l_result as ut_equal); end; member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal is @@ -56,11 +58,12 @@ create or replace type body ut_expectation_compound as return treat(l_result as ut_equal); end; - member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_expectation_compound is - l_result ut_expectation_compound := self; + member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal is + l_result ut_matcher; begin - l_result.matcher := ut_equal(a_expected, a_nulls_are_equal).negated(); - return l_result; + l_result := ut_equal(a_expected, a_nulls_are_equal).negated(); + l_result.expectation := self; + return treat(l_result as ut_equal); end; member function to_contain(a_expected sys_refcursor) return ut_expectation_compound is @@ -91,107 +94,5 @@ create or replace type body ut_expectation_compound as return l_result; end; - member function include(a_items varchar2) return ut_expectation_compound is - begin - return include( ut_varchar2_list( a_items ) ); - end; - - member function include(a_items ut_varchar2_list) return ut_expectation_compound is - l_result ut_expectation_compound := self; - begin - l_result.matcher := treat(l_result.matcher as ut_equal).include(a_items); - return l_result; - end; - - member procedure include(self in ut_expectation_compound, a_items varchar2) is - begin - include( ut_varchar2_list( a_items ) ); - end; - - member procedure include(self in ut_expectation_compound, a_items ut_varchar2_list) is - begin - self.to_( treat(matcher as ut_equal).include(a_items) ); - end; - - member function exclude(a_items varchar2) return ut_expectation_compound is - begin - return exclude( ut_varchar2_list( a_items ) ); - end; - - member function exclude(a_items ut_varchar2_list) return ut_expectation_compound is - l_result ut_expectation_compound := self; - begin - l_result.matcher := treat(l_result.matcher as ut_equal).exclude(a_items); - return l_result; - end; - - member procedure exclude(self in ut_expectation_compound, a_items varchar2) is - begin - exclude( ut_varchar2_list( a_items ) ); - end; - - member procedure exclude(self in ut_expectation_compound, a_items ut_varchar2_list) is - begin - self.to_( treat(matcher as ut_equal).exclude(a_items) ); - end; - - member function unordered return ut_expectation_compound is - l_result ut_expectation_compound := self; - begin - l_result.matcher := treat(l_result.matcher as ut_equal).unordered(); - return l_result; - end; - - member procedure unordered(self in ut_expectation_compound) is - begin - self.to_( treat(matcher as ut_equal).unordered() ); - end; - - member function join_by(a_columns varchar2) return ut_expectation_compound is - begin - return join_by( ut_varchar2_list( a_columns ) ); - end; - - member function join_by(a_columns ut_varchar2_list) return ut_expectation_compound is - l_result ut_expectation_compound; - begin - l_result := self; - l_result.matcher := treat(l_result.matcher as ut_equal).join_by(a_columns); - return l_result; - end; - - member procedure join_by(self in ut_expectation_compound, a_columns varchar2) is - begin - join_by( ut_varchar2_list( a_columns ) ); - end; - - member procedure join_by(self in ut_expectation_compound, a_columns ut_varchar2_list) is - begin - self.to_( treat(matcher as ut_equal).join_by(a_columns) ); - end; - - member function unordered_columns return ut_expectation_compound is - l_result ut_expectation_compound; - begin - l_result := self; - l_result.matcher := treat(l_result.matcher as ut_equal).unordered_columns; - return l_result; - end; - - member procedure unordered_columns(self in ut_expectation_compound) is - begin - self.to_( treat(matcher as ut_equal).unordered_columns ); - end; - - member function uc return ut_expectation_compound is - begin - return unordered_columns; - end; - - member procedure uc(self in ut_expectation_compound) is - begin - unordered_columns; - end; - end; / diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index 4b2347859..3aae56670 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -22,33 +22,14 @@ create or replace type ut_expectation_compound under ut_expectation( member procedure to_have_count(self in ut_expectation_compound, a_expected integer), member procedure not_to_have_count(self in ut_expectation_compound, a_expected integer), - member function to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_expectation_compound, - member function not_to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_expectation_compound, + member function to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_equal, + member function not_to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_equal, member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal, - member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_expectation_compound, + member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal, member function to_contain(a_expected sys_refcursor) return ut_expectation_compound, member function not_to_contain(a_expected sys_refcursor) return ut_expectation_compound, member function to_contain(a_expected anydata) return ut_expectation_compound, - member function not_to_contain(a_expected anydata) return ut_expectation_compound, - - member function include(a_items varchar2) return ut_expectation_compound, - member function include(a_items ut_varchar2_list) return ut_expectation_compound, - member procedure include(self in ut_expectation_compound, a_items varchar2), - member procedure include(self in ut_expectation_compound, a_items ut_varchar2_list), - member function exclude(a_items varchar2) return ut_expectation_compound, - member function exclude(a_items ut_varchar2_list) return ut_expectation_compound, - member procedure exclude(self in ut_expectation_compound, a_items varchar2), - member procedure exclude(self in ut_expectation_compound, a_items ut_varchar2_list), - member function unordered return ut_expectation_compound, - member procedure unordered(self in ut_expectation_compound), - member function join_by(a_columns varchar2) return ut_expectation_compound, - member function join_by(a_columns ut_varchar2_list) return ut_expectation_compound, - member procedure join_by(self in ut_expectation_compound, a_columns varchar2), - member procedure join_by(self in ut_expectation_compound, a_columns ut_varchar2_list), - - member function unordered_columns return ut_expectation_compound, - member procedure unordered_columns(self in ut_expectation_compound), - member function uc return ut_expectation_compound, - member procedure uc(self in ut_expectation_compound) + member function not_to_contain(a_expected anydata) return ut_expectation_compound ) / + From caeeb30ea4fef1eeeea2283e5c76b717eb9809e3 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 2 Jun 2020 21:30:05 +0100 Subject: [PATCH 074/887] Adding contain and not contain --- .../expectations/ut_expectation_compound.tpb | 38 ++++++++++--------- .../expectations/ut_expectation_compound.tps | 8 ++-- 2 files changed, 25 insertions(+), 21 deletions(-) diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index 365272b21..7043ec053 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -66,32 +66,36 @@ create or replace type body ut_expectation_compound as return treat(l_result as ut_equal); end; - member function to_contain(a_expected sys_refcursor) return ut_expectation_compound is - l_result ut_expectation_compound := self; + member function to_contain(a_expected sys_refcursor) return ut_equal is + l_result ut_matcher; begin - l_result.matcher := ut_contain(a_expected); - return l_result; + l_result := ut_contain(a_expected); + l_result.expectation := self; + return treat(l_result as ut_equal); end; - member function not_to_contain(a_expected sys_refcursor) return ut_expectation_compound is - l_result ut_expectation_compound := self; + member function not_to_contain(a_expected sys_refcursor) return ut_equal is + l_result ut_matcher; begin - l_result.matcher := ut_contain(a_expected).negated(); - return l_result; + l_result := ut_contain(a_expected).negated(); + l_result.expectation := self; + return treat(l_result as ut_equal); end; - - member function to_contain(a_expected anydata) return ut_expectation_compound is - l_result ut_expectation_compound := self; + + member function to_contain(a_expected anydata) return ut_equal is + l_result ut_matcher; begin - l_result.matcher := ut_contain(a_expected); - return l_result; + l_result := ut_contain(a_expected); + l_result.expectation := self; + return treat(l_result as ut_equal); end; - member function not_to_contain(a_expected anydata) return ut_expectation_compound is - l_result ut_expectation_compound := self; + member function not_to_contain(a_expected anydata) return ut_equal is + l_result ut_matcher; begin - l_result.matcher := ut_contain(a_expected).negated(); - return l_result; + l_result := ut_contain(a_expected).negated(); + l_result.expectation := self; + return treat(l_result as ut_equal); end; end; diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index 3aae56670..c840aaf35 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -26,10 +26,10 @@ create or replace type ut_expectation_compound under ut_expectation( member function not_to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_equal, member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal, member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal, - member function to_contain(a_expected sys_refcursor) return ut_expectation_compound, - member function not_to_contain(a_expected sys_refcursor) return ut_expectation_compound, - member function to_contain(a_expected anydata) return ut_expectation_compound, - member function not_to_contain(a_expected anydata) return ut_expectation_compound + member function to_contain(a_expected sys_refcursor) return ut_equal, + member function not_to_contain(a_expected sys_refcursor) return ut_equal, + member function to_contain(a_expected anydata) return ut_equal, + member function not_to_contain(a_expected anydata) return ut_equal ) / From 0dd978f6c11eece36eb226e518610f5925deef01 Mon Sep 17 00:00:00 2001 From: Philipp Salvisberg Date: Thu, 4 Jun 2020 18:35:51 +0200 Subject: [PATCH 075/887] grant privileges to debug via UT3_USER --- .travis/install.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.travis/install.sh b/.travis/install.sh index 99c88c79b..b914dd4d3 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -113,6 +113,20 @@ PROMPT Creating $UT3_USER - minimal privileges user for API testing create user $UT3_USER identified by "$UT3_USER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; grant create session, create procedure, create type, create table to $UT3_USER; +PROMPT Grants for starting a debugging session from $UT3_USER +grant debug connect session to $UT3_USER; +begin + dbms_network_acl_admin.append_host_ace ( + host =>'*', + ace => sys.xs\$ace_type( + privilege_list => sys.xs\$name_list('JDWP') , + principal_name => '$UT3_USER', + principal_type => sys.xs_acl.ptype_db + ) + ); +end; +/ +grant debug any procedure to $UT3_USER; -------------------------------------------------------------------------------- PROMPT Creating $UT3_TESTER_HELPER - provides functions to allow min grant test user setup tests. From 9ea6ab408dc66df31372dc4bb19eb0fd19366c52 Mon Sep 17 00:00:00 2001 From: Philipp Salvisberg Date: Thu, 4 Jun 2020 18:36:35 +0200 Subject: [PATCH 076/887] add test case to reproduce bug #1073 --- .../reporters/test_realtime_reporter.pkb | 46 +++++++++++++++++++ .../reporters/test_realtime_reporter.pks | 3 ++ 2 files changed, 49 insertions(+) diff --git a/test/ut3_user/reporters/test_realtime_reporter.pkb b/test/ut3_user/reporters/test_realtime_reporter.pkb index 53a268ff4..ad354133b 100644 --- a/test/ut3_user/reporters/test_realtime_reporter.pkb +++ b/test/ut3_user/reporters/test_realtime_reporter.pkb @@ -118,6 +118,22 @@ create or replace package body test_realtime_reporter as end; end;]'; + execute immediate q'[create or replace package check_realtime_reporting5 is + --%suite + --%suitepath(realtime_reporting_bufix) + + --%test(test XML with nested CDATA) + procedure test_nested_cdata; + end;]'; + + execute immediate q'[create or replace package body check_realtime_reporting5 is + procedure test_nested_cdata is + begin + dbms_output.put_line('nested cdata block: , to be handled.'); + ut.expect(1).to_equal(1); + end; + end;]'; + <> declare l_reporter ut3_develop.ut_realtime_reporter := ut3_develop.ut_realtime_reporter(); @@ -448,6 +464,35 @@ create or replace package body test_realtime_reporter as l_actual := l_reporter.get_description(); ut.expect(l_actual).to_be_like(l_expected); end get_description; + + procedure nested_cdata_output is + l_text varchar2(4000); + l_xml xmltype; + -- + function produce_and_consume return varchar2 is + pragma autonomous_transaction; + l_reporter ut3_develop.ut_realtime_reporter := ut3_develop.ut_realtime_reporter(); + l_text varchar2(4000); + begin + -- produce + ut3_develop.ut_runner.run( + a_paths => ut3_develop.ut_varchar2_list(':realtime_reporting_bufix'), + a_reporters => ut3_develop.ut_reporters(l_reporter) + ); + -- consume + select text + into l_text + from table(l_reporter.get_lines()) + where item_type = 'post-test'; + return l_text; + end produce_and_consume; + begin + l_text := produce_and_consume(); + ut.expect(l_text).to_be_not_null(); + -- this fails, if l_text is not a valid XML + l_xml := xmltype(l_text); + ut.expect(l_xml is not null).to_be_true(); + end; procedure remove_test_suites is pragma autonomous_transaction; @@ -456,6 +501,7 @@ create or replace package body test_realtime_reporter as execute immediate 'drop package check_realtime_reporting2'; execute immediate 'drop package check_realtime_reporting3'; execute immediate 'drop package check_realtime_reporting4'; + execute immediate 'drop package check_realtime_reporting5'; end remove_test_suites; end test_realtime_reporter; diff --git a/test/ut3_user/reporters/test_realtime_reporter.pks b/test/ut3_user/reporters/test_realtime_reporter.pks index e57ccab21..453824ca5 100644 --- a/test/ut3_user/reporters/test_realtime_reporter.pks +++ b/test/ut3_user/reporters/test_realtime_reporter.pks @@ -54,6 +54,9 @@ create or replace package test_realtime_reporter as --%test(Provide a description of the reporter explaining the use for SQL Developer) procedure get_description; + --%test(Escape nested CDATA sections in test output) + procedure nested_cdata_output; + --%afterall procedure remove_test_suites; From bfe94cd6abe68ee50d54f51e2ee624f1ba1c939c Mon Sep 17 00:00:00 2001 From: Philipp Salvisberg Date: Thu, 4 Jun 2020 18:37:09 +0200 Subject: [PATCH 077/887] handle nested CDATA sections to fix bug #1073 --- source/reporters/ut_realtime_reporter.tpb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/reporters/ut_realtime_reporter.tpb b/source/reporters/ut_realtime_reporter.tpb index 64eb343e5..367b2c51a 100644 --- a/source/reporters/ut_realtime_reporter.tpb +++ b/source/reporters/ut_realtime_reporter.tpb @@ -252,7 +252,7 @@ create or replace type body ut_realtime_reporter is ) is begin if a_content is not null then - self.print_xml_fragment('<' || a_name || '>'); + self.print_xml_fragment('<' || a_name || '>'); end if; end print_cdata_node; From 6631930da1a70d26f2f828b6c061292f577f39ad Mon Sep 17 00:00:00 2001 From: Philipp Salvisberg Date: Thu, 4 Jun 2020 20:17:41 +0200 Subject: [PATCH 078/887] support Oracle DB 11.2, add ace only on 12c and higher --- .travis/install.sh | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/.travis/install.sh b/.travis/install.sh index b914dd4d3..225b6ff52 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -115,18 +115,23 @@ grant create session, create procedure, create type, create table to $UT3_USER; PROMPT Grants for starting a debugging session from $UT3_USER grant debug connect session to $UT3_USER; +grant debug any procedure to $UT3_USER; begin - dbms_network_acl_admin.append_host_ace ( - host =>'*', - ace => sys.xs\$ace_type( - privilege_list => sys.xs\$name_list('JDWP') , - principal_name => '$UT3_USER', - principal_type => sys.xs_acl.ptype_db - ) - ); + \$if dbms_db_version.version <= 11 \$then + null; -- no addition action necessary + \$else + -- necessary on 12c or higher + dbms_network_acl_admin.append_host_ace ( + host =>'*', + ace => sys.xs\$ace_type( + privilege_list => sys.xs\$name_list('JDWP') , + principal_name => '$UT3_USER', + principal_type => sys.xs_acl.ptype_db + ) + ); + \$end end; / -grant debug any procedure to $UT3_USER; -------------------------------------------------------------------------------- PROMPT Creating $UT3_TESTER_HELPER - provides functions to allow min grant test user setup tests. From c4651518b5b896a263b41663411293c87f2f76a6 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 4 Jun 2020 19:07:42 +0000 Subject: [PATCH 079/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index dc1b0c36e..aca93a957 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 48355af2e..4fcdda511 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 964b7a743..884fc6c07 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 27b9d0798..63f8e851d 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 73a257690..e0cf1b0c9 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index b46032a15..7ed3dce21 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index c573f8858..cf72be22d 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0ac1a14c8..0fbcb4851 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index b0fcab539..3b968ccc4 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a7603da59..3487ffac6 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 5924be80f..2a1044454 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c528766ae..bc9894cee 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index a65943e81..385db7257 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 32506007c..66b52496f 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 6eb5cf4d0..24dabecf8 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 243026021..7bbbe2df1 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 7328451ef..af711ae4f 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3380--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index ba98763e0..6bceb5261 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3380-develop + * secion v3.1.11.3392-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6ed6c4ac9..ec8781391 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3380-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3392-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 8ff4f6bbf847bab652a1628aa68abc140655d7fe Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 6 Jun 2020 01:16:30 +0100 Subject: [PATCH 080/887] Adding code and tests,. --- source/core/ut_utils.pkb | 25 ++++ source/core/ut_utils.pks | 9 +- .../data_values/ut_data_value_dsinterval.tpb | 2 +- .../data_values/ut_data_value_yminterval.tpb | 2 +- source/expectations/matchers/ut_be_within.tpb | 104 +++++++++++++ source/expectations/matchers/ut_be_within.tps | 38 +++++ source/expectations/matchers/ut_matcher.tps | 2 +- source/expectations/ut_expectation.tpb | 57 +++---- source/expectations/ut_expectation.tps | 16 +- source/expectations/ut_expectation_base.tpb | 44 ++++++ source/expectations/ut_expectation_base.tps | 25 ++++ .../expectations/ut_expectation_compound.tps | 1 + source/install.sql | 6 +- test/install_ut3_user_tests.sql | 2 + .../ut3_tester_helper/expectations_helper.pkb | 26 +++- .../ut3_tester_helper/expectations_helper.pks | 10 ++ .../expectations/binary/test_to_be_within.pkb | 141 ++++++++++++++++++ .../expectations/binary/test_to_be_within.pks | 31 ++++ 18 files changed, 501 insertions(+), 40 deletions(-) create mode 100644 source/expectations/matchers/ut_be_within.tpb create mode 100644 source/expectations/matchers/ut_be_within.tps create mode 100644 source/expectations/ut_expectation_base.tpb create mode 100644 source/expectations/ut_expectation_base.tps create mode 100644 test/ut3_user/expectations/binary/test_to_be_within.pkb create mode 100644 test/ut3_user/expectations/binary/test_to_be_within.pks diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index ba98763e0..8e96870d9 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -877,5 +877,30 @@ create or replace package body ut_utils is end; end; + function interval_to_text(a_interval dsinterval_unconstrained) return varchar2 is + l_day varchar2(100) := extract(day from a_interval); + l_hour varchar2(100) := extract(hour from a_interval); + l_minute varchar2(100) := extract(minute from a_interval); + l_second varchar2(100) := extract(second from a_interval); + l_result varchar2(32767); + begin + l_result := case when l_day > 0 then l_day ||' day' else null end; + l_result := l_result || case when l_hour > 0 then ' '|| l_hour ||' hour' else null end; + l_result := l_result || case when l_minute> 0 then ' '||l_minute ||' minute' else null end; + l_result := l_result || case when l_second > 0 then ' '||l_second ||' second' else null end; + return trim(leading ' ' from l_result); + end; + + function interval_to_text(a_interval yminterval_unconstrained) return varchar2 is + l_year varchar2(4) := extract(year from a_interval); + l_month varchar2(20) := extract(month from a_interval); + l_result varchar2(32767); + begin + l_result := case when l_year > 0 then l_year ||' year' else null end; + l_result := l_result || case when l_month > 0 then ' '||l_month ||' month' else null end; + return trim(leading ' ' from l_result); + end; + + end ut_utils; / diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6ed6c4ac9..750b17a77 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -434,6 +434,13 @@ create or replace package ut_utils authid definer is * If null value passed returns null */ function qualified_sql_name(a_name varchar2) return varchar2; - + + /* + * Return value of interval in plain english + */ + function interval_to_text(a_interval dsinterval_unconstrained) return varchar2; + + function interval_to_text(a_interval yminterval_unconstrained) return varchar2; + end ut_utils; / diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tpb b/source/expectations/data_values/ut_data_value_dsinterval.tpb index ff9d5fe1e..e55b2fb17 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tpb +++ b/source/expectations/data_values/ut_data_value_dsinterval.tpb @@ -31,7 +31,7 @@ create or replace type body ut_data_value_dsinterval as overriding member function to_string return varchar2 is begin - return ut_utils.to_string(self.data_value); + return ut_utils.interval_to_text(self.data_value); end; overriding member function compare_implementation(a_other ut_data_value) return integer is diff --git a/source/expectations/data_values/ut_data_value_yminterval.tpb b/source/expectations/data_values/ut_data_value_yminterval.tpb index 6d6a05b4a..225406756 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tpb +++ b/source/expectations/data_values/ut_data_value_yminterval.tpb @@ -31,7 +31,7 @@ create or replace type body ut_data_value_yminterval as overriding member function to_string return varchar2 is begin - return ut_utils.to_string(self.data_value); + return ut_utils.interval_to_text(self.data_value); end; overriding member function compare_implementation(a_other ut_data_value) return integer is diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb new file mode 100644 index 000000000..0832b4946 --- /dev/null +++ b/source/expectations/matchers/ut_be_within.tpb @@ -0,0 +1,104 @@ +create or replace type body ut_be_within as + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + member procedure init(self in out nocopy ut_be_within, a_dist ut_data_value, a_is_pct number , a_self_type varchar2 := null) is + begin + self.dist := a_dist; + self.is_pct := nvl(a_is_pct,0); + self.self_type := nvl( a_self_type, $$plsql_unit ); + end; + + constructor function ut_be_within(self in out nocopy ut_be_within, a_dist number, a_is_pct number) return self as result is + begin + init(ut_data_value_number(a_dist),a_is_pct); + return; + end; + + constructor function ut_be_within(self in out nocopy ut_be_within, a_dist dsinterval_unconstrained, a_is_pct number) return self as result is + begin + init(ut_data_value_dsinterval(a_dist),a_is_pct); + return; + end; + + constructor function ut_be_within(self in out nocopy ut_be_within, a_dist yminterval_unconstrained, a_is_pct number) return self as result is + begin + init(ut_data_value_yminterval(a_dist),a_is_pct); + return; + end; + + member procedure of_(self in ut_be_within, a_expected number) is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_number(a_expected); + l_result.expectation.to_(l_result ); + end; + + member procedure of_(self in ut_be_within, a_expected date) is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_date(a_expected); + l_result.expectation.to_(l_result ); + end; + + overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean is + l_result boolean; + begin + if self.expected.data_type = a_actual.data_type then + if self.expected is of (ut_data_value_number) and self.is_pct = 0 then + l_result := abs((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value)) <= treat(self.dist as ut_data_value_number).data_value; + elsif self.expected is of (ut_data_value_number) and self.is_pct = 1 then + l_result := treat(self.dist as ut_data_value_number).data_value >= ((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ) / + (treat(self.expected as ut_data_value_number).data_value) ; + elsif self.expected is of (ut_data_value_date) and self.dist is of ( ut_data_value_yminterval) then + l_result := treat(a_actual as ut_data_value_date).data_value between (treat(self.expected as ut_data_value_date).data_value) - treat(self.dist as ut_data_value_yminterval).data_value + and (treat(self.expected as ut_data_value_date).data_value) + treat(self.dist as ut_data_value_yminterval).data_value; + elsif self.expected is of (ut_data_value_date) and self.dist is of ( ut_data_value_dsinterval) then + l_result := treat(a_actual as ut_data_value_date).data_value between (treat(self.expected as ut_data_value_date).data_value) - treat(self.dist as ut_data_value_dsinterval).data_value + and (treat(self.expected as ut_data_value_date).data_value) + treat(self.dist as ut_data_value_dsinterval).data_value; + end if; + else + l_result := (self as ut_matcher).run_matcher(a_actual); + end if; + return l_result; + end; + + overriding member function failure_message(a_actual ut_data_value) return varchar2 is + l_distance varchar2(32767); + begin + l_distance := case + when self.dist is of (ut_data_value_number) then + treat(self.dist as ut_data_value_number).to_string + when self.dist is of (ut_data_value_yminterval) then + treat(self.dist as ut_data_value_yminterval).to_string + when self.dist is of (ut_data_value_dsinterval) then + treat(self.dist as ut_data_value_dsinterval).to_string + else + null + end; + + return (self as ut_matcher).failure_message(a_actual) || ' '||l_distance ||' of '|| expected.to_string_report(); + end; + + overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 is + l_result varchar2(32767); + begin + return (self as ut_matcher).failure_message_when_negated(a_actual) || ': '|| expected.to_string_report(); + end; + +end; +/ \ No newline at end of file diff --git a/source/expectations/matchers/ut_be_within.tps b/source/expectations/matchers/ut_be_within.tps new file mode 100644 index 000000000..30947d2aa --- /dev/null +++ b/source/expectations/matchers/ut_be_within.tps @@ -0,0 +1,38 @@ +create or replace type ut_be_within under ut_comparison_matcher( + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + + /** + * Holds information about mather options + */ + dist ut_data_value, + is_pct number(1,0), + + member procedure init(self in out nocopy ut_be_within, a_dist ut_data_value, a_is_pct number , a_self_type varchar2 := null), + constructor function ut_be_within(self in out nocopy ut_be_within, a_dist number, a_is_pct number) return self as result, + constructor function ut_be_within(self in out nocopy ut_be_within, a_dist dsinterval_unconstrained, a_is_pct number) return self as result, + constructor function ut_be_within(self in out nocopy ut_be_within, a_dist yminterval_unconstrained, a_is_pct number) return self as result, + member procedure of_(self in ut_be_within, a_expected number), + member procedure of_(self in ut_be_within, a_expected date), + + overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean, + overriding member function failure_message(a_actual ut_data_value) return varchar2, + overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 +) +not final +/ \ No newline at end of file diff --git a/source/expectations/matchers/ut_matcher.tps b/source/expectations/matchers/ut_matcher.tps index 16af94a1a..75231d4f3 100644 --- a/source/expectations/matchers/ut_matcher.tps +++ b/source/expectations/matchers/ut_matcher.tps @@ -17,7 +17,7 @@ create or replace type ut_matcher under ut_matcher_base( */ is_errored integer, is_negated_flag number(1,0), - expectation ut_expectation, + expectation ut_expectation_base, /* function: run_matcher diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index b18e2f7b0..288c6cf19 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -15,31 +15,6 @@ create or replace type body ut_expectation as See the License for the specific language governing permissions and limitations under the License. */ - member procedure to_(self in ut_expectation, a_matcher ut_matcher_base) is - l_expectation_result boolean; - l_matcher ut_matcher := treat(a_matcher as ut_matcher); - l_message varchar2(32767); - begin - if l_matcher.is_negated() then - self.not_to( a_matcher ); - else - l_expectation_result := l_matcher.run_matcher( self.actual_data ); - l_expectation_result := coalesce(l_expectation_result,false); - l_message := coalesce( l_matcher.error_message( self.actual_data ), l_matcher.failure_message( self.actual_data ) ); - ut_expectation_processor.add_expectation_result( ut_expectation_result( ut_utils.to_test_result( l_expectation_result ), self.description, l_message ) ); - end if; - end; - - member procedure not_to(self in ut_expectation, a_matcher ut_matcher_base) is - l_expectation_result boolean; - l_matcher ut_matcher := treat(a_matcher as ut_matcher); - l_message varchar2(32767); - begin - l_expectation_result := coalesce( l_matcher.run_matcher_negated( self.actual_data ), false ); - - l_message := coalesce( l_matcher.error_message( self.actual_data ), l_matcher.failure_message_when_negated( self.actual_data ) ); - ut_expectation_processor.add_expectation_result( ut_expectation_result( ut_utils.to_test_result( l_expectation_result ), self.description, l_message ) ); - end; member procedure to_be_null(self in ut_expectation) is begin @@ -719,5 +694,37 @@ create or replace type body ut_expectation as self.not_to( ut_contain(a_expected).negated() ); end; + member function to_be_within(a_dist natural) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist,0); + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; + + member function to_be_within(a_dist dsinterval_unconstrained) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist,0); + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; + + member function to_be_within(a_dist yminterval_unconstrained) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist,0); + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; + + member function to_be_within_pct(a_dist natural) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist,1); + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; + end; / diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index 95aeb9fce..b45141b5c 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation authid current_user as object( +create or replace type ut_expectation under ut_expectation_base( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -15,13 +15,7 @@ create or replace type ut_expectation authid current_user as object( See the License for the specific language governing permissions and limitations under the License. */ - actual_data ut_data_value, - description varchar2(4000 char), - - --base matcher executors - member procedure to_(self in ut_expectation, a_matcher ut_matcher_base), - member procedure not_to(self in ut_expectation, a_matcher ut_matcher_base), - + --shortcuts member procedure to_be_null(self in ut_expectation), member procedure to_be_not_null(self in ut_expectation), @@ -168,8 +162,12 @@ create or replace type ut_expectation authid current_user as object( member procedure to_contain(self in ut_expectation, a_expected sys_refcursor), member procedure not_to_contain(self in ut_expectation, a_expected sys_refcursor), member procedure to_contain(self in ut_expectation, a_expected anydata), - member procedure not_to_contain(self in ut_expectation, a_expected anydata) + member procedure not_to_contain(self in ut_expectation, a_expected anydata), + member function to_be_within(a_dist natural) return ut_be_within, + member function to_be_within(a_dist dsinterval_unconstrained) return ut_be_within, + member function to_be_within(a_dist yminterval_unconstrained) return ut_be_within, + member function to_be_within_pct(a_dist natural) return ut_be_within ) not final / diff --git a/source/expectations/ut_expectation_base.tpb b/source/expectations/ut_expectation_base.tpb new file mode 100644 index 000000000..d657c2822 --- /dev/null +++ b/source/expectations/ut_expectation_base.tpb @@ -0,0 +1,44 @@ +create or replace type body ut_expectation_base as + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + member procedure to_(self in ut_expectation_base, a_matcher ut_matcher_base) is + l_expectation_result boolean; + l_matcher ut_matcher := treat(a_matcher as ut_matcher); + l_message varchar2(32767); + begin + if l_matcher.is_negated() then + self.not_to( a_matcher ); + else + l_expectation_result := l_matcher.run_matcher( self.actual_data ); + l_expectation_result := coalesce(l_expectation_result,false); + l_message := coalesce( l_matcher.error_message( self.actual_data ), l_matcher.failure_message( self.actual_data ) ); + ut_expectation_processor.add_expectation_result( ut_expectation_result( ut_utils.to_test_result( l_expectation_result ), self.description, l_message ) ); + end if; + end; + + member procedure not_to(self in ut_expectation_base, a_matcher ut_matcher_base) is + l_expectation_result boolean; + l_matcher ut_matcher := treat(a_matcher as ut_matcher); + l_message varchar2(32767); + begin + l_expectation_result := coalesce( l_matcher.run_matcher_negated( self.actual_data ), false ); + + l_message := coalesce( l_matcher.error_message( self.actual_data ), l_matcher.failure_message_when_negated( self.actual_data ) ); + ut_expectation_processor.add_expectation_result( ut_expectation_result( ut_utils.to_test_result( l_expectation_result ), self.description, l_message ) ); + end; +end; +/ \ No newline at end of file diff --git a/source/expectations/ut_expectation_base.tps b/source/expectations/ut_expectation_base.tps new file mode 100644 index 000000000..87c0083b0 --- /dev/null +++ b/source/expectations/ut_expectation_base.tps @@ -0,0 +1,25 @@ +create or replace type ut_expectation_base force authid current_user as object( + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + actual_data ut_data_value, + description varchar2(4000 char), + + --base matcher executors + member procedure to_(self in ut_expectation_base, a_matcher ut_matcher_base), + member procedure not_to(self in ut_expectation_base, a_matcher ut_matcher_base) +) not final +/ \ No newline at end of file diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index c840aaf35..a2c06ce76 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -33,3 +33,4 @@ create or replace type ut_expectation_compound under ut_expectation( ) / + diff --git a/source/install.sql b/source/install.sql index 45a67f924..911760a63 100644 --- a/source/install.sql +++ b/source/install.sql @@ -236,10 +236,12 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/data_values/ut_data_value_xmltype.tps' @@install_component.sql 'expectations/data_values/ut_compound_data_helper.pks' @@install_component.sql 'expectations/data_values/ut_data_value_json.tps' -@@install_component.sql 'expectations/ut_expectation.tps' @@install_component.sql 'expectations/matchers/ut_matcher_base.tps' +@@install_component.sql 'expectations/ut_expectation_base.tps' @@install_component.sql 'expectations/matchers/ut_matcher.tps' @@install_component.sql 'expectations/matchers/ut_comparison_matcher.tps' +@@install_component.sql 'expectations/matchers/ut_be_within.tps' +@@install_component.sql 'expectations/ut_expectation.tps' @@install_component.sql 'expectations/matchers/ut_be_false.tps' @@install_component.sql 'expectations/matchers/ut_be_greater_or_equal.tps' @@install_component.sql 'expectations/matchers/ut_be_greater_than.tps' @@ -294,11 +296,13 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/matchers/ut_be_null.tpb' @@install_component.sql 'expectations/matchers/ut_be_true.tpb' @@install_component.sql 'expectations/matchers/ut_equal.tpb' +@@install_component.sql 'expectations/matchers/ut_be_within.tpb' @@install_component.sql 'expectations/matchers/ut_contain.tpb' @@install_component.sql 'expectations/matchers/ut_have_count.tpb' @@install_component.sql 'expectations/matchers/ut_be_between.tpb' @@install_component.sql 'expectations/matchers/ut_be_empty.tpb' @@install_component.sql 'expectations/matchers/ut_match.tpb' +@@install_component.sql 'expectations/ut_expectation_base.tpb' @@install_component.sql 'expectations/ut_expectation.tpb' @@install_component.sql 'expectations/ut_expectation_compound.tpb' @@install_component.sql 'expectations/ut_expectation_json.tpb' diff --git a/test/install_ut3_user_tests.sql b/test/install_ut3_user_tests.sql index 05f2634e8..1330a7f75 100644 --- a/test/install_ut3_user_tests.sql +++ b/test/install_ut3_user_tests.sql @@ -25,6 +25,7 @@ prompt Install user tests @@ut3_user/expectations/binary/test_be_less_or_equal.pks @@ut3_user/expectations/binary/test_be_greater_or_equal.pks @@ut3_user/expectations/binary/test_be_greater_than.pks +@@ut3_user/expectations/binary/test_to_be_within.pks @@ut3_user/expectations/test_matchers.pks @@ut3_user/expectations/test_expectation_anydata.pks @@ut3_user/expectations/test_expectations_cursor.pks @@ -66,6 +67,7 @@ set define off @@ut3_user/expectations/binary/test_be_less_or_equal.pkb @@ut3_user/expectations/binary/test_be_greater_or_equal.pkb @@ut3_user/expectations/binary/test_be_greater_than.pkb +@@ut3_user/expectations/binary/test_to_be_within.pkb @@ut3_user/expectations/test_matchers.pkb @@ut3_user/expectations/test_expectation_anydata.pkb @@ut3_user/expectations/test_expectations_cursor.pkb diff --git a/test/ut3_tester_helper/expectations_helper.pkb b/test/ut3_tester_helper/expectations_helper.pkb index c5c1f379f..7714e1ea3 100644 --- a/test/ut3_tester_helper/expectations_helper.pkb +++ b/test/ut3_tester_helper/expectations_helper.pkb @@ -1,4 +1,4 @@ -create or replace package body expectations_helper is +create or replace package body ut3_tester_helper.expectations_helper is function unary_expectation_block( a_matcher_name varchar2, @@ -53,5 +53,29 @@ create or replace package body expectations_helper is return l_execute; end; + function be_within_expectation_block( + a_matcher_name varchar2, + a_actual_data_type varchar2, + a_actual_data varchar2, + a_expected_data_type varchar2, + a_expected_data varchar2, + a_distance varchar2, + a_distance_data_type varchar2 + ) return varchar2 + is + l_execute varchar2(32000); + begin + l_execute := ' + declare + l_actual '||a_actual_data_type||' := '||a_actual_data||'; + l_expected '||a_expected_data_type||' := '||a_expected_data||'; + l_distance '||a_distance_data_type||' := '||a_distance||'; + begin + --act - execute the expectation + ut3_develop.ut.expect( l_actual ).'||a_matcher_name||'(l_distance).of_(l_expected); + end;'; + return l_execute; + end; + end; / diff --git a/test/ut3_tester_helper/expectations_helper.pks b/test/ut3_tester_helper/expectations_helper.pks index 9c1d54333..3b0a754d2 100644 --- a/test/ut3_tester_helper/expectations_helper.pks +++ b/test/ut3_tester_helper/expectations_helper.pks @@ -21,5 +21,15 @@ create or replace package expectations_helper is a_expected_data varchar2 ) return varchar2; + function be_within_expectation_block( + a_matcher_name varchar2, + a_actual_data_type varchar2, + a_actual_data varchar2, + a_expected_data_type varchar2, + a_expected_data varchar2, + a_distance varchar2, + a_distance_data_type varchar2 + ) return varchar2; + end; / diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb new file mode 100644 index 000000000..eb4f2da68 --- /dev/null +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -0,0 +1,141 @@ +create or replace package body test_to_be_within is + + procedure cleanup_expectations is + begin + ut3_tester_helper.main_helper.clear_expectations( ); + end; + + function be_within_expectation_block( + a_matcher_name varchar2, + a_data_type varchar2, + a_actual varchar2, + a_expected varchar2, + a_distance varchar2, + a_distance_data_type varchar2 + ) return varchar2 is + begin + return ut3_tester_helper.expectations_helper.be_within_expectation_block( + a_matcher_name, a_data_type, a_actual, a_data_type, a_expected,a_distance,a_distance_data_type + ); + end; + + procedure test_to_be_within_fail( + a_matcher_name varchar2, + a_data_type varchar2, + a_actual varchar2, + a_expected varchar2, + a_distance varchar2, + a_distance_data_type varchar2 + ) is + begin + execute immediate be_within_expectation_block(a_matcher_name,a_data_type, a_actual, a_expected,a_distance,a_distance_data_type); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).not_to_equal(0); + cleanup_expectations; + end; + + procedure test_to_be_within_success( + a_matcher_name varchar2, + a_data_type varchar2, + a_actual varchar2, + a_expected varchar2, + a_distance varchar2, + a_distance_data_type varchar2 + ) is + begin + execute immediate be_within_expectation_block(a_matcher_name,a_data_type, a_actual, a_expected,a_distance,a_distance_data_type); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + cleanup_expectations; + end; + + procedure success_tests is + begin + test_to_be_within_success('to_be_within','number', '2', '4','2','number'); + test_to_be_within_success('to_be_within','number', '4', '2','2','number'); + test_to_be_within_success('to_be_within','date', 'sysdate+1', 'sysdate','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','date', 'sysdate', 'sysdate+1','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','date', 'sysdate', 'sysdate+200','''1-0''','interval year to month'); + test_to_be_within_success('to_be_within','date', 'sysdate+200', 'sysdate','''1-0''','interval year to month'); + end; + + procedure failed_tests is + begin + test_to_be_within_fail('to_be_within','number', '2', '4','1','number'); + test_to_be_within_fail('to_be_within','number', '4', '2','1','number'); + test_to_be_within_fail('to_be_within','date', 'sysdate', 'sysdate+1','''0 0:00:11.333''','interval day to second'); + test_to_be_within_fail('to_be_within','date', 'sysdate+1', 'sysdate','''0 0:00:11.333''','interval day to second'); + test_to_be_within_fail('to_be_within','date', 'sysdate', 'sysdate+750','''1-0''','interval year to month'); + test_to_be_within_fail('to_be_within','date', 'sysdate+750', 'sysdate','''1-0''','interval year to month'); + end; + + procedure fail_for_number_not_within is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + --Act + ut3_develop.ut.expect(4).to_be_within(1).of_(7); + --Assert + l_expected_message := q'[Actual: 4 (number) was expected to be within 1 of 7 (number)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure fail_for_ds_interval_not_within is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + --Act + ut3_develop.ut.expect(sysdate).to_be_within(interval '1' second).of_(sysdate+1); + --Assert + l_expected_message := q'[Actual: % (date) was expected to be within 1 second of % (date)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure fail_for_custom_ds_interval_not_within is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + --Act + ut3_develop.ut.expect(sysdate).to_be_within(INTERVAL '2 3:04:11.333' DAY TO SECOND).of_(sysdate+100); + --Assert + l_expected_message := q'[Actual: % (date) was expected to be within 2 day 3 hour 4 minute 11.333 second of % (date)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure fail_for_ym_interval_not_within is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + --Act + ut3_develop.ut.expect(sysdate).to_be_within(INTERVAL '1' MONTH).of_(sysdate+ 45); + --Assert + l_expected_message := q'[Actual: % (date) was expected to be within 1 month of % (date)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure fail_for_custom_ym_interval_not_within is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + --Act + ut3_develop.ut.expect(sysdate).to_be_within(INTERVAL '1-3' YEAR TO MONTH).of_(sysdate+720); + --Assert + l_expected_message := q'[Actual: % (date) was expected to be within 1 year 3 month % (date)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + +end; +/ \ No newline at end of file diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pks b/test/ut3_user/expectations/binary/test_to_be_within.pks new file mode 100644 index 000000000..259a80915 --- /dev/null +++ b/test/ut3_user/expectations/binary/test_to_be_within.pks @@ -0,0 +1,31 @@ +create or replace package test_to_be_within is + + --%suite((not)to_be_less_or_equal) + --%suitepath(utplsql.test_user.expectations.binary) + + --%aftereach + procedure cleanup_expectations; + + --%test(Gives failure when number is not within positive distance) + procedure success_tests; + + --%test(Gives failure when number is not within negative distance) + procedure failed_tests; + + --%test(Check failure message for number not within) + procedure fail_for_number_not_within; + + --%test(Check failure message for inteval of 1 sec not within) + procedure fail_for_ds_interval_not_within; + + --%test(Check failure message for custom ds interval not within) + procedure fail_for_custom_ds_interval_not_within; + + --%test(Check failure message for inteval of 1 month not within) + procedure fail_for_ym_interval_not_within; + + --%test(Check failure message for custom ym interval not within) + procedure fail_for_custom_ym_interval_not_within; + +end; +/ \ No newline at end of file From 89cb0bcfef59e838e493482d00427a750b5c27a9 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 6 Jun 2020 02:00:39 +0100 Subject: [PATCH 081/887] Fixingtoo long names --- docs/userguide/expectations.md | 12 ++++++++++++ .../expectations/binary/test_to_be_within.pkb | 8 ++++---- .../expectations/binary/test_to_be_within.pks | 8 ++++---- 3 files changed, 20 insertions(+), 8 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 5924be80f..0d8893ba4 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -333,6 +333,7 @@ The matrix below illustrates the data types supported by different matchers. | **be_like** | | | X | | | | | | X | | | | | | | | **be_empty** | X | | X | | | | | | | | | X | X | | X | | **have_count** | | | | | | | | | | | | X | X | | X | +| **be_within().of_()** | | | | x | x | | | | | | | X | X | | X | # Expecting exceptions @@ -1093,6 +1094,17 @@ SUCCESS DEF ``` +## to_be_within of + +This fuzzy matcher is designed to allow user to compare a numbers and dates within distance of error. + +We are allowing a numbers to be compared within a absolute distance from other number of within a percentage calculated based on expected value. + +When comparing a date a distance is measured in interval. + + + + ## Comparing cursors, object types, nested tables and varrays diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index eb4f2da68..727ebbc03 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -81,7 +81,7 @@ create or replace package body test_to_be_within is ut.expect(l_actual_message).to_be_like(l_expected_message); end; - procedure fail_for_ds_interval_not_within is + procedure fail_for_number_not_within is l_actual_message varchar2(32767); l_expected_message varchar2(32767); begin @@ -95,7 +95,7 @@ create or replace package body test_to_be_within is ut.expect(l_actual_message).to_be_like(l_expected_message); end; - procedure fail_for_custom_ds_interval_not_within is + procedure fail_for_custom_ds_int is l_actual_message varchar2(32767); l_expected_message varchar2(32767); begin @@ -109,7 +109,7 @@ create or replace package body test_to_be_within is ut.expect(l_actual_message).to_be_like(l_expected_message); end; - procedure fail_for_ym_interval_not_within is + procedure fail_for_ym_int_not_within is l_actual_message varchar2(32767); l_expected_message varchar2(32767); begin @@ -123,7 +123,7 @@ create or replace package body test_to_be_within is ut.expect(l_actual_message).to_be_like(l_expected_message); end; - procedure fail_for_custom_ym_interval_not_within is + procedure fail_for_custom_ym_int is l_actual_message varchar2(32767); l_expected_message varchar2(32767); begin diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pks b/test/ut3_user/expectations/binary/test_to_be_within.pks index 259a80915..5c042bd53 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pks +++ b/test/ut3_user/expectations/binary/test_to_be_within.pks @@ -16,16 +16,16 @@ create or replace package test_to_be_within is procedure fail_for_number_not_within; --%test(Check failure message for inteval of 1 sec not within) - procedure fail_for_ds_interval_not_within; + procedure fail_for_ds_int_not_within; --%test(Check failure message for custom ds interval not within) - procedure fail_for_custom_ds_interval_not_within; + procedure fail_for_custom_ds_int; --%test(Check failure message for inteval of 1 month not within) - procedure fail_for_ym_interval_not_within; + procedure fail_for_ym_int_not_within; --%test(Check failure message for custom ym interval not within) - procedure fail_for_custom_ym_interval_not_within; + procedure fail_for_custom_ym_int; end; / \ No newline at end of file From a5481ac993f3fd4951a40c1a14ff44b05452045d Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 6 Jun 2020 02:21:16 +0100 Subject: [PATCH 082/887] fixing issue --- test/ut3_user/expectations/binary/test_to_be_within.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index 727ebbc03..b4c727a34 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -81,7 +81,7 @@ create or replace package body test_to_be_within is ut.expect(l_actual_message).to_be_like(l_expected_message); end; - procedure fail_for_number_not_within is + procedure fail_for_ds_int_not_within is l_actual_message varchar2(32767); l_expected_message varchar2(32767); begin From 9ee0e75cfa6f3e8cfef95e7f47d54f62c1990d93 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 7 Jun 2020 14:34:48 +0100 Subject: [PATCH 083/887] Update documentation and tests --- docs/userguide/expectations.md | 76 ++++++++++++++++++- source/core/ut_utils.pkb | 40 ++++++++-- source/expectations/matchers/ut_be_within.tpb | 23 ++++-- test/ut3_tester/core/test_ut_utils.pkb | 57 ++++++++++++++ test/ut3_tester/core/test_ut_utils.pks | 29 +++++++ .../expectations/binary/test_to_be_within.pkb | 4 +- 6 files changed, 211 insertions(+), 18 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0d8893ba4..4e93f0be1 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1096,15 +1096,85 @@ SUCCESS ## to_be_within of -This fuzzy matcher is designed to allow user to compare a numbers and dates within distance of error. +This matcher is created to determine wheter expected value is approximately equal or "close" to another value. -We are allowing a numbers to be compared within a absolute distance from other number of within a percentage calculated based on expected value. +Matcher will allow to compare numbers as well as dates. -When comparing a date a distance is measured in interval. +When comparing a number the tolerance / distance can be expressed as another postive number or a percentage. +When comparing a two dates tolerance can be expressed in interval time either Day-To-Second or Year-To-Month. +Matcher for numbers will calculate a absolute distance between expected and actual and check whether that value is within a tolerance. +When comparing a date a distance is measured in interval, the check is done that actual value is within date range of expected taking into account interval plus and minus. +**Example 1.** +```sql +begin + ut.expect(3).to_be_within(1).of_(4); +end; +/ +``` + +**Example 2.** +```sql +begin + ut.expect(9).to_be_within_pct(10).of_(10); +end; +/ +``` + +**Example 3.** +```sql +begin + ut.expect(sysdate).to_be_within_pct(interval '1' day).of_(sysdate + 1); +end; +/ +``` + +**Example 4.** +```sql +begin + ut.expect(sysdate).to_be_within_pct(interval '1' month).of_(add_months(sysdate,1)); +end; +/ +``` + +**Example 5.** +```sql +begin + ut.expect(3).to_be_within(1).of_(5); +end; +/ +``` + +Returns following output via DBMS_OUTPUT: +``` +Failures: + + 1) wihtin_test + Actual: 3 (number) was expected to be within 1 of 5 (number) + at "UT3_DEVELOP.UT_BE_WITHIN.OF_", line 48 l_result.expectation.to_(l_result ); + at "UT3_DEVELOP.TEST_BETWNSTR.WIHTIN_TEST", line 5 +``` + +**Example 6.** +```sql +begin + ut.expect(sysdate).to_be_within(interval '1' day).of_(sysdate+2); +end; +/ +``` + +Returns following output via DBMS_OUTPUT: +``` +Failures: + + 1) wihtin_test + Actual: 2020-06-07T13:32:58 (date) was expected to be within 1 day of 2020-06-09T13:32:58 (date) + at "UT3_DEVELOP.UT_BE_WITHIN.OF_", line 55 l_result.expectation.to_(l_result ); + at "UT3_DEVELOP.TEST_BETWNSTR.WIHTIN_TEST", line 5 +``` ## Comparing cursors, object types, nested tables and varrays diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 8e96870d9..4b6c66d95 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -884,10 +884,29 @@ create or replace package body ut_utils is l_second varchar2(100) := extract(second from a_interval); l_result varchar2(32767); begin - l_result := case when l_day > 0 then l_day ||' day' else null end; - l_result := l_result || case when l_hour > 0 then ' '|| l_hour ||' hour' else null end; - l_result := l_result || case when l_minute> 0 then ' '||l_minute ||' minute' else null end; - l_result := l_result || case when l_second > 0 then ' '||l_second ||' second' else null end; + l_result := case + when l_day = 1 then l_day ||' day' + when l_day > 1 then l_day ||' days' + else null + end; + l_result := l_result || + case + when l_hour = 1 then ' '|| l_hour ||' hour' + when l_hour > 1 then ' '|| l_hour ||' hours' + else null + end; + l_result := l_result || + case + when l_minute = 1 then ' '||l_minute ||' minute' + when l_minute > 1 then ' '||l_minute ||' minutes' + else null + end; + l_result := l_result || + case + when l_second = 1 then ' '||l_second ||' second' + when l_second > 1 then ' '||l_second ||' seconds' + else null + end; return trim(leading ' ' from l_result); end; @@ -896,8 +915,17 @@ create or replace package body ut_utils is l_month varchar2(20) := extract(month from a_interval); l_result varchar2(32767); begin - l_result := case when l_year > 0 then l_year ||' year' else null end; - l_result := l_result || case when l_month > 0 then ' '||l_month ||' month' else null end; + l_result := case + when l_year = 1 then l_year ||' year' + when l_year > 1 then l_year ||' years' + else null + end; + l_result := l_result || + case + when l_month = 1 then ' '||l_month ||' month' + when l_month > 1 then ' '||l_month ||' months' + else null + end; return trim(leading ' ' from l_result); end; diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index 0832b4946..ab4ed8b6f 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -60,16 +60,25 @@ create or replace type body ut_be_within as begin if self.expected.data_type = a_actual.data_type then if self.expected is of (ut_data_value_number) and self.is_pct = 0 then - l_result := abs((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value)) <= treat(self.dist as ut_data_value_number).data_value; + l_result := abs((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value)) <= + treat(self.dist as ut_data_value_number).data_value; elsif self.expected is of (ut_data_value_number) and self.is_pct = 1 then - l_result := treat(self.dist as ut_data_value_number).data_value >= ((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ) / - (treat(self.expected as ut_data_value_number).data_value) ; + l_result := treat(self.dist as ut_data_value_number).data_value >= + ( + ((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ) / + (treat(self.expected as ut_data_value_number).data_value)) ; elsif self.expected is of (ut_data_value_date) and self.dist is of ( ut_data_value_yminterval) then - l_result := treat(a_actual as ut_data_value_date).data_value between (treat(self.expected as ut_data_value_date).data_value) - treat(self.dist as ut_data_value_yminterval).data_value - and (treat(self.expected as ut_data_value_date).data_value) + treat(self.dist as ut_data_value_yminterval).data_value; + l_result := treat(a_actual as ut_data_value_date).data_value + between + (treat(self.expected as ut_data_value_date).data_value) - treat(self.dist as ut_data_value_yminterval).data_value + and + (treat(self.expected as ut_data_value_date).data_value) + treat(self.dist as ut_data_value_yminterval).data_value; elsif self.expected is of (ut_data_value_date) and self.dist is of ( ut_data_value_dsinterval) then - l_result := treat(a_actual as ut_data_value_date).data_value between (treat(self.expected as ut_data_value_date).data_value) - treat(self.dist as ut_data_value_dsinterval).data_value - and (treat(self.expected as ut_data_value_date).data_value) + treat(self.dist as ut_data_value_dsinterval).data_value; + l_result := treat(a_actual as ut_data_value_date).data_value + between + (treat(self.expected as ut_data_value_date).data_value) - treat(self.dist as ut_data_value_dsinterval).data_value + and + (treat(self.expected as ut_data_value_date).data_value) + treat(self.dist as ut_data_value_dsinterval).data_value; end if; else l_result := (self as ut_matcher).run_matcher(a_actual); diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index a3ed605f9..61bc61a84 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -432,5 +432,62 @@ end; --Assert ut.expect(l_actual).to_equal(l_expected); end; + + procedure int_conv_ds_sec is + l_expected varchar2(100) := '1 second'; + l_actual varchar2(200) := ut3_develop.ut_utils.interval_to_text(interval '1' second); + begin + ut.expect(l_expected).to_equal(l_actual); + end; + + procedure int_conv_ds_minute is + l_expected varchar2(100) := '1 minute'; + l_actual varchar2(200) := ut3_develop.ut_utils.interval_to_text(interval '1' minute); + begin + ut.expect(l_expected).to_equal(l_actual); + end; + + procedure int_conv_ds_hour is + l_expected varchar2(100) := '1 hour'; + l_actual varchar2(200) := ut3_develop.ut_utils.interval_to_text(interval '1' hour); + begin + ut.expect(l_expected).to_equal(l_actual); + end; + + procedure int_conv_ds_day is + l_expected varchar2(100) := '1 day'; + l_actual varchar2(200) := ut3_develop.ut_utils.interval_to_text(interval '1' day); + begin + ut.expect(l_expected).to_equal(l_actual); + end; + + procedure int_conv_ds_date is + l_expected varchar2(100) := '2 days 3 hours 4 minutes 11.333 seconds'; + l_actual varchar2(200) := ut3_develop.ut_utils.interval_to_text(INTERVAL '2 3:04:11.333' DAY TO SECOND); + begin + ut.expect(l_expected).to_equal(l_actual); + end; + + procedure int_conv_ym_year is + l_expected varchar2(100) := '1 year'; + l_actual varchar2(200) := ut3_develop.ut_utils.interval_to_text(interval '1' year); + begin + ut.expect(l_expected).to_equal(l_actual); + end; + + procedure int_conv_ym_month is + l_expected varchar2(100) := '1 month'; + l_actual varchar2(200) := ut3_develop.ut_utils.interval_to_text(interval '1' month); + begin + ut.expect(l_expected).to_equal(l_actual); + end; + + procedure int_conv_ym_date is + l_expected varchar2(100) := '1 year 2 months'; + l_actual varchar2(200) := ut3_develop.ut_utils.interval_to_text(INTERVAL '1-2' YEAR TO MONTH); + begin + ut.expect(l_expected).to_equal(l_actual); + end; + end test_ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index d8fca3b60..9d428b363 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -128,5 +128,34 @@ create or replace package test_ut_utils is --%test(replace_multiline_comments - replaces multi-line comments with empty lines) procedure replace_multiline_comments; + --%context(interval_converter_to_strin) + + --%test(Test day to second interval passing a second) + procedure int_conv_ds_sec; + + --%test(Test day to second interval passing a minute) + procedure int_conv_ds_minute; + + --%test(Test day to second interval passing a hour) + procedure int_conv_ds_hour; + + --%test(Test day to second interval passing a day) + procedure int_conv_ds_day; + + --%test(Test day to second interval passing a custom date ) + procedure int_conv_ds_date; + + --%test(Test year to month interval passing a hour) + procedure int_conv_ym_year; + + --%test(Test year to month interval passing a day) + procedure int_conv_ym_month; + + --%test(Test year to month interval passing a custom date ) + procedure int_conv_ym_date; + + + --%endcontext + end test_ut_utils; / diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index b4c727a34..af672e809 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -103,7 +103,7 @@ create or replace package body test_to_be_within is --Act ut3_develop.ut.expect(sysdate).to_be_within(INTERVAL '2 3:04:11.333' DAY TO SECOND).of_(sysdate+100); --Assert - l_expected_message := q'[Actual: % (date) was expected to be within 2 day 3 hour 4 minute 11.333 second of % (date)]'; + l_expected_message := q'[Actual: % (date) was expected to be within 2 days 3 hours 4 minutes 11.333 seconds of % (date)]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); @@ -131,7 +131,7 @@ create or replace package body test_to_be_within is --Act ut3_develop.ut.expect(sysdate).to_be_within(INTERVAL '1-3' YEAR TO MONTH).of_(sysdate+720); --Assert - l_expected_message := q'[Actual: % (date) was expected to be within 1 year 3 month % (date)]'; + l_expected_message := q'[Actual: % (date) was expected to be within 1 year 3 months % (date)]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); From a3b3a203e91e001b6bcd5ae0a0212242410afe35 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 10 Jun 2020 23:28:47 +0100 Subject: [PATCH 084/887] Changed `dbms_plssqlcode` tables to be permanent. --- source/core/coverage/dbms_plssqlcode.sql | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/source/core/coverage/dbms_plssqlcode.sql b/source/core/coverage/dbms_plssqlcode.sql index 4bba7780c..1ae287207 100644 --- a/source/core/coverage/dbms_plssqlcode.sql +++ b/source/core/coverage/dbms_plssqlcode.sql @@ -7,7 +7,7 @@ begin select synonym_name from all_synonyms where synonym_name = 'DBMSPCC_BLOCKS' and owner = sys_context('USERENV','CURRENT_SCHEMA')); if l_tab_exist = 0 then execute immediate q'[ - create global temporary table dbmspcc_blocks ( + create table dbmspcc_blocks ( run_id number(38, 0), object_id number(38, 0), block number(38, 0), @@ -21,7 +21,7 @@ begin constraint dbmspcc_blocks_covered_ck check ( covered in ( 0, 1 ) ) enable, constraint dbmspcc_blocks_not_feasible_ck check ( not_feasible in ( 0, 1 ) ) enable, constraint dbmspcc_blocks_pk primary key ( run_id, object_id, block ) using index - ) on commit preserve rows]'; + )]'; end if; end; / @@ -34,13 +34,13 @@ begin select synonym_name from all_synonyms where synonym_name = 'DBMSPCC_RUNS' and owner = sys_context('USERENV','CURRENT_SCHEMA')); if l_tab_exist = 0 then execute immediate q'[ - create global temporary table dbmspcc_runs ( + create table dbmspcc_runs ( run_id number(38, 0), run_comment varchar2(4000 byte), run_owner varchar2(128 byte) constraint dbmspcc_runs_run_owner_nn not null enable, run_timestamp date constraint dbmspcc_runs_run_timestamp_nn not null enable, constraint dbmspcc_runs_pk primary key ( run_id ) using index enable - ) on commit preserve rows]'; + )]'; end if; end; / @@ -53,7 +53,7 @@ begin select synonym_name from all_synonyms where synonym_name = 'DBMSPCC_UNITS' and owner = sys_context('USERENV','CURRENT_SCHEMA')); if l_tab_exist = 0 then execute immediate q'[ - create global temporary table dbmspcc_units ( + create table dbmspcc_units ( run_id number(38, 0), object_id number(38, 0), owner varchar2(128 byte) constraint dbmspcc_units_owner_nn not null enable, @@ -61,7 +61,7 @@ begin type varchar2(12 byte) constraint dbmspcc_units_type_nn not null enable, last_ddl_time date constraint dbmspcc_units_last_ddl_time_nn not null enable, constraint dbmspcc_units_pk primary key ( run_id, object_id ) using index enable - ) on commit preserve rows]'; + )]'; end if; end; / From 93fd222b3133aad57ce8bec57ad0fdf71d3d5dfc Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 10 Jun 2020 23:29:15 +0100 Subject: [PATCH 085/887] Reworked coverage to allow for gathering coverage without calling utPLSQL. Enables multi-session coverage too. --- examples/RunExpectations.sql | 2 +- source/api/ut.pkb | 36 ++ source/api/ut_runner.pkb | 77 ++-- source/api/ut_runner.pks | 4 + source/core/coverage/ut_coverage.pkb | 61 ++- source/core/coverage/ut_coverage.pks | 34 +- source/core/coverage/ut_coverage_block.pkb | 8 +- source/core/coverage/ut_coverage_block.pks | 2 +- source/core/coverage/ut_coverage_helper.pkb | 16 +- source/core/coverage/ut_coverage_helper.pks | 2 + .../coverage/ut_coverage_helper_block.pkb | 67 ++-- .../coverage/ut_coverage_helper_block.pks | 6 +- .../coverage/ut_coverage_helper_profiler.pkb | 20 +- .../coverage/ut_coverage_helper_profiler.pks | 6 +- source/core/coverage/ut_coverage_profiler.pkb | 8 +- source/core/coverage/ut_coverage_profiler.pks | 2 +- .../coverage/ut_coverage_reporter_base.tpb | 28 +- .../coverage/ut_coverage_reporter_base.tps | 5 +- source/core/coverage/ut_coverage_runs.sql | 20 + .../output_buffers/ut_output_buffer_base.tpb | 2 +- source/core/types/ut_coverage_options.tpb | 64 ++++ source/core/types/ut_coverage_options.tps | 11 +- source/core/types/ut_run.tpb | 14 +- source/core/types/ut_run.tps | 7 +- source/core/ut_utils.pkb | 33 +- source/core/ut_utils.pks | 43 ++- source/create_grants.sql | 2 + source/create_synonyms.sql | 1 + source/install.sql | 2 + .../ut_coverage_cobertura_reporter.tpb | 2 +- .../ut_coverage_report_html_helper.pkb | 2 +- .../reporters/ut_coverage_sonar_reporter.tpb | 2 +- source/reporters/ut_coveralls_reporter.tpb | 2 +- source/uninstall_coverage_tables.sql | 2 +- source/uninstall_objects.sql | 4 +- test/install_ut3_user_tests.sql | 10 +- test/ut3_tester/core/test_output_buffer.pkb | 2 +- test/ut3_tester/core/test_ut_executable.pkb | 30 -- test/ut3_tester/core/test_ut_test.pks | 2 +- test/ut3_tester_helper/coverage_helper.pkb | 355 +++++++++++------- test/ut3_tester_helper/coverage_helper.pks | 21 +- test/ut3_tester_helper/main_helper.pkb | 8 - test/ut3_tester_helper/main_helper.pks | 6 +- test/ut3_user/reporters/test_coverage.pkb | 8 +- test/ut3_user/reporters/test_coverage.pks | 15 +- .../test_cov_cobertura_reporter.pkb | 55 +-- .../test_coverage_sonar_reporter.pkb | 33 +- .../test_coverage_standalone.pkb | 36 ++ .../test_coverage_standalone.pks | 13 + .../test_coverage/test_coveralls_reporter.pkb | 58 +-- .../test_coverage/test_extended_coverage.pkb | 71 ++++ .../test_extended_coverage.pks | 6 +- .../test_html_extended_reporter.pkb | 31 +- .../test_html_extended_reporter.pks | 2 +- .../test_coverage/test_proftab_coverage.pkb | 133 +++++++ .../test_proftab_coverage.pks | 3 +- .../reporters/test_extended_coverage.pkb | 74 ---- .../reporters/test_proftab_coverage.pkb | 132 ------- 58 files changed, 1009 insertions(+), 692 deletions(-) create mode 100644 source/core/coverage/ut_coverage_runs.sql create mode 100644 source/core/types/ut_coverage_options.tpb create mode 100644 test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb create mode 100644 test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks create mode 100644 test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb rename test/ut3_user/reporters/{ => test_coverage}/test_extended_coverage.pks (66%) create mode 100644 test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb rename test/ut3_user/reporters/{ => test_coverage}/test_proftab_coverage.pks (85%) delete mode 100644 test/ut3_user/reporters/test_extended_coverage.pkb delete mode 100644 test/ut3_user/reporters/test_proftab_coverage.pkb diff --git a/examples/RunExpectations.sql b/examples/RunExpectations.sql index aeb5c40bc..eed123e72 100644 --- a/examples/RunExpectations.sql +++ b/examples/RunExpectations.sql @@ -11,7 +11,7 @@ set echo off @@demo_expectations.pck begin - ut_coverage.coverage_start(); + ut_coverage.coverage_start(sys_guid()); ut_coverage.set_develop_mode(true); ut.run(); ut_coverage.set_develop_mode(false); diff --git a/source/api/ut.pkb b/source/api/ut.pkb index 3b94a2bf7..72e868a9d 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -248,6 +248,12 @@ create or replace package body ut is end loop; end if; return; + exception + when no_data_needed then + if l_results%isopen then + close l_results; + end if; + raise; end; function run( @@ -287,6 +293,12 @@ create or replace package body ut is end loop; end if; return; + exception + when no_data_needed then + if l_results%isopen then + close l_results; + end if; + raise; end; function run( @@ -327,6 +339,12 @@ create or replace package body ut is end loop; end if; return; + exception + when no_data_needed then + if l_results%isopen then + close l_results; + end if; + raise; end; function run( @@ -367,6 +385,12 @@ create or replace package body ut is end loop; end if; return; + exception + when no_data_needed then + if l_results%isopen then + close l_results; + end if; + raise; end; function run( @@ -407,6 +431,12 @@ create or replace package body ut is end loop; end if; return; + exception + when no_data_needed then + if l_results%isopen then + close l_results; + end if; + raise; end; function run( @@ -447,6 +477,12 @@ create or replace package body ut is end loop; end if; return; + exception + when no_data_needed then + if l_results%isopen then + close l_results; + end if; + raise; end; procedure run( diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 2f523e1dd..31306b1c9 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -20,27 +20,6 @@ create or replace package body ut_runner is /** * Private functions */ - function to_ut_object_list(a_names ut_varchar2_list, a_schema_names ut_varchar2_rows) return ut_object_names is - l_result ut_object_names; - l_object_name ut_object_name; - begin - if a_names is not empty then - l_result := ut_object_names(); - for i in 1 .. a_names.count loop - l_object_name := ut_object_name(a_names(i)); - if l_object_name.owner is null then - for i in 1 .. cardinality(a_schema_names) loop - l_result.extend; - l_result(l_result.last) := ut_object_name(a_schema_names(i)||'.'||l_object_name.name); - end loop; - else - l_result.extend; - l_result(l_result.last) := l_object_name; - end if; - end loop; - end if; - return l_result; - end; procedure finish_run(a_run ut_run, a_force_manual_rollback boolean) is begin @@ -51,7 +30,6 @@ create or replace package body ut_runner is ut_compound_data_helper.cleanup_diff(); if not a_force_manual_rollback then rollback; - ut_utils.cleanup_session_temp_tables; end if; end; @@ -95,9 +73,7 @@ create or replace package body ut_runner is ) is l_run ut_run; l_coverage_schema_names ut_varchar2_rows; - l_exclude_object_names ut_object_names := ut_object_names(); - l_include_object_names ut_object_names; - l_paths ut_varchar2_list := ut_varchar2_list(); + l_paths ut_varchar2_list; l_random_test_order_seed positive; l_tags ut_varchar2_rows := ut_varchar2_rows(); begin @@ -113,18 +89,17 @@ create or replace package body ut_runner is ut_event_manager.trigger_event(ut_event_manager.gc_initialize); ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_run_info()); + if a_random_test_order_seed is not null then l_random_test_order_seed := a_random_test_order_seed; elsif a_random_test_order then dbms_random.seed( to_char(systimestamp,'yyyyddmmhh24missffff') ); l_random_test_order_seed := trunc(dbms_random.value(1, 1000000000)); end if; - if a_paths is null or a_paths is empty or a_paths.count = 1 and a_paths(1) is null then + + l_paths := ut_utils.filter_list(ut_utils.string_table_to_table(a_paths,','), '.+'); + if l_paths is null or l_paths is empty then l_paths := ut_varchar2_list(sys_context('userenv', 'current_schema')); - else - for i in 1..a_paths.count loop - l_paths := l_paths multiset union ut_utils.string_to_table(a_string => a_paths(i),a_delimiter => ','); - end loop; end if; begin @@ -132,36 +107,32 @@ create or replace package body ut_runner is ut_utils.save_dbms_output_to_cache(); ut_console_reporter_base.set_color_enabled(a_color_console); + if a_coverage_schemes is not empty then l_coverage_schema_names := ut_utils.convert_collection(a_coverage_schemes); else l_coverage_schema_names := ut_suite_manager.get_schema_names(l_paths); end if; - if a_exclude_objects is not empty then - l_exclude_object_names := to_ut_object_list(a_exclude_objects, l_coverage_schema_names); - end if; - + if a_tags is not null then - l_tags := l_tags multiset union distinct ut_utils.convert_collection( + l_tags := l_tags multiset union distinct ut_utils.convert_collection( ut_utils.trim_list_elements(ut_utils.filter_list(ut_utils.string_to_table(a_tags,','),ut_utils.gc_word_no_space)) ); end if; - l_exclude_object_names := l_exclude_object_names multiset union all ut_suite_manager.get_schema_ut_packages(l_coverage_schema_names); - - l_include_object_names := to_ut_object_list(a_include_objects, l_coverage_schema_names); l_run := ut_run( - null, - l_paths, - l_coverage_schema_names, - l_exclude_object_names, - l_include_object_names, - set(a_source_file_mappings), - set(a_test_file_mappings), - a_client_character_set, - l_random_test_order_seed, - l_tags + a_run_paths => l_paths, + a_coverage_options => ut_coverage_options( + schema_names => l_coverage_schema_names, + exclude_objects => ut_utils.convert_collection(a_exclude_objects), + include_objects => ut_utils.convert_collection(a_include_objects), + file_mappings => set(a_source_file_mappings) + ), + a_test_file_mappings => set(a_test_file_mappings), + a_client_character_set => a_client_character_set, + a_random_test_order_seed => l_random_test_order_seed, + a_run_tags => l_tags ); ut_suite_manager.configure_execution_by_path(l_paths, l_run.items, l_random_test_order_seed, l_tags); @@ -296,5 +267,15 @@ create or replace package body ut_runner is return l_result; end; + procedure coverage_start(a_coverage_run_id raw) is + begin + ut_coverage.coverage_start(a_coverage_run_id); + end; + + procedure coverage_stop is + begin + ut_coverage.coverage_stop; + end; + end ut_runner; / diff --git a/source/api/ut_runner.pks b/source/api/ut_runner.pks index 38167ac57..61578a4e0 100644 --- a/source/api/ut_runner.pks +++ b/source/api/ut_runner.pks @@ -145,5 +145,9 @@ create or replace package ut_runner authid current_user is */ function hash_suite_path(a_path varchar2, a_random_seed positiven) return varchar2; + procedure coverage_start(a_coverage_run_id raw); + + procedure coverage_stop; + end ut_runner; / diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index caa75ae51..879b6f5b5 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -16,26 +16,21 @@ create or replace package body ut_coverage is limitations under the License. */ - g_coverage_id tt_coverage_id_arr; - g_develop_mode boolean not null := false; - g_is_started boolean not null := false; + g_coverage_run_id raw(32); + g_develop_mode boolean not null := false; + g_is_started boolean not null := false; procedure set_develop_mode(a_develop_mode in boolean) is - begin - g_develop_mode := a_develop_mode; - end; - - function get_coverage_id(a_coverage_type in varchar2) return integer is - begin - return g_coverage_id(a_coverage_type); - end; + begin + g_develop_mode := a_develop_mode; + end; function is_develop_mode return boolean is - begin - return g_develop_mode; - end; + begin + return g_develop_mode; + end; - function get_cov_sources_sql(a_coverage_options ut_coverage_options, a_skip_objects ut_object_names) return varchar2 is + function get_cov_sources_sql(a_coverage_options ut_coverage_options, a_skip_objects ut_object_names) return varchar2 is l_result varchar2(32767); l_full_name varchar2(32767); l_join_mappings varchar2(32767); @@ -177,14 +172,16 @@ create or replace package body ut_coverage is /** * Public functions */ - procedure coverage_start(a_coverage_options ut_coverage_options default null) is + procedure coverage_start(a_coverage_run_id t_coverage_run_id) is l_run_comment varchar2(200) := 'utPLSQL Code coverage run '||ut_utils.to_string(systimestamp); + l_line_coverage_id integer; + l_block_coverage_id integer; begin if not is_develop_mode() and not g_is_started then - ut_coverage_helper_block.coverage_start( l_run_comment, g_coverage_id(gc_block_coverage) ); - ut_coverage_helper_profiler.coverage_start( l_run_comment, g_coverage_id(gc_proftab_coverage) ); - coverage_pause(); + l_line_coverage_id := ut_coverage_helper_profiler.coverage_start( l_run_comment ); + l_block_coverage_id := ut_coverage_helper_block.coverage_start( l_run_comment ); g_is_started := true; + ut_coverage_helper.set_coverage_run_ids(a_coverage_run_id, l_line_coverage_id, l_block_coverage_id); end if; end; @@ -200,18 +197,14 @@ create or replace package body ut_coverage is ut_coverage_helper_profiler.coverage_resume(); end; - procedure mock_coverage_id(a_coverage_id integer,a_coverage_type in varchar2) is + procedure mock_coverage_id( + a_coverage_run_id t_coverage_run_id, a_line_coverage_id integer, a_block_coverage_id integer + ) is begin g_develop_mode := true; g_is_started := true; - g_coverage_id(a_coverage_type) := a_coverage_id; - end; - - procedure mock_coverage_id(a_coverage_id tt_coverage_id_arr) is - begin - g_develop_mode := true; - g_is_started := true; - g_coverage_id := a_coverage_id; + g_coverage_run_id := a_coverage_run_id; + ut_coverage_helper.set_coverage_run_ids(a_coverage_run_id, a_line_coverage_id, a_block_coverage_id); end; procedure coverage_stop is @@ -227,22 +220,26 @@ create or replace package body ut_coverage is function get_coverage_data(a_coverage_options ut_coverage_options) return t_coverage is l_result_block ut_coverage.t_coverage; l_result_profiler_enrich ut_coverage.t_coverage; - l_object ut_coverage.t_full_name; + l_object ut_coverage.t_object_name; l_line_no binary_integer; + l_coverage_options ut_coverage_options := a_coverage_options; begin + if is_develop_mode() then + l_coverage_options.coverage_run_id := coalesce(g_coverage_run_id, l_coverage_options.coverage_run_id); + end if; --prepare global temp table with sources ut_event_manager.trigger_event('about to populate coverage temp table'); - populate_tmp_table(a_coverage_options); + populate_tmp_table(l_coverage_options); ut_event_manager.trigger_event('coverage temp table populated'); -- Get raw data for both reporters, order is important as tmp table will skip headers and dont populate -- tmp table for block again. - l_result_profiler_enrich:= ut_coverage_profiler.get_coverage_data( a_coverage_options, get_coverage_id(gc_proftab_coverage) ); + l_result_profiler_enrich := ut_coverage_profiler.get_coverage_data( l_coverage_options ); ut_event_manager.trigger_event('profiler coverage data retrieved'); -- If block coverage available we will use it. $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - l_result_block := ut_coverage_block.get_coverage_data( a_coverage_options, get_coverage_id(gc_block_coverage) ); + l_result_block := ut_coverage_block.get_coverage_data( l_coverage_options ); ut_event_manager.trigger_event('block coverage data retrieved'); -- Enrich profiler results with some of the block results diff --git a/source/core/coverage/ut_coverage.pks b/source/core/coverage/ut_coverage.pks index 1d87d50c9..5e960c5ea 100644 --- a/source/core/coverage/ut_coverage.pks +++ b/source/core/coverage/ut_coverage.pks @@ -16,25 +16,21 @@ create or replace package ut_coverage authid current_user is limitations under the License. */ - gc_proftab_coverage constant varchar2(32) := 'proftab'; - gc_block_coverage constant varchar2(32) := 'block'; - - type tt_coverage_id_arr is table of integer index by varchar2(30); + subtype t_coverage_run_id is raw(32) not null; -- total run coverage information - subtype t_full_name is varchar2(4000); - subtype t_object_name is varchar2(250); - - --subtype t_line_executions is binary_integer; + subtype t_object_name is varchar2(257); + subtype t_line_no is binary_integer; type t_line_executions is record( - executions binary_integer - ,partcove binary_integer - ,no_blocks binary_integer + executions binary_integer + ,partcove binary_integer + ,no_blocks binary_integer ,covered_blocks binary_integer); + -- line coverage information indexed by line no. - --type tt_lines is table of t_line_executions index by binary_integer; - type tt_lines is table of t_line_executions index by binary_integer; + type tt_lines is table of t_line_executions index by t_line_no; + --unit coverage information record type t_unit_coverage is record( owner varchar2(128) @@ -50,7 +46,7 @@ create or replace package ut_coverage authid current_user is ,lines tt_lines); -- coverage information indexed by full object name (schema.object) - type tt_program_units is table of t_unit_coverage index by t_full_name; + type tt_program_units is table of t_unit_coverage index by t_object_name; -- total run coverage information type t_coverage is record( @@ -64,8 +60,6 @@ create or replace package ut_coverage authid current_user is ,executions number(38, 0) := 0 ,objects tt_program_units); - function get_coverage_id(a_coverage_type in varchar2) return integer; - procedure set_develop_mode(a_develop_mode in boolean); function is_develop_mode return boolean; @@ -74,11 +68,11 @@ create or replace package ut_coverage authid current_user is * Allows overwriting of private global variable g_coverage_id * Used internally, only for unit testing of the framework only */ - procedure mock_coverage_id(a_coverage_id integer, a_coverage_type in varchar2); - - procedure mock_coverage_id(a_coverage_id tt_coverage_id_arr); + procedure mock_coverage_id( + a_coverage_run_id t_coverage_run_id, a_line_coverage_id integer, a_block_coverage_id integer + ); - procedure coverage_start(a_coverage_options ut_coverage_options default null); + procedure coverage_start(a_coverage_run_id t_coverage_run_id); procedure coverage_stop; diff --git a/source/core/coverage/ut_coverage_block.pkb b/source/core/coverage/ut_coverage_block.pkb index c6d0f409d..0e0373a48 100644 --- a/source/core/coverage/ut_coverage_block.pkb +++ b/source/core/coverage/ut_coverage_block.pkb @@ -23,7 +23,7 @@ create or replace package body ut_coverage_block is * Public functions */ - function get_coverage_data(a_coverage_options ut_coverage_options, a_coverage_id integer) return ut_coverage.t_coverage is + function get_coverage_data(a_coverage_options ut_coverage_options) return ut_coverage.t_coverage is l_line_calls ut_coverage_helper.t_unit_line_calls; l_result ut_coverage.t_coverage; l_new_unit ut_coverage.t_unit_coverage; @@ -40,7 +40,11 @@ create or replace package body ut_coverage_block is exit when l_source_objects_crsr%notfound; --get coverage data - l_line_calls := ut_coverage_helper_block.get_raw_coverage_data(l_source_object.owner, l_source_object.name, a_coverage_id); + l_line_calls := ut_coverage_helper_block.get_raw_coverage_data( + l_source_object.owner, + l_source_object.name, + a_coverage_options.coverage_run_id + ); --if there is coverage, we need to filter out the garbage (badly indicated data) if l_line_calls.count > 0 then --remove lines that should not be indicted as meaningful diff --git a/source/core/coverage/ut_coverage_block.pks b/source/core/coverage/ut_coverage_block.pks index 26c79317e..08de58e69 100644 --- a/source/core/coverage/ut_coverage_block.pks +++ b/source/core/coverage/ut_coverage_block.pks @@ -16,7 +16,7 @@ create or replace package ut_coverage_block authid current_user is limitations under the License. */ - function get_coverage_data(a_coverage_options ut_coverage_options, a_coverage_id integer) return ut_coverage.t_coverage; + function get_coverage_data(a_coverage_options ut_coverage_options) return ut_coverage.t_coverage; end; / diff --git a/source/core/coverage/ut_coverage_helper.pkb b/source/core/coverage/ut_coverage_helper.pkb index 12ee9e1f7..5762452c4 100644 --- a/source/core/coverage/ut_coverage_helper.pkb +++ b/source/core/coverage/ut_coverage_helper.pkb @@ -60,10 +60,10 @@ create or replace package body ut_coverage_helper is l_result t_tmp_table_objects_crsr; begin open l_result for - select o.owner, o.name, o.full_name, max(o.line) lines_count, + select o.owner, o.name, o.full_name, max(o.line) as lines_count, cast( collect(decode(to_be_skipped, 'Y', to_char(line))) as ut_varchar2_list - ) to_be_skipped_list + ) as to_be_skipped_list from ut_coverage_sources_tmp o group by o.owner, o.name, o.full_name; @@ -73,7 +73,7 @@ create or replace package body ut_coverage_helper is function get_tmp_table_object_lines(a_owner varchar2, a_object_name varchar2) return ut_varchar2_list is l_result ut_varchar2_list; begin - select rtrim(s.text,chr(10)) text + select rtrim(s.text,chr(10)) as text bulk collect into l_result from ut_coverage_sources_tmp s where s.owner = a_owner @@ -83,5 +83,15 @@ create or replace package body ut_coverage_helper is return l_result; end; + procedure set_coverage_run_ids( a_coverage_run_id raw, a_line_coverage_id integer, a_block_coverage_id integer ) is + pragma autonomous_transaction; + begin + insert into ut_coverage_runs + ( coverage_run_id, line_coverage_id, block_coverage_id ) + values + ( a_coverage_run_id, a_line_coverage_id, a_block_coverage_id ); + commit; + end; + end; / diff --git a/source/core/coverage/ut_coverage_helper.pks b/source/core/coverage/ut_coverage_helper.pks index 85a54a7ca..955542633 100644 --- a/source/core/coverage/ut_coverage_helper.pks +++ b/source/core/coverage/ut_coverage_helper.pks @@ -59,5 +59,7 @@ create or replace package ut_coverage_helper authid definer is function get_tmp_table_object_lines(a_owner varchar2, a_object_name varchar2) return ut_varchar2_list; + procedure set_coverage_run_ids( a_coverage_run_id raw, a_line_coverage_id integer, a_block_coverage_id integer ); + end; / diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index fc64c507f..b81292017 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -30,12 +30,12 @@ create or replace package body ut_coverage_helper_block is type t_block_rows is table of t_block_row; - procedure coverage_start(a_run_comment varchar2, a_coverage_id out integer) is + function coverage_start(a_run_comment varchar2) return integer is begin $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - a_coverage_id := dbms_plsql_code_coverage.start_coverage(run_comment => a_run_comment); + return dbms_plsql_code_coverage.start_coverage(run_comment => a_run_comment); $else - null; + return null; $end end; @@ -48,45 +48,54 @@ create or replace package body ut_coverage_helper_block is $end end; - function block_results(a_object_owner varchar2, a_object_name varchar2, a_coverage_id integer) return t_block_rows is + function block_results(a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw) return t_block_rows is l_coverage_rows t_block_rows; + l_ut_owner varchar2(250) := ut_utils.ut_owner; begin - - select ccb.line as line, - count(ccb.block) as blocks, - sum(ccb.covered) as covered_blocks - bulk collect into l_coverage_rows - from dbmspcc_units ccu - left outer join dbmspcc_blocks ccb - on ccu.run_id = ccb.run_id - and ccu.object_id = ccb.object_id - where ccu.run_id = a_coverage_id - and ccu.owner = a_object_owner - and ccu.name = a_object_name - group by ccb.line - order by 1; - - return l_coverage_rows; + execute immediate q'[ + select line as line, + count(block) as blocks, + sum(covered) as covered_blocks + from (select line, + block, + max(covered) as covered + from dbmspcc_units ccu + join ]'||l_ut_owner||q'[.ut_coverage_runs r + on r.block_coverage_id = ccu.run_id + left join dbmspcc_blocks ccb + on ccu.run_id = ccb.run_id + and ccu.object_id = ccb.object_id + where r.coverage_run_id = :a_coverage_run_id + and ccu.owner = :a_object_owner + and ccu.name = :a_object_name + group by ccb.line, ccb.block + ) + group by line + order by line]' + bulk collect into l_coverage_rows using a_coverage_run_id, a_object_owner, a_object_name; + return l_coverage_rows; end; - function get_raw_coverage_data(a_object_owner varchar2, a_object_name varchar2, a_coverage_id integer) return ut_coverage_helper.t_unit_line_calls is + function get_raw_coverage_data( + a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw + ) return ut_coverage_helper.t_unit_line_calls is l_tmp_data t_block_rows; l_results ut_coverage_helper.t_unit_line_calls; begin $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - l_tmp_data := block_results(a_object_owner, a_object_name, a_coverage_id); + l_tmp_data := block_results(a_object_owner, a_object_name, a_coverage_run_id); for i in 1 .. l_tmp_data.count loop l_results(l_tmp_data(i).line).blocks := l_tmp_data(i).blocks; l_results(l_tmp_data(i).line).covered_blocks := l_tmp_data(i).covered_blocks; - l_results(l_tmp_data(i).line).partcovered := case - when (l_tmp_data(i).covered_blocks > 0) and - (l_tmp_data(i).blocks > l_tmp_data(i).covered_blocks) then - 1 - else - 0 - end; + l_results(l_tmp_data(i).line).partcovered := + case + when (l_tmp_data(i).covered_blocks > 0) + and (l_tmp_data(i).blocks > l_tmp_data(i).covered_blocks) + then 1 + else 0 + end; end loop; $end return l_results; diff --git a/source/core/coverage/ut_coverage_helper_block.pks b/source/core/coverage/ut_coverage_helper_block.pks index 0afa3ab15..9d24989d6 100644 --- a/source/core/coverage/ut_coverage_helper_block.pks +++ b/source/core/coverage/ut_coverage_helper_block.pks @@ -16,11 +16,13 @@ create or replace package ut_coverage_helper_block authid current_user is limitations under the License. */ - procedure coverage_start(a_run_comment in varchar2,a_coverage_id out integer); + function coverage_start(a_run_comment in varchar2) return integer; procedure coverage_stop; - function get_raw_coverage_data(a_object_owner varchar2, a_object_name varchar2, a_coverage_id integer) return ut_coverage_helper.t_unit_line_calls; + function get_raw_coverage_data( + a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw + ) return ut_coverage_helper.t_unit_line_calls; end; / diff --git a/source/core/coverage/ut_coverage_helper_profiler.pkb b/source/core/coverage/ut_coverage_helper_profiler.pkb index c90a5b36a..dde3bf3ea 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pkb +++ b/source/core/coverage/ut_coverage_helper_profiler.pkb @@ -31,9 +31,11 @@ create or replace package body ut_coverage_helper_profiler is type t_block_rows is table of t_block_row; - procedure coverage_start(a_run_comment varchar2,a_coverage_id out integer) is + function coverage_start(a_run_comment varchar2) return integer is + l_coverage_id integer; begin - dbms_profiler.start_profiler(run_comment => a_run_comment, run_number => a_coverage_id); + dbms_profiler.start_profiler(run_comment => a_run_comment, run_number => l_coverage_id); + return l_coverage_id; end; procedure coverage_pause is @@ -53,7 +55,7 @@ create or replace package body ut_coverage_helper_profiler is dbms_profiler.stop_profiler(); end; - function proftab_results(a_object_owner varchar2, a_object_name varchar2, a_coverage_id integer) return t_proftab_rows is + function proftab_results(a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw) return t_proftab_rows is l_coverage_rows t_proftab_rows; begin select @@ -64,20 +66,24 @@ create or replace package body ut_coverage_helper_profiler is join plsql_profiler_data d on u.runid = d.runid and u.unit_number = d.unit_number - where u.runid = a_coverage_id + join ut_coverage_runs r + on r.line_coverage_id = u.runid + where r.coverage_run_id = a_coverage_run_id and u.unit_owner = a_object_owner and u.unit_name = a_object_name and u.unit_type in ('PACKAGE BODY', 'TYPE BODY', 'PROCEDURE', 'FUNCTION', 'TRIGGER') group by d.line#; - + return l_coverage_rows; end; - function get_raw_coverage_data(a_object_owner varchar2, a_object_name varchar2, a_coverage_id integer) return ut_coverage_helper.t_unit_line_calls is + function get_raw_coverage_data( + a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw + ) return ut_coverage_helper.t_unit_line_calls is l_tmp_data t_proftab_rows; l_results ut_coverage_helper.t_unit_line_calls; begin - l_tmp_data := proftab_results(a_object_owner, a_object_name, a_coverage_id); + l_tmp_data := proftab_results(a_object_owner, a_object_name, a_coverage_run_id); for i in 1 .. l_tmp_data.count loop l_results(l_tmp_data(i).line).calls := l_tmp_data(i).calls; diff --git a/source/core/coverage/ut_coverage_helper_profiler.pks b/source/core/coverage/ut_coverage_helper_profiler.pks index 9345f4b88..390495810 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pks +++ b/source/core/coverage/ut_coverage_helper_profiler.pks @@ -16,7 +16,7 @@ create or replace package ut_coverage_helper_profiler authid definer is limitations under the License. */ - procedure coverage_start(a_run_comment in varchar2,a_coverage_id out integer); + function coverage_start(a_run_comment in varchar2) return integer; procedure coverage_stop; @@ -24,7 +24,9 @@ create or replace package ut_coverage_helper_profiler authid definer is procedure coverage_resume; - function get_raw_coverage_data(a_object_owner varchar2, a_object_name varchar2, a_coverage_id integer) return ut_coverage_helper.t_unit_line_calls; + function get_raw_coverage_data( + a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw + ) return ut_coverage_helper.t_unit_line_calls; end; / diff --git a/source/core/coverage/ut_coverage_profiler.pkb b/source/core/coverage/ut_coverage_profiler.pkb index 160e2dd41..274f6949c 100644 --- a/source/core/coverage/ut_coverage_profiler.pkb +++ b/source/core/coverage/ut_coverage_profiler.pkb @@ -19,7 +19,7 @@ create or replace package body ut_coverage_profiler is /** * Public functions */ - function get_coverage_data(a_coverage_options ut_coverage_options, a_coverage_id integer) return ut_coverage.t_coverage is + function get_coverage_data(a_coverage_options ut_coverage_options) return ut_coverage.t_coverage is l_line_calls ut_coverage_helper.t_unit_line_calls; l_result ut_coverage.t_coverage; l_new_unit ut_coverage.t_unit_coverage; @@ -34,7 +34,11 @@ create or replace package body ut_coverage_profiler is exit when l_source_objects_crsr%notfound; --get coverage data - l_line_calls := ut_coverage_helper_profiler.get_raw_coverage_data( l_source_object.owner, l_source_object.name, a_coverage_id); + l_line_calls := ut_coverage_helper_profiler.get_raw_coverage_data( + l_source_object.owner, + l_source_object.name, + a_coverage_options.coverage_run_id + ); --if there is coverage, we need to filter out the garbage (badly indicated data from dbms_profiler) if l_line_calls.count > 0 then diff --git a/source/core/coverage/ut_coverage_profiler.pks b/source/core/coverage/ut_coverage_profiler.pks index 8e671f899..59256ae65 100644 --- a/source/core/coverage/ut_coverage_profiler.pks +++ b/source/core/coverage/ut_coverage_profiler.pks @@ -16,7 +16,7 @@ create or replace package ut_coverage_profiler authid current_user is limitations under the License. */ - function get_coverage_data(a_coverage_options ut_coverage_options, a_coverage_id integer) return ut_coverage.t_coverage; + function get_coverage_data(a_coverage_options ut_coverage_options) return ut_coverage.t_coverage; end; / diff --git a/source/core/coverage/ut_coverage_reporter_base.tpb b/source/core/coverage/ut_coverage_reporter_base.tpb index 5067f9221..6300348e0 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tpb +++ b/source/core/coverage/ut_coverage_reporter_base.tpb @@ -19,7 +19,8 @@ create or replace type body ut_coverage_reporter_base is overriding final member procedure before_calling_run(self in out nocopy ut_coverage_reporter_base, a_run ut_run) as begin (self as ut_output_reporter_base).before_calling_run(a_run); - ut_coverage.coverage_start(a_coverage_options => a_run.coverage_options); + ut_coverage.coverage_start(a_coverage_run_id => a_run.coverage_options.coverage_run_id); + ut_coverage.coverage_pause(); end; overriding final member procedure before_calling_before_all(self in out nocopy ut_coverage_reporter_base, a_executable in ut_executable) is @@ -85,5 +86,30 @@ create or replace type body ut_coverage_reporter_base is ut_coverage.coverage_pause(); end; + final member function get_report( a_coverage_options ut_coverage_options ) return ut_varchar2_rows pipelined is + l_reporter ut_coverage_reporter_base := self; + begin + ut_coverage_helper.cleanup_tmp_table(); + (l_reporter as ut_output_reporter_base).before_calling_run(null); + l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options ) ); + l_reporter.on_finalize(null); + for i in (select x.text from table(l_reporter.get_lines(1, 1)) x ) loop + pipe row (i.text); + end loop; + return; + end; + + final member function get_report_cursor( a_coverage_options ut_coverage_options ) return sys_refcursor is + l_reporter ut_coverage_reporter_base := self; + l_result sys_refcursor; + begin + ut_coverage_helper.cleanup_tmp_table(); + (l_reporter as ut_output_reporter_base).before_calling_run(null); + l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options ) ); + l_reporter.on_finalize(null); + open l_result for select x.text from table(l_reporter.get_lines(1, 1)) x; + return l_result; + end; + end; / diff --git a/source/core/coverage/ut_coverage_reporter_base.tps b/source/core/coverage/ut_coverage_reporter_base.tps index 2b9d1c625..039bbe320 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tps +++ b/source/core/coverage/ut_coverage_reporter_base.tps @@ -36,8 +36,9 @@ create or replace type ut_coverage_reporter_base under ut_output_reporter_base( overriding final member procedure after_calling_after_each (self in out nocopy ut_coverage_reporter_base, a_executable in ut_executable), overriding final member procedure before_calling_after_all(self in out nocopy ut_coverage_reporter_base, a_executable in ut_executable), - overriding final member procedure after_calling_after_all (self in out nocopy ut_coverage_reporter_base, a_executable in ut_executable) - + overriding final member procedure after_calling_after_all (self in out nocopy ut_coverage_reporter_base, a_executable in ut_executable), + final member function get_report(a_coverage_options ut_coverage_options ) return ut_varchar2_rows pipelined, + final member function get_report_cursor(a_coverage_options ut_coverage_options ) return sys_refcursor ) not final not instantiable / diff --git a/source/core/coverage/ut_coverage_runs.sql b/source/core/coverage/ut_coverage_runs.sql new file mode 100644 index 000000000..78230240d --- /dev/null +++ b/source/core/coverage/ut_coverage_runs.sql @@ -0,0 +1,20 @@ +declare + l_tab_exist number; +begin + select count(*) into l_tab_exist + from all_tables + where table_name = 'UT_COVERAGE_RUNS' and owner = sys_context('USERENV','CURRENT_SCHEMA'); + if l_tab_exist = 0 then + execute immediate q'[create table ut_coverage_runs + ( + coverage_run_id raw(32) not null, + line_coverage_id number(38,0) unique not null, + block_coverage_id number(38,0) unique, + constraint ut_coverage_runs primary key (coverage_run_id, line_coverage_id) + ) organization index ]'; + execute immediate q'[comment on table ut_coverage_runs is + 'Map of block and line coverage runs for a test-run']'; + dbms_output.put_line('UT_COVERAGE_RUNS table created'); + end if; +end; +/ diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index 018250e4b..38f008e75 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -44,7 +44,7 @@ create or replace type body ut_output_buffer_base is return l_lines; end; - member procedure lines_to_dbms_output(self in ut_output_buffer_base, a_initial_timeout natural := null, a_timeout_sec natural := null) is + member procedure lines_to_dbms_output(self in ut_output_buffer_base, a_initial_timeout natural := null, a_timeout_sec natural := null) is l_data sys_refcursor; l_clob clob; l_item_type varchar2(32767); diff --git a/source/core/types/ut_coverage_options.tpb b/source/core/types/ut_coverage_options.tpb new file mode 100644 index 000000000..48a0f27c8 --- /dev/null +++ b/source/core/types/ut_coverage_options.tpb @@ -0,0 +1,64 @@ +create or replace type body ut_coverage_options as + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + constructor function ut_coverage_options( + self in out nocopy ut_coverage_options, + coverage_run_id raw := null, + schema_names ut_varchar2_rows := null, + exclude_objects ut_varchar2_rows := null, + include_objects ut_varchar2_rows := null, + file_mappings ut_file_mappings := null + ) return self as result is + function to_ut_object_list(a_names ut_varchar2_rows, a_schema_names ut_varchar2_rows) return ut_object_names is + l_result ut_object_names; + l_object_name ut_object_name; + begin + if a_names is not empty then + l_result := ut_object_names(); + for i in 1 .. a_names.count loop + l_object_name := ut_object_name(a_names(i)); + if l_object_name.owner is null then + for i in 1 .. cardinality(a_schema_names) loop + l_result.extend; + l_result(l_result.last) := ut_object_name(a_schema_names(i)||'.'||l_object_name.name); + end loop; + else + l_result.extend; + l_result(l_result.last) := l_object_name; + end if; + end loop; + end if; + return l_result; + end; + begin + self.coverage_run_id := coalesce(coverage_run_id, sys_guid()); + self.file_mappings := file_mappings; + self.schema_names := schema_names; + self.exclude_objects := ut_object_names(); + + if exclude_objects is not empty then + self.exclude_objects := to_ut_object_list(exclude_objects, self.schema_names); + end if; +-- self.exclude_objects := self.exclude_objects multiset union all ut_suite_manager.get_schema_ut_packages(schema_names); + + self.include_objects := to_ut_object_list(include_objects, self.schema_names); + + return; + end; +end; +/ diff --git a/source/core/types/ut_coverage_options.tps b/source/core/types/ut_coverage_options.tps index bcdbc0b32..0de07b568 100644 --- a/source/core/types/ut_coverage_options.tps +++ b/source/core/types/ut_coverage_options.tps @@ -16,9 +16,18 @@ create or replace type ut_coverage_options force as object ( limitations under the License. */ + coverage_run_id raw(32), schema_names ut_varchar2_rows, exclude_objects ut_object_names, include_objects ut_object_names, - file_mappings ut_file_mappings + file_mappings ut_file_mappings, + constructor function ut_coverage_options( + self in out nocopy ut_coverage_options, + coverage_run_id raw := null, + schema_names ut_varchar2_rows := null, + exclude_objects ut_varchar2_rows := null, + include_objects ut_varchar2_rows := null, + file_mappings ut_file_mappings := null + ) return self as result ) / diff --git a/source/core/types/ut_run.tpb b/source/core/types/ut_run.tpb index bff16dc69..395b164f0 100644 --- a/source/core/types/ut_run.tpb +++ b/source/core/types/ut_run.tpb @@ -18,12 +18,9 @@ create or replace type body ut_run as constructor function ut_run( self in out nocopy ut_run, - a_items ut_suite_items, + a_items ut_suite_items := null, a_run_paths ut_varchar2_list := null, - a_schema_names ut_varchar2_rows := null, - a_exclude_objects ut_object_names := null, - a_include_objects ut_object_names := null, - a_project_file_mappings ut_file_mappings := null, + a_coverage_options ut_coverage_options := null, a_test_file_mappings ut_file_mappings := null, a_client_character_set varchar2 := null, a_random_test_order_seed positive := null, @@ -38,12 +35,7 @@ create or replace type body ut_run as self.random_test_order_seed := a_random_test_order_seed; self.results_count := ut_results_counter(); self.test_file_mappings := coalesce(a_test_file_mappings, ut_file_mappings()); - self.coverage_options := ut_coverage_options( - a_schema_names, - a_exclude_objects, - a_include_objects, - a_project_file_mappings - ); + self.coverage_options := a_coverage_options; return; end; diff --git a/source/core/types/ut_run.tps b/source/core/types/ut_run.tps index 2a4e11656..617347b25 100644 --- a/source/core/types/ut_run.tps +++ b/source/core/types/ut_run.tps @@ -28,12 +28,9 @@ create or replace type ut_run under ut_suite_item ( random_test_order_seed number(38,0), constructor function ut_run( self in out nocopy ut_run, - a_items ut_suite_items, + a_items ut_suite_items := null, a_run_paths ut_varchar2_list := null, - a_schema_names ut_varchar2_rows := null, - a_exclude_objects ut_object_names := null, - a_include_objects ut_object_names := null, - a_project_file_mappings ut_file_mappings := null, + a_coverage_options ut_coverage_options := null, a_test_file_mappings ut_file_mappings := null, a_client_character_set varchar2 := null, a_random_test_order_seed positive := null, diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 6bceb5261..c6a1b0657 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -229,6 +229,19 @@ create or replace package body ut_utils is return l_result; end; + function string_table_to_table(a_list ut_varchar2_list, a_delimiter varchar2:= chr(10), a_skip_leading_delimiter varchar2 := 'N') return ut_varchar2_list is + l_result ut_varchar2_list; + begin + if a_delimiter is null then + l_result := a_list; + elsif a_list is not empty then + for i in 1 .. a_list.count loop + ut_utils.append_to_list(l_result, ut_utils.string_to_table(a_list(i), a_delimiter, a_skip_leading_delimiter) ); + end loop; + end if; + return l_result; + end; + function clob_to_table(a_clob clob, a_max_amount integer := 8191, a_delimiter varchar2:= chr(10)) return ut_varchar2_list is l_offset integer := 1; l_length integer := dbms_lob.getlength(a_clob); @@ -369,6 +382,19 @@ create or replace package body ut_utils is end if; end; + procedure append_to_list(a_list in out nocopy ut_varchar2_list, a_items ut_varchar2_list) is + begin + if a_items is not null then + if a_list is null then + a_list := ut_varchar2_list(); + end if; + for i in 1 .. a_items.count loop + a_list.extend; + a_list(a_list.last) := a_items(i); + end loop; + end if; + end; + procedure append_to_list(a_list in out nocopy ut_varchar2_rows, a_item clob) is begin append_to_list( @@ -479,13 +505,6 @@ create or replace package body ut_utils is return l_xpath; end; - procedure cleanup_session_temp_tables is - begin - execute immediate 'truncate table dbmspcc_blocks'; - execute immediate 'truncate table dbmspcc_units'; - execute immediate 'truncate table dbmspcc_runs'; - end; - function to_version(a_version_no varchar2) return t_version is l_result t_version; c_version_part_regex constant varchar2(20) := '[0-9]+'; diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index ec8781391..8d3093108 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -216,8 +216,10 @@ create or replace package ut_utils authid definer is * * Splits a given string into table of string by delimiter. * The delimiter gets removed. - * If null passed as any of the parameters, empty table is returned. - * If no occurence of a_delimiter found in a_text then text is returned as a single row of the table. + * If null a_string passed, empty table is returned. + * If null a_delimiter passed, a_string is returned as element of result table. + * If null a_skip_leading_delimiter, it defaults to 'N' + * If no occurrence of a_delimiter found in a_text then text is returned as a single row of the table. * If no text between delimiters found then an empty row is returned, example: * string_to_table( 'a,,b', ',' ) gives table ut_varchar2_list( 'a', null, 'b' ); * @@ -229,14 +231,36 @@ create or replace package ut_utils authid definer is */ function string_to_table(a_string varchar2, a_delimiter varchar2:= chr(10), a_skip_leading_delimiter varchar2 := 'N') return ut_varchar2_list; + /** + * + * Splits each string in table of string into a table of string using specified delimiter. + * The delimiter gets removed. + * If null a_delimiter passed, a_list is returned as-is. + * If null a_list passed, empty table is returned. + * If null a_skip_leading_delimiter, it defaults to 'N' + * If no occurrence of a_delimiter found in a_text then text is returned as a single row of the table. + * If no text between delimiters found then an empty row is returned, example: + * string_table_to_table( a_list => ut_varchar2_list('x','y',null,'a,,b'), a_delimiter=>',' ) gives table ut_varchar2_list( 'x', 'y', null, 'a', null, 'b' ); + * + * @param a_list the table of texts to be split. + * @param a_delimiter the delimiter character or string + * @param a_skip_leading_delimiter determines if the leading delimiter should be ignored, used by clob_to_table + * + * @return table of varchar2 values + */ + function string_table_to_table(a_list ut_varchar2_list, a_delimiter varchar2:= chr(10), a_skip_leading_delimiter varchar2 := 'N') return ut_varchar2_list; + /** * Splits a given string into table of string by delimiter. * Default value of a_max_amount is 8191 because of code can contains multibyte character. * The delimiter gets removed. - * If null passed as any of the parameters, empty table is returned. + * If null a_clob passed, empty table is returned. + * If null a_delimiter passed, a_string is returned as element of result table. + * If null a_skip_leading_delimiter, it defaults to 'N' + * If no occurrence of a_delimiter found in a_text then text is returned as a single row of the table. * If split text is longer than a_max_amount it gets split into pieces of a_max_amount. * If no text between delimiters found then an empty row is returned, example: - * string_to_table( 'a,,b', ',' ) gives table ut_varchar2_list( 'a', null, 'b' ); + * clob_to_table( 'a,,b', ',' ) gives table ut_varchar2_list( 'a', null, 'b' ); * * @param a_clob the text to be split. * @param a_delimiter the delimiter character or string (default chr(10) ) @@ -287,6 +311,11 @@ create or replace package ut_utils authid definer is */ procedure append_to_list(a_list in out nocopy ut_varchar2_rows, a_items ut_varchar2_rows); + /** + * Append a list of items to the end of ut_varchar2_list + */ + procedure append_to_list(a_list in out nocopy ut_varchar2_list, a_items ut_varchar2_list); + procedure append_to_clob(a_src_clob in out nocopy clob, a_clob_table t_clob_tab, a_delimiter varchar2 := chr(10)); procedure append_to_clob(a_src_clob in out nocopy clob, a_new_data clob); @@ -299,12 +328,6 @@ create or replace package ut_utils authid definer is function to_xpath(a_list ut_varchar2_list, a_ancestors varchar2 := '/*/') return varchar2; - /* - * Truncates session-level GTT's (on commit preserve rows) - * IMPORTANT: Procedure will do an implicit commit when called - */ - procedure cleanup_session_temp_tables; - /** * Converts version string into version record * diff --git a/source/create_grants.sql b/source/create_grants.sql index 4553c52f6..db26faa24 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -61,6 +61,7 @@ grant execute on &&ut3_owner..ut_file_mapper to &ut3_user; grant execute on &&ut3_owner..ut_suite_items_info to &ut3_user; grant execute on &&ut3_owner..ut_suite_item_info to &ut3_user; grant execute on &&ut3_owner..ut_run_info to &ut3_user; +grant execute on &&ut3_owner..ut_coverage_options to &ut3_user; --generic types grant execute on &&ut3_owner..ut_varchar2_list to &ut3_user; @@ -133,6 +134,7 @@ grant execute on &&ut3_owner..ut_suite_cache_rows to &ut3_user; grant select, insert, delete, update on &&ut3_owner..dbmspcc_blocks to &ut3_user; grant select, insert, delete, update on &&ut3_owner..dbmspcc_runs to &ut3_user; grant select, insert, delete, update on &&ut3_owner..dbmspcc_units to &ut3_user; +grant select on &&ut3_owner..ut_coverage_runs to &ut3_user; grant execute on &&ut3_owner..ut_matcher_options to &ut3_user; grant execute on &&ut3_owner..ut_matcher_options_items to &ut3_user; diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index 425ca57a6..3f18ba3ed 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -77,6 +77,7 @@ create &action_type. synonym &ut3_user.ut_file_mapper for &&ut3_owner..ut_file_m create &action_type. synonym &ut3_user.ut_suite_items_info for &&ut3_owner..ut_suite_items_info; create &action_type. synonym &ut3_user.ut_suite_item_info for &&ut3_owner..ut_suite_item_info; create &action_type. synonym &ut3_user.ut_run_info for &&ut3_owner..ut_run_info; +create &action_type. synonym &ut3_user.ut_coverage_options for &&ut3_owner..ut_coverage_options; --generic types create &action_type. synonym &ut3_user.ut_varchar2_list for &&ut3_owner..ut_varchar2_list; diff --git a/source/install.sql b/source/install.sql index 253b13fb2..3249e3e49 100644 --- a/source/install.sql +++ b/source/install.sql @@ -177,6 +177,7 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema --gathering coverage @@install_component.sql 'core/coverage/ut_coverage_sources_tmp.sql' +@@install_component.sql 'core/coverage/ut_coverage_runs.sql' @@install_component.sql 'core/coverage/ut_coverage_helper.pks' @@install_component.sql 'core/coverage/ut_coverage_helper_block.pks' @@install_component.sql 'core/coverage/ut_coverage_helper_profiler.pks' @@ -199,6 +200,7 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'core/types/ut_logical_suite.tpb' @@install_component.sql 'core/types/ut_suite.tpb' @@install_component.sql 'core/types/ut_suite_context.tpb' +@@install_component.sql 'core/types/ut_coverage_options.tpb' @@install_component.sql 'core/types/ut_run.tpb' @@install_component.sql 'core/types/ut_expectation_result.tpb' @@install_component.sql 'core/types/ut_reporter_base.tpb' diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index eed8e8e73..2b34193ce 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -70,7 +70,7 @@ create or replace type body ut_coverage_cobertura_reporter is ) return ut_varchar2_rows is l_file_part varchar2(32767); l_result ut_varchar2_rows := ut_varchar2_rows(); - l_unit ut_coverage.t_full_name; + l_unit ut_coverage.t_object_name; l_obj_name ut_coverage.t_object_name; c_coverage_def constant varchar2(200) := ''; c_file_footer constant varchar2(30) := ''; diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index 00a53c4c6..d673a7f6c 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -287,7 +287,7 @@ create or replace package body ut_coverage_report_html_helper is l_coverage_pct number(5, 2); l_time_str varchar2(50); l_using varchar2(1000); - l_unit ut_coverage.t_full_name; + l_unit ut_coverage.t_object_name; l_charset varchar2(1000); begin l_charset := coalesce(upper(a_charset),'UTF-8'); diff --git a/source/reporters/ut_coverage_sonar_reporter.tpb b/source/reporters/ut_coverage_sonar_reporter.tpb index bfe0d890b..68f4a7989 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tpb +++ b/source/reporters/ut_coverage_sonar_reporter.tpb @@ -61,7 +61,7 @@ create or replace type body ut_coverage_sonar_reporter is a_run ut_run ) return ut_varchar2_rows is l_result ut_varchar2_rows := ut_varchar2_rows(); - l_unit ut_coverage.t_full_name; + l_unit ut_coverage.t_object_name; c_coverage_header constant varchar2(30) := ''; c_file_footer constant varchar2(30) := ''; c_coverage_footer constant varchar2(30) := '
'; diff --git a/source/reporters/ut_coveralls_reporter.tpb b/source/reporters/ut_coveralls_reporter.tpb index 1ca317c69..f2cb73abe 100644 --- a/source/reporters/ut_coveralls_reporter.tpb +++ b/source/reporters/ut_coveralls_reporter.tpb @@ -62,7 +62,7 @@ create or replace type body ut_coveralls_reporter is a_coverage_data ut_coverage.t_coverage ) return ut_varchar2_rows is l_result ut_varchar2_rows := ut_varchar2_rows(); - l_unit ut_coverage.t_full_name; + l_unit ut_coverage.t_object_name; c_coverage_header constant varchar2(30) := '{"source_files":['; c_coverage_footer constant varchar2(30) := ']}'||chr(10)||' '; begin diff --git a/source/uninstall_coverage_tables.sql b/source/uninstall_coverage_tables.sql index 8de75b51e..890aa7090 100644 --- a/source/uninstall_coverage_tables.sql +++ b/source/uninstall_coverage_tables.sql @@ -11,7 +11,7 @@ begin and owner = sys_context( 'USERENV', 'CURRENT_SCHEMA' ) ) loop - execute immediate 'drop table '||to_be_dopped.table_name||' cascade constraints'; + execute immediate 'drop table '||to_be_dopped.table_name||' cascade constraints purge'; dbms_output.put_line('Table '||to_be_dopped.table_name||' dropped'); end loop; end; diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index c905153f4..230e394ee 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -74,6 +74,8 @@ drop package ut_coverage_helper; drop table ut_coverage_sources_tmp purge; +drop table ut_coverage_runs purge; + drop package ut_teamcity_reporter_helper; drop package ut_runner; @@ -196,7 +198,7 @@ drop table ut_compound_data_tmp purge; drop table ut_compound_data_diff_tmp purge; -drop table ut_json_data_diff_tmp; +drop table ut_json_data_diff_tmp purge; drop package ut_annotation_manager; diff --git a/test/install_ut3_user_tests.sql b/test/install_ut3_user_tests.sql index 05f2634e8..336a63241 100644 --- a/test/install_ut3_user_tests.sql +++ b/test/install_ut3_user_tests.sql @@ -42,15 +42,16 @@ set define off @@ut3_user/reporters/test_debug_reporter.pks @@ut3_user/reporters/test_realtime_reporter.pks @@ut3_user/reporters/test_coverage.pks +@@ut3_user/reporters/test_coverage/test_coverage_standalone.pks set define on -@@install_above_12_1.sql 'ut3_user/reporters/test_extended_coverage.pks' +@@install_above_12_1.sql 'ut3_user/reporters/test_coverage/test_extended_coverage.pks' @@install_above_12_1.sql 'ut3_user/reporters/test_coverage/test_html_extended_reporter.pks' set define off @@ut3_user/reporters/test_coverage/test_coveralls_reporter.pks @@ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pks @@ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pks set define on -@@install_below_12_2.sql 'ut3_user/reporters/test_proftab_coverage.pks' +@@install_below_12_2.sql 'ut3_user/reporters/test_coverage/test_proftab_coverage.pks' @@install_below_12_2.sql 'ut3_user/reporters/test_coverage/test_html_proftab_reporter.pks' set define off @@ -83,15 +84,16 @@ set define off @@ut3_user/reporters/test_debug_reporter.pkb @@ut3_user/reporters/test_realtime_reporter.pkb @@ut3_user/reporters/test_coverage.pkb +@@ut3_user/reporters/test_coverage/test_coverage_standalone.pkb set define on -@@install_above_12_1.sql 'ut3_user/reporters/test_extended_coverage.pkb' +@@install_above_12_1.sql 'ut3_user/reporters/test_coverage/test_extended_coverage.pkb' @@install_above_12_1.sql 'ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb' set define off @@ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb @@ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb set define on -@@install_below_12_2.sql 'ut3_user/reporters/test_proftab_coverage.pkb' +@@install_below_12_2.sql 'ut3_user/reporters/test_coverage/test_proftab_coverage.pkb' @@install_below_12_2.sql 'ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb' set define off diff --git a/test/ut3_tester/core/test_output_buffer.pkb b/test/ut3_tester/core/test_output_buffer.pkb index a552cc567..2e8b3337c 100644 --- a/test/ut3_tester/core/test_output_buffer.pkb +++ b/test/ut3_tester/core/test_output_buffer.pkb @@ -132,7 +132,7 @@ create or replace package body test_output_buffer is --Assert -- Data in "fresh" buffer remains ut.expect( l_fresh_buffer.get_lines_cursor(0,0), l_buffer.self_type ).to_have_count(1); - -- Data in "slate" buffer is purged and so the call to get_lines_cursor throws ORA-20218 + -- Data in "stale" buffer is purged and so the call to get_lines_cursor throws ORA-20218 ut.expect( l_stale_buffer.get_lines_cursor(0,0), l_buffer.self_type ).to_be_empty(); end; diff --git a/test/ut3_tester/core/test_ut_executable.pkb b/test/ut3_tester/core/test_ut_executable.pkb index 337095607..e27a2e432 100644 --- a/test/ut3_tester/core/test_ut_executable.pkb +++ b/test/ut3_tester/core/test_ut_executable.pkb @@ -51,36 +51,6 @@ create or replace package body test_ut_executable is ut.expect(l_executable.get_error_stack_trace()).to_be_like('ORA-06501: PL/SQL: program error%'); end; - procedure modify_stateful_package is - l_job_name varchar2(30) := 'recreate_stateful_package'; - l_cnt integer := 1; - pragma autonomous_transaction; - begin - dbms_scheduler.create_job( - job_name => l_job_name, - job_type => 'PLSQL_BLOCK', - job_action => q'/ - begin - execute immediate q'[ - create or replace package stateful_package as - g_state varchar2(3) := 'abc'; - end;]'; - end;/', - start_date => localtimestamp, - enabled => TRUE, - auto_drop => TRUE, - comments => 'one-time job' - ); - $if dbms_db_version.version >= 18 $then - dbms_session.sleep(0.4); - $else - dbms_lock.sleep(0.4); - $end - while l_cnt > 0 loop - l_cnt:=ut3_tester_helper.main_helper.get_job_count(l_job_name); - end loop; - end; - procedure form_name is begin ut.expect(ut3_develop.ut_executable_test( user, ' package ', 'proc', null ).form_name()).to_equal(user||'.package.proc'); diff --git a/test/ut3_tester/core/test_ut_test.pks b/test/ut3_tester/core/test_ut_test.pks index 18ea6613f..caf75eb6c 100644 --- a/test/ut3_tester/core/test_ut_test.pks +++ b/test/ut3_tester/core/test_ut_test.pks @@ -29,7 +29,7 @@ create or replace package test_ut_test is --%test(Fails test when aftereach procedure name invalid) procedure after_each_proc_name_invalid; - --%test(Tails test when aftereach procedure name null) + --%test(Fails test when aftereach procedure name null) procedure after_each_procedure_name_null; procedure create_app_info_package; diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index e86a155fa..9aec00f8e 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -1,103 +1,87 @@ create or replace package body coverage_helper is - g_run_ids ut3_develop.ut_coverage.tt_coverage_id_arr; - g_profiler_run_id integer; - g_block_run_id integer; - - function get_mock_proftab_run_id return integer is - v_result integer; - begin - select nvl(min(runid),0) - 1 into v_result - from ut3_develop.plsql_profiler_runs; - return v_result; - end; - - function get_mock_block_run_id return integer is - v_result integer; - begin - select nvl(min(run_id),0) - 1 into v_result - from ut3_develop.dbmspcc_runs; - return v_result; - end; - - procedure setup_mock_coverage_ids(a_profiler_run_id integer, a_block_run_id integer) is - l_coverage_ids ut3_develop.ut_coverage.tt_coverage_id_arr; - begin - l_coverage_ids(ut3_develop.ut_coverage.gc_proftab_coverage) := a_profiler_run_id; - l_coverage_ids(ut3_develop.ut_coverage.gc_block_coverage) := a_block_run_id; - ut3_develop.ut_coverage.mock_coverage_id(l_coverage_ids); - end; + g_job_no integer := 0; procedure setup_mock_coverage_id is begin - g_profiler_run_id := get_mock_proftab_run_id(); - g_block_run_id := get_mock_block_run_id(); - setup_mock_coverage_ids(g_profiler_run_id, g_block_run_id); + null; end; - procedure setup_dummy_coverage is + procedure setup_long_name_package is pragma autonomous_transaction; begin - create_dummy_12_2_cov_pck(); - create_dummy_12_2_cov_test(); - grant_exec_on_12_2_cov(); + execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is + procedure do_stuff(i_input in number); - g_profiler_run_id := get_mock_proftab_run_id(); - g_block_run_id := get_mock_block_run_id(); - setup_mock_coverage_ids(g_profiler_run_id, g_block_run_id); + procedure grant_myself; + end;]'; + execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is + procedure do_stuff(i_input in number) is + begin + if i_input = 2 then dbms_output.put_line('should not get here'); else dbms_output.put_line('should get here'); end if; + end; - mock_block_coverage_data(g_block_run_id, user); - mock_profiler_coverage_data(g_profiler_run_id, user); - commit; - end; + procedure grant_myself is + begin + execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG to ut3$user#'; + end; - procedure mock_coverage_data(a_user in varchar2) is - c_unit_id constant integer := 1; - begin - insert into ut3_develop.plsql_profiler_runs ( runid, run_owner, run_date, run_comment) - values(g_profiler_run_id, a_user, sysdate, 'unit testing utPLSQL'); + end;]'; - insert into ut3_develop.plsql_profiler_units ( runid, unit_number, unit_type, unit_owner, unit_name) - values(g_profiler_run_id, c_unit_id, 'PACKAGE BODY', 'UT3_DEVELOP', 'DUMMY_COVERAGE'); + execute immediate q'[create or replace package UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is + --%suite(dummy coverage test) + --%suitepath(coverage_testing) - insert into ut3_develop.plsql_profiler_data ( runid, unit_number, line#, total_occur, total_time) - select g_profiler_run_id, c_unit_id, 4, 1, 1 from dual union all - select g_profiler_run_id, c_unit_id, 5, 0, 0 from dual union all - select g_profiler_run_id, c_unit_id, 7, 1, 1 from dual; - end; + --%test + procedure test_do_stuff; + + procedure grant_myself; + + end;]'; + execute immediate q'[create or replace package body UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is + procedure test_do_stuff is + begin + dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.do_stuff(1); + ut.expect(1).to_equal(1); + end; + + procedure grant_myself is + begin + execute immediate 'grant debug,execute on UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE to ut3$user#'; + end; + end;]'; + + + execute immediate 'begin UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG.grant_myself(); end;'; + execute immediate 'begin UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE.grant_myself(); end;'; - procedure cleanup_dummy_coverage(a_run_id in integer) is - pragma autonomous_transaction; - begin - delete from ut3_develop.plsql_profiler_data where runid = a_run_id; - delete from ut3_develop.plsql_profiler_units where runid = a_run_id; - delete from ut3_develop.plsql_profiler_runs where runid = a_run_id; commit; end; - procedure cleanup_dummy_coverage(a_block_id in integer, a_prof_id in integer) is - pragma autonomous_transaction; + procedure mock_coverage_data(a_user in varchar2) is begin - begin execute immediate q'[drop package ut3_develop.test_block_dummy_coverage]'; exception when others then null; end; - begin execute immediate q'[drop package ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long]'; exception when others then null; end; - delete from dbmspcc_blocks where run_id = a_block_id; - delete from dbmspcc_units where run_id = a_block_id; - delete from dbmspcc_runs where run_id = a_block_id; - cleanup_dummy_coverage(a_prof_id); - commit; + null; end; - procedure cleanup_dummy_coverage is + procedure cleanup_long_name_package is + pragma autonomous_transaction; begin - cleanup_dummy_coverage( - g_block_run_id, - g_profiler_run_id - ); + begin + execute immediate q'[drop package ut3_develop.test_block_dummy_coverage]'; + exception + when others then null; + end; + begin + execute immediate q'[drop package ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long]'; + exception + when others then null; + end; end; procedure create_dummy_coverage_package is pragma autonomous_transaction; begin + execute immediate 'alter session set plsql_optimize_level=0'; execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE is procedure do_stuff; @@ -116,6 +100,7 @@ create or replace package body coverage_helper is procedure grant_myself is begin execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE to ut3$user#'; + execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE to ut3_tester_helper'; end; end;]'; @@ -130,6 +115,9 @@ create or replace package body coverage_helper is --%test procedure test_do_stuff; + + --%test + procedure zero_coverage; procedure grant_myself; end;]'; @@ -138,7 +126,12 @@ create or replace package body coverage_helper is begin dummy_coverage.do_stuff; end; - + + procedure zero_coverage is + begin + null; + end; + procedure grant_myself is begin execute immediate 'grant debug,execute on UT3_DEVELOP.TEST_DUMMY_COVERAGE to ut3$user#'; @@ -213,62 +206,8 @@ create or replace package body coverage_helper is procedure drop_dummy_coverage_test_1 is pragma autonomous_transaction; begin - execute immediate q'[drop package UT3_DEVELOP.DUMMY_COVERAGE_1]'; - execute immediate q'[drop package UT3_DEVELOP.TEST_DUMMY_COVERAGE_1]'; - end; - - --12.2 Setup - procedure create_dummy_12_2_cov_pck is - pragma autonomous_transaction; - begin - execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is - procedure do_stuff(i_input in number); - - procedure grant_myself; - end;]'; - execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is - procedure do_stuff(i_input in number) is - begin - if i_input = 2 then - dbms_output.put_line('should not get here'); - else - dbms_output.put_line('should get here'); - end if; - end; - - procedure grant_myself is - begin - execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG to ut3$user#'; - end; - - end;]'; - end; - - procedure create_dummy_12_2_cov_test is - pragma autonomous_transaction; - begin - execute immediate q'[create or replace package UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is - --%suite(dummy coverage test) - --%suitepath(coverage_testing) - - --%test - procedure test_do_stuff; - - procedure grant_myself; - - end;]'; - execute immediate q'[create or replace package body UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is - procedure test_do_stuff is - begin - dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.do_stuff(1); - ut.expect(1).to_equal(1); - end; - - procedure grant_myself is - begin - execute immediate 'grant debug,execute on UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE to ut3$user#'; - end; - end;]'; + begin execute immediate q'[drop package UT3_DEVELOP.DUMMY_COVERAGE_1]'; exception when others then null; end; + begin execute immediate q'[drop package UT3_DEVELOP.TEST_DUMMY_COVERAGE_1]'; exception when others then null; end; end; procedure mock_block_coverage_data(a_run_id integer,a_user in varchar2) is @@ -303,17 +242,161 @@ create or replace package body coverage_helper is select a_run_id, c_unit_id, 7, 1, 1 from dual; end; - procedure grant_exec_on_12_2_cov is - pragma autonomous_transaction; - begin - execute immediate 'begin UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG.grant_myself(); end;'; - execute immediate 'begin UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE.grant_myself(); end;'; - end; procedure set_develop_mode is begin ut3_develop.ut_coverage.set_develop_mode(true); end; + procedure create_coverage_pkg is + pragma autonomous_transaction; + begin + execute immediate 'alter session set plsql_optimize_level=0'; + execute immediate q'[create or replace package coverage_pkg as + function run_some_branching_code(a_input integer) return integer; + end;]'; + execute immediate q'[create or replace package body coverage_pkg as + function run_some_branching_code(a_input integer) return integer is + l_result integer; + begin + if a_input = 1 then return -1; elsif a_input = 2 then return 0; + else + return a_input; + end if; + end; + end;]'; + execute immediate 'grant debug on coverage_pkg to ut3$user#'; + end; + + procedure drop_coverage_pkg is + pragma autonomous_transaction; + begin + execute immediate q'[drop package coverage_pkg]'; + end; + + procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer) is + x integer; + begin + ut3_develop.ut_runner.coverage_start(a_coverage_run_id); + execute immediate 'begin :x := coverage_pkg.run_some_branching_code(:a_input); end;' using out x, in a_input; + ut3_develop.ut_runner.coverage_stop(); + end; + + function get_job_status(a_job_name varchar2, a_job_started_after timestamp with time zone) return varchar2 is + l_status varchar2(1000); + begin + begin + select status into l_status + from user_scheduler_job_run_details + where job_name = upper(a_job_name) + and req_start_date >= a_job_started_after; + exception + when no_data_found then + null; + end; + return l_status; + end; + + procedure sleep(a_time number) is + begin + $if dbms_db_version.version >= 18 $then + dbms_session.sleep(a_time); + $else + dbms_lock.sleep(a_time ); + $end + end; + + procedure run_job_and_wait_for_finish(a_job_action varchar2) is + l_status varchar2(1000); + l_job_name varchar2(30); + l_timestamp timestamp with time zone := current_timestamp; + i integer := 0; + pragma autonomous_transaction; + begin + g_job_no := g_job_no + 1; + l_job_name := 'utPLSQL_selftest_job_'||g_job_no; + sleep(0.01); + dbms_scheduler.create_job( + job_name => l_job_name, + job_type => 'PLSQL_BLOCK', + job_action => a_job_action, + start_date => l_timestamp, + enabled => TRUE, + auto_drop => TRUE, + comments => 'one-time-job' + ); + while (l_status is null or l_status not in ('SUCCEEDED','FAILED')) and i < 30 loop + l_status := get_job_status( l_job_name, l_timestamp ); + sleep(0.1); + i := i + 1; + end loop; + commit; + if l_status = 'FAILED' then + raise_application_error(-20000, 'Running a scheduler job failed'); + end if; + end; + + procedure run_coverage_job(a_coverage_run_id raw, a_input integer) is + begin + run_job_and_wait_for_finish( + 'begin coverage_helper.run_standalone_coverage('''||a_coverage_run_id||''', '||a_input||'); end;' + ); + end; + + procedure create_test_results_table is + pragma autonomous_transaction; + e_exists exception; + pragma exception_init ( e_exists, -955 ); + begin + execute immediate 'create table test_results (text varchar2(4000))'; + exception + when e_exists then + null; + end; + + procedure drop_test_results_table is + pragma autonomous_transaction; + e_not_exists exception; + pragma exception_init ( e_not_exists, -942 ); + begin + execute immediate 'drop table test_results'; + exception + when e_not_exists then + null; + end; + + function run_code_as_job( a_plsql_block varchar2 ) return clob is + l_result_clob clob; + pragma autonomous_transaction; + begin + run_job_and_wait_for_finish( a_plsql_block ); + + execute immediate q'[ + declare + l_results ut3_develop.ut_varchar2_list; + begin + select * + bulk collect into l_results + from test_results; + delete from test_results; + commit; + :clob_results := ut3_tester_helper.main_helper.table_to_clob(l_results); + end; + ]' + using out l_result_clob; + + return l_result_clob; + end; + + function run_tests_as_job( a_run_command varchar2 ) return clob is + l_plsql_block varchar2(32767); + l_result_clob clob; + pragma autonomous_transaction; + begin + l_plsql_block := 'begin insert into test_results select * from table( {a_run_command} ); commit; end;'; + l_plsql_block := replace(l_plsql_block,'{a_run_command}',a_run_command); + return run_code_as_job( l_plsql_block ); + end; + end; / diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index c240ed490..7abeb5770 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -2,15 +2,13 @@ create or replace package coverage_helper is type prof_runs_tab is table of ut3_develop.plsql_profiler_runs%rowtype; - function get_mock_proftab_run_id return integer; - procedure setup_mock_coverage_id; procedure mock_coverage_data(a_user in varchar2); - procedure cleanup_dummy_coverage; + procedure cleanup_long_name_package; - procedure setup_dummy_coverage; + procedure setup_long_name_package; --Profiler coverage procedure create_dummy_coverage_package; @@ -23,12 +21,19 @@ create or replace package coverage_helper is procedure drop_dummy_coverage_test_1; --Block coverage - procedure create_dummy_12_2_cov_pck; - procedure create_dummy_12_2_cov_test; procedure mock_block_coverage_data(a_run_id integer,a_user in varchar2); - procedure grant_exec_on_12_2_cov; procedure set_develop_mode; - + + procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer); + procedure run_coverage_job(a_coverage_run_id raw, a_input integer); + procedure create_coverage_pkg; + procedure drop_coverage_pkg; + + function run_tests_as_job( a_run_command varchar2 ) return clob; + function run_code_as_job( a_plsql_block varchar2 ) return clob; + procedure create_test_results_table; + procedure drop_test_results_table; + end; / diff --git a/test/ut3_tester_helper/main_helper.pkb b/test/ut3_tester_helper/main_helper.pkb index 5c3032b75..76245ea12 100644 --- a/test/ut3_tester_helper/main_helper.pkb +++ b/test/ut3_tester_helper/main_helper.pkb @@ -126,14 +126,6 @@ create or replace package body main_helper is execute immediate 'begin ut3$user#.parse_annotations; end;'; end; - function get_job_count(a_job_name varchar2) return number is - l_cnt number; - begin - select count(1) into l_cnt - from dba_scheduler_running_jobs srj - where srj.job_name = a_job_name; - end; - procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_list, a_item varchar2) is begin ut3_develop.ut_utils.append_to_list(a_list,a_item); diff --git a/test/ut3_tester_helper/main_helper.pks b/test/ut3_tester_helper/main_helper.pks index e675e267e..6dd453446 100644 --- a/test/ut3_tester_helper/main_helper.pks +++ b/test/ut3_tester_helper/main_helper.pks @@ -1,7 +1,7 @@ create or replace package main_helper is - gc_success number := ut3_develop.ut_utils.gc_success; - gc_failure number := ut3_develop.ut_utils.gc_failure; + gc_success number := ut3_develop.ut_utils.gc_success; + gc_failure number := ut3_develop.ut_utils.gc_failure; procedure execute_autonomous(a_sql varchar2); @@ -35,8 +35,6 @@ create or replace package main_helper is procedure parse_dummy_test_as_ut3$user#; - function get_job_count(a_job_name varchar2) return number; - procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_list, a_item varchar2); procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_rows, a_item varchar2); diff --git a/test/ut3_user/reporters/test_coverage.pkb b/test/ut3_user/reporters/test_coverage.pkb index 738ce67e4..dcee1f8f8 100644 --- a/test/ut3_user/reporters/test_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage.pkb @@ -1,15 +1,11 @@ create or replace package body test_coverage is - procedure create_dummy_coverage_pkg is + procedure setup is + pragma autonomous_transaction; begin ut3_tester_helper.coverage_helper.create_dummy_coverage_package(); ut3_tester_helper.coverage_helper.create_dummy_coverage_test(); ut3_tester_helper.coverage_helper.grant_exec_on_cov(); - end; - - procedure setup_dummy_coverage is - pragma autonomous_transaction; - begin ut3_tester_helper.coverage_helper.setup_mock_coverage_id(); ut3_tester_helper.coverage_helper.mock_coverage_data(user); commit; diff --git a/test/ut3_user/reporters/test_coverage.pks b/test/ut3_user/reporters/test_coverage.pks index 4c19e125a..bc9379298 100644 --- a/test/ut3_user/reporters/test_coverage.pks +++ b/test/ut3_user/reporters/test_coverage.pks @@ -3,15 +3,20 @@ create or replace package test_coverage is --%suite --%suitepath(utplsql.test_user.reporters) + $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then + gc_block_coverage_enabled constant boolean := true; + $else + gc_block_coverage_enabled constant boolean := false; + $end + --%beforeall - procedure create_dummy_coverage_pkg; - --%beforeall - procedure setup_dummy_coverage; + procedure setup; + --%beforeall(ut3_tester_helper.coverage_helper.create_test_results_table) --%afterall(ut3_tester_helper.coverage_helper.drop_dummy_coverage_pkg) - - --%afterall(ut3_tester_helper.coverage_helper.cleanup_dummy_coverage) + --%afterall(ut3_tester_helper.coverage_helper.cleanup_long_name_package) + --%afterall(ut3_tester_helper.coverage_helper.drop_test_results_table) end; / diff --git a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb index 7ae4b6f0d..a0ee44219 100644 --- a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ -1,7 +1,6 @@ create or replace package body test_cov_cobertura_reporter is procedure report_on_file is - l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; begin @@ -9,7 +8,7 @@ create or replace package body test_cov_cobertura_reporter is l_expected := q'[ - + test/ut3_develop.dummy_coverage.pkb @@ -20,29 +19,30 @@ create or replace package body test_cov_cobertura_reporter is + +
]'; --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_cobertura_reporter( ), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), - a_test_files => ut3_develop.ut_varchar2_list( ) - ) - ); - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter => ut3_develop.ut_coverage_cobertura_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ) + ) + ]' + ); --Assert ut.expect(l_actual).to_be_like(l_expected); end; procedure report_zero_coverage is - l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; begin @@ -50,7 +50,7 @@ create or replace package body test_cov_cobertura_reporter is l_expected := q'[ - + ut3_develop.dummy_coverage @@ -73,28 +73,29 @@ create or replace package body test_cov_cobertura_reporter is +
]'; - ut3_tester_helper.coverage_helper.cleanup_dummy_coverage(); + ut3_tester_helper.coverage_helper.cleanup_long_name_package(); --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_cobertura_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.DUMMY_COVERAGE') - ) - ); - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + 'ut3_develop.test_dummy_coverage.zero_coverage', + ut3_develop.ut_coverage_cobertura_reporter(), + a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.DUMMY_COVERAGE') + ) + ]' + ); --Assert ut.expect(l_actual).to_be_like(l_expected); --Cleanup - test_coverage.setup_dummy_coverage; + test_coverage.setup; end; end; diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb index b0cb05a5b..e6c71563f 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb @@ -1,31 +1,38 @@ create or replace package body test_coverage_sonar_reporter is procedure report_on_file is - l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; + l_block_cov clob; begin --Arrange + if test_coverage.gc_block_coverage_enabled then + l_block_cov := ''; + else + l_block_cov := ''; + end if; l_expected := ' - +'||l_block_cov||' + + '; --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), - a_test_files => ut3_develop.ut_varchar2_list( ) - ) - ); - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ) + ) + ]' + ); --Assert ut.expect(l_actual).to_equal(l_expected); end; diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb new file mode 100644 index 000000000..1b508cc01 --- /dev/null +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -0,0 +1,36 @@ +create or replace package body test_coverage_standalone is + + procedure coverage_without_ut_run is + l_coverage_run_id raw(32) := sys_guid(); + l_actual ut3_develop.ut_varchar2_list; + l_expected clob; + begin + --Arrange + l_expected := '%ut3_tester_helper.coverage_pkg' || + '%' || + '%' || + '%%'; + --Act + ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 1); + ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 3); + + --Assert + select * + bulk collect into l_actual + from + table ( + ut3_develop.ut_coverage_cobertura_reporter( ).get_report( + ut3_develop.ut_coverage_options( + coverage_run_id => l_coverage_run_id, + include_objects => ut3_develop.ut_varchar2_rows('COVERAGE_PKG'), + schema_names => ut3_develop.ut_varchar2_rows('UT3_TESTER_HELPER') + ) + ) + ); + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_actual)).to_be_like( l_expected ); + end; + +end; +/ diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks new file mode 100644 index 000000000..662dedf66 --- /dev/null +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks @@ -0,0 +1,13 @@ +create or replace package test_coverage_standalone authid current_user is + + --%suite + --%suitepath(utplsql.test_user.reporters) + + --%beforeall(ut3_tester_helper.coverage_helper.create_coverage_pkg) + --%afterall(ut3_tester_helper.coverage_helper.drop_coverage_pkg) + + --%test(Coverage can be invoked standalone in multiple sessions and a combined report can be produced at the end) + procedure coverage_without_ut_run; + +end; +/ diff --git a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb index 73dde1b78..56290ea3d 100644 --- a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb @@ -1,7 +1,6 @@ create or replace package body test_coveralls_reporter is procedure report_on_file is - l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; begin @@ -15,32 +14,36 @@ null, 1, 0, null, -1 +1, +null, +null, +null, +null, +null, +0, +0 ] } ]} ]'; - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coveralls_reporter( ), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), - a_test_files => ut3_develop.ut_varchar2_list( ) - ) + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter => ut3_develop.ut_coveralls_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ) + ) + ]' ); - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); --Assert ut.expect(l_actual).to_equal(l_expected); end; procedure report_zero_coverage is - l_results ut3_develop.ut_varchar2_list; l_expected clob; l_actual clob; - pragma autonomous_transaction; begin --Arrange l_expected := q'[{"source_files":[ @@ -60,30 +63,27 @@ null, 0, 0, 0, +0, 0 ] } ]} ]'; - ut3_tester_helper.coverage_helper.cleanup_dummy_coverage(); - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - 'ut3_develop.test_dummy_coverage', - ut3_develop.ut_coveralls_reporter(), - a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.DUMMY_COVERAGE') - ) - ); - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + 'ut3_develop.test_dummy_coverage.zero_coverage', + ut3_develop.ut_coveralls_reporter(), + a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.DUMMY_COVERAGE') + ) + ]' + ); --Assert ut.expect(l_actual).to_equal(l_expected); - test_coverage.setup_dummy_coverage; - end; end; diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb new file mode 100644 index 000000000..8617b79ce --- /dev/null +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -0,0 +1,71 @@ +create or replace package body test_extended_coverage is + + procedure coverage_for_object is + l_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%%%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_block_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long' ) + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + end; + + procedure coverage_for_schema is + l_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%%%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_block_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_coverage_schemes => ut3_develop.ut_varchar2_list( 'ut3_develop' ) + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).to_be_like('%%%'); + end; + + procedure coverage_for_file is + l_expected clob; + l_actual clob; + l_file_path varchar2(250); + begin + --Arrange + l_file_path := 'test/ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb'; + l_expected := '%%%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_block_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( ']'||l_file_path||q'[' ), + a_test_files => ut3_develop.ut_varchar2_list( ) + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + end; + +end; +/ diff --git a/test/ut3_user/reporters/test_extended_coverage.pks b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks similarity index 66% rename from test/ut3_user/reporters/test_extended_coverage.pks rename to test/ut3_user/reporters/test_coverage/test_extended_coverage.pks index a8460aa3a..b2abb7c6d 100644 --- a/test/ut3_user/reporters/test_extended_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks @@ -1,11 +1,11 @@ create or replace package test_extended_coverage is --%suite - --%suitepath(utplsql.test_user.reporters) + --%suitepath(utplsql.test_user.reporters.test_coverage) - --%beforeall(ut3_tester_helper.coverage_helper.setup_dummy_coverage) + --%beforeall(ut3_tester_helper.coverage_helper.setup_long_name_package) + --%afterall(ut3_tester_helper.coverage_helper.cleanup_long_name_package) - --%afterall(ut3_tester_helper.coverage_helper.cleanup_dummy_coverage) --%test(Coverage is gathered for specified object - extended coverage type) procedure coverage_for_object; diff --git a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb index 8c6ae9e02..f54c8bda3 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb @@ -7,20 +7,23 @@ create or replace package body test_html_extended_reporter is l_charset varchar2(100) := 'ISO-8859-1'; begin --Arrange - l_expected := '%%

UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG

%4 relevant lines. 3 lines covered (including 1 lines partially covered ) and 1 lines missed%'; - - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_block_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_html_reporter(), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb' ), - a_test_files => ut3_develop.ut_varchar2_list( ), - a_client_character_set => l_charset - ) - ); - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + l_expected := '%%

UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_' || + 'LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG

' || + '%2 relevant lines. 1 lines covered ' || + '(including 1 lines partially covered ) and 1 lines missed%'; + + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_block_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_html_reporter(), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ), + a_client_character_set => ']'||l_charset||q'[' + ) + ]' + ); --Assert ut.expect(l_actual).to_be_like(l_expected); end; diff --git a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pks b/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pks index dbe31b83d..3158b3777 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pks +++ b/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pks @@ -1,7 +1,7 @@ create or replace package test_html_extended_reporter is --%suite(ut_html_extended_reporter) - --%suitepath(utplsql.test_user.reporters.test_extended_coverage) + --%suitepath(utplsql.test_user.reporters.test_coverage.test_extended_coverage) --%test(reports on a project file mapped to database object in extended profiler coverage) procedure report_on_file; diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb new file mode 100644 index 000000000..e55d0abec --- /dev/null +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -0,0 +1,133 @@ +create or replace package body test_proftab_coverage is + + procedure coverage_for_object is + l_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + end; + + procedure coverage_for_object_no_owner is + l_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'dummy_coverage' ) + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + end; + + procedure coverage_for_schema is + l_expected clob; + l_actual clob; + begin + --Arrange + l_expected := ''; + l_expected := '%'||l_expected||'%'||l_expected||'%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_coverage_schemes => ut3_develop.ut_varchar2_list( 'ut3_develop' ) + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + end; + + procedure coverage_for_file is + l_expected clob; + l_actual clob; + l_file_path varchar2(100); + begin + --Arrange + l_file_path := 'test/ut3_develop.dummy_coverage.pkb'; + l_expected := '%%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( ']'||l_file_path||q'[' ), + a_test_files => ut3_develop.ut_varchar2_list( ) + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + end; + + procedure coverage_tmp_data_refresh is + l_actual clob; + l_test_code varchar2(32767); + begin + l_test_code := q'[ + declare + l_tmp_data ut3_develop.ut_varchar2_list; + begin + --Arrange + select * bulk collect into l_tmp_data + from table( + ut3_develop.ut.run( + a_path => 'ut3_develop:coverage_testing', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) + ) + ); + coverage_helper.drop_dummy_coverage_pkg(); + coverage_helper.create_dummy_coverage_test_1(); + + --Act + insert into test_results + select * + from table( + ut3_develop.ut.run( + a_path => 'ut3_develop:coverage_testing', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) + ) + ); + commit; + end; + ]'; + + l_actual := ut3_tester_helper.coverage_helper.run_code_as_job( l_test_code ); + --Assert + ut.expect(l_actual).to_equal(to_clob(' + +')); + end; + +end; +/ diff --git a/test/ut3_user/reporters/test_proftab_coverage.pks b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks similarity index 85% rename from test/ut3_user/reporters/test_proftab_coverage.pks rename to test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks index 6f2548158..8c9ecd5f8 100644 --- a/test/ut3_user/reporters/test_proftab_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks @@ -16,8 +16,7 @@ create or replace package test_proftab_coverage is procedure coverage_for_file; --%test(Coverage data is not cached between runs - issue #562 ) - --%aftertest(ut3$user#.test_coverage.create_dummy_coverage_pkg) - --%aftertest(ut3$user#.test_coverage.setup_dummy_coverage) + --%aftertest(ut3$user#.test_coverage.setup) --%aftertest(ut3_tester_helper.coverage_helper.drop_dummy_coverage_test_1) procedure coverage_tmp_data_refresh; diff --git a/test/ut3_user/reporters/test_extended_coverage.pkb b/test/ut3_user/reporters/test_extended_coverage.pkb deleted file mode 100644 index 28742aa70..000000000 --- a/test/ut3_user/reporters/test_extended_coverage.pkb +++ /dev/null @@ -1,74 +0,0 @@ -create or replace package body test_extended_coverage is - - procedure coverage_for_object is - l_expected clob; - l_actual clob; - l_results ut3_develop.ut_varchar2_list; - begin - --Arrange - l_expected := '%%%'; - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_block_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long' ) - ) - ); - --Assert - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); - ut.expect(l_actual).to_be_like(l_expected); - end; - - procedure coverage_for_schema is - l_expected clob; - l_actual clob; - l_results ut3_develop.ut_varchar2_list; - begin - --Arrange - l_expected := '%%%'; - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_block_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_coverage_schemes => ut3_develop.ut_varchar2_list( 'ut3_develop' ) - ) - ); - --Assert - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); - ut.expect(l_actual).to_be_like(l_expected); - ut.expect(l_actual).to_be_like('%%%'); - end; - - procedure coverage_for_file is - l_expected clob; - l_actual clob; - l_results ut3_develop.ut_varchar2_list; - l_file_path varchar2(250); - begin - --Arrange - l_file_path := lower('test/ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb'); - l_expected := '%%%'; - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_block_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_source_files => ut3_develop.ut_varchar2_list( l_file_path ), - a_test_files => ut3_develop.ut_varchar2_list( ) - ) - ); - --Assert - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); - ut.expect(l_actual).to_be_like(l_expected); - end; - -end; -/ diff --git a/test/ut3_user/reporters/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_proftab_coverage.pkb deleted file mode 100644 index c132517a7..000000000 --- a/test/ut3_user/reporters/test_proftab_coverage.pkb +++ /dev/null @@ -1,132 +0,0 @@ -create or replace package body test_proftab_coverage is - - procedure coverage_for_object is - l_expected clob; - l_actual clob; - l_results ut3_develop.ut_varchar2_list; - begin - --Arrange - l_expected := '%%'; - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) - ) - ); - --Assert - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); - ut.expect(l_actual).to_be_like(l_expected); - end; - - procedure coverage_for_object_no_owner is - l_expected clob; - l_actual clob; - l_results ut3_develop.ut_varchar2_list; - begin - --Arrange - l_expected := '%%'; - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'dummy_coverage' ) - ) - ); - --Assert - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); - ut.expect(l_actual).to_be_like(l_expected); - end; - - procedure coverage_for_schema is - l_expected clob; - l_actual clob; - l_results ut3_develop.ut_varchar2_list; - begin - --Arrange - l_expected := ''; - l_expected := '%'||l_expected||'%'||l_expected||'%'; - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_coverage_schemes => ut3_develop.ut_varchar2_list( 'ut3_develop' ) - ) - ); - --Assert - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); - ut.expect(l_actual).to_be_like(l_expected); - end; - - procedure coverage_for_file is - l_expected clob; - l_actual clob; - l_results ut3_develop.ut_varchar2_list; - l_file_path varchar2(100); - begin - --Arrange - l_file_path := lower('test/ut3_develop.dummy_coverage.pkb'); - l_expected := '%%'; - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_source_files => ut3_develop.ut_varchar2_list( l_file_path ), - a_test_files => ut3_develop.ut_varchar2_list( ) - ) - ); - --Assert - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); - ut.expect(l_actual).to_be_like(l_expected); - end; - - procedure coverage_tmp_data_refresh is - l_actual clob; - l_results ut3_develop.ut_varchar2_list; - begin - --Arrange - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop:coverage_testing', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) - ) - ); - ut3_tester_helper.coverage_helper.cleanup_dummy_coverage(); - ut3_tester_helper.coverage_helper.drop_dummy_coverage_pkg(); - ut3_tester_helper.coverage_helper.create_dummy_coverage_test_1(); - - --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop:coverage_testing', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) - ) - ); - - --Assert - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); - ut.expect(l_actual).to_equal(to_clob(' - -')); - end; - -end; -/ From a23f7be2161626c0055f7a370a061d42a2715461 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Wed, 10 Jun 2020 23:30:50 +0000 Subject: [PATCH 086/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index aca93a957..2d0bce9da 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 4fcdda511..23fc28fc7 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 884fc6c07..0e8334ea1 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 63f8e851d..b7ae9d169 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index e0cf1b0c9..22387ed5a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7ed3dce21..202ddbbad 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index cf72be22d..65a9ac0fe 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0fbcb4851..576fe89b6 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 3b968ccc4..0f001a5a8 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 3487ffac6..72e5c476a 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 2a1044454..a9a29e213 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index bc9894cee..0de315b4a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 385db7257..f3ab786e8 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 66b52496f..6ea157369 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 24dabecf8..ac03362a5 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 7bbbe2df1..a3d8b0cb0 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index af711ae4f..3c7565323 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 6bceb5261..7779c3dfe 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3392-develop + * secion v3.1.11.3400-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index ec8781391..c109a6c26 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3392-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3400-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 641d87c1cb40c260f4a7d2c2b6e6ef457ecb75ab Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 13 Jun 2020 22:14:51 +0100 Subject: [PATCH 087/887] Removed mocking API for coverage, Fixed failing tests for 11.2 and 12.1 Refactored some parts of tests --- source/core/coverage/ut_coverage.pkb | 14 -- source/core/coverage/ut_coverage.pks | 8 -- test/ut3_tester_helper/coverage_helper.pkb | 121 ++---------------- test/ut3_tester_helper/coverage_helper.pks | 21 +-- test/ut3_tester_helper/run_helper.pks | 1 - test/ut3_user/reporters/test_coverage.pkb | 11 -- test/ut3_user/reporters/test_coverage.pks | 8 +- .../test_cov_cobertura_reporter.pkb | 16 +-- .../test_coverage_sonar_reporter.pkb | 2 - .../test_coverage_standalone.pkb | 16 ++- .../test_coverage/test_coveralls_reporter.pkb | 15 +-- .../test_coverage/test_extended_coverage.pks | 4 +- .../test_html_extended_reporter.pkb | 5 +- .../test_html_proftab_reporter.pkb | 25 ++-- .../test_coverage/test_proftab_coverage.pkb | 2 +- .../test_coverage/test_proftab_coverage.pks | 2 +- 16 files changed, 49 insertions(+), 222 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 879b6f5b5..a05fa554a 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -16,7 +16,6 @@ create or replace package body ut_coverage is limitations under the License. */ - g_coverage_run_id raw(32); g_develop_mode boolean not null := false; g_is_started boolean not null := false; @@ -197,16 +196,6 @@ create or replace package body ut_coverage is ut_coverage_helper_profiler.coverage_resume(); end; - procedure mock_coverage_id( - a_coverage_run_id t_coverage_run_id, a_line_coverage_id integer, a_block_coverage_id integer - ) is - begin - g_develop_mode := true; - g_is_started := true; - g_coverage_run_id := a_coverage_run_id; - ut_coverage_helper.set_coverage_run_ids(a_coverage_run_id, a_line_coverage_id, a_block_coverage_id); - end; - procedure coverage_stop is begin if not is_develop_mode() then @@ -224,9 +213,6 @@ create or replace package body ut_coverage is l_line_no binary_integer; l_coverage_options ut_coverage_options := a_coverage_options; begin - if is_develop_mode() then - l_coverage_options.coverage_run_id := coalesce(g_coverage_run_id, l_coverage_options.coverage_run_id); - end if; --prepare global temp table with sources ut_event_manager.trigger_event('about to populate coverage temp table'); populate_tmp_table(l_coverage_options); diff --git a/source/core/coverage/ut_coverage.pks b/source/core/coverage/ut_coverage.pks index 5e960c5ea..ba5263dd2 100644 --- a/source/core/coverage/ut_coverage.pks +++ b/source/core/coverage/ut_coverage.pks @@ -64,14 +64,6 @@ create or replace package ut_coverage authid current_user is function is_develop_mode return boolean; - /*** - * Allows overwriting of private global variable g_coverage_id - * Used internally, only for unit testing of the framework only - */ - procedure mock_coverage_id( - a_coverage_run_id t_coverage_run_id, a_line_coverage_id integer, a_block_coverage_id integer - ); - procedure coverage_start(a_coverage_run_id t_coverage_run_id); procedure coverage_stop; diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 9aec00f8e..20a041321 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -2,30 +2,17 @@ create or replace package body coverage_helper is g_job_no integer := 0; - procedure setup_mock_coverage_id is - begin - null; - end; - - procedure setup_long_name_package is + procedure create_long_name_package is pragma autonomous_transaction; begin execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is procedure do_stuff(i_input in number); - - procedure grant_myself; end;]'; execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is procedure do_stuff(i_input in number) is begin if i_input = 2 then dbms_output.put_line('should not get here'); else dbms_output.put_line('should get here'); end if; end; - - procedure grant_myself is - begin - execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG to ut3$user#'; - end; - end;]'; execute immediate q'[create or replace package UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is @@ -34,9 +21,6 @@ create or replace package body coverage_helper is --%test procedure test_do_stuff; - - procedure grant_myself; - end;]'; execute immediate q'[create or replace package body UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is procedure test_do_stuff is @@ -44,26 +28,11 @@ create or replace package body coverage_helper is dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.do_stuff(1); ut.expect(1).to_equal(1); end; - - procedure grant_myself is - begin - execute immediate 'grant debug,execute on UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE to ut3$user#'; - end; end;]'; - - execute immediate 'begin UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG.grant_myself(); end;'; - execute immediate 'begin UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE.grant_myself(); end;'; - - commit; - end; - - procedure mock_coverage_data(a_user in varchar2) is - begin - null; end; - procedure cleanup_long_name_package is + procedure drop_long_name_package is pragma autonomous_transaction; begin begin @@ -78,14 +47,15 @@ create or replace package body coverage_helper is end; end; - procedure create_dummy_coverage_package is + + + + procedure create_dummy_coverage is pragma autonomous_transaction; begin execute immediate 'alter session set plsql_optimize_level=0'; execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE is procedure do_stuff; - - procedure grant_myself; end;]'; execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE is procedure do_stuff is @@ -96,19 +66,7 @@ create or replace package body coverage_helper is dbms_output.put_line('should get here'); end if; end; - - procedure grant_myself is - begin - execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE to ut3$user#'; - execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE to ut3_tester_helper'; - end; end;]'; - - end; - - procedure create_dummy_coverage_test is - pragma autonomous_transaction; - begin execute immediate q'[create or replace package UT3_DEVELOP.TEST_DUMMY_COVERAGE is --%suite(dummy coverage test) --%suitepath(coverage_testing) @@ -118,8 +76,6 @@ create or replace package body coverage_helper is --%test procedure zero_coverage; - - procedure grant_myself; end;]'; execute immediate q'[create or replace package body UT3_DEVELOP.TEST_DUMMY_COVERAGE is procedure test_do_stuff is @@ -131,23 +87,11 @@ create or replace package body coverage_helper is begin null; end; - - procedure grant_myself is - begin - execute immediate 'grant debug,execute on UT3_DEVELOP.TEST_DUMMY_COVERAGE to ut3$user#'; - end; end;]'; end; - - procedure grant_exec_on_cov is - pragma autonomous_transaction; - begin - execute immediate 'begin UT3_DEVELOP.DUMMY_COVERAGE.grant_myself(); end;'; - execute immediate 'begin UT3_DEVELOP.TEST_DUMMY_COVERAGE.grant_myself(); end;'; - end; - - procedure drop_dummy_coverage_pkg is + + procedure drop_dummy_coverage is pragma autonomous_transaction; begin begin execute immediate q'[drop package ut3_develop.test_dummy_coverage]'; exception when others then null; end; @@ -160,7 +104,6 @@ create or replace package body coverage_helper is begin execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE_1 is procedure do_stuff; - procedure grant_myself; end;]'; execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE_1 is procedure do_stuff is @@ -171,12 +114,6 @@ create or replace package body coverage_helper is dbms_output.put_line('should get here'); end if; end; - - procedure grant_myself is - begin - execute immediate 'grant debug,execute on UT3_DEVELOP.DUMMY_COVERAGE_1 to ut3$user#'; - end; - end;]'; execute immediate q'[create or replace package UT3_DEVELOP.TEST_DUMMY_COVERAGE_1 is --%suite(dummy coverage test 1) @@ -184,8 +121,6 @@ create or replace package body coverage_helper is --%test procedure test_do_stuff; - - procedure grant_myself; end;]'; execute immediate q'[create or replace package body UT3_DEVELOP.TEST_DUMMY_COVERAGE_1 is procedure test_do_stuff is @@ -193,14 +128,7 @@ create or replace package body coverage_helper is dummy_coverage_1.do_stuff; end; - procedure grant_myself is - begin - execute immediate 'grant debug,execute on UT3_DEVELOP.TEST_DUMMY_COVERAGE_1 to ut3$user#'; - end; - end;]'; - execute immediate 'begin UT3_DEVELOP.DUMMY_COVERAGE_1.grant_myself(); end;'; - execute immediate 'begin UT3_DEVELOP.TEST_DUMMY_COVERAGE_1.grant_myself(); end;'; end; procedure drop_dummy_coverage_test_1 is @@ -210,39 +138,6 @@ create or replace package body coverage_helper is begin execute immediate q'[drop package UT3_DEVELOP.TEST_DUMMY_COVERAGE_1]'; exception when others then null; end; end; - procedure mock_block_coverage_data(a_run_id integer,a_user in varchar2) is - c_unit_id constant integer := 1; - begin - insert into dbmspcc_runs ( run_id, run_owner, run_timestamp, run_comment) - values(a_run_id, a_user, sysdate, 'unit testing utPLSQL'); - - insert into dbmspcc_units ( run_id, object_id, type, owner, name,last_ddl_time) - values(a_run_id, c_unit_id, 'PACKAGE BODY', 'UT3_DEVELOP', 'DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG',sysdate); - - insert into dbmspcc_blocks ( run_id, object_id, line,block,col,covered,not_feasible) - select a_run_id, c_unit_id,4,1,1,1,0 from dual union all - select a_run_id, c_unit_id,4,2,2,0,0 from dual union all - select a_run_id, c_unit_id,5,3,0,1,0 from dual union all - select a_run_id, c_unit_id,7,4,1,1,0 from dual; - end; - - procedure mock_profiler_coverage_data(a_run_id integer,a_user in varchar2) is - c_unit_id constant integer := 1; - begin - insert into ut3_develop.plsql_profiler_runs ( runid, run_owner, run_date, run_comment) - values(a_run_id, a_user, sysdate, 'unit testing utPLSQL'); - - insert into ut3_develop.plsql_profiler_units ( runid, unit_number, unit_type, unit_owner, unit_name) - values(a_run_id, c_unit_id, 'PACKAGE BODY', 'UT3_DEVELOP', 'DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG'); - - insert into ut3_develop.plsql_profiler_data ( runid, unit_number, line#, total_occur, total_time) - select a_run_id, c_unit_id, 4, 1, 1 from dual union all - select a_run_id, c_unit_id, 5, 0, 0 from dual union all - select a_run_id, c_unit_id, 6, 1, 0 from dual union all - select a_run_id, c_unit_id, 7, 1, 1 from dual; - end; - - procedure set_develop_mode is begin ut3_develop.ut_coverage.set_develop_mode(true); diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index 7abeb5770..124b1e24e 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -1,28 +1,15 @@ create or replace package coverage_helper is - type prof_runs_tab is table of ut3_develop.plsql_profiler_runs%rowtype; - - procedure setup_mock_coverage_id; - - procedure mock_coverage_data(a_user in varchar2); - - procedure cleanup_long_name_package; - - procedure setup_long_name_package; + procedure create_long_name_package; + procedure drop_long_name_package; --Profiler coverage - procedure create_dummy_coverage_package; - procedure create_dummy_coverage_test; - procedure grant_exec_on_cov; - procedure mock_profiler_coverage_data(a_run_id integer,a_user in varchar2); - procedure drop_dummy_coverage_pkg; + procedure create_dummy_coverage; + procedure drop_dummy_coverage; procedure create_dummy_coverage_test_1; procedure drop_dummy_coverage_test_1; - --Block coverage - procedure mock_block_coverage_data(a_run_id integer,a_user in varchar2); - procedure set_develop_mode; procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer); diff --git a/test/ut3_tester_helper/run_helper.pks b/test/ut3_tester_helper/run_helper.pks index 88f55d961..0657c1a51 100644 --- a/test/ut3_tester_helper/run_helper.pks +++ b/test/ut3_tester_helper/run_helper.pks @@ -3,7 +3,6 @@ create or replace package run_helper is g_run_id integer; type t_out_buff_tab is table of ut3_develop.ut_output_buffer_tmp%rowtype; - type prof_runs_tab is table of ut3_develop.plsql_profiler_runs%rowtype; procedure setup_cache_objects; procedure setup_cache_objectstag; diff --git a/test/ut3_user/reporters/test_coverage.pkb b/test/ut3_user/reporters/test_coverage.pkb index dcee1f8f8..6a7536370 100644 --- a/test/ut3_user/reporters/test_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage.pkb @@ -1,15 +1,4 @@ create or replace package body test_coverage is - procedure setup is - pragma autonomous_transaction; - begin - ut3_tester_helper.coverage_helper.create_dummy_coverage_package(); - ut3_tester_helper.coverage_helper.create_dummy_coverage_test(); - ut3_tester_helper.coverage_helper.grant_exec_on_cov(); - ut3_tester_helper.coverage_helper.setup_mock_coverage_id(); - ut3_tester_helper.coverage_helper.mock_coverage_data(user); - commit; - end; - end; / diff --git a/test/ut3_user/reporters/test_coverage.pks b/test/ut3_user/reporters/test_coverage.pks index bc9379298..ea906ff62 100644 --- a/test/ut3_user/reporters/test_coverage.pks +++ b/test/ut3_user/reporters/test_coverage.pks @@ -9,13 +9,11 @@ create or replace package test_coverage is gc_block_coverage_enabled constant boolean := false; $end - --%beforeall - procedure setup; - --%beforeall(ut3_tester_helper.coverage_helper.create_test_results_table) + --%beforeall(ut3_tester_helper.coverage_helper.create_dummy_coverage) + - --%afterall(ut3_tester_helper.coverage_helper.drop_dummy_coverage_pkg) - --%afterall(ut3_tester_helper.coverage_helper.cleanup_long_name_package) + --%afterall(ut3_tester_helper.coverage_helper.drop_dummy_coverage) --%afterall(ut3_tester_helper.coverage_helper.drop_test_results_table) end; diff --git a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb index a0ee44219..c8a97bb71 100644 --- a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ -8,7 +8,7 @@ create or replace package body test_cov_cobertura_reporter is l_expected := q'[ - + test/ut3_develop.dummy_coverage.pkb @@ -19,8 +19,6 @@ create or replace package body test_cov_cobertura_reporter is - -
@@ -50,7 +48,7 @@ create or replace package body test_cov_cobertura_reporter is l_expected := q'[ - + ut3_develop.dummy_coverage @@ -68,19 +66,13 @@ create or replace package body test_cov_cobertura_reporter is - - - - - - ]'; - ut3_tester_helper.coverage_helper.cleanup_long_name_package(); + ut3_tester_helper.coverage_helper.drop_long_name_package(); --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( @@ -95,7 +87,7 @@ create or replace package body test_cov_cobertura_reporter is --Assert ut.expect(l_actual).to_be_like(l_expected); --Cleanup - test_coverage.setup; + ut3_tester_helper.coverage_helper.create_dummy_coverage; end; end; diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb index e6c71563f..935c7d10b 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb @@ -17,8 +17,6 @@ create or replace package body test_coverage_sonar_reporter is '||l_block_cov||' - - '; --Act diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index 1b508cc01..b72ec9217 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -4,14 +4,20 @@ create or replace package body test_coverage_standalone is l_coverage_run_id raw(32) := sys_guid(); l_actual ut3_develop.ut_varchar2_list; l_expected clob; + l_block_cov clob; begin --Arrange + if test_coverage.gc_block_coverage_enabled then + l_block_cov := '%'; + else + l_block_cov := '%'; + end if; l_expected := '%ut3_tester_helper.coverage_pkg' || - '%' || - '%' || - '%%'; + '%' || + l_block_cov || + '%%'; --Act ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 1); ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 3); diff --git a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb index 56290ea3d..1baf88a61 100644 --- a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb @@ -14,14 +14,7 @@ null, 1, 0, null, -1, -null, -null, -null, -null, -null, -0, -0 +1 ] } ]} @@ -58,12 +51,6 @@ null, 0, 0, 0, -0, -0, -0, -0, -0, -0, 0 ] } diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks index b2abb7c6d..bbc644100 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks @@ -3,8 +3,8 @@ create or replace package test_extended_coverage is --%suite --%suitepath(utplsql.test_user.reporters.test_coverage) - --%beforeall(ut3_tester_helper.coverage_helper.setup_long_name_package) - --%afterall(ut3_tester_helper.coverage_helper.cleanup_long_name_package) + --%beforeall(ut3_tester_helper.coverage_helper.create_long_name_package) + --%afterall(ut3_tester_helper.coverage_helper.drop_long_name_package) --%test(Coverage is gathered for specified object - extended coverage type) diff --git a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb index f54c8bda3..b7b8722e4 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb @@ -1,7 +1,6 @@ create or replace package body test_html_extended_reporter is procedure report_on_file is - l_results ut3_develop.ut_varchar2_list; l_expected varchar2(32767); l_actual clob; l_charset varchar2(100) := 'ISO-8859-1'; @@ -9,8 +8,8 @@ create or replace package body test_html_extended_reporter is --Arrange l_expected := '%%

UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_' || 'LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG

' || - '%2 relevant lines. 1 lines covered ' || - '(including 1 lines partially covered ) and 1 lines missed%'; + '%1 relevant lines. 1 lines covered ' || + '(including 1 lines partially covered ) and 0 lines missed%'; l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( diff --git a/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb index 9f3fb90e5..2102137ee 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb @@ -1,7 +1,6 @@ create or replace package body test_html_proftab_reporter is procedure report_on_file is - l_results ut3_develop.ut_varchar2_list; l_expected varchar2(32767); l_actual clob; l_charset varchar2(100) := 'ISO-8859-1'; @@ -9,18 +8,18 @@ create or replace package body test_html_proftab_reporter is --Arrange l_expected := '%%

UT3_DEVELOP.DUMMY_COVERAGE

%3 relevant lines. 2 lines covered and 1 lines missed%'; --Act - select * - bulk collect into l_results - from table( - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_html_reporter(), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), - a_test_files => ut3_develop.ut_varchar2_list( ), - a_client_character_set => l_charset - ) - ); - l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_html_reporter(), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_test_files => ut3_develop.ut_varchar2_list( ), + a_client_character_set => ']'||l_charset||q'[' + ) + ]' + ); --Assert ut.expect(l_actual).to_be_like(l_expected); end; diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index e55d0abec..a707c33d2 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -105,7 +105,7 @@ create or replace package body test_proftab_coverage is a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) ) ); - coverage_helper.drop_dummy_coverage_pkg(); + coverage_helper.drop_dummy_coverage(); coverage_helper.create_dummy_coverage_test_1(); --Act diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks index 8c9ecd5f8..3bfec567c 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks @@ -16,7 +16,7 @@ create or replace package test_proftab_coverage is procedure coverage_for_file; --%test(Coverage data is not cached between runs - issue #562 ) - --%aftertest(ut3$user#.test_coverage.setup) + --%aftertest(ut3_tester_helper.coverage_helper.create_dummy_coverage) --%aftertest(ut3_tester_helper.coverage_helper.drop_dummy_coverage_test_1) procedure coverage_tmp_data_refresh; From 52e1db9cbc94632f51f9d5f723a812f94847c31d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 14 Jun 2020 01:06:11 +0100 Subject: [PATCH 088/887] Workaround for 12.2 issue with conditional compilation in package spec. Added missing testcase for get_report_cursor --- test/ut3_user/reporters/test_coverage.pkb | 9 +++++ test/ut3_user/reporters/test_coverage.pks | 6 +-- .../test_coverage_sonar_reporter.pkb | 2 +- .../test_coverage_standalone.pkb | 39 ++++++++++++++++++- .../test_coverage_standalone.pks | 2 + 5 files changed, 51 insertions(+), 7 deletions(-) diff --git a/test/ut3_user/reporters/test_coverage.pkb b/test/ut3_user/reporters/test_coverage.pkb index 6a7536370..aa1acde77 100644 --- a/test/ut3_user/reporters/test_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage.pkb @@ -1,4 +1,13 @@ create or replace package body test_coverage is + function block_coverage_available return boolean is + begin + $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then + return true; + $else + return false; + $end + end; + end; / diff --git a/test/ut3_user/reporters/test_coverage.pks b/test/ut3_user/reporters/test_coverage.pks index ea906ff62..06eec3690 100644 --- a/test/ut3_user/reporters/test_coverage.pks +++ b/test/ut3_user/reporters/test_coverage.pks @@ -3,11 +3,7 @@ create or replace package test_coverage is --%suite --%suitepath(utplsql.test_user.reporters) - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - gc_block_coverage_enabled constant boolean := true; - $else - gc_block_coverage_enabled constant boolean := false; - $end + function block_coverage_available return boolean; --%beforeall(ut3_tester_helper.coverage_helper.create_test_results_table) --%beforeall(ut3_tester_helper.coverage_helper.create_dummy_coverage) diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb index 935c7d10b..477ad2ade 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb @@ -6,7 +6,7 @@ create or replace package body test_coverage_sonar_reporter is l_block_cov clob; begin --Arrange - if test_coverage.gc_block_coverage_enabled then + if test_coverage.block_coverage_available then l_block_cov := ''; else l_block_cov := ''; diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index b72ec9217..9aa0060ff 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -7,7 +7,7 @@ create or replace package body test_coverage_standalone is l_block_cov clob; begin --Arrange - if test_coverage.gc_block_coverage_enabled then + if test_coverage.block_coverage_available then l_block_cov := '%'; else l_block_cov := '%'; @@ -38,5 +38,42 @@ create or replace package body test_coverage_standalone is ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_actual)).to_be_like( l_expected ); end; + procedure coverage_cursor_without_ut_run is + l_coverage_run_id raw(32) := sys_guid(); + l_coverage_cursor sys_refcursor; + l_actual ut3_develop.ut_varchar2_list; + l_expected clob; + l_block_cov clob; + begin + --Arrange + if test_coverage.block_coverage_available then + l_block_cov := '%'; + else + l_block_cov := '%'; + end if; + l_expected := '%ut3_tester_helper.coverage_pkg' || + '%' || + l_block_cov || + '%%'; + --Act + ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 1); + ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 3); + + --Assert + l_coverage_cursor := + ut3_develop.ut_coverage_cobertura_reporter( ).get_report_cursor( + ut3_develop.ut_coverage_options( + coverage_run_id => l_coverage_run_id, + include_objects => ut3_develop.ut_varchar2_rows('COVERAGE_PKG'), + schema_names => ut3_develop.ut_varchar2_rows('UT3_TESTER_HELPER') + ) + ); + fetch l_coverage_cursor bulk collect into l_actual; + close l_coverage_cursor; + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_actual)).to_be_like( l_expected ); + end; + end; / diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks index 662dedf66..69aae3f25 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks @@ -9,5 +9,7 @@ create or replace package test_coverage_standalone authid current_user is --%test(Coverage can be invoked standalone in multiple sessions and a combined report can be produced at the end) procedure coverage_without_ut_run; + --%test(Coverage can be invoked standalone in multiple sessions and a combined report can be produced at the end as cursor) + procedure coverage_cursor_without_ut_run; end; / From a17c3aff4b45d085869c80cacd3d9437c3ac001f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 14 Jun 2020 01:43:23 +0100 Subject: [PATCH 089/887] cleanup of unneeded safety code --- source/api/ut.pkb | 36 ------------------------------------ 1 file changed, 36 deletions(-) diff --git a/source/api/ut.pkb b/source/api/ut.pkb index 72e868a9d..3b94a2bf7 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -248,12 +248,6 @@ create or replace package body ut is end loop; end if; return; - exception - when no_data_needed then - if l_results%isopen then - close l_results; - end if; - raise; end; function run( @@ -293,12 +287,6 @@ create or replace package body ut is end loop; end if; return; - exception - when no_data_needed then - if l_results%isopen then - close l_results; - end if; - raise; end; function run( @@ -339,12 +327,6 @@ create or replace package body ut is end loop; end if; return; - exception - when no_data_needed then - if l_results%isopen then - close l_results; - end if; - raise; end; function run( @@ -385,12 +367,6 @@ create or replace package body ut is end loop; end if; return; - exception - when no_data_needed then - if l_results%isopen then - close l_results; - end if; - raise; end; function run( @@ -431,12 +407,6 @@ create or replace package body ut is end loop; end if; return; - exception - when no_data_needed then - if l_results%isopen then - close l_results; - end if; - raise; end; function run( @@ -477,12 +447,6 @@ create or replace package body ut is end loop; end if; return; - exception - when no_data_needed then - if l_results%isopen then - close l_results; - end if; - raise; end; procedure run( From 09ab22632f7e83df3cb9e24b1a780b332ff0eac1 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 14 Jun 2020 03:47:14 +0100 Subject: [PATCH 090/887] Refactoring tests --- test/install_ut3_tester_helper.sql | 1 + test/install_ut3_user_tests.sql | 15 +-- test/ut3_tester_helper/coverage_helper.pkb | 119 ++++++++---------- test/ut3_tester_helper/coverage_helper.pks | 20 +-- test/ut3_user/reporters/test_coverage.pkb | 13 -- test/ut3_user/reporters/test_coverage.pks | 2 - .../test_cov_cobertura_reporter.pkb | 79 +++--------- .../test_cov_cobertura_reporter.pks | 3 - .../test_coverage_sonar_reporter.pkb | 13 +- .../test_coverage_standalone.pkb | 4 +- .../test_coverage/test_coveralls_reporter.pkb | 16 +-- .../test_coverage/test_extended_coverage.pkb | 32 +++-- .../test_coverage/test_extended_coverage.pks | 4 - ...er.pkb => test_html_coverage_reporter.pkb} | 18 ++- ...er.pks => test_html_coverage_reporter.pks} | 4 +- .../test_html_extended_reporter.pkb | 31 ----- .../test_html_proftab_reporter.pks | 10 -- .../test_coverage/test_proftab_coverage.pkb | 96 ++++++++++---- .../test_coverage/test_proftab_coverage.pks | 5 +- 19 files changed, 225 insertions(+), 260 deletions(-) delete mode 100644 test/ut3_user/reporters/test_coverage.pkb rename test/ut3_user/reporters/test_coverage/{test_html_proftab_reporter.pkb => test_html_coverage_reporter.pkb} (54%) rename test/ut3_user/reporters/test_coverage/{test_html_extended_reporter.pks => test_html_coverage_reporter.pks} (73%) delete mode 100644 test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb delete mode 100644 test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pks diff --git a/test/install_ut3_tester_helper.sql b/test/install_ut3_tester_helper.sql index c0c20634e..9841252a0 100644 --- a/test/install_ut3_tester_helper.sql +++ b/test/install_ut3_tester_helper.sql @@ -29,6 +29,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester_helper/annotation_cache_helper.pks @@ut3_tester_helper/annotation_cache_helper.pkb create or replace synonym ut3_tester.annotation_cache_helper for ut3_tester_helper.annotation_cache_helper; +create or replace synonym ut3$user#.coverage_helper for ut3_tester_helper.coverage_helper; set linesize 200 set define on diff --git a/test/install_ut3_user_tests.sql b/test/install_ut3_user_tests.sql index 336a63241..e790293c8 100644 --- a/test/install_ut3_user_tests.sql +++ b/test/install_ut3_user_tests.sql @@ -44,15 +44,14 @@ set define off @@ut3_user/reporters/test_coverage.pks @@ut3_user/reporters/test_coverage/test_coverage_standalone.pks set define on -@@install_above_12_1.sql 'ut3_user/reporters/test_coverage/test_extended_coverage.pks' -@@install_above_12_1.sql 'ut3_user/reporters/test_coverage/test_html_extended_reporter.pks' +@@ut3_user/reporters/test_coverage/test_extended_coverage.pks +@@ut3_user/reporters/test_coverage/test_html_coverage_reporter.pks set define off @@ut3_user/reporters/test_coverage/test_coveralls_reporter.pks @@ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pks @@ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pks set define on -@@install_below_12_2.sql 'ut3_user/reporters/test_coverage/test_proftab_coverage.pks' -@@install_below_12_2.sql 'ut3_user/reporters/test_coverage/test_html_proftab_reporter.pks' +@@ut3_user/reporters/test_coverage/test_proftab_coverage.pks set define off @@ut3_user/test_user.pkb @@ -83,18 +82,16 @@ set define off @@ut3_user/reporters/test_documentation_reporter.pkb @@ut3_user/reporters/test_debug_reporter.pkb @@ut3_user/reporters/test_realtime_reporter.pkb -@@ut3_user/reporters/test_coverage.pkb @@ut3_user/reporters/test_coverage/test_coverage_standalone.pkb set define on -@@install_above_12_1.sql 'ut3_user/reporters/test_coverage/test_extended_coverage.pkb' -@@install_above_12_1.sql 'ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb' +@@ut3_user/reporters/test_coverage/test_extended_coverage.pkb +@@ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb set define off @@ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb @@ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb set define on -@@install_below_12_2.sql 'ut3_user/reporters/test_coverage/test_proftab_coverage.pkb' -@@install_below_12_2.sql 'ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb' +@@ut3_user/reporters/test_coverage/test_proftab_coverage.pkb set define off diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 20a041321..67bef571a 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -2,72 +2,56 @@ create or replace package body coverage_helper is g_job_no integer := 0; - procedure create_long_name_package is - pragma autonomous_transaction; + function block_coverage_available return boolean is begin - execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is - procedure do_stuff(i_input in number); - end;]'; - execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG is - procedure do_stuff(i_input in number) is - begin - if i_input = 2 then dbms_output.put_line('should not get here'); else dbms_output.put_line('should get here'); end if; - end; - end;]'; - - execute immediate q'[create or replace package UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is - --%suite(dummy coverage test) - --%suitepath(coverage_testing) - - --%test - procedure test_do_stuff; - end;]'; - execute immediate q'[create or replace package body UT3_DEVELOP.TEST_BLOCK_DUMMY_COVERAGE is - procedure test_do_stuff is - begin - dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.do_stuff(1); - ut.expect(1).to_equal(1); - end; - end;]'; - + $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then + return true; + $else + return false; + $end end; - procedure drop_long_name_package is - pragma autonomous_transaction; + function covered_package_name return varchar2 is begin - begin - execute immediate q'[drop package ut3_develop.test_block_dummy_coverage]'; - exception - when others then null; - end; - begin - execute immediate q'[drop package ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long]'; - exception - when others then null; - end; + $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then + return 'dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long'; + $else + return 'dummy_coverage'; + $end end; + function substitute_covered_package( + a_text varchar2, + a_substitution varchar2 + ) return varchar2 is + begin + return replace( replace( a_text, a_substitution, covered_package_name() ), upper(a_substitution), upper(covered_package_name()) ); + end; + procedure set_develop_mode is + begin + ut3_develop.ut_coverage.set_develop_mode(true); + end; procedure create_dummy_coverage is pragma autonomous_transaction; begin - execute immediate 'alter session set plsql_optimize_level=0'; - execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE is - procedure do_stuff; + execute immediate q'[create or replace package ut3_develop.]'||covered_package_name||q'[ is + procedure do_stuff(i_input in number); end;]'; - execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE is - procedure do_stuff is + + execute immediate q'[create or replace package body ut3_develop.]'||covered_package_name||q'[ is + procedure do_stuff(i_input in number) is begin - if 1 = 2 then - dbms_output.put_line('should not get here'); + if i_input = 2 then dbms_output.put_line('should not get here'); elsif i_input = 1 then dbms_output.put_line('should get here'); else - dbms_output.put_line('should get here'); + dbms_output.put_line('should not get here'); end if; end; end;]'; - execute immediate q'[create or replace package UT3_DEVELOP.TEST_DUMMY_COVERAGE is + + execute immediate q'[create or replace package ut3_develop.test_dummy_coverage is --%suite(dummy coverage test) --%suitepath(coverage_testing) @@ -77,35 +61,37 @@ create or replace package body coverage_helper is --%test procedure zero_coverage; end;]'; - execute immediate q'[create or replace package body UT3_DEVELOP.TEST_DUMMY_COVERAGE is + + execute immediate q'[create or replace package body ut3_develop.test_dummy_coverage is procedure test_do_stuff is begin - dummy_coverage.do_stuff; + ]'||covered_package_name||q'[.do_stuff(1); + ut.expect(1).to_equal(1); end; - procedure zero_coverage is begin null; end; end;]'; - + end; procedure drop_dummy_coverage is pragma autonomous_transaction; begin - begin execute immediate q'[drop package ut3_develop.test_dummy_coverage]'; exception when others then null; end; - begin execute immediate q'[drop package ut3_develop.dummy_coverage]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.test_dummy_coverage]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.]'||covered_package_name; exception when others then null; end; end; - procedure create_dummy_coverage_test_1 is + procedure create_dummy_coverage_1 is pragma autonomous_transaction; begin - execute immediate q'[create or replace package UT3_DEVELOP.DUMMY_COVERAGE_1 is + execute immediate q'[create or replace package ut3_develop.dummy_coverage_1 is procedure do_stuff; end;]'; - execute immediate q'[create or replace package body UT3_DEVELOP.DUMMY_COVERAGE_1 is + + execute immediate q'[create or replace package body ut3_develop.dummy_coverage_1 is procedure do_stuff is begin if 1 = 2 then @@ -115,14 +101,16 @@ create or replace package body coverage_helper is end if; end; end;]'; - execute immediate q'[create or replace package UT3_DEVELOP.TEST_DUMMY_COVERAGE_1 is + + execute immediate q'[create or replace package ut3_develop.test_dummy_coverage_1 is --%suite(dummy coverage test 1) --%suitepath(coverage_testing) --%test procedure test_do_stuff; end;]'; - execute immediate q'[create or replace package body UT3_DEVELOP.TEST_DUMMY_COVERAGE_1 is + + execute immediate q'[create or replace package body ut3_develop.test_dummy_coverage_1 is procedure test_do_stuff is begin dummy_coverage_1.do_stuff; @@ -131,16 +119,11 @@ create or replace package body coverage_helper is end;]'; end; - procedure drop_dummy_coverage_test_1 is + procedure drop_dummy_coverage_1 is pragma autonomous_transaction; begin - begin execute immediate q'[drop package UT3_DEVELOP.DUMMY_COVERAGE_1]'; exception when others then null; end; - begin execute immediate q'[drop package UT3_DEVELOP.TEST_DUMMY_COVERAGE_1]'; exception when others then null; end; - end; - - procedure set_develop_mode is - begin - ut3_develop.ut_coverage.set_develop_mode(true); + begin execute immediate q'[drop package ut3_develop.dummy_coverage_1]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.test_dummy_coverage_1]'; exception when others then null; end; end; procedure create_coverage_pkg is @@ -169,6 +152,8 @@ create or replace package body coverage_helper is execute immediate q'[drop package coverage_pkg]'; end; + + procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer) is x integer; begin diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index 124b1e24e..470b1971d 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -1,19 +1,25 @@ create or replace package coverage_helper is - procedure create_long_name_package; - procedure drop_long_name_package; + function block_coverage_available return boolean; - --Profiler coverage - procedure create_dummy_coverage; - procedure drop_dummy_coverage; + function covered_package_name return varchar2; - procedure create_dummy_coverage_test_1; - procedure drop_dummy_coverage_test_1; + function substitute_covered_package( + a_text varchar2, + a_substitution varchar2 := '{p}' + ) return varchar2; procedure set_develop_mode; + procedure create_dummy_coverage; + procedure drop_dummy_coverage; + + procedure create_dummy_coverage_1; + procedure drop_dummy_coverage_1; + procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer); procedure run_coverage_job(a_coverage_run_id raw, a_input integer); + procedure create_coverage_pkg; procedure drop_coverage_pkg; diff --git a/test/ut3_user/reporters/test_coverage.pkb b/test/ut3_user/reporters/test_coverage.pkb deleted file mode 100644 index aa1acde77..000000000 --- a/test/ut3_user/reporters/test_coverage.pkb +++ /dev/null @@ -1,13 +0,0 @@ -create or replace package body test_coverage is - - function block_coverage_available return boolean is - begin - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - return true; - $else - return false; - $end - end; - -end; -/ diff --git a/test/ut3_user/reporters/test_coverage.pks b/test/ut3_user/reporters/test_coverage.pks index 06eec3690..11bc6d480 100644 --- a/test/ut3_user/reporters/test_coverage.pks +++ b/test/ut3_user/reporters/test_coverage.pks @@ -3,8 +3,6 @@ create or replace package test_coverage is --%suite --%suitepath(utplsql.test_user.reporters) - function block_coverage_available return boolean; - --%beforeall(ut3_tester_helper.coverage_helper.create_test_results_table) --%beforeall(ut3_tester_helper.coverage_helper.create_dummy_coverage) diff --git a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb index c8a97bb71..098405ff9 100644 --- a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ -3,91 +3,52 @@ create or replace package body test_cov_cobertura_reporter is procedure report_on_file is l_expected clob; l_actual clob; + l_block_cov clob; + l_name varchar2(250); + l_file_path varchar2(250); begin - --Arrange - l_expected := - q'[ - - - -test/ut3_develop.dummy_coverage.pkb - - - - - - - - - - - - -]'; - --Act - l_actual := - ut3_tester_helper.coverage_helper.run_tests_as_job( - q'[ - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter => ut3_develop.ut_coverage_cobertura_reporter( ), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), - a_test_files => ut3_develop.ut_varchar2_list( ) - ) - ]' - ); - --Assert - ut.expect(l_actual).to_be_like(l_expected); - end; - procedure report_zero_coverage is - l_expected clob; - l_actual clob; - begin + --Arrange + l_name := ut3_tester_helper.coverage_helper.covered_package_name; + l_file_path := 'test/ut3_develop.'||ut3_tester_helper.coverage_helper.covered_package_name||'.pkb'; + if ut3_tester_helper.coverage_helper.block_coverage_available then + l_block_cov := ''; + else + l_block_cov := ''; + end if; l_expected := q'[ - + -ut3_develop.dummy_coverage +]'||l_file_path||q'[ - - + + - - - - - +]'||l_block_cov||q'[ - - - - ]'; - - ut3_tester_helper.coverage_helper.drop_long_name_package(); --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( q'[ ut3_develop.ut.run( - 'ut3_develop.test_dummy_coverage.zero_coverage', - ut3_develop.ut_coverage_cobertura_reporter(), - a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.DUMMY_COVERAGE') + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter => ut3_develop.ut_coverage_cobertura_reporter( ), + a_source_files => ut3_develop.ut_varchar2_list( ']'||l_file_path||q'[' ), + a_test_files => ut3_develop.ut_varchar2_list( ) ) ]' ); --Assert ut.expect(l_actual).to_be_like(l_expected); - --Cleanup - ut3_tester_helper.coverage_helper.create_dummy_coverage; end; end; diff --git a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pks b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pks index 0016641d5..365815964 100644 --- a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pks +++ b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pks @@ -6,8 +6,5 @@ create or replace package test_cov_cobertura_reporter is --%test(reports on a project file mapped to database object) procedure report_on_file; - --%test(reports zero coverage on each line of non-executed database object - Issue #917) - procedure report_zero_coverage; - end test_cov_cobertura_reporter; / diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb index 477ad2ade..50d7bfe4c 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb @@ -6,17 +6,16 @@ create or replace package body test_coverage_sonar_reporter is l_block_cov clob; begin --Arrange - if test_coverage.block_coverage_available then - l_block_cov := ''; + if ut3_tester_helper.coverage_helper.block_coverage_available then + l_block_cov := ''; else - l_block_cov := ''; + l_block_cov := ''; end if; l_expected := ' - - - + '||l_block_cov||' + '; --Act @@ -26,7 +25,7 @@ create or replace package body test_coverage_sonar_reporter is ut3_develop.ut.run( a_path => 'ut3_develop.test_dummy_coverage', a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.]'||ut3_tester_helper.coverage_helper.covered_package_name||q'[.pkb' ), a_test_files => ut3_develop.ut_varchar2_list( ) ) ]' diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index 9aa0060ff..8816d4895 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -7,7 +7,7 @@ create or replace package body test_coverage_standalone is l_block_cov clob; begin --Arrange - if test_coverage.block_coverage_available then + if ut3_tester_helper.coverage_helper.block_coverage_available then l_block_cov := '%'; else l_block_cov := '%'; @@ -46,7 +46,7 @@ create or replace package body test_coverage_standalone is l_block_cov clob; begin --Arrange - if test_coverage.block_coverage_available then + if ut3_tester_helper.coverage_helper.block_coverage_available then l_block_cov := '%'; else l_block_cov := '%'; diff --git a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb index 1baf88a61..48a62f7f6 100644 --- a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb @@ -3,18 +3,19 @@ create or replace package body test_coveralls_reporter is procedure report_on_file is l_expected clob; l_actual clob; + l_file_path varchar2(250); begin --Arrange + l_file_path := 'test/ut3_develop.'||ut3_tester_helper.coverage_helper.covered_package_name||'.pkb'; l_expected := q'[{"source_files":[ -{ "name": "test/ut3_develop.dummy_coverage.pkb", +{ "name": "]'||l_file_path||q'[", "coverage": [ null, null, null, -1, -0, +3, null, -1 +0 ] } ]} @@ -25,7 +26,7 @@ null, ut3_develop.ut.run( a_path => 'ut3_develop.test_dummy_coverage', a_reporter => ut3_develop.ut_coveralls_reporter( ), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_source_files => ut3_develop.ut_varchar2_list( ']'||l_file_path||q'[' ), a_test_files => ut3_develop.ut_varchar2_list( ) ) ]' @@ -40,7 +41,7 @@ null, begin --Arrange l_expected := q'[{"source_files":[ -{ "name": "ut3_develop.dummy_coverage", +{ "name": "ut3_develop.]'||ut3_tester_helper.coverage_helper.covered_package_name||q'[", "coverage": [ 0, 0, @@ -50,7 +51,6 @@ null, 0, 0, 0, -0, 0 ] } @@ -64,7 +64,7 @@ null, ut3_develop.ut.run( 'ut3_develop.test_dummy_coverage.zero_coverage', ut3_develop.ut_coveralls_reporter(), - a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.DUMMY_COVERAGE') + a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.]'||ut3_tester_helper.coverage_helper.covered_package_name||q'[') ) ]' ); diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index 8617b79ce..4b995b7c8 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -1,19 +1,31 @@ create or replace package body test_extended_coverage is + function get_block_coverage_line return clob is + begin + return + case + when ut3_tester_helper.coverage_helper.block_coverage_available then + '%' + else + '%' + end; + end; procedure coverage_for_object is l_expected clob; l_actual clob; begin --Arrange - l_expected := '%%%'; + l_expected := '%' || + get_block_coverage_line|| + '%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( q'[ ut3_develop.ut.run( - a_path => 'ut3_develop.test_block_dummy_coverage', + a_path => 'ut3_develop.test_dummy_coverage', a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long' ) + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.]'||ut3_tester_helper.coverage_helper.covered_package_name||q'[' ) ) ]' ); @@ -26,13 +38,15 @@ create or replace package body test_extended_coverage is l_actual clob; begin --Arrange - l_expected := '%%%'; + l_expected := '%' || + get_block_coverage_line || + '%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( q'[ ut3_develop.ut.run( - a_path => 'ut3_develop.test_block_dummy_coverage', + a_path => 'ut3_develop.test_dummy_coverage', a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), a_coverage_schemes => ut3_develop.ut_varchar2_list( 'ut3_develop' ) ) @@ -49,14 +63,16 @@ create or replace package body test_extended_coverage is l_file_path varchar2(250); begin --Arrange - l_file_path := 'test/ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb'; - l_expected := '%%%'; + l_file_path := 'test/ut3_develop.'||ut3_tester_helper.coverage_helper.covered_package_name||'.pkb'; + l_expected := '%' || + get_block_coverage_line || + '%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( q'[ ut3_develop.ut.run( - a_path => 'ut3_develop.test_block_dummy_coverage', + a_path => 'ut3_develop.test_dummy_coverage', a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), a_source_files => ut3_develop.ut_varchar2_list( ']'||l_file_path||q'[' ), a_test_files => ut3_develop.ut_varchar2_list( ) diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks index bbc644100..600a87e16 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks @@ -3,10 +3,6 @@ create or replace package test_extended_coverage is --%suite --%suitepath(utplsql.test_user.reporters.test_coverage) - --%beforeall(ut3_tester_helper.coverage_helper.create_long_name_package) - --%afterall(ut3_tester_helper.coverage_helper.drop_long_name_package) - - --%test(Coverage is gathered for specified object - extended coverage type) procedure coverage_for_object; diff --git a/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb similarity index 54% rename from test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb rename to test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb index 2102137ee..d1645acae 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb @@ -1,20 +1,28 @@ -create or replace package body test_html_proftab_reporter is +create or replace package body test_html_coverage_reporter is procedure report_on_file is l_expected varchar2(32767); l_actual clob; + l_block_cov clob; + l_name varchar2(250); l_charset varchar2(100) := 'ISO-8859-1'; begin --Arrange - l_expected := '%%

UT3_DEVELOP.DUMMY_COVERAGE

%3 relevant lines. 2 lines covered and 1 lines missed%'; - --Act + l_name := ut3_tester_helper.coverage_helper.covered_package_name; + if ut3_tester_helper.coverage_helper.block_coverage_available then + l_block_cov := '(including 1 lines partially covered ) '; + end if; + l_expected := '%%

UT3_DEVELOP.'||upper(l_name)||'

' || + '%2 relevant lines. 1 lines covered ' || + l_block_cov || 'and 1 lines missed%'; + l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( q'[ ut3_develop.ut.run( a_path => 'ut3_develop.test_dummy_coverage', a_reporter=> ut3_develop.ut_coverage_html_reporter(), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage.pkb' ), + a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.]'||l_name||q'[.pkb' ), a_test_files => ut3_develop.ut_varchar2_list( ), a_client_character_set => ']'||l_charset||q'[' ) @@ -24,5 +32,5 @@ create or replace package body test_html_proftab_reporter is ut.expect(l_actual).to_be_like(l_expected); end; -end test_html_proftab_reporter; +end test_html_coverage_reporter; / diff --git a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pks b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pks similarity index 73% rename from test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pks rename to test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pks index 3158b3777..629d41793 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pks +++ b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pks @@ -1,4 +1,4 @@ -create or replace package test_html_extended_reporter is +create or replace package test_html_coverage_reporter is --%suite(ut_html_extended_reporter) --%suitepath(utplsql.test_user.reporters.test_coverage.test_extended_coverage) @@ -6,5 +6,5 @@ create or replace package test_html_extended_reporter is --%test(reports on a project file mapped to database object in extended profiler coverage) procedure report_on_file; -end test_html_extended_reporter; +end test_html_coverage_reporter; / diff --git a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb deleted file mode 100644 index b7b8722e4..000000000 --- a/test/ut3_user/reporters/test_coverage/test_html_extended_reporter.pkb +++ /dev/null @@ -1,31 +0,0 @@ -create or replace package body test_html_extended_reporter is - - procedure report_on_file is - l_expected varchar2(32767); - l_actual clob; - l_charset varchar2(100) := 'ISO-8859-1'; - begin - --Arrange - l_expected := '%%

UT3_DEVELOP.DUMMY_COVERAGE_PACKAGE_WITH_AN_AMAZINGLY_' || - 'LONG_NAME_THAT_YOU_WOULD_NOT_THINK_OF_IN_REAL_LIFE_PROJECT_BECAUSE_ITS_SIMPLY_TOO_LONG

' || - '%1 relevant lines. 1 lines covered ' || - '(including 1 lines partially covered ) and 0 lines missed%'; - - l_actual := - ut3_tester_helper.coverage_helper.run_tests_as_job( - q'[ - ut3_develop.ut.run( - a_path => 'ut3_develop.test_block_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_html_reporter(), - a_source_files => ut3_develop.ut_varchar2_list( 'test/ut3_develop.dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long.pkb' ), - a_test_files => ut3_develop.ut_varchar2_list( ), - a_client_character_set => ']'||l_charset||q'[' - ) - ]' - ); - --Assert - ut.expect(l_actual).to_be_like(l_expected); - end; - -end test_html_extended_reporter; -/ diff --git a/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pks b/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pks deleted file mode 100644 index 02973fbe0..000000000 --- a/test/ut3_user/reporters/test_coverage/test_html_proftab_reporter.pks +++ /dev/null @@ -1,10 +0,0 @@ -create or replace package test_html_proftab_reporter is - - --%suite(ut_html_proftab_reporter) - --%suitepath(utplsql.test_user.reporters.test_coverage.test_proftab_coverage) - - --%test(reports on a project file mapped to database object in profiler coverage) - procedure report_on_file; - -end test_html_proftab_reporter; -/ diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index a707c33d2..c6e087462 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -5,17 +5,19 @@ create or replace package body test_proftab_coverage is l_actual clob; begin --Arrange - l_expected := '%%'; + l_expected := coverage_helper.substitute_covered_package('%%'); --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( - q'[ - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) - ) - ]' + coverage_helper.substitute_covered_package( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.{p}' ) + ) + ]' + ) ); --Assert ut.expect(l_actual).to_be_like(l_expected); @@ -26,17 +28,19 @@ create or replace package body test_proftab_coverage is l_actual clob; begin --Arrange - l_expected := '%%'; + l_expected := coverage_helper.substitute_covered_package('%%'); --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( - q'[ - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'dummy_coverage' ) - ) - ]' + coverage_helper.substitute_covered_package( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( '{p}' ) + ) + ]' + ) ); --Assert ut.expect(l_actual).to_be_like(l_expected); @@ -67,10 +71,10 @@ create or replace package body test_proftab_coverage is procedure coverage_for_file is l_expected clob; l_actual clob; - l_file_path varchar2(100); + l_file_path varchar2(250); begin --Arrange - l_file_path := 'test/ut3_develop.dummy_coverage.pkb'; + l_file_path := coverage_helper.substitute_covered_package('test/ut3_develop.{p}.pkb'); l_expected := '%%'; --Act l_actual := @@ -102,11 +106,11 @@ create or replace package body test_proftab_coverage is ut3_develop.ut.run( a_path => 'ut3_develop:coverage_testing', a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.{p}' ) ) ); coverage_helper.drop_dummy_coverage(); - coverage_helper.create_dummy_coverage_test_1(); + coverage_helper.create_dummy_coverage_1(); --Act insert into test_results @@ -115,19 +119,67 @@ create or replace package body test_proftab_coverage is ut3_develop.ut.run( a_path => 'ut3_develop:coverage_testing', a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.dummy_coverage' ) + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.{p}' ) ) ); commit; end; ]'; - l_actual := ut3_tester_helper.coverage_helper.run_code_as_job( l_test_code ); + l_actual := ut3_tester_helper.coverage_helper.run_code_as_job( coverage_helper.substitute_covered_package(l_test_code) ); --Assert ut.expect(l_actual).to_equal(to_clob(' ')); end; + procedure report_zero_coverage is + l_expected clob; + l_actual clob; + begin + --Arrange + l_expected := + q'[ + + + +ut3_develop.{p} + + + + + + + + + + + + + + + + + + +]'; + + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + coverage_helper.substitute_covered_package( + q'[ + ut3_develop.ut.run( + 'ut3_develop.test_dummy_coverage.zero_coverage', + ut3_develop.ut_coverage_cobertura_reporter(), + a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.{P}') + ) + ]' + ) + ); + --Assert + ut.expect(l_actual).to_be_like(coverage_helper.substitute_covered_package(l_expected)); + end; + end; / diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks index 3bfec567c..055422bf7 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks @@ -16,9 +16,12 @@ create or replace package test_proftab_coverage is procedure coverage_for_file; --%test(Coverage data is not cached between runs - issue #562 ) + --%aftertest(ut3_tester_helper.coverage_helper.drop_dummy_coverage_1) --%aftertest(ut3_tester_helper.coverage_helper.create_dummy_coverage) - --%aftertest(ut3_tester_helper.coverage_helper.drop_dummy_coverage_test_1) procedure coverage_tmp_data_refresh; + --%test(reports zero coverage on each line of non-executed database object - Issue #917) + procedure report_zero_coverage; + end; / From 631d6da109b9a50c19abd930fe6c6d41286ad4f9 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 14 Jun 2020 16:28:54 +0100 Subject: [PATCH 091/887] Renamed master to main --- .travis.yml | 2 +- .travis/push_docs_to_github_io.sh | 2 +- CONTRIBUTING.md | 2 +- development/refresh_sources.sh | 6 +++--- development/releasing.md | 10 +++++----- readme.md | 2 +- 6 files changed, 12 insertions(+), 12 deletions(-) diff --git a/.travis.yml b/.travis.yml index 265fc0888..d3299de4e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -74,7 +74,7 @@ before_install: - git fetch --unshallow # download latest utPLSQL release #- curl -LOk $(curl --silent https://api.github.com/repos/utPLSQL/utPLSQL/releases/latest | awk '/browser_download_url/ { print $2 }' | grep ".zip" | sed 's/"//g') - - git clone --depth=1 --branch=${SELFTESTING_BRANCH:-master} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR + - git clone --depth=1 --branch=${SELFTESTING_BRANCH:-main} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR # download latest utPLSQL-cli release - curl -Lk -o utPLSQL-cli.zip https://github.com/utPLSQL/utPLSQL-cli/releases/download/v${UTPLSQL_CLI_VERSION}/utPLSQL-cli.zip diff --git a/.travis/push_docs_to_github_io.sh b/.travis/push_docs_to_github_io.sh index e29f1c88c..80fd47b43 100644 --- a/.travis/push_docs_to_github_io.sh +++ b/.travis/push_docs_to_github_io.sh @@ -15,7 +15,7 @@ # Required ENV Variables LATEST_DOCS_BRANCH="develop" GITHUB_IO_REPO='utPLSQL/utPLSQL.github.io' -GITHUB_IO_BRANCH='master' +GITHUB_IO_BRANCH='main' # TRAVIS_* variables are set by travis directly and only need to be if testing externally diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 895b53fb9..a65b7b685 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -107,7 +107,7 @@ development/install.sh You now have the following: - sources from `develop` branch of your fork of utPLSQL repository in `utPLSQL/ut3_latest_release` directory -- sources from `master` branch of utPLSQL/utPLSQL repository in `utPLSQL/ut3_latest_release` directory +- sources from `main` branch of utPLSQL/utPLSQL repository in `utPLSQL/ut3_latest_release` directory - binaries of `utplsql-cli` in `utPLSQL/utPLSQL-cli` directory - database users created - your current branch of utPLSQL deployed into `ut3` schema diff --git a/development/refresh_sources.sh b/development/refresh_sources.sh index e051787a1..7af3aaec0 100755 --- a/development/refresh_sources.sh +++ b/development/refresh_sources.sh @@ -5,10 +5,10 @@ git rev-parse && cd "$(git rev-parse --show-cdup)" . development/env.sh -# remove sub-direcotry containing master branch shallow copy +# remove sub-direcotry containing main branch shallow copy rm -rf ${UTPLSQL_DIR:-utPLSQL_latest_release} -# clone utPLSQL master branch from upstream into utPLSQL sub-directory of your project -git clone --depth=1 --branch=${SELFTESTING_BRANCH:-master} https://github.com/utPLSQL/utPLSQL.git ${UTPLSQL_DIR:-utPLSQL_latest_release} +# clone utPLSQL main branch from upstream into utPLSQL sub-directory of your project +git clone --depth=1 --branch=${SELFTESTING_BRANCH:-main} https://github.com/utPLSQL/utPLSQL.git ${UTPLSQL_DIR:-utPLSQL_latest_release} rm -rf utPLSQL-cli/* # download latest release version of utPLSQL-cli diff --git a/development/releasing.md b/development/releasing.md index 93634018d..f85e18c3c 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -8,19 +8,19 @@ This step is performed, to confirm that the update of versions works properly. - create release branch from development branch and make sure to name the release branch: `release/vX.Y.Z` - update, commit and push at least one file change in the release branch, to kickoff a Travis build - wait for th build to complete successfully - - merge the release branch to master and wait for master build to complete successfully (do not use Squash/rebase for merge operation) - - create a Github release from the master branch using [github releases page](https://github.com/utPLSQL/utPLSQL/releases) and populate release description using information found on the issues and pull requests since previous release. + - merge the release branch to main and wait for main build to complete successfully (do not use Squash/rebase for merge operation) + - create a Github release from the main branch using [github releases page](https://github.com/utPLSQL/utPLSQL/releases) and populate release description using information found on the issues and pull requests since previous release. To find issues closed after certain date use [advanced filters](https://help.github.com/articles/searching-issues-and-pull-requests/#search-by-open-or-closed-state). Example: [`is:issue closed:>2018-07-22`](https://github.com/utPLSQL/utPLSQL/issues?utf8=%E2%9C%93&q=is%3Aissue+closed%3A%3E2018-07-22+) - - After A build was completed on a TAG (github release) was successful, merge master branch back into develop branch. - - At this point, master branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. + - After A build was completed on a TAG (github release) was successful, merge main branch back into develop branch. + - At this point, main branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. - After develop branch was built, update version number in `VERSION` file to represent next planned release version. - Clone `utplsql.githug.io` project and add a new announcement about next version being released in `_posts`. Use previous announcements as a template. Make sure to set date, time and post title properly. The following will happen: - build executed on branch `release/vX.Y.Z-[something]` updates files `sonar-project.properties`, `VERSION` with project version derived from the release branch name - changes to those two files are committed and pushed back to release branch by Travis - - builds on master branch are **not getting executed** + - builds on main branch are **not getting executed** - when a Github release is created, a new tag is added in on the repository and a tag build is executed - the documentation for new release is published on `utplsql.github.io` and installation archives are added to the tag. diff --git a/readme.md b/readme.md index 715b87302..7adecd3e0 100644 --- a/readme.md +++ b/readme.md @@ -8,7 +8,7 @@ [![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) -[![build](https://img.shields.io/travis/utPLSQL/utPLSQL/master.svg?label=master%20branch)](https://travis-ci.org/utPLSQL/utPLSQL) +[![build](https://img.shields.io/travis/utPLSQL/utPLSQL/main.svg?label=main%20branch)](https://travis-ci.org/utPLSQL/utPLSQL) [![build](https://img.shields.io/travis/utPLSQL/utPLSQL/develop.svg?label=develop%20branch)](https://travis-ci.org/utPLSQL/utPLSQL) [![sonar](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=sqale_rating)](https://sonarcloud.io/dashboard/index?id=utPLSQL) [![Coveralls coverage](https://coveralls.io/repos/github/utPLSQL/utPLSQL/badge.svg?branch=develop)](https://coveralls.io/github/utPLSQL/utPLSQL?branch=develop) From a660208acc592faee891a4ca22e7835fdca4224c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 14 Jun 2020 20:02:49 +0100 Subject: [PATCH 092/887] First code corrections --- docs/userguide/expectations.md | 18 +------ source/core/ut_utils.pkb | 18 ++----- source/core/ut_utils.pks | 3 ++ source/expectations/matchers/ut_be_within.tpb | 52 +++++++++---------- source/expectations/matchers/ut_be_within.tps | 12 ++--- .../expectations/matchers/ut_matcher_base.tps | 2 +- source/expectations/ut_expectation_base.tpb | 2 +- source/expectations/ut_expectation_base.tps | 4 +- 8 files changed, 44 insertions(+), 67 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 4e93f0be1..3049ac447 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1126,22 +1126,6 @@ end; **Example 3.** ```sql -begin - ut.expect(sysdate).to_be_within_pct(interval '1' day).of_(sysdate + 1); -end; -/ -``` - -**Example 4.** -```sql -begin - ut.expect(sysdate).to_be_within_pct(interval '1' month).of_(add_months(sysdate,1)); -end; -/ -``` - -**Example 5.** -```sql begin ut.expect(3).to_be_within(1).of_(5); end; @@ -1158,7 +1142,7 @@ Failures: at "UT3_DEVELOP.TEST_BETWNSTR.WIHTIN_TEST", line 5 ``` -**Example 6.** +**Example 4.** ```sql begin ut.expect(sysdate).to_be_within(interval '1' day).of_(sysdate+2); diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 4b6c66d95..e2804a3b8 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -887,25 +887,18 @@ create or replace package body ut_utils is l_result := case when l_day = 1 then l_day ||' day' when l_day > 1 then l_day ||' days' - else null - end; - l_result := l_result || + end || case when l_hour = 1 then ' '|| l_hour ||' hour' when l_hour > 1 then ' '|| l_hour ||' hours' - else null - end; - l_result := l_result || + end || case when l_minute = 1 then ' '||l_minute ||' minute' when l_minute > 1 then ' '||l_minute ||' minutes' - else null - end; - l_result := l_result || + end || case when l_second = 1 then ' '||l_second ||' second' when l_second > 1 then ' '||l_second ||' seconds' - else null end; return trim(leading ' ' from l_result); end; @@ -918,13 +911,10 @@ create or replace package body ut_utils is l_result := case when l_year = 1 then l_year ||' year' when l_year > 1 then l_year ||' years' - else null - end; - l_result := l_result || + end || case when l_month = 1 then ' '||l_month ||' month' when l_month > 1 then ' '||l_month ||' months' - else null end; return trim(leading ' ' from l_result); end; diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 750b17a77..e8219374b 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -440,6 +440,9 @@ create or replace package ut_utils authid definer is */ function interval_to_text(a_interval dsinterval_unconstrained) return varchar2; + /* + * Return value of interval in plain english + */ function interval_to_text(a_interval yminterval_unconstrained) return varchar2; end ut_utils; diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index ab4ed8b6f..b6e975166 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -16,28 +16,28 @@ create or replace type body ut_be_within as limitations under the License. */ - member procedure init(self in out nocopy ut_be_within, a_dist ut_data_value, a_is_pct number , a_self_type varchar2 := null) is + member procedure init(self in out nocopy ut_be_within, a_distance_from_expected ut_data_value, a_is_pct number , a_self_type varchar2 := null) is begin - self.dist := a_dist; + self.distance_from_expected := a_distance_from_expected; self.is_pct := nvl(a_is_pct,0); self.self_type := nvl( a_self_type, $$plsql_unit ); end; - constructor function ut_be_within(self in out nocopy ut_be_within, a_dist number, a_is_pct number) return self as result is + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected number, a_is_pct number) return self as result is begin - init(ut_data_value_number(a_dist),a_is_pct); + init(ut_data_value_number(a_distance_from_expected),a_is_pct); return; end; - constructor function ut_be_within(self in out nocopy ut_be_within, a_dist dsinterval_unconstrained, a_is_pct number) return self as result is + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected dsinterval_unconstrained, a_is_pct number) return self as result is begin - init(ut_data_value_dsinterval(a_dist),a_is_pct); + init(ut_data_value_dsinterval(a_distance_from_expected),a_is_pct); return; end; - constructor function ut_be_within(self in out nocopy ut_be_within, a_dist yminterval_unconstrained, a_is_pct number) return self as result is + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained, a_is_pct number) return self as result is begin - init(ut_data_value_yminterval(a_dist),a_is_pct); + init(ut_data_value_yminterval(a_distance_from_expected),a_is_pct); return; end; @@ -61,24 +61,24 @@ create or replace type body ut_be_within as if self.expected.data_type = a_actual.data_type then if self.expected is of (ut_data_value_number) and self.is_pct = 0 then l_result := abs((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value)) <= - treat(self.dist as ut_data_value_number).data_value; + treat(self.distance_from_expected as ut_data_value_number).data_value; elsif self.expected is of (ut_data_value_number) and self.is_pct = 1 then - l_result := treat(self.dist as ut_data_value_number).data_value >= + l_result := treat(self.distance_from_expected as ut_data_value_number).data_value >= ( ((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ) / (treat(self.expected as ut_data_value_number).data_value)) ; - elsif self.expected is of (ut_data_value_date) and self.dist is of ( ut_data_value_yminterval) then + elsif self.expected is of (ut_data_value_date) and self.distance_from_expected is of ( ut_data_value_yminterval) then l_result := treat(a_actual as ut_data_value_date).data_value between - (treat(self.expected as ut_data_value_date).data_value) - treat(self.dist as ut_data_value_yminterval).data_value + (treat(self.expected as ut_data_value_date).data_value) - treat(self.distance_from_expected as ut_data_value_yminterval).data_value and - (treat(self.expected as ut_data_value_date).data_value) + treat(self.dist as ut_data_value_yminterval).data_value; - elsif self.expected is of (ut_data_value_date) and self.dist is of ( ut_data_value_dsinterval) then + (treat(self.expected as ut_data_value_date).data_value) + treat(self.distance_from_expected as ut_data_value_yminterval).data_value; + elsif self.expected is of (ut_data_value_date) and self.distance_from_expected is of ( ut_data_value_dsinterval) then l_result := treat(a_actual as ut_data_value_date).data_value between - (treat(self.expected as ut_data_value_date).data_value) - treat(self.dist as ut_data_value_dsinterval).data_value + (treat(self.expected as ut_data_value_date).data_value) - treat(self.distance_from_expected as ut_data_value_dsinterval).data_value and - (treat(self.expected as ut_data_value_date).data_value) + treat(self.dist as ut_data_value_dsinterval).data_value; + (treat(self.expected as ut_data_value_date).data_value) + treat(self.distance_from_expected as ut_data_value_dsinterval).data_value; end if; else l_result := (self as ut_matcher).run_matcher(a_actual); @@ -87,20 +87,20 @@ create or replace type body ut_be_within as end; overriding member function failure_message(a_actual ut_data_value) return varchar2 is - l_distance varchar2(32767); + l_distance_from_expected varchar2(32767); begin - l_distance := case - when self.dist is of (ut_data_value_number) then - treat(self.dist as ut_data_value_number).to_string - when self.dist is of (ut_data_value_yminterval) then - treat(self.dist as ut_data_value_yminterval).to_string - when self.dist is of (ut_data_value_dsinterval) then - treat(self.dist as ut_data_value_dsinterval).to_string + l_distance_from_expected := case + when self.distance_from_expected is of (ut_data_value_number) then + treat(self.distance_from_expected as ut_data_value_number).to_string + when self.distance_from_expected is of (ut_data_value_yminterval) then + treat(self.distance_from_expected as ut_data_value_yminterval).to_string + when self.distance_from_expected is of (ut_data_value_dsinterval) then + treat(self.distance_from_expected as ut_data_value_dsinterval).to_string else null end; - return (self as ut_matcher).failure_message(a_actual) || ' '||l_distance ||' of '|| expected.to_string_report(); + return (self as ut_matcher).failure_message(a_actual) || ' '||l_distance_from_expected ||' of '|| expected.to_string_report(); end; overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 is @@ -110,4 +110,4 @@ create or replace type body ut_be_within as end; end; -/ \ No newline at end of file +/ diff --git a/source/expectations/matchers/ut_be_within.tps b/source/expectations/matchers/ut_be_within.tps index 30947d2aa..9b0d0109d 100644 --- a/source/expectations/matchers/ut_be_within.tps +++ b/source/expectations/matchers/ut_be_within.tps @@ -20,13 +20,13 @@ create or replace type ut_be_within under ut_comparison_matcher( /** * Holds information about mather options */ - dist ut_data_value, + distance_from_expected ut_data_value, is_pct number(1,0), - member procedure init(self in out nocopy ut_be_within, a_dist ut_data_value, a_is_pct number , a_self_type varchar2 := null), - constructor function ut_be_within(self in out nocopy ut_be_within, a_dist number, a_is_pct number) return self as result, - constructor function ut_be_within(self in out nocopy ut_be_within, a_dist dsinterval_unconstrained, a_is_pct number) return self as result, - constructor function ut_be_within(self in out nocopy ut_be_within, a_dist yminterval_unconstrained, a_is_pct number) return self as result, + member procedure init(self in out nocopy ut_be_within, a_distance_from_expected ut_data_value, a_is_pct number , a_self_type varchar2 := null), + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected number, a_is_pct number) return self as result, + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected dsinterval_unconstrained, a_is_pct number) return self as result, + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained, a_is_pct number) return self as result, member procedure of_(self in ut_be_within, a_expected number), member procedure of_(self in ut_be_within, a_expected date), @@ -35,4 +35,4 @@ create or replace type ut_be_within under ut_comparison_matcher( overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 ) not final -/ \ No newline at end of file +/ diff --git a/source/expectations/matchers/ut_matcher_base.tps b/source/expectations/matchers/ut_matcher_base.tps index ec37267a0..ef7fd98a2 100644 --- a/source/expectations/matchers/ut_matcher_base.tps +++ b/source/expectations/matchers/ut_matcher_base.tps @@ -2,4 +2,4 @@ create or replace type ut_matcher_base force authid current_user as object( self_type varchar2(250) ) not final not instantiable -/ \ No newline at end of file +/ diff --git a/source/expectations/ut_expectation_base.tpb b/source/expectations/ut_expectation_base.tpb index d657c2822..20b3e7a95 100644 --- a/source/expectations/ut_expectation_base.tpb +++ b/source/expectations/ut_expectation_base.tpb @@ -41,4 +41,4 @@ create or replace type body ut_expectation_base as ut_expectation_processor.add_expectation_result( ut_expectation_result( ut_utils.to_test_result( l_expectation_result ), self.description, l_message ) ); end; end; -/ \ No newline at end of file +/ diff --git a/source/expectations/ut_expectation_base.tps b/source/expectations/ut_expectation_base.tps index 87c0083b0..ad96ea97b 100644 --- a/source/expectations/ut_expectation_base.tps +++ b/source/expectations/ut_expectation_base.tps @@ -21,5 +21,5 @@ create or replace type ut_expectation_base force authid current_user as object( --base matcher executors member procedure to_(self in ut_expectation_base, a_matcher ut_matcher_base), member procedure not_to(self in ut_expectation_base, a_matcher ut_matcher_base) -) not final -/ \ No newline at end of file +) not final not instantiable +/ From ada1ea44fcaac3c118253f32ba710f2214e81705 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 14 Jun 2020 20:35:33 +0100 Subject: [PATCH 093/887] Resolving another comment --- source/expectations/ut_expectation_compound.tpb | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index 7043ec053..ec6bf392c 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -35,11 +35,11 @@ create or replace type body ut_expectation_compound as member function to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_equal is - l_result ut_matcher; + l_result ut_equal; begin l_result := ut_equal(a_expected, a_nulls_are_equal); l_result.expectation := self; - return treat(l_result as ut_equal); + return l_result; end; member function not_to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_equal is @@ -51,11 +51,11 @@ create or replace type body ut_expectation_compound as end; member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal is - l_result ut_matcher; + l_result ut_equal; begin l_result := ut_equal(a_expected, a_nulls_are_equal); l_result.expectation := self; - return treat(l_result as ut_equal); + return l_result; end; member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal is @@ -67,11 +67,11 @@ create or replace type body ut_expectation_compound as end; member function to_contain(a_expected sys_refcursor) return ut_equal is - l_result ut_matcher; + l_result ut_equal; begin l_result := ut_contain(a_expected); l_result.expectation := self; - return treat(l_result as ut_equal); + return l_result; end; member function not_to_contain(a_expected sys_refcursor) return ut_equal is @@ -83,11 +83,11 @@ create or replace type body ut_expectation_compound as end; member function to_contain(a_expected anydata) return ut_equal is - l_result ut_matcher; + l_result ut_equal; begin l_result := ut_contain(a_expected); l_result.expectation := self; - return treat(l_result as ut_equal); + return l_result; end; member function not_to_contain(a_expected anydata) return ut_equal is From fe1b0cb4c93314257b196157e33eec42f3c7d251 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 14 Jun 2020 20:51:18 +0100 Subject: [PATCH 094/887] Updating issues --- source/expectations/ut_expectation_compound.tpb | 16 ++++++++-------- source/expectations/ut_expectation_compound.tps | 8 ++++---- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index ec6bf392c..6a2047aed 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -66,36 +66,36 @@ create or replace type body ut_expectation_compound as return treat(l_result as ut_equal); end; - member function to_contain(a_expected sys_refcursor) return ut_equal is - l_result ut_equal; + member function to_contain(a_expected sys_refcursor) return ut_contain is + l_result ut_contain; begin l_result := ut_contain(a_expected); l_result.expectation := self; return l_result; end; - member function not_to_contain(a_expected sys_refcursor) return ut_equal is + member function not_to_contain(a_expected sys_refcursor) return ut_contain is l_result ut_matcher; begin l_result := ut_contain(a_expected).negated(); l_result.expectation := self; - return treat(l_result as ut_equal); + return treat(l_result as ut_contain); end; - member function to_contain(a_expected anydata) return ut_equal is - l_result ut_equal; + member function to_contain(a_expected anydata) return ut_contain is + l_result ut_contain; begin l_result := ut_contain(a_expected); l_result.expectation := self; return l_result; end; - member function not_to_contain(a_expected anydata) return ut_equal is + member function not_to_contain(a_expected anydata) return ut_contain is l_result ut_matcher; begin l_result := ut_contain(a_expected).negated(); l_result.expectation := self; - return treat(l_result as ut_equal); + return treat(l_result as ut_contain); end; end; diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index a2c06ce76..71c5e2ce9 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -26,10 +26,10 @@ create or replace type ut_expectation_compound under ut_expectation( member function not_to_equal(a_expected anydata, a_nulls_are_equal boolean := null) return ut_equal, member function to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal, member function not_to_equal(a_expected sys_refcursor, a_nulls_are_equal boolean := null) return ut_equal, - member function to_contain(a_expected sys_refcursor) return ut_equal, - member function not_to_contain(a_expected sys_refcursor) return ut_equal, - member function to_contain(a_expected anydata) return ut_equal, - member function not_to_contain(a_expected anydata) return ut_equal + member function to_contain(a_expected sys_refcursor) return ut_contain, + member function not_to_contain(a_expected sys_refcursor) return ut_contain, + member function to_contain(a_expected anydata) return ut_contain, + member function not_to_contain(a_expected anydata) return ut_contain ) / From 013db74c9e0be8c67ffb7e3288b5027fac759296 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 14 Jun 2020 23:12:56 +0100 Subject: [PATCH 095/887] Update tble --- docs/userguide/expectations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3049ac447..3ecf8db0a 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -333,7 +333,7 @@ The matrix below illustrates the data types supported by different matchers. | **be_like** | | | X | | | | | | X | | | | | | | | **be_empty** | X | | X | | | | | | | | | X | X | | X | | **have_count** | | | | | | | | | | | | X | X | | X | -| **be_within().of_()** | | | | x | x | | | | | | | X | X | | X | +| **be_within().of_()** | | | | x | x | | | | | | | | | | | # Expecting exceptions From 4e7631b996b52d6317bf1bf30f6fb394b4124d81 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Mon, 15 Jun 2020 07:49:21 +0000 Subject: [PATCH 096/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 2d0bce9da..40066e6aa 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 23fc28fc7..35cf2e9b8 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 0e8334ea1..c2d7c8f54 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index b7ae9d169..458a925a9 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 22387ed5a..8c47b7c55 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 202ddbbad..3baefddfc 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 65a9ac0fe..191f3fdc4 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 576fe89b6..0cd0fb9ae 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0f001a5a8..e15167f1a 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 72e5c476a..fce6a83fd 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index a9a29e213..a43f3ebec 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 0de315b4a..95e82dcd9 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index f3ab786e8..fca4bcf13 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 6ea157369..7107cc139 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ac03362a5..7730c7c6c 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a3d8b0cb0..6f9774a8b 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 3c7565323..eab281d70 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 7779c3dfe..e12b91752 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3400-develop + * secion v3.1.11.3422-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c109a6c26..b0ee188fc 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3400-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3422-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From b5c73b44898bfcfe28497f0ff27df4df892f6af2 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 19 Jun 2020 10:11:55 +0100 Subject: [PATCH 097/887] Separated into two different matchers Added synonym and grant for matcher Reworked expectation to work fine with syntax `to_( matcher() )` for to_be_within. TODO - add tests for other matchers with `to_( matcher )` and `not_to( matcher )` syntax --- source/api/be_within.syn | 1 + source/create_grants.sql | 1 + source/create_synonyms.sql | 1 + source/expectations/matchers/ut_be_within.tpb | 42 ++++++---- source/expectations/matchers/ut_be_within.tps | 14 ++-- .../matchers/ut_be_within_pct.tpb | 42 ++++++++++ .../matchers/ut_be_within_pct.tps | 24 ++++++ source/expectations/matchers/ut_matcher.tpb | 5 -- source/expectations/ut_expectation.tpb | 52 +++++++++--- source/expectations/ut_expectation.tps | 6 +- source/install.sql | 3 + .../ut3_tester_helper/expectations_helper.pkb | 24 ------ .../ut3_tester_helper/expectations_helper.pks | 10 --- .../expectations/binary/test_to_be_within.pkb | 81 ++++++++++++++++--- .../expectations/binary/test_to_be_within.pks | 2 +- 15 files changed, 220 insertions(+), 88 deletions(-) create mode 100644 source/api/be_within.syn create mode 100644 source/expectations/matchers/ut_be_within_pct.tpb create mode 100644 source/expectations/matchers/ut_be_within_pct.tps diff --git a/source/api/be_within.syn b/source/api/be_within.syn new file mode 100644 index 000000000..e00005bb7 --- /dev/null +++ b/source/api/be_within.syn @@ -0,0 +1 @@ +create synonym be_within for ut_be_within; diff --git a/source/create_grants.sql b/source/create_grants.sql index 4553c52f6..111294cef 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -87,6 +87,7 @@ grant execute on &&ut3_owner..ut_be_like to &ut3_user; grant execute on &&ut3_owner..ut_be_not_null to &ut3_user; grant execute on &&ut3_owner..ut_be_null to &ut3_user; grant execute on &&ut3_owner..ut_be_true to &ut3_user; +grant execute on &&ut3_owner..ut_be_within to &ut3_user; grant execute on &&ut3_owner..ut_contain to &ut3_user; grant execute on &&ut3_owner..ut_equal to &ut3_user; grant execute on &&ut3_owner..ut_have_count to &ut3_user; diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index 425ca57a6..53e2bb65f 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -103,6 +103,7 @@ create &action_type. synonym &ut3_user.be_like for &&ut3_owner..be_like; create &action_type. synonym &ut3_user.be_not_null for &&ut3_owner..be_not_null; create &action_type. synonym &ut3_user.be_null for &&ut3_owner..be_null; create &action_type. synonym &ut3_user.be_true for &&ut3_owner..be_true; +create &action_type. synonym &ut3_user.be_within for &&ut3_owner..be_within; create &action_type. synonym &ut3_user.contain for &&ut3_owner..contain; create &action_type. synonym &ut3_user.equal for &&ut3_owner..equal; create &action_type. synonym &ut3_user.have_count for &&ut3_owner..have_count; diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index b6e975166..a5b5d6cbf 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -16,28 +16,27 @@ create or replace type body ut_be_within as limitations under the License. */ - member procedure init(self in out nocopy ut_be_within, a_distance_from_expected ut_data_value, a_is_pct number , a_self_type varchar2 := null) is + member procedure init(self in out nocopy ut_be_within, a_distance_from_expected ut_data_value) is begin self.distance_from_expected := a_distance_from_expected; - self.is_pct := nvl(a_is_pct,0); - self.self_type := nvl( a_self_type, $$plsql_unit ); + self.self_type := $$plsql_unit; end; - constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected number, a_is_pct number) return self as result is + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected number) return self as result is begin - init(ut_data_value_number(a_distance_from_expected),a_is_pct); + init(ut_data_value_number(a_distance_from_expected)); return; end; - constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected dsinterval_unconstrained, a_is_pct number) return self as result is + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected dsinterval_unconstrained) return self as result is begin - init(ut_data_value_dsinterval(a_distance_from_expected),a_is_pct); + init(ut_data_value_dsinterval(a_distance_from_expected)); return; end; - constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained, a_is_pct number) return self as result is + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained) return self as result is begin - init(ut_data_value_yminterval(a_distance_from_expected),a_is_pct); + init(ut_data_value_yminterval(a_distance_from_expected)); return; end; @@ -54,20 +53,29 @@ create or replace type body ut_be_within as l_result.expected := ut_data_value_date(a_expected); l_result.expectation.to_(l_result ); end; - + + member function of_(self in ut_be_within, a_expected number) return ut_be_within is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_number(a_expected); + return l_result; + end; + + member function of_(self in ut_be_within, a_expected date) return ut_be_within is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_date(a_expected); + return l_result; + end; + overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean is l_result boolean; begin if self.expected.data_type = a_actual.data_type then - if self.expected is of (ut_data_value_number) and self.is_pct = 0 then + if self.expected is of (ut_data_value_number) then l_result := abs((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value)) <= treat(self.distance_from_expected as ut_data_value_number).data_value; - elsif self.expected is of (ut_data_value_number) and self.is_pct = 1 then - l_result := treat(self.distance_from_expected as ut_data_value_number).data_value >= - ( - ((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ) / - (treat(self.expected as ut_data_value_number).data_value)) ; - elsif self.expected is of (ut_data_value_date) and self.distance_from_expected is of ( ut_data_value_yminterval) then + elsif self.expected is of (ut_data_value_date) and self.distance_from_expected is of ( ut_data_value_yminterval) then l_result := treat(a_actual as ut_data_value_date).data_value between (treat(self.expected as ut_data_value_date).data_value) - treat(self.distance_from_expected as ut_data_value_yminterval).data_value diff --git a/source/expectations/matchers/ut_be_within.tps b/source/expectations/matchers/ut_be_within.tps index 9b0d0109d..55f32bc4e 100644 --- a/source/expectations/matchers/ut_be_within.tps +++ b/source/expectations/matchers/ut_be_within.tps @@ -21,15 +21,15 @@ create or replace type ut_be_within under ut_comparison_matcher( * Holds information about mather options */ distance_from_expected ut_data_value, - is_pct number(1,0), - - member procedure init(self in out nocopy ut_be_within, a_distance_from_expected ut_data_value, a_is_pct number , a_self_type varchar2 := null), - constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected number, a_is_pct number) return self as result, - constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected dsinterval_unconstrained, a_is_pct number) return self as result, - constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained, a_is_pct number) return self as result, + member procedure init(self in out nocopy ut_be_within, a_distance_from_expected ut_data_value), + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected number) return self as result, + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected dsinterval_unconstrained) return self as result, + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained) return self as result, member procedure of_(self in ut_be_within, a_expected number), member procedure of_(self in ut_be_within, a_expected date), - + member function of_(self in ut_be_within, a_expected number) return ut_be_within, + member function of_(self in ut_be_within, a_expected date) return ut_be_within, + overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean, overriding member function failure_message(a_actual ut_data_value) return varchar2, overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 diff --git a/source/expectations/matchers/ut_be_within_pct.tpb b/source/expectations/matchers/ut_be_within_pct.tpb new file mode 100644 index 000000000..326197fe6 --- /dev/null +++ b/source/expectations/matchers/ut_be_within_pct.tpb @@ -0,0 +1,42 @@ +create or replace type body ut_be_within_pct as + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + constructor function ut_be_within_pct(self in out nocopy ut_be_within_pct, a_distance_from_expected number) return self as result is + begin + self.init(ut_data_value_number(a_distance_from_expected)); + return; + end; + + overriding member function run_matcher(self in out nocopy ut_be_within_pct, a_actual ut_data_value) return boolean is + l_result boolean; + begin + if self.expected.data_type = a_actual.data_type then + if self.expected is of (ut_data_value_number) then + l_result := treat(self.distance_from_expected as ut_data_value_number).data_value >= + ( + ((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ) / + (treat(self.expected as ut_data_value_number).data_value)) ; + end if; + else + l_result := (self as ut_matcher).run_matcher(a_actual); + end if; + return l_result; + end; + +end; +/ diff --git a/source/expectations/matchers/ut_be_within_pct.tps b/source/expectations/matchers/ut_be_within_pct.tps new file mode 100644 index 000000000..b47c7a9fd --- /dev/null +++ b/source/expectations/matchers/ut_be_within_pct.tps @@ -0,0 +1,24 @@ +create or replace type ut_be_within_pct under ut_be_within( + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + + constructor function ut_be_within_pct(self in out nocopy ut_be_within_pct, a_distance_from_expected number) return self as result, + overriding member function run_matcher(self in out nocopy ut_be_within_pct, a_actual ut_data_value) return boolean +) +not final +/ diff --git a/source/expectations/matchers/ut_matcher.tpb b/source/expectations/matchers/ut_matcher.tpb index 11ff1b6b6..ca8598fd8 100644 --- a/source/expectations/matchers/ut_matcher.tpb +++ b/source/expectations/matchers/ut_matcher.tpb @@ -20,11 +20,6 @@ create or replace type body ut_matcher as begin ut_utils.debug_log('Failure - ut_matcher.run_matcher'||'(a_actual '||a_actual.data_type||')'); self.is_errored := ut_utils.boolean_to_int(true); --- self.error_message := 'The matcher '''||name()||''' cannot be used'; --- if self.expected is not null then --- self.error_message := self.error_message ||' for comparison of data type ('||self.expected.data_type||')'; --- end if; --- self.error_message := self.error_message ||' with data type ('||a_actual.data_type||').'; return null; end; diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index 288c6cf19..8801af724 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -694,37 +694,69 @@ create or replace type body ut_expectation as self.not_to( ut_contain(a_expected).negated() ); end; - member function to_be_within(a_dist natural) return ut_be_within is + member function to_be_within(a_dist natural) return ut_be_within is l_result ut_matcher; begin - l_result := ut_be_within(a_dist,0); + l_result := ut_be_within(a_dist); l_result.expectation := self; return treat(l_result as ut_be_within); end; - member function to_be_within(a_dist dsinterval_unconstrained) return ut_be_within is + member function to_be_within(a_dist dsinterval_unconstrained) return ut_be_within is l_result ut_matcher; begin - l_result := ut_be_within(a_dist,0); + l_result := ut_be_within(a_dist); l_result.expectation := self; return treat(l_result as ut_be_within); end; - member function to_be_within(a_dist yminterval_unconstrained) return ut_be_within is + member function to_be_within(a_dist yminterval_unconstrained) return ut_be_within is l_result ut_matcher; begin - l_result := ut_be_within(a_dist,0); + l_result := ut_be_within(a_dist); l_result.expectation := self; return treat(l_result as ut_be_within); end; - member function to_be_within_pct(a_dist natural) return ut_be_within is + member function to_be_within_pct(a_dist natural) return ut_be_within_pct is + l_result ut_matcher; + begin + l_result := ut_be_within_pct(a_dist); + l_result.expectation := self; + return treat(l_result as ut_be_within_pct); + end; + + member function not_to_be_within(a_dist natural) return ut_be_within is l_result ut_matcher; begin - l_result := ut_be_within(a_dist,1); + l_result := ut_be_within(a_dist).negated(); l_result.expectation := self; return treat(l_result as ut_be_within); - end; - + end; + + member function not_to_be_within(a_dist dsinterval_unconstrained) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist).negated(); + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; + + member function not_to_be_within(a_dist yminterval_unconstrained) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist).negated(); + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; + + member function not_to_be_within_pct(a_dist natural) return ut_be_within_pct is + l_result ut_matcher; + begin + l_result := ut_be_within_pct(a_dist).negated(); + l_result.expectation := self; + return treat(l_result as ut_be_within_pct); + end; + end; / diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index b45141b5c..31144d82c 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -167,7 +167,11 @@ create or replace type ut_expectation under ut_expectation_base( member function to_be_within(a_dist natural) return ut_be_within, member function to_be_within(a_dist dsinterval_unconstrained) return ut_be_within, member function to_be_within(a_dist yminterval_unconstrained) return ut_be_within, - member function to_be_within_pct(a_dist natural) return ut_be_within + member function to_be_within_pct(a_dist natural) return ut_be_within_pct, + member function not_to_be_within(a_dist natural) return ut_be_within, + member function not_to_be_within(a_dist dsinterval_unconstrained) return ut_be_within, + member function not_to_be_within(a_dist yminterval_unconstrained) return ut_be_within, + member function not_to_be_within_pct(a_dist natural) return ut_be_within_pct ) not final / diff --git a/source/install.sql b/source/install.sql index 911760a63..af639ac78 100644 --- a/source/install.sql +++ b/source/install.sql @@ -241,6 +241,7 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/matchers/ut_matcher.tps' @@install_component.sql 'expectations/matchers/ut_comparison_matcher.tps' @@install_component.sql 'expectations/matchers/ut_be_within.tps' +@@install_component.sql 'expectations/matchers/ut_be_within_pct.tps' @@install_component.sql 'expectations/ut_expectation.tps' @@install_component.sql 'expectations/matchers/ut_be_false.tps' @@install_component.sql 'expectations/matchers/ut_be_greater_or_equal.tps' @@ -297,6 +298,7 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/matchers/ut_be_true.tpb' @@install_component.sql 'expectations/matchers/ut_equal.tpb' @@install_component.sql 'expectations/matchers/ut_be_within.tpb' +@@install_component.sql 'expectations/matchers/ut_be_within_pct.tpb' @@install_component.sql 'expectations/matchers/ut_contain.tpb' @@install_component.sql 'expectations/matchers/ut_have_count.tpb' @@install_component.sql 'expectations/matchers/ut_be_between.tpb' @@ -360,6 +362,7 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'api/be_not_null.syn' @@install_component.sql 'api/be_null.syn' @@install_component.sql 'api/be_true.syn' +@@install_component.sql 'api/be_within.syn' @@install_component.sql 'api/equal.syn' @@install_component.sql 'api/have_count.syn' @@install_component.sql 'api/match.syn' diff --git a/test/ut3_tester_helper/expectations_helper.pkb b/test/ut3_tester_helper/expectations_helper.pkb index 7714e1ea3..b2fb04320 100644 --- a/test/ut3_tester_helper/expectations_helper.pkb +++ b/test/ut3_tester_helper/expectations_helper.pkb @@ -53,29 +53,5 @@ create or replace package body ut3_tester_helper.expectations_helper is return l_execute; end; - function be_within_expectation_block( - a_matcher_name varchar2, - a_actual_data_type varchar2, - a_actual_data varchar2, - a_expected_data_type varchar2, - a_expected_data varchar2, - a_distance varchar2, - a_distance_data_type varchar2 - ) return varchar2 - is - l_execute varchar2(32000); - begin - l_execute := ' - declare - l_actual '||a_actual_data_type||' := '||a_actual_data||'; - l_expected '||a_expected_data_type||' := '||a_expected_data||'; - l_distance '||a_distance_data_type||' := '||a_distance||'; - begin - --act - execute the expectation - ut3_develop.ut.expect( l_actual ).'||a_matcher_name||'(l_distance).of_(l_expected); - end;'; - return l_execute; - end; - end; / diff --git a/test/ut3_tester_helper/expectations_helper.pks b/test/ut3_tester_helper/expectations_helper.pks index 3b0a754d2..9c1d54333 100644 --- a/test/ut3_tester_helper/expectations_helper.pks +++ b/test/ut3_tester_helper/expectations_helper.pks @@ -21,15 +21,5 @@ create or replace package expectations_helper is a_expected_data varchar2 ) return varchar2; - function be_within_expectation_block( - a_matcher_name varchar2, - a_actual_data_type varchar2, - a_actual_data varchar2, - a_expected_data_type varchar2, - a_expected_data varchar2, - a_distance varchar2, - a_distance_data_type varchar2 - ) return varchar2; - end; / diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index af672e809..2605d3c53 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -7,16 +7,27 @@ create or replace package body test_to_be_within is function be_within_expectation_block( a_matcher_name varchar2, - a_data_type varchar2, - a_actual varchar2, - a_expected varchar2, + a_actual_data_type varchar2, + a_actual_data varchar2, + a_expected_data_type varchar2, + a_expected_data varchar2, a_distance varchar2, - a_distance_data_type varchar2 - ) return varchar2 is + a_distance_data_type varchar2, + a_matcher_end varchar2 + ) return varchar2 + is + l_execute varchar2(32000); begin - return ut3_tester_helper.expectations_helper.be_within_expectation_block( - a_matcher_name, a_data_type, a_actual, a_data_type, a_expected,a_distance,a_distance_data_type - ); + l_execute := ' + declare + l_actual '||a_actual_data_type||' := '||a_actual_data||'; + l_expected '||a_expected_data_type||' := '||a_expected_data||'; + l_distance '||a_distance_data_type||' := '||a_distance||'; + begin + --act - execute the expectation + ut3_develop.ut.expect( l_actual ).'||a_matcher_name||'(l_distance).of_(l_expected)'||a_matcher_end||'; + end;'; + return l_execute; end; procedure test_to_be_within_fail( @@ -25,10 +36,14 @@ create or replace package body test_to_be_within is a_actual varchar2, a_expected varchar2, a_distance varchar2, - a_distance_data_type varchar2 + a_distance_data_type varchar2, + a_matcher_end varchar2 := null ) is begin - execute immediate be_within_expectation_block(a_matcher_name,a_data_type, a_actual, a_expected,a_distance,a_distance_data_type); + execute immediate be_within_expectation_block( + a_matcher_name,a_data_type, a_actual, a_data_type, a_expected, + a_distance,a_distance_data_type, a_matcher_end + ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).not_to_equal(0); cleanup_expectations; end; @@ -39,10 +54,14 @@ create or replace package body test_to_be_within is a_actual varchar2, a_expected varchar2, a_distance varchar2, - a_distance_data_type varchar2 + a_distance_data_type varchar2, + a_matcher_end varchar2 := null ) is begin - execute immediate be_within_expectation_block(a_matcher_name,a_data_type, a_actual, a_expected,a_distance,a_distance_data_type); + execute immediate be_within_expectation_block( + a_matcher_name,a_data_type, a_actual, a_data_type, a_expected, + a_distance,a_distance_data_type, a_matcher_end + ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); cleanup_expectations; end; @@ -55,6 +74,24 @@ create or replace package body test_to_be_within is test_to_be_within_success('to_be_within','date', 'sysdate', 'sysdate+1','''1 0:00:11.333''','interval day to second'); test_to_be_within_success('to_be_within','date', 'sysdate', 'sysdate+200','''1-0''','interval year to month'); test_to_be_within_success('to_be_within','date', 'sysdate+200', 'sysdate','''1-0''','interval year to month'); + test_to_be_within_success('to_( ut3_develop.be_within','number', '2', '4','2','number', ')'); + test_to_be_within_success('to_( ut3_develop.be_within','number', '4', '2','2','number', ')'); + test_to_be_within_success('to_( ut3_develop.be_within','date', 'sysdate+1', 'sysdate','''1 0:00:11.333''','interval day to second', ')'); + test_to_be_within_success('to_( ut3_develop.be_within','date', 'sysdate', 'sysdate+1','''1 0:00:11.333''','interval day to second', ')'); + test_to_be_within_success('to_( ut3_develop.be_within','date', 'sysdate', 'sysdate+200','''1-0''','interval year to month', ')'); + test_to_be_within_success('to_( ut3_develop.be_within','date', 'sysdate+200', 'sysdate','''1-0''','interval year to month', ')'); + test_to_be_within_fail('not_to_be_within','number', '2', '4','2','number'); + test_to_be_within_fail('not_to_be_within','number', '4', '2','2','number'); + test_to_be_within_fail('not_to_be_within','date', 'sysdate+1', 'sysdate','''1 0:00:11.333''','interval day to second'); + test_to_be_within_fail('not_to_be_within','date', 'sysdate', 'sysdate+1','''1 0:00:11.333''','interval day to second'); + test_to_be_within_fail('not_to_be_within','date', 'sysdate', 'sysdate+200','''1-0''','interval year to month'); + test_to_be_within_fail('not_to_be_within','date', 'sysdate+200', 'sysdate','''1-0''','interval year to month'); + test_to_be_within_fail('not_to( ut3_develop.be_within','number', '2', '4','2','number',')'); + test_to_be_within_fail('not_to( ut3_develop.be_within','number', '4', '2','2','number',')'); + test_to_be_within_fail('not_to( ut3_develop.be_within','date', 'sysdate+1', 'sysdate','''1 0:00:11.333''','interval day to second',')'); + test_to_be_within_fail('not_to( ut3_develop.be_within','date', 'sysdate', 'sysdate+1','''1 0:00:11.333''','interval day to second',')'); + test_to_be_within_fail('not_to( ut3_develop.be_within','date', 'sysdate', 'sysdate+200','''1-0''','interval year to month',')'); + test_to_be_within_fail('not_to( ut3_develop.be_within','date', 'sysdate+200', 'sysdate','''1-0''','interval year to month',')'); end; procedure failed_tests is @@ -65,7 +102,25 @@ create or replace package body test_to_be_within is test_to_be_within_fail('to_be_within','date', 'sysdate+1', 'sysdate','''0 0:00:11.333''','interval day to second'); test_to_be_within_fail('to_be_within','date', 'sysdate', 'sysdate+750','''1-0''','interval year to month'); test_to_be_within_fail('to_be_within','date', 'sysdate+750', 'sysdate','''1-0''','interval year to month'); - end; + test_to_be_within_fail('to_( ut3_develop.be_within','number', '2', '4','1','number',')'); + test_to_be_within_fail('to_( ut3_develop.be_within','number', '4', '2','1','number',')'); + test_to_be_within_fail('to_( ut3_develop.be_within','date', 'sysdate', 'sysdate+1','''0 0:00:11.333''','interval day to second',')'); + test_to_be_within_fail('to_( ut3_develop.be_within','date', 'sysdate+1', 'sysdate','''0 0:00:11.333''','interval day to second',')'); + test_to_be_within_fail('to_( ut3_develop.be_within','date', 'sysdate', 'sysdate+750','''1-0''','interval year to month',')'); + test_to_be_within_fail('to_( ut3_develop.be_within','date', 'sysdate+750', 'sysdate','''1-0''','interval year to month',')'); + test_to_be_within_success('not_to_be_within','number', '2', '4','1','number'); + test_to_be_within_success('not_to_be_within','number', '4', '2','1','number'); + test_to_be_within_success('not_to_be_within','date', 'sysdate', 'sysdate+1','''0 0:00:11.333''','interval day to second'); + test_to_be_within_success('not_to_be_within','date', 'sysdate+1', 'sysdate','''0 0:00:11.333''','interval day to second'); + test_to_be_within_success('not_to_be_within','date', 'sysdate', 'sysdate+750','''1-0''','interval year to month'); + test_to_be_within_success('not_to_be_within','date', 'sysdate+750', 'sysdate','''1-0''','interval year to month'); + test_to_be_within_success('not_to( ut3_develop.be_within','number', '2', '4','1','number',')'); + test_to_be_within_success('not_to( ut3_develop.be_within','number', '4', '2','1','number',')'); + test_to_be_within_success('not_to( ut3_develop.be_within','date', 'sysdate', 'sysdate+1','''0 0:00:11.333''','interval day to second',')'); + test_to_be_within_success('not_to( ut3_develop.be_within','date', 'sysdate+1', 'sysdate','''0 0:00:11.333''','interval day to second',')'); + test_to_be_within_success('not_to( ut3_develop.be_within','date', 'sysdate', 'sysdate+750','''1-0''','interval year to month',')'); + test_to_be_within_success('not_to( ut3_develop.be_within','date', 'sysdate+750', 'sysdate','''1-0''','interval year to month',')'); + end; procedure fail_for_number_not_within is l_actual_message varchar2(32767); diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pks b/test/ut3_user/expectations/binary/test_to_be_within.pks index 5c042bd53..dcfb471af 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pks +++ b/test/ut3_user/expectations/binary/test_to_be_within.pks @@ -1,6 +1,6 @@ create or replace package test_to_be_within is - --%suite((not)to_be_less_or_equal) + --%suite((not)to_be_within) --%suitepath(utplsql.test_user.expectations.binary) --%aftereach From 2e721da4635da8652d69fecbc908b961962bf8c1 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 19 Jun 2020 16:53:32 +0100 Subject: [PATCH 098/887] CHECKPOINT --- source/expectations/matchers/ut_be_within.tpb | 12 +++++-- source/expectations/ut_expectation.tpb | 33 +++++++++++++++++++ source/expectations/ut_expectation.tps | 8 ++++- source/expectations/ut_expectation_base.tps | 2 +- test/ut3_tester/core/test_ut_utils.pks | 16 ++++----- .../ut3_tester_helper/expectations_helper.pkb | 2 +- .../expectations/binary/test_to_be_within.pkb | 2 +- .../expectations/binary/test_to_be_within.pks | 8 ++--- 8 files changed, 65 insertions(+), 18 deletions(-) diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index b6e975166..028bd6ad9 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -45,14 +45,22 @@ create or replace type body ut_be_within as l_result ut_be_within := self; begin l_result.expected := ut_data_value_number(a_expected); - l_result.expectation.to_(l_result ); + if l_result.is_negated_flag = 1 then + l_result.expectation.not_to(l_result ); + else + l_result.expectation.to_(l_result ); + end if; end; member procedure of_(self in ut_be_within, a_expected date) is l_result ut_be_within := self; begin l_result.expected := ut_data_value_date(a_expected); - l_result.expectation.to_(l_result ); + if l_result.is_negated_flag = 1 then + l_result.expectation.not_to(l_result ); + else + l_result.expectation.to_(l_result ); + end if; end; overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean is diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index 288c6cf19..6ef07c47b 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -725,6 +725,39 @@ create or replace type body ut_expectation as l_result.expectation := self; return treat(l_result as ut_be_within); end; + + member function not_to_be_within(a_dist natural) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist,0).negated; + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; + + member function not_to_be_within(a_dist dsinterval_unconstrained) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist,0).negated; + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; + + member function not_to_be_within(a_dist yminterval_unconstrained) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist,0).negated; + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; + + member function not_to_be_within_pct(a_dist natural) return ut_be_within is + l_result ut_matcher; + begin + l_result := ut_be_within(a_dist,0).negated; + l_result.expectation := self; + return treat(l_result as ut_be_within); + end; end; / + diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index b45141b5c..d4c446ea8 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -167,7 +167,13 @@ create or replace type ut_expectation under ut_expectation_base( member function to_be_within(a_dist natural) return ut_be_within, member function to_be_within(a_dist dsinterval_unconstrained) return ut_be_within, member function to_be_within(a_dist yminterval_unconstrained) return ut_be_within, - member function to_be_within_pct(a_dist natural) return ut_be_within + member function to_be_within_pct(a_dist natural) return ut_be_within, + + member function not_to_be_within(a_dist natural) return ut_be_within, + member function not_to_be_within(a_dist dsinterval_unconstrained) return ut_be_within, + member function not_to_be_within(a_dist yminterval_unconstrained) return ut_be_within, + member function not_to_be_within_pct(a_dist natural) return ut_be_within + ) not final / diff --git a/source/expectations/ut_expectation_base.tps b/source/expectations/ut_expectation_base.tps index ad96ea97b..a542d26ea 100644 --- a/source/expectations/ut_expectation_base.tps +++ b/source/expectations/ut_expectation_base.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation_base force authid current_user as object( +create or replace type ut_expectation_base authid current_user as object( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index 9d428b363..4d83b5042 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -130,28 +130,28 @@ create or replace package test_ut_utils is --%context(interval_converter_to_strin) - --%test(Test day to second interval passing a second) + --%test(returns text representation of interval day to second for 1 second interval) procedure int_conv_ds_sec; - --%test(Test day to second interval passing a minute) + --%test(returns text representation of interval day to second for 1 minute interval) procedure int_conv_ds_minute; - --%test(Test day to second interval passing a hour) + --%test(returns text representation of interval day to second for 1 hour interval) procedure int_conv_ds_hour; - --%test(Test day to second interval passing a day) + --%test(returns text representation of interval day to second for 1 day interval) procedure int_conv_ds_day; - --%test(Test day to second interval passing a custom date ) + --%test(returns text representation of interval day to second for combination interval) procedure int_conv_ds_date; - --%test(Test year to month interval passing a hour) + --%test(returns text representation of interval year to month for 1 year interval) procedure int_conv_ym_year; - --%test(Test year to month interval passing a day) + --%test(returns text representation of interval year to month for 1 month interval) procedure int_conv_ym_month; - --%test(Test year to month interval passing a custom date ) + --%test(returns text representation of interval year to month for custom interval) procedure int_conv_ym_date; diff --git a/test/ut3_tester_helper/expectations_helper.pkb b/test/ut3_tester_helper/expectations_helper.pkb index 7714e1ea3..eafb9fa3e 100644 --- a/test/ut3_tester_helper/expectations_helper.pkb +++ b/test/ut3_tester_helper/expectations_helper.pkb @@ -1,4 +1,4 @@ -create or replace package body ut3_tester_helper.expectations_helper is +create or replace package body expectations_helper is function unary_expectation_block( a_matcher_name varchar2, diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index af672e809..97dd865f4 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -138,4 +138,4 @@ create or replace package body test_to_be_within is end; end; -/ \ No newline at end of file +/ diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pks b/test/ut3_user/expectations/binary/test_to_be_within.pks index 5c042bd53..76b606446 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pks +++ b/test/ut3_user/expectations/binary/test_to_be_within.pks @@ -6,10 +6,10 @@ create or replace package test_to_be_within is --%aftereach procedure cleanup_expectations; - --%test(Gives failure when number is not within positive distance) + --%test(gives success for values within a distance) procedure success_tests; - --%test(Gives failure when number is not within negative distance) + --%test(gives failure when number is not within distance) procedure failed_tests; --%test(Check failure message for number not within) @@ -25,7 +25,7 @@ create or replace package test_to_be_within is procedure fail_for_ym_int_not_within; --%test(Check failure message for custom ym interval not within) - procedure fail_for_custom_ym_int; + procedure fail_for_custom_ym_int; end; -/ \ No newline at end of file +/ From f1824303682355d85ca52fe0a45623225582e836 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 19 Jun 2020 19:48:49 +0100 Subject: [PATCH 099/887] Update uninstall --- source/uninstall_objects.sql | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index c905153f4..82d8a7e5a 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -54,6 +54,8 @@ drop synonym be_true; drop synonym equal; +drop synonym be_within; + drop type ut_coveralls_reporter force; drop type ut_coverage_sonar_reporter force; @@ -140,6 +142,10 @@ drop type ut_be_less_than force; drop type ut_be_false force; +drop type ut_be_within_pct force; + +drop type ut_be_within force; + drop type ut_comparison_matcher force; drop type ut_matcher force; From e3fb2d7f15062b91a81570973f56209be8f89cb3 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 19 Jun 2020 20:26:26 +0100 Subject: [PATCH 100/887] Update progress --- docs/userguide/expectations.md | 36 +++++++++++++------ source/expectations/matchers/ut_be_within.tpb | 20 +++-------- source/expectations/ut_expectation.tpb | 18 +++++----- .../expectations/binary/test_to_be_within.pkb | 15 ++++++++ .../expectations/binary/test_to_be_within.pks | 15 ++++---- 5 files changed, 63 insertions(+), 41 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3ecf8db0a..3f26a0eff 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -334,7 +334,7 @@ The matrix below illustrates the data types supported by different matchers. | **be_empty** | X | | X | | | | | | | | | X | X | | X | | **have_count** | | | | | | | | | | | | X | X | | X | | **be_within().of_()** | | | | x | x | | | | | | | | | | | - +| **be_within_pct().of()**| | | | | x | | | | | | | | | | | # Expecting exceptions @@ -1118,14 +1118,6 @@ end; **Example 2.** ```sql -begin - ut.expect(9).to_be_within_pct(10).of_(10); -end; -/ -``` - -**Example 3.** -```sql begin ut.expect(3).to_be_within(1).of_(5); end; @@ -1142,7 +1134,7 @@ Failures: at "UT3_DEVELOP.TEST_BETWNSTR.WIHTIN_TEST", line 5 ``` -**Example 4.** +**Example 3.** ```sql begin ut.expect(sysdate).to_be_within(interval '1' day).of_(sysdate+2); @@ -1160,6 +1152,30 @@ Failures: at "UT3_DEVELOP.TEST_BETWNSTR.WIHTIN_TEST", line 5 ``` + +## to_be_within_pct of + +This matcher is created to determine wheter expected value is approximately equal or "close" to another value within percentage value of expected. + +Matcher will allow to compare numbers. + +When comparing a number the tolerance / distance can be expressed as another postive number or a percentage. + +When comparing a two dates tolerance can be expressed in interval time either Day-To-Second or Year-To-Month. + +Matcher for numbers will calculate a absolute distance between expected and actual and check whether that value is within a tolerance. + +When comparing a date a distance is measured in interval, the check is done that actual value is within date range of expected taking into account interval plus and minus. + +**Example 1.** +```sql +begin + ut.expect(9).to_be_within_pct(10).of_(10); +end; +/ +``` + + ## Comparing cursors, object types, nested tables and varrays utPLSQL is capable of comparing compound data-types including: diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index 9089c0033..52fe6aef0 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -103,26 +103,14 @@ create or replace type body ut_be_within as end; overriding member function failure_message(a_actual ut_data_value) return varchar2 is - l_distance_from_expected varchar2(32767); - begin - l_distance_from_expected := case - when self.distance_from_expected is of (ut_data_value_number) then - treat(self.distance_from_expected as ut_data_value_number).to_string - when self.distance_from_expected is of (ut_data_value_yminterval) then - treat(self.distance_from_expected as ut_data_value_yminterval).to_string - when self.distance_from_expected is of (ut_data_value_dsinterval) then - treat(self.distance_from_expected as ut_data_value_dsinterval).to_string - else - null - end; - - return (self as ut_matcher).failure_message(a_actual) || ' '||l_distance_from_expected ||' of '|| expected.to_string_report(); + begin + return (self as ut_matcher).failure_message(a_actual) || ' '||self.distance_from_expected.to_string ||' of '|| expected.to_string_report(); end; overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 is l_result varchar2(32767); - begin - return (self as ut_matcher).failure_message_when_negated(a_actual) || ': '|| expected.to_string_report(); + begin + return (self as ut_matcher).failure_message_when_negated(a_actual) || ' '||self.distance_from_expected.to_string ||' of '|| expected.to_string_report(); end; end; diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index 710e8f68c..4c25872f5 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -695,35 +695,35 @@ create or replace type body ut_expectation as end; member function to_be_within(a_dist natural) return ut_be_within is - l_result ut_matcher; + l_result ut_be_within; begin l_result := ut_be_within(a_dist); l_result.expectation := self; - return treat(l_result as ut_be_within); + return l_result; end; member function to_be_within(a_dist dsinterval_unconstrained) return ut_be_within is - l_result ut_matcher; + l_result ut_be_within; begin l_result := ut_be_within(a_dist); l_result.expectation := self; - return treat(l_result as ut_be_within); + return l_result; end; member function to_be_within(a_dist yminterval_unconstrained) return ut_be_within is - l_result ut_matcher; + l_result ut_be_within; begin l_result := ut_be_within(a_dist); l_result.expectation := self; - return treat(l_result as ut_be_within); + return l_result; end; member function to_be_within_pct(a_dist natural) return ut_be_within_pct is - l_result ut_matcher; + l_result ut_be_within_pct; begin l_result := ut_be_within_pct(a_dist); l_result.expectation := self; - return treat(l_result as ut_be_within_pct); + return l_result; end; member function not_to_be_within(a_dist natural) return ut_be_within is @@ -731,7 +731,7 @@ create or replace type body ut_expectation as begin l_result := ut_be_within(a_dist).negated(); l_result.expectation := self; - return treat(l_result as ut_be_within); + return treat(l_result as ut_be_within); end; member function not_to_be_within(a_dist dsinterval_unconstrained) return ut_be_within is diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index cb1b3317b..b845bb26a 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -192,5 +192,20 @@ create or replace package body test_to_be_within is ut.expect(l_actual_message).to_be_like(l_expected_message); end; + procedure fail_msg_when_not_within is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + --Act + ut3_develop.ut.expect(1).to_be_within(3).of_(12); + --Assert + l_expected_message := q'[Actual: 1 (number) was expected to be within 3 of 12 (number)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + end; / diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pks b/test/ut3_user/expectations/binary/test_to_be_within.pks index 6c3406ac4..8aa6798e2 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pks +++ b/test/ut3_user/expectations/binary/test_to_be_within.pks @@ -12,20 +12,23 @@ create or replace package test_to_be_within is --%test(gives failure when number is not within distance) procedure failed_tests; - --%test(Check failure message for number not within) + --%test(check failure message for number not within) procedure fail_for_number_not_within; - --%test(Check failure message for inteval of 1 sec not within) + --%test(check failure message for inteval of 1 sec not within) procedure fail_for_ds_int_not_within; - --%test(Check failure message for custom ds interval not within) + --%test(check failure message for custom ds interval not within) procedure fail_for_custom_ds_int; - --%test(Check failure message for inteval of 1 month not within) + --%test(check failure message for inteval of 1 month not within) procedure fail_for_ym_int_not_within; - --%test(Check failure message for custom ym interval not within) + --%test(check failure message for custom ym interval not within) procedure fail_for_custom_ym_int; - + + --%test(check failure message for simple within) + procedure fail_msg_when_not_within; + end; / From 322e0a15c5ea5a8879ee92a6950b7bc1f24a840a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 19 Jun 2020 20:57:41 +0100 Subject: [PATCH 101/887] Making code a bit more readable --- source/expectations/matchers/ut_be_within.tpb | 43 ++++++++++++------- .../expectations/binary/test_to_be_within.pks | 12 +++--- 2 files changed, 34 insertions(+), 21 deletions(-) diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index 52fe6aef0..6f09f0392 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -75,26 +75,39 @@ create or replace type body ut_be_within as l_result.expected := ut_data_value_date(a_expected); return l_result; end; - + overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean is l_result boolean; + function l_result_from_number return boolean is + l_expected number := treat(self.expected as ut_data_value_number).data_value; + l_actual number := treat(a_actual as ut_data_value_number).data_value; + l_distance number := treat(self.distance_from_expected as ut_data_value_number).data_value; + begin + return abs(l_expected - l_actual) <= l_distance; + end; + + function l_result_from_date(a_distance ut_data_value) return boolean is + l_expected date := treat(self.expected as ut_data_value_date).data_value; + l_actual date := treat(a_actual as ut_data_value_date).data_value; + l_distance_ym yminterval_unconstrained := case when self.distance_from_expected is of ( ut_data_value_yminterval) + then treat(self.distance_from_expected as ut_data_value_yminterval).data_value + end; + l_distance_ds dsinterval_unconstrained := case when self.distance_from_expected is of ( ut_data_value_dsinterval) + then treat(self.distance_from_expected as ut_data_value_dsinterval).data_value + end; + begin + return case when l_distance_ym is not null + then l_actual between l_expected - l_distance_ym and l_expected + l_distance_ym + else l_actual between l_expected - l_distance_ds and l_expected + l_distance_ds + end; + end; + begin if self.expected.data_type = a_actual.data_type then if self.expected is of (ut_data_value_number) then - l_result := abs((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value)) <= - treat(self.distance_from_expected as ut_data_value_number).data_value; - elsif self.expected is of (ut_data_value_date) and self.distance_from_expected is of ( ut_data_value_yminterval) then - l_result := treat(a_actual as ut_data_value_date).data_value - between - (treat(self.expected as ut_data_value_date).data_value) - treat(self.distance_from_expected as ut_data_value_yminterval).data_value - and - (treat(self.expected as ut_data_value_date).data_value) + treat(self.distance_from_expected as ut_data_value_yminterval).data_value; - elsif self.expected is of (ut_data_value_date) and self.distance_from_expected is of ( ut_data_value_dsinterval) then - l_result := treat(a_actual as ut_data_value_date).data_value - between - (treat(self.expected as ut_data_value_date).data_value) - treat(self.distance_from_expected as ut_data_value_dsinterval).data_value - and - (treat(self.expected as ut_data_value_date).data_value) + treat(self.distance_from_expected as ut_data_value_dsinterval).data_value; + l_result := l_result_from_number; + elsif self.expected is of (ut_data_value_date)then + l_result := l_result_from_date(self.distance_from_expected); end if; else l_result := (self as ut_matcher).run_matcher(a_actual); diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pks b/test/ut3_user/expectations/binary/test_to_be_within.pks index 8aa6798e2..b2f456584 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pks +++ b/test/ut3_user/expectations/binary/test_to_be_within.pks @@ -12,22 +12,22 @@ create or replace package test_to_be_within is --%test(gives failure when number is not within distance) procedure failed_tests; - --%test(check failure message for number not within) + --%test(returns well formatted failure message when expectation fails) procedure fail_for_number_not_within; - --%test(check failure message for inteval of 1 sec not within) + --%test(returns well formatted failure message for inteval of 1 sec not within) procedure fail_for_ds_int_not_within; - --%test(check failure message for custom ds interval not within) + --%test(returns well formatted failure message for custom ds interval not within) procedure fail_for_custom_ds_int; - --%test(check failure message for inteval of 1 month not within) + --%test(returns well formatted failure message for inteval of 1 month not within) procedure fail_for_ym_int_not_within; - --%test(check failure message for custom ym interval not within) + --%test(returns well formatted failure message for custom ym interval not within) procedure fail_for_custom_ym_int; - --%test(check failure message for simple within) + --%test(returns well formatted failure message for simple within) procedure fail_msg_when_not_within; end; From ff15596a7c8c3b907136ea2e83bb52f33dff00ca Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 20 Jun 2020 21:57:10 +0100 Subject: [PATCH 102/887] Added tests for `be_within_pct` Reorganized code so that `be_within_pct` is only supported for `number` Added tests for non-supported syntax --- source/api/be_within_pct.syn | 1 + source/core/ut_expectation_processor.pkb | 1 + source/create_grants.sql | 1 + source/create_synonyms.sql | 1 + source/expectations/matchers/ut_be_within.tpb | 43 +--- source/expectations/matchers/ut_be_within.tps | 10 +- .../matchers/ut_be_within_pct.tpb | 46 ++++- .../matchers/ut_be_within_pct.tps | 16 +- source/install.sql | 5 +- source/uninstall_objects.sql | 2 + test/install_ut3_user_tests.sql | 2 + .../binary/test_to_be_within_pct.pkb | 184 ++++++++++++++++++ .../binary/test_to_be_within_pct.pks | 22 +++ 13 files changed, 280 insertions(+), 54 deletions(-) create mode 100644 source/api/be_within_pct.syn create mode 100644 test/ut3_user/expectations/binary/test_to_be_within_pct.pkb create mode 100644 test/ut3_user/expectations/binary/test_to_be_within_pct.pks diff --git a/source/api/be_within_pct.syn b/source/api/be_within_pct.syn new file mode 100644 index 000000000..40e3fb8b9 --- /dev/null +++ b/source/api/be_within_pct.syn @@ -0,0 +1 @@ +create synonym be_within_pct for ut_be_within_pct; diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index d65d210c8..4bf15ee55 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -183,6 +183,7 @@ create or replace package body ut_expectation_processor as ); end; begin +-- dbms_output.put_line(a_call_stack); l_call_stack := cut_header_and_expectations( a_call_stack ); l_call_stack := cut_address_columns( l_call_stack ); l_call_stack := cut_framework_stack( l_call_stack ); diff --git a/source/create_grants.sql b/source/create_grants.sql index 111294cef..d2f51e121 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -88,6 +88,7 @@ grant execute on &&ut3_owner..ut_be_not_null to &ut3_user; grant execute on &&ut3_owner..ut_be_null to &ut3_user; grant execute on &&ut3_owner..ut_be_true to &ut3_user; grant execute on &&ut3_owner..ut_be_within to &ut3_user; +grant execute on &&ut3_owner..ut_be_within_pct to &ut3_user; grant execute on &&ut3_owner..ut_contain to &ut3_user; grant execute on &&ut3_owner..ut_equal to &ut3_user; grant execute on &&ut3_owner..ut_have_count to &ut3_user; diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index 53e2bb65f..7b04dacd0 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -104,6 +104,7 @@ create &action_type. synonym &ut3_user.be_not_null for &&ut3_owner..be_not_null; create &action_type. synonym &ut3_user.be_null for &&ut3_owner..be_null; create &action_type. synonym &ut3_user.be_true for &&ut3_owner..be_true; create &action_type. synonym &ut3_user.be_within for &&ut3_owner..be_within; +create &action_type. synonym &ut3_user.be_within_pct for &&ut3_owner..be_within_pct; create &action_type. synonym &ut3_user.contain for &&ut3_owner..contain; create &action_type. synonym &ut3_user.equal for &&ut3_owner..equal; create &action_type. synonym &ut3_user.have_count for &&ut3_owner..have_count; diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index 6f09f0392..40bcfbab0 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -16,41 +16,24 @@ create or replace type body ut_be_within as limitations under the License. */ - member procedure init(self in out nocopy ut_be_within, a_distance_from_expected ut_data_value) is - begin - self.distance_from_expected := a_distance_from_expected; - self.self_type := $$plsql_unit; - end; - constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected number) return self as result is begin - init(ut_data_value_number(a_distance_from_expected)); + self.init(ut_data_value_number(a_distance_from_expected), $$plsql_unit); return; end; constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected dsinterval_unconstrained) return self as result is begin - init(ut_data_value_dsinterval(a_distance_from_expected)); + self.init(ut_data_value_dsinterval(a_distance_from_expected), $$plsql_unit); return; end; - + constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained) return self as result is begin - init(ut_data_value_yminterval(a_distance_from_expected)); + self.init(ut_data_value_yminterval(a_distance_from_expected), $$plsql_unit); return; end; - member procedure of_(self in ut_be_within, a_expected number) is - l_result ut_be_within := self; - begin - l_result.expected := ut_data_value_number(a_expected); - if l_result.is_negated_flag = 1 then - l_result.expectation.not_to(l_result ); - else - l_result.expectation.to_(l_result ); - end if; - end; - member procedure of_(self in ut_be_within, a_expected date) is l_result ut_be_within := self; begin @@ -62,13 +45,6 @@ create or replace type body ut_be_within as end if; end; - member function of_(self in ut_be_within, a_expected number) return ut_be_within is - l_result ut_be_within := self; - begin - l_result.expected := ut_data_value_number(a_expected); - return l_result; - end; - member function of_(self in ut_be_within, a_expected date) return ut_be_within is l_result ut_be_within := self; begin @@ -96,7 +72,7 @@ create or replace type body ut_be_within as then treat(self.distance_from_expected as ut_data_value_dsinterval).data_value end; begin - return case when l_distance_ym is not null + return case when l_distance_ym is not null then l_actual between l_expected - l_distance_ym and l_expected + l_distance_ym else l_actual between l_expected - l_distance_ds and l_expected + l_distance_ds end; @@ -116,15 +92,14 @@ create or replace type body ut_be_within as end; overriding member function failure_message(a_actual ut_data_value) return varchar2 is - begin + begin return (self as ut_matcher).failure_message(a_actual) || ' '||self.distance_from_expected.to_string ||' of '|| expected.to_string_report(); end; overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 is - l_result varchar2(32767); - begin + begin return (self as ut_matcher).failure_message_when_negated(a_actual) || ' '||self.distance_from_expected.to_string ||' of '|| expected.to_string_report(); - end; - + end; + end; / diff --git a/source/expectations/matchers/ut_be_within.tps b/source/expectations/matchers/ut_be_within.tps index 55f32bc4e..5090d3414 100644 --- a/source/expectations/matchers/ut_be_within.tps +++ b/source/expectations/matchers/ut_be_within.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_within under ut_comparison_matcher( +create or replace type ut_be_within under ut_be_within_pct( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -17,19 +17,11 @@ create or replace type ut_be_within under ut_comparison_matcher( */ - /** - * Holds information about mather options - */ - distance_from_expected ut_data_value, - member procedure init(self in out nocopy ut_be_within, a_distance_from_expected ut_data_value), constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected number) return self as result, constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected dsinterval_unconstrained) return self as result, constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained) return self as result, - member procedure of_(self in ut_be_within, a_expected number), member procedure of_(self in ut_be_within, a_expected date), - member function of_(self in ut_be_within, a_expected number) return ut_be_within, member function of_(self in ut_be_within, a_expected date) return ut_be_within, - overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean, overriding member function failure_message(a_actual ut_data_value) return varchar2, overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 diff --git a/source/expectations/matchers/ut_be_within_pct.tpb b/source/expectations/matchers/ut_be_within_pct.tpb index 326197fe6..bf662c066 100644 --- a/source/expectations/matchers/ut_be_within_pct.tpb +++ b/source/expectations/matchers/ut_be_within_pct.tpb @@ -16,21 +16,45 @@ create or replace type body ut_be_within_pct as limitations under the License. */ - constructor function ut_be_within_pct(self in out nocopy ut_be_within_pct, a_distance_from_expected number) return self as result is + constructor function ut_be_within_pct(self in out nocopy ut_be_within_pct, a_pct_of_expected number) return self as result is begin - self.init(ut_data_value_number(a_distance_from_expected)); + self.init(ut_data_value_number(a_pct_of_expected), $$plsql_unit); return; end; + member procedure init(self in out nocopy ut_be_within_pct, a_distance_from_expected ut_data_value, self_type varchar2) is + begin + self.distance_from_expected := a_distance_from_expected; + self.self_type := self_type; + end; + + member procedure of_(self in ut_be_within_pct, a_expected number) is + l_result ut_be_within_pct := self; + begin + l_result.expected := ut_data_value_number(a_expected); + if l_result.is_negated_flag = 1 then + l_result.expectation.not_to(l_result ); + else + l_result.expectation.to_(l_result ); + end if; + end; + + member function of_(self in ut_be_within_pct, a_expected number) return ut_be_within_pct is + l_result ut_be_within_pct := self; + begin + l_result.expected := ut_data_value_number(a_expected); + return l_result; + end; + overriding member function run_matcher(self in out nocopy ut_be_within_pct, a_actual ut_data_value) return boolean is l_result boolean; begin if self.expected.data_type = a_actual.data_type then if self.expected is of (ut_data_value_number) then - l_result := treat(self.distance_from_expected as ut_data_value_number).data_value >= - ( - ((treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ) / - (treat(self.expected as ut_data_value_number).data_value)) ; + l_result := + treat(self.distance_from_expected as ut_data_value_number).data_value + >= ( ( treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ) / + treat(self.expected as ut_data_value_number).data_value; end if; else l_result := (self as ut_matcher).run_matcher(a_actual); @@ -38,5 +62,15 @@ create or replace type body ut_be_within_pct as return l_result; end; + overriding member function failure_message(a_actual ut_data_value) return varchar2 is + begin + return rtrim( (self as ut_matcher).failure_message(a_actual), 'pct' ) || self.distance_from_expected.to_string ||' % of '|| expected.to_string_report(); + end; + + overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 is + begin + return rtrim( (self as ut_matcher).failure_message_when_negated(a_actual), 'pct' ) || self.distance_from_expected.to_string ||' % of '|| expected.to_string_report(); + end; + end; / diff --git a/source/expectations/matchers/ut_be_within_pct.tps b/source/expectations/matchers/ut_be_within_pct.tps index b47c7a9fd..b1c7e4dfc 100644 --- a/source/expectations/matchers/ut_be_within_pct.tps +++ b/source/expectations/matchers/ut_be_within_pct.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_within_pct under ut_be_within( +create or replace type ut_be_within_pct under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -17,8 +17,18 @@ create or replace type ut_be_within_pct under ut_be_within( */ - constructor function ut_be_within_pct(self in out nocopy ut_be_within_pct, a_distance_from_expected number) return self as result, - overriding member function run_matcher(self in out nocopy ut_be_within_pct, a_actual ut_data_value) return boolean + /** + * Holds information about mather options + */ + distance_from_expected ut_data_value, + + constructor function ut_be_within_pct(self in out nocopy ut_be_within_pct, a_pct_of_expected number) return self as result, + member procedure init(self in out nocopy ut_be_within_pct, a_distance_from_expected ut_data_value, self_type varchar2), + member procedure of_(self in ut_be_within_pct, a_expected number), + member function of_(self in ut_be_within_pct, a_expected number) return ut_be_within_pct, + overriding member function run_matcher(self in out nocopy ut_be_within_pct, a_actual ut_data_value) return boolean, + overriding member function failure_message(a_actual ut_data_value) return varchar2, + overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 ) not final / diff --git a/source/install.sql b/source/install.sql index af639ac78..a3cf2c3d8 100644 --- a/source/install.sql +++ b/source/install.sql @@ -240,8 +240,8 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/ut_expectation_base.tps' @@install_component.sql 'expectations/matchers/ut_matcher.tps' @@install_component.sql 'expectations/matchers/ut_comparison_matcher.tps' -@@install_component.sql 'expectations/matchers/ut_be_within.tps' @@install_component.sql 'expectations/matchers/ut_be_within_pct.tps' +@@install_component.sql 'expectations/matchers/ut_be_within.tps' @@install_component.sql 'expectations/ut_expectation.tps' @@install_component.sql 'expectations/matchers/ut_be_false.tps' @@install_component.sql 'expectations/matchers/ut_be_greater_or_equal.tps' @@ -297,8 +297,8 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/matchers/ut_be_null.tpb' @@install_component.sql 'expectations/matchers/ut_be_true.tpb' @@install_component.sql 'expectations/matchers/ut_equal.tpb' -@@install_component.sql 'expectations/matchers/ut_be_within.tpb' @@install_component.sql 'expectations/matchers/ut_be_within_pct.tpb' +@@install_component.sql 'expectations/matchers/ut_be_within.tpb' @@install_component.sql 'expectations/matchers/ut_contain.tpb' @@install_component.sql 'expectations/matchers/ut_have_count.tpb' @@install_component.sql 'expectations/matchers/ut_be_between.tpb' @@ -362,6 +362,7 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'api/be_not_null.syn' @@install_component.sql 'api/be_null.syn' @@install_component.sql 'api/be_true.syn' +@@install_component.sql 'api/be_within_pct.syn' @@install_component.sql 'api/be_within.syn' @@install_component.sql 'api/equal.syn' @@install_component.sql 'api/have_count.syn' diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 82d8a7e5a..ee76cb8eb 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -56,6 +56,8 @@ drop synonym equal; drop synonym be_within; +drop synonym be_within_pct; + drop type ut_coveralls_reporter force; drop type ut_coverage_sonar_reporter force; diff --git a/test/install_ut3_user_tests.sql b/test/install_ut3_user_tests.sql index 1330a7f75..8431c69ed 100644 --- a/test/install_ut3_user_tests.sql +++ b/test/install_ut3_user_tests.sql @@ -26,6 +26,7 @@ prompt Install user tests @@ut3_user/expectations/binary/test_be_greater_or_equal.pks @@ut3_user/expectations/binary/test_be_greater_than.pks @@ut3_user/expectations/binary/test_to_be_within.pks +@@ut3_user/expectations/binary/test_to_be_within_pct.pks @@ut3_user/expectations/test_matchers.pks @@ut3_user/expectations/test_expectation_anydata.pks @@ut3_user/expectations/test_expectations_cursor.pks @@ -68,6 +69,7 @@ set define off @@ut3_user/expectations/binary/test_be_greater_or_equal.pkb @@ut3_user/expectations/binary/test_be_greater_than.pkb @@ut3_user/expectations/binary/test_to_be_within.pkb +@@ut3_user/expectations/binary/test_to_be_within_pct.pkb @@ut3_user/expectations/test_matchers.pkb @@ut3_user/expectations/test_expectation_anydata.pkb @@ut3_user/expectations/test_expectations_cursor.pkb diff --git a/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb new file mode 100644 index 000000000..728cdeec6 --- /dev/null +++ b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb @@ -0,0 +1,184 @@ +create or replace package body test_to_be_within_pct is + + procedure cleanup_expectations is + begin + ut3_tester_helper.main_helper.clear_expectations( ); + end; + + function be_within_expectation_block( + a_matcher varchar2, + a_actual_type varchar2, + a_actual varchar2, + a_expected_type varchar2, + a_expected varchar2, + a_distance varchar2, + a_distance_type varchar2, + a_matcher_end varchar2 + ) return varchar2 + is + l_execute varchar2(32000); + begin + l_execute := ' + declare + l_actual '||a_actual_type||' := '||a_actual||'; + l_expected '||a_expected_type||' := '||a_expected||'; + l_distance '||a_distance_type||' := '||a_distance||'; + begin + --act - execute the expectation + ut3_develop.ut.expect( l_actual ).'||a_matcher||'( l_distance ).of_( l_expected )'||a_matcher_end||'; + end;'; + return l_execute; + end; + + procedure test_to_be_within_fail( + a_matcher varchar2, + a_actual_type varchar2, + a_actual varchar2, + a_expected_type varchar2, + a_expected varchar2, + a_distance varchar2, + a_distance_type varchar2, + a_failure_message varchar2 := null, + a_matcher_end varchar2 := null + ) is + l_failure_text varchar2(4000); + begin + execute immediate be_within_expectation_block( + a_matcher,a_actual_type, a_actual, a_expected_type, a_expected, + a_distance,a_distance_type, a_matcher_end + ); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(1); + if a_failure_message is not null then + l_failure_text := ut3_tester_helper.main_helper.get_failed_expectations(1); + ut.expect( l_failure_text ).to_be_like('%'||a_failure_message||'%' ); + end if; + cleanup_expectations; + end; + + procedure test_to_be_within_success( + a_matcher varchar2, + a_actual_type varchar2, + a_actual varchar2, + a_expected_type varchar2, + a_expected varchar2, + a_distance varchar2, + a_distance_type varchar2, + a_matcher_end varchar2 := null + ) is + begin + execute immediate be_within_expectation_block( + a_matcher,a_actual_type, a_actual, a_expected_type, a_expected, + a_distance,a_distance_type, a_matcher_end + ); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + cleanup_expectations; + end; + + + procedure test_to_be_within_error( + a_matcher varchar2, + a_actual_type varchar2, + a_actual varchar2, + a_expected_type varchar2, + a_expected varchar2, + a_distance varchar2, + a_distance_type varchar2, + a_error_message varchar2, + a_matcher_end varchar2 := null + ) is + begin + execute immediate be_within_expectation_block( + a_matcher,a_actual_type, a_actual, a_expected_type, a_expected, + a_distance,a_distance_type, a_matcher_end + ); + cleanup_expectations; + ut.fail('Expected exception but nothing was raised'); + exception + when others then + ut.expect(sqlerrm).to_be_like('%'||a_error_message||'%'); + cleanup_expectations; + end; + + + procedure expect_success is + begin + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + cleanup_expectations; + end; + + procedure expect_failure is + begin + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(1); + cleanup_expectations; + end; + + procedure success_tests is + begin + ut3_develop.ut.expect( 2.987654321 ).to_be_within_pct( 1 ).of_(3); + expect_success; + + ut3_develop.ut.expect( 2.987654321 ).to_( ut3_develop.be_within_pct( 1 ).of_(3) ); + expect_success; + + ut3_develop.ut.expect( 2.987654321 ).not_to_be_within_pct( 0.1 ).of_(3); + expect_success; + + ut3_develop.ut.expect( 2.987654321 ).not_to( ut3_develop.be_within_pct( 0.1 ).of_(3) ); + expect_success; + end; + + procedure failed_tests is + begin + ut3_develop.ut.expect( 2.987654321 ).to_be_within_pct( 0.1 ).of_(3); + expect_failure; + + ut3_develop.ut.expect( 2.987654321 ).to_( ut3_develop.be_within_pct( 0.1 ).of_(3) ); + expect_failure; + + ut3_develop.ut.expect( 2.987654321 ).not_to_be_within_pct( 1 ).of_(3); + expect_failure; + + ut3_develop.ut.expect( 2.987654321 ).not_to( ut3_develop.be_within_pct( 1 ).of_(3) ); + expect_failure; + end; + + procedure fail_for_number_not_within is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + --Act + ut3_develop.ut.expect(4).to_be_within_pct(1).of_(7); + --Assert + l_expected_message := q'[Actual: 4 (number) was expected to be within 1 % of 7 (number)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure fail_to_compile_for_types is + begin + test_to_be_within_error( + 'to_be_within_pct','date', 'sysdate', 'date','sysdate', + '''0 0:00:11.333''','interval day to second', + 'wrong number or types of arguments in call to ''TO_BE_WITHIN_PCT''' + ); + test_to_be_within_error( + 'to_be_within_pct','number','1', 'date', 'sysdate', + '1','number', + ' wrong number or types of arguments in call to ''OF_''' + ); + test_to_be_within_error( + 'to_be_within_pct','number','1','number','1', + 'sysdate', 'date', + ' wrong number or types of arguments in call to ''TO_BE_WITHIN_PCT''' + ); + test_to_be_within_fail( + 'to_be_within_pct','date', 'sysdate', 'number','1', + '1','number', + 'Actual (date) cannot be compared to Expected (number) using matcher ''be within pct''' + ); + end; + +end; +/ diff --git a/test/ut3_user/expectations/binary/test_to_be_within_pct.pks b/test/ut3_user/expectations/binary/test_to_be_within_pct.pks new file mode 100644 index 000000000..6203d48e3 --- /dev/null +++ b/test/ut3_user/expectations/binary/test_to_be_within_pct.pks @@ -0,0 +1,22 @@ +create or replace package test_to_be_within_pct is + + --%suite((not)to_be_within_pct) + --%suitepath(utplsql.test_user.expectations.binary) + + --%aftereach + procedure cleanup_expectations; + + --%test(gives success for values within a distance) + procedure success_tests; + + --%test(gives failure when number is not within distance) + procedure failed_tests; + + --%test(returns well formatted failure message when expectation fails) + procedure fail_for_number_not_within; + + --%test(fails at compile or run time for unsupported data-types ) + procedure fail_in_invalid_argument_types; + +end; +/ From 3cae9a2d75311abda3c8cdd736848615682dddd9 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 20 Jun 2020 22:20:28 +0100 Subject: [PATCH 103/887] Fixed test issue --- .../binary/test_to_be_within_pct.pkb | 17 ++++++----------- .../binary/test_to_be_within_pct.pks | 2 +- 2 files changed, 7 insertions(+), 12 deletions(-) diff --git a/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb index 728cdeec6..a184c3728 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb @@ -143,20 +143,15 @@ create or replace package body test_to_be_within_pct is end; procedure fail_for_number_not_within is - l_actual_message varchar2(32767); - l_expected_message varchar2(32767); begin - --Arrange - --Act - ut3_develop.ut.expect(4).to_be_within_pct(1).of_(7); - --Assert - l_expected_message := q'[Actual: 4 (number) was expected to be within 1 % of 7 (number)]'; - l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); - --Assert - ut.expect(l_actual_message).to_be_like(l_expected_message); + test_to_be_within_fail( + 'to_be_within_pct','number', '4', 'number','7', + '1','number', + q'[Actual: 4 (number) was expected to be within 1 % of 7 (number)]' + ); end; - procedure fail_to_compile_for_types is + procedure fail_at_invalid_argument_types is begin test_to_be_within_error( 'to_be_within_pct','date', 'sysdate', 'date','sysdate', diff --git a/test/ut3_user/expectations/binary/test_to_be_within_pct.pks b/test/ut3_user/expectations/binary/test_to_be_within_pct.pks index 6203d48e3..4b8f0cb4c 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within_pct.pks +++ b/test/ut3_user/expectations/binary/test_to_be_within_pct.pks @@ -16,7 +16,7 @@ create or replace package test_to_be_within_pct is procedure fail_for_number_not_within; --%test(fails at compile or run time for unsupported data-types ) - procedure fail_in_invalid_argument_types; + procedure fail_at_invalid_argument_types; end; / From 22549db1c0aaa2d34c43d8365de6e6023807247d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 21 Jun 2020 12:11:58 +0100 Subject: [PATCH 104/887] Fixed stacktrace for failed expectations on chained matchers. --- source/core/ut_expectation_processor.pkb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index 4bf15ee55..7e1217acf 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -159,7 +159,7 @@ create or replace package body ut_expectation_processor as -- when 11g and 12c reports only package name function cut_header_and_expectations( a_stack varchar2 ) return varchar2 is begin - return regexp_substr( a_stack, '(.*\.(UT_EXPECTATION[A-Z0-9#_$]*|UT|UTASSERT2?)(\.[A-Z0-9#_$]+)?\s+)+((.|\s)*)', 1, 1, 'm', 4); + return regexp_substr( a_stack, '(.*\.(UT_EQUAL|UT_BE_WITHIN[A-Z0-9#_$]*|UT_EXPECTATION[A-Z0-9#_$]*|UT|UTASSERT2?)(\.[A-Z0-9#_$]+)?\s+)+((.|\s)*)', 1, 1, 'm', 4); end; function cut_address_columns( a_stack varchar2 ) return varchar2 is begin @@ -183,7 +183,6 @@ create or replace package body ut_expectation_processor as ); end; begin --- dbms_output.put_line(a_call_stack); l_call_stack := cut_header_and_expectations( a_call_stack ); l_call_stack := cut_address_columns( l_call_stack ); l_call_stack := cut_framework_stack( l_call_stack ); From e9e4b9ed3d5dd9f65f5f52dd080920ca4eefc1ff Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 21 Jun 2020 14:18:27 +0100 Subject: [PATCH 105/887] Reorganized and cleaned up tests to have only one package used for coverage tests. --- test/ut3_tester_helper/coverage_helper.pkb | 36 +------- test/ut3_tester_helper/coverage_helper.pks | 8 +- .../test_coverage_standalone.pkb | 88 +++++++++++-------- .../test_coverage_standalone.pks | 5 +- 4 files changed, 56 insertions(+), 81 deletions(-) diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 67bef571a..9b595a0b3 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -20,10 +20,7 @@ create or replace package body coverage_helper is $end end; - function substitute_covered_package( - a_text varchar2, - a_substitution varchar2 - ) return varchar2 is + function substitute_covered_package( a_text varchar2, a_substitution varchar2 ) return varchar2 is begin return replace( replace( a_text, a_substitution, covered_package_name() ), upper(a_substitution), upper(covered_package_name()) ); end; @@ -126,39 +123,10 @@ create or replace package body coverage_helper is begin execute immediate q'[drop package ut3_develop.test_dummy_coverage_1]'; exception when others then null; end; end; - procedure create_coverage_pkg is - pragma autonomous_transaction; - begin - execute immediate 'alter session set plsql_optimize_level=0'; - execute immediate q'[create or replace package coverage_pkg as - function run_some_branching_code(a_input integer) return integer; - end;]'; - execute immediate q'[create or replace package body coverage_pkg as - function run_some_branching_code(a_input integer) return integer is - l_result integer; - begin - if a_input = 1 then return -1; elsif a_input = 2 then return 0; - else - return a_input; - end if; - end; - end;]'; - execute immediate 'grant debug on coverage_pkg to ut3$user#'; - end; - - procedure drop_coverage_pkg is - pragma autonomous_transaction; - begin - execute immediate q'[drop package coverage_pkg]'; - end; - - - procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer) is - x integer; begin ut3_develop.ut_runner.coverage_start(a_coverage_run_id); - execute immediate 'begin :x := coverage_pkg.run_some_branching_code(:a_input); end;' using out x, in a_input; + execute immediate 'begin ut3_develop.'||covered_package_name||'.do_stuff(:a_input); end;' using in a_input; ut3_develop.ut_runner.coverage_stop(); end; diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index 470b1971d..b044c897b 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -4,10 +4,7 @@ create or replace package coverage_helper is function covered_package_name return varchar2; - function substitute_covered_package( - a_text varchar2, - a_substitution varchar2 := '{p}' - ) return varchar2; + function substitute_covered_package( a_text varchar2, a_substitution varchar2 := '{p}' ) return varchar2; procedure set_develop_mode; @@ -20,9 +17,6 @@ create or replace package coverage_helper is procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer); procedure run_coverage_job(a_coverage_run_id raw, a_input integer); - procedure create_coverage_pkg; - procedure drop_coverage_pkg; - function run_tests_as_job( a_run_command varchar2 ) return clob; function run_code_as_job( a_plsql_block varchar2 ) return clob; procedure create_test_results_table; diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index 8816d4895..6ec700b16 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -1,28 +1,52 @@ create or replace package body test_coverage_standalone is - procedure coverage_without_ut_run is - l_coverage_run_id raw(32) := sys_guid(); - l_actual ut3_develop.ut_varchar2_list; + function run_coverage_twice(a_overage_run_id raw, a_object_name varchar2) return clob is l_expected clob; l_block_cov clob; + l_file_path varchar2(250); begin + l_file_path := 'ut3_develop.'||a_object_name; --Arrange if ut3_tester_helper.coverage_helper.block_coverage_available then - l_block_cov := '%'; + l_block_cov := ''; else - l_block_cov := '%'; + l_block_cov := ''; end if; - l_expected := '%ut3_tester_helper.coverage_pkg' || - '%' || - l_block_cov || - '%%'; - --Act - ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 1); - ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 3); + l_expected := + q'[ + + + +]'||l_file_path||q'[ + + + + + +]'||l_block_cov||q'[ + + + + + +]'; + --Act + ut3_tester_helper.coverage_helper.run_coverage_job(a_overage_run_id, 1); + ut3_tester_helper.coverage_helper.run_coverage_job(a_overage_run_id, 3); + return l_expected; + end; + + procedure coverage_without_ut_run is + l_coverage_run_id raw(32) := sys_guid(); + l_actual ut3_develop.ut_varchar2_list; + l_expected clob; + l_name varchar2(250); + begin + l_name := ut3_tester_helper.coverage_helper.covered_package_name; + + --Arrange and Act + l_expected := run_coverage_twice(l_coverage_run_id, l_name); - --Assert select * bulk collect into l_actual from @@ -30,11 +54,13 @@ create or replace package body test_coverage_standalone is ut3_develop.ut_coverage_cobertura_reporter( ).get_report( ut3_develop.ut_coverage_options( coverage_run_id => l_coverage_run_id, - include_objects => ut3_develop.ut_varchar2_rows('COVERAGE_PKG'), - schema_names => ut3_develop.ut_varchar2_rows('UT3_TESTER_HELPER') + include_objects => ut3_develop.ut_varchar2_rows(l_name), + schema_names => ut3_develop.ut_varchar2_rows('UT3_DEVELOP') ) ) ); + + --Assert ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_actual)).to_be_like( l_expected ); end; @@ -43,35 +69,25 @@ create or replace package body test_coverage_standalone is l_coverage_cursor sys_refcursor; l_actual ut3_develop.ut_varchar2_list; l_expected clob; - l_block_cov clob; + l_name varchar2(250); begin - --Arrange - if ut3_tester_helper.coverage_helper.block_coverage_available then - l_block_cov := '%'; - else - l_block_cov := '%'; - end if; - l_expected := '%ut3_tester_helper.coverage_pkg' || - '%' || - l_block_cov || - '%%'; - --Act - ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 1); - ut3_tester_helper.coverage_helper.run_coverage_job(l_coverage_run_id, 3); + l_name := ut3_tester_helper.coverage_helper.covered_package_name; + + --Arrange and Act + l_expected := run_coverage_twice(l_coverage_run_id, l_name); - --Assert l_coverage_cursor := ut3_develop.ut_coverage_cobertura_reporter( ).get_report_cursor( ut3_develop.ut_coverage_options( coverage_run_id => l_coverage_run_id, - include_objects => ut3_develop.ut_varchar2_rows('COVERAGE_PKG'), - schema_names => ut3_develop.ut_varchar2_rows('UT3_TESTER_HELPER') + include_objects => ut3_develop.ut_varchar2_rows(l_name), + schema_names => ut3_develop.ut_varchar2_rows('UT3_DEVELOP') ) ); fetch l_coverage_cursor bulk collect into l_actual; close l_coverage_cursor; + + --Assert ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_actual)).to_be_like( l_expected ); end; diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks index 69aae3f25..1d5bb9a2c 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pks @@ -1,10 +1,7 @@ create or replace package test_coverage_standalone authid current_user is --%suite - --%suitepath(utplsql.test_user.reporters) - - --%beforeall(ut3_tester_helper.coverage_helper.create_coverage_pkg) - --%afterall(ut3_tester_helper.coverage_helper.drop_coverage_pkg) + --%suitepath(utplsql.test_user.reporters.test_coverage) --%test(Coverage can be invoked standalone in multiple sessions and a combined report can be produced at the end) procedure coverage_without_ut_run; From a4ae4cf875cf7e925d7c7634786a4811474bc8a5 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 21 Jun 2020 15:48:48 +0100 Subject: [PATCH 106/887] Removed dead code. --- source/core/coverage/ut_coverage_helper_block.pkb | 7 ------- 1 file changed, 7 deletions(-) diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index b81292017..1ded434ba 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -16,13 +16,6 @@ create or replace package body ut_coverage_helper_block is limitations under the License. */ - type t_proftab_row is record ( - line binary_integer, - calls number(38,0) - ); - - type t_proftab_rows is table of t_proftab_row; - type t_block_row is record( line binary_integer ,blocks binary_integer From 0e72abc1198ff3bdc585ef4bb1c0f5611b834419 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 21 Jun 2020 20:59:24 +0100 Subject: [PATCH 107/887] Added support for client_character_set as report parameter. --- .../coverage/ut_coverage_reporter_base.tpb | 8 +++---- .../coverage/ut_coverage_reporter_base.tps | 4 ++-- .../test_coverage_standalone.pkb | 22 +++++++++++-------- 3 files changed, 19 insertions(+), 15 deletions(-) diff --git a/source/core/coverage/ut_coverage_reporter_base.tpb b/source/core/coverage/ut_coverage_reporter_base.tpb index 6300348e0..96c4b5066 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tpb +++ b/source/core/coverage/ut_coverage_reporter_base.tpb @@ -86,12 +86,12 @@ create or replace type body ut_coverage_reporter_base is ut_coverage.coverage_pause(); end; - final member function get_report( a_coverage_options ut_coverage_options ) return ut_varchar2_rows pipelined is + final member function get_report( a_coverage_options ut_coverage_options, a_client_character_set varchar2 := null ) return ut_varchar2_rows pipelined is l_reporter ut_coverage_reporter_base := self; begin ut_coverage_helper.cleanup_tmp_table(); (l_reporter as ut_output_reporter_base).before_calling_run(null); - l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options ) ); + l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options, a_client_character_set => a_client_character_set ) ); l_reporter.on_finalize(null); for i in (select x.text from table(l_reporter.get_lines(1, 1)) x ) loop pipe row (i.text); @@ -99,13 +99,13 @@ create or replace type body ut_coverage_reporter_base is return; end; - final member function get_report_cursor( a_coverage_options ut_coverage_options ) return sys_refcursor is + final member function get_report_cursor( a_coverage_options ut_coverage_options, a_client_character_set varchar2 := null ) return sys_refcursor is l_reporter ut_coverage_reporter_base := self; l_result sys_refcursor; begin ut_coverage_helper.cleanup_tmp_table(); (l_reporter as ut_output_reporter_base).before_calling_run(null); - l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options ) ); + l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options, a_client_character_set => a_client_character_set ) ); l_reporter.on_finalize(null); open l_result for select x.text from table(l_reporter.get_lines(1, 1)) x; return l_result; diff --git a/source/core/coverage/ut_coverage_reporter_base.tps b/source/core/coverage/ut_coverage_reporter_base.tps index 039bbe320..cae165258 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tps +++ b/source/core/coverage/ut_coverage_reporter_base.tps @@ -37,8 +37,8 @@ create or replace type ut_coverage_reporter_base under ut_output_reporter_base( overriding final member procedure before_calling_after_all(self in out nocopy ut_coverage_reporter_base, a_executable in ut_executable), overriding final member procedure after_calling_after_all (self in out nocopy ut_coverage_reporter_base, a_executable in ut_executable), - final member function get_report(a_coverage_options ut_coverage_options ) return ut_varchar2_rows pipelined, - final member function get_report_cursor(a_coverage_options ut_coverage_options ) return sys_refcursor + final member function get_report( a_coverage_options ut_coverage_options, a_client_character_set varchar2 := null ) return ut_varchar2_rows pipelined, + final member function get_report_cursor( a_coverage_options ut_coverage_options, a_client_character_set varchar2 := null ) return sys_refcursor ) not final not instantiable / diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index 6ec700b16..ef7014235 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -1,6 +1,6 @@ create or replace package body test_coverage_standalone is - function run_coverage_twice(a_overage_run_id raw, a_object_name varchar2) return clob is + function run_coverage_twice(a_overage_run_id raw, a_object_name varchar2, a_charset varchar2) return clob is l_expected clob; l_block_cov clob; l_file_path varchar2(250); @@ -13,7 +13,7 @@ create or replace package body test_coverage_standalone is l_block_cov := ''; end if; l_expected := - q'[ + q'[ @@ -41,22 +41,24 @@ create or replace package body test_coverage_standalone is l_actual ut3_develop.ut_varchar2_list; l_expected clob; l_name varchar2(250); + l_charset varchar2(100) := 'ISO-8859-1'; begin l_name := ut3_tester_helper.coverage_helper.covered_package_name; --Arrange and Act - l_expected := run_coverage_twice(l_coverage_run_id, l_name); + l_expected := run_coverage_twice(l_coverage_run_id, l_name, l_charset); select * bulk collect into l_actual from table ( - ut3_develop.ut_coverage_cobertura_reporter( ).get_report( - ut3_develop.ut_coverage_options( + ut3_develop.ut_coverage_cobertura_reporter().get_report( + a_coverage_options => ut3_develop.ut_coverage_options( coverage_run_id => l_coverage_run_id, include_objects => ut3_develop.ut_varchar2_rows(l_name), schema_names => ut3_develop.ut_varchar2_rows('UT3_DEVELOP') - ) + ), + a_client_character_set => l_charset ) ); @@ -70,19 +72,21 @@ create or replace package body test_coverage_standalone is l_actual ut3_develop.ut_varchar2_list; l_expected clob; l_name varchar2(250); + l_charset varchar2(100) := 'ISO-8859-1'; begin l_name := ut3_tester_helper.coverage_helper.covered_package_name; --Arrange and Act - l_expected := run_coverage_twice(l_coverage_run_id, l_name); + l_expected := run_coverage_twice(l_coverage_run_id, l_name, l_charset); l_coverage_cursor := ut3_develop.ut_coverage_cobertura_reporter( ).get_report_cursor( - ut3_develop.ut_coverage_options( + a_coverage_options => ut3_develop.ut_coverage_options( coverage_run_id => l_coverage_run_id, include_objects => ut3_develop.ut_varchar2_rows(l_name), schema_names => ut3_develop.ut_varchar2_rows('UT3_DEVELOP') - ) + ), + a_client_character_set => l_charset ); fetch l_coverage_cursor bulk collect into l_actual; close l_coverage_cursor; From 955de5c2dc527a98a6f5dc0dd8bd8d81a44c459f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 21 Jun 2020 22:36:02 +0100 Subject: [PATCH 108/887] Made coverage_run_id mandatory in `ut_coverage_options` Added documentation --- docs/userguide/coverage.md | 143 ++++++++++++++++++++-- source/api/ut_runner.pkb | 1 + source/core/types/ut_coverage_options.tpb | 4 +- source/core/types/ut_coverage_options.tps | 2 +- 4 files changed, 134 insertions(+), 16 deletions(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 3b968ccc4..893c2e3a6 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,7 +1,7 @@ ![version](https://img.shields.io/badge/version-v3.1.11.3392--develop-blue.svg) # Coverage -utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. +utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. Code coverage is gathered for the following source types: * package bodies * type bodies @@ -11,9 +11,9 @@ Code coverage is gathered for the following source types: **Note** -> The package and type specifications are explicitly excluded from code coverage analysis. This limitation is introduced to avoid false-negatives. Typically package specifications contain no executable code. The only exception is initialization of global constants and variables in package specification. Since most package specifications are not executable at all, there is no information available on the number of lines covered and those would be reported as 0% covered, which is not desirable. +> The package and type specifications are excluded from code coverage analysis. This limitation is introduced to avoid false-negatives. Typically package specifications contain no executable code. The only exception is initialization of global constants and variables in package specification. Since most package specifications are not executable at all, there is no information available on the number of lines covered and those would be reported as 0% covered, which is not desirable. -To obtain information about code coverage of your unit tests, all you need to do is run your unit tests with one of built-in code coverage reporters. +To obtain information about code coverage for unit tests, run utPLSQL with one of built-in code coverage reporters. The following code coverage reporters are supplied with utPLSQL: * `ut_coverage_html_reporter` - generates a HTML coverage report providing summary and detailed information on code coverage. The HTML reporter is based on the open-source [simplecov-html](https://github.com/colszowka/simplecov-html) reporter for Ruby. It includes source code of the code that was covered (if possible) * `ut_coveralls_reporter` - generates a [Coveralls compatible JSON](https://coveralls.zendesk.com/hc/en-us/articles/201774865-API-Introduction) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by cloud services like [Coveralls](https://coveralls.io) @@ -33,8 +33,8 @@ If you have `execute` privilege only on the unit tests, but do not have `execute If the code that is being tested is complied as NATIVE, the code coverage will not be reported as well. ## Running unit tests with coverage -Using the code coverage functionality is as easy as using any other [reporter](reporters.md) for the utPLSQL project. You just run your tests from your preferred SQL tool and save the reporter results to a file. -All you need to do is pass the constructor of the reporter to your `ut.run` +Using the code coverage functionality is as easy as using any other [reporter](reporters.md) for the utPLSQL test-run. You just run your tests from your preferred SQL tool and save the reporter results to a file. +All you need to do is pass the constructor of the reporter to the `ut.run` procedure call. Example: ```sql @@ -43,10 +43,10 @@ begin end; / ``` -Executes all unit tests in the current schema, gathers information about code coverage and outputs the HTML text into DBMS_OUTPUT. +The above command executes all unit tests in the **current schema**, gathers information about code coverage and outputs the HTML report as text into DBMS_OUTPUT. The `ut_coverage_html_reporter` will produce an interactive HTML report. You can see a sample of code coverage for the utPLSQL project [here](https://utplsql.github.io/utPLSQL-coverage-html/) -The report provides summary information with a list of source code that was expected to be covered. +The report provides summary information with a list of source code that should be covered. ![Coverage Summary page](../images/coverage_html_summary.png) @@ -57,8 +57,8 @@ The report allow you to navigate to each source file and inspect line by line co #### Oracle 12.2 extended coverage with profiler and block coverage Using data collected from profiler and block coverage running parallel we are able to enrich information about coverage. -For every line recorded by profiler if we have a partially covered same line in block coverage we will display that information -presenting line as partially covered, displaying number of block and how many blocks been covered in that line.The feature will be automatically enabled in the Oracle database version 12.2 and higher, for older versions current profiler will be used. +For every line recorded by the profiler if we have a partially covered same line in block coverage we will display that information +presenting line as partially covered, displaying number of block and how many blocks have been covered in that line.The feature will be automatically enabled in the Oracle database version 12.2 and higher, for older versions current profiler will be used. utPLSQL installation automatically creates tables needed by `dbms_plsql_code_coverage` on databases in versions above 12c Release 1. Due to security model of `dbms_plsql_code_coverage` package, utPLSQL grants access to those tables and creates synonyms for those tables. @@ -92,7 +92,8 @@ The default behavior of coverage reporting can be altered using invocation param ### Schema based Coverage -To simply gather coverage for all objects in your current schema execute tests with coverage reporting. +To gather coverage for all objects in the **current schema** execute tests with coverage report as argument. +This is the default reporting option and therefore additional coverage options don't need to be provided. ```sql exec ut.run(ut_coverage_html_reporter()); @@ -109,7 +110,7 @@ exec ut.run(ut_coverage_html_reporter()); #### Setting coverage schema(s) By default, coverage is gathered on the schema(s) derived from suite paths provided to execute tests. -This is correct as long as your test packages and tested code share the same schema. +This is a valid approach as long as your test packages and tested code share the same schema. So when you run: ```sql @@ -531,8 +532,8 @@ Unit test code is mapped to files in `test_results.xml` In order to allow deterministic and accurate mapping of database source-code into project files, the project directory and file structure needs to meet certain criteria. - Source code is kept separate from test code (separate directories) -- Each database (source-code) object is stored in individual file. Package/type specification is kept separate from it's body. -- File name (file path) contains name of database object +- Each database (source-code) object is stored in an individual file. Package/type specification is kept separate from its body. +- File name (file path) contains the name of database object - Each file-path clearly identifies object type (by file extension) - Each file contains representation of database object "as is". No extra commands (like `set echo off` `ALTER SESSION SET PLSQL_CCFLAGS = 'debug:TRUE';`) or blank lines are present before `CREATE TYPE`,`CREATE TYPE` etc. - When project is spanning across multiple database schemes, each file-path clearly and uniformly identifies object owner @@ -659,3 +660,119 @@ begin end; ``` +## Reporting coverage outside of utPLSQL + +utPSLQL allows fo standalone reporting code coverage across multiple database sessions. This functionality enables coverage reporting for external testing tools. + +Following API calls enable the standalone coverage reporting. + +- `ut_runner.coverage_start( coverage_run_id );` - initiates code coverage within a session +- `ut_runner.coverage_stop();` - stops gathering of code coverage within a session +- `.get_report( ... )` - coverage reporters function producing coverage report as pipelined data-set (to be used in SQL query) +- `.get_report_cursor( ... )` - coverage reporters function producing coverage report as ref-cursor + +Example: +```sql +--SESSION 1 +-- gather coverage on code using specific coverage_run_id value +declare + l_coverage_run_id raw(32); +begin + l_coverage_run_id := 'A6AA5B7361251CE6E053020011ACA055'; +-- l_coverage_run_id := sys_guid; + ut_runner.coverage_start(l_coverage_run_id); + + --The code to gather coverage on goes here + + ut_runner.coverage_stop(); +end; +/ +``` + +```sql +--SESSION 2 +-- alternative approach +-- gather coverage on code using specific coverage_run_id value +exec ut_runner.coverage_start('A6AA5B7361251CE6E053020011ACA055'); + +--The code to gather coverage on goes here + +exec ut_runner.coverage_stop(); +``` + + +```sql +--SESSION 1 or SESSION2 2 or SESSION 3 +-- run after calls in SESSION 1 & 2 are finshed +-- retrieve coverage report in HTML format coverage_run_id value +select * + from table( + ut_coverage_html_reporter().get_report( + a_coverage_options => ut_coverage_options( + coverage_run_id => 'A6AA5B7361251CE6E053020011ACA055' + ) + ) + ); +``` + +```sql +--SESSION 1 or SESSION2 2 or SESSION 3 +-- run after calls in SESSION 1 & 2 are finshed +declare + l_results_cursor sys_refcursor; +begin + l_results_cursor := ut_coverage_html_reporter().get_report_cursor( + a_coverage_options => ut_coverage_options( + coverage_run_id => 'A6AA5B7361251CE6E053020011ACA055' + ) + ); + --fetch and process the cursor results + close l_results_cursor; +end; +/ +``` + +Specification of parameters for `get_report` and `get_report_cursor` +```sql +function get_report( + a_coverage_options ut_coverage_options, + a_client_character_set varchar2 := null +) return ut_varchar2_rows pipelined +``` + +```sql +function get_report_cursor( + a_coverage_options ut_coverage_options, + a_client_character_set varchar2 := null +) return sys_refcursor +``` +```sql +ut_coverage_options( + coverage_run_id raw, + schema_names ut_varchar2_rows := null, + exclude_objects ut_varchar2_rows := null, + include_objects ut_varchar2_rows := null, + file_mappings ut_file_mappings := null +); +``` + +The `a_client_character_set` is used to provide character set to the report. Coverage reports in XML and HTML format include this information to assure that HMTL/XML encoding tag is aligned with encoding of the report produced. +Use this parameter to provide encoding of your client application. + +The `a_coverage_options` parameter is used to control the scope and formatting of data returned by report. + +`ut_coverage_options` object accepts the following arguments + +- `coverage_run_id` - identifier of coverage run to generate report for - data-type `RAW(32)` +- `schema_names` - optional - list of schema names to include in coverage report - data-type `UT_VARCHAR2_ROWS` +- `exclude_objects` - optional - list of object names to exclude from report - data-type `UT_VARCHAR2_ROWS` +- `include_objects` - optional - list of object names to gather coverage on - data-type `UT_VARCHAR2_ROWS` +- `file_mappings` - optional - list of schema names to gather coverage on - data-type `UT_FILE_MAPPINGS` + +`coverage_run_id` parameter identifies a common coverage run. The valid value type for that parameter is RAW(32). +It is recommended to use `sys_guid()` to generate a common, unique identifier for a specific coverage run. +If the identifier is not unique, previous runs of coverage that used the same `coverage_run_id` will be aggregated to the resulting coverage report. + +For details on the meaning of `schema_names`, `exclude_objects`, `include_objects`, `file_mappings` see sections above. +Note that data-types of include/exclude/schema lists are different when calling `ut.run` vs. calling `get_report/get_report_cursor`. + diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 31306b1c9..bb7d3e458 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -124,6 +124,7 @@ create or replace package body ut_runner is l_run := ut_run( a_run_paths => l_paths, a_coverage_options => ut_coverage_options( + coverage_run_id => sys_guid(), schema_names => l_coverage_schema_names, exclude_objects => ut_utils.convert_collection(a_exclude_objects), include_objects => ut_utils.convert_collection(a_include_objects), diff --git a/source/core/types/ut_coverage_options.tpb b/source/core/types/ut_coverage_options.tpb index 48a0f27c8..6eb4921a7 100644 --- a/source/core/types/ut_coverage_options.tpb +++ b/source/core/types/ut_coverage_options.tpb @@ -18,7 +18,7 @@ create or replace type body ut_coverage_options as constructor function ut_coverage_options( self in out nocopy ut_coverage_options, - coverage_run_id raw := null, + coverage_run_id raw, schema_names ut_varchar2_rows := null, exclude_objects ut_varchar2_rows := null, include_objects ut_varchar2_rows := null, @@ -46,7 +46,7 @@ create or replace type body ut_coverage_options as return l_result; end; begin - self.coverage_run_id := coalesce(coverage_run_id, sys_guid()); + self.coverage_run_id := coverage_run_id; self.file_mappings := file_mappings; self.schema_names := schema_names; self.exclude_objects := ut_object_names(); diff --git a/source/core/types/ut_coverage_options.tps b/source/core/types/ut_coverage_options.tps index 0de07b568..d6e86b653 100644 --- a/source/core/types/ut_coverage_options.tps +++ b/source/core/types/ut_coverage_options.tps @@ -23,7 +23,7 @@ create or replace type ut_coverage_options force as object ( file_mappings ut_file_mappings, constructor function ut_coverage_options( self in out nocopy ut_coverage_options, - coverage_run_id raw := null, + coverage_run_id raw, schema_names ut_varchar2_rows := null, exclude_objects ut_varchar2_rows := null, include_objects ut_varchar2_rows := null, From 1d771a546e1a081c07c1ad539624e6c67b2f97be Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 25 Jun 2020 20:31:51 +0100 Subject: [PATCH 109/887] Update timestamps No tests --- source/expectations/matchers/ut_be_within.tpb | 81 +++++++++++++++++++ source/expectations/matchers/ut_be_within.tps | 6 ++ .../expectations/binary/test_to_be_within.pkb | 6 ++ 3 files changed, 93 insertions(+) diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index 40bcfbab0..7e90ff4e6 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -52,6 +52,60 @@ create or replace type body ut_be_within as return l_result; end; + member procedure of_(self in ut_be_within, a_expected timestamp) is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_timestamp(a_expected); + if l_result.is_negated_flag = 1 then + l_result.expectation.not_to(l_result ); + else + l_result.expectation.to_(l_result ); + end if; + end; + + member function of_(self in ut_be_within, a_expected timestamp) return ut_be_within is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_timestamp(a_expected); + return l_result; + end; + + member procedure of_(self in ut_be_within, a_expected timestamp_tz_unconstrained) is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_timestamp_tz(a_expected); + if l_result.is_negated_flag = 1 then + l_result.expectation.not_to(l_result ); + else + l_result.expectation.to_(l_result ); + end if; + end; + + member function of_(self in ut_be_within, a_expected timestamp_tz_unconstrained) return ut_be_within is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_timestamp_tz(a_expected); + return l_result; + end; + + member procedure of_(self in ut_be_within, a_expected timestamp_ltz_unconstrained) is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_timestamp_ltz(a_expected); + if l_result.is_negated_flag = 1 then + l_result.expectation.not_to(l_result ); + else + l_result.expectation.to_(l_result ); + end if; + end; + + member function of_(self in ut_be_within, a_expected timestamp_ltz_unconstrained) return ut_be_within is + l_result ut_be_within := self; + begin + l_result.expected := ut_data_value_timestamp_ltz(a_expected); + return l_result; + end; + overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean is l_result boolean; function l_result_from_number return boolean is @@ -78,12 +132,39 @@ create or replace type body ut_be_within as end; end; + function l_result_from_timestamp (a_distance ut_data_value) return boolean is + l_expected timestamp := case when self.expected is of ( ut_data_value_timestamp) then + treat(self.expected as ut_data_value_timestamp).data_value + when self.expected is of ( ut_data_value_timestamp_tz) then + treat(self.expected as ut_data_value_timestamp_tz).data_value + when self.expected is of ( ut_data_value_timestamp_ltz) then + treat(self.expected as ut_data_value_timestamp_ltz).data_value + end; + l_actual timestamp with time zone := treat(a_actual as ut_data_value_date).data_value; + l_distance_ym yminterval_unconstrained := case when self.distance_from_expected is of ( ut_data_value_yminterval) + then treat(self.distance_from_expected as ut_data_value_yminterval).data_value + end; + l_distance_ds dsinterval_unconstrained := case when self.distance_from_expected is of ( ut_data_value_dsinterval) + then treat(self.distance_from_expected as ut_data_value_dsinterval).data_value + end; + begin + return case when l_distance_ym is not null + then l_actual between l_expected - l_distance_ym and l_expected + l_distance_ym + else l_actual between l_expected - l_distance_ds and l_expected + l_distance_ds + end; + end; + + begin if self.expected.data_type = a_actual.data_type then if self.expected is of (ut_data_value_number) then l_result := l_result_from_number; elsif self.expected is of (ut_data_value_date)then l_result := l_result_from_date(self.distance_from_expected); + elsif self.expected is of (ut_data_value_timestamp_tz)then + l_result := l_result_from_date(self.distance_from_expected); + elsif self.expected is of (ut_data_value_timestamp_ltz)then + l_result := l_result_from_date(self.distance_from_expected); end if; else l_result := (self as ut_matcher).run_matcher(a_actual); diff --git a/source/expectations/matchers/ut_be_within.tps b/source/expectations/matchers/ut_be_within.tps index 5090d3414..0b14bce44 100644 --- a/source/expectations/matchers/ut_be_within.tps +++ b/source/expectations/matchers/ut_be_within.tps @@ -22,6 +22,12 @@ create or replace type ut_be_within under ut_be_within_pct( constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained) return self as result, member procedure of_(self in ut_be_within, a_expected date), member function of_(self in ut_be_within, a_expected date) return ut_be_within, + member procedure of_(self in ut_be_within, a_expected timestamp), + member function of_(self in ut_be_within, a_expected timestamp) return ut_be_within, + member procedure of_(self in ut_be_within, a_expected timestamp_tz_unconstrained ), + member function of_(self in ut_be_within, a_expected timestamp_tz_unconstrained) return ut_be_within, + member procedure of_(self in ut_be_within, a_expected timestamp_ltz_unconstrained), + member function of_(self in ut_be_within, a_expected timestamp_ltz_unconstrained) return ut_be_within, overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean, overriding member function failure_message(a_actual ut_data_value) return varchar2, overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index b845bb26a..2ea90bd6b 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -74,6 +74,12 @@ create or replace package body test_to_be_within is test_to_be_within_success('to_be_within','date', 'sysdate', 'sysdate+1','''1 0:00:11.333''','interval day to second'); test_to_be_within_success('to_be_within','date', 'sysdate', 'sysdate+200','''1-0''','interval year to month'); test_to_be_within_success('to_be_within','date', 'sysdate+200', 'sysdate','''1-0''','interval year to month'); + + test_to_be_within_success('to_be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', 'sysdate','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', 'sysdate+1','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', 'sysdate+200','''1-0''','interval year to month'); + test_to_be_within_success('to_be_within','timestamp_ltz_unconstrained', 'sysdate+200', 'sysdate','''1-0''','interval year to month'); + test_to_be_within_success('to_( ut3_develop.be_within','number', '2', '4','2','number', ')'); test_to_be_within_success('to_( ut3_develop.be_within','number', '4', '2','2','number', ')'); test_to_be_within_success('to_( ut3_develop.be_within','date', 'sysdate+1', 'sysdate','''1 0:00:11.333''','interval day to second', ')'); From 363c333ba466eef38b57992f821afd397bb08d6a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 27 Jun 2020 01:07:06 +0100 Subject: [PATCH 110/887] Fixed and simplified matcher --- .../data_values/ut_data_value_dsinterval.tps | 2 +- .../data_values/ut_data_value_yminterval.tps | 2 +- source/expectations/matchers/ut_be_within.tpb | 63 ++----------------- .../matchers/ut_be_within_helper.pkb | 41 ++++++++++++ .../matchers/ut_be_within_helper.pks | 24 +++++++ source/install.sql | 2 + source/uninstall_objects.sql | 2 + .../expectations/binary/test_to_be_within.pkb | 18 ++++-- 8 files changed, 90 insertions(+), 64 deletions(-) create mode 100644 source/expectations/matchers/ut_be_within_helper.pkb create mode 100644 source/expectations/matchers/ut_be_within_helper.pks diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tps b/source/expectations/data_values/ut_data_value_dsinterval.tps index 114619bf2..09aa7ac0d 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tps +++ b/source/expectations/data_values/ut_data_value_dsinterval.tps @@ -15,7 +15,7 @@ create or replace type ut_data_value_dsinterval under ut_data_value( See the License for the specific language governing permissions and limitations under the License. */ - data_value dsinterval_unconstrained, + data_value interval day(9) to second(9), constructor function ut_data_value_dsinterval(self in out nocopy ut_data_value_dsinterval, a_value dsinterval_unconstrained) return self as result, overriding member function is_null return boolean, overriding member function to_string return varchar2, diff --git a/source/expectations/data_values/ut_data_value_yminterval.tps b/source/expectations/data_values/ut_data_value_yminterval.tps index d20dfcad7..3144d205c 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tps +++ b/source/expectations/data_values/ut_data_value_yminterval.tps @@ -15,7 +15,7 @@ create or replace type ut_data_value_yminterval under ut_data_value( See the License for the specific language governing permissions and limitations under the License. */ - data_value yminterval_unconstrained, + data_value interval year(9) to month, constructor function ut_data_value_yminterval(self in out nocopy ut_data_value_yminterval, a_value yminterval_unconstrained) return self as result, overriding member function is_null return boolean, overriding member function to_string return varchar2, diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index 7e90ff4e6..c411c4f61 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -107,64 +107,13 @@ create or replace type body ut_be_within as end; overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean is - l_result boolean; - function l_result_from_number return boolean is - l_expected number := treat(self.expected as ut_data_value_number).data_value; - l_actual number := treat(a_actual as ut_data_value_number).data_value; - l_distance number := treat(self.distance_from_expected as ut_data_value_number).data_value; - begin - return abs(l_expected - l_actual) <= l_distance; - end; - - function l_result_from_date(a_distance ut_data_value) return boolean is - l_expected date := treat(self.expected as ut_data_value_date).data_value; - l_actual date := treat(a_actual as ut_data_value_date).data_value; - l_distance_ym yminterval_unconstrained := case when self.distance_from_expected is of ( ut_data_value_yminterval) - then treat(self.distance_from_expected as ut_data_value_yminterval).data_value - end; - l_distance_ds dsinterval_unconstrained := case when self.distance_from_expected is of ( ut_data_value_dsinterval) - then treat(self.distance_from_expected as ut_data_value_dsinterval).data_value - end; - begin - return case when l_distance_ym is not null - then l_actual between l_expected - l_distance_ym and l_expected + l_distance_ym - else l_actual between l_expected - l_distance_ds and l_expected + l_distance_ds - end; - end; - - function l_result_from_timestamp (a_distance ut_data_value) return boolean is - l_expected timestamp := case when self.expected is of ( ut_data_value_timestamp) then - treat(self.expected as ut_data_value_timestamp).data_value - when self.expected is of ( ut_data_value_timestamp_tz) then - treat(self.expected as ut_data_value_timestamp_tz).data_value - when self.expected is of ( ut_data_value_timestamp_ltz) then - treat(self.expected as ut_data_value_timestamp_ltz).data_value - end; - l_actual timestamp with time zone := treat(a_actual as ut_data_value_date).data_value; - l_distance_ym yminterval_unconstrained := case when self.distance_from_expected is of ( ut_data_value_yminterval) - then treat(self.distance_from_expected as ut_data_value_yminterval).data_value - end; - l_distance_ds dsinterval_unconstrained := case when self.distance_from_expected is of ( ut_data_value_dsinterval) - then treat(self.distance_from_expected as ut_data_value_dsinterval).data_value - end; - begin - return case when l_distance_ym is not null - then l_actual between l_expected - l_distance_ym and l_expected + l_distance_ym - else l_actual between l_expected - l_distance_ds and l_expected + l_distance_ds - end; - end; - - - begin + l_result boolean; + begin if self.expected.data_type = a_actual.data_type then - if self.expected is of (ut_data_value_number) then - l_result := l_result_from_number; - elsif self.expected is of (ut_data_value_date)then - l_result := l_result_from_date(self.distance_from_expected); - elsif self.expected is of (ut_data_value_timestamp_tz)then - l_result := l_result_from_date(self.distance_from_expected); - elsif self.expected is of (ut_data_value_timestamp_ltz)then - l_result := l_result_from_date(self.distance_from_expected); + if self.expected is of (ut_data_value_date, ut_data_value_number, ut_data_value_timestamp, ut_data_value_timestamp_tz, ut_data_value_timestamp_ltz) then + l_result := ut_be_within_helper.values_within_abs_distance(self.expected, a_actual, self.distance_from_expected) ; + else + l_result := (self as ut_matcher).run_matcher(a_actual); end if; else l_result := (self as ut_matcher).run_matcher(a_actual); diff --git a/source/expectations/matchers/ut_be_within_helper.pkb b/source/expectations/matchers/ut_be_within_helper.pkb new file mode 100644 index 000000000..a958c3e0f --- /dev/null +++ b/source/expectations/matchers/ut_be_within_helper.pkb @@ -0,0 +1,41 @@ +create or replace package body ut_be_within_helper as + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + function values_within_abs_distance( + a_value_1 ut_data_value, a_value_2 ut_data_value, a_distance ut_data_value + ) return boolean is + l_result boolean; + begin + execute immediate q'[ + begin + :result := + treat(:a_value_1 as ut3_develop.]'||a_value_1.self_type||q'[).data_value + between + treat(:a_value_2 as ut3_develop.]'||a_value_2.self_type||q'[).data_value + - treat(:a_distance as ut3_develop.]'||a_distance.self_type||q'[).data_value + and + treat(:a_value_2 as ut3_develop.]'||a_value_2.self_type||q'[).data_value + + treat(:a_distance as ut3_develop.]'||a_distance.self_type||q'[).data_value; + end; + ]' + using out l_result, a_value_1, a_value_2, a_distance; + return l_result; + end; + +end; +/ diff --git a/source/expectations/matchers/ut_be_within_helper.pks b/source/expectations/matchers/ut_be_within_helper.pks new file mode 100644 index 000000000..0cb146a98 --- /dev/null +++ b/source/expectations/matchers/ut_be_within_helper.pks @@ -0,0 +1,24 @@ +create or replace package ut_be_within_helper authid definer as + /* + utPLSQL - Version 3 + Copyright 2016 - 2019 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + function values_within_abs_distance( + a_value_1 ut_data_value, a_value_2 ut_data_value, a_distance ut_data_value + ) return boolean; + +end; +/ diff --git a/source/install.sql b/source/install.sql index a3cf2c3d8..8a855f817 100644 --- a/source/install.sql +++ b/source/install.sql @@ -242,6 +242,7 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/matchers/ut_comparison_matcher.tps' @@install_component.sql 'expectations/matchers/ut_be_within_pct.tps' @@install_component.sql 'expectations/matchers/ut_be_within.tps' +@@install_component.sql 'expectations/matchers/ut_be_within_helper.pks' @@install_component.sql 'expectations/ut_expectation.tps' @@install_component.sql 'expectations/matchers/ut_be_false.tps' @@install_component.sql 'expectations/matchers/ut_be_greater_or_equal.tps' @@ -299,6 +300,7 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'expectations/matchers/ut_equal.tpb' @@install_component.sql 'expectations/matchers/ut_be_within_pct.tpb' @@install_component.sql 'expectations/matchers/ut_be_within.tpb' +@@install_component.sql 'expectations/matchers/ut_be_within_helper.pkb' @@install_component.sql 'expectations/matchers/ut_contain.tpb' @@install_component.sql 'expectations/matchers/ut_have_count.tpb' @@install_component.sql 'expectations/matchers/ut_be_between.tpb' diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index ee76cb8eb..84d319f96 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -148,6 +148,8 @@ drop type ut_be_within_pct force; drop type ut_be_within force; +drop package ut_be_within_helper; + drop type ut_comparison_matcher force; drop type ut_matcher force; diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index 2ea90bd6b..ae6220d2a 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -75,11 +75,19 @@ create or replace package body test_to_be_within is test_to_be_within_success('to_be_within','date', 'sysdate', 'sysdate+200','''1-0''','interval year to month'); test_to_be_within_success('to_be_within','date', 'sysdate+200', 'sysdate','''1-0''','interval year to month'); - test_to_be_within_success('to_be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', 'sysdate','''1 0:00:11.333''','interval day to second'); - test_to_be_within_success('to_be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', 'sysdate+1','''1 0:00:11.333''','interval day to second'); - test_to_be_within_success('to_be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', 'sysdate+200','''1-0''','interval year to month'); - test_to_be_within_success('to_be_within','timestamp_ltz_unconstrained', 'sysdate+200', 'sysdate','''1-0''','interval year to month'); - + test_to_be_within_success('to_be_within','timestamp', q'[TIMESTAMP '2017-08-09 07:00:00']', q'[TIMESTAMP '2017-08-08 06:59:48.667']','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','timestamp', q'[TIMESTAMP '2017-08-08 06:59:48.667']', q'[TIMESTAMP '2017-08-09 07:00:00']','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','timestamp', q'[TIMESTAMP '2017-08-09 07:00:00']', q'[TIMESTAMP '2018-08-09 07:00:00']','''1-0''','interval year to month'); + test_to_be_within_success('to_be_within','timestamp', q'[TIMESTAMP '2018-08-09 07:00:00']', q'[TIMESTAMP '2017-08-09 07:00:00']','''1-0''','interval year to month'); + test_to_be_within_success('to_be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2018-08-09 07:00:00 -7:00']','''1-0''','interval year to month'); + test_to_be_within_success('to_be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2018-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']','''1-0''','interval year to month'); + test_to_be_within_success('to_be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']','''1 0:00:11.333''','interval day to second'); + test_to_be_within_success('to_be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2018-08-09 07:00:00 -7:00']','''1-0''','interval year to month'); + test_to_be_within_success('to_be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2018-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']','''1-0''','interval year to month'); + test_to_be_within_success('to_( ut3_develop.be_within','number', '2', '4','2','number', ')'); test_to_be_within_success('to_( ut3_develop.be_within','number', '4', '2','2','number', ')'); test_to_be_within_success('to_( ut3_develop.be_within','date', 'sysdate+1', 'sysdate','''1 0:00:11.333''','interval day to second', ')'); From 0ea892522cad433a18664e20da41d2e559157d90 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 28 Jun 2020 12:15:37 +0100 Subject: [PATCH 111/887] Fixed native dynamic SQL types compatibility for 11g --- .../matchers/ut_be_within_helper.pkb | 22 +++++++++++-------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/source/expectations/matchers/ut_be_within_helper.pkb b/source/expectations/matchers/ut_be_within_helper.pkb index a958c3e0f..03f88e3a4 100644 --- a/source/expectations/matchers/ut_be_within_helper.pkb +++ b/source/expectations/matchers/ut_be_within_helper.pkb @@ -19,22 +19,26 @@ create or replace package body ut_be_within_helper as function values_within_abs_distance( a_value_1 ut_data_value, a_value_2 ut_data_value, a_distance ut_data_value ) return boolean is - l_result boolean; + l_result integer; begin execute immediate q'[ begin :result := - treat(:a_value_1 as ut3_develop.]'||a_value_1.self_type||q'[).data_value - between - treat(:a_value_2 as ut3_develop.]'||a_value_2.self_type||q'[).data_value - - treat(:a_distance as ut3_develop.]'||a_distance.self_type||q'[).data_value - and - treat(:a_value_2 as ut3_develop.]'||a_value_2.self_type||q'[).data_value - + treat(:a_distance as ut3_develop.]'||a_distance.self_type||q'[).data_value; + case + when + treat(:a_value_1 as ut3_develop.]'||a_value_1.self_type||q'[).data_value + between + treat(:a_value_2 as ut3_develop.]'||a_value_2.self_type||q'[).data_value + - treat(:a_distance as ut3_develop.]'||a_distance.self_type||q'[).data_value + and + treat(:a_value_2 as ut3_develop.]'||a_value_2.self_type||q'[).data_value + + treat(:a_distance as ut3_develop.]'||a_distance.self_type||q'[).data_value + then 1 + end; end; ]' using out l_result, a_value_1, a_value_2, a_distance; - return l_result; + return l_result > 0; end; end; From 7c01afbcbe5e7fba235dba49d1eb9d693bd4157f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 28 Jun 2020 12:21:03 +0100 Subject: [PATCH 112/887] Fixed native dynamic SQL types compatibility for 11g --- source/expectations/matchers/ut_be_within_helper.pkb | 1 + 1 file changed, 1 insertion(+) diff --git a/source/expectations/matchers/ut_be_within_helper.pkb b/source/expectations/matchers/ut_be_within_helper.pkb index 03f88e3a4..aecaf7179 100644 --- a/source/expectations/matchers/ut_be_within_helper.pkb +++ b/source/expectations/matchers/ut_be_within_helper.pkb @@ -34,6 +34,7 @@ create or replace package body ut_be_within_helper as treat(:a_value_2 as ut3_develop.]'||a_value_2.self_type||q'[).data_value + treat(:a_distance as ut3_develop.]'||a_distance.self_type||q'[).data_value then 1 + else 0 end; end; ]' From cd7d738d23ee25d24596986ba81afaeab66fc1ea Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 28 Jun 2020 16:12:33 +0100 Subject: [PATCH 113/887] Fixed CDATA tagging in JUnit reporter Resolves #1084 --- source/core/ut_utils.pkb | 3 +++ source/reporters/ut_realtime_reporter.tpb | 2 +- test/ut3_user/reporters/test_junit_reporter.pkb | 3 +++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index e12b91752..caaca44b3 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -827,6 +827,9 @@ create or replace package body ut_utils is begin if a_clob is not null and a_clob != empty_clob() then l_result := replace( a_clob, gc_cdata_end_tag, gc_cdata_end_tag_wrap ); + l_result := to_clob(gc_cdata_start_tag) + || replace( a_clob, gc_cdata_end_tag, gc_cdata_end_tag_wrap ) + || to_clob(gc_cdata_end_tag); else l_result := a_clob; end if; diff --git a/source/reporters/ut_realtime_reporter.tpb b/source/reporters/ut_realtime_reporter.tpb index 367b2c51a..443c7c4e7 100644 --- a/source/reporters/ut_realtime_reporter.tpb +++ b/source/reporters/ut_realtime_reporter.tpb @@ -252,7 +252,7 @@ create or replace type body ut_realtime_reporter is ) is begin if a_content is not null then - self.print_xml_fragment('<' || a_name || '>'); + self.print_xml_fragment('<' || a_name || '>' || ut_utils.to_cdata(a_content) || ''); end if; end print_cdata_node; diff --git a/test/ut3_user/reporters/test_junit_reporter.pkb b/test/ut3_user/reporters/test_junit_reporter.pkb index f3cc6c6d2..8f015e80b 100644 --- a/test/ut3_user/reporters/test_junit_reporter.pkb +++ b/test/ut3_user/reporters/test_junit_reporter.pkb @@ -15,6 +15,7 @@ create or replace package body test_junit_reporter as begin ut3_develop.ut.expect(1).to_equal(1); ut3_develop.ut.expect(1).to_equal(2); + dbms_output.put_line(' ]]>'); end; end;]'; @@ -87,6 +88,8 @@ create or replace package body test_junit_reporter as --Assert ut.expect(l_actual).not_to_be_like('%%'); ut.expect(l_actual).to_be_like('%<tag>%'); + ut.expect(l_actual).to_be_like(q'/% ]]]]> +]]>%/'); end; procedure reports_only_failed_or_errored is From 2956d07688ad7089ee9add699c09fa249c24ebb0 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sat, 18 Jul 2020 16:20:08 +0000 Subject: [PATCH 114/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 40066e6aa..36821dadf 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 35cf2e9b8..06f26aa11 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index c2d7c8f54..b4fe423aa 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 458a925a9..d4be9073b 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 8c47b7c55..177f3bc70 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 3baefddfc..7b50ae506 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 191f3fdc4..f83515d85 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0cd0fb9ae..c01c417ca 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index e15167f1a..11d2aea40 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting is based on the DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index fce6a83fd..a41802a66 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index a43f3ebec..3d0a9da11 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 95e82dcd9..0d79a5f3c 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index fca4bcf13..0025cc7eb 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 7107cc139..15e726c22 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 7730c7c6c..e04f89c97 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 6f9774a8b..72f73f2fd 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index eab281d70..042ba91a9 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3422--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index caaca44b3..b58876369 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,7 +769,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3422-develop + * secion v3.1.11.3455-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index b0ee188fc..bdddb5815 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3422-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3455-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 89d546abb854d0854fd505449d10c02227086b76 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 18 Jul 2020 17:53:57 +0100 Subject: [PATCH 115/887] Extended UK on ut_coverage_sources_tmp table. Resolves #1086 TODO - need to fix coverage reporting so that coverage is grouped by object type not only object name --- .travis/install.sh | 2 +- source/core/coverage/ut_coverage.pkb | 6 +-- source/core/coverage/ut_coverage_block.pkb | 6 +-- source/core/coverage/ut_coverage_helper.pkb | 8 +-- source/core/coverage/ut_coverage_helper.pks | 2 + .../coverage/ut_coverage_helper_block.pkb | 15 +++--- .../coverage/ut_coverage_helper_block.pks | 4 +- .../coverage/ut_coverage_helper_profiler.pkb | 14 +++-- .../coverage/ut_coverage_helper_profiler.pks | 4 +- source/core/coverage/ut_coverage_profiler.pkb | 6 +-- .../core/coverage/ut_coverage_sources_tmp.sql | 3 +- test/ut3_tester_helper/coverage_helper.pkb | 53 +++++++++++++++++++ test/ut3_tester_helper/coverage_helper.pks | 3 ++ .../test_coverage/test_proftab_coverage.pkb | 21 ++++++++ .../test_coverage/test_proftab_coverage.pks | 5 ++ 15 files changed, 113 insertions(+), 39 deletions(-) diff --git a/.travis/install.sh b/.travis/install.sh index 225b6ff52..537fddb66 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -147,7 +147,7 @@ PROMPT Grants for testing coverage outside of main $UT3_DEVELOP_SCHEMA schema. grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type, select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table, select any dictionary, create any synonym, drop any synonym, - grant any object privilege, grant any privilege, create public synonym, drop public synonym + grant any object privilege, grant any privilege, create public synonym, drop public synonym, create any trigger to $UT3_TESTER_HELPER; grant create job to $UT3_TESTER_HELPER; diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index a05fa554a..e1b7572be 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -48,7 +48,7 @@ create or replace package body ut_coverage is ), sources as ( select /*+ cardinality(f {mappings_cardinality}) */ - {l_full_name} as full_name, s.owner, s.name, + {l_full_name} as full_name, s.owner, s.name, s.type, s.line - case when s.type = 'TRIGGER' then o.offset else 0 end as line, s.text from {sources_view} s {join_file_mappings} @@ -58,7 +58,7 @@ create or replace package body ut_coverage is {filters} ), coverage_sources as ( - select full_name, owner, name, line, text, + select full_name, owner, name, type, line, text, case when -- to avoid execution of regexp_like on every line @@ -77,7 +77,7 @@ create or replace package body ut_coverage is end as to_be_skipped from sources s ) - select full_name, owner, name, line, to_be_skipped, text + select full_name, owner, name, type, line, to_be_skipped, text from coverage_sources s -- Exclude calls to utPLSQL framework, Unit Test packages and objects from a_exclude_list parameter of coverage reporter where (s.owner, s.name) not in ( select /*+ cardinality(el {skipped_objects_cardinality})*/el.owner, el.name from table(:l_skipped_objects) el ) diff --git a/source/core/coverage/ut_coverage_block.pkb b/source/core/coverage/ut_coverage_block.pkb index 0e0373a48..79fd42699 100644 --- a/source/core/coverage/ut_coverage_block.pkb +++ b/source/core/coverage/ut_coverage_block.pkb @@ -40,11 +40,7 @@ create or replace package body ut_coverage_block is exit when l_source_objects_crsr%notfound; --get coverage data - l_line_calls := ut_coverage_helper_block.get_raw_coverage_data( - l_source_object.owner, - l_source_object.name, - a_coverage_options.coverage_run_id - ); + l_line_calls := ut_coverage_helper_block.get_raw_coverage_data(l_source_object, a_coverage_options.coverage_run_id); --if there is coverage, we need to filter out the garbage (badly indicated data) if l_line_calls.count > 0 then --remove lines that should not be indicted as meaningful diff --git a/source/core/coverage/ut_coverage_helper.pkb b/source/core/coverage/ut_coverage_helper.pkb index 5762452c4..4c41aa2f6 100644 --- a/source/core/coverage/ut_coverage_helper.pkb +++ b/source/core/coverage/ut_coverage_helper.pkb @@ -36,8 +36,8 @@ create or replace package body ut_coverage_helper is begin forall i in 1 .. a_data.count insert into ut_coverage_sources_tmp - (full_name,owner,name,line,text, to_be_skipped) - values(a_data(i).full_name,a_data(i).owner,a_data(i).name,a_data(i).line,a_data(i).text,a_data(i).to_be_skipped); + (full_name,owner,name,type,line,text,to_be_skipped) + values(a_data(i).full_name,a_data(i).owner,a_data(i).name,a_data(i).type,a_data(i).line,a_data(i).text,a_data(i).to_be_skipped); end; procedure cleanup_tmp_table is @@ -60,12 +60,12 @@ create or replace package body ut_coverage_helper is l_result t_tmp_table_objects_crsr; begin open l_result for - select o.owner, o.name, o.full_name, max(o.line) as lines_count, + select o.owner, o.name, o.type, o.full_name, max(o.line) as lines_count, cast( collect(decode(to_be_skipped, 'Y', to_char(line))) as ut_varchar2_list ) as to_be_skipped_list from ut_coverage_sources_tmp o - group by o.owner, o.name, o.full_name; + group by o.owner, o.name, o.type, o.full_name; return l_result; end; diff --git a/source/core/coverage/ut_coverage_helper.pks b/source/core/coverage/ut_coverage_helper.pks index 955542633..632b18a0d 100644 --- a/source/core/coverage/ut_coverage_helper.pks +++ b/source/core/coverage/ut_coverage_helper.pks @@ -32,6 +32,7 @@ create or replace package ut_coverage_helper authid definer is full_name ut_coverage_sources_tmp.full_name%type, owner ut_coverage_sources_tmp.owner%type, name ut_coverage_sources_tmp.name%type, + type ut_coverage_sources_tmp.type%type, line ut_coverage_sources_tmp.line%type, to_be_skipped ut_coverage_sources_tmp.to_be_skipped%type, text ut_coverage_sources_tmp.text%type @@ -42,6 +43,7 @@ create or replace package ut_coverage_helper authid definer is type t_tmp_table_object is record( owner ut_coverage_sources_tmp.owner%type, name ut_coverage_sources_tmp.name%type, + type ut_coverage_sources_tmp.type%type, full_name ut_coverage_sources_tmp.full_name%type, lines_count integer, to_be_skipped_list ut_varchar2_list diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index 1ded434ba..6f0e66783 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -41,7 +41,7 @@ create or replace package body ut_coverage_helper_block is $end end; - function block_results(a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw) return t_block_rows is + function block_results(a_object ut_coverage_helper.t_tmp_table_object, a_coverage_run_id raw) return t_block_rows is l_coverage_rows t_block_rows; l_ut_owner varchar2(250) := ut_utils.ut_owner; begin @@ -61,23 +61,26 @@ create or replace package body ut_coverage_helper_block is where r.coverage_run_id = :a_coverage_run_id and ccu.owner = :a_object_owner and ccu.name = :a_object_name + and ccu.type = :a_object_type group by ccb.line, ccb.block ) group by line order by line]' - bulk collect into l_coverage_rows using a_coverage_run_id, a_object_owner, a_object_name; + bulk collect into l_coverage_rows + using + a_coverage_run_id, a_object.owner, + a_object.name, a_object.type; + return l_coverage_rows; end; - function get_raw_coverage_data( - a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw - ) return ut_coverage_helper.t_unit_line_calls is + function get_raw_coverage_data(a_object ut_coverage_helper.t_tmp_table_object, a_coverage_run_id raw) return ut_coverage_helper.t_unit_line_calls is l_tmp_data t_block_rows; l_results ut_coverage_helper.t_unit_line_calls; begin $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - l_tmp_data := block_results(a_object_owner, a_object_name, a_coverage_run_id); + l_tmp_data := block_results(a_object, a_coverage_run_id); for i in 1 .. l_tmp_data.count loop l_results(l_tmp_data(i).line).blocks := l_tmp_data(i).blocks; diff --git a/source/core/coverage/ut_coverage_helper_block.pks b/source/core/coverage/ut_coverage_helper_block.pks index 9d24989d6..18adf4fbd 100644 --- a/source/core/coverage/ut_coverage_helper_block.pks +++ b/source/core/coverage/ut_coverage_helper_block.pks @@ -20,9 +20,7 @@ create or replace package ut_coverage_helper_block authid current_user is procedure coverage_stop; - function get_raw_coverage_data( - a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw - ) return ut_coverage_helper.t_unit_line_calls; + function get_raw_coverage_data(a_object ut_coverage_helper.t_tmp_table_object, a_coverage_run_id raw) return ut_coverage_helper.t_unit_line_calls; end; / diff --git a/source/core/coverage/ut_coverage_helper_profiler.pkb b/source/core/coverage/ut_coverage_helper_profiler.pkb index dde3bf3ea..dacfcbaa3 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pkb +++ b/source/core/coverage/ut_coverage_helper_profiler.pkb @@ -55,7 +55,7 @@ create or replace package body ut_coverage_helper_profiler is dbms_profiler.stop_profiler(); end; - function proftab_results(a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw) return t_proftab_rows is + function proftab_results(a_object ut_coverage_helper.t_tmp_table_object, a_coverage_run_id raw) return t_proftab_rows is l_coverage_rows t_proftab_rows; begin select @@ -69,21 +69,19 @@ create or replace package body ut_coverage_helper_profiler is join ut_coverage_runs r on r.line_coverage_id = u.runid where r.coverage_run_id = a_coverage_run_id - and u.unit_owner = a_object_owner - and u.unit_name = a_object_name - and u.unit_type in ('PACKAGE BODY', 'TYPE BODY', 'PROCEDURE', 'FUNCTION', 'TRIGGER') + and u.unit_owner = a_object.owner + and u.unit_name = a_object.name + and u.unit_type = a_object.type group by d.line#; return l_coverage_rows; end; - function get_raw_coverage_data( - a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw - ) return ut_coverage_helper.t_unit_line_calls is + function get_raw_coverage_data(a_object ut_coverage_helper.t_tmp_table_object, a_coverage_run_id raw) return ut_coverage_helper.t_unit_line_calls is l_tmp_data t_proftab_rows; l_results ut_coverage_helper.t_unit_line_calls; begin - l_tmp_data := proftab_results(a_object_owner, a_object_name, a_coverage_run_id); + l_tmp_data := proftab_results(a_object, a_coverage_run_id); for i in 1 .. l_tmp_data.count loop l_results(l_tmp_data(i).line).calls := l_tmp_data(i).calls; diff --git a/source/core/coverage/ut_coverage_helper_profiler.pks b/source/core/coverage/ut_coverage_helper_profiler.pks index 390495810..f105d3c9c 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pks +++ b/source/core/coverage/ut_coverage_helper_profiler.pks @@ -24,9 +24,7 @@ create or replace package ut_coverage_helper_profiler authid definer is procedure coverage_resume; - function get_raw_coverage_data( - a_object_owner varchar2, a_object_name varchar2, a_coverage_run_id raw - ) return ut_coverage_helper.t_unit_line_calls; + function get_raw_coverage_data(a_object ut_coverage_helper.t_tmp_table_object, a_coverage_run_id raw) return ut_coverage_helper.t_unit_line_calls; end; / diff --git a/source/core/coverage/ut_coverage_profiler.pkb b/source/core/coverage/ut_coverage_profiler.pkb index 274f6949c..6d9f894d5 100644 --- a/source/core/coverage/ut_coverage_profiler.pkb +++ b/source/core/coverage/ut_coverage_profiler.pkb @@ -34,11 +34,7 @@ create or replace package body ut_coverage_profiler is exit when l_source_objects_crsr%notfound; --get coverage data - l_line_calls := ut_coverage_helper_profiler.get_raw_coverage_data( - l_source_object.owner, - l_source_object.name, - a_coverage_options.coverage_run_id - ); + l_line_calls := ut_coverage_helper_profiler.get_raw_coverage_data( l_source_object, a_coverage_options.coverage_run_id); --if there is coverage, we need to filter out the garbage (badly indicated data from dbms_profiler) if l_line_calls.count > 0 then diff --git a/source/core/coverage/ut_coverage_sources_tmp.sql b/source/core/coverage/ut_coverage_sources_tmp.sql index f53283dcd..abaae5353 100644 --- a/source/core/coverage/ut_coverage_sources_tmp.sql +++ b/source/core/coverage/ut_coverage_sources_tmp.sql @@ -15,10 +15,11 @@ create global temporary table ut_coverage_sources_tmp( full_name varchar2(4000), owner varchar2(250), name varchar2(250), + type varchar2(250), line number(38,0), to_be_skipped varchar2(1), text varchar2(4000), - constraint ut_coverage_sources_tmp_pk primary key (owner,name,line) + constraint ut_coverage_sources_tmp_pk primary key (owner,name,type,line) ) on commit preserve rows; --is this needed? diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 9b595a0b3..73dec720b 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -246,5 +246,58 @@ create or replace package body coverage_helper is return run_code_as_job( l_plsql_block ); end; + procedure create_dup_object_name is + pragma autonomous_transaction; + begin + execute immediate 'create table ut3_develop.test_table(id integer)'; + execute immediate q'[ + create or replace trigger ut3_develop.duplicate_name + before insert on ut3_develop.test_table + begin + + dbms_output.put_line('A'); + end; + ]'; + execute immediate q'[ + create or replace package ut3_develop.duplicate_name is + procedure some_procedure; + end; + ]'; + execute immediate q'[ + create or replace package body ut3_develop.duplicate_name is + procedure some_procedure is + begin + insert into test_table(id) values(1); + end; + end; + ]'; + execute immediate q'[ + create or replace package ut3_develop.test_duplicate_name is + --%suite + + --%test + procedure run_duplicate_name; + end; + ]'; + execute immediate q'[ + create or replace package body ut3_develop.test_duplicate_name is + procedure run_duplicate_name is + l_actual sys_refcursor; + begin + ut3_develop.duplicate_name.some_procedure; + ut.expect(l_actual).to_have_count(1); + end; + end; + ]'; + end; + + procedure drop_dup_object_name is + pragma autonomous_transaction; + begin + execute immediate 'drop table ut3_develop.test_table'; + execute immediate 'drop package ut3_develop.duplicate_name'; + execute immediate 'drop package ut3_develop.test_duplicate_name'; + end; + end; / diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index b044c897b..9a3bd1db6 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -22,5 +22,8 @@ create or replace package coverage_helper is procedure create_test_results_table; procedure drop_test_results_table; + procedure drop_dup_object_name; + procedure create_dup_object_name; + end; / diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index c6e087462..9fbc24718 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -92,6 +92,27 @@ create or replace package body test_proftab_coverage is ut.expect(l_actual).to_be_like(l_expected); end; + procedure dup_object_name_coverage is + l_actual clob; + l_expected clob; + begin + l_expected := '%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_duplicate_name', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.duplicate_name' ) + ) + ]' + ); + --Assert + --TODO - need to fix coverage reporting so that coverage is grouped by object type not only object name + ut.expect(l_actual).to_be_like(l_expected); + end; + procedure coverage_tmp_data_refresh is l_actual clob; l_test_code varchar2(32767); diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks index 055422bf7..740862f86 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks @@ -14,6 +14,11 @@ create or replace package test_proftab_coverage is --%test(Coverage is gathered for specified file - default coverage type) procedure coverage_for_file; + + --%beforetest(ut3_tester_helper.coverage_helper.create_dup_object_name) + --%aftertest(ut3_tester_helper.coverage_helper.drop_dup_object_name) + --%test(Coverage on duplicate object name) + procedure dup_object_name_coverage; --%test(Coverage data is not cached between runs - issue #562 ) --%aftertest(ut3_tester_helper.coverage_helper.drop_dummy_coverage_1) From 461bc016fdbb34f72761ebd087e108942743a345 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 19 Jul 2020 22:56:30 +0000 Subject: [PATCH 116/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 36821dadf..9e6c42d93 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 06f26aa11..fbf99289b 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index b4fe423aa..43671176f 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index d4be9073b..b66268f5f 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 177f3bc70..b83b9e941 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7b50ae506..a074e1b35 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index f83515d85..333ff300a 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index c01c417ca..4c0282a0a 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 45f552769..ccc5e9b44 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a41802a66..f6115ba45 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3d0a9da11..72e634deb 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 0d79a5f3c..97b7fd91b 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 0025cc7eb..0c5023eb8 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 15e726c22..c23674e60 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index e04f89c97..2fe5f4d2a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 72f73f2fd..8e933a8d8 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 042ba91a9..9e12db146 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3455--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 56db02fa3..e9df15926 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3455-develop + * secion v3.1.11.3456-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 68e5a962d..443548b83 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3455-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3456-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From e96b9780257ee0bcf73404db1440a2248d9169e4 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 20 Jul 2020 01:00:00 +0100 Subject: [PATCH 117/887] Added object type to name in coverage reports. Fixed issue with reporting non-block coverage as block coverage. Resolves #1086 --- source/core/coverage/ut_coverage.pkb | 2 +- source/core/coverage/ut_coverage_helper_block.pkb | 1 + .../test_coverage/test_coverage_standalone.pkb | 2 +- .../test_coverage/test_coveralls_reporter.pkb | 2 +- .../test_coverage/test_extended_coverage.pkb | 6 +++--- .../test_coverage/test_proftab_coverage.pkb | 14 ++++++++------ 6 files changed, 15 insertions(+), 12 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index e1b7572be..81d17704a 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -93,7 +93,7 @@ create or replace package body ut_coverage is and s.type = f.object_type and s.owner = f.object_owner'; else - l_full_name := q'[lower(s.owner||'.'||s.name)]'; + l_full_name := q'[lower(s.type||' '||s.owner||'.'||s.name)]'; l_filters := case when a_coverage_options.include_objects is not empty then ' and (s.owner, s.name) in ( diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index 6f0e66783..e030f2c37 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -65,6 +65,7 @@ create or replace package body ut_coverage_helper_block is group by ccb.line, ccb.block ) group by line + having count(block) > 1 order by line]' bulk collect into l_coverage_rows using diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index ef7014235..bcd933eed 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -5,7 +5,7 @@ create or replace package body test_coverage_standalone is l_block_cov clob; l_file_path varchar2(250); begin - l_file_path := 'ut3_develop.'||a_object_name; + l_file_path := 'package body ut3_develop.'||a_object_name; --Arrange if ut3_tester_helper.coverage_helper.block_coverage_available then l_block_cov := ''; diff --git a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb index 48a62f7f6..e3806cd97 100644 --- a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb @@ -41,7 +41,7 @@ null, begin --Arrange l_expected := q'[{"source_files":[ -{ "name": "ut3_develop.]'||ut3_tester_helper.coverage_helper.covered_package_name||q'[", +{ "name": "package body ut3_develop.]'||ut3_tester_helper.coverage_helper.covered_package_name||q'[", "coverage": [ 0, 0, diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index 4b995b7c8..ec95c0bfb 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -15,7 +15,7 @@ create or replace package body test_extended_coverage is l_actual clob; begin --Arrange - l_expected := '%' || + l_expected := '%' || get_block_coverage_line|| '%%'; --Act @@ -38,7 +38,7 @@ create or replace package body test_extended_coverage is l_actual clob; begin --Arrange - l_expected := '%' || + l_expected := '%' || get_block_coverage_line || '%%'; --Act @@ -54,7 +54,7 @@ create or replace package body test_extended_coverage is ); --Assert ut.expect(l_actual).to_be_like(l_expected); - ut.expect(l_actual).to_be_like('%%%'); + ut.expect(l_actual).to_be_like('%%%'); end; procedure coverage_for_file is diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index 9fbc24718..6171ecb80 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -5,7 +5,7 @@ create or replace package body test_proftab_coverage is l_actual clob; begin --Arrange - l_expected := coverage_helper.substitute_covered_package('%%'); + l_expected := coverage_helper.substitute_covered_package('%%'); --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( @@ -28,7 +28,7 @@ create or replace package body test_proftab_coverage is l_actual clob; begin --Arrange - l_expected := coverage_helper.substitute_covered_package('%%'); + l_expected := coverage_helper.substitute_covered_package('%%'); --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( @@ -51,7 +51,7 @@ create or replace package body test_proftab_coverage is l_actual clob; begin --Arrange - l_expected := ''; + l_expected := ''; l_expected := '%'||l_expected||'%'||l_expected||'%'; --Act l_actual := @@ -96,7 +96,9 @@ create or replace package body test_proftab_coverage is l_actual clob; l_expected clob; begin - l_expected := '%'; + l_expected := + '%%' || + '%%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( @@ -164,11 +166,11 @@ create or replace package body test_proftab_coverage is -ut3_develop.{p} +package body ut3_develop.{p} - + From 507c176cee4f6e291728354a3db1cac1e06d5ec9 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Mon, 20 Jul 2020 17:32:54 +0000 Subject: [PATCH 118/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 9e6c42d93..0b67eb07c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index fbf99289b..ac992ab44 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 43671176f..9c8ff22d3 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index b66268f5f..2c808838f 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b83b9e941..a3aa9bee9 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index a074e1b35..3f32da536 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 333ff300a..1d2c81694 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 4c0282a0a..14e835f69 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index ccc5e9b44..52e34332d 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index f6115ba45..fa7ebda44 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 72e634deb..9a872becf 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 97b7fd91b..54aa18234 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 0c5023eb8..09484b850 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c23674e60..c0263af1e 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 2fe5f4d2a..09febcd38 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 8e933a8d8..194c0b44c 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 9e12db146..b5be914e2 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3456--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index e9df15926..6a5788a71 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3456-develop + * secion v3.1.11.3460-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 443548b83..cc4cc3f52 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3456-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3460-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 959c1c95dc862233f776fc0465e5a0386dbc3f5a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 3 Aug 2020 14:28:36 +0100 Subject: [PATCH 119/887] Added example of a reporter that reports out all expectation outputs, not only the failed ones. The success & failure of expectation is also reported inline with tests (not at the end in the summary section of report). Reorganized some of examples as well. --- examples/RunAllExamplesAsTests.sql | 4 + examples/RunCustomReportersExamples.sql | 10 ++ examples/RunDeveloperExamples.sql | 2 - examples/between_string/run_betwnstr_test.sql | 3 +- .../run_betwnstr_test_coverage.sql | 3 +- .../{test_betwnstr.pkg => test_betwnstr.pkb} | 22 --- examples/between_string/test_betwnstr.pks | 22 +++ .../run_ut_custom_reporter.sql | 16 ++ .../run_ut_expectations_reporter.sql | 16 ++ .../ut_custom_reporter.tpb | 0 .../ut_custom_reporter.tps | 6 + .../ut_expectations_reporter.tpb | 149 ++++++++++++++++++ .../ut_expectations_reporter.tps | 30 ++++ .../demo_equal_matcher.sql | 4 +- .../drop_demo_equal_matcher.sql | 5 + examples/demo_of_expectations/run.sql | 5 +- .../RunExampleTestSuiteWithCustomReporter.sql | 56 ------- 17 files changed, 265 insertions(+), 88 deletions(-) create mode 100644 examples/RunCustomReportersExamples.sql rename examples/between_string/{test_betwnstr.pkg => test_betwnstr.pkb} (52%) create mode 100644 examples/between_string/test_betwnstr.pks create mode 100644 examples/custom_reporters/run_ut_custom_reporter.sql create mode 100644 examples/custom_reporters/run_ut_expectations_reporter.sql rename examples/{developer_examples => custom_reporters}/ut_custom_reporter.tpb (100%) rename examples/{developer_examples => custom_reporters}/ut_custom_reporter.tps (69%) create mode 100644 examples/custom_reporters/ut_expectations_reporter.tpb create mode 100644 examples/custom_reporters/ut_expectations_reporter.tps create mode 100644 examples/demo_of_expectations/drop_demo_equal_matcher.sql delete mode 100644 examples/developer_examples/RunExampleTestSuiteWithCustomReporter.sql diff --git a/examples/RunAllExamplesAsTests.sql b/examples/RunAllExamplesAsTests.sql index 458f11091..d089ba447 100644 --- a/examples/RunAllExamplesAsTests.sql +++ b/examples/RunAllExamplesAsTests.sql @@ -3,3 +3,7 @@ whenever oserror exit failure rollback @@RunAllExamples.sql +prompt ******************************************************************************* +prompt All examples completed successfully +prompt ******************************************************************************* +prompt diff --git a/examples/RunCustomReportersExamples.sql b/examples/RunCustomReportersExamples.sql new file mode 100644 index 000000000..730946662 --- /dev/null +++ b/examples/RunCustomReportersExamples.sql @@ -0,0 +1,10 @@ +prompt ******************************************************************************* +prompt Running custom reporters examples +prompt ******************************************************************************* +Clear Screen +set echo off +set feedback on +set linesize 1000 + +@@custom_reporters/run_ut_custom_reporter.sql +@@custom_reporters/run_ut_expectations_reporter.sql diff --git a/examples/RunDeveloperExamples.sql b/examples/RunDeveloperExamples.sql index eaf87c143..2f4ca13e3 100644 --- a/examples/RunDeveloperExamples.sql +++ b/examples/RunDeveloperExamples.sql @@ -6,8 +6,6 @@ set linesize 1000 exec ut_ansiconsole_helper.color_enabled(true); --developer examples -prompt RunExampleTestSuiteWithCustomReporter -@@developer_examples/RunExampleTestSuiteWithCustomReporter.sql prompt RunExampleTestAnnotationsParsingTimeHugePackage @@developer_examples/RunExampleTestAnnotationsParsingTimeHugePackage.sql prompt RunExampleTestSuite diff --git a/examples/between_string/run_betwnstr_test.sql b/examples/between_string/run_betwnstr_test.sql index 120645410..31edc52cf 100644 --- a/examples/between_string/run_betwnstr_test.sql +++ b/examples/between_string/run_betwnstr_test.sql @@ -1,5 +1,6 @@ @@betwnstr.sql -@@test_betwnstr.pkg +@@test_betwnstr.pks +@@test_betwnstr.pkb set serveroutput on size unlimited format truncated diff --git a/examples/between_string/run_betwnstr_test_coverage.sql b/examples/between_string/run_betwnstr_test_coverage.sql index ab75872ce..098445cae 100644 --- a/examples/between_string/run_betwnstr_test_coverage.sql +++ b/examples/between_string/run_betwnstr_test_coverage.sql @@ -4,7 +4,8 @@ set pagesize 0 set long 200000000 set longchunksize 1000000 @@betwnstr.sql -@@test_betwnstr.pkg +@@test_betwnstr.pks +@@test_betwnstr.pkb set serveroutput on size unlimited format truncated diff --git a/examples/between_string/test_betwnstr.pkg b/examples/between_string/test_betwnstr.pkb similarity index 52% rename from examples/between_string/test_betwnstr.pkg rename to examples/between_string/test_betwnstr.pkb index 84f153ecc..f872f6447 100644 --- a/examples/between_string/test_betwnstr.pkg +++ b/examples/between_string/test_betwnstr.pkb @@ -1,25 +1,3 @@ -create or replace package test_betwnstr as - - -- %suite(Between string function) - - -- %test(Returns substring from start position to end position) - procedure normal_case; - - -- %test(Returns substring when start position is zero) - procedure zero_start_position; - - -- %test(Returns string until end if end position is greater than string length) - procedure big_end_position; - - -- %test(Returns null for null input string value) - procedure null_string; - - -- %test(Demo of a disabled test) - -- %disabled - procedure disabled_test; - -end; -/ create or replace package body test_betwnstr as procedure normal_case is diff --git a/examples/between_string/test_betwnstr.pks b/examples/between_string/test_betwnstr.pks new file mode 100644 index 000000000..7b98d0005 --- /dev/null +++ b/examples/between_string/test_betwnstr.pks @@ -0,0 +1,22 @@ +create or replace package test_betwnstr as + + -- %suite(Between string function) + + -- %test(Returns substring from start position to end position) + procedure normal_case; + + -- %test(Returns substring when start position is zero) + procedure zero_start_position; + + -- %test(Returns string until end if end position is greater than string length) + procedure big_end_position; + + -- %test(Returns null for null input string value) + procedure null_string; + + -- %test(Demo of a disabled test) + -- %disabled + procedure disabled_test; + +end; +/ diff --git a/examples/custom_reporters/run_ut_custom_reporter.sql b/examples/custom_reporters/run_ut_custom_reporter.sql new file mode 100644 index 000000000..dbb142ce1 --- /dev/null +++ b/examples/custom_reporters/run_ut_custom_reporter.sql @@ -0,0 +1,16 @@ +prompt ******************************************************************************* +prompt Runnign tests with UT_CUSTOM_REPORTER on top of UT_DOCUMENTATION_REPROTER +prompt ******************************************************************************* + +set echo off +--install the example unit test packages +@demo_of_expectations/demo_equal_matcher.sql +@@ut_custom_reporter.tps +@@ut_custom_reporter.tpb + +set serveroutput on size unlimited format truncated + +exec ut.run('demo_equal_matcher', ut_custom_reporter()); + +@demo_of_expectations/drop_demo_equal_matcher.sql +drop type ut_custom_reporter; diff --git a/examples/custom_reporters/run_ut_expectations_reporter.sql b/examples/custom_reporters/run_ut_expectations_reporter.sql new file mode 100644 index 000000000..90b1ff9ff --- /dev/null +++ b/examples/custom_reporters/run_ut_expectations_reporter.sql @@ -0,0 +1,16 @@ +prompt ******************************************************************************* +prompt Runnign tests with UT_CUSTOM_REPORTER on top of UT_DOCUMENTATION_REPROTER +prompt ******************************************************************************* + +set echo off +--install the example unit test packages +@demo_of_expectations/demo_equal_matcher.sql +@@ut_expectations_reporter.tps +@@ut_expectations_reporter.tpb + +set serveroutput on size unlimited format truncated + +exec ut.run('demo_equal_matcher', ut_expectations_reporter()); + +@demo_of_expectations/drop_demo_equal_matcher.sql +drop type ut_expectations_reporter; diff --git a/examples/developer_examples/ut_custom_reporter.tpb b/examples/custom_reporters/ut_custom_reporter.tpb similarity index 100% rename from examples/developer_examples/ut_custom_reporter.tpb rename to examples/custom_reporters/ut_custom_reporter.tpb diff --git a/examples/developer_examples/ut_custom_reporter.tps b/examples/custom_reporters/ut_custom_reporter.tps similarity index 69% rename from examples/developer_examples/ut_custom_reporter.tps rename to examples/custom_reporters/ut_custom_reporter.tps index cc7de666e..0cc3d67ed 100644 --- a/examples/developer_examples/ut_custom_reporter.tps +++ b/examples/custom_reporters/ut_custom_reporter.tps @@ -4,6 +4,12 @@ create or replace type ut_custom_reporter under ut_documentation_reporter -- Member functions and procedures constructor function ut_custom_reporter(a_tab_size integer default 4) return self as result, + + /* The reporter is using base functions of parent type ( UT_DOCUMENTATION_REPORTER ) + It is altering the behavior of the base functions by change of the indentation. + So the custom reporter is same as documentation reporter except that the tab size is bigger. + Additionally, the reporter constructor accepts parameter to indicate the indentation size + */ overriding member function tab(self in ut_custom_reporter) return varchar2, overriding member procedure print_text(a_text varchar2, a_item_type varchar2 := null), overriding member procedure before_calling_suite(self in out nocopy ut_custom_reporter, a_suite ut_logical_suite), diff --git a/examples/custom_reporters/ut_expectations_reporter.tpb b/examples/custom_reporters/ut_expectations_reporter.tpb new file mode 100644 index 000000000..af9cceb28 --- /dev/null +++ b/examples/custom_reporters/ut_expectations_reporter.tpb @@ -0,0 +1,149 @@ +create or replace type body ut_expectations_reporter is + /* + utPLSQL - Version 3 + Copyright 2016 - 2020 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + constructor function ut_expectations_reporter(a_report_all_expectations varchar2 := 'Y')return self as result is + begin + self.init($$plsql_unit); + self.lvl := 0; + self.report_all_expectations := substr(a_report_all_expectations,1,1); + self.failed_test_running_count := 0; + return; + end; + + /* The reporter procedure after_calling_test from ut_documentation_reporter is overriden here so that: + - the test name is printed + - the test staus is printed + - test duration is printed + - all expectation results from the test are printed (default) or only the failing ones + - error stack trace is printed + - dbms_output from test run is always printed + */ + overriding member procedure after_calling_test(a_test ut_test) as + l_message varchar2(4000); + + procedure print_expectation(a_expectation ut_expectation_result) is + l_lines ut_varchar2_list; + l_failed boolean := a_expectation.status > ut_utils.gc_success; + begin + if l_failed or self.report_all_expectations = 'Y' then + l_lines := a_expectation.get_result_lines(); + for i in 1 .. l_lines.count loop + if l_failed then + self.print_red_text(l_lines(i)); + else + self.print_green_text(l_lines(i)); + end if; + end loop; + self.print_cyan_text(a_expectation.caller_info); + self.print_text(' '); + end if; + end; + + procedure print_results_for_test(a_test ut_test) is + begin + self.lvl := self.lvl + 3; + self.print_red_text(ut_utils.table_to_clob( a_test.get_error_stack_traces() )); + for j in 1 .. a_test.all_expectations.count loop + print_expectation(a_test.all_expectations(j)); + end loop; + self.lvl := self.lvl - 3; + end; + begin + l_message := coalesce(a_test.description, a_test.name)||' ['||round(a_test.execution_time,3)||' sec]'; + --if test failed, then add it to the failures list, print failure with number + if a_test.result = ut_utils.gc_disabled then + self.print_yellow_text(l_message || ' (DISABLED)'); + elsif a_test.result = ut_utils.gc_success then + self.print_green_text(l_message); + elsif a_test.result > ut_utils.gc_success then + self.failed_test_running_count := self.failed_test_running_count + 1; + self.print_red_text(l_message || ' (FAILED - ' || failed_test_running_count || ')'); + end if; + + print_results_for_test(a_test); + -- reproduce the output from before/after procedures and the test + self.print_clob(a_test.get_serveroutputs); + end; + + overriding member procedure after_calling_run(a_run in ut_run) as + l_summary_text varchar2(4000); + l_warning_index pls_integer := 0; + -- make all warning indexes uniformly indented + c_warnings_lpad constant integer := length(to_char(a_run.results_count.warnings_count)); + + procedure print_item_warnings(a_item in ut_suite_item) is + l_items ut_suite_items; + begin + if a_item is of (ut_logical_suite) then + l_items := treat(a_item as ut_logical_suite).items; + for i in 1 .. l_items.count loop + print_item_warnings(l_items(i)); + end loop; + end if; + + if a_item.warnings is not null and a_item.warnings.count > 0 then + for i in 1 .. a_item.warnings.count loop + l_warning_index := l_warning_index + 1; + self.print_text(' ' || lpad(l_warning_index, c_warnings_lpad) || ') ' || a_item.path); + self.lvl := self.lvl + 3; + self.print_red_text(a_item.warnings(i)); + self.lvl := self.lvl - 3; + end loop; + self.print_text(' '); + end if; + end; + + procedure print_warnings(a_run in ut_run) is + begin + if a_run.results_count.warnings_count > 0 then + self.print_text(' '); + self.print_text('Warnings:'); + self.print_text(' '); + for i in 1 .. a_run.items.count loop + print_item_warnings(treat(a_run.items(i) as ut_suite_item)); + end loop; + end if; + end; + + begin + print_warnings(a_run); + self.print_text('Finished in ' || a_run.execution_time || ' seconds'); + + l_summary_text := + a_run.results_count.total_count || ' tests, ' + || a_run.results_count.failure_count || ' failed, ' || a_run.results_count.errored_count || ' errored, ' + || a_run.results_count.disabled_count ||' disabled, ' || a_run.results_count.warnings_count || ' warning(s)'; + if a_run.results_count.failure_count + a_run.results_count.errored_count + a_run.results_count.warnings_count > 0 then + self.print_red_text(l_summary_text); + else + self.print_green_text(l_summary_text); + end if; + if a_run.random_test_order_seed is not null then + self.print_text('Tests were executed with random order seed '''||a_run.random_test_order_seed||'''.'); + end if; + self.print_text(' '); + (self as ut_reporter_base).after_calling_run(a_run); + end; + + overriding member function get_description return varchar2 as + begin + return 'A custom reporter for pretty-printing all expectation results directly under the test'; + end; + +end; +/ diff --git a/examples/custom_reporters/ut_expectations_reporter.tps b/examples/custom_reporters/ut_expectations_reporter.tps new file mode 100644 index 000000000..a4238c302 --- /dev/null +++ b/examples/custom_reporters/ut_expectations_reporter.tps @@ -0,0 +1,30 @@ +create or replace type ut_expectations_reporter under ut_documentation_reporter( + /* + utPLSQL - Version 3 + Copyright 2016 - 2020 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + report_all_expectations varchar2(1), + + + constructor function ut_expectations_reporter(a_report_all_expectations varchar2 := 'Y') return self as result, + + overriding member procedure after_calling_test(a_test ut_test), + overriding member procedure after_calling_run(a_run in ut_run), + + overriding member function get_description return varchar2 + +) +not final +/ diff --git a/examples/demo_of_expectations/demo_equal_matcher.sql b/examples/demo_of_expectations/demo_equal_matcher.sql index 0836eeb52..f7b20581f 100644 --- a/examples/demo_of_expectations/demo_equal_matcher.sql +++ b/examples/demo_of_expectations/demo_equal_matcher.sql @@ -18,7 +18,7 @@ create or replace package demo_equal_matcher as -- %suitepath(org.utplsql.v3.demo.matchers) -- TODO this should go into context(compare_objects, Comparing objects) - -- %context(compare_objects, Comparing objects) + -- %context(Comparing objects) -- %test -- %displayname(Gives success when comparing identical objects containing identical data) @@ -48,7 +48,7 @@ create or replace package demo_equal_matcher as -- %displayname(Gives failure when comparing different objects containing identical data) procedure object_compare_different_type; - -- %end_context + -- %endcontext end; / diff --git a/examples/demo_of_expectations/drop_demo_equal_matcher.sql b/examples/demo_of_expectations/drop_demo_equal_matcher.sql new file mode 100644 index 000000000..8ec8cfa83 --- /dev/null +++ b/examples/demo_of_expectations/drop_demo_equal_matcher.sql @@ -0,0 +1,5 @@ +drop package demo_equal_matcher; +drop type demo_departments; +drop type demo_department_new; +drop type demo_department; + diff --git a/examples/demo_of_expectations/run.sql b/examples/demo_of_expectations/run.sql index a5f93a05f..42a43400c 100644 --- a/examples/demo_of_expectations/run.sql +++ b/examples/demo_of_expectations/run.sql @@ -4,8 +4,5 @@ set serveroutput on size unlimited format truncated exec ut.run(user||'.demo_equal_matcher'); -drop package demo_equal_matcher; -drop type demo_departments; -drop type demo_department_new; -drop type demo_department; +@@drop_demo_equal_matcher.sql diff --git a/examples/developer_examples/RunExampleTestSuiteWithCustomReporter.sql b/examples/developer_examples/RunExampleTestSuiteWithCustomReporter.sql deleted file mode 100644 index 285cbf9a1..000000000 --- a/examples/developer_examples/RunExampleTestSuiteWithCustomReporter.sql +++ /dev/null @@ -1,56 +0,0 @@ ---Shows how to create a test suite with the default reporter which is dbms_output ---No tables are used for this. ---Suite Management packages are when developed will make this easier. ---Clear Screen ---http://stackoverflow.com/questions/2584492/how-to-prevent-dbms-output-put-line-from-trimming-leading-whitespace -Set Serveroutput On Size Unlimited format truncated -set echo off ---install the example unit test packages -@@ut_exampletest.pks -@@ut_exampletest.pkb -@@ut_exampletest2.pks -@@ut_exampletest2.pkb -@@ut_custom_reporter.tps -@@ut_custom_reporter.tpb - -declare - l_suite ut_logical_suite; - l_test ut_test; - l_reporter ut_output_reporter_base; - l_run ut_run; -begin - ut_event_manager.initialize(); - -- Install ut_custom_reporter first from example folder - - l_suite := ut_suite(user, 'ut_exampletest',a_line_no=>1); - - l_test := ut_test(user, 'ut_exampletest','ut_exAmpletest',a_line_no=>3); - l_test.description := 'Example test1'; - l_test.before_test_list := ut_executables(ut_executable(user, 'ut_exampletest','Setup',ut_utils.gc_before_test)); - l_test.after_test_list := ut_executables(ut_executable(user, 'ut_exampletest','tEardown',ut_utils.gc_after_test)); - l_suite.items.extend; - l_suite.items(l_suite.items.last) := l_test; - - l_test := ut_test(user, 'UT_EXAMPLETEST2','ut_exAmpletest',a_line_no=>6); - l_test.description := 'Another example test'; - l_test.before_test_list := ut_executables(ut_executable(user, 'ut_exampletest','SETUP',ut_utils.gc_before_test)); - l_test.after_test_list := ut_executables(ut_executable(user, 'ut_exampletest','TEARDOWN',ut_utils.gc_after_test)); - l_suite.items.extend; - l_suite.items(l_suite.items.last) := l_test; - - -- provide a reporter to process results tabbing each hierarcy level by tab_size - l_reporter := ut_custom_reporter(a_tab_size => 2); - ut_event_manager.add_listener(l_reporter); - l_run := ut_run(ut_suite_items(l_suite)); - l_run.do_execute(); - ut_event_manager.trigger_event(ut_event_manager.gc_finalize, l_run); - l_reporter.lines_to_dbms_output(0,0); -end; -/ - - ---FIXME this drop is causing issues when executing script several times within single session -drop type ut_custom_reporter; -drop package ut_exampletest; -drop package ut_exampletest2; -exec dbms_session.reset_package; From 81d4194383ec00cf2e6cdf10da0443f91256bdc5 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 3 Aug 2020 17:38:34 +0100 Subject: [PATCH 120/887] Fixes to annotation parsing. Resolves #1088 Changed tests to reproduce issue with `dbms_preprocessor` failing to parse source that start with: `package owner.name authid definer is ...` --- test/ut3_tester_helper/annotation_cache_helper.pkb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/ut3_tester_helper/annotation_cache_helper.pkb b/test/ut3_tester_helper/annotation_cache_helper.pkb index 1a52faade..0715b6af1 100644 --- a/test/ut3_tester_helper/annotation_cache_helper.pkb +++ b/test/ut3_tester_helper/annotation_cache_helper.pkb @@ -4,7 +4,7 @@ create or replace package body annotation_cache_helper as pragma autonomous_transaction; begin execute immediate - 'create or replace package ut3_cache_test_owner.granted_test_suite is + 'create or replace package ut3_cache_test_owner.granted_test_suite authid definer is --%suite --%test @@ -19,7 +19,7 @@ create or replace package body annotation_cache_helper as procedure test2 is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; end;'; execute immediate - 'create or replace package ut3_cache_test_owner.not_granted_test_suite is + 'create or replace package ut3_cache_test_owner.not_granted_test_suite authid definer is --%suite --%test @@ -54,7 +54,7 @@ create or replace package body annotation_cache_helper as pragma autonomous_transaction; begin execute immediate - 'create or replace package ut3_cache_test_owner.new_suite is + 'create or replace package ut3_cache_test_owner.new_suite authid definer is --%suite --%test From 86e335e8c534db4f0f93f7a64683971acba1442f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 3 Aug 2020 17:45:34 +0100 Subject: [PATCH 121/887] Fixed issue by removing owner from beginning of source code. --- source/core/annotations/ut_annotation_manager.pkb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index f8ca03326..c9de1c7e4 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -246,6 +246,9 @@ create or replace package body ut_annotation_manager as -- remove the "create [or replace] [[non]editionable] " so that we have only "type|package" for parsing -- needed for dbms_preprocessor l_sql_clob := regexp_replace(l_sql_clob, '^(.*?\s*create(\s+or\s+replace)?(\s+(editionable|noneditionable))?\s+?)((package|type).*)', '\5', 1, 1, 'ni'); + -- remove "OWNER." from create or replace statement. + -- Owner is not supported along with AUTHID - see issue https://github.com/utPLSQL/utPLSQL/issues/1088 + l_sql_clob := regexp_replace(l_sql_clob, '^(package|type)\s+("?[a-zA-Z][a-zA-Z0-9#_$]*"?\.)(.*)', '\1 \3', 1, 1, 'ni'); l_sql_lines := ut_utils.convert_collection( ut_utils.clob_to_table(l_sql_clob) ); end if; open l_result for From 7eeae3967d4b583654008c65ee8b7f11c1eca746 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 9 Aug 2020 13:43:28 +0000 Subject: [PATCH 122/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 0b67eb07c..dd64b7637 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index ac992ab44..f38b2a891 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 9c8ff22d3..3cfb82e48 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 2c808838f..a59a7cc46 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index a3aa9bee9..e5bec6b03 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 3f32da536..03b8172db 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 1d2c81694..8794e6011 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 14e835f69..0f02b8da2 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 52e34332d..7bddca771 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index fa7ebda44..5649582de 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 9a872becf..c1091fffa 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 54aa18234..cbf82ef53 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 09484b850..ed803222d 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c0263af1e..2644fc9e8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 09febcd38..ca1c376c6 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 194c0b44c..777d84a09 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index b5be914e2..736f3b44e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3460--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 6a5788a71..7fd15dd5d 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3460-develop + * secion v3.1.11.3466-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index cc4cc3f52..c704a37ab 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3460-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3466-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From eced7a58415d7f8f7c17ad35f98de222c0f422b6 Mon Sep 17 00:00:00 2001 From: Philipp Salvisberg Date: Wed, 9 Dec 2020 01:12:39 +0100 Subject: [PATCH 123/887] add executable flag (required on macOS and Linux) --- .travis/push_docs_to_github_io.sh | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 .travis/push_docs_to_github_io.sh diff --git a/.travis/push_docs_to_github_io.sh b/.travis/push_docs_to_github_io.sh old mode 100644 new mode 100755 From 7812a8a22643e44ce8012cd02721ef715f343ba1 Mon Sep 17 00:00:00 2001 From: Philipp Salvisberg Date: Wed, 9 Dec 2020 01:25:28 +0100 Subject: [PATCH 124/887] resolves #1111 - use dbms_crypto instead of dbms_obfuscation_toolkit --- source/reporters/ut_coverage_report_html_helper.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index d673a7f6c..f4b633c1f 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -90,7 +90,7 @@ create or replace package body ut_coverage_report_html_helper is function object_id(a_object_full_name varchar2) return varchar2 is begin - return rawtohex(utl_raw.cast_to_raw(dbms_obfuscation_toolkit.md5(input_string => a_object_full_name))); + return rawtohex(dbms_crypto.hash(src => utl_raw.cast_to_raw(a_object_full_name), typ => dbms_crypto.hash_md5)); end; function link_to_source_file(a_object_full_name varchar2) return varchar2 is From 04b5f5287b77cbd62f1aa6ff2ff8fd594ad5dc0b Mon Sep 17 00:00:00 2001 From: Travis CI Date: Wed, 9 Dec 2020 21:57:59 +0000 Subject: [PATCH 125/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index dd64b7637..d40eec597 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index f38b2a891..75a456bfe 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 3cfb82e48..4e33bdfa1 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index a59a7cc46..6fe4368b3 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index e5bec6b03..86f38c43f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 03b8172db..7da4985a6 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8794e6011..06572c9e0 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0f02b8da2..de98a9b5b 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 7bddca771..92eef8dc1 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 5649582de..88d3e0154 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c1091fffa..e0b2b5191 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index cbf82ef53..35ea4b45e 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ed803222d..c87401929 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 2644fc9e8..0c461c71f 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ca1c376c6..ab5252ca3 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 777d84a09..c8ad285ab 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 736f3b44e..7b922264a 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3466--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 7fd15dd5d..6f0be724d 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3466-develop + * secion v3.1.11.3469-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c704a37ab..839deefe7 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3466-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3469-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ae50802f0c05f78f0dc0749a36830de1e802c3bc Mon Sep 17 00:00:00 2001 From: Blaine Carter Date: Thu, 20 May 2021 12:11:05 -0600 Subject: [PATCH 126/887] Added missing tag #1107 The missing tags cause several CICD tools fail when displaying test coverage --- source/reporters/ut_coverage_cobertura_reporter.tpb | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index 2b34193ce..d8aae7f7a 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -79,6 +79,7 @@ create or replace type body ut_coverage_cobertura_reporter is c_packages_footer constant varchar2(30) := ''; c_package_footer constant varchar2(30) := ''; c_class_footer constant varchar2(30) := ''; + c_classes_footer constant varchar2(30) := ''; c_lines_footer constant varchar2(30) := ''; l_epoch varchar2(50) := (sysdate - to_date('01-01-1970 00:00:00', 'dd-mm-yyyy hh24:mi:ss')) * 24 * 60 * 60; begin @@ -116,6 +117,11 @@ create or replace type body ut_coverage_cobertura_reporter is l_result, '' ); + + ut_utils.append_to_list( + l_result, + '' + ); ut_utils.append_to_list( l_result, @@ -129,6 +135,7 @@ create or replace type body ut_coverage_cobertura_reporter is ut_utils.append_to_list(l_result, c_lines_footer); ut_utils.append_to_list(l_result, c_class_footer); + ut_utils.append_to_list(l_result, c_classes_footer); ut_utils.append_to_list(l_result, c_package_footer); l_unit := a_coverage_data.objects.next(l_unit); From 12f9bdfa1d4b60b65234a915d8dfb090e98ba1d5 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 20 May 2021 22:51:29 +0100 Subject: [PATCH 127/887] Updated unit tests after coverage format fix by @OsBlaineOra References: #1137 --- .../reporters/test_coverage/test_cov_cobertura_reporter.pkb | 2 ++ .../reporters/test_coverage/test_coverage_standalone.pkb | 2 ++ test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb | 2 ++ 3 files changed, 6 insertions(+) diff --git a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb index 098405ff9..a18409463 100644 --- a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ -26,12 +26,14 @@ create or replace package body test_cov_cobertura_reporter is + ]'||l_block_cov||q'[ +
]'; diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index bcd933eed..d94108a32 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -21,12 +21,14 @@ create or replace package body test_coverage_standalone is + ]'||l_block_cov||q'[ + ]'; diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index 6171ecb80..81a9a4c58 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -170,6 +170,7 @@ create or replace package body test_proftab_coverage is + @@ -183,6 +184,7 @@ create or replace package body test_proftab_coverage is + ]'; From 75037c8ec46aa280058e047015c9a50a60ec6b0c Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 20 May 2021 23:09:10 +0000 Subject: [PATCH 128/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index d40eec597..8fb6b36a4 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 75a456bfe..9e97f9a38 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 4e33bdfa1..3576d6137 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 6fe4368b3..1acbd4f25 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 86f38c43f..a2c178ad7 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7da4985a6..7b85ca542 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 06572c9e0..7d6801320 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index de98a9b5b..4be85696a 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 92eef8dc1..3698f4076 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 88d3e0154..6da6a5fbe 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index e0b2b5191..1d98faa6c 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 35ea4b45e..db7bff7cd 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index c87401929..e8ff255c5 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 0c461c71f..f15eb029a 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ab5252ca3..fc0d8f714 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c8ad285ab..e8e411613 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 7b922264a..ad5f2bf8f 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3469--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 6f0be724d..05339a831 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3469-develop + * secion v3.1.11.3475-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 839deefe7..3faa88f99 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3469-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3475-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 74985306f9f52b85bdc9ae69729ec402f02a3754 Mon Sep 17 00:00:00 2001 From: Blaine Carter Date: Tue, 1 Jun 2021 14:17:11 -0600 Subject: [PATCH 129/887] Replaced hard coded 0 in total test coverage with covered lines / total total lines. Rounding to 17 decimal places since that's what I found when looking at cobertura examples online. Used an rpad to generate the format mask to avoid having a long string of 9s. This was mentioned in #1107 but does not have an issue of its own. --- source/reporters/ut_coverage_cobertura_reporter.tpb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index d8aae7f7a..7bc8bfcd4 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -90,7 +90,9 @@ create or replace type body ut_coverage_cobertura_reporter is --write header ut_utils.append_to_list( l_result, - '' From 70ccc22ed61ef9b68d0ba64b8226d673b608cef2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 17 Aug 2021 23:15:41 +0100 Subject: [PATCH 130/887] Update readme.md --- readme.md | 1 + 1 file changed, 1 insertion(+) diff --git a/readme.md b/readme.md index 7adecd3e0..e3cc9b8ba 100644 --- a/readme.md +++ b/readme.md @@ -203,3 +203,4 @@ The utPLSQL project is community-driven and is not commercially motivated. Nonet + From 3b7687bf833800739693f4be9b7432ca14528a24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 17 Aug 2021 23:28:23 +0100 Subject: [PATCH 131/887] Update readme.md --- readme.md | 1 - 1 file changed, 1 deletion(-) diff --git a/readme.md b/readme.md index e3cc9b8ba..7adecd3e0 100644 --- a/readme.md +++ b/readme.md @@ -203,4 +203,3 @@ The utPLSQL project is community-driven and is not commercially motivated. Nonet - From cbfac19f1a6ebb599748eee5db50e02093c59e7d Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 17 Aug 2021 22:39:29 +0000 Subject: [PATCH 132/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 8fb6b36a4..299e6b049 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 9e97f9a38..5838bab87 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 3576d6137..e501f57cc 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 1acbd4f25..95ec7714b 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index a2c178ad7..211bf0b10 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7b85ca542..c5618dd9a 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 7d6801320..15fdb6ef9 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 4be85696a..0139d4527 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 3698f4076..360959c9b 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 6da6a5fbe..217c43357 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 1d98faa6c..0a54c9a93 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index db7bff7cd..885b8e63d 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index e8ff255c5..dab73b03a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index f15eb029a..c539e6158 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index fc0d8f714..08387879b 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index e8e411613..b4baa8602 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index ad5f2bf8f..91a0c35d5 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 05339a831..01a7d2637 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3475-develop + * secion v3.1.11.3477-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 3faa88f99..7ecddc593 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3475-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3477-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 4acb559cc42d5c99dd8707ca6e7793fd0f69172e Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 17 Aug 2021 23:44:46 +0100 Subject: [PATCH 133/887] Adjusting build to work with new travis server. --- .travis.yml | 9 ++++----- .travis/trigger_travis.sh | 2 +- readme.md | 3 +-- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/.travis.yml b/.travis.yml index d3299de4e..615851748 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,12 +1,10 @@ sudo: required language: python +os: linux + +jdk: openjdk10 addons: - apt: - packages: - - unzip - # Java9+ Required for Sonar and SQLCL - - openjdk-9-jre-headless sonarcloud: organization: utplsql token: ${SONAR_TOKEN} @@ -65,6 +63,7 @@ cache: - $MAVEN_CFG before_install: + #cache to be used between stages. Based on https://github.com/travis-ci/docs-travis-ci-com/issues/1329 #delete all files in cache that are older than 5 days - mkdir -p $CACHE_DIR/stages_cache; find $CACHE_DIR/stages_cache/ -mtime +5 -exec rm {} \; diff --git a/.travis/trigger_travis.sh b/.travis/trigger_travis.sh index 039b00bbb..10083dd89 100755 --- a/.travis/trigger_travis.sh +++ b/.travis/trigger_travis.sh @@ -15,7 +15,7 @@ echoerr() { echo "$@" 1>&2; } -TRAVIS_URL=travis-ci.org +TRAVIS_URL=travis-ci.com BRANCH=develop USER="utPLSQL" RESULT=1 diff --git a/readme.md b/readme.md index 7adecd3e0..e7bceaac9 100644 --- a/readme.md +++ b/readme.md @@ -8,8 +8,7 @@ [![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) -[![build](https://img.shields.io/travis/utPLSQL/utPLSQL/main.svg?label=main%20branch)](https://travis-ci.org/utPLSQL/utPLSQL) -[![build](https://img.shields.io/travis/utPLSQL/utPLSQL/develop.svg?label=develop%20branch)](https://travis-ci.org/utPLSQL/utPLSQL) +[![build](https://travis-ci.com/utPLSQL/utPLSQL.svg?branch=develop)](https://travis-ci.com/utPLSQL/utPLSQL) [![sonar](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=sqale_rating)](https://sonarcloud.io/dashboard/index?id=utPLSQL) [![Coveralls coverage](https://coveralls.io/repos/github/utPLSQL/utPLSQL/badge.svg?branch=develop)](https://coveralls.io/github/utPLSQL/utPLSQL?branch=develop) From ff1158477c85e59b61f7640af01221204b2be32a Mon Sep 17 00:00:00 2001 From: Travis CI Date: Wed, 18 Aug 2021 22:36:42 +0000 Subject: [PATCH 134/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 299e6b049..31d64ac84 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 5838bab87..d4b01ef7d 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index e501f57cc..c5434f5cb 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 95ec7714b..5f748d405 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 211bf0b10..29abf5a7a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index c5618dd9a..b24e39f26 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 15fdb6ef9..8ceed197f 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0139d4527..ad379211d 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 360959c9b..c222ca214 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 217c43357..4f8175a34 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0a54c9a93..14d79e24b 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 885b8e63d..5e9f2ffb1 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index dab73b03a..a7fd36511 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c539e6158..b5fc20a90 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 08387879b..c0ba24869 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index b4baa8602..1c8b71e27 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 91a0c35d5..6fef62333 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3477--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 01a7d2637..d7dc9e0ed 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3477-develop + * secion v3.1.11.3490-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 7ecddc593..ca18ce4e4 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3477-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3490-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From b0031ab305ffccbded4f5ac2f7a7ab2c8b49dfcb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 3 Sep 2021 17:12:21 +0300 Subject: [PATCH 135/887] Update annotations documentation Resolves #1154 --- docs/userguide/annotations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8ceed197f..faf2bf689 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1029,7 +1029,7 @@ If `--%aftertest` raises an unhandled exception the following will happen: - the `--%afterall` procedures **will be executed** - test execution will continue uninterrupted for rest of the suite -When multiple `--%aftertest` procedures are defined for a test, all of them will be executed before invoking the test. +When multiple `--%aftertest` procedures are defined for a test, all of them will be executed after invoking the test. The order of execution for `--%aftertest` procedures is defined by: - position of procedure on the list within single annotation From b33d395a828c348abf5cd882fafced7bfef0fe2f Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sat, 4 Sep 2021 09:23:49 +0000 Subject: [PATCH 136/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 31d64ac84..abedc2646 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index d4b01ef7d..3ed9e01c3 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index c5434f5cb..eedb55e83 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 5f748d405..6d426ebf9 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 29abf5a7a..dcbda7778 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index b24e39f26..e62f2214d 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index faf2bf689..530d1a535 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index ad379211d..676cbbf9d 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index c222ca214..d1b8e0cb8 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 4f8175a34..a65a09c15 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 14d79e24b..4a56bf00d 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 5e9f2ffb1..6523a9bb2 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index a7fd36511..6f2392411 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index b5fc20a90..a74851764 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index c0ba24869..d02128d9d 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 1c8b71e27..838b2f09e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 6fef62333..b1b14352f 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index d7dc9e0ed..7a4a6db84 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3490-develop + * secion v3.1.11.3491-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index ca18ce4e4..f07a53376 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3490-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3491-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 4e2b9f5f7b5ee5a39fac59a5fc20bb28f7c27d98 Mon Sep 17 00:00:00 2001 From: Blaine Carter Date: Tue, 7 Sep 2021 16:13:23 -0600 Subject: [PATCH 137/887] Fixed a divide by zero error. I introduced the error in the previous commit. To fix I added a l_lines_valid variable, used a case statement to check for 0 else return the calculation. I also replaced the lines_valid calculation to use the new variable to reduce code duplication. --- source/reporters/ut_coverage_cobertura_reporter.tpb | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index 7bc8bfcd4..e34bca79b 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -79,9 +79,10 @@ create or replace type body ut_coverage_cobertura_reporter is c_packages_footer constant varchar2(30) := ''; c_package_footer constant varchar2(30) := '
'; c_class_footer constant varchar2(30) := ''; - c_classes_footer constant varchar2(30) := ''; + c_classes_footer constant varchar2(30) := ''; c_lines_footer constant varchar2(30) := ''; l_epoch varchar2(50) := (sysdate - to_date('01-01-1970 00:00:00', 'dd-mm-yyyy hh24:mi:ss')) * 24 * 60 * 60; + l_lines_valid number := a_coverage_data.covered_lines + a_coverage_data.uncovered_lines; begin ut_utils.append_to_list( l_result, ut_utils.get_xml_header(a_run.client_character_set) ); @@ -91,10 +92,10 @@ create or replace type body ut_coverage_cobertura_reporter is ut_utils.append_to_list( l_result, '' ); From 9cbcaa18e72424a86e931f73e131256ec0c7328e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 29 Oct 2021 12:21:45 +0300 Subject: [PATCH 138/887] Update of slack invite link --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index e7bceaac9..14b8c56ba 100644 --- a/readme.md +++ b/readme.md @@ -5,7 +5,7 @@ [![license](https://img.shields.io/github/license/utPLSQL/utPLSQL.svg)](https://www.apache.org/licenses/LICENSE-2.0) [![latest-release](https://img.shields.io/github/release/utPLSQL/utPLSQL.svg)](https://github.com/utPLSQL/utPLSQL/releases) [![Download statistics](https://img.shields.io/github/downloads/utPLSQL/utPLSQL/total.svg)](http://gra.caldis.me/?url=https://github.com/utPLSQL/utPLSQL) -[![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) +[![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-hsu14tf7-GLUyLpj~x2LIL_F57PMbhA) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) [![build](https://travis-ci.com/utPLSQL/utPLSQL.svg?branch=develop)](https://travis-ci.com/utPLSQL/utPLSQL) From 56ee7c98fa47d04404a6d322a654ef32988e9069 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 29 Oct 2021 12:26:11 +0300 Subject: [PATCH 139/887] Update link for slack --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index 14b8c56ba..e56aba1d4 100644 --- a/readme.md +++ b/readme.md @@ -5,7 +5,7 @@ [![license](https://img.shields.io/github/license/utPLSQL/utPLSQL.svg)](https://www.apache.org/licenses/LICENSE-2.0) [![latest-release](https://img.shields.io/github/release/utPLSQL/utPLSQL.svg)](https://github.com/utPLSQL/utPLSQL/releases) [![Download statistics](https://img.shields.io/github/downloads/utPLSQL/utPLSQL/total.svg)](http://gra.caldis.me/?url=https://github.com/utPLSQL/utPLSQL) -[![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-hsu14tf7-GLUyLpj~x2LIL_F57PMbhA) +[![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) [![build](https://travis-ci.com/utPLSQL/utPLSQL.svg?branch=develop)](https://travis-ci.com/utPLSQL/utPLSQL) From 29677259995bd08bba856b5e513c5dfd919df168 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 3 Nov 2021 15:00:32 +0200 Subject: [PATCH 140/887] Adjusting tests for Oracle21cXE --- .../expectations/test_expectations_json.pkb | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/test/ut3_user/expectations/test_expectations_json.pkb b/test/ut3_user/expectations/test_expectations_json.pkb index 670502c0d..9516ecb04 100644 --- a/test/ut3_user/expectations/test_expectations_json.pkb +++ b/test/ut3_user/expectations/test_expectations_json.pkb @@ -68,9 +68,7 @@ create or replace package body test_expectations_json is --Act ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert - l_expected_message := q'[%Diff: 20 differences found -%3 incorrect types, 4 unequal values, 13 missing properties -%Missing property: "Alexander Skarsg?rd" on path: $ + l_expected_message := q'[%Missing property: "Alexander Skarsg?rd" on path: $ %Extra property: "Alexander Skarsgard" on path: $ %Missing property: "Alice Farmer" on path: $ %Extra property: "Clarke Peters" on path: $ @@ -93,6 +91,10 @@ create or replace package body test_expectations_json is l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); + ut.expect(l_actual_message).to_be_like('%Diff: 20 differences found%'); + ut.expect(l_actual_message).to_be_like('%13 missing properties%'); + ut.expect(l_actual_message).to_be_like('%4 unequal values%'); + ut.expect(l_actual_message).to_be_like('%3 incorrect types%'); end; procedure null_json_variable @@ -1556,9 +1558,7 @@ create or replace package body test_expectations_json is --Act ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); --Assert - l_expected_message := q'[%Diff: 133 differences found, showing first 20 -%132 unequal values, 1 missing properties -%Extra property: object on path: $[5] + l_expected_message := q'[%Extra property: object on path: $[5] %Actual value: "5ce6ec46cb9977b050f15d97" was expected to be: "5ce6ec6660565269b16cf836" on path: $[0]."_id" %Actual value: "5ce6ec469ba57bef5c421021" was expected to be: "5ce6ec66383ddbf3c400e3ed" on path: $[1]."_id" %Actual value: "5ce6ec4632328a654d592cb6" was expected to be: "5ce6ec6600fb7aaee2d1243e" on path: $[3]."_id" @@ -1582,6 +1582,9 @@ create or replace package body test_expectations_json is l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); + ut.expect(l_actual_message).to_be_like('%Diff: 133 differences found, showing first 20%'); + ut.expect(l_actual_message).to_be_like('%1 missing properties%'); + ut.expect(l_actual_message).to_be_like('%132 unequal values%'); end; procedure check_json_objects is From a36d796a63168241cd139f84fc3008fa2e01da79 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 3 Nov 2021 21:30:58 +0200 Subject: [PATCH 141/887] Adding ORacle 21c XE to the build process --- .travis.yml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 615851748..e2f19e950 100644 --- a/.travis.yml +++ b/.travis.yml @@ -48,11 +48,12 @@ env: - MAVEN_HOME=/usr/local/maven - MAVEN_CFG=$HOME/.m2 matrix: - - ORACLE_VERSION="${DOCKER_TAG_11G:-11g-r2-xe}" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_OPTIONS='--shm-size=1g' - - ORACLE_VERSION="${DOCKER_TAG_12C:-12c-r1-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="${DOCKER_TAG_12C2:-12c-r2-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="${DOCKER_TAG_18:-18c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="${DOCKER_TAG_19:-19c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="${DOCKER_TAG_11G:-11g-r2-xe}" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_OPTIONS='--shm-size=1g' + - ORACLE_VERSION="${DOCKER_TAG_12C:-12c-r1-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="${DOCKER_TAG_12C2:-12c-r2-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="${DOCKER_TAG_18:-18c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="${DOCKER_TAG_19:-19c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="${DOCKER_TAG_19:-utplsqlv3/oracledb:21c-xe-full}" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' cache: pip: true From ee7d9e2686c82c1d7f4870100a4e5f1e5bbb2a26 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 3 Nov 2021 21:35:50 +0200 Subject: [PATCH 142/887] Adding Oracle 21c XE to the build process --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index e2f19e950..7d04693e0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -53,7 +53,7 @@ env: - ORACLE_VERSION="${DOCKER_TAG_12C2:-12c-r2-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - ORACLE_VERSION="${DOCKER_TAG_18:-18c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - ORACLE_VERSION="${DOCKER_TAG_19:-19c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="${DOCKER_TAG_19:-utplsqlv3/oracledb:21c-xe-full}" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' + - ORACLE_VERSION="${DOCKER_TAG_21XE:-21c-xe-full}" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' cache: pip: true From e48508f2c6abe3f91f9b146b50bc70f02f2c2d67 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 4 Nov 2021 06:59:20 +0000 Subject: [PATCH 143/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index abedc2646..46014790f 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 3ed9e01c3..6514efb62 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index eedb55e83..b2bdb573c 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 6d426ebf9..7a951b76d 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index dcbda7778..65934b0e8 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index e62f2214d..7b9cfa641 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 530d1a535..6eb8b1b6c 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 676cbbf9d..ded4b085c 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index d1b8e0cb8..f514b031c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a65a09c15..a063f45d2 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 4a56bf00d..670ce1741 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 6523a9bb2..86ec6a4c7 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 6f2392411..8b99a5e0f 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index a74851764..ebc5b12b9 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index d02128d9d..70e0952b3 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 838b2f09e..63a9e0de4 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index b1b14352f..5a62efd2b 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 7a4a6db84..69e6c4725 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3491-develop + * secion v3.1.11.3495-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f07a53376..3f5631aab 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3491-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3495-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 14eca7f6422aaf8998ead771fc53004c94d5d736 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 17 Aug 2021 23:35:47 +0100 Subject: [PATCH 144/887] Adding noparallel hint to elements causing issues on parallel-enabled servers. --- .../ut_annotation_cache_manager.pkb | 31 ++++++++++--------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index 4882108fc..475e05536 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -21,12 +21,12 @@ create or replace package body ut_annotation_cache_manager as l_timestamp timestamp := systimestamp; pragma autonomous_transaction; begin - update ut_annotation_cache_schema s + update /*+ noparallel */ ut_annotation_cache_schema s set s.max_parse_time = l_timestamp where s.object_type = a_object.object_type and s.object_owner = a_object.object_owner; if sql%rowcount = 0 then - insert into ut_annotation_cache_schema s + insert /*+ noparallel */ into ut_annotation_cache_schema s (object_owner, object_type, max_parse_time) values (a_object.object_owner, a_object.object_type, l_timestamp); end if; @@ -34,7 +34,7 @@ create or replace package body ut_annotation_cache_manager as -- if not in trigger, or object has annotations if ora_sysevent is null or a_object.annotations is not null and a_object.annotations.count > 0 then - update ut_annotation_cache_info i + update /*+ noparallel */ ut_annotation_cache_info i set i.parse_time = l_timestamp where (i.object_owner, i.object_name, i.object_type) in ((a_object.object_owner, a_object.object_name, a_object.object_type)) @@ -42,7 +42,7 @@ create or replace package body ut_annotation_cache_manager as if sql%rowcount = 0 then - insert into ut_annotation_cache_info + insert /*+ noparallel */ into ut_annotation_cache_info (cache_id, object_owner, object_name, object_type, parse_time) values (ut_annotation_cache_seq.nextval, a_object.object_owner, a_object.object_name, a_object.object_type, l_timestamp) returning cache_id into l_cache_id; @@ -50,10 +50,10 @@ create or replace package body ut_annotation_cache_manager as end if; - delete from ut_annotation_cache c where cache_id = l_cache_id; + delete /*+ noparallel */ from ut_annotation_cache c where cache_id = l_cache_id; if a_object.annotations is not null and a_object.annotations.count > 0 then - insert into ut_annotation_cache + insert /*+ noparallel */ into ut_annotation_cache (cache_id, annotation_position, annotation_name, annotation_text, subobject_name) select l_cache_id, a.position, a.name, a.text, a.subobject_name from table(a_object.annotations) a; @@ -67,7 +67,7 @@ create or replace package body ut_annotation_cache_manager as pragma autonomous_transaction; begin - delete from ut_annotation_cache c + delete /*+ noparallel */ from ut_annotation_cache c where c.cache_id in (select i.cache_id from ut_annotation_cache_info i @@ -78,7 +78,7 @@ create or replace package body ut_annotation_cache_manager as and o.needs_refresh = 'Y' ); - update ut_annotation_cache_schema s + update /*+ noparallel */ ut_annotation_cache_schema s set s.max_parse_time = l_timestamp where (s.object_owner, s.object_type) in ( @@ -88,14 +88,15 @@ create or replace package body ut_annotation_cache_manager as ); if sql%rowcount = 0 then - insert into ut_annotation_cache_schema s + insert /*+ noparallel */ into ut_annotation_cache_schema s (object_owner, object_type, max_parse_time) select distinct o.object_owner, o.object_type, l_timestamp from table(a_objects) o where o.needs_refresh = 'Y'; end if; - merge into ut_annotation_cache_info i + merge /*+ noparallel */ + into ut_annotation_cache_info i using (select o.object_name, o.object_type, o.object_owner from table(a_objects) o where o.needs_refresh = 'Y' @@ -149,7 +150,7 @@ create or replace package body ut_annotation_cache_manager as procedure set_fully_refreshed(a_object_owner varchar2, a_object_type varchar2) is pragma autonomous_transaction; begin - update ut_annotation_cache_schema s + update /*+ noparallel */ ut_annotation_cache_schema s set s.full_refresh_time = s.max_parse_time where s.object_owner = a_object_owner and s.object_type = a_object_type; @@ -160,7 +161,7 @@ create or replace package body ut_annotation_cache_manager as pragma autonomous_transaction; begin - delete from ut_annotation_cache_info i + delete /*+ noparallel */ from ut_annotation_cache_info i where exists ( select 1 from table (a_objects) o where o.object_name = i.object_name @@ -206,13 +207,13 @@ create or replace package body ut_annotation_cache_manager as l_filter := l_filter || ' and ' || case when a_object_type is null then ':a_object_type is null' else 'object_type = :a_object_type' end; l_cache_filter := ' c.cache_id in (select i.cache_id from ut_annotation_cache_info i where ' || l_filter || ' )'; end if; - execute immediate 'delete from ut_annotation_cache c where ' || l_cache_filter + execute immediate 'delete /*+ noparallel */ from ut_annotation_cache c where ' || l_cache_filter using a_object_owner, a_object_type; - execute immediate ' delete from ut_annotation_cache_info i where ' || l_filter + execute immediate ' delete /*+ noparallel */ from ut_annotation_cache_info i where ' || l_filter using a_object_owner, a_object_type; - execute immediate ' delete from ut_annotation_cache_schema s where ' || l_filter + execute immediate ' delete /*+ noparallel */ from ut_annotation_cache_schema s where ' || l_filter using a_object_owner, a_object_type; commit; From f35694e744e2bd8d322a0f3a153cfe54c36b5525 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 7 Nov 2021 22:34:57 +0200 Subject: [PATCH 145/887] Added no_parallel hints to all SQLs to assure stable performance on parallel-enabled systems. --- source/api/ut.pkb | 2 +- source/check_object_grants.sql | 2 +- .../ut_annotation_cache_manager.pkb | 50 +++++++++---------- .../annotations/ut_annotation_manager.pkb | 12 ++--- .../core/annotations/ut_annotation_parser.pkb | 2 +- source/core/coverage/ut_coverage.pkb | 2 +- source/core/coverage/ut_coverage_helper.pkb | 10 ++-- .../coverage/ut_coverage_helper_block.pkb | 3 +- .../coverage/ut_coverage_helper_profiler.pkb | 2 +- .../coverage/ut_coverage_reporter_base.tpb | 4 +- .../output_buffers/ut_output_buffer_base.tpb | 8 +-- .../ut_output_clob_table_buffer.tpb | 14 +++--- .../output_buffers/ut_output_table_buffer.tpb | 14 +++--- source/core/types/ut_output_reporter_base.tpb | 2 +- source/core/types/ut_run_info.tpb | 10 ++-- source/core/ut_dbms_output_cache.sql | 2 +- source/core/ut_expectation_processor.pkb | 2 +- source/core/ut_metadata.pkb | 10 ++-- source/core/ut_suite_cache_manager.pkb | 50 +++++++++---------- source/core/ut_suite_manager.pkb | 10 ++-- source/core/ut_utils.pkb | 16 +++--- .../data_values/ut_compound_data_helper.pkb | 20 ++++---- .../data_values/ut_cursor_details.tpb | 16 +++--- .../data_values/ut_data_value_anydata.tpb | 4 +- .../data_values/ut_data_value_refcursor.tpb | 2 +- source/reporters/ut_debug_reporter.tpb | 2 +- 26 files changed, 136 insertions(+), 135 deletions(-) diff --git a/source/api/ut.pkb b/source/api/ut.pkb index 3b94a2bf7..81d3e59a7 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -674,7 +674,7 @@ create or replace package body ut is procedure set_nls is begin if g_nls_date_format is null then - select nsp.value + select /*+ no_parallel */ nsp.value into g_nls_date_format from nls_session_parameters nsp where parameter = 'NLS_DATE_FORMAT'; diff --git a/source/check_object_grants.sql b/source/check_object_grants.sql index d499ced9c..5f560e6b1 100644 --- a/source/check_object_grants.sql +++ b/source/check_object_grants.sql @@ -24,7 +24,7 @@ begin l_target_table := get_view('dba_tab_privs'); l_owner_column := case when l_target_table like 'dba%' then 'owner' else 'table_schema' end; execute immediate q'[ - select listagg(' - '||object_name,CHR(10)) within group(order by object_name) + select /*+ no_parallel */ listagg(' - '||object_name,CHR(10)) within group(order by object_name) from ( select column_value as object_name from table(:l_expected_grants) diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index 475e05536..cef6fa519 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -21,12 +21,12 @@ create or replace package body ut_annotation_cache_manager as l_timestamp timestamp := systimestamp; pragma autonomous_transaction; begin - update /*+ noparallel */ ut_annotation_cache_schema s + update /*+ no_parallel */ ut_annotation_cache_schema s set s.max_parse_time = l_timestamp where s.object_type = a_object.object_type and s.object_owner = a_object.object_owner; if sql%rowcount = 0 then - insert /*+ noparallel */ into ut_annotation_cache_schema s + insert /*+ no_parallel */ into ut_annotation_cache_schema s (object_owner, object_type, max_parse_time) values (a_object.object_owner, a_object.object_type, l_timestamp); end if; @@ -34,7 +34,7 @@ create or replace package body ut_annotation_cache_manager as -- if not in trigger, or object has annotations if ora_sysevent is null or a_object.annotations is not null and a_object.annotations.count > 0 then - update /*+ noparallel */ ut_annotation_cache_info i + update /*+ no_parallel */ ut_annotation_cache_info i set i.parse_time = l_timestamp where (i.object_owner, i.object_name, i.object_type) in ((a_object.object_owner, a_object.object_name, a_object.object_type)) @@ -42,7 +42,7 @@ create or replace package body ut_annotation_cache_manager as if sql%rowcount = 0 then - insert /*+ noparallel */ into ut_annotation_cache_info + insert /*+ no_parallel */ into ut_annotation_cache_info (cache_id, object_owner, object_name, object_type, parse_time) values (ut_annotation_cache_seq.nextval, a_object.object_owner, a_object.object_name, a_object.object_type, l_timestamp) returning cache_id into l_cache_id; @@ -50,12 +50,12 @@ create or replace package body ut_annotation_cache_manager as end if; - delete /*+ noparallel */ from ut_annotation_cache c where cache_id = l_cache_id; + delete /*+ no_parallel */ from ut_annotation_cache c where cache_id = l_cache_id; if a_object.annotations is not null and a_object.annotations.count > 0 then - insert /*+ noparallel */ into ut_annotation_cache + insert /*+ no_parallel */ into ut_annotation_cache (cache_id, annotation_position, annotation_name, annotation_text, subobject_name) - select l_cache_id, a.position, a.name, a.text, a.subobject_name + select /*+ no_parallel */ l_cache_id, a.position, a.name, a.text, a.subobject_name from table(a_object.annotations) a; end if; commit; @@ -67,9 +67,9 @@ create or replace package body ut_annotation_cache_manager as pragma autonomous_transaction; begin - delete /*+ noparallel */ from ut_annotation_cache c + delete /*+ no_parallel */ from ut_annotation_cache c where c.cache_id - in (select i.cache_id + in (select /*+ no_parallel */ i.cache_id from ut_annotation_cache_info i join table (a_objects) o on o.object_name = i.object_name @@ -78,26 +78,26 @@ create or replace package body ut_annotation_cache_manager as and o.needs_refresh = 'Y' ); - update /*+ noparallel */ ut_annotation_cache_schema s + update /*+ no_parallel */ ut_annotation_cache_schema s set s.max_parse_time = l_timestamp where (s.object_owner, s.object_type) in ( - select o.object_owner, o.object_type + select /*+ no_parallel */ o.object_owner, o.object_type from table(a_objects) o where o.needs_refresh = 'Y' ); if sql%rowcount = 0 then - insert /*+ noparallel */ into ut_annotation_cache_schema s + insert /*+ no_parallel */ into ut_annotation_cache_schema s (object_owner, object_type, max_parse_time) - select distinct o.object_owner, o.object_type, l_timestamp + select /*+ no_parallel */ distinct o.object_owner, o.object_type, l_timestamp from table(a_objects) o where o.needs_refresh = 'Y'; end if; - merge /*+ noparallel */ + merge /*+ no_parallel */ into ut_annotation_cache_info i - using (select o.object_name, o.object_type, o.object_owner + using (select /*+ no_parallel */ o.object_name, o.object_type, o.object_owner from table(a_objects) o where o.needs_refresh = 'Y' ) o @@ -117,7 +117,7 @@ create or replace package body ut_annotation_cache_manager as function get_cached_objects_list(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return ut_annotation_objs_cache_info is l_result ut_annotation_objs_cache_info; begin - select ut_annotation_obj_cache_info( + select /*+ no_parallel */ ut_annotation_obj_cache_info( object_owner => i.object_owner, object_name => i.object_name, object_type => i.object_type, @@ -136,7 +136,7 @@ create or replace package body ut_annotation_cache_manager as l_result t_cache_schema_info; begin begin - select * + select /*+ no_parallel */ * into l_result from ut_annotation_cache_schema s where s.object_type = a_object_type and s.object_owner = a_object_owner; @@ -150,7 +150,7 @@ create or replace package body ut_annotation_cache_manager as procedure set_fully_refreshed(a_object_owner varchar2, a_object_type varchar2) is pragma autonomous_transaction; begin - update /*+ noparallel */ ut_annotation_cache_schema s + update /*+ no_parallel */ ut_annotation_cache_schema s set s.full_refresh_time = s.max_parse_time where s.object_owner = a_object_owner and s.object_type = a_object_type; @@ -161,9 +161,9 @@ create or replace package body ut_annotation_cache_manager as pragma autonomous_transaction; begin - delete /*+ noparallel */ from ut_annotation_cache_info i + delete /*+ no_parallel */ from ut_annotation_cache_info i where exists ( - select 1 from table (a_objects) o + select /*+ no_parallel */ 1 from table (a_objects) o where o.object_name = i.object_name and o.object_type = i.object_type and o.object_owner = i.object_owner @@ -176,7 +176,7 @@ create or replace package body ut_annotation_cache_manager as l_results sys_refcursor; begin open l_results for - select ut_annotated_object( + select /*+ no_parallel */ ut_annotated_object( i.object_owner, i.object_name, i.object_type, i.parse_time, cast( collect( @@ -205,15 +205,15 @@ create or replace package body ut_annotation_cache_manager as else l_filter := case when a_object_owner is null then ':a_object_owner is null' else 'object_owner = :a_object_owner' end; l_filter := l_filter || ' and ' || case when a_object_type is null then ':a_object_type is null' else 'object_type = :a_object_type' end; - l_cache_filter := ' c.cache_id in (select i.cache_id from ut_annotation_cache_info i where ' || l_filter || ' )'; + l_cache_filter := ' c.cache_id in (select /*+ no_parallel */ i.cache_id from ut_annotation_cache_info i where ' || l_filter || ' )'; end if; - execute immediate 'delete /*+ noparallel */ from ut_annotation_cache c where ' || l_cache_filter + execute immediate 'delete /*+ no_parallel */ from ut_annotation_cache c where ' || l_cache_filter using a_object_owner, a_object_type; - execute immediate ' delete /*+ noparallel */ from ut_annotation_cache_info i where ' || l_filter + execute immediate ' delete /*+ no_parallel */ from ut_annotation_cache_info i where ' || l_filter using a_object_owner, a_object_type; - execute immediate ' delete /*+ noparallel */ from ut_annotation_cache_schema s where ' || l_filter + execute immediate ' delete /*+ no_parallel */ from ut_annotation_cache_schema s where ' || l_filter using a_object_owner, a_object_type; commit; diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index c9de1c7e4..ca0c358cf 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -34,7 +34,7 @@ create or replace package body ut_annotation_manager as l_cached_objects := ut_annotation_cache_manager.get_cached_objects_list( a_object_owner, a_object_type ); if l_cached_objects is not empty then - execute immediate 'select /*+ cardinality(i '||ut_utils.scale_cardinality(cardinality(l_cached_objects))||') */ + execute immediate 'select /*+ no_parallel cardinality(i '||ut_utils.scale_cardinality(cardinality(l_cached_objects))||') */ value(i) from table( :l_data ) i where @@ -71,7 +71,7 @@ create or replace package body ut_annotation_manager as --limit the list to objects that exist and are visible to the invoking user --enrich the list by info about cache validity execute immediate - 'select /*+ cardinality(i '||ut_utils.scale_cardinality(cardinality(l_cached_objects))||') */ + 'select /*+ no_parallel cardinality(i '||ut_utils.scale_cardinality(cardinality(l_cached_objects))||') */ '||l_ut_owner||q'[.ut_annotation_obj_cache_info( object_owner => o.owner, object_name => o.object_name, @@ -108,7 +108,7 @@ create or replace package body ut_annotation_manager as begin l_card := ut_utils.scale_cardinality(cardinality(a_objects_to_refresh)); open l_result for - q'[select x.name, x.text + q'[select /*+ no_parallel */ x.name, x.text from (select /*+ cardinality( r ]'||l_card||q'[ )*/ s.name, s.text, s.line, max(case when s.text like '%--%\%%' escape '\' @@ -252,7 +252,7 @@ create or replace package body ut_annotation_manager as l_sql_lines := ut_utils.convert_collection( ut_utils.clob_to_table(l_sql_clob) ); end if; open l_result for - select a_object_name as name, column_value||chr(10) as text from table(l_sql_lines); + select /*+ no_parallel */ a_object_name as name, column_value||chr(10) as text from table(l_sql_lines); return l_result; end; @@ -261,7 +261,7 @@ create or replace package body ut_annotation_manager as l_sources_view varchar2(200) := ut_metadata.get_source_view_name(); begin open l_result for - q'[select :a_object_name, s.text + q'[select /*+ no_parallel */ :a_object_name, s.text from ]'||l_sources_view||q'[ s where s.type = :a_object_type and s.owner = :a_object_owner @@ -279,7 +279,7 @@ create or replace package body ut_annotation_manager as 'GSMCATUSER','GSMUSER','ORACLE_OCM','OUTLN','REMOTE_SCHEDULER_AGENT','SYS','SYS$UMF', 'SYSBACKUP','SYSDG','SYSKM','SYSRAC','SYSTEM','WMSYS','XDB','XS$NULL'); $else - select username bulk collect into l_restricted_users + select /*+ no_parallel */ username bulk collect into l_restricted_users from all_users where oracle_maintained = 'Y'; $end if ora_dict_obj_owner member of l_restricted_users then diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 6248f36b9..6ef15a3ac 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -210,7 +210,7 @@ create or replace package body ut_annotation_parser as dbms_lob.freetemporary(l_source); - select value(x) bulk collect into l_result from table(l_annotations) x order by x.position; + select /*+ no_parallel */ value(x) bulk collect into l_result from table(l_annotations) x order by x.position; return l_result; end parse_object_annotations; diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 81d17704a..1900e6c3c 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -77,7 +77,7 @@ create or replace package body ut_coverage is end as to_be_skipped from sources s ) - select full_name, owner, name, type, line, to_be_skipped, text + select /*+ no_parallel */ full_name, owner, name, type, line, to_be_skipped, text from coverage_sources s -- Exclude calls to utPLSQL framework, Unit Test packages and objects from a_exclude_list parameter of coverage reporter where (s.owner, s.name) not in ( select /*+ cardinality(el {skipped_objects_cardinality})*/el.owner, el.name from table(:l_skipped_objects) el ) diff --git a/source/core/coverage/ut_coverage_helper.pkb b/source/core/coverage/ut_coverage_helper.pkb index 4c41aa2f6..a000237c6 100644 --- a/source/core/coverage/ut_coverage_helper.pkb +++ b/source/core/coverage/ut_coverage_helper.pkb @@ -35,7 +35,7 @@ create or replace package body ut_coverage_helper is procedure insert_into_tmp_table(a_data t_coverage_sources_tmp_rows) is begin forall i in 1 .. a_data.count - insert into ut_coverage_sources_tmp + insert /*+ no_parallel */ into ut_coverage_sources_tmp (full_name,owner,name,type,line,text,to_be_skipped) values(a_data(i).full_name,a_data(i).owner,a_data(i).name,a_data(i).type,a_data(i).line,a_data(i).text,a_data(i).to_be_skipped); end; @@ -49,7 +49,7 @@ create or replace package body ut_coverage_helper is function is_tmp_table_populated return boolean is l_result integer; begin - select 1 into l_result from ut_coverage_sources_tmp where rownum = 1; + select /*+ no_parallel */ 1 into l_result from ut_coverage_sources_tmp where rownum = 1; return (l_result = 1); exception when no_data_found then @@ -60,7 +60,7 @@ create or replace package body ut_coverage_helper is l_result t_tmp_table_objects_crsr; begin open l_result for - select o.owner, o.name, o.type, o.full_name, max(o.line) as lines_count, + select /*+ no_parallel */ o.owner, o.name, o.type, o.full_name, max(o.line) as lines_count, cast( collect(decode(to_be_skipped, 'Y', to_char(line))) as ut_varchar2_list ) as to_be_skipped_list @@ -73,7 +73,7 @@ create or replace package body ut_coverage_helper is function get_tmp_table_object_lines(a_owner varchar2, a_object_name varchar2) return ut_varchar2_list is l_result ut_varchar2_list; begin - select rtrim(s.text,chr(10)) as text + select /*+ no_parallel */ rtrim(s.text,chr(10)) as text bulk collect into l_result from ut_coverage_sources_tmp s where s.owner = a_owner @@ -86,7 +86,7 @@ create or replace package body ut_coverage_helper is procedure set_coverage_run_ids( a_coverage_run_id raw, a_line_coverage_id integer, a_block_coverage_id integer ) is pragma autonomous_transaction; begin - insert into ut_coverage_runs + insert /*+ no_parallel */ into ut_coverage_runs ( coverage_run_id, line_coverage_id, block_coverage_id ) values ( a_coverage_run_id, a_line_coverage_id, a_block_coverage_id ); diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index e030f2c37..913b0fb4c 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -46,7 +46,8 @@ create or replace package body ut_coverage_helper_block is l_ut_owner varchar2(250) := ut_utils.ut_owner; begin execute immediate q'[ - select line as line, + select /*+ no_parallel */ + line as line, count(block) as blocks, sum(covered) as covered_blocks from (select line, diff --git a/source/core/coverage/ut_coverage_helper_profiler.pkb b/source/core/coverage/ut_coverage_helper_profiler.pkb index dacfcbaa3..22aa6619d 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pkb +++ b/source/core/coverage/ut_coverage_helper_profiler.pkb @@ -58,7 +58,7 @@ create or replace package body ut_coverage_helper_profiler is function proftab_results(a_object ut_coverage_helper.t_tmp_table_object, a_coverage_run_id raw) return t_proftab_rows is l_coverage_rows t_proftab_rows; begin - select + select /*+ no_parallel */ d.line#, case when sum(d.total_occur) = 0 and sum(d.total_time) > 0 then 1 else sum(d.total_occur) end total_occur bulk collect into l_coverage_rows diff --git a/source/core/coverage/ut_coverage_reporter_base.tpb b/source/core/coverage/ut_coverage_reporter_base.tpb index 96c4b5066..1cc856ea6 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tpb +++ b/source/core/coverage/ut_coverage_reporter_base.tpb @@ -93,7 +93,7 @@ create or replace type body ut_coverage_reporter_base is (l_reporter as ut_output_reporter_base).before_calling_run(null); l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options, a_client_character_set => a_client_character_set ) ); l_reporter.on_finalize(null); - for i in (select x.text from table(l_reporter.get_lines(1, 1)) x ) loop + for i in (select /*+ no_parallel */ x.text from table(l_reporter.get_lines(1, 1)) x ) loop pipe row (i.text); end loop; return; @@ -107,7 +107,7 @@ create or replace type body ut_coverage_reporter_base is (l_reporter as ut_output_reporter_base).before_calling_run(null); l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options, a_client_character_set => a_client_character_set ) ); l_reporter.on_finalize(null); - open l_result for select x.text from table(l_reporter.get_lines(1, 1)) x; + open l_result for select /*+ no_parallel */ x.text from table(l_reporter.get_lines(1, 1)) x; return l_result; end; diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index 38f008e75..412f30836 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -25,11 +25,11 @@ create or replace type body ut_output_buffer_base is self.output_id := coalesce(a_output_id, self.output_id, sys_guid()); self.start_date := coalesce(self.start_date, sysdate); self.last_message_id := 0; - select count(*) into l_exists from ut_output_buffer_info_tmp where output_id = self.output_id; + select /*+ no_parallel */ count(*) into l_exists from ut_output_buffer_info_tmp where output_id = self.output_id; if ( l_exists > 0 ) then - update ut_output_buffer_info_tmp set start_date = self.start_date where output_id = self.output_id; + update /*+ no_parallel */ ut_output_buffer_info_tmp set start_date = self.start_date where output_id = self.output_id; else - insert into ut_output_buffer_info_tmp(output_id, start_date) values (self.output_id, self.start_date); + insert /*+ no_parallel */ into ut_output_buffer_info_tmp(output_id, start_date) values (self.output_id, self.start_date); end if; commit; self.is_closed := 0; @@ -39,7 +39,7 @@ create or replace type body ut_output_buffer_base is l_lines sys_refcursor; begin open l_lines for - select text, item_type + select /*+ no_parallel */ text, item_type from table(self.get_lines(a_initial_timeout, a_timeout_sec)); return l_lines; end; diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index 8c2825151..8d23b9422 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -26,7 +26,7 @@ create or replace type body ut_output_clob_table_buffer is pragma autonomous_transaction; begin self.last_message_id := self.last_message_id + 1; - insert into ut_output_clob_buffer_tmp(output_id, message_id, is_finished) + insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, is_finished) values (self.output_id, self.last_message_id, 1); commit; self.is_closed := 1; @@ -37,7 +37,7 @@ create or replace type body ut_output_clob_table_buffer is begin if a_text is not null or a_item_type is not null then self.last_message_id := self.last_message_id + 1; - insert into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) + insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) values (self.output_id, self.last_message_id, a_text, a_item_type); end if; commit; @@ -46,8 +46,8 @@ create or replace type body ut_output_clob_table_buffer is overriding member procedure send_lines(self in out nocopy ut_output_clob_table_buffer, a_text_list ut_varchar2_rows, a_item_type varchar2 := null) is pragma autonomous_transaction; begin - insert into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) - select self.output_id, self.last_message_id + rownum, t.column_value, a_item_type + insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) + select /*+ no_parallel */ self.output_id, self.last_message_id + rownum, t.column_value, a_item_type from table(a_text_list) t where t.column_value is not null or a_item_type is not null; self.last_message_id := self.last_message_id + SQL%rowcount; @@ -59,7 +59,7 @@ create or replace type body ut_output_clob_table_buffer is begin if a_text is not null and a_text != empty_clob() or a_item_type is not null then self.last_message_id := self.last_message_id + 1; - insert into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) + insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) values (self.output_id, self.last_message_id, a_text, a_item_type); end if; commit; @@ -102,13 +102,13 @@ create or replace type body ut_output_clob_table_buffer is begin while not l_finished loop with ordered_buffer as ( - select /*+ index(a) */ a.rowid, ut_output_data_row(a.text, a.item_type), is_finished + select /*+ no_parallel index(a) */ a.rowid, ut_output_data_row(a.text, a.item_type), is_finished from ut_output_clob_buffer_tmp a where a.output_id = self.output_id and a.message_id <= l_max_message_id order by a.message_id ) - select b.* + select /*+ no_parallel */ b.* bulk collect into l_message_rowids, l_buffer_data, l_finished_flags from ordered_buffer b; diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index e3f869b22..5f9c536f9 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -26,7 +26,7 @@ create or replace type body ut_output_table_buffer is pragma autonomous_transaction; begin self.last_message_id := self.last_message_id + 1; - insert into ut_output_buffer_tmp(output_id, message_id, is_finished) + insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, is_finished) values (self.output_id, self.last_message_id, 1); commit; self.is_closed := 1; @@ -45,7 +45,7 @@ create or replace type body ut_output_table_buffer is ); else self.last_message_id := self.last_message_id + 1; - insert into ut_output_buffer_tmp(output_id, message_id, text, item_type) + insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) values (self.output_id, self.last_message_id, a_text, a_item_type); end if; commit; @@ -55,8 +55,8 @@ create or replace type body ut_output_table_buffer is overriding member procedure send_lines(self in out nocopy ut_output_table_buffer, a_text_list ut_varchar2_rows, a_item_type varchar2 := null) is pragma autonomous_transaction; begin - insert into ut_output_buffer_tmp(output_id, message_id, text, item_type) - select self.output_id, self.last_message_id + rownum, t.column_value, a_item_type + insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) + select /*+ no_parallel */ self.output_id, self.last_message_id + rownum, t.column_value, a_item_type from table(a_text_list) t where t.column_value is not null or a_item_type is not null; self.last_message_id := self.last_message_id + SQL%rowcount; @@ -76,7 +76,7 @@ create or replace type body ut_output_table_buffer is ); else self.last_message_id := self.last_message_id + 1; - insert into ut_output_buffer_tmp(output_id, message_id, text, item_type) + insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) values (self.output_id, self.last_message_id, a_text, a_item_type); end if; commit; @@ -107,8 +107,8 @@ create or replace type body ut_output_table_buffer is ) is pragma autonomous_transaction; begin - delete from ( - select * + delete /*+ no_parallel */ from ( + select /*+ no_parallel */ * from ut_output_buffer_tmp o where o.output_id = self.output_id and o.message_id <= a_max_message_id diff --git a/source/core/types/ut_output_reporter_base.tpb b/source/core/types/ut_output_reporter_base.tpb index c4ba73ba5..b8dc24667 100644 --- a/source/core/types/ut_output_reporter_base.tpb +++ b/source/core/types/ut_output_reporter_base.tpb @@ -65,7 +65,7 @@ create or replace type body ut_output_reporter_base is final member function get_lines(a_initial_timeout natural := null, a_timeout_sec natural) return ut_output_data_rows pipelined is begin - for i in (select value(x) val from table(self.output_buffer.get_lines(a_initial_timeout, a_timeout_sec)) x ) loop + for i in (select /*+ no_parallel */ value(x) val from table(self.output_buffer.get_lines(a_initial_timeout, a_timeout_sec)) x ) loop pipe row (i.val); end loop; end; diff --git a/source/core/types/ut_run_info.tpb b/source/core/types/ut_run_info.tpb index 8e06d6137..ffa1a6372 100644 --- a/source/core/types/ut_run_info.tpb +++ b/source/core/types/ut_run_info.tpb @@ -20,27 +20,27 @@ create or replace type body ut_run_info as begin self.self_type := $$plsql_unit; execute immediate - 'select '||l_ut_owner||'.ut.version() from dual' + 'select /*+ no_parallel */ '||l_ut_owner||'.ut.version() from dual' into self.ut_version; dbms_utility.db_version( self.db_version, self.db_compatibility ); db_os_type := dbms_utility.port_string(); execute immediate - 'select '||l_ut_owner||'.ut_key_value_pair(x.product, x.version) from product_component_version x' + 'select /*+ no_parallel */ '||l_ut_owner||'.ut_key_value_pair(x.product, x.version) from product_component_version x' bulk collect into self.db_component_version; execute immediate - 'select '||l_ut_owner||'.ut_key_value_pair(x.parameter, x.value) + 'select /*+ no_parallel */ '||l_ut_owner||'.ut_key_value_pair(x.parameter, x.value) from nls_session_parameters x' bulk collect into self.nls_session_params; execute immediate - 'select '||l_ut_owner||'.ut_key_value_pair(x.parameter, x.value) from nls_instance_parameters x' + 'select /*+ no_parallel */ '||l_ut_owner||'.ut_key_value_pair(x.parameter, x.value) from nls_instance_parameters x' bulk collect into self.nls_instance_params; execute immediate - 'select '||l_ut_owner||'.ut_key_value_pair(x.parameter, x.value) from nls_database_parameters x' + 'select /*+ no_parallel */ '||l_ut_owner||'.ut_key_value_pair(x.parameter, x.value) from nls_database_parameters x' bulk collect into self.nls_db_params; return; end; diff --git a/source/core/ut_dbms_output_cache.sql b/source/core/ut_dbms_output_cache.sql index 1fe4251c7..3d4c12845 100644 --- a/source/core/ut_dbms_output_cache.sql +++ b/source/core/ut_dbms_output_cache.sql @@ -19,7 +19,7 @@ limitations under the License. declare l_tab_exist number; begin - select count(*) into l_tab_exist from + select /*+ no_parallel */ count(*) into l_tab_exist from (select table_name from all_tables where table_name = 'UT_DBMS_OUTPUT_CACHE' and owner = sys_context('USERENV','CURRENT_SCHEMA') union all select synonym_name from all_synonyms where synonym_name = 'UT_DBMS_OUTPUT_CACHE' and owner = sys_context('USERENV','CURRENT_SCHEMA')); diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index d65d210c8..22e268dca 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -104,7 +104,7 @@ create or replace package body ut_expectation_processor as function get_session_parameters return tt_nls_params is l_session_params tt_nls_params; begin - select nsp.parameter, nsp.value + select /*+ no_parallel */ nsp.parameter, nsp.value bulk collect into l_session_params from nls_session_parameters nsp where parameter diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index 727dd6318..3afc9d1c6 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -39,7 +39,7 @@ create or replace package body ut_metadata as l_view_name varchar2(200) := get_objects_view_name; begin - execute immediate q'[select count(*) + execute immediate q'[select /*+ no_parallel */ count(*) from ]'||l_view_name||q'[ where owner = :a_owner_name and object_name = :a_package_name @@ -58,7 +58,7 @@ create or replace package body ut_metadata as l_view_name varchar2(200) := get_dba_view('dba_procedures'); begin execute immediate - 'select count(*) from '||l_view_name + 'select /*+ no_parallel */ count(*) from '||l_view_name ||' where owner = :l_schema and object_name = :l_package_name and procedure_name = :l_procedure_name and rownum = 1' into l_cnt using a_owner_name, a_package_name, a_procedure_name; @@ -77,7 +77,7 @@ create or replace package body ut_metadata as if not nvl(c_key = g_cached_object, false) then g_cached_object := c_key; execute immediate - 'select trim(text) text + 'select /*+ no_parallel */ trim(text) text from '||l_view_name||q'[ s where s.owner = :a_owner and s.name = :a_object_name @@ -123,7 +123,7 @@ create or replace package body ut_metadata as function user_has_execute_any_proc return boolean is l_has_execute_any varchar2(1); begin - select decode( count( 1 ), 0, 'N', 'Y' ) + select /*+ no_parallel */ decode( count( 1 ), 0, 'N', 'Y' ) into l_has_execute_any from dual where @@ -157,7 +157,7 @@ create or replace package body ut_metadata as l_cnt number; c_current_schema constant all_tables.owner%type := sys_context('USERENV','CURRENT_SCHEMA'); begin - select count(*) + select /*+ no_parallel */ count(*) into l_cnt from all_objects t where t.object_name = a_object_name diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 06c4c76a5..ebc9a839d 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -79,7 +79,7 @@ create or replace package body ut_suite_cache_manager is union all select obj from logical_suites ) - select c.obj + select /*+ no_parallel */ c.obj from items c order by c.obj.object_owner,{:random_seed:}]'; @@ -89,7 +89,7 @@ create or replace package body ut_suite_cache_manager is begin l_data := ut_annotation_cache_manager.get_cached_objects_list(a_object_owner, 'PACKAGE'); - select i.object_name + select /*+ no_parallel */ i.object_name bulk collect into l_result from ut_suite_cache_package i where not exists ( @@ -172,7 +172,7 @@ create or replace package body ut_suite_cache_manager is 'nls_sort=binary' )desc nulls last, case when c.obj.self_type = 'UT_SUITE_CONTEXT' then - ( select max( x.line_no ) + 1 + ( select /*+ no_parallel */ max( x.line_no ) + 1 from ut_suite_cache x where c.obj.object_owner = x.object_owner and c.obj.object_name = x.object_name @@ -216,18 +216,18 @@ create or replace package body ut_suite_cache_manager is l_procedure_name varchar2(250) := ut_utils.qualified_sql_name(a_procedure_name); begin - select column_value + select /*+ no_parallel */ column_value bulk collect into l_include_tags from table(l_tags) where column_value not like '-%'; - select ltrim(column_value,'-') + select /*+ no_parallel */ ltrim(column_value,'-') bulk collect into l_exclude_tags from table(l_tags) where column_value like '-%'; if a_path is null and a_object_name is not null then - select min(c.path) + select /*+ no_parallel */ min(c.path) into l_path from ut_suite_cache c where c.object_owner = upper(l_object_owner) @@ -258,7 +258,7 @@ create or replace package body ut_suite_cache_manager is function get_schema_parse_time(a_schema_name varchar2) return timestamp result_cache is l_cache_parse_time timestamp; begin - select min(t.parse_time) + select /*+ no_parallel */ min(t.parse_time) into l_cache_parse_time from ut_suite_cache_schema t where object_owner = upper(a_schema_name); @@ -288,7 +288,7 @@ create or replace package body ut_suite_cache_manager is else - select min(parse_time) + select /*+ no_parallel */ min(parse_time) into l_cached_parse_time from ut_suite_cache_package t where t.object_name = l_object_name @@ -296,23 +296,23 @@ create or replace package body ut_suite_cache_manager is if a_parse_time > l_cached_parse_time or l_cached_parse_time is null then - update ut_suite_cache_schema t + update /*+ no_parallel */ ut_suite_cache_schema t set t.parse_time = a_parse_time where object_owner = l_object_owner; if sql%rowcount = 0 then - insert into ut_suite_cache_schema + insert /*+ no_parallel */ into ut_suite_cache_schema (object_owner, parse_time) values (l_object_owner, a_parse_time); end if; - update ut_suite_cache_package t + update /*+ no_parallel */ ut_suite_cache_package t set t.parse_time = a_parse_time where t.object_owner = l_object_owner and t.object_name = l_object_name; if sql%rowcount = 0 then - insert into ut_suite_cache_package + insert /*+ no_parallel */ into ut_suite_cache_package (object_owner, object_name, parse_time) values (l_object_owner, l_object_name, a_parse_time ); end if; @@ -321,7 +321,7 @@ create or replace package body ut_suite_cache_manager is where t.object_owner = l_object_owner and t.object_name = l_object_name; - insert into ut_suite_cache t + insert /*+ no_parallel */ into ut_suite_cache t ( id, self_type, path, object_owner, object_name, name, line_no, parse_time, description, @@ -336,7 +336,7 @@ create or replace package body ut_suite_cache_manager is select treat(value(x) as ut_suite) i from table(a_suite_items) x where x.self_type in( 'UT_SUITE', 'UT_SUITE_CONTEXT' ) ) - select ut_suite_cache_seq.nextval, s.i.self_type as self_type, s.i.path as path, + select /*+ no_parallel */ ut_suite_cache_seq.nextval, s.i.self_type as self_type, s.i.path as path, upper(s.i.object_owner) as object_owner, upper(s.i.object_name) as object_name, upper(s.i.name) as name, s.i.line_no as line_no, s.i.parse_time as parse_time, s.i.description as description, s.i.rollback_type as rollback_type, s.i.disabled_flag as disabled_flag, s.i.warnings as warnings, @@ -347,7 +347,7 @@ create or replace package body ut_suite_cache_manager is null item from suites s; - insert into ut_suite_cache t + insert /*+ no_parallel */ into ut_suite_cache t ( id, self_type, path, object_owner, object_name, name, line_no, parse_time, description, @@ -362,7 +362,7 @@ create or replace package body ut_suite_cache_manager is select treat(value(x) as ut_test) t from table ( a_suite_items ) x where x.self_type in ( 'UT_TEST' ) ) - select ut_suite_cache_seq.nextval, s.t.self_type as self_type, s.t.path as path, + select /*+ no_parallel */ ut_suite_cache_seq.nextval, s.t.self_type as self_type, s.t.path as path, upper(s.t.object_owner) as object_owner, upper(s.t.object_name) as object_name, upper(s.t.name) as name, s.t.line_no as line_no, s.t.parse_time as parse_time, s.t.description as description, s.t.rollback_type as rollback_type, s.t.disabled_flag as disabled_flag, s.t.warnings as warnings, @@ -385,13 +385,13 @@ create or replace package body ut_suite_cache_manager is l_objects := get_missing_cache_objects(a_schema_name); if l_objects is not empty then - delete from ut_suite_cache i + delete /*+ no_parallel */ from ut_suite_cache i where i.object_owner = a_schema_name - and i.object_name in ( select column_value from table (l_objects) ); + and i.object_name in ( select /*+ no_parallel */ column_value from table (l_objects) ); - delete from ut_suite_cache_package i + delete /*+ no_parallel */ from ut_suite_cache_package i where i.object_owner = a_schema_name - and i.object_name in ( select column_value from table (l_objects) ); + and i.object_name in ( select /*+ no_parallel */ column_value from table (l_objects) ); end if; commit; @@ -405,7 +405,7 @@ create or replace package body ut_suite_cache_manager is l_results ut_suite_items_info; begin l_cache_rows := get_cached_suite_rows( a_object_owner => a_object_owner, a_object_name =>a_object_name ); - select ut_suite_item_info( + select /*+ no_parallel */ ut_suite_item_info( c.object_owner, c.object_name, c.name, c.description, c.self_type, c.line_no, c.path, c.disabled_flag, c.tags @@ -421,7 +421,7 @@ create or replace package body ut_suite_cache_manager is ) return ut_object_names is l_results ut_object_names; begin - select ut_object_name( c.object_owner, c.object_name ) + select /*+ no_parallel */ ut_object_name( c.object_owner, c.object_name ) bulk collect into l_results from ut_suite_cache_package c join table ( a_schema_names ) s @@ -437,7 +437,7 @@ create or replace package body ut_suite_cache_manager is l_count integer; begin if a_procedure_name is not null then - select count( 1 ) into l_count from dual + select /*+ no_parallel */ count( 1 ) into l_count from dual where exists( select 1 from ut_suite_cache c @@ -446,7 +446,7 @@ create or replace package body ut_suite_cache_manager is and c.name = a_procedure_name ); elsif a_package_name is not null then - select count( 1 ) into l_count from dual + select /*+ no_parallel */ count( 1 ) into l_count from dual where exists( select 1 from ut_suite_cache c @@ -454,7 +454,7 @@ create or replace package body ut_suite_cache_manager is and c.object_name = a_package_name ); else - select count( 1 ) into l_count from dual + select /*+ no_parallel */ count( 1 ) into l_count from dual where exists( select 1 from ut_suite_cache c diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 603e713ec..60c33f21f 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -353,10 +353,10 @@ create or replace package body ut_suite_manager is ); if a_skip_all_objects then open l_result for - select c.* from table(l_unfiltered_rows) c; + select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c; else open l_result for - select c.* from table(l_unfiltered_rows) c + select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c where exists ( select 1 from all_objects a @@ -596,12 +596,12 @@ create or replace package body ut_suite_manager is l_all_suite_info := ut_suite_cache_manager.get_cached_suite_info( l_owner_name, l_package_name ); if can_skip_all_objects_scan( l_owner_name ) then open l_result for - select value(c) + select /*+ no_parallel */ value(c) from table(l_all_suite_info) c order by c.object_owner, c.object_name, c.item_line_no; else open l_result for - select value(c) + select /*+ no_parallel */ value(c) from table(l_all_suite_info) c where exists ( select 1 @@ -631,7 +631,7 @@ create or replace package body ut_suite_manager is refresh_cache(l_owner_name); l_item_exists := ut_suite_cache_manager.suite_item_exists( l_owner_name, l_package_name, l_procedure_name ); if not can_skip_all_objects_scan( l_owner_name ) and l_package_name is not null then - select count(1) + select /*+ no_parallel */ count(1) into l_count from dual c where exists diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 69e6c4725..fa7d229aa 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -350,7 +350,7 @@ create or replace package body ut_utils is function get_utplsql_objects_list return ut_object_names is l_result ut_object_names; begin - select distinct ut_object_name(sys_context('userenv','current_user'), o.object_name) + select /*+ no_parallel */ distinct ut_object_name(sys_context('userenv','current_user'), o.object_name) bulk collect into l_result from user_objects o where o.object_name = 'UT' or object_name like 'UT\_%' escape '\' @@ -532,8 +532,8 @@ create or replace package body ut_utils is procedure flush_lines(a_lines ut_varchar2_rows, a_offset integer) is begin if a_lines is not empty then - insert into ut_dbms_output_cache (seq_no,text) - select rownum+a_offset, column_value + insert /*+ no_parallel */ into ut_dbms_output_cache (seq_no,text) + select /*+ no_parallel */ rownum+a_offset, column_value from table(a_lines); end if; end; @@ -558,7 +558,7 @@ create or replace package body ut_utils is c_lines_limit constant integer := 10000; pragma autonomous_transaction; begin - open l_lines_data for select text from ut_dbms_output_cache order by seq_no; + open l_lines_data for select /*+ no_parallel */ text from ut_dbms_output_cache order by seq_no; loop fetch l_lines_data bulk collect into l_lines limit c_lines_limit; for i in 1 .. l_lines.count loop @@ -646,10 +646,10 @@ create or replace package body ut_utils is function xmlgen_escaped_string(a_string in varchar2) return varchar2 is l_result varchar2(4000) := a_string; - l_sql varchar2(32767) := q'!select q'[!'||a_string||q'!]' as "!'||a_string||'" from dual'; + l_sql varchar2(32767) := q'!select /*+ no_parallel */ q'[!'||a_string||q'!]' as "!'||a_string||'" from dual'; begin if a_string is not null then - select extract(dbms_xmlgen.getxmltype(l_sql),'/*/*/*').getRootElement() + select /*+ no_parallel */ extract(dbms_xmlgen.getxmltype(l_sql),'/*/*/*').getRootElement() into l_result from dual; end if; @@ -753,7 +753,7 @@ create or replace package body ut_utils is l_for_reporters := ut_reporters_info(ut_reporter_info('UT_REPORTER_BASE','N','N','N')); end if; - select /*+ cardinality(f 10) */ + select /*+ no_parallel cardinality(f 10) */ ut_reporter_info( object_name => t.type_name, is_output_reporter => @@ -801,7 +801,7 @@ create or replace package body ut_utils is function build_valid_xml_name(a_preprocessed_name varchar2) return varchar2 is l_post_processed varchar2(4000); begin - for i in (select regexp_substr( a_preprocessed_name ,'(.{1})', 1, level, null, 1 ) AS string_char,level level_no + for i in (select /*+ no_parallel */ regexp_substr( a_preprocessed_name ,'(.{1})', 1, level, null, 1 ) AS string_char,level level_no from dual connect by level <= regexp_count(a_preprocessed_name, '(.{1})')) loop if i.level_no = 1 and regexp_like(i.string_char,gc_invalid_first_xml_char) then diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 69ba90811..657c02ce3 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -61,7 +61,7 @@ create or replace package body ut_compound_data_helper is where x.data_id = :act_guid ) ucd ) - select + select /*+ no_parallel */ a."UT3$_Item#Data" as act_item_data, a."UT3$_Data#Id" act_data_id, e."UT3$_Item#Data" as exp_item_data, @@ -103,7 +103,7 @@ create or replace package body ut_compound_data_helper is full outer join actual_cols a on e.exp_column_name = a.act_column_name ) - select case + select /*+ no_parallel */ case when exp_col_pos is null and act_col_pos is not null then '+' when exp_col_pos is not null and act_col_pos is null then '-' when exp_col_type_compare != act_col_type_compare then 't' @@ -486,7 +486,7 @@ create or replace package body ut_compound_data_helper is ) unpivot ( data_item for diff_type in (exp_item as 'Expected:', act_item as 'Actual:') ) ) - select rn, diff_type, diffed_row, pk_value + select /*+ no_parallel */ rn, diff_type, diffed_row, pk_value from ( select rn, diff_type, diffed_row, pk_value, case when diff_type = 'Actual:' then 1 else 2 end rnk, @@ -564,7 +564,7 @@ create or replace package body ut_compound_data_helper is procedure insert_diffs_result(a_diff_tab t_diff_tab, a_diff_id raw) is begin forall idx in 1..a_diff_tab.count save exceptions - insert into ut_compound_data_diff_tmp + insert /*+ no_parallel */ into ut_compound_data_diff_tmp ( diff_id, act_item_data, act_data_id, exp_item_data, exp_data_id, item_no, duplicate_no ) values (a_diff_id, @@ -639,13 +639,13 @@ create or replace package body ut_compound_data_helper is procedure save_cursor_data_for_diff(a_data_id raw, a_set_id integer, a_xml xmltype) is begin - insert into ut_compound_data_tmp (data_id, item_no, item_data) values (a_data_id, a_set_id, a_xml); + insert /*+ no_parallel */ into ut_compound_data_tmp (data_id, item_no, item_data) values (a_data_id, a_set_id, a_xml); end; function get_row_data_as_xml(a_data_id raw, a_max_rows integer) return ut_utils.t_clob_tab is l_results ut_utils.t_clob_tab; begin - select xmlserialize( content ucd.item_data no indent) + select /*+ no_parallel */ xmlserialize( content ucd.item_data no indent) bulk collect into l_results from ut_compound_data_tmp tmp ,xmltable ( '/ROWSET' passing tmp.item_data @@ -720,7 +720,7 @@ create or replace package body ut_compound_data_helper is or (a.json_type != e.json_type) or (decode(a.element_value,e.element_value,1,0) = 0) ) - select difference_type, + select /*+ no_parallel */ difference_type, act_element_name, act_element_value, act_json_type, act_access_path, act_parent_path, exp_element_name, exp_element_value, exp_json_type, exp_access_path, exp_parent_path bulk collect into l_result_diff @@ -742,7 +742,7 @@ create or replace package body ut_compound_data_helper is l_diffs tt_json_diff_tab := compare_json_data(a_act_json_data,a_exp_json_data); begin forall i in 1..l_diffs.count - insert into ut_json_data_diff_tmp ( + insert /*+ no_parallel */ into ut_json_data_diff_tmp ( diff_id, difference_type, act_element_name, act_element_value, act_json_type, act_access_path, act_parent_path, exp_element_name, exp_element_value, exp_json_type, exp_access_path, exp_parent_path @@ -759,7 +759,7 @@ create or replace package body ut_compound_data_helper is function get_json_diffs_type(a_diff_id raw) return tt_json_diff_type_tab is l_diffs_summary tt_json_diff_type_tab := tt_json_diff_type_tab(); begin - select d.difference_type,count(1) + select /*+ no_parallel */ d.difference_type,count(1) bulk collect into l_diffs_summary from ut_json_data_diff_tmp d where diff_id = a_diff_id @@ -771,7 +771,7 @@ create or replace package body ut_compound_data_helper is function get_json_diffs_tmp(a_diff_id raw) return tt_json_diff_tab is l_diffs tt_json_diff_tab; begin - select difference_type, + select /*+ no_parallel */ difference_type, act_element_name, act_element_value, act_json_type, act_access_path, act_parent_path, exp_element_name, exp_element_value, exp_json_type, exp_access_path, exp_parent_path bulk collect into l_diffs diff --git a/source/expectations/data_values/ut_cursor_details.tpb b/source/expectations/data_values/ut_cursor_details.tpb index 20313ed96..adc705f65 100644 --- a/source/expectations/data_values/ut_cursor_details.tpb +++ b/source/expectations/data_values/ut_cursor_details.tpb @@ -3,7 +3,7 @@ create or replace type body ut_cursor_details as member function equals( a_other ut_cursor_details, a_match_options ut_matcher_options ) return boolean is l_diffs integer; begin - select count(1) into l_diffs + select /*+ no_parallel */ count(1) into l_diffs from table(self.cursor_columns_info) a full outer join table(a_other.cursor_columns_info) e on decode(a.parent_name,e.parent_name,1,0)= 1 @@ -139,7 +139,7 @@ create or replace type body ut_cursor_details as member function contains_collection return boolean is l_collection_elements number; begin - select count(1) into l_collection_elements + select /*+ no_parallel */ count(1) into l_collection_elements from table(cursor_columns_info) c where c.is_collection = 1 and rownum = 1; return l_collection_elements > 0; @@ -149,7 +149,7 @@ create or replace type body ut_cursor_details as l_result ut_varchar2_list; begin --regexp_replace(c.access_path,'^\/?([^\/]+\/){1}') - select fl.column_value + select /*+ no_parallel */ fl.column_value bulk collect into l_result from table(a_expected_columns) fl where not exists ( @@ -179,7 +179,7 @@ create or replace type body ut_cursor_details as select regexp_replace( column_value, c_xpath_extract_reg, '\5' ) col_names from table(a_match_options.exclude.items) ) - select value(x) + select /*+ no_parallel */ value(x) bulk collect into l_result.cursor_columns_info from table(self.cursor_columns_info) x where exists( @@ -192,7 +192,7 @@ create or replace type body ut_cursor_details as select regexp_replace( column_value, c_xpath_extract_reg, '\5' ) col_names from table(a_match_options.exclude.items) ) - select value(x) + select /*+ no_parallel */ value(x) bulk collect into l_result.cursor_columns_info from table(self.cursor_columns_info) x where not exists( @@ -202,7 +202,7 @@ create or replace type body ut_cursor_details as --Rewrite column order after columns been excluded for i in ( - select parent_name, access_path, display_path, has_nested_col, + select /*+ no_parallel */ parent_name, access_path, display_path, has_nested_col, transformed_name, hierarchy_level, rownum as new_position, xml_valid_name, column_name, column_type, column_type_name, column_schema, @@ -224,7 +224,7 @@ create or replace type body ut_cursor_details as member function get_xml_children(a_parent_name varchar2 := null) return xmltype is l_result xmltype; begin - select xmlagg(xmlelement(evalname t.column_name,t.column_type_name)) + select /*+ no_parallel */ xmlagg(xmlelement(evalname t.column_name,t.column_type_name)) into l_result from table(self.cursor_columns_info) t where (a_parent_name is null and parent_name is null and hierarchy_level = 1 and column_name is not null) @@ -236,7 +236,7 @@ create or replace type body ut_cursor_details as l_root varchar2(250); begin if self.cursor_columns_info.count > 0 then - select x.access_path into l_root from table(self.cursor_columns_info) x + select /*+ no_parallel */ x.access_path into l_root from table(self.cursor_columns_info) x where x.hierarchy_level = 1; else l_root := null; diff --git a/source/expectations/data_values/ut_data_value_anydata.tpb b/source/expectations/data_values/ut_data_value_anydata.tpb index a81b0f5c7..bb52159e0 100644 --- a/source/expectations/data_values/ut_data_value_anydata.tpb +++ b/source/expectations/data_values/ut_data_value_anydata.tpb @@ -48,11 +48,11 @@ create or replace type body ut_data_value_anydata as begin l_status := l_value.get'||self.compound_type||'(l_data); '|| case when self.compound_type = 'collection' then - q'[ open :l_tmp_refcursor for select value(x) as "]'|| + q'[ open :l_tmp_refcursor for select /*+ no_parallel */ value(x) as "]'|| ut_metadata.get_object_name(ut_metadata.get_collection_element(a_data_value))|| q'[" from table(l_data) x;]' else - q'[ open :l_tmp_refcursor for select l_data as "]'||ut_metadata.get_object_name(self.data_type)|| + q'[ open :l_tmp_refcursor for select /*+ no_parallel */ l_data as "]'||ut_metadata.get_object_name(self.data_type)|| q'[" from dual;]' end || 'end;'; diff --git a/source/expectations/data_values/ut_data_value_refcursor.tpb b/source/expectations/data_values/ut_data_value_refcursor.tpb index 801b35802..da5c1a381 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tpb +++ b/source/expectations/data_values/ut_data_value_refcursor.tpb @@ -178,7 +178,7 @@ create or replace type body ut_data_value_refcursor as l_missing_cols(l_missing_cols.last) := coalesce(a_column_diffs(i).expected_name, a_column_diffs(i).actual_name); end if; end loop; - select value(i) bulk collect into l_result + select /*+ no_parallel */ value(i) bulk collect into l_result from table(a_cursor_details) i where i.access_path not in ( select c.column_value diff --git a/source/reporters/ut_debug_reporter.tpb b/source/reporters/ut_debug_reporter.tpb index 365f77755..5f457bb79 100644 --- a/source/reporters/ut_debug_reporter.tpb +++ b/source/reporters/ut_debug_reporter.tpb @@ -71,7 +71,7 @@ create or replace type body ut_debug_reporter is member function event_item_to_clob(a_event_item ut_event_item) return clob is l_clob clob; begin - select xmlserialize( content deletexml(xmltype(a_event_item),'/*/ITEMS|/*/ALL_EXPECTATIONS|/*/FAILED_EXPECTATIONS') as clob indent size = 2 ) into l_clob from dual; + select /*+ no_parallel */ xmlserialize( content deletexml(xmltype(a_event_item),'/*/ITEMS|/*/ALL_EXPECTATIONS|/*/FAILED_EXPECTATIONS') as clob indent size = 2 ) into l_clob from dual; return l_clob; end; From c930ba6885d74d73890876ab478b55041a40f5cf Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 7 Nov 2021 21:10:05 +0000 Subject: [PATCH 146/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 46014790f..58e628fdf 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 6514efb62..6f1301ebc 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index b2bdb573c..32f61f685 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 7a951b76d..a7f46d889 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 65934b0e8..11cef2063 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7b9cfa641..2d368ece8 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 6eb8b1b6c..bbcadda92 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index ded4b085c..20be24aab 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index f514b031c..a154c1063 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a063f45d2..6f62e6621 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 670ce1741..9805c8882 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 86ec6a4c7..8de75e8b9 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 8b99a5e0f..7123d71e7 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index ebc5b12b9..043589462 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 70e0952b3..3ba0f209a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 63a9e0de4..2d3e786a0 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 5a62efd2b..dfb729941 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 69e6c4725..bdc46c952 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3495-develop + * secion v3.1.11.3502-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 3f5631aab..6e4faea13 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3495-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3502-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 45d1d5b9b32fc1a94d2c525e807c7d863c61732f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 9 Nov 2021 00:03:38 +0200 Subject: [PATCH 147/887] Improved build speed by ~1.5 minute Added bind mount to DB docker at runtime to enable faster execution of scripts Removed need for sqlcl locally in build Added download of ojdbc and orai18n directly without click-through Cleanup of build scripts to make them more TRAVIS-agnostic --- .travis.yml | 40 +++++++++---- .travis/coveralls_uploader.js | 2 +- .travis/install.sh | 5 +- .travis/install_sqlcl.sh | 20 ------- .travis/install_utplsql_release.sh | 4 +- .travis/push_docs_to_github_io.sh | 10 ++-- .travis/push_release_version.sh | 4 +- .travis/run_examples.sh | 4 +- .travis/run_sonar_scanner.sh | 16 ++--- .travis/start_db.sh | 5 +- .travis/validate_report_files.sh | 4 +- development/template.env.sh | 3 +- test/install_tests.sh | 6 +- .../reporters/test_documentation_reporter.pkb | 60 ++++++++++++++++++- 14 files changed, 118 insertions(+), 65 deletions(-) delete mode 100755 .travis/install_sqlcl.sh diff --git a/.travis.yml b/.travis.yml index 7d04693e0..d51089389 100644 --- a/.travis.yml +++ b/.travis.yml @@ -25,6 +25,15 @@ env: - UT3_TESTER_HELPER=UT3_TESTER_HELPER - UT3_TESTER_HELPER_PASSWORD=ut3 - UT3_TABLESPACE=users + - BUILD_DIR=${TRAVIS_BUILD_DIR} + - JOB_ID=${TRAVIS_JOB_ID} + - JOB_NUMBER=${TRAVIS_JOB_NUMBER} + - PULL_REQUEST_NAME=${TRAVIS_PULL_REQUEST} + - PULL_REQUEST_BRANCH=${TRAVIS_PULL_REQUEST_BRANCH} + - TAG_NAME=${TRAVIS_TAG} + - REPO_SLUG=${TRAVIS_REPO_SLUG} + - PR_SLUG=${TRAVIS_PULL_REQUEST_SLUG} + - BRANCH_NAME=${TRAVIS_BRANCH} # Environment for building a release - CURRENT_BRANCH=${TRAVIS_BRANCH} - UTPLSQL_REPO="utPLSQL/utPLSQL" @@ -35,11 +44,13 @@ env: - UTPLSQL_BUILD_USER_NAME="Travis CI" - CACHE_DIR=$HOME/.cache # Database Env - - SQLCLI="$HOME/sqlcl/bin/sql" - - OJDBC_HOME="$HOME/sqlcl/lib" + - SQLCLI="${BUILD_DIR}/sqlcl/bin/sql" + - OJDBC_HOME="${BUILD_DIR}/ojdbc" - ORACLE_PWD="oracle" - UT3_DOCKER_REPO="utplsqlv3/oracledb" - DOCKHER_HUB_REPO="${DOCKER_BASE_TAG:-$UT3_DOCKER_REPO}" + - DOCKER_VOLUME="/home/oracle/host" + - DOCKER_ENV="-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" #utPLSQL released version directory - UTPLSQL_DIR="utPLSQL_latest_release" - SELFTESTING_BRANCH=${TRAVIS_BRANCH} @@ -47,13 +58,13 @@ env: # Maven - MAVEN_HOME=/usr/local/maven - MAVEN_CFG=$HOME/.m2 - matrix: - - ORACLE_VERSION="${DOCKER_TAG_11G:-11g-r2-xe}" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_OPTIONS='--shm-size=1g' + jobs: + - ORACLE_VERSION="${DOCKER_TAG_11G:-11g-r2-xe}" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_VOLUME="/mnt/host" DOCKER_OPTIONS='--shm-size=1g' - ORACLE_VERSION="${DOCKER_TAG_12C:-12c-r1-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - ORACLE_VERSION="${DOCKER_TAG_12C2:-12c-r2-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - ORACLE_VERSION="${DOCKER_TAG_18:-18c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - ORACLE_VERSION="${DOCKER_TAG_19:-19c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="${DOCKER_TAG_21XE:-21c-xe-full}" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' + - ORACLE_VERSION="${DOCKER_TAG_21XE:-21c-xe-full}" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' cache: pip: true @@ -73,24 +84,29 @@ before_install: #Allow for sonar to blame issues - git fetch --unshallow # download latest utPLSQL release - #- curl -LOk $(curl --silent https://api.github.com/repos/utPLSQL/utPLSQL/releases/latest | awk '/browser_download_url/ { print $2 }' | grep ".zip" | sed 's/"//g') - git clone --depth=1 --branch=${SELFTESTING_BRANCH:-main} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR # download latest utPLSQL-cli release - curl -Lk -o utPLSQL-cli.zip https://github.com/utPLSQL/utPLSQL-cli/releases/download/v${UTPLSQL_CLI_VERSION}/utPLSQL-cli.zip install: - #- unzip utPLSQL.zip - unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli - - bash .travis/install_sqlcl.sh +# - curl -Lk -o sqlcl-latest.zip https://download.oracle.com/otn_software/java/sqldeveloper/sqlcl-latest.zip +# - unzip -q sqlcl-latest.zip -d $HOME + - mkdir -p ${OJDBC_HOME} #get JDBC driver and orai18n + - curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar https://download.oracle.com/otn-pub/otn_software/jdbc/213/ojdbc8.jar + - curl -Lk -o ${OJDBC_HOME}/orai18n.jar https://download.oracle.com/otn-pub/otn_software/jdbc/213/orai18n.jar + # Chmod is needed to allow for write access within from docker container volume + - chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} - if [[ ! $TRAVIS_TAG ]]; then bash .travis/start_db.sh; fi + - if [[ ! $TRAVIS_TAG ]]; then docker exec ${ORACLE_VERSION} ${DOCKER_VOLUME}/.travis/install.sh; fi + - if [[ ! $TRAVIS_TAG ]]; then docker exec ${ORACLE_VERSION} ${DOCKER_VOLUME}/.travis/install_utplsql_release.sh; fi before_script: - - if [[ ! $TRAVIS_TAG ]]; then bash .travis/install.sh; fi - - if [[ ! $TRAVIS_TAG ]]; then bash .travis/install_utplsql_release.sh; fi - - if [[ ! $TRAVIS_TAG ]]; then bash .travis/run_examples.sh; fi + - if [[ ! $TRAVIS_TAG ]]; then docker exec ${ORACLE_VERSION} ${DOCKER_VOLUME}/.travis/run_examples.sh; fi + - if [[ ! $TRAVIS_TAG ]]; then docker exec ${ORACLE_VERSION} ${DOCKER_VOLUME}/test/install_tests.sh; fi script: - - if [[ ! $TRAVIS_TAG ]]; then bash test/install_and_run_tests.sh; fi + - if [[ ! $TRAVIS_TAG ]]; then bash test/run_tests.sh; fi - if [[ ! $TRAVIS_TAG ]]; then bash .travis/validate_report_files.sh; fi - if [[ ! $TRAVIS_TAG ]] && [[ ("${TRAVIS_REPO_SLUG}" = "${UTPLSQL_REPO}" && "${TRAVIS_PULL_REQUEST}" == false) || ("${TRAVIS_PULL_REQUEST_SLUG}" = "${UTPLSQL_REPO}") ]]; then bash .travis/run_sonar_scanner.sh; fi - if [[ ! $TRAVIS_TAG ]]; then bash .travis/coveralls_uploader.sh; fi diff --git a/.travis/coveralls_uploader.js b/.travis/coveralls_uploader.js index ad6eeee74..182f84066 100644 --- a/.travis/coveralls_uploader.js +++ b/.travis/coveralls_uploader.js @@ -14,7 +14,7 @@ fs.readFile('../coverage.json',function (err,data) { return console.log(err); } req = JSON.parse(data); - req.service_job_id = process.env.TRAVIS_JOB_ID; + req.service_job_id = process.env.JOB_ID; req.service_name = 'travis-ci'; if (process.env.COVERALLS_REPO_TOKEN) { req.repo_token = process.env.COVERALLS_REPO_TOKEN; diff --git a/.travis/install.sh b/.travis/install.sh index 537fddb66..603cb7d1e 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -1,7 +1,8 @@ #!/bin/bash -cd source set -ev +SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" +cd ${SCRIPT_DIR}/../source INSTALL_FILE="install_headless_with_trigger.sql" if [[ ! -f "${INSTALL_FILE}" ]]; then @@ -20,7 +21,7 @@ alter session set plsql_optimize_level=0; SQL #Run this step only on second child job (12.1 - at it's fastest) -if [[ "${TRAVIS_JOB_NUMBER}" =~ \.2$ ]]; then +if [[ "${JOB_NUMBER}" =~ \.2$ ]]; then #check code-style for errors time "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @../development/utplsql_style_check.sql diff --git a/.travis/install_sqlcl.sh b/.travis/install_sqlcl.sh deleted file mode 100755 index 9743ddac2..000000000 --- a/.travis/install_sqlcl.sh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/bash -set -e - -SQLCL_FILE=sqlcl-18.3.0.259.2029.zip -cd .travis - -# Download if not present on cache dir. -if [ ! -f $CACHE_DIR/$SQLCL_FILE ]; then - npm install -g phantomjs-prebuilt casperjs - bash download.sh -p sqlcl - mv $SQLCL_FILE $CACHE_DIR -else - echo "Installing sqlcl from cache..." -fi; - -# Install sqlcl. -unzip -q $CACHE_DIR/$SQLCL_FILE -d $HOME - -# Check if it is installed correctly. -$SQLCLI -v diff --git a/.travis/install_utplsql_release.sh b/.travis/install_utplsql_release.sh index 12ec50118..fea162f8f 100755 --- a/.travis/install_utplsql_release.sh +++ b/.travis/install_utplsql_release.sh @@ -1,8 +1,8 @@ #!/bin/bash set -ev - -cd $UTPLSQL_DIR/source +SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" +cd ${SCRIPT_DIR}/../${UTPLSQL_DIR}/source "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <>index.md fi #If build running on a TAG - it's a new release - need to add it to documentation - if [ -n "${TRAVIS_TAG}" ]; then - sed -i '7s@.*@'" - [Latest ${TRAVIS_TAG} documentation](latest/) - Created $now"'@' index.md + if [ -n "${TAG_NAME}" ]; then + sed -i '7s@.*@'" - [Latest ${TAG_NAME} documentation](latest/) - Created $now"'@' index.md #add entry to the top of version history (line end of file - ## Released Version Doc History - sed -i '12i'" - [${TRAVIS_TAG} documentation](${UTPLSQL_VERSION}/) - Created $now" index.md + sed -i '12i'" - [${TAG_NAME} documentation](${UTPLSQL_VERSION}/) - Created $now" index.md fi #replace 4th line in log sed -i '8s@.*@'" - [Latest development version](develop/) - Created $now"'@' index.md diff --git a/.travis/push_release_version.sh b/.travis/push_release_version.sh index 082359af4..f4ca8f819 100755 --- a/.travis/push_release_version.sh +++ b/.travis/push_release_version.sh @@ -3,7 +3,7 @@ # We are updating version number only when: # - not a pull request # - branch name is = develop or branch name is like release/vX.X.X... -if [ "${TRAVIS_REPO_SLUG}" = "${UTPLSQL_REPO}" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && [[ "${CURRENT_BRANCH}" =~ ^(release/v[0-9]+\.[0-9]+\.[0-9]+.*|develop)$ ]]; then +if [ "${REPO_SLUG}" = "${UTPLSQL_REPO}" ] && [ "${PULL_REQUEST_NAME}" == "false" ] && [[ "${CURRENT_BRANCH}" =~ ^(release/v[0-9]+\.[0-9]+\.[0-9]+.*|develop)$ ]]; then echo Current branch is "${CURRENT_BRANCH}" echo "Committing version & buildNo into branch (${CURRENT_BRANCH})" git add sonar-project.properties @@ -14,5 +14,5 @@ if [ "${TRAVIS_REPO_SLUG}" = "${UTPLSQL_REPO}" ] && [ "$TRAVIS_PULL_REQUEST" == echo "Pushing to origin" git push --quiet origin HEAD:${CURRENT_BRANCH} else - echo "Publishing of version skipped for branch ${CURRENT_BRANCH}, pull request ${TRAVIS_PULL_REQUEST}" + echo "Publishing of version skipped for branch ${CURRENT_BRANCH}, pull request ${PULL_REQUEST_NAME}" fi diff --git a/.travis/run_examples.sh b/.travis/run_examples.sh index 935037245..8eb3d097f 100755 --- a/.travis/run_examples.sh +++ b/.travis/run_examples.sh @@ -1,8 +1,8 @@ #!/bin/bash -cd "$(dirname "$(readlink -f "$0")")"/../examples - set -ev +SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" +cd ${SCRIPT_DIR}/../examples "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR <> sonar-project.properties - if [ "$TRAVIS_PULL_REQUEST" == "false" ]; then + if [ "${PULL_REQUEST_NAME}" == "false" ]; then echo "Updating sonar properties to include branch ${BRANCH}" add_sonar_property "${BRANCH_SONAR_PROPERTY}" "${BRANCH}" add_sonar_property "${BRANCH_SONAR_TARGET_PROPERTY}" "${MAIN_DEV_BRANCH}" - elif [ "${TRAVIS_PULL_REQUEST_SLUG}" = "${TRAVIS_REPO_SLUG}" ]; then + elif [ "${PR_SLUG}" = "${REPO_SLUG}" ]; then echo "Updating sonar properties to include pull request ${BRANCH}" add_sonar_property "${PR_SONAR_TOKEN_PROPERTY}" "${GITHUB_TRAVISCI_TOKEN}" add_sonar_property "${PR_SONAR_BRANCH_PROPERTY}" "${BRANCH}" diff --git a/.travis/start_db.sh b/.travis/start_db.sh index e42656987..285f8172f 100755 --- a/.travis/start_db.sh +++ b/.travis/start_db.sh @@ -10,9 +10,6 @@ else mkdir -p $HOME/.docker && cp $CACHE_DIR/.docker/config.json $HOME/.docker/ fi -df -h time docker pull $DOCKHER_HUB_REPO:$ORACLE_VERSION -df -h -docker run -d --name $ORACLE_VERSION $DOCKER_OPTIONS -p 1521:1521 $DOCKHER_HUB_REPO:$ORACLE_VERSION +docker run -d --name $ORACLE_VERSION --mount type=bind,source=${BUILD_DIR},target=${DOCKER_VOLUME} $DOCKER_OPTIONS $DOCKER_ENV -p 1521:1521 $DOCKHER_HUB_REPO:$ORACLE_VERSION time docker logs -f $ORACLE_VERSION | grep -m 1 "DATABASE IS READY TO USE!" --line-buffered -df -h diff --git a/.travis/validate_report_files.sh b/.travis/validate_report_files.sh index 621297a0b..7c7d1354d 100755 --- a/.travis/validate_report_files.sh +++ b/.travis/validate_report_files.sh @@ -1,8 +1,8 @@ #!/usr/bin/env bash GL_VALID=1 -XSD_DIR="$TRAVIS_BUILD_DIR/.travis/xsd" -XML_JAR_DIR="$TRAVIS_BUILD_DIR/.travis/lib" +XSD_DIR="$BUILD_DIR/.travis/xsd" +XML_JAR_DIR="$BUILD_DIR/.travis/lib" #XML Validator XML_VALIDATOR="$XML_JAR_DIR/xml_validator.jar" HTML_VALIDATOR_URL="https://validator.w3.org/nu/" diff --git a/development/template.env.sh b/development/template.env.sh index 5e1aaad1a..521d9343d 100755 --- a/development/template.env.sh +++ b/development/template.env.sh @@ -2,7 +2,7 @@ export SQLCLI=sql # For sqlcl client #export SQLCLI=sqlplus # For sqlplus client -export CONNECTION_STR=127.0.0.1:1521/xe # Adjust the connect string +export CONNECTION_STR=127.0.0.1:1521/xe ORACLE_VERSION=11g-r2-xe# Adjust the connect string export ORACLE_PWD=oracle # Adjust your local SYS password export UTPLSQL_CLI_VERSION="3.1.6" export SELFTESTING_BRANCH=develop @@ -19,3 +19,4 @@ export UT3_TESTER_HELPER_PASSWORD=ut3 export UT3_TABLESPACE=users export UT3_USER="UT3\$USER#" export UT3_USER_PASSWORD=ut3 +export DOCKER_ENV="-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" diff --git a/test/install_tests.sh b/test/install_tests.sh index e07b4d2b3..4ccc312e8 100755 --- a/test/install_tests.sh +++ b/test/install_tests.sh @@ -1,9 +1,9 @@ #!/bin/bash set -ev -#goto git root directory -git rev-parse && cd "$(git rev-parse --show-cdup)" -cd test +SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" +cd ${SCRIPT_DIR} + "$SQLCLI" ${UT3_TESTER_HELPER}/${UT3_TESTER_HELPER_PASSWORD}@//${CONNECTION_STR} @install_ut3_tester_helper.sql diff --git a/test/ut3_user/reporters/test_documentation_reporter.pkb b/test/ut3_user/reporters/test_documentation_reporter.pkb index 456fa86f9..03759fe6a 100644 --- a/test/ut3_user/reporters/test_documentation_reporter.pkb +++ b/test/ut3_user/reporters/test_documentation_reporter.pkb @@ -1 +1,59 @@ -create or replace package body test_documentation_reporter as procedure report_produces_expected_out is l_results ut3_develop.ut_varchar2_list; l_actual clob; l_expected varchar2(32767):=q'[%org utplsql tests helpers A suite for testing different outcomes from reporters A description of some context passing_test [% sec] a test with failing assertion [% sec] (FAILED - 1) a test raising unhandled exception [% sec] (FAILED - 2) a disabled test [0 sec] (DISABLED) % Failures: % 1) failing_test "Fails as values are different" Actual: 'number [1] ' (varchar2) was expected to equal: 'number [2] ' (varchar2)% at "UT3$USER#.TEST_REPORTERS%", line 36 ut3_develop.ut.expect('number [1] ','Fails as values are different').to_equal('number [2] '); % % 2) erroring_test ORA-06502: PL/SQL: numeric or value error: character to number conversion error ORA-06512: at "UT3$USER#.TEST_REPORTERS", line 44% ORA-06512: at line 6 Finished in % seconds 4 tests, 1 failed, 1 errored, 1 disabled, 0 warning(s)%]'; begin select * bulk collect into l_results from table( ut3_develop.ut.run( 'test_reporters', ut3_develop.ut_documentation_reporter() ) ); l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); ut.expect(l_actual).to_be_like(l_expected); end; end; / \ No newline at end of file +create or replace package body test_documentation_reporter as + + procedure report_produces_expected_out is + l_results ut3_develop.ut_varchar2_list; + l_actual clob; + l_expected varchar2(32767):=q'[%org + utplsql + tests + helpers + A suite for testing different outcomes from reporters + + A description of some context + passing_test [% sec] + + + + + + a test with failing assertion [% sec] (FAILED - 1) + + + + a test raising unhandled exception [% sec] (FAILED - 2) + + + + a disabled test [0 sec] (DISABLED) + +% +Failures: +% + 1) failing_test + "Fails as values are different" + Actual: 'number [1] ' (varchar2) was expected to equal: 'number [2] ' (varchar2)% + at "UT3$USER#.TEST_REPORTERS%", line 36 ut3_develop.ut.expect('number [1] ','Fails as values are different').to_equal('number [2] '); +% +% + 2) erroring_test + ORA-06502: PL/SQL: numeric or value error: character to number conversion error + ORA-06512: at "UT3$USER#.TEST_REPORTERS", line 44% + ORA-06512: at line 6 +Finished in % seconds +4 tests, 1 failed, 1 errored, 1 disabled, 0 warning(s)%]'; + + begin + select * + bulk collect into l_results + from table( + ut3_develop.ut.run( + 'test_reporters', + ut3_develop.ut_documentation_reporter() + ) + ); + l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + ut.expect(l_actual).to_be_like(l_expected); + end; + +end; +/ From 8080604df0256ab2202c9f64bb67671d55c63710 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 9 Nov 2021 23:44:54 +0200 Subject: [PATCH 148/887] Testing build on images from Gerald Venzl --- .travis.yml | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/.travis.yml b/.travis.yml index d51089389..b20bee6c2 100644 --- a/.travis.yml +++ b/.travis.yml @@ -47,8 +47,7 @@ env: - SQLCLI="${BUILD_DIR}/sqlcl/bin/sql" - OJDBC_HOME="${BUILD_DIR}/ojdbc" - ORACLE_PWD="oracle" - - UT3_DOCKER_REPO="utplsqlv3/oracledb" - - DOCKHER_HUB_REPO="${DOCKER_BASE_TAG:-$UT3_DOCKER_REPO}" + - DOCKHER_HUB_REPO="utplsqlv3/oracledb" - DOCKER_VOLUME="/home/oracle/host" - DOCKER_ENV="-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" #utPLSQL released version directory @@ -59,12 +58,14 @@ env: - MAVEN_HOME=/usr/local/maven - MAVEN_CFG=$HOME/.m2 jobs: - - ORACLE_VERSION="${DOCKER_TAG_11G:-11g-r2-xe}" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_VOLUME="/mnt/host" DOCKER_OPTIONS='--shm-size=1g' - - ORACLE_VERSION="${DOCKER_TAG_12C:-12c-r1-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="${DOCKER_TAG_12C2:-12c-r2-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="${DOCKER_TAG_18:-18c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="${DOCKER_TAG_19:-19c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="${DOCKER_TAG_21XE:-21c-xe-full}" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' + - ORACLE_VERSION="11g-r2-xe" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_VOLUME="/mnt/host" DOCKER_OPTIONS='--shm-size=1g' + - ORACLE_VERSION="11-slim" CONNECTION_STR='127.0.0.1:1521/XE' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' DOCKER_VOLUME="/mnt/host" + - ORACLE_VERSION="12c-r1-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="12c-r2-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="18-slim" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' + - ORACLE_VERSION="18c-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="19c-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' + - ORACLE_VERSION="21-full" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' cache: pip: true From 23d86513f00c3198e4e206748b936dd18a3a98c2 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 11 Nov 2021 01:37:07 +0200 Subject: [PATCH 149/887] Testing build on images from Gerald Venzl --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index b20bee6c2..e7e168c49 100644 --- a/.travis.yml +++ b/.travis.yml @@ -59,7 +59,7 @@ env: - MAVEN_CFG=$HOME/.m2 jobs: - ORACLE_VERSION="11g-r2-xe" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_VOLUME="/mnt/host" DOCKER_OPTIONS='--shm-size=1g' - - ORACLE_VERSION="11-slim" CONNECTION_STR='127.0.0.1:1521/XE' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' DOCKER_VOLUME="/mnt/host" + - ORACLE_VERSION="11-full" CONNECTION_STR='127.0.0.1:1521/XE' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle --shm-size=1g' DOCKER_VOLUME="/mnt/host" - ORACLE_VERSION="12c-r1-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - ORACLE_VERSION="12c-r2-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - ORACLE_VERSION="18-slim" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' From 2c1624e9725f25ab001ed6ac3bfedba11b3279f2 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 11 Nov 2021 11:26:21 +0200 Subject: [PATCH 150/887] Disabled 11g build from Gerald as utPLSQL fails on that build. --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index e7e168c49..cd1e8efe0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -59,7 +59,7 @@ env: - MAVEN_CFG=$HOME/.m2 jobs: - ORACLE_VERSION="11g-r2-xe" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_VOLUME="/mnt/host" DOCKER_OPTIONS='--shm-size=1g' - - ORACLE_VERSION="11-full" CONNECTION_STR='127.0.0.1:1521/XE' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle --shm-size=1g' DOCKER_VOLUME="/mnt/host" +# - ORACLE_VERSION="11-full" CONNECTION_STR='127.0.0.1:1521/XE' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle --shm-size=1g' DOCKER_VOLUME="/mnt/host" - ORACLE_VERSION="12c-r1-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - ORACLE_VERSION="12c-r2-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - ORACLE_VERSION="18-slim" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' From 78ae58db7e5b3e04be797e85ddec75ef77d4ab23 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 11 Nov 2021 18:37:45 +0200 Subject: [PATCH 151/887] Increasing wait time before proceeding with background job run for tests --- test/ut3_tester_helper/coverage_helper.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 73dec720b..e9385d7d9 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -163,7 +163,7 @@ create or replace package body coverage_helper is begin g_job_no := g_job_no + 1; l_job_name := 'utPLSQL_selftest_job_'||g_job_no; - sleep(0.01); + sleep(0.15); dbms_scheduler.create_job( job_name => l_job_name, job_type => 'PLSQL_BLOCK', From 9388cb36bbbc2fcff67061df80fabfc001517099 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 11 Nov 2021 18:54:10 +0000 Subject: [PATCH 152/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 58e628fdf..0b2b353a8 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 6f1301ebc..e6d021790 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 32f61f685..5001c3498 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index a7f46d889..be257a0e2 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 11cef2063..8126a2a68 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 2d368ece8..6563f0a42 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index bbcadda92..3ccf528dc 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 20be24aab..0d7b1d7f0 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index a154c1063..4482d51d1 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 6f62e6621..7c8d4c397 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 9805c8882..193055557 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8de75e8b9..ec1e69bc0 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 7123d71e7..d7fa81ce9 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 043589462..c82efe503 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3ba0f209a..849fbc4e1 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 2d3e786a0..c956429ec 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index dfb729941..a87e5f132 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3502--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index fd2985f11..dd8120419 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3502-develop + * secion v3.1.11.3548-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6e4faea13..7fb359d0f 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3502-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3548-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 1e1952028617990963d32d195335f057692ecf84 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 11 Nov 2021 23:01:34 +0000 Subject: [PATCH 153/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 0b2b353a8..cd16c82b6 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index e6d021790..7758a2190 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 5001c3498..f0304acf9 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index be257a0e2..ed6c34fe8 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 8126a2a68..57a29707b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 6563f0a42..a5331ff2e 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 3ccf528dc..b760cb1b1 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0d7b1d7f0..bf7189d10 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4482d51d1..814733301 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 7c8d4c397..71113a1d6 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 193055557..3bc60effb 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index ec1e69bc0..8a14cd767 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index d7fa81ce9..144b4a835 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c82efe503..79942bb30 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 849fbc4e1..ebb32163d 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c956429ec..0dee54b06 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index a87e5f132..6f6af8798 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3548--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index dd8120419..4e0bafe7c 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3548-develop + * secion v3.1.11.3549-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 7fb359d0f..35aff2929 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3548-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3549-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 38c53b6cabebe81e4421562654bc9331c5653b47 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 15 Nov 2021 20:38:59 +0200 Subject: [PATCH 154/887] Update copyright dates in license --- source/api/ut.pkb | 2 +- source/api/ut.pks | 2 +- source/api/ut_runner.pkb | 2 +- source/api/ut_runner.pks | 2 +- source/api/ut_suite_item_info.tpb | 2 +- source/api/ut_suite_item_info.tps | 2 +- source/api/ut_suite_items_info.tps | 2 +- source/core/annotations/ut_annotated_object.tps | 2 +- source/core/annotations/ut_annotated_objects.tps | 2 +- source/core/annotations/ut_annotation.tps | 2 +- source/core/annotations/ut_annotation_cache.sql | 2 +- source/core/annotations/ut_annotation_cache_info.sql | 2 +- source/core/annotations/ut_annotation_cache_manager.pkb | 2 +- source/core/annotations/ut_annotation_cache_manager.pks | 2 +- source/core/annotations/ut_annotation_cache_schema.sql | 2 +- source/core/annotations/ut_annotation_cache_seq.sql | 2 +- source/core/annotations/ut_annotation_manager.pkb | 2 +- source/core/annotations/ut_annotation_manager.pks | 2 +- source/core/annotations/ut_annotation_obj_cache_info.tps | 2 +- source/core/annotations/ut_annotation_objs_cache_info.tps | 2 +- source/core/annotations/ut_annotation_parser.pkb | 2 +- source/core/annotations/ut_annotation_parser.pks | 2 +- source/core/annotations/ut_annotations.tps | 2 +- source/core/annotations/ut_trigger_check.pkb | 2 +- source/core/annotations/ut_trigger_check.pks | 2 +- source/core/coverage/ut_coverage.pkb | 2 +- source/core/coverage/ut_coverage.pks | 2 +- source/core/coverage/ut_coverage_block.pkb | 2 +- source/core/coverage/ut_coverage_block.pks | 2 +- source/core/coverage/ut_coverage_helper.pkb | 2 +- source/core/coverage/ut_coverage_helper.pks | 2 +- source/core/coverage/ut_coverage_helper_block.pkb | 2 +- source/core/coverage/ut_coverage_helper_block.pks | 2 +- source/core/coverage/ut_coverage_helper_profiler.pkb | 2 +- source/core/coverage/ut_coverage_helper_profiler.pks | 2 +- source/core/coverage/ut_coverage_profiler.pkb | 2 +- source/core/coverage/ut_coverage_profiler.pks | 2 +- source/core/coverage/ut_coverage_reporter_base.tpb | 2 +- source/core/coverage/ut_coverage_reporter_base.tps | 2 +- source/core/coverage/ut_coverage_sources_tmp.sql | 2 +- source/core/events/ut_event_item.tps | 2 +- source/core/events/ut_event_listener.tps | 2 +- source/core/events/ut_event_manager.pkb | 2 +- source/core/events/ut_event_manager.pks | 2 +- source/core/output_buffers/ut_output_buffer_base.tpb | 2 +- source/core/output_buffers/ut_output_buffer_base.tps | 2 +- source/core/output_buffers/ut_output_buffer_info_tmp.sql | 2 +- source/core/output_buffers/ut_output_buffer_tmp.sql | 2 +- source/core/output_buffers/ut_output_clob_buffer_tmp.sql | 2 +- source/core/output_buffers/ut_output_clob_table_buffer.tpb | 2 +- source/core/output_buffers/ut_output_clob_table_buffer.tps | 2 +- source/core/output_buffers/ut_output_data_row.tps | 2 +- source/core/output_buffers/ut_output_data_rows.tps | 2 +- source/core/output_buffers/ut_output_table_buffer.tpb | 2 +- source/core/output_buffers/ut_output_table_buffer.tps | 2 +- source/core/session_context/ut_session_context.pkb | 2 +- source/core/session_context/ut_session_context.pks | 2 +- source/core/session_context/ut_session_info.tpb | 2 +- source/core/session_context/ut_session_info.tps | 2 +- source/core/types/ut_console_reporter_base.tpb | 2 +- source/core/types/ut_console_reporter_base.tps | 2 +- source/core/types/ut_coverage_options.tpb | 2 +- source/core/types/ut_coverage_options.tps | 2 +- source/core/types/ut_executable.tpb | 2 +- source/core/types/ut_executable.tps | 2 +- source/core/types/ut_executable_test.tpb | 2 +- source/core/types/ut_executable_test.tps | 2 +- source/core/types/ut_executables.tps | 2 +- source/core/types/ut_expectation_result.tpb | 2 +- source/core/types/ut_expectation_result.tps | 2 +- source/core/types/ut_expectation_results.tps | 2 +- source/core/types/ut_file_mapping.tpb | 2 +- source/core/types/ut_file_mapping.tps | 2 +- source/core/types/ut_file_mappings.tps | 2 +- source/core/types/ut_integer_list.tps | 2 +- source/core/types/ut_key_value_pair.tps | 2 +- source/core/types/ut_key_value_pairs.tps | 2 +- source/core/types/ut_logical_suite.tpb | 2 +- source/core/types/ut_logical_suite.tps | 2 +- source/core/types/ut_object_name.tpb | 2 +- source/core/types/ut_object_name.tps | 2 +- source/core/types/ut_object_names.tps | 2 +- source/core/types/ut_output_reporter_base.tpb | 2 +- source/core/types/ut_output_reporter_base.tps | 2 +- source/core/types/ut_reporter_base.tpb | 2 +- source/core/types/ut_reporter_base.tps | 2 +- source/core/types/ut_reporter_info.tps | 2 +- source/core/types/ut_reporters.tps | 2 +- source/core/types/ut_reporters_info.tps | 2 +- source/core/types/ut_results_counter.tpb | 2 +- source/core/types/ut_results_counter.tps | 2 +- source/core/types/ut_run.tpb | 2 +- source/core/types/ut_run.tps | 2 +- source/core/types/ut_run_info.tpb | 2 +- source/core/types/ut_run_info.tps | 2 +- source/core/types/ut_suite.tpb | 2 +- source/core/types/ut_suite.tps | 2 +- source/core/types/ut_suite_cache_row.tps | 2 +- source/core/types/ut_suite_cache_rows.tps | 2 +- source/core/types/ut_suite_context.tpb | 2 +- source/core/types/ut_suite_context.tps | 2 +- source/core/types/ut_suite_item.tpb | 2 +- source/core/types/ut_suite_item.tps | 2 +- source/core/types/ut_suite_items.tps | 2 +- source/core/types/ut_test.tpb | 2 +- source/core/types/ut_test.tps | 2 +- source/core/types/ut_varchar2_list.tps | 2 +- source/core/types/ut_varchar2_rows.tps | 2 +- source/core/ut_dbms_output_cache.sql | 2 +- source/core/ut_expectation_processor.pkb | 2 +- source/core/ut_expectation_processor.pks | 2 +- source/core/ut_file_mapper.pkb | 2 +- source/core/ut_file_mapper.pks | 2 +- source/core/ut_metadata.pkb | 2 +- source/core/ut_metadata.pks | 2 +- source/core/ut_savepoint_seq.sql | 2 +- source/core/ut_suite_builder.pkb | 2 +- source/core/ut_suite_builder.pks | 2 +- source/core/ut_suite_cache.sql | 2 +- source/core/ut_suite_cache_manager.pkb | 2 +- source/core/ut_suite_cache_manager.pks | 2 +- source/core/ut_suite_cache_package.sql | 2 +- source/core/ut_suite_cache_schema.sql | 2 +- source/core/ut_suite_cache_seq.sql | 2 +- source/core/ut_suite_manager.pkb | 2 +- source/core/ut_suite_manager.pks | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- source/create_grants.sql | 2 +- source/create_synonyms.sql | 2 +- source/create_synonyms_and_grants_for_public.sql | 2 +- source/create_user_grants.sql | 2 +- source/create_user_synonyms.sql | 2 +- source/create_utplsql_owner.sql | 2 +- source/define_ut3_owner_param.sql | 2 +- source/expectations/data_values/ut_compound_data_diff_tmp.sql | 2 +- source/expectations/data_values/ut_compound_data_helper.pkb | 2 +- source/expectations/data_values/ut_compound_data_helper.pks | 2 +- source/expectations/data_values/ut_compound_data_tmp.sql | 2 +- source/expectations/data_values/ut_compound_data_value.tpb | 2 +- source/expectations/data_values/ut_compound_data_value.tps | 2 +- source/expectations/data_values/ut_cursor_column.tps | 2 +- source/expectations/data_values/ut_cursor_column_tab.tps | 2 +- source/expectations/data_values/ut_cursor_details.tps | 2 +- source/expectations/data_values/ut_data_value.tpb | 2 +- source/expectations/data_values/ut_data_value.tps | 2 +- source/expectations/data_values/ut_data_value_anydata.tpb | 2 +- source/expectations/data_values/ut_data_value_anydata.tps | 2 +- source/expectations/data_values/ut_data_value_blob.tpb | 2 +- source/expectations/data_values/ut_data_value_blob.tps | 2 +- source/expectations/data_values/ut_data_value_boolean.tpb | 2 +- source/expectations/data_values/ut_data_value_boolean.tps | 2 +- source/expectations/data_values/ut_data_value_clob.tpb | 2 +- source/expectations/data_values/ut_data_value_clob.tps | 2 +- source/expectations/data_values/ut_data_value_date.tpb | 2 +- source/expectations/data_values/ut_data_value_date.tps | 2 +- source/expectations/data_values/ut_data_value_dsinterval.tpb | 2 +- source/expectations/data_values/ut_data_value_dsinterval.tps | 2 +- source/expectations/data_values/ut_data_value_json.tpb | 2 +- source/expectations/data_values/ut_data_value_json.tps | 2 +- source/expectations/data_values/ut_data_value_number.tpb | 2 +- source/expectations/data_values/ut_data_value_number.tps | 2 +- source/expectations/data_values/ut_data_value_refcursor.tpb | 2 +- source/expectations/data_values/ut_data_value_refcursor.tps | 2 +- source/expectations/data_values/ut_data_value_timestamp.tpb | 2 +- source/expectations/data_values/ut_data_value_timestamp.tps | 2 +- source/expectations/data_values/ut_data_value_timestamp_ltz.tpb | 2 +- source/expectations/data_values/ut_data_value_timestamp_ltz.tps | 2 +- source/expectations/data_values/ut_data_value_timestamp_tz.tpb | 2 +- source/expectations/data_values/ut_data_value_timestamp_tz.tps | 2 +- source/expectations/data_values/ut_data_value_varchar2.tpb | 2 +- source/expectations/data_values/ut_data_value_varchar2.tps | 2 +- source/expectations/data_values/ut_data_value_xmltype.tpb | 2 +- source/expectations/data_values/ut_data_value_xmltype.tps | 2 +- source/expectations/data_values/ut_data_value_yminterval.tpb | 2 +- source/expectations/data_values/ut_data_value_yminterval.tps | 2 +- source/expectations/data_values/ut_json_data_diff_tmp.sql | 2 +- source/expectations/data_values/ut_json_leaf.tps | 2 +- source/expectations/data_values/ut_json_leaf_tab.tps | 2 +- source/expectations/data_values/ut_json_tree_details.tps | 2 +- source/expectations/data_values/ut_key_anyval_pair.tps | 2 +- source/expectations/data_values/ut_key_anyval_pairs.tps | 2 +- source/expectations/data_values/ut_key_anyvalues.tpb | 2 +- source/expectations/data_values/ut_key_anyvalues.tps | 2 +- source/expectations/matchers/ut_be_between.tpb | 2 +- source/expectations/matchers/ut_be_between.tps | 2 +- source/expectations/matchers/ut_be_empty.tpb | 2 +- source/expectations/matchers/ut_be_empty.tps | 2 +- source/expectations/matchers/ut_be_false.tpb | 2 +- source/expectations/matchers/ut_be_false.tps | 2 +- source/expectations/matchers/ut_be_greater_or_equal.tpb | 2 +- source/expectations/matchers/ut_be_greater_or_equal.tps | 2 +- source/expectations/matchers/ut_be_greater_than.tpb | 2 +- source/expectations/matchers/ut_be_greater_than.tps | 2 +- source/expectations/matchers/ut_be_less_or_equal.tpb | 2 +- source/expectations/matchers/ut_be_less_or_equal.tps | 2 +- source/expectations/matchers/ut_be_less_than.tpb | 2 +- source/expectations/matchers/ut_be_less_than.tps | 2 +- source/expectations/matchers/ut_be_like.tpb | 2 +- source/expectations/matchers/ut_be_like.tps | 2 +- source/expectations/matchers/ut_be_not_null.tpb | 2 +- source/expectations/matchers/ut_be_not_null.tps | 2 +- source/expectations/matchers/ut_be_null.tpb | 2 +- source/expectations/matchers/ut_be_null.tps | 2 +- source/expectations/matchers/ut_be_true.tpb | 2 +- source/expectations/matchers/ut_be_true.tps | 2 +- source/expectations/matchers/ut_comparison_matcher.tpb | 2 +- source/expectations/matchers/ut_comparison_matcher.tps | 2 +- source/expectations/matchers/ut_contain.tpb | 2 +- source/expectations/matchers/ut_contain.tps | 2 +- source/expectations/matchers/ut_equal.tpb | 2 +- source/expectations/matchers/ut_equal.tps | 2 +- source/expectations/matchers/ut_have_count.tpb | 2 +- source/expectations/matchers/ut_have_count.tps | 2 +- source/expectations/matchers/ut_match.tpb | 2 +- source/expectations/matchers/ut_match.tps | 2 +- source/expectations/matchers/ut_matcher.tpb | 2 +- source/expectations/matchers/ut_matcher.tps | 2 +- source/expectations/matchers/ut_matcher_options.tpb | 2 +- source/expectations/matchers/ut_matcher_options.tps | 2 +- source/expectations/matchers/ut_matcher_options_items.tpb | 2 +- source/expectations/matchers/ut_matcher_options_items.tps | 2 +- source/expectations/ut_expectation.tpb | 2 +- source/expectations/ut_expectation.tps | 2 +- source/expectations/ut_expectation_compound.tpb | 2 +- source/expectations/ut_expectation_compound.tps | 2 +- source/expectations/ut_expectation_json.tpb | 2 +- source/expectations/ut_expectation_json.tps | 2 +- source/install.sql | 2 +- source/install_component.sql | 2 +- source/install_ddl_trigger.sql | 2 +- source/install_headless.sql | 2 +- source/install_headless_with_trigger.sql | 2 +- source/reporters/ut_ansiconsole_helper.pkb | 2 +- source/reporters/ut_ansiconsole_helper.pks | 2 +- source/reporters/ut_coverage_cobertura_reporter.tpb | 2 +- source/reporters/ut_coverage_cobertura_reporter.tps | 2 +- source/reporters/ut_coverage_html_reporter.tpb | 2 +- source/reporters/ut_coverage_html_reporter.tps | 2 +- source/reporters/ut_coverage_report_html_helper.pkb | 2 +- source/reporters/ut_coverage_report_html_helper.pks | 2 +- source/reporters/ut_coverage_sonar_reporter.tpb | 2 +- source/reporters/ut_coverage_sonar_reporter.tps | 2 +- source/reporters/ut_coveralls_reporter.tpb | 2 +- source/reporters/ut_coveralls_reporter.tps | 2 +- source/reporters/ut_debug_reporter.tpb | 2 +- source/reporters/ut_debug_reporter.tps | 2 +- source/reporters/ut_documentation_reporter.tpb | 2 +- source/reporters/ut_documentation_reporter.tps | 2 +- source/reporters/ut_junit_reporter.tpb | 2 +- source/reporters/ut_junit_reporter.tps | 2 +- source/reporters/ut_realtime_reporter.tpb | 2 +- source/reporters/ut_realtime_reporter.tps | 2 +- source/reporters/ut_sonar_test_reporter.tpb | 2 +- source/reporters/ut_sonar_test_reporter.tps | 2 +- source/reporters/ut_teamcity_reporter.tpb | 2 +- source/reporters/ut_teamcity_reporter.tps | 2 +- source/reporters/ut_teamcity_reporter_helper.pkb | 2 +- source/reporters/ut_teamcity_reporter_helper.pks | 2 +- source/reporters/ut_tfs_junit_reporter.tpb | 2 +- source/reporters/ut_tfs_junit_reporter.tps | 2 +- source/reporters/ut_xunit_reporter.tpb | 2 +- source/reporters/ut_xunit_reporter.tps | 2 +- source/set_install_params.sql | 2 +- source/uninstall.sql | 2 +- source/uninstall_all.sql | 2 +- 266 files changed, 266 insertions(+), 266 deletions(-) diff --git a/source/api/ut.pkb b/source/api/ut.pkb index 81d3e59a7..9e3defe16 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -2,7 +2,7 @@ create or replace package body ut is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut.pks b/source/api/ut.pks index ff75179b0..2cce4e183 100644 --- a/source/api/ut.pks +++ b/source/api/ut.pks @@ -2,7 +2,7 @@ create or replace package ut authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index bb7d3e458..d2bd74b91 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -2,7 +2,7 @@ create or replace package body ut_runner is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_runner.pks b/source/api/ut_runner.pks index 61578a4e0..75aa12f8f 100644 --- a/source/api/ut_runner.pks +++ b/source/api/ut_runner.pks @@ -2,7 +2,7 @@ create or replace package ut_runner authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_suite_item_info.tpb b/source/api/ut_suite_item_info.tpb index 9b142acb0..97d931c59 100644 --- a/source/api/ut_suite_item_info.tpb +++ b/source/api/ut_suite_item_info.tpb @@ -1,7 +1,7 @@ create or replace type body ut_suite_item_info is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_suite_item_info.tps b/source/api/ut_suite_item_info.tps index 807635d1b..2c0f16198 100644 --- a/source/api/ut_suite_item_info.tps +++ b/source/api/ut_suite_item_info.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_item_info as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_suite_items_info.tps b/source/api/ut_suite_items_info.tps index 7c9ac33c3..208098f9d 100644 --- a/source/api/ut_suite_items_info.tps +++ b/source/api/ut_suite_items_info.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_items_info as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotated_object.tps b/source/core/annotations/ut_annotated_object.tps index 06a0f4a36..3fda363fe 100644 --- a/source/core/annotations/ut_annotated_object.tps +++ b/source/core/annotations/ut_annotated_object.tps @@ -1,7 +1,7 @@ create type ut_annotated_object as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotated_objects.tps b/source/core/annotations/ut_annotated_objects.tps index c7b142a32..c67c1bd53 100644 --- a/source/core/annotations/ut_annotated_objects.tps +++ b/source/core/annotations/ut_annotated_objects.tps @@ -1,7 +1,7 @@ create type ut_annotated_objects as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation.tps b/source/core/annotations/ut_annotation.tps index 982c0348c..3d0311571 100644 --- a/source/core/annotations/ut_annotation.tps +++ b/source/core/annotations/ut_annotation.tps @@ -1,7 +1,7 @@ create type ut_annotation as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_cache.sql b/source/core/annotations/ut_annotation_cache.sql index 8baa6e75c..67149ce60 100644 --- a/source/core/annotations/ut_annotation_cache.sql +++ b/source/core/annotations/ut_annotation_cache.sql @@ -1,7 +1,7 @@ create table ut_annotation_cache ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/annotations/ut_annotation_cache_info.sql b/source/core/annotations/ut_annotation_cache_info.sql index 7bbf99e00..167973a04 100644 --- a/source/core/annotations/ut_annotation_cache_info.sql +++ b/source/core/annotations/ut_annotation_cache_info.sql @@ -1,7 +1,7 @@ create table ut_annotation_cache_info ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index cef6fa519..17129c316 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_annotation_cache_manager as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_cache_manager.pks b/source/core/annotations/ut_annotation_cache_manager.pks index e4ba6dd7a..1e9734934 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pks +++ b/source/core/annotations/ut_annotation_cache_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_annotation_cache_manager authid definer as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_cache_schema.sql b/source/core/annotations/ut_annotation_cache_schema.sql index b8f908e84..8889b9abf 100644 --- a/source/core/annotations/ut_annotation_cache_schema.sql +++ b/source/core/annotations/ut_annotation_cache_schema.sql @@ -1,7 +1,7 @@ create table ut_annotation_cache_schema ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/annotations/ut_annotation_cache_seq.sql b/source/core/annotations/ut_annotation_cache_seq.sql index 0a898e98e..b371b382b 100644 --- a/source/core/annotations/ut_annotation_cache_seq.sql +++ b/source/core/annotations/ut_annotation_cache_seq.sql @@ -1,7 +1,7 @@ create sequence ut_annotation_cache_seq /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index ca0c358cf..95d944843 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_annotation_manager as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_manager.pks b/source/core/annotations/ut_annotation_manager.pks index 70257afac..20fcd810f 100644 --- a/source/core/annotations/ut_annotation_manager.pks +++ b/source/core/annotations/ut_annotation_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_annotation_manager authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_obj_cache_info.tps b/source/core/annotations/ut_annotation_obj_cache_info.tps index 4b8178a9d..1db3fd190 100644 --- a/source/core/annotations/ut_annotation_obj_cache_info.tps +++ b/source/core/annotations/ut_annotation_obj_cache_info.tps @@ -1,7 +1,7 @@ create type ut_annotation_obj_cache_info as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_objs_cache_info.tps b/source/core/annotations/ut_annotation_objs_cache_info.tps index bab33a9d3..fc96e7d25 100644 --- a/source/core/annotations/ut_annotation_objs_cache_info.tps +++ b/source/core/annotations/ut_annotation_objs_cache_info.tps @@ -1,7 +1,7 @@ create type ut_annotation_objs_cache_info as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 6ef15a3ac..f0271c957 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -1,7 +1,7 @@ create or replace package body ut_annotation_parser as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_parser.pks b/source/core/annotations/ut_annotation_parser.pks index 0368811db..2f474c883 100644 --- a/source/core/annotations/ut_annotation_parser.pks +++ b/source/core/annotations/ut_annotation_parser.pks @@ -1,7 +1,7 @@ create or replace package ut_annotation_parser authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotations.tps b/source/core/annotations/ut_annotations.tps index 85be05e72..a6579d236 100644 --- a/source/core/annotations/ut_annotations.tps +++ b/source/core/annotations/ut_annotations.tps @@ -1,7 +1,7 @@ create type ut_annotations /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_trigger_check.pkb b/source/core/annotations/ut_trigger_check.pkb index 76d3aa11c..34e43ba46 100644 --- a/source/core/annotations/ut_trigger_check.pkb +++ b/source/core/annotations/ut_trigger_check.pkb @@ -1,7 +1,7 @@ create or replace package body ut_trigger_check is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_trigger_check.pks b/source/core/annotations/ut_trigger_check.pks index c4c27c596..cee0b06fd 100644 --- a/source/core/annotations/ut_trigger_check.pks +++ b/source/core/annotations/ut_trigger_check.pks @@ -1,7 +1,7 @@ create or replace package ut_trigger_check authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 1900e6c3c..ddcdeaf2e 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage.pks b/source/core/coverage/ut_coverage.pks index ba5263dd2..210cb13f6 100644 --- a/source/core/coverage/ut_coverage.pks +++ b/source/core/coverage/ut_coverage.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_block.pkb b/source/core/coverage/ut_coverage_block.pkb index 79fd42699..a906b81a3 100644 --- a/source/core/coverage/ut_coverage_block.pkb +++ b/source/core/coverage/ut_coverage_block.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_block is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_block.pks b/source/core/coverage/ut_coverage_block.pks index 08de58e69..01caca035 100644 --- a/source/core/coverage/ut_coverage_block.pks +++ b/source/core/coverage/ut_coverage_block.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_block authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper.pkb b/source/core/coverage/ut_coverage_helper.pkb index a000237c6..e249b3381 100644 --- a/source/core/coverage/ut_coverage_helper.pkb +++ b/source/core/coverage/ut_coverage_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper.pks b/source/core/coverage/ut_coverage_helper.pks index 632b18a0d..cd6ed9ec7 100644 --- a/source/core/coverage/ut_coverage_helper.pks +++ b/source/core/coverage/ut_coverage_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_helper authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index 913b0fb4c..25cb00f90 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_helper_block is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper_block.pks b/source/core/coverage/ut_coverage_helper_block.pks index 18adf4fbd..a147d9f4f 100644 --- a/source/core/coverage/ut_coverage_helper_block.pks +++ b/source/core/coverage/ut_coverage_helper_block.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_helper_block authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper_profiler.pkb b/source/core/coverage/ut_coverage_helper_profiler.pkb index 22aa6619d..f29291efb 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pkb +++ b/source/core/coverage/ut_coverage_helper_profiler.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_helper_profiler is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper_profiler.pks b/source/core/coverage/ut_coverage_helper_profiler.pks index f105d3c9c..0c54a83bf 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pks +++ b/source/core/coverage/ut_coverage_helper_profiler.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_helper_profiler authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_profiler.pkb b/source/core/coverage/ut_coverage_profiler.pkb index 6d9f894d5..663ceab7f 100644 --- a/source/core/coverage/ut_coverage_profiler.pkb +++ b/source/core/coverage/ut_coverage_profiler.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_profiler is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_profiler.pks b/source/core/coverage/ut_coverage_profiler.pks index 59256ae65..9ce9a27f0 100644 --- a/source/core/coverage/ut_coverage_profiler.pks +++ b/source/core/coverage/ut_coverage_profiler.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_profiler authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_reporter_base.tpb b/source/core/coverage/ut_coverage_reporter_base.tpb index 1cc856ea6..aff4e6560 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tpb +++ b/source/core/coverage/ut_coverage_reporter_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_reporter_base is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_reporter_base.tps b/source/core/coverage/ut_coverage_reporter_base.tps index cae165258..305c5d757 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tps +++ b/source/core/coverage/ut_coverage_reporter_base.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_reporter_base under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_sources_tmp.sql b/source/core/coverage/ut_coverage_sources_tmp.sql index abaae5353..c091d5955 100644 --- a/source/core/coverage/ut_coverage_sources_tmp.sql +++ b/source/core/coverage/ut_coverage_sources_tmp.sql @@ -1,7 +1,7 @@ create global temporary table ut_coverage_sources_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/events/ut_event_item.tps b/source/core/events/ut_event_item.tps index efec940f5..c0ea653ea 100644 --- a/source/core/events/ut_event_item.tps +++ b/source/core/events/ut_event_item.tps @@ -1,7 +1,7 @@ create or replace type ut_event_item authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/events/ut_event_listener.tps b/source/core/events/ut_event_listener.tps index 71ee16a0f..bbcdbf218 100644 --- a/source/core/events/ut_event_listener.tps +++ b/source/core/events/ut_event_listener.tps @@ -1,7 +1,7 @@ create or replace type ut_event_listener authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/events/ut_event_manager.pkb b/source/core/events/ut_event_manager.pkb index 039eb43a0..f51019421 100644 --- a/source/core/events/ut_event_manager.pkb +++ b/source/core/events/ut_event_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_event_manager as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/events/ut_event_manager.pks b/source/core/events/ut_event_manager.pks index f67bd0f4d..03b18b728 100644 --- a/source/core/events/ut_event_manager.pks +++ b/source/core/events/ut_event_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_event_manager authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index 412f30836..6d7964150 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_output_buffer_base is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_buffer_base.tps b/source/core/output_buffers/ut_output_buffer_base.tps index 745692f38..98a6847cd 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tps +++ b/source/core/output_buffers/ut_output_buffer_base.tps @@ -1,7 +1,7 @@ create or replace type ut_output_buffer_base force authid definer as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_buffer_info_tmp.sql b/source/core/output_buffers/ut_output_buffer_info_tmp.sql index ec09619d2..af730d394 100644 --- a/source/core/output_buffers/ut_output_buffer_info_tmp.sql +++ b/source/core/output_buffers/ut_output_buffer_info_tmp.sql @@ -1,7 +1,7 @@ create table ut_output_buffer_info_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/output_buffers/ut_output_buffer_tmp.sql b/source/core/output_buffers/ut_output_buffer_tmp.sql index 49fefa24d..57027817e 100644 --- a/source/core/output_buffers/ut_output_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_buffer_tmp.sql @@ -1,7 +1,7 @@ create table ut_output_buffer_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql index 48cfe6fde..40dda121f 100644 --- a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql @@ -6,7 +6,7 @@ begin v_table_sql := 'create table ut_output_clob_buffer_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index 8d23b9422..66ff71c62 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -1,7 +1,7 @@ create or replace type body ut_output_clob_table_buffer is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tps b/source/core/output_buffers/ut_output_clob_table_buffer.tps index 2eb3640b0..7b98efaba 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tps +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tps @@ -1,7 +1,7 @@ create or replace type ut_output_clob_table_buffer under ut_output_buffer_base ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_data_row.tps b/source/core/output_buffers/ut_output_data_row.tps index b0f5efe91..c5dd95e98 100644 --- a/source/core/output_buffers/ut_output_data_row.tps +++ b/source/core/output_buffers/ut_output_data_row.tps @@ -1,7 +1,7 @@ create or replace type ut_output_data_row as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_data_rows.tps b/source/core/output_buffers/ut_output_data_rows.tps index 1918f0c81..097e9beff 100644 --- a/source/core/output_buffers/ut_output_data_rows.tps +++ b/source/core/output_buffers/ut_output_data_rows.tps @@ -1,7 +1,7 @@ create or replace type ut_output_data_rows as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index 5f9c536f9..1809a49d5 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -1,7 +1,7 @@ create or replace type body ut_output_table_buffer is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_table_buffer.tps b/source/core/output_buffers/ut_output_table_buffer.tps index 3e395304a..726b692f8 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tps +++ b/source/core/output_buffers/ut_output_table_buffer.tps @@ -1,7 +1,7 @@ create or replace type ut_output_table_buffer under ut_output_buffer_base ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/session_context/ut_session_context.pkb b/source/core/session_context/ut_session_context.pkb index 2364d8513..a97505e9c 100644 --- a/source/core/session_context/ut_session_context.pkb +++ b/source/core/session_context/ut_session_context.pkb @@ -1,7 +1,7 @@ create or replace package body ut_session_context as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/session_context/ut_session_context.pks b/source/core/session_context/ut_session_context.pks index bbe256db4..63da3399e 100644 --- a/source/core/session_context/ut_session_context.pks +++ b/source/core/session_context/ut_session_context.pks @@ -1,7 +1,7 @@ create or replace package ut_session_context as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/session_context/ut_session_info.tpb b/source/core/session_context/ut_session_info.tpb index 2d3fdbed9..c7fe7dc5f 100644 --- a/source/core/session_context/ut_session_info.tpb +++ b/source/core/session_context/ut_session_info.tpb @@ -1,7 +1,7 @@ create or replace type body ut_session_info as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/session_context/ut_session_info.tps b/source/core/session_context/ut_session_info.tps index 863b0dc3e..17e596d88 100644 --- a/source/core/session_context/ut_session_info.tps +++ b/source/core/session_context/ut_session_info.tps @@ -1,7 +1,7 @@ create or replace type ut_session_info under ut_event_listener ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_console_reporter_base.tpb b/source/core/types/ut_console_reporter_base.tpb index df256e832..909e9355a 100644 --- a/source/core/types/ut_console_reporter_base.tpb +++ b/source/core/types/ut_console_reporter_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_console_reporter_base is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_console_reporter_base.tps b/source/core/types/ut_console_reporter_base.tps index 6c0a08502..a2c4b6b8c 100644 --- a/source/core/types/ut_console_reporter_base.tps +++ b/source/core/types/ut_console_reporter_base.tps @@ -1,7 +1,7 @@ create or replace type ut_console_reporter_base under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_coverage_options.tpb b/source/core/types/ut_coverage_options.tpb index 6eb4921a7..308c75553 100644 --- a/source/core/types/ut_coverage_options.tpb +++ b/source/core/types/ut_coverage_options.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_options as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_coverage_options.tps b/source/core/types/ut_coverage_options.tps index d6e86b653..1be518c5e 100644 --- a/source/core/types/ut_coverage_options.tps +++ b/source/core/types/ut_coverage_options.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_options force as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executable.tpb b/source/core/types/ut_executable.tpb index 826a5aaa1..d2ce9b79d 100644 --- a/source/core/types/ut_executable.tpb +++ b/source/core/types/ut_executable.tpb @@ -1,7 +1,7 @@ create or replace type body ut_executable is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executable.tps b/source/core/types/ut_executable.tps index 786d926ad..aaa5a3a72 100644 --- a/source/core/types/ut_executable.tps +++ b/source/core/types/ut_executable.tps @@ -1,7 +1,7 @@ create or replace type ut_executable under ut_event_item( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index 6f25ea1c8..c5a7f29a1 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -1,7 +1,7 @@ create or replace type body ut_executable_test as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executable_test.tps b/source/core/types/ut_executable_test.tps index 88500c9be..42b6080df 100644 --- a/source/core/types/ut_executable_test.tps +++ b/source/core/types/ut_executable_test.tps @@ -1,7 +1,7 @@ create or replace type ut_executable_test authid current_user under ut_executable ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executables.tps b/source/core/types/ut_executables.tps index f5732d5a1..d6d52b3d2 100644 --- a/source/core/types/ut_executables.tps +++ b/source/core/types/ut_executables.tps @@ -1,7 +1,7 @@ create or replace type ut_executables as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_expectation_result.tpb b/source/core/types/ut_expectation_result.tpb index 9aa8b81c0..0b3adf983 100644 --- a/source/core/types/ut_expectation_result.tpb +++ b/source/core/types/ut_expectation_result.tpb @@ -1,7 +1,7 @@ create or replace type body ut_expectation_result is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_expectation_result.tps b/source/core/types/ut_expectation_result.tps index 815d90820..d4b4c7548 100644 --- a/source/core/types/ut_expectation_result.tps +++ b/source/core/types/ut_expectation_result.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation_result under ut_event_item( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_expectation_results.tps b/source/core/types/ut_expectation_results.tps index 963c726f8..e5e4c6223 100644 --- a/source/core/types/ut_expectation_results.tps +++ b/source/core/types/ut_expectation_results.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation_results as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_file_mapping.tpb b/source/core/types/ut_file_mapping.tpb index 247aa5ac8..dab1e35c5 100644 --- a/source/core/types/ut_file_mapping.tpb +++ b/source/core/types/ut_file_mapping.tpb @@ -1,7 +1,7 @@ create or replace type body ut_file_mapping as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_file_mapping.tps b/source/core/types/ut_file_mapping.tps index c032e0b77..941d95283 100644 --- a/source/core/types/ut_file_mapping.tps +++ b/source/core/types/ut_file_mapping.tps @@ -1,7 +1,7 @@ create or replace type ut_file_mapping as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_file_mappings.tps b/source/core/types/ut_file_mappings.tps index a48c3e872..240fb8dd7 100644 --- a/source/core/types/ut_file_mappings.tps +++ b/source/core/types/ut_file_mappings.tps @@ -1,7 +1,7 @@ create or replace type ut_file_mappings as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_integer_list.tps b/source/core/types/ut_integer_list.tps index 25f1679b2..ec9a2a78f 100644 --- a/source/core/types/ut_integer_list.tps +++ b/source/core/types/ut_integer_list.tps @@ -1,7 +1,7 @@ create or replace type ut_integer_list as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_key_value_pair.tps b/source/core/types/ut_key_value_pair.tps index 873a354fd..5a337e608 100644 --- a/source/core/types/ut_key_value_pair.tps +++ b/source/core/types/ut_key_value_pair.tps @@ -1,7 +1,7 @@ create or replace type ut_key_value_pair force as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_key_value_pairs.tps b/source/core/types/ut_key_value_pairs.tps index 28fa87cf0..24bdded36 100644 --- a/source/core/types/ut_key_value_pairs.tps +++ b/source/core/types/ut_key_value_pairs.tps @@ -1,7 +1,7 @@ create or replace type ut_key_value_pairs as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_logical_suite.tpb b/source/core/types/ut_logical_suite.tpb index 74c7ff81c..486cb83e7 100644 --- a/source/core/types/ut_logical_suite.tpb +++ b/source/core/types/ut_logical_suite.tpb @@ -1,7 +1,7 @@ create or replace type body ut_logical_suite as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_logical_suite.tps b/source/core/types/ut_logical_suite.tps index 71cfdb23d..0f816f26b 100644 --- a/source/core/types/ut_logical_suite.tps +++ b/source/core/types/ut_logical_suite.tps @@ -1,7 +1,7 @@ create or replace type ut_logical_suite under ut_suite_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_object_name.tpb b/source/core/types/ut_object_name.tpb index cf1ab2a78..76acc15bf 100644 --- a/source/core/types/ut_object_name.tpb +++ b/source/core/types/ut_object_name.tpb @@ -1,7 +1,7 @@ create or replace type body ut_object_name as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_object_name.tps b/source/core/types/ut_object_name.tps index 28e41958f..5f8f724c4 100644 --- a/source/core/types/ut_object_name.tps +++ b/source/core/types/ut_object_name.tps @@ -1,7 +1,7 @@ create or replace type ut_object_name as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_object_names.tps b/source/core/types/ut_object_names.tps index 2f7e5ea16..03830be17 100644 --- a/source/core/types/ut_object_names.tps +++ b/source/core/types/ut_object_names.tps @@ -1,7 +1,7 @@ create or replace type ut_object_names as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_output_reporter_base.tpb b/source/core/types/ut_output_reporter_base.tpb index b8dc24667..f6bb27b94 100644 --- a/source/core/types/ut_output_reporter_base.tpb +++ b/source/core/types/ut_output_reporter_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_output_reporter_base is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_output_reporter_base.tps b/source/core/types/ut_output_reporter_base.tps index 01350208a..22f507f8d 100644 --- a/source/core/types/ut_output_reporter_base.tps +++ b/source/core/types/ut_output_reporter_base.tps @@ -1,7 +1,7 @@ create or replace type ut_output_reporter_base under ut_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporter_base.tpb b/source/core/types/ut_reporter_base.tpb index 94d518af4..3f8984331 100644 --- a/source/core/types/ut_reporter_base.tpb +++ b/source/core/types/ut_reporter_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_reporter_base is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporter_base.tps b/source/core/types/ut_reporter_base.tps index 36af70776..de157136e 100644 --- a/source/core/types/ut_reporter_base.tps +++ b/source/core/types/ut_reporter_base.tps @@ -1,7 +1,7 @@ create or replace type ut_reporter_base under ut_event_listener ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporter_info.tps b/source/core/types/ut_reporter_info.tps index d1f159211..f09c42e07 100644 --- a/source/core/types/ut_reporter_info.tps +++ b/source/core/types/ut_reporter_info.tps @@ -1,7 +1,7 @@ create or replace type ut_reporter_info as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporters.tps b/source/core/types/ut_reporters.tps index b16e74653..a2802bb26 100644 --- a/source/core/types/ut_reporters.tps +++ b/source/core/types/ut_reporters.tps @@ -1,7 +1,7 @@ create or replace type ut_reporters as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporters_info.tps b/source/core/types/ut_reporters_info.tps index 6e9a866ef..82c264f36 100644 --- a/source/core/types/ut_reporters_info.tps +++ b/source/core/types/ut_reporters_info.tps @@ -1,7 +1,7 @@ create or replace type ut_reporters_info as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_results_counter.tpb b/source/core/types/ut_results_counter.tpb index 0007acd9b..811389e0e 100644 --- a/source/core/types/ut_results_counter.tpb +++ b/source/core/types/ut_results_counter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_results_counter as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_results_counter.tps b/source/core/types/ut_results_counter.tps index 1b26b673a..913ae0967 100644 --- a/source/core/types/ut_results_counter.tps +++ b/source/core/types/ut_results_counter.tps @@ -1,7 +1,7 @@ create or replace type ut_results_counter as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_run.tpb b/source/core/types/ut_run.tpb index 395b164f0..258396427 100644 --- a/source/core/types/ut_run.tpb +++ b/source/core/types/ut_run.tpb @@ -1,7 +1,7 @@ create or replace type body ut_run as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_run.tps b/source/core/types/ut_run.tps index 617347b25..f556934ce 100644 --- a/source/core/types/ut_run.tps +++ b/source/core/types/ut_run.tps @@ -1,7 +1,7 @@ create or replace type ut_run under ut_suite_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_run_info.tpb b/source/core/types/ut_run_info.tpb index ffa1a6372..6edc0f109 100644 --- a/source/core/types/ut_run_info.tpb +++ b/source/core/types/ut_run_info.tpb @@ -1,7 +1,7 @@ create or replace type body ut_run_info as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_run_info.tps b/source/core/types/ut_run_info.tps index f59c22c05..4a3da691f 100644 --- a/source/core/types/ut_run_info.tps +++ b/source/core/types/ut_run_info.tps @@ -1,7 +1,7 @@ create or replace type ut_run_info under ut_event_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite.tpb b/source/core/types/ut_suite.tpb index baaaf044d..2ec1c9ccd 100644 --- a/source/core/types/ut_suite.tpb +++ b/source/core/types/ut_suite.tpb @@ -1,7 +1,7 @@ create or replace type body ut_suite as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite.tps b/source/core/types/ut_suite.tps index ffe2d2d42..ff7f3e171 100644 --- a/source/core/types/ut_suite.tps +++ b/source/core/types/ut_suite.tps @@ -1,7 +1,7 @@ create or replace type ut_suite under ut_logical_suite ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_cache_row.tps b/source/core/types/ut_suite_cache_row.tps index d9f542de3..9c5990bfd 100644 --- a/source/core/types/ut_suite_cache_row.tps +++ b/source/core/types/ut_suite_cache_row.tps @@ -1,7 +1,7 @@ create type ut_suite_cache_row as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_cache_rows.tps b/source/core/types/ut_suite_cache_rows.tps index 660f934cf..9b6919df5 100644 --- a/source/core/types/ut_suite_cache_rows.tps +++ b/source/core/types/ut_suite_cache_rows.tps @@ -1,7 +1,7 @@ create type ut_suite_cache_rows as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_context.tpb b/source/core/types/ut_suite_context.tpb index 3669d3d7e..be92e6fc9 100644 --- a/source/core/types/ut_suite_context.tpb +++ b/source/core/types/ut_suite_context.tpb @@ -1,7 +1,7 @@ create or replace type body ut_suite_context as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_context.tps b/source/core/types/ut_suite_context.tps index a328e7657..5e3d20f87 100644 --- a/source/core/types/ut_suite_context.tps +++ b/source/core/types/ut_suite_context.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_context under ut_suite ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_item.tpb b/source/core/types/ut_suite_item.tpb index 9b939727a..12f857cba 100644 --- a/source/core/types/ut_suite_item.tpb +++ b/source/core/types/ut_suite_item.tpb @@ -1,7 +1,7 @@ create or replace type body ut_suite_item as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_item.tps b/source/core/types/ut_suite_item.tps index 87f577459..d96ec8c30 100644 --- a/source/core/types/ut_suite_item.tps +++ b/source/core/types/ut_suite_item.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_item force under ut_event_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_items.tps b/source/core/types/ut_suite_items.tps index e80bcc7b4..615283446 100644 --- a/source/core/types/ut_suite_items.tps +++ b/source/core/types/ut_suite_items.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_items as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_test.tpb b/source/core/types/ut_test.tpb index 4ed3f665e..9a36205c1 100644 --- a/source/core/types/ut_test.tpb +++ b/source/core/types/ut_test.tpb @@ -1,7 +1,7 @@ create or replace type body ut_test as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_test.tps b/source/core/types/ut_test.tps index 85caf7380..07958ec0f 100644 --- a/source/core/types/ut_test.tps +++ b/source/core/types/ut_test.tps @@ -1,7 +1,7 @@ create or replace type ut_test force under ut_suite_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_varchar2_list.tps b/source/core/types/ut_varchar2_list.tps index dd15f0d8f..f0b5df509 100644 --- a/source/core/types/ut_varchar2_list.tps +++ b/source/core/types/ut_varchar2_list.tps @@ -1,7 +1,7 @@ create or replace type ut_varchar2_list as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_varchar2_rows.tps b/source/core/types/ut_varchar2_rows.tps index d56eeee46..e7fa29c29 100644 --- a/source/core/types/ut_varchar2_rows.tps +++ b/source/core/types/ut_varchar2_rows.tps @@ -1,7 +1,7 @@ create or replace type ut_varchar2_rows as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_dbms_output_cache.sql b/source/core/ut_dbms_output_cache.sql index 3d4c12845..e61b403c8 100644 --- a/source/core/ut_dbms_output_cache.sql +++ b/source/core/ut_dbms_output_cache.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 -Copyright 2016 - 2019 utPLSQL Project +Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index 22e268dca..a03a28965 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -1,7 +1,7 @@ create or replace package body ut_expectation_processor as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_expectation_processor.pks b/source/core/ut_expectation_processor.pks index cfcae8b42..dd9187526 100644 --- a/source/core/ut_expectation_processor.pks +++ b/source/core/ut_expectation_processor.pks @@ -1,7 +1,7 @@ create or replace package ut_expectation_processor authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_file_mapper.pkb b/source/core/ut_file_mapper.pkb index adecb7dc8..425360533 100644 --- a/source/core/ut_file_mapper.pkb +++ b/source/core/ut_file_mapper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_file_mapper is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_file_mapper.pks b/source/core/ut_file_mapper.pks index 4ed670ee5..adc4c983f 100644 --- a/source/core/ut_file_mapper.pks +++ b/source/core/ut_file_mapper.pks @@ -1,7 +1,7 @@ create or replace package ut_file_mapper authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index 3afc9d1c6..700c0efb0 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -1,7 +1,7 @@ create or replace package body ut_metadata as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_metadata.pks b/source/core/ut_metadata.pks index bf62c4e52..27bfa5d30 100644 --- a/source/core/ut_metadata.pks +++ b/source/core/ut_metadata.pks @@ -1,7 +1,7 @@ create or replace package ut_metadata authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_savepoint_seq.sql b/source/core/ut_savepoint_seq.sql index b87d18e6d..5b0cda35e 100644 --- a/source/core/ut_savepoint_seq.sql +++ b/source/core/ut_savepoint_seq.sql @@ -1,7 +1,7 @@ create sequence ut_savepoint_seq /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index d13cbaed9..2dac6b4ad 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -1,7 +1,7 @@ create or replace package body ut_suite_builder is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_builder.pks b/source/core/ut_suite_builder.pks index e982fdbc1..352601a6d 100644 --- a/source/core/ut_suite_builder.pks +++ b/source/core/ut_suite_builder.pks @@ -1,7 +1,7 @@ create or replace package ut_suite_builder authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_cache.sql b/source/core/ut_suite_cache.sql index a7f998f83..182caabd0 100644 --- a/source/core/ut_suite_cache.sql +++ b/source/core/ut_suite_cache.sql @@ -1,7 +1,7 @@ create table ut_suite_cache /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index ebc9a839d..0ae8d7104 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_suite_cache_manager is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index d5b31ccee..0a38851fe 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_suite_cache_manager authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_cache_package.sql b/source/core/ut_suite_cache_package.sql index 06f786949..7a146ff83 100644 --- a/source/core/ut_suite_cache_package.sql +++ b/source/core/ut_suite_cache_package.sql @@ -1,7 +1,7 @@ create table ut_suite_cache_package ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_cache_schema.sql b/source/core/ut_suite_cache_schema.sql index 46c7b0ef3..636816e65 100644 --- a/source/core/ut_suite_cache_schema.sql +++ b/source/core/ut_suite_cache_schema.sql @@ -1,7 +1,7 @@ create table ut_suite_cache_schema ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_cache_seq.sql b/source/core/ut_suite_cache_seq.sql index 36de28809..e1e560286 100644 --- a/source/core/ut_suite_cache_seq.sql +++ b/source/core/ut_suite_cache_seq.sql @@ -1,7 +1,7 @@ create sequence ut_suite_cache_seq /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 60c33f21f..8a5bcb9b8 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_suite_manager is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 093201b36..5ae98d72a 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_suite_manager authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 4e0bafe7c..7c0daf878 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -1,7 +1,7 @@ create or replace package body ut_utils is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 35aff2929..f8dcc19ab 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -1,7 +1,7 @@ create or replace package ut_utils authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_grants.sql b/source/create_grants.sql index db26faa24..f7f37a662 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index 3f18ba3ed..a4f06c228 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_synonyms_and_grants_for_public.sql b/source/create_synonyms_and_grants_for_public.sql index 6d43c6b7a..050162d72 100644 --- a/source/create_synonyms_and_grants_for_public.sql +++ b/source/create_synonyms_and_grants_for_public.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_user_grants.sql b/source/create_user_grants.sql index 4ca721cf4..83e594884 100644 --- a/source/create_user_grants.sql +++ b/source/create_user_grants.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_user_synonyms.sql b/source/create_user_synonyms.sql index ee9f60fdd..a1e7a6acc 100644 --- a/source/create_user_synonyms.sql +++ b/source/create_user_synonyms.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_utplsql_owner.sql b/source/create_utplsql_owner.sql index 81325e925..1af2cf168 100644 --- a/source/create_utplsql_owner.sql +++ b/source/create_utplsql_owner.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/define_ut3_owner_param.sql b/source/define_ut3_owner_param.sql index 1b183b581..259b49712 100644 --- a/source/define_ut3_owner_param.sql +++ b/source/define_ut3_owner_param.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_compound_data_diff_tmp.sql b/source/expectations/data_values/ut_compound_data_diff_tmp.sql index e96d716b5..c10e8d2e8 100644 --- a/source/expectations/data_values/ut_compound_data_diff_tmp.sql +++ b/source/expectations/data_values/ut_compound_data_diff_tmp.sql @@ -1,7 +1,7 @@ create global temporary table ut_compound_data_diff_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 657c02ce3..37d9901ff 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_compound_data_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_compound_data_helper.pks b/source/expectations/data_values/ut_compound_data_helper.pks index b39df0039..53b0846b8 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pks +++ b/source/expectations/data_values/ut_compound_data_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_compound_data_helper authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_compound_data_tmp.sql b/source/expectations/data_values/ut_compound_data_tmp.sql index c860a1872..1bfa77fca 100644 --- a/source/expectations/data_values/ut_compound_data_tmp.sql +++ b/source/expectations/data_values/ut_compound_data_tmp.sql @@ -1,7 +1,7 @@ create global temporary table ut_compound_data_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/expectations/data_values/ut_compound_data_value.tpb b/source/expectations/data_values/ut_compound_data_value.tpb index 627e14680..2c52ff8fa 100644 --- a/source/expectations/data_values/ut_compound_data_value.tpb +++ b/source/expectations/data_values/ut_compound_data_value.tpb @@ -1,7 +1,7 @@ create or replace type body ut_compound_data_value as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_compound_data_value.tps b/source/expectations/data_values/ut_compound_data_value.tps index 027b5ca26..c14dadceb 100644 --- a/source/expectations/data_values/ut_compound_data_value.tps +++ b/source/expectations/data_values/ut_compound_data_value.tps @@ -1,7 +1,7 @@ create or replace type ut_compound_data_value force under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_cursor_column.tps b/source/expectations/data_values/ut_cursor_column.tps index c865ea64b..77bf78f01 100644 --- a/source/expectations/data_values/ut_cursor_column.tps +++ b/source/expectations/data_values/ut_cursor_column.tps @@ -1,7 +1,7 @@ create or replace type ut_cursor_column authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_cursor_column_tab.tps b/source/expectations/data_values/ut_cursor_column_tab.tps index b1b33f7fe..106023d96 100644 --- a/source/expectations/data_values/ut_cursor_column_tab.tps +++ b/source/expectations/data_values/ut_cursor_column_tab.tps @@ -1,7 +1,7 @@ create or replace type ut_cursor_column_tab as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_cursor_details.tps b/source/expectations/data_values/ut_cursor_details.tps index 7092e834f..e7f9405eb 100644 --- a/source/expectations/data_values/ut_cursor_details.tps +++ b/source/expectations/data_values/ut_cursor_details.tps @@ -1,7 +1,7 @@ create or replace type ut_cursor_details authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value.tpb b/source/expectations/data_values/ut_data_value.tpb index a644fe30e..6b1763dd0 100644 --- a/source/expectations/data_values/ut_data_value.tpb +++ b/source/expectations/data_values/ut_data_value.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value.tps b/source/expectations/data_values/ut_data_value.tps index ca7e18308..6864bc52e 100644 --- a/source/expectations/data_values/ut_data_value.tps +++ b/source/expectations/data_values/ut_data_value.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value force authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_anydata.tpb b/source/expectations/data_values/ut_data_value_anydata.tpb index bb52159e0..f6fbdc840 100644 --- a/source/expectations/data_values/ut_data_value_anydata.tpb +++ b/source/expectations/data_values/ut_data_value_anydata.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_anydata as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_anydata.tps b/source/expectations/data_values/ut_data_value_anydata.tps index 5ed0406ca..60dba5515 100644 --- a/source/expectations/data_values/ut_data_value_anydata.tps +++ b/source/expectations/data_values/ut_data_value_anydata.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_anydata under ut_data_value_refcursor( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_blob.tpb b/source/expectations/data_values/ut_data_value_blob.tpb index 11af6d2f7..a7b5fbeca 100644 --- a/source/expectations/data_values/ut_data_value_blob.tpb +++ b/source/expectations/data_values/ut_data_value_blob.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_blob as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_blob.tps b/source/expectations/data_values/ut_data_value_blob.tps index f557ffbce..6df3f3273 100644 --- a/source/expectations/data_values/ut_data_value_blob.tps +++ b/source/expectations/data_values/ut_data_value_blob.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_blob under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_boolean.tpb b/source/expectations/data_values/ut_data_value_boolean.tpb index 0645d3269..798222e30 100644 --- a/source/expectations/data_values/ut_data_value_boolean.tpb +++ b/source/expectations/data_values/ut_data_value_boolean.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_boolean as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_boolean.tps b/source/expectations/data_values/ut_data_value_boolean.tps index a254e05c0..e25b6e0fd 100644 --- a/source/expectations/data_values/ut_data_value_boolean.tps +++ b/source/expectations/data_values/ut_data_value_boolean.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_boolean under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_clob.tpb b/source/expectations/data_values/ut_data_value_clob.tpb index dacb390b6..9cfe9b283 100644 --- a/source/expectations/data_values/ut_data_value_clob.tpb +++ b/source/expectations/data_values/ut_data_value_clob.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_clob as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_clob.tps b/source/expectations/data_values/ut_data_value_clob.tps index 1ff5d5623..6869798d1 100644 --- a/source/expectations/data_values/ut_data_value_clob.tps +++ b/source/expectations/data_values/ut_data_value_clob.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_clob under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_date.tpb b/source/expectations/data_values/ut_data_value_date.tpb index dd87156bc..5b5b1d387 100644 --- a/source/expectations/data_values/ut_data_value_date.tpb +++ b/source/expectations/data_values/ut_data_value_date.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_date as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_date.tps b/source/expectations/data_values/ut_data_value_date.tps index 4435a3512..f64a577e0 100644 --- a/source/expectations/data_values/ut_data_value_date.tps +++ b/source/expectations/data_values/ut_data_value_date.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_date under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tpb b/source/expectations/data_values/ut_data_value_dsinterval.tpb index ff9d5fe1e..f81f35974 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tpb +++ b/source/expectations/data_values/ut_data_value_dsinterval.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_dsinterval as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tps b/source/expectations/data_values/ut_data_value_dsinterval.tps index 114619bf2..a047ead48 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tps +++ b/source/expectations/data_values/ut_data_value_dsinterval.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_dsinterval under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_json.tpb b/source/expectations/data_values/ut_data_value_json.tpb index 83916c30e..dfb3275ab 100644 --- a/source/expectations/data_values/ut_data_value_json.tpb +++ b/source/expectations/data_values/ut_data_value_json.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_json as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_json.tps b/source/expectations/data_values/ut_data_value_json.tps index bfaccb2e2..135124e64 100644 --- a/source/expectations/data_values/ut_data_value_json.tps +++ b/source/expectations/data_values/ut_data_value_json.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_json under ut_compound_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_number.tpb b/source/expectations/data_values/ut_data_value_number.tpb index b8a28a124..c5c4fe2c3 100644 --- a/source/expectations/data_values/ut_data_value_number.tpb +++ b/source/expectations/data_values/ut_data_value_number.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_number as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_number.tps b/source/expectations/data_values/ut_data_value_number.tps index 872ab405e..86d68f356 100644 --- a/source/expectations/data_values/ut_data_value_number.tps +++ b/source/expectations/data_values/ut_data_value_number.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_number under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_refcursor.tpb b/source/expectations/data_values/ut_data_value_refcursor.tpb index da5c1a381..2715614c4 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tpb +++ b/source/expectations/data_values/ut_data_value_refcursor.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_refcursor as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_refcursor.tps b/source/expectations/data_values/ut_data_value_refcursor.tps index 4de253b8f..594695e32 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tps +++ b/source/expectations/data_values/ut_data_value_refcursor.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_refcursor under ut_compound_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp.tpb b/source/expectations/data_values/ut_data_value_timestamp.tpb index adb18e360..79facae4a 100644 --- a/source/expectations/data_values/ut_data_value_timestamp.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_timestamp as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp.tps b/source/expectations/data_values/ut_data_value_timestamp.tps index ebd00762c..c047e3c79 100644 --- a/source/expectations/data_values/ut_data_value_timestamp.tps +++ b/source/expectations/data_values/ut_data_value_timestamp.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_timestamp under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb index 0f41e16b1..f2c5cddbd 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_timestamp_ltz as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp_ltz.tps b/source/expectations/data_values/ut_data_value_timestamp_ltz.tps index 3608ebd37..7bb296bc9 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_ltz.tps +++ b/source/expectations/data_values/ut_data_value_timestamp_ltz.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_timestamp_ltz under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb index 710a313a7..0991e9e9f 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_timestamp_tz as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp_tz.tps b/source/expectations/data_values/ut_data_value_timestamp_tz.tps index ca0bfc5cb..01cf11124 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_tz.tps +++ b/source/expectations/data_values/ut_data_value_timestamp_tz.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_timestamp_tz under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_varchar2.tpb b/source/expectations/data_values/ut_data_value_varchar2.tpb index da4276d51..307ca583d 100644 --- a/source/expectations/data_values/ut_data_value_varchar2.tpb +++ b/source/expectations/data_values/ut_data_value_varchar2.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_varchar2 as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_varchar2.tps b/source/expectations/data_values/ut_data_value_varchar2.tps index 27bb720ce..3fbeb378b 100644 --- a/source/expectations/data_values/ut_data_value_varchar2.tps +++ b/source/expectations/data_values/ut_data_value_varchar2.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_varchar2 under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_xmltype.tpb b/source/expectations/data_values/ut_data_value_xmltype.tpb index 3b10aadce..d17896492 100644 --- a/source/expectations/data_values/ut_data_value_xmltype.tpb +++ b/source/expectations/data_values/ut_data_value_xmltype.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_xmltype as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_xmltype.tps b/source/expectations/data_values/ut_data_value_xmltype.tps index 476097de3..9ba738b88 100644 --- a/source/expectations/data_values/ut_data_value_xmltype.tps +++ b/source/expectations/data_values/ut_data_value_xmltype.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_xmltype under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_yminterval.tpb b/source/expectations/data_values/ut_data_value_yminterval.tpb index 6d6a05b4a..7de3e58cd 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tpb +++ b/source/expectations/data_values/ut_data_value_yminterval.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_yminterval as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_yminterval.tps b/source/expectations/data_values/ut_data_value_yminterval.tps index d20dfcad7..278a2f803 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tps +++ b/source/expectations/data_values/ut_data_value_yminterval.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_yminterval under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_json_data_diff_tmp.sql b/source/expectations/data_values/ut_json_data_diff_tmp.sql index bfaaa1b72..5ff3440d8 100644 --- a/source/expectations/data_values/ut_json_data_diff_tmp.sql +++ b/source/expectations/data_values/ut_json_data_diff_tmp.sql @@ -1,7 +1,7 @@ create global temporary table ut_json_data_diff_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/expectations/data_values/ut_json_leaf.tps b/source/expectations/data_values/ut_json_leaf.tps index c38c3b238..8aa8afd6a 100644 --- a/source/expectations/data_values/ut_json_leaf.tps +++ b/source/expectations/data_values/ut_json_leaf.tps @@ -1,7 +1,7 @@ create or replace type ut_json_leaf authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_json_leaf_tab.tps b/source/expectations/data_values/ut_json_leaf_tab.tps index 0c7a40b9f..395ab5d9e 100644 --- a/source/expectations/data_values/ut_json_leaf_tab.tps +++ b/source/expectations/data_values/ut_json_leaf_tab.tps @@ -1,7 +1,7 @@ create or replace type ut_json_leaf_tab as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_json_tree_details.tps b/source/expectations/data_values/ut_json_tree_details.tps index 0684ecafe..20ac2fdcc 100644 --- a/source/expectations/data_values/ut_json_tree_details.tps +++ b/source/expectations/data_values/ut_json_tree_details.tps @@ -1,7 +1,7 @@ create or replace type ut_json_tree_details force as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_key_anyval_pair.tps b/source/expectations/data_values/ut_key_anyval_pair.tps index 4903282e9..d1068f109 100644 --- a/source/expectations/data_values/ut_key_anyval_pair.tps +++ b/source/expectations/data_values/ut_key_anyval_pair.tps @@ -1,7 +1,7 @@ create or replace type ut_key_anyval_pair force as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_key_anyval_pairs.tps b/source/expectations/data_values/ut_key_anyval_pairs.tps index 94bd5df54..7e10bf50f 100644 --- a/source/expectations/data_values/ut_key_anyval_pairs.tps +++ b/source/expectations/data_values/ut_key_anyval_pairs.tps @@ -1,7 +1,7 @@ create or replace type ut_key_anyval_pairs as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_key_anyvalues.tpb b/source/expectations/data_values/ut_key_anyvalues.tpb index 93bf1eb53..d30d8a841 100644 --- a/source/expectations/data_values/ut_key_anyvalues.tpb +++ b/source/expectations/data_values/ut_key_anyvalues.tpb @@ -1,7 +1,7 @@ create or replace type body ut_key_anyvalues as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_key_anyvalues.tps b/source/expectations/data_values/ut_key_anyvalues.tps index 6dd32a76d..8c672bd00 100644 --- a/source/expectations/data_values/ut_key_anyvalues.tps +++ b/source/expectations/data_values/ut_key_anyvalues.tps @@ -1,7 +1,7 @@ create or replace type ut_key_anyvalues under ut_event_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_between.tpb b/source/expectations/matchers/ut_be_between.tpb index 7368ad5a7..6aea96f55 100644 --- a/source/expectations/matchers/ut_be_between.tpb +++ b/source/expectations/matchers/ut_be_between.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_between is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_between.tps b/source/expectations/matchers/ut_be_between.tps index 7e254719e..9e984085b 100644 --- a/source/expectations/matchers/ut_be_between.tps +++ b/source/expectations/matchers/ut_be_between.tps @@ -1,7 +1,7 @@ create or replace type ut_be_between under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_empty.tpb b/source/expectations/matchers/ut_be_empty.tpb index 08523fb02..e5e02f6b2 100644 --- a/source/expectations/matchers/ut_be_empty.tpb +++ b/source/expectations/matchers/ut_be_empty.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_empty as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_empty.tps b/source/expectations/matchers/ut_be_empty.tps index 76af402fe..9e9f899d0 100644 --- a/source/expectations/matchers/ut_be_empty.tps +++ b/source/expectations/matchers/ut_be_empty.tps @@ -1,7 +1,7 @@ create or replace type ut_be_empty under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_false.tpb b/source/expectations/matchers/ut_be_false.tpb index 671f43cbe..4cc88600a 100644 --- a/source/expectations/matchers/ut_be_false.tpb +++ b/source/expectations/matchers/ut_be_false.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_false as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_false.tps b/source/expectations/matchers/ut_be_false.tps index 3d4e8dda9..ede510719 100644 --- a/source/expectations/matchers/ut_be_false.tps +++ b/source/expectations/matchers/ut_be_false.tps @@ -1,7 +1,7 @@ create or replace type ut_be_false under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_greater_or_equal.tpb b/source/expectations/matchers/ut_be_greater_or_equal.tpb index 6877eb32c..1c2a19c09 100644 --- a/source/expectations/matchers/ut_be_greater_or_equal.tpb +++ b/source/expectations/matchers/ut_be_greater_or_equal.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_greater_or_equal AS /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_greater_or_equal.tps b/source/expectations/matchers/ut_be_greater_or_equal.tps index facd33b3d..b3ab54ff1 100644 --- a/source/expectations/matchers/ut_be_greater_or_equal.tps +++ b/source/expectations/matchers/ut_be_greater_or_equal.tps @@ -1,7 +1,7 @@ create or replace type ut_be_greater_or_equal under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_greater_than.tpb b/source/expectations/matchers/ut_be_greater_than.tpb index da46347af..9cce79119 100644 --- a/source/expectations/matchers/ut_be_greater_than.tpb +++ b/source/expectations/matchers/ut_be_greater_than.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_greater_than AS /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_greater_than.tps b/source/expectations/matchers/ut_be_greater_than.tps index fa19a9bd4..a5a44692d 100644 --- a/source/expectations/matchers/ut_be_greater_than.tps +++ b/source/expectations/matchers/ut_be_greater_than.tps @@ -1,7 +1,7 @@ create or replace type ut_be_greater_than under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_less_or_equal.tpb b/source/expectations/matchers/ut_be_less_or_equal.tpb index 98c4238eb..6acec1dda 100644 --- a/source/expectations/matchers/ut_be_less_or_equal.tpb +++ b/source/expectations/matchers/ut_be_less_or_equal.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_less_or_equal AS /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_less_or_equal.tps b/source/expectations/matchers/ut_be_less_or_equal.tps index 225c99b72..118611a41 100644 --- a/source/expectations/matchers/ut_be_less_or_equal.tps +++ b/source/expectations/matchers/ut_be_less_or_equal.tps @@ -1,7 +1,7 @@ create or replace type ut_be_less_or_equal under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_less_than.tpb b/source/expectations/matchers/ut_be_less_than.tpb index e1c5c84b1..7608e4917 100644 --- a/source/expectations/matchers/ut_be_less_than.tpb +++ b/source/expectations/matchers/ut_be_less_than.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_less_than as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_less_than.tps b/source/expectations/matchers/ut_be_less_than.tps index 8482f0327..b652de789 100644 --- a/source/expectations/matchers/ut_be_less_than.tps +++ b/source/expectations/matchers/ut_be_less_than.tps @@ -1,7 +1,7 @@ create or replace type ut_be_less_than under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_like.tpb b/source/expectations/matchers/ut_be_like.tpb index dbcd1c798..6865c2942 100644 --- a/source/expectations/matchers/ut_be_like.tpb +++ b/source/expectations/matchers/ut_be_like.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_like as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_like.tps b/source/expectations/matchers/ut_be_like.tps index 0c1609a98..dae93a1d9 100644 --- a/source/expectations/matchers/ut_be_like.tps +++ b/source/expectations/matchers/ut_be_like.tps @@ -1,7 +1,7 @@ create or replace type ut_be_like under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_not_null.tpb b/source/expectations/matchers/ut_be_not_null.tpb index 94ee0ce0a..194e2ea32 100644 --- a/source/expectations/matchers/ut_be_not_null.tpb +++ b/source/expectations/matchers/ut_be_not_null.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_not_null as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_not_null.tps b/source/expectations/matchers/ut_be_not_null.tps index 34cc2bfd0..196aac9fb 100644 --- a/source/expectations/matchers/ut_be_not_null.tps +++ b/source/expectations/matchers/ut_be_not_null.tps @@ -1,7 +1,7 @@ create or replace type ut_be_not_null under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_null.tpb b/source/expectations/matchers/ut_be_null.tpb index 3194f092f..8c672791b 100644 --- a/source/expectations/matchers/ut_be_null.tpb +++ b/source/expectations/matchers/ut_be_null.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_null as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_null.tps b/source/expectations/matchers/ut_be_null.tps index 486e11f28..3b2d6ac84 100644 --- a/source/expectations/matchers/ut_be_null.tps +++ b/source/expectations/matchers/ut_be_null.tps @@ -1,7 +1,7 @@ create or replace type ut_be_null under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_true.tpb b/source/expectations/matchers/ut_be_true.tpb index 565ab590b..fe78b4e22 100644 --- a/source/expectations/matchers/ut_be_true.tpb +++ b/source/expectations/matchers/ut_be_true.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_true as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_true.tps b/source/expectations/matchers/ut_be_true.tps index b994913f5..8b5491e39 100644 --- a/source/expectations/matchers/ut_be_true.tps +++ b/source/expectations/matchers/ut_be_true.tps @@ -1,7 +1,7 @@ create or replace type ut_be_true under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_comparison_matcher.tpb b/source/expectations/matchers/ut_comparison_matcher.tpb index 50f8d6050..20ed35927 100644 --- a/source/expectations/matchers/ut_comparison_matcher.tpb +++ b/source/expectations/matchers/ut_comparison_matcher.tpb @@ -1,7 +1,7 @@ create or replace type body ut_comparison_matcher as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_comparison_matcher.tps b/source/expectations/matchers/ut_comparison_matcher.tps index 76520a296..68ecb4462 100644 --- a/source/expectations/matchers/ut_comparison_matcher.tps +++ b/source/expectations/matchers/ut_comparison_matcher.tps @@ -1,7 +1,7 @@ create or replace type ut_comparison_matcher under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_contain.tpb b/source/expectations/matchers/ut_contain.tpb index c0c4f481a..7591925f5 100644 --- a/source/expectations/matchers/ut_contain.tpb +++ b/source/expectations/matchers/ut_contain.tpb @@ -1,7 +1,7 @@ create or replace type body ut_contain as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_contain.tps b/source/expectations/matchers/ut_contain.tps index 518352573..e572edf62 100644 --- a/source/expectations/matchers/ut_contain.tps +++ b/source/expectations/matchers/ut_contain.tps @@ -1,7 +1,7 @@ create or replace type ut_contain under ut_equal( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_equal.tpb b/source/expectations/matchers/ut_equal.tpb index afa2148f3..05caf3b09 100644 --- a/source/expectations/matchers/ut_equal.tpb +++ b/source/expectations/matchers/ut_equal.tpb @@ -1,7 +1,7 @@ create or replace type body ut_equal as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_equal.tps b/source/expectations/matchers/ut_equal.tps index 1f42324d7..eecbe8c1d 100644 --- a/source/expectations/matchers/ut_equal.tps +++ b/source/expectations/matchers/ut_equal.tps @@ -1,7 +1,7 @@ create or replace type ut_equal force under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_have_count.tpb b/source/expectations/matchers/ut_have_count.tpb index b0f4e06d4..457cd6272 100644 --- a/source/expectations/matchers/ut_have_count.tpb +++ b/source/expectations/matchers/ut_have_count.tpb @@ -1,7 +1,7 @@ create or replace type body ut_have_count as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_have_count.tps b/source/expectations/matchers/ut_have_count.tps index fb0fc76fc..d48dc44c8 100644 --- a/source/expectations/matchers/ut_have_count.tps +++ b/source/expectations/matchers/ut_have_count.tps @@ -1,7 +1,7 @@ create or replace type ut_have_count under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_match.tpb b/source/expectations/matchers/ut_match.tpb index 57fabbaec..3c7a71402 100644 --- a/source/expectations/matchers/ut_match.tpb +++ b/source/expectations/matchers/ut_match.tpb @@ -1,7 +1,7 @@ create or replace type body ut_match as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_match.tps b/source/expectations/matchers/ut_match.tps index 8d6b0f73a..ee51a4c28 100644 --- a/source/expectations/matchers/ut_match.tps +++ b/source/expectations/matchers/ut_match.tps @@ -1,7 +1,7 @@ create or replace type ut_match under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher.tpb b/source/expectations/matchers/ut_matcher.tpb index 11ff1b6b6..c64b6d246 100644 --- a/source/expectations/matchers/ut_matcher.tpb +++ b/source/expectations/matchers/ut_matcher.tpb @@ -1,7 +1,7 @@ create or replace type body ut_matcher as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher.tps b/source/expectations/matchers/ut_matcher.tps index 34e1742df..ba8bb7e85 100644 --- a/source/expectations/matchers/ut_matcher.tps +++ b/source/expectations/matchers/ut_matcher.tps @@ -1,7 +1,7 @@ create or replace type ut_matcher authid current_user as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher_options.tpb b/source/expectations/matchers/ut_matcher_options.tpb index 6fec3dee6..8730c204b 100644 --- a/source/expectations/matchers/ut_matcher_options.tpb +++ b/source/expectations/matchers/ut_matcher_options.tpb @@ -1,7 +1,7 @@ create or replace type body ut_matcher_options as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher_options.tps b/source/expectations/matchers/ut_matcher_options.tps index dbdf985f0..276cad2ec 100644 --- a/source/expectations/matchers/ut_matcher_options.tps +++ b/source/expectations/matchers/ut_matcher_options.tps @@ -1,7 +1,7 @@ create or replace type ut_matcher_options authid current_user as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher_options_items.tpb b/source/expectations/matchers/ut_matcher_options_items.tpb index 2c3f51d34..92da588ce 100644 --- a/source/expectations/matchers/ut_matcher_options_items.tpb +++ b/source/expectations/matchers/ut_matcher_options_items.tpb @@ -1,7 +1,7 @@ create or replace type body ut_matcher_options_items is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher_options_items.tps b/source/expectations/matchers/ut_matcher_options_items.tps index cc74650f3..53787070d 100644 --- a/source/expectations/matchers/ut_matcher_options_items.tps +++ b/source/expectations/matchers/ut_matcher_options_items.tps @@ -1,7 +1,7 @@ create or replace type ut_matcher_options_items authid current_user as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index d8ed1f79a..dfad630a6 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -1,7 +1,7 @@ create or replace type body ut_expectation as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index 37fefd085..45d768200 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation authid current_user as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index 5e7268bd9..9dfd78e3e 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -1,7 +1,7 @@ create or replace type body ut_expectation_compound as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index fc413e3fd..ab320cae0 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation_compound force under ut_expectation( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation_json.tpb b/source/expectations/ut_expectation_json.tpb index 49c0c2e1f..b71e8ea83 100644 --- a/source/expectations/ut_expectation_json.tpb +++ b/source/expectations/ut_expectation_json.tpb @@ -1,7 +1,7 @@ create or replace type body ut_expectation_json as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation_json.tps b/source/expectations/ut_expectation_json.tps index dd3aa5b25..f33c6a580 100644 --- a/source/expectations/ut_expectation_json.tps +++ b/source/expectations/ut_expectation_json.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation_json under ut_expectation( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install.sql b/source/install.sql index 3249e3e49..f7df12b39 100644 --- a/source/install.sql +++ b/source/install.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install_component.sql b/source/install_component.sql index 857c1771c..373c85c54 100644 --- a/source/install_component.sql +++ b/source/install_component.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install_ddl_trigger.sql b/source/install_ddl_trigger.sql index 843ee0c07..bc147c2be 100644 --- a/source/install_ddl_trigger.sql +++ b/source/install_ddl_trigger.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install_headless.sql b/source/install_headless.sql index e8cf00705..183262675 100644 --- a/source/install_headless.sql +++ b/source/install_headless.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install_headless_with_trigger.sql b/source/install_headless_with_trigger.sql index 16d81f3c6..76ae48ccb 100644 --- a/source/install_headless_with_trigger.sql +++ b/source/install_headless_with_trigger.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_ansiconsole_helper.pkb b/source/reporters/ut_ansiconsole_helper.pkb index b015e50be..53e6bc6aa 100644 --- a/source/reporters/ut_ansiconsole_helper.pkb +++ b/source/reporters/ut_ansiconsole_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_ansiconsole_helper as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_ansiconsole_helper.pks b/source/reporters/ut_ansiconsole_helper.pks index 7c83ca73b..217d36a49 100644 --- a/source/reporters/ut_ansiconsole_helper.pks +++ b/source/reporters/ut_ansiconsole_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_ansiconsole_helper as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index d8aae7f7a..0c3857b7e 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_cobertura_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_cobertura_reporter.tps b/source/reporters/ut_coverage_cobertura_reporter.tps index ec5cef2cb..1292e60fb 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tps +++ b/source/reporters/ut_coverage_cobertura_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_cobertura_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_html_reporter.tpb b/source/reporters/ut_coverage_html_reporter.tpb index 9e51b5cc2..c88c91a80 100644 --- a/source/reporters/ut_coverage_html_reporter.tpb +++ b/source/reporters/ut_coverage_html_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_html_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_html_reporter.tps b/source/reporters/ut_coverage_html_reporter.tps index f6bdcc249..42f2fd4e3 100644 --- a/source/reporters/ut_coverage_html_reporter.tps +++ b/source/reporters/ut_coverage_html_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_html_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index f4b633c1f..2bb9a87d9 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_report_html_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_report_html_helper.pks b/source/reporters/ut_coverage_report_html_helper.pks index 48dd76acf..42a59c123 100644 --- a/source/reporters/ut_coverage_report_html_helper.pks +++ b/source/reporters/ut_coverage_report_html_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_report_html_helper authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_sonar_reporter.tpb b/source/reporters/ut_coverage_sonar_reporter.tpb index 68f4a7989..4bde1a88d 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tpb +++ b/source/reporters/ut_coverage_sonar_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_sonar_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_sonar_reporter.tps b/source/reporters/ut_coverage_sonar_reporter.tps index aa21cafe3..f3076368f 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tps +++ b/source/reporters/ut_coverage_sonar_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_sonar_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coveralls_reporter.tpb b/source/reporters/ut_coveralls_reporter.tpb index f2cb73abe..3a54aa7f7 100644 --- a/source/reporters/ut_coveralls_reporter.tpb +++ b/source/reporters/ut_coveralls_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coveralls_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coveralls_reporter.tps b/source/reporters/ut_coveralls_reporter.tps index 53e86338e..f3cad3a4e 100644 --- a/source/reporters/ut_coveralls_reporter.tps +++ b/source/reporters/ut_coveralls_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_coveralls_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_debug_reporter.tpb b/source/reporters/ut_debug_reporter.tpb index 5f457bb79..879725172 100644 --- a/source/reporters/ut_debug_reporter.tpb +++ b/source/reporters/ut_debug_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_debug_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_debug_reporter.tps b/source/reporters/ut_debug_reporter.tps index 5fbab61fb..2123f19cc 100644 --- a/source/reporters/ut_debug_reporter.tps +++ b/source/reporters/ut_debug_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_debug_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_documentation_reporter.tpb b/source/reporters/ut_documentation_reporter.tpb index 7210e1cb6..8b92d447f 100644 --- a/source/reporters/ut_documentation_reporter.tpb +++ b/source/reporters/ut_documentation_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_documentation_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_documentation_reporter.tps b/source/reporters/ut_documentation_reporter.tps index 08097e7d4..422225117 100644 --- a/source/reporters/ut_documentation_reporter.tps +++ b/source/reporters/ut_documentation_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_documentation_reporter under ut_console_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_junit_reporter.tpb b/source/reporters/ut_junit_reporter.tpb index aa6786f6f..94ea5c5e6 100644 --- a/source/reporters/ut_junit_reporter.tpb +++ b/source/reporters/ut_junit_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_junit_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_junit_reporter.tps b/source/reporters/ut_junit_reporter.tps index ca6cf505b..6cdaff1b9 100644 --- a/source/reporters/ut_junit_reporter.tps +++ b/source/reporters/ut_junit_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_junit_reporter force under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_realtime_reporter.tpb b/source/reporters/ut_realtime_reporter.tpb index 443c7c4e7..837643b0b 100644 --- a/source/reporters/ut_realtime_reporter.tpb +++ b/source/reporters/ut_realtime_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_realtime_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_realtime_reporter.tps b/source/reporters/ut_realtime_reporter.tps index 99efed387..0501006e4 100644 --- a/source/reporters/ut_realtime_reporter.tps +++ b/source/reporters/ut_realtime_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_realtime_reporter force under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_sonar_test_reporter.tpb b/source/reporters/ut_sonar_test_reporter.tpb index 6d76b5d41..8b043832a 100644 --- a/source/reporters/ut_sonar_test_reporter.tpb +++ b/source/reporters/ut_sonar_test_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_sonar_test_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_sonar_test_reporter.tps b/source/reporters/ut_sonar_test_reporter.tps index 8bdb067df..ac3b16bd1 100644 --- a/source/reporters/ut_sonar_test_reporter.tps +++ b/source/reporters/ut_sonar_test_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_sonar_test_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_teamcity_reporter.tpb b/source/reporters/ut_teamcity_reporter.tpb index 9475c0a90..3e1a4bcf8 100644 --- a/source/reporters/ut_teamcity_reporter.tpb +++ b/source/reporters/ut_teamcity_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_teamcity_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_teamcity_reporter.tps b/source/reporters/ut_teamcity_reporter.tps index 2738ec00e..e03fa3643 100644 --- a/source/reporters/ut_teamcity_reporter.tps +++ b/source/reporters/ut_teamcity_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_teamcity_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_teamcity_reporter_helper.pkb b/source/reporters/ut_teamcity_reporter_helper.pkb index 2d165d7a3..3a4679cb4 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pkb +++ b/source/reporters/ut_teamcity_reporter_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_teamcity_reporter_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_teamcity_reporter_helper.pks b/source/reporters/ut_teamcity_reporter_helper.pks index 7258999e1..d94099411 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pks +++ b/source/reporters/ut_teamcity_reporter_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_teamcity_reporter_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_tfs_junit_reporter.tpb b/source/reporters/ut_tfs_junit_reporter.tpb index 5262ac687..e14af1d4d 100644 --- a/source/reporters/ut_tfs_junit_reporter.tpb +++ b/source/reporters/ut_tfs_junit_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_tfs_junit_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_tfs_junit_reporter.tps b/source/reporters/ut_tfs_junit_reporter.tps index ecf422bd3..61cbc3fd8 100644 --- a/source/reporters/ut_tfs_junit_reporter.tps +++ b/source/reporters/ut_tfs_junit_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_tfs_junit_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_xunit_reporter.tpb b/source/reporters/ut_xunit_reporter.tpb index b06c20810..eab0c8a3c 100644 --- a/source/reporters/ut_xunit_reporter.tpb +++ b/source/reporters/ut_xunit_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_xunit_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_xunit_reporter.tps b/source/reporters/ut_xunit_reporter.tps index b09205171..6c530fee4 100644 --- a/source/reporters/ut_xunit_reporter.tps +++ b/source/reporters/ut_xunit_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_xunit_reporter under ut_junit_reporter( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/set_install_params.sql b/source/set_install_params.sql index 4dc33c367..34a23dc93 100644 --- a/source/set_install_params.sql +++ b/source/set_install_params.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/uninstall.sql b/source/uninstall.sql index 760bf89b7..ced7b8dc4 100644 --- a/source/uninstall.sql +++ b/source/uninstall.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/uninstall_all.sql b/source/uninstall_all.sql index 32180d762..cfaaaa29f 100644 --- a/source/uninstall_all.sql +++ b/source/uninstall_all.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2021 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. From 000aeabab0072ab1d4584ef1661146e12f51e312 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Mon, 15 Nov 2021 18:53:23 +0000 Subject: [PATCH 155/887] Updated project version after build [skip ci] --- VERSION | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 21 files changed, 21 insertions(+), 21 deletions(-) diff --git a/VERSION b/VERSION index 571f2ad11..021c7c624 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.11-develop +v3.1.11 diff --git a/docs/about/authors.md b/docs/about/authors.md index cd16c82b6..6575abbec 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 7758a2190..772fa553f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index f0304acf9..4f4f34f1a 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index ed6c34fe8..15906a35b 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 57a29707b..7654a2e01 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index a5331ff2e..557dc2d9c 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index b760cb1b1..443c7ae21 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index bf7189d10..c0fa4ee10 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 814733301..40aacae39 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 71113a1d6..0794f4ca7 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3bc60effb..1da384c1d 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8a14cd767..c1233c258 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 144b4a835..f9af73346 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 79942bb30..e280a3187 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ebb32163d..ac00118db 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 0dee54b06..c2c1f6a33 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 6f6af8798..7e21cbd27 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index ddd794a91..6220e0b90 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -2,7 +2,7 @@ sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.11-develop +sonar.projectVersion=v3.1.11 # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 7c0daf878..b5951a905 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3549-develop + * secion v3.1.11.3550 */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f8dcc19ab..6e5f149eb 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3549-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3550'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 581991b4127445f1846cc89823329f3c3309c396 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 15 Nov 2021 21:39:13 +0200 Subject: [PATCH 156/887] Fixed failing tests and improved coverage reporting --- source/reporters/ut_coverage_cobertura_reporter.tpb | 6 +++--- .../reporters/test_coverage/test_cov_cobertura_reporter.pkb | 2 +- .../reporters/test_coverage/test_coverage_standalone.pkb | 2 +- .../reporters/test_coverage/test_proftab_coverage.pkb | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index e34bca79b..8ee6dd31a 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -82,7 +82,7 @@ create or replace type body ut_coverage_cobertura_reporter is c_classes_footer constant varchar2(30) := ''; c_lines_footer constant varchar2(30) := ''; l_epoch varchar2(50) := (sysdate - to_date('01-01-1970 00:00:00', 'dd-mm-yyyy hh24:mi:ss')) * 24 * 60 * 60; - l_lines_valid number := a_coverage_data.covered_lines + a_coverage_data.uncovered_lines; + l_lines_valid integer := a_coverage_data.covered_lines + a_coverage_data.uncovered_lines; begin ut_utils.append_to_list( l_result, ut_utils.get_xml_header(a_run.client_character_set) ); @@ -92,10 +92,10 @@ create or replace type body ut_coverage_cobertura_reporter is ut_utils.append_to_list( l_result, '' ); diff --git a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb index a18409463..2c36f37ba 100644 --- a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ -20,7 +20,7 @@ create or replace package body test_cov_cobertura_reporter is l_expected := q'[ - + ]'||l_file_path||q'[ diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index d94108a32..e5706f885 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -15,7 +15,7 @@ create or replace package body test_coverage_standalone is l_expected := q'[ - + ]'||l_file_path||q'[ diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index 81a9a4c58..7256fc202 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -164,7 +164,7 @@ create or replace package body test_proftab_coverage is l_expected := q'[ - + package body ut3_develop.{p} From ad5faa8ca06f3e81ce21708fdfb44ff35e6057b6 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Mon, 15 Nov 2021 20:25:41 +0000 Subject: [PATCH 157/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index cd16c82b6..bbfd22348 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 7758a2190..3568a0c9d 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index f0304acf9..4dd55a8ba 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index ed6c34fe8..e396c4ebc 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 57a29707b..1a1b91e1d 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index a5331ff2e..1be56953d 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index b760cb1b1..a4aad38a5 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index bf7189d10..d7b1d29af 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 814733301..78e7131d3 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 71113a1d6..fa6ab38d2 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3bc60effb..0ae2bd9c7 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8a14cd767..80c96a78b 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 144b4a835..04cc5e7db 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 79942bb30..2de932893 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ebb32163d..c7185af3e 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 0dee54b06..74b185f1e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 6f6af8798..ae0dee73a 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3549--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 4e0bafe7c..fd53b50ce 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3549-develop + * secion v3.1.11.3553-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 35aff2929..ff443849b 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3549-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3553-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From fae53a4c2f9a9e183b63197f7f73bb13406bdb47 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 16 Nov 2021 11:41:59 +0200 Subject: [PATCH 158/887] Removed duplicate profiler table installation. Resolves #1149 --- source/install.sql | 3 --- 1 file changed, 3 deletions(-) diff --git a/source/install.sql b/source/install.sql index 3249e3e49..42d37ac9f 100644 --- a/source/install.sql +++ b/source/install.sql @@ -165,9 +165,6 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex prompt Installing PLSQL profiler objects into &&ut3_owner schema @@core/coverage/proftab.sql -prompt Installing PLSQL profiler objects into &&ut3_owner schema -@@core/coverage/proftab.sql - prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@core/coverage/dbms_plssqlcode.sql From f841ecf9ebbd19286a7bc276f33b4774f091e95e Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 16 Nov 2021 10:17:44 +0000 Subject: [PATCH 159/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index bbfd22348..fd7f57822 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 3568a0c9d..b3838b1fb 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 4dd55a8ba..9dfa29abe 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index e396c4ebc..4ee320a9f 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 1a1b91e1d..300177ae2 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 1be56953d..6767f0735 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index a4aad38a5..94ac10f67 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index d7b1d29af..b2b4ab9f3 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 78e7131d3..a5e34b45d 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index fa6ab38d2..7bec5c32d 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0ae2bd9c7..7b17dfdc8 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 80c96a78b..9dbe473ec 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 04cc5e7db..e26b9046f 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 2de932893..a4334834c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index c7185af3e..77d3f24ff 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 74b185f1e..4832681e7 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index ae0dee73a..9dc6968cc 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3553--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3556--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index fd53b50ce..58c137e65 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3553-develop + * secion v3.1.11.3556-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index ff443849b..1562be8a1 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3553-develop'; + gc_version constant varchar2(50) := 'v3.1.11.3556-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 5eaefd36b32de62bbc3649e9e205cbf8931d4cff Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 16 Nov 2021 22:40:32 +0000 Subject: [PATCH 160/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 6575abbec..d03e93575 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 772fa553f..41f07a7a7 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 4f4f34f1a..63db76bbb 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 15906a35b..1e07adab3 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 7654a2e01..6940d4b94 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 557dc2d9c..a9dec00dd 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 443c7ae21..ee3033da8 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index c0fa4ee10..b75ef1413 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 40aacae39..e0935b2ea 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 0794f4ca7..ce2264fcf 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 1da384c1d..4fcb47322 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c1233c258..f2acf0e02 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index f9af73346..743858b2f 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index e280a3187..8ab8efc4d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ac00118db..2c41bd54b 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c2c1f6a33..acda0fea7 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 7e21cbd27..af5e2d585 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3550-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index b5951a905..f76a2668d 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3550 + * secion v3.1.11.3557 */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6e5f149eb..a2c3bb4d7 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3550'; + gc_version constant varchar2(50) := 'v3.1.11.3557'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 158c9853660edc75abecfdf1673088d5a3636dea Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 18 Nov 2021 00:21:06 +0000 Subject: [PATCH 161/887] Updated project version after build [skip ci] --- VERSION | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 21 files changed, 21 insertions(+), 21 deletions(-) diff --git a/VERSION b/VERSION index 021c7c624..571f2ad11 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.11 +v3.1.11-develop diff --git a/docs/about/authors.md b/docs/about/authors.md index d03e93575..b80140085 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 41f07a7a7..95ddbd696 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 63db76bbb..ce19bb28f 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 1e07adab3..1044fb383 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 6940d4b94..2ba06cd92 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index a9dec00dd..06ea7759b 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index ee3033da8..bdad4fadc 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b75ef1413..b02209ba5 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index e0935b2ea..fbc50e2e3 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index ce2264fcf..25fdb2d3c 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 4fcb47322..b36dff50d 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index f2acf0e02..536c837b2 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 743858b2f..5cd5ba241 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 8ab8efc4d..a581458b3 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 2c41bd54b..2109b10e1 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index acda0fea7..cb8714f7d 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index af5e2d585..dcdc7217e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3557-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index 6220e0b90..ddd794a91 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -2,7 +2,7 @@ sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.11 +sonar.projectVersion=v3.1.11-develop # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index f76a2668d..b50fb4d95 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3557 + * secion v3.1.11.3561-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index a2c3bb4d7..0038c46f1 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3557'; + gc_version constant varchar2(50) := 'v3.1.11.3561-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 3d25924712d1a82475ee3a58537abf69518f0aee Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 18 Nov 2021 02:23:21 +0200 Subject: [PATCH 162/887] Updated version to 3.1.12 --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 571f2ad11..8ecb8bfc6 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.11-develop +v3.1.12 From bb1e9b3518ab2ce9519eb33a679c01e9d4562721 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 18 Nov 2021 00:43:01 +0000 Subject: [PATCH 163/887] Updated project version after build [skip ci] --- VERSION | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 21 files changed, 21 insertions(+), 21 deletions(-) diff --git a/VERSION b/VERSION index 8ecb8bfc6..a0d004aa2 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.12 +v3.1.12-develop diff --git a/docs/about/authors.md b/docs/about/authors.md index b80140085..34b6dc228 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 95ddbd696..1d85c978a 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index ce19bb28f..e166099de 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 1044fb383..5ad87fc66 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 2ba06cd92..0815fafac 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 06ea7759b..6117b8fb5 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index bdad4fadc..f5f5c9d06 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b02209ba5..3fac28b94 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index fbc50e2e3..e89ad4562 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 25fdb2d3c..5c78ada34 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b36dff50d..3bce1033f 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 536c837b2..4ab0c3904 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 5cd5ba241..227e7c22a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index a581458b3..81e53b98b 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 2109b10e1..18e5e307e 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index cb8714f7d..5bb5b7d6d 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index dcdc7217e..af4ef241e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.11.3561--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index ddd794a91..d81d0a2b2 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -2,7 +2,7 @@ sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.11-develop +sonar.projectVersion=v3.1.12-develop # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index b50fb4d95..cf189e768 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.11.3561-develop + * secion v3.1.12.3562-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 0038c46f1..49e81558e 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.11.3561-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3562-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 0354c1a009f78df774b5c264c297eee4aa4f2d71 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 24 Nov 2021 23:15:02 +0200 Subject: [PATCH 164/887] First attempt at running as github actions --- .github/workflows/build.yml | 122 ++++++++++++++++++++++++++++++++++ .travis/download.js | 56 ---------------- .travis/download.sh | 72 -------------------- .travis.yml => old.travis.yml | 0 4 files changed, 122 insertions(+), 128 deletions(-) create mode 100644 .github/workflows/build.yml delete mode 100644 .travis/download.js delete mode 100755 .travis/download.sh rename .travis.yml => old.travis.yml (100%) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 000000000..d3f4f0f4f --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,122 @@ +name: Deploy and test +env: + UT3_DEVELOP_SCHEMA: UT3_DEVELOP + UT3_DEVELOP_SCHEMA_PASSWORD: ut3 + UT3_RELEASE_VERSION_SCHEMA: UT3 + UT3_RELEASE_VERSION_SCHEMA_PASSWORD: ut3 + UT3_USER: 'UT3\$USER#' + UT3_USER_PASSWORD: ut3 + UT3_TESTER: UT3_TESTER + UT3_TESTER_PASSWORD: ut3 + UT3_TESTER_HELPER: UT3_TESTER_HELPER + UT3_TESTER_HELPER_PASSWORD: ut3 + UT3_TABLESPACE: users + BUILD_DIR: ${{env.GITHUB_WORKSPACE}} + JOB_ID: ${{env.GITHUB_RUN_ID}} + JOB_NUMBER: ${{env.GITHUB_RUN_NUMBER}} + PULL_REQUEST_NAME: ${env.GITHUB_HEAD_REF} + PULL_REQUEST_BRANCH: ${{env.GITHUB_HEAD_REF}} + TAG_NAME: ${TRAVIS_TAG} + REPO_SLUG: ${TRAVIS_REPO_SLUG} + PR_SLUG: ${{env.GITHUB_REPOSITORY}} + BRANCH_NAME: ${TRAVIS_BRANCH} + # Environment for building a release + CURRENT_BRANCH: ${TRAVIS_BRANCH} + UTPLSQL_REPO: "utPLSQL/utPLSQL" + UTPLSQL_BUILD_NO: ${{env.GITHUB_RUN_ID}} + UTPLSQL_VERSION: $(. .travis/get_project_version.sh) + UTPLSQL_BUILD_VERSION: $(. .travis/get_project_build_version.sh) + UTPLSQL_SOURCES_DIR: 'source' + UTPLSQL_BUILD_USER_NAME: "Travis CI" + CACHE_DIR: $HOME/.cache + # Database Env + SQLCLI: "${BUILD_DIR}/sqlcl/bin/sql" + OJDBC_HOME: "${BUILD_DIR}/ojdbc" + ORACLE_PWD: "oracle" + DOCKHER_HUB_REPO: "utplsqlv3/oracledb" + DOCKER_VOLUME: "/home/oracle/host" + DOCKER_ENV: "-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" + #utPLSQL released version directory + UTPLSQL_DIR: "utPLSQL_latest_release" + SELFTESTING_BRANCH: ${TRAVIS_BRANCH} + UTPLSQL_CLI_VERSION: "3.1.8" + # Maven + MAVEN_HOME: /usr/local/maven + MAVEN_CFG: $HOME/.m2 + +on: + push: + branches: [ develop, feature/github_actions ] + pull_request: + branches: [ develop ] + + workflow_dispatch: + +jobs: + build: + + env: + UTPLSQL_VERSION: ${{matrix.utplsql-version}} + + runs-on: ubuntu-latest + strategy: + matrix: + include: + - oracle-version: "gvenzl/oracle-xe:11-slim" + connection-str: '127.0.0.1:1521/XE' +# docker-options: '--shm-size=1g' +# - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' +# - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' + - oracle-version: "gvenzl/oracle-xe:18-slim" + connection-str: '127.0.0.1:1521/XE' + docker-options: '-e ORACLE_PASSWORD=oracle' +# - oracle-version: "utplsqlv3/oracledb:18c-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' +# - oracle-version: "utplsqlv3/oracledb:19c-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' + - oracle-version: "gvenzl/oracle-xe:21-full" + connection-str: '127.0.0.1:1521/XE' + docker-options: '-e ORACLE_PASSWORD=oracle' + + services: + oracle: + image: ${matrix.oracle-version} + env: + CONNECTION_STR: ${matrix.connection-str} + ORACLE_PASSWORD: oracle + ports: + - 1521:1521 + options: >- + --health-cmd healthcheck.sh + --health-interval 10s + --health-timeout 5s + --health-retries 10 + ${matrix.docker-options} + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + + - name: Install utPLSQL ${{matrix.utplsql-version}} + run: echo Installing ${UTPLSQL_VERSION} && sh ${{ github.workspace }}/scripts/1_install_utplsql.sh + + - name: Install utPLSQL-cli + run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli + + - name: Install demo project + run: sh ${{ github.workspace }}/scripts/2_install_demo_project.sh + + - name: Install unit tests + run: sh ${{ github.workspace }}/scripts/3_install_tests.sh + + - name: Run unit tests + run: sh ${{ github.workspace }}/scripts/4_run_tests.sh + + - name: SonarCloud Scan + uses: SonarSource/sonarcloud-github-action@master + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} diff --git a/.travis/download.js b/.travis/download.js deleted file mode 100644 index 67c45fac6..000000000 --- a/.travis/download.js +++ /dev/null @@ -1,56 +0,0 @@ - -var casper = require("casper").create({ - // verbose: true, - // logLevel: "debug", - pageSettings: { - loadImages: false, - loadPlugins: false - } -}); - -if (casper.cli.args.length < 4) { - casper.echo("Missing parameters: username password agreementUrl downloadUrl").exit(1); -} - -// Script parameters. -var paramUsername = casper.cli.get(0); -var paramPassword = casper.cli.get(1); -var agreementUrl = casper.cli.get(2); -var downloadUrl = casper.cli.get(3); -var downloaded = false; - -phantom.addCookie({ - 'name': 'oraclelicense', - 'value': '152021', - 'domain': 'oracle.com' - }); - -casper.start(); -// TODO: Error handling. - - -// Try to access the download page, wait for redirection and submit the login form. -casper.thenOpen(downloadUrl).waitForUrl(/signon\.jsp$/, function (re) { - //this.echo("Injecting Login Info"); - this.evaluate(function (username, password) { - document.getElementById("sso_username").value = username; - document.getElementById("ssopassword").value = password; - doLogin(document.LoginForm); - }, paramUsername, paramPassword); - // this.capture("Screenshot.png"); -}); - -casper.on("resource.received", function (resource) { - //this.echo("Received something: " + resource.url); - if (resource.url.indexOf("AuthParam") !== -1 && !downloaded) { - //this.echo("DownloadUrl:"); - // Print the download url. - this.echo(resource.url); - downloaded = true; - // TODO: Try to download file from here. this.download is not working because of cross site request. - } -}); - -casper.run(function () { - this.exit(); -}); diff --git a/.travis/download.sh b/.travis/download.sh deleted file mode 100755 index 8dfa1942d..000000000 --- a/.travis/download.sh +++ /dev/null @@ -1,72 +0,0 @@ -#!/bin/bash -set -e - -if [ "$ORACLE_OTN_USER" == "" ] || [ "$ORACLE_OTN_PASSWORD" == "" ]; then - echo "Error: Oracle OTN username/password not specified." - exit 1 -fi - -PRODUCT="" - -# Call the casperjs script to return the download url. -# Then download the file using curl. -downloadFile() { - downloadUrl=$(exec casperjs download.js $ORACLE_OTN_USER $ORACLE_OTN_PASSWORD $1 $2) - downloadUrl=${downloadUrl%$'\r'} - echo "DownloadURL: $downloadUrl" - curl -o $3 -L "$downloadUrl" -} - -############################# -########### START ########### -############################# - -while getopts "p:" OPTNAME; do - case "${OPTNAME}" in - "p") PRODUCT="${OPTARG}" ;; - esac -done - -if [ "$PRODUCT" == "se12c" ]; then - agreementUrl="http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html" - downloadUrl="http://download.oracle.com/otn/linux/oracle12c/121020/linuxamd64_12102_database_se2_1of2.zip" - outputFile=linuxamd64_12102_database_se2_1of2.zip - downloadFile $agreementUrl $downloadUrl $outputFile - agreementUrl="http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html" - downloadUrl="http://download.oracle.com/otn/linux/oracle12c/121020/linuxamd64_12102_database_se2_2of2.zip" - outputFile=linuxamd64_12102_database_se2_2of2.zip - downloadFile $agreementUrl $downloadUrl $outputFile - exit 0 -fi - -if [ "$PRODUCT" == "ee12c" ]; then - agreementUrl="http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html" - downloadUrl="http://download.oracle.com/otn/linux/oracle12c/121020/linuxamd64_12102_database_1of2.zip" - outputFile=linuxamd64_12102_database_1of2.zip - downloadFile $agreementUrl $downloadUrl $outputFile - agreementUrl="http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html" - DOWNLOAD_URL="http://download.oracle.com/otn/linux/oracle12c/121020/linuxamd64_12102_database_2of2.zip" - outputFile=linuxamd64_12102_database_2of2.zip - downloadFile $agreementUrl $downloadUrl $outputFile - exit 0 -fi - -if [ "$PRODUCT" == "xe11g" ]; then - agreementUrl="http://www.oracle.com/technetwork/database/database-technologies/express-edition/downloads/index.html" - downloadUrl="https://edelivery.oracle.com/akam/otn/linux/oracle11g/xe/oracle-xe-11.2.0-1.0.x86_64.rpm.zip" - outputFile=oracle-xe-11.2.0-1.0.x86_64.rpm.zip - downloadFile $agreementUrl $downloadUrl $outputFile - exit 0 -fi - -if [ "$PRODUCT" == "sqlcl" ]; then - agreementUrl="http://www.oracle.com/technetwork/developer-tools/sqlcl/downloads/index.html" - downloadUrl="https://download.oracle.com/otn/java/sqldeveloper/sqlcl-18.3.0.259.2029.zip" - #downloadUrl="https://download.oracle.com/otn/java/sqldeveloper/sqlcl-19.2.1.206.1649.zip" - outputFile=sqlcl-18.3.0.259.2029.zip - downloadFile $agreementUrl $downloadUrl $outputFile - exit 0 -fi - -echo "Error: invalid product: $PRODUCT" -exit 1 diff --git a/.travis.yml b/old.travis.yml similarity index 100% rename from .travis.yml rename to old.travis.yml From 99774b9af4d4a4d1167df3ad7f2f222810eb4533 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Kukie=C5=82a?= <53443372+kukimik@users.noreply.github.com> Date: Mon, 6 Dec 2021 16:40:17 +0100 Subject: [PATCH 165/887] Rewording of a note --- docs/userguide/advanced_data_comparison.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 6117b8fb5..d25411370 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -250,8 +250,9 @@ FAILURE at "anonymous block", line 15 ``` **Note** -> `join_by` matcher is much faster on performing data comparison, consider using `join_by` over unordered -> `contain` matcher is not considering order of compared data-sets. Using `unordered` makes no difference (it's default) +> Consider using `join_by( columns... )` over `unordered()` with the `equal` matcher. The `join_by` method is much faster at performing data comparison. +> +> The `contain` matcher is not considering the order of the compared data-sets. Using `unordered` makes no difference (it's default). ## Join By option From 66f29f4e6500d7e66014ca7f09434948afa9e790 Mon Sep 17 00:00:00 2001 From: kukimik Date: Wed, 22 Dec 2021 22:59:51 +0100 Subject: [PATCH 166/887] Minor typo, style, grammar fixes --- docs/userguide/expectations.md | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3bce1033f..0c45df2ea 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -24,7 +24,7 @@ Expectation is a combination of: - the expected value - optional custom message for the expectation - the matcher used to perform comparison -- them matcher parameters (actual value), depending on the matcher type +- the matcher parameters (actual value), depending on the matcher type Matcher defines the comparison operation to be performed on expected (and actual) value. @@ -88,7 +88,7 @@ There are two ways to use expectations: - without invoking the utPLSQL framework - running expectations standalone ## Running expectations within utPLSQL framework -When expectations are ran a part of test suite, the framework tracks: +When expectations are ran as a part of a test suite, the framework tracks: - status of each expectation - outcomes (messages) produced by each expectation - call stack to each expectation @@ -161,7 +161,7 @@ When expectations are invoked outside of utPLSQL framework the outputs from expe > Source code of the line which called the expectation is only reported when the line is part of in-database code (package) and the user calling expectation has privileges to see that source code. **Important** -> Please do not use expectations as part of your production code. They are not designed to be used as part ot your code. Expectations are meant to be used only as part of your day-to-day testing activities. +> Please do not use expectations as part of your production code. They are not designed to be used as part of your code. Expectations are meant to be used only as part of your day-to-day testing activities. **Note:** > The examples in the document will be only using standalone expectations, to keep the document brief. @@ -186,7 +186,7 @@ utPLSQL provides the following matchers to perform checks on the expected and ac - `match( a_patter {varchar2} [, a_modifiers {varchar2}] )` ## Providing a custom message -You can provide a custom failure message as second argument for the expectation by passing message as the second parameter to the expectation. +You can provide a custom failure message by passing it as the second parameter to the expectation. `ut.expect( a_actual {data-type}, a_message {varchar2} ).to_{matcher}` Example: @@ -386,7 +386,7 @@ For more details see documentation of the [`--%throws` annotation.](annotations. # Matchers -You can choose different matchers to validate the your PL/SQL code is working as expected. +You can choose different matchers to validate that your PL/SQL code is working as expected. ## be_between @@ -759,7 +759,7 @@ FAILURE ## have_count Unary matcher that validates if the provided dataset count is equal to expected value. -Can be used with `refcursor` , `json`or `table type` +Can be used with `refcursor`, `json` or `table type` Usage: ```sql @@ -827,8 +827,8 @@ FAILURE ``` ## equal -The equal matcher is very restrictive. Test using this matcher succeeds only when the compared data-types are exactly the same. -If you are comparing `varchar2` to a `number` will fail even if the text contains the same numeric value as the number. +The `equal` matcher is very restrictive. Test using this matcher succeeds only when the compared data-types are exactly the same. +If you are comparing a `varchar2` to a `number`, it will fail even if the text contains the same numeric value as the number. The matcher will also fail when comparing a `timestamp` to a `timestamp with timezone` data-type etc. The matcher enables detection of data-type changes. @@ -916,13 +916,13 @@ To change the behavior of `NULL = NULL` comparison pass the `a_nulls_are_equal = This matcher supports only compound data-types comparison. It check if the actual set contains all values of expected subset. -When comparing data using `contain` matcher, the data-types of columns for compared compound types must be exactly the same. +When comparing data using the `contain` matcher, the data-types of columns for compared compound types must be exactly the same. The matcher supports all advanced comparison options as `equal` like: `include` , `exclude`, `join_by` etc.. The matcher is successful when actual data set contains all of the values from expected results. -The matcher will cause a test to fail if actual data set does not contain any of expected values. +The matcher will cause a test to fail if actual data set does not contain some of expected values. ![included_set](../images/venn21.gif) @@ -1108,7 +1108,7 @@ utPLSQL is capable of comparing compound data-types including: - Columns in compound data are compared as **ordered list of elements** by default. Use `unordered_columns` option when order of columns in cursor is not relevant - Comparison of compound data is data-type aware. So a column `ID NUMBER` in a cursor is not the same as `ID VARCHAR2(100)`, even if they both hold the same numeric values. - Comparison of cursor columns containing `DATE` will only compare date part **and ignore time** by default. See [Comparing cursor data containing DATE fields](#comparing-cursor-data-containing-date-fields) to check how to enable date-time comparison in cursors. -- Comparison of cursor returning `TIMESTAMP` **columns** against cursor returning `TIMESTAMP` **bind variables** requires variables to be casted to proper precision. This is an Oracle SQL - PLSQL compatibility issue and usage of CAST is the only known workaround for now. See [Comparing cursor data containing TIMESTAMP bind variables](#comparing-cursor-data-containing-timestamp-bind-variables) for examples. +- Comparison of cursor returning `TIMESTAMP` **columns** against cursor returning `TIMESTAMP` **bind variables** requires variables to be cast to proper precision. This is an Oracle SQL - PLSQL compatibility issue and usage of CAST is the only known workaround for now. See [Comparing cursor data containing TIMESTAMP bind variables](#comparing-cursor-data-containing-timestamp-bind-variables) for examples. - To compare nested table/varray type you need to convert it to `anydata` by using `anydata.convertCollection()` - To compare object type you need to convert it to `anydata` by using `anydata.convertObject()` - It is possible to compare PL/SQL records, collections, varrays and associative arrays. To compare this types of data, use cursor comparison feature of utPLSQL and TABLE operator in SQL query @@ -1541,7 +1541,7 @@ drop table events; In the above example: - The first expectation is successful, as the `l_expected` cursor contains different date-time then the cursor returned by `get_events` function call -- The second expectation fails, as the column `event_date` will get compared as DATE without TIME (suing default current session NLS date format) +- The second expectation fails, as the column `event_date` will get compared as DATE without TIME (using default current session NLS date format) Output via DBMS_OUTPUT from the above example: ``` From 0bb6cdbd9752e464eb5448c7e4030a9a2deb846f Mon Sep 17 00:00:00 2001 From: kukimik Date: Tue, 4 Jan 2022 22:41:45 +0100 Subject: [PATCH 167/887] replace inactive Slack invitation link --- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- readme.md | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/about/project-details.md b/docs/about/project-details.md index e166099de..0790f1356 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -4,7 +4,7 @@ [![chat](http://img.shields.io/badge/GitHub_Project-Active-blue.svg)](https://github.com/utPLSQL/utPLSQL) [![license](http://img.shields.io/badge/license-apache%202.0-blue.svg)](https://www.apache.org/licenses/LICENSE-2.0) -[![chat](http://img.shields.io/badge/chat-slack-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) +[![chat](http://img.shields.io/badge/chat-slack-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) diff --git a/docs/about/support.md b/docs/about/support.md index 5ad87fc66..3dc0c0412 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -3,4 +3,4 @@ # How to get support - Feel free to post questions, bugs or issues in the [issues area of GitHub](https://github.com/utPLSQL/utPLSQL/issues) -- [Join](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) developers team on utPLSQL [Slack](https://utplsql.slack.com/) +- [Join](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) developers team on utPLSQL [Slack](https://utplsql.slack.com/) diff --git a/readme.md b/readme.md index e56aba1d4..2cc72040d 100644 --- a/readme.md +++ b/readme.md @@ -162,7 +162,7 @@ We welcome new developers to join our community and contribute to the utPLSQL pr If you are interested in helping please read our [guide to contributing](CONTRIBUTING.md) The best place to start is to read the documentation and get familiar with the existing code base. A [slack chat](https://utplsql.slack.com/) is the place to go if you want to talk with team members. -To sign up to the chat use [this link](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA). +To sign up to the chat use [this link](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww). ---------- @@ -182,7 +182,7 @@ __Project Directories__ ---------- -If you have a great feature in mind, that you would like to see in utPLSQL v3 please create an [issue on GitHub](https://github.com/utPLSQL/utPLSQL/issues) or discuss it with us in the [slack chat rooms](https://utplsql.slack.com/). Use [invite link](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA) to join the chat. +If you have a great feature in mind, that you would like to see in utPLSQL v3 please create an [issue on GitHub](https://github.com/utPLSQL/utPLSQL/issues) or discuss it with us in the [slack chat rooms](https://utplsql.slack.com/). Use [invite link](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) to join the chat. # Version 2 to Version 3 Comparison From de73451b9a4ad7531ab481284d1f941e20886504 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 24 Nov 2021 23:35:29 +0200 Subject: [PATCH 168/887] Building github actions --- .github/workflows/build.yml | 84 ++++++++++++++++++++++--------------- 1 file changed, 50 insertions(+), 34 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d3f4f0f4f..20a011d34 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -4,38 +4,36 @@ env: UT3_DEVELOP_SCHEMA_PASSWORD: ut3 UT3_RELEASE_VERSION_SCHEMA: UT3 UT3_RELEASE_VERSION_SCHEMA_PASSWORD: ut3 - UT3_USER: 'UT3\$USER#' + UT3_USER: 'UT3$USER#' UT3_USER_PASSWORD: ut3 UT3_TESTER: UT3_TESTER UT3_TESTER_PASSWORD: ut3 UT3_TESTER_HELPER: UT3_TESTER_HELPER UT3_TESTER_HELPER_PASSWORD: ut3 UT3_TABLESPACE: users - BUILD_DIR: ${{env.GITHUB_WORKSPACE}} - JOB_ID: ${{env.GITHUB_RUN_ID}} - JOB_NUMBER: ${{env.GITHUB_RUN_NUMBER}} - PULL_REQUEST_NAME: ${env.GITHUB_HEAD_REF} - PULL_REQUEST_BRANCH: ${{env.GITHUB_HEAD_REF}} + BUILD_DIR: ${{github.workspace}} + JOB_ID: ${{github.run_id}} + JOB_NUMBER: ${{github.run_number}} + PULL_REQUEST_NAME: ${github.head_ref} + PULL_REQUEST_BRANCH: ${{github.head_ref}} TAG_NAME: ${TRAVIS_TAG} REPO_SLUG: ${TRAVIS_REPO_SLUG} - PR_SLUG: ${{env.GITHUB_REPOSITORY}} + PR_SLUG: ${{github.repository}} BRANCH_NAME: ${TRAVIS_BRANCH} # Environment for building a release CURRENT_BRANCH: ${TRAVIS_BRANCH} UTPLSQL_REPO: "utPLSQL/utPLSQL" - UTPLSQL_BUILD_NO: ${{env.GITHUB_RUN_ID}} + UTPLSQL_BUILD_NO: ${{github.run_id}} UTPLSQL_VERSION: $(. .travis/get_project_version.sh) UTPLSQL_BUILD_VERSION: $(. .travis/get_project_build_version.sh) UTPLSQL_SOURCES_DIR: 'source' UTPLSQL_BUILD_USER_NAME: "Travis CI" CACHE_DIR: $HOME/.cache # Database Env - SQLCLI: "${BUILD_DIR}/sqlcl/bin/sql" + SQLCLI: "sqlplus" OJDBC_HOME: "${BUILD_DIR}/ojdbc" ORACLE_PWD: "oracle" DOCKHER_HUB_REPO: "utplsqlv3/oracledb" - DOCKER_VOLUME: "/home/oracle/host" - DOCKER_ENV: "-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" #utPLSQL released version directory UTPLSQL_DIR: "utPLSQL_latest_release" SELFTESTING_BRANCH: ${TRAVIS_BRANCH} @@ -56,36 +54,40 @@ jobs: build: env: - UTPLSQL_VERSION: ${{matrix.utplsql-version}} + ORACLE_VERSION: ${{matrix.oracle-version}} + CONNECTION_STR: ${{matrix.connection-str}} + ORACLE_PASSWORD: oracle + DOCKER_VOLUME: ${{matrix.docker-volume}} + DOCKER_ENV: "-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" runs-on: ubuntu-latest strategy: + fail-fast: false matrix: include: - - oracle-version: "gvenzl/oracle-xe:11-slim" + - oracle-version: "gvenzl/oracle-xe:11-full" connection-str: '127.0.0.1:1521/XE' -# docker-options: '--shm-size=1g' # - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' # - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' - oracle-version: "gvenzl/oracle-xe:18-slim" connection-str: '127.0.0.1:1521/XE' - docker-options: '-e ORACLE_PASSWORD=oracle' # - oracle-version: "utplsqlv3/oracledb:18c-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' # - oracle-version: "utplsqlv3/oracledb:19c-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' - - oracle-version: "gvenzl/oracle-xe:21-full" - connection-str: '127.0.0.1:1521/XE' - docker-options: '-e ORACLE_PASSWORD=oracle' +# - oracle-version: "gvenzl/oracle-xe:21-full" +# connection-str: '127.0.0.1:1521/XE' services: oracle: - image: ${matrix.oracle-version} + image: ${{matrix.oracle-version}} env: - CONNECTION_STR: ${matrix.connection-str} ORACLE_PASSWORD: oracle +# credentials: +# username: ${{ secrets.DOCKER_USER }} +# password: ${{ secrets.DOCKER_PASSWORD }} ports: - 1521:1521 options: >- @@ -93,30 +95,44 @@ jobs: --health-interval 10s --health-timeout 5s --health-retries 10 - ${matrix.docker-options} + -e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR steps: - uses: actions/checkout@v2 with: fetch-depth: 0 - - name: Install utPLSQL ${{matrix.utplsql-version}} - run: echo Installing ${UTPLSQL_VERSION} && sh ${{ github.workspace }}/scripts/1_install_utplsql.sh +# - name: Update project version & build number +# run: sh ${{ github.workspace }}/.travis/update_project_version.sh + + - name: Download latest utPLSQL release + run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR - name: Install utPLSQL-cli run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli - - name: Install demo project - run: sh ${{ github.workspace }}/scripts/2_install_demo_project.sh + - name: Update privileges on sources + run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} - - name: Install unit tests - run: sh ${{ github.workspace }}/scripts/3_install_tests.sh + - name: Install utPLSQL + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .travis/install.sh - - name: Run unit tests - run: sh ${{ github.workspace }}/scripts/4_run_tests.sh + - name: Install utPLSQL release + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/install_utplsql_release.sh - - name: SonarCloud Scan - uses: SonarSource/sonarcloud-github-action@master - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + - name: Run Examples + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/run_examples.sh + + - name: Install tests + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./test/install_tests.sh + + - name: Run Tests + run: bash $(pwd)/test/run_tests.sh + + +# +# - name: SonarCloud Scan +# uses: SonarSource/sonarcloud-github-action@master +# env: +# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any +# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} From 1c3004a5b28b44c3a1ea65308e97fbf59b215c3c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 25 Nov 2021 09:43:25 +0200 Subject: [PATCH 169/887] Adding OJDBC Download --- .github/workflows/build.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 20a011d34..88d84c3bd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,7 +31,8 @@ env: CACHE_DIR: $HOME/.cache # Database Env SQLCLI: "sqlplus" - OJDBC_HOME: "${BUILD_DIR}/ojdbc" + OJDBC_HOME: ${{github.workspace}}/ojdbc + OJDBC_URL: "https://download.oracle.com/otn-pub/otn_software/jdbc/213" ORACLE_PWD: "oracle" DOCKHER_HUB_REPO: "utplsqlv3/oracledb" #utPLSQL released version directory @@ -108,6 +109,9 @@ jobs: - name: Download latest utPLSQL release run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR + - name: Add OJDBC home + run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar + - name: Install utPLSQL-cli run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli From 0b9f937822f233c5b241cb873b25c5bd600a4111 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 25 Nov 2021 09:47:54 +0200 Subject: [PATCH 170/887] Adding TimeZone --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 88d84c3bd..0153beeb1 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -39,6 +39,7 @@ env: UTPLSQL_DIR: "utPLSQL_latest_release" SELFTESTING_BRANCH: ${TRAVIS_BRANCH} UTPLSQL_CLI_VERSION: "3.1.8" + TZ: "Europe/London" # Maven MAVEN_HOME: /usr/local/maven MAVEN_CFG: $HOME/.m2 From 0ce0368c41e26b5fd8819ae534c636c3cf41322d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 25 Nov 2021 10:25:52 +0200 Subject: [PATCH 171/887] Adding 21xe-full --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0153beeb1..3c49f9d6a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -79,8 +79,8 @@ jobs: # connection-str: '127.0.0.1:1521/ORCLCDB' # - oracle-version: "utplsqlv3/oracledb:19c-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' -# - oracle-version: "gvenzl/oracle-xe:21-full" -# connection-str: '127.0.0.1:1521/XE' + - oracle-version: "gvenzl/oracle-xe:21-full" + connection-str: '127.0.0.1:1521/XE' services: oracle: From 49216103029909e92e86fdc8d32f5fcc109dd352 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 30 Nov 2021 23:03:08 +0200 Subject: [PATCH 172/887] Switching to 21c-xe-slim --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3c49f9d6a..5afb5aeee 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -79,7 +79,7 @@ jobs: # connection-str: '127.0.0.1:1521/ORCLCDB' # - oracle-version: "utplsqlv3/oracledb:19c-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' - - oracle-version: "gvenzl/oracle-xe:21-full" + - oracle-version: "gvenzl/oracle-xe:21-slim" connection-str: '127.0.0.1:1521/XE' services: From 09d32618b5887449d601ba4d6ccef25576bd2e1a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 2 Dec 2021 22:38:30 +0200 Subject: [PATCH 173/887] Fixing build numbers and sonar analysis configuration. --- .github/workflows/build.yml | 27 ++++++++++++++++++++------- .travis/coveralls_uploader.js | 2 +- readme.md | 4 ++-- sonar-project.properties | 1 + 4 files changed, 24 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5afb5aeee..e88fca2b6 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -23,7 +23,8 @@ env: # Environment for building a release CURRENT_BRANCH: ${TRAVIS_BRANCH} UTPLSQL_REPO: "utPLSQL/utPLSQL" - UTPLSQL_BUILD_NO: ${{github.run_id}} + UTPLSQL_BUILD_NO_OFFSET: 3563 + UTPLSQL_BUILD_NO: $( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} ) UTPLSQL_VERSION: $(. .travis/get_project_version.sh) UTPLSQL_BUILD_VERSION: $(. .travis/get_project_build_version.sh) UTPLSQL_SOURCES_DIR: 'source' @@ -104,6 +105,17 @@ jobs: with: fetch-depth: 0 + - name: Set build no + run: echo "UTPLSQL_BUILD_NO=$( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} )" >> $GITHUB_ENV + + - name: Set version + run: echo "UTPLSQL_VERSION=$(. .travis/get_project_version.sh)" >> $GITHUB_ENV + + - name: Set version build no + + run: echo "UTPLSQL_BUILD_VERSION=$(. .travis/get_project_build_version.sh)" >> $GITHUB_ENV + - name: Output Run numbers + run: echo github.run_id is ${{ github.run_id }} github.run_number is ${{ github.run_number }} UTPLSQL_BUILD_NO is $UTPLSQL_BUILD_NO UTPLSQL_VERSION is $UTPLSQL_VERSION UTPLSQL_BUILD_VERSION is $UTPLSQL_BUILD_VERSION # - name: Update project version & build number # run: sh ${{ github.workspace }}/.travis/update_project_version.sh @@ -134,10 +146,11 @@ jobs: - name: Run Tests run: bash $(pwd)/test/run_tests.sh + - name: Validate utPLSQL reports format + run: bash .travis/validate_report_files.sh -# -# - name: SonarCloud Scan -# uses: SonarSource/sonarcloud-github-action@master -# env: -# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any -# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + - name: SonarCloud Scan + uses: SonarSource/sonarcloud-github-action@master + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} diff --git a/.travis/coveralls_uploader.js b/.travis/coveralls_uploader.js index 182f84066..b76c8f496 100644 --- a/.travis/coveralls_uploader.js +++ b/.travis/coveralls_uploader.js @@ -15,7 +15,7 @@ fs.readFile('../coverage.json',function (err,data) { } req = JSON.parse(data); req.service_job_id = process.env.JOB_ID; - req.service_name = 'travis-ci'; + req.service_name = 'github-actions'; if (process.env.COVERALLS_REPO_TOKEN) { req.repo_token = process.env.COVERALLS_REPO_TOKEN; } diff --git a/readme.md b/readme.md index e56aba1d4..0928f2b95 100644 --- a/readme.md +++ b/readme.md @@ -9,8 +9,8 @@ [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) [![build](https://travis-ci.com/utPLSQL/utPLSQL.svg?branch=develop)](https://travis-ci.com/utPLSQL/utPLSQL) -[![sonar](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=sqale_rating)](https://sonarcloud.io/dashboard/index?id=utPLSQL) -[![Coveralls coverage](https://coveralls.io/repos/github/utPLSQL/utPLSQL/badge.svg?branch=develop)](https://coveralls.io/github/utPLSQL/utPLSQL?branch=develop) +[![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=sqale_rating)](https://sonarcloud.io/dashboard/index?id=utPLSQL) +[![Coverage](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=coverage)](https://sonarcloud.io/summary/new_code?id=utPLSQL) ---------- utPLSQL version 3 is a complete rewrite of utPLSQL v2 from scratch. diff --git a/sonar-project.properties b/sonar-project.properties index d81d0a2b2..b68d13879 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -1,4 +1,5 @@ # must be unique in a given SonarQube instance +sonar.organization=utplsql sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL From e3e8c79375d7855598ae2acb56267418a2405608 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 5 Jan 2022 01:28:13 +0200 Subject: [PATCH 174/887] Added update of project version and build number. --- .github/workflows/build.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e88fca2b6..295e3ca63 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -111,13 +111,14 @@ jobs: - name: Set version run: echo "UTPLSQL_VERSION=$(. .travis/get_project_version.sh)" >> $GITHUB_ENV - - name: Set version build no + - name: Set version with build no + run: echo UTPLSQL_BUILD_VERSION=$(sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/" <<< "${UTPLSQL_VERSION}") >> $GITHUB_ENV - run: echo "UTPLSQL_BUILD_VERSION=$(. .travis/get_project_build_version.sh)" >> $GITHUB_ENV - name: Output Run numbers run: echo github.run_id is ${{ github.run_id }} github.run_number is ${{ github.run_number }} UTPLSQL_BUILD_NO is $UTPLSQL_BUILD_NO UTPLSQL_VERSION is $UTPLSQL_VERSION UTPLSQL_BUILD_VERSION is $UTPLSQL_BUILD_VERSION -# - name: Update project version & build number -# run: sh ${{ github.workspace }}/.travis/update_project_version.sh + + - name: Update project version & build number + run: sh ${{ github.workspace }}/.travis/update_project_version.sh - name: Download latest utPLSQL release run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR From e841b9b9a0acc690e27faeb1b2353b4c050ba42d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 5 Jan 2022 02:15:48 +0200 Subject: [PATCH 175/887] Fixing docs update --- .github/workflows/build.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 295e3ca63..358e0b01e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -19,9 +19,9 @@ env: TAG_NAME: ${TRAVIS_TAG} REPO_SLUG: ${TRAVIS_REPO_SLUG} PR_SLUG: ${{github.repository}} - BRANCH_NAME: ${TRAVIS_BRANCH} + BRANCH_NAME: ${github.ref} # Environment for building a release - CURRENT_BRANCH: ${TRAVIS_BRANCH} + CURRENT_BRANCH: ${{github.ref}} UTPLSQL_REPO: "utPLSQL/utPLSQL" UTPLSQL_BUILD_NO_OFFSET: 3563 UTPLSQL_BUILD_NO: $( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} ) @@ -118,7 +118,7 @@ jobs: run: echo github.run_id is ${{ github.run_id }} github.run_number is ${{ github.run_number }} UTPLSQL_BUILD_NO is $UTPLSQL_BUILD_NO UTPLSQL_VERSION is $UTPLSQL_VERSION UTPLSQL_BUILD_VERSION is $UTPLSQL_BUILD_VERSION - name: Update project version & build number - run: sh ${{ github.workspace }}/.travis/update_project_version.sh + run: .travis/update_project_version.sh - name: Download latest utPLSQL release run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR @@ -145,7 +145,7 @@ jobs: run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./test/install_tests.sh - name: Run Tests - run: bash $(pwd)/test/run_tests.sh + run: bash test/run_tests.sh - name: Validate utPLSQL reports format run: bash .travis/validate_report_files.sh From cae6a3589840f73be5896dc0f6bcb010404faf7a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 5 Jan 2022 02:25:48 +0200 Subject: [PATCH 176/887] Update env variables --- .github/workflows/build.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 358e0b01e..193872b4d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -17,11 +17,8 @@ env: PULL_REQUEST_NAME: ${github.head_ref} PULL_REQUEST_BRANCH: ${{github.head_ref}} TAG_NAME: ${TRAVIS_TAG} - REPO_SLUG: ${TRAVIS_REPO_SLUG} + REPO_SLUG: ${{github.repository}} PR_SLUG: ${{github.repository}} - BRANCH_NAME: ${github.ref} - # Environment for building a release - CURRENT_BRANCH: ${{github.ref}} UTPLSQL_REPO: "utPLSQL/utPLSQL" UTPLSQL_BUILD_NO_OFFSET: 3563 UTPLSQL_BUILD_NO: $( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} ) @@ -70,6 +67,7 @@ jobs: include: - oracle-version: "gvenzl/oracle-xe:11-full" connection-str: '127.0.0.1:1521/XE' +# TODO - need to add healthcheck.sh into our containers # - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' # - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" @@ -105,6 +103,11 @@ jobs: with: fetch-depth: 0 + - uses: nelonoel/branch-name@v1.0.1 + + - name: Set current branch name + run: echo "CURRENT_BRANCH=${BRANCH_NAME}" >> $GITHUB_ENV + - name: Set build no run: echo "UTPLSQL_BUILD_NO=$( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} )" >> $GITHUB_ENV From 7e875588f1a096654883ab3db6adf660b44f7788 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 5 Jan 2022 03:19:35 +0200 Subject: [PATCH 177/887] Formatting and cleanup --- .github/workflows/build.yml | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 193872b4d..03bbb03af 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -105,20 +105,19 @@ jobs: - uses: nelonoel/branch-name@v1.0.1 - - name: Set current branch name - run: echo "CURRENT_BRANCH=${BRANCH_NAME}" >> $GITHUB_ENV - - - name: Set build no - run: echo "UTPLSQL_BUILD_NO=$( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} )" >> $GITHUB_ENV - - - name: Set version - run: echo "UTPLSQL_VERSION=$(. .travis/get_project_version.sh)" >> $GITHUB_ENV - - - name: Set version with build no - run: echo UTPLSQL_BUILD_VERSION=$(sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/" <<< "${UTPLSQL_VERSION}") >> $GITHUB_ENV - - - name: Output Run numbers - run: echo github.run_id is ${{ github.run_id }} github.run_number is ${{ github.run_number }} UTPLSQL_BUILD_NO is $UTPLSQL_BUILD_NO UTPLSQL_VERSION is $UTPLSQL_VERSION UTPLSQL_BUILD_VERSION is $UTPLSQL_BUILD_VERSION + - name: Set dynamic environment variables + run: | + echo "CURRENT_BRANCH=${BRANCH_NAME}" >> $GITHUB_ENV + echo "UTPLSQL_BUILD_NO=$( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} )" >> $GITHUB_ENV + echo "UTPLSQL_VERSION=$(. .travis/get_project_version.sh)" >> $GITHUB_ENV + echo UTPLSQL_BUILD_VERSION=$(sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/" <<< "${UTPLSQL_VERSION}") >> $GITHUB_ENV + +# - name: print variables +# run: | +# echo github.run_number is ${{ github.run_number }} +# echo UTPLSQL_BUILD_NO is $UTPLSQL_BUILD_NO +# echo UTPLSQL_VERSION is $UTPLSQL_VERSION +# echo UTPLSQL_BUILD_VERSION is $UTPLSQL_BUILD_VERSION - name: Update project version & build number run: .travis/update_project_version.sh From 9307524cd9a8ac309e694ddf2191ea47c0a1dcf1 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 5 Jan 2022 23:02:51 +0200 Subject: [PATCH 178/887] Adding publishing of project version updates --- .github/workflows/build.yml | 247 ++++++++++++++++++------------ .travis/push_project_version.sh | 12 ++ .travis/push_release_version.sh | 18 --- .travis/update_project_version.sh | 2 +- 4 files changed, 165 insertions(+), 114 deletions(-) create mode 100755 .travis/push_project_version.sh delete mode 100755 .travis/push_release_version.sh diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 03bbb03af..f6de8da00 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,5 +1,6 @@ name: Deploy and test env: + #utPLSQL install env UT3_DEVELOP_SCHEMA: UT3_DEVELOP UT3_DEVELOP_SCHEMA_PASSWORD: ut3 UT3_RELEASE_VERSION_SCHEMA: UT3 @@ -11,22 +12,17 @@ env: UT3_TESTER_HELPER: UT3_TESTER_HELPER UT3_TESTER_HELPER_PASSWORD: ut3 UT3_TABLESPACE: users + #Build env BUILD_DIR: ${{github.workspace}} JOB_ID: ${{github.run_id}} JOB_NUMBER: ${{github.run_number}} - PULL_REQUEST_NAME: ${github.head_ref} + PULL_REQUEST_NAME: ${{github.head_ref}} PULL_REQUEST_BRANCH: ${{github.head_ref}} TAG_NAME: ${TRAVIS_TAG} REPO_SLUG: ${{github.repository}} PR_SLUG: ${{github.repository}} UTPLSQL_REPO: "utPLSQL/utPLSQL" UTPLSQL_BUILD_NO_OFFSET: 3563 - UTPLSQL_BUILD_NO: $( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} ) - UTPLSQL_VERSION: $(. .travis/get_project_version.sh) - UTPLSQL_BUILD_VERSION: $(. .travis/get_project_build_version.sh) - UTPLSQL_SOURCES_DIR: 'source' - UTPLSQL_BUILD_USER_NAME: "Travis CI" - CACHE_DIR: $HOME/.cache # Database Env SQLCLI: "sqlplus" OJDBC_HOME: ${{github.workspace}}/ojdbc @@ -51,52 +47,120 @@ on: workflow_dispatch: jobs: - build: - - env: - ORACLE_VERSION: ${{matrix.oracle-version}} - CONNECTION_STR: ${{matrix.connection-str}} - ORACLE_PASSWORD: oracle - DOCKER_VOLUME: ${{matrix.docker-volume}} - DOCKER_ENV: "-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" +# build: +# env: +# ORACLE_VERSION: ${{matrix.oracle-version}} +# CONNECTION_STR: ${{matrix.connection-str}} +# ORACLE_PASSWORD: oracle +# DOCKER_VOLUME: ${{matrix.docker-volume}} +# DOCKER_ENV: "-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" +# +# runs-on: ubuntu-latest +# strategy: +# fail-fast: false +# matrix: +# include: +# - oracle-version: "gvenzl/oracle-xe:11-full" +# connection-str: '127.0.0.1:1521/XE' +## TODO - need to add healthcheck.sh into our containers +## - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" +## connection-str: '127.0.0.1:1521/ORCLCDB' +## - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" +## connection-str: '127.0.0.1:1521/ORCLCDB' +# - oracle-version: "gvenzl/oracle-xe:18-slim" +# connection-str: '127.0.0.1:1521/XE' +## - oracle-version: "utplsqlv3/oracledb:18c-se2-small" +## connection-str: '127.0.0.1:1521/ORCLCDB' +## - oracle-version: "utplsqlv3/oracledb:19c-se2-small" +## connection-str: '127.0.0.1:1521/ORCLCDB' +# - oracle-version: "gvenzl/oracle-xe:21-slim" +# connection-str: '127.0.0.1:1521/XE' +# +# services: +# oracle: +# image: ${{matrix.oracle-version}} +# env: +# ORACLE_PASSWORD: oracle +## credentials: +## username: ${{ secrets.DOCKER_USER }} +## password: ${{ secrets.DOCKER_PASSWORD }} +# ports: +# - 1521:1521 +# options: >- +# --health-cmd healthcheck.sh +# --health-interval 10s +# --health-timeout 5s +# --health-retries 10 +# -e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR +# +# steps: +# - uses: actions/checkout@v2 +# with: +# fetch-depth: 0 +# +# - uses: nelonoel/branch-name@v1.0.1 +# +# - name: Set dynamic environment variables +# run: | +# echo "CURRENT_BRANCH=${BRANCH_NAME}" >> $GITHUB_ENV +# echo "UTPLSQL_BUILD_NO=$( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} )" >> $GITHUB_ENV +# echo "UTPLSQL_VERSION=$(.travis/get_project_version.sh)" >> $GITHUB_ENV +# shell: bash +# +# - name: Set buid version number +# run: echo UTPLSQL_BUILD_VERSION=$(echo ${UTPLSQL_VERSION} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/") >> $GITHUB_ENV +# shell: bash +# +# - name: print variables +# run: | +# echo github.run_number is ${{ github.run_number }} +# echo UTPLSQL_BUILD_NO is $UTPLSQL_BUILD_NO +# echo UTPLSQL_VERSION is $UTPLSQL_VERSION +# echo UTPLSQL_BUILD_VERSION is $UTPLSQL_BUILD_VERSION +# +# - name: Update project version & build number to verify that code is deployable after the update +# run: .travis/update_project_version.sh +# +# - name: Download latest utPLSQL release +# run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR +# +# - name: Add OJDBC home +# run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar +# +# - name: Install utPLSQL-cli +# run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli +# +# - name: Update privileges on sources +# run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} +# +# - name: Install utPLSQL +# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .travis/install.sh +# +# - name: Install utPLSQL release +# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/install_utplsql_release.sh +# +# - name: Run Examples +# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/run_examples.sh +# +# - name: Install tests +# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./test/install_tests.sh +# +# - name: Run Tests +# run: bash test/run_tests.sh +# +# - name: Validate utPLSQL reports format +# run: bash .travis/validate_report_files.sh +# +# - name: SonarCloud Scan +# uses: SonarSource/sonarcloud-github-action@master +# env: +# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any +# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + + publish: +# needs: build runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - include: - - oracle-version: "gvenzl/oracle-xe:11-full" - connection-str: '127.0.0.1:1521/XE' -# TODO - need to add healthcheck.sh into our containers -# - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" -# connection-str: '127.0.0.1:1521/ORCLCDB' -# - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" -# connection-str: '127.0.0.1:1521/ORCLCDB' - - oracle-version: "gvenzl/oracle-xe:18-slim" - connection-str: '127.0.0.1:1521/XE' -# - oracle-version: "utplsqlv3/oracledb:18c-se2-small" -# connection-str: '127.0.0.1:1521/ORCLCDB' -# - oracle-version: "utplsqlv3/oracledb:19c-se2-small" -# connection-str: '127.0.0.1:1521/ORCLCDB' - - oracle-version: "gvenzl/oracle-xe:21-slim" - connection-str: '127.0.0.1:1521/XE' - - services: - oracle: - image: ${{matrix.oracle-version}} - env: - ORACLE_PASSWORD: oracle -# credentials: -# username: ${{ secrets.DOCKER_USER }} -# password: ${{ secrets.DOCKER_PASSWORD }} - ports: - - 1521:1521 - options: >- - --health-cmd healthcheck.sh - --health-interval 10s - --health-timeout 5s - --health-retries 10 - -e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR steps: - uses: actions/checkout@v2 @@ -109,51 +173,44 @@ jobs: run: | echo "CURRENT_BRANCH=${BRANCH_NAME}" >> $GITHUB_ENV echo "UTPLSQL_BUILD_NO=$( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} )" >> $GITHUB_ENV - echo "UTPLSQL_VERSION=$(. .travis/get_project_version.sh)" >> $GITHUB_ENV - echo UTPLSQL_BUILD_VERSION=$(sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/" <<< "${UTPLSQL_VERSION}") >> $GITHUB_ENV + echo "UTPLSQL_VERSION=$(.travis/get_project_version.sh)" >> $GITHUB_ENV + shell: bash -# - name: print variables -# run: | -# echo github.run_number is ${{ github.run_number }} -# echo UTPLSQL_BUILD_NO is $UTPLSQL_BUILD_NO -# echo UTPLSQL_VERSION is $UTPLSQL_VERSION -# echo UTPLSQL_BUILD_VERSION is $UTPLSQL_BUILD_VERSION - - - name: Update project version & build number - run: .travis/update_project_version.sh - - - name: Download latest utPLSQL release - run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR - - - name: Add OJDBC home - run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar - - - name: Install utPLSQL-cli - run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli - - - name: Update privileges on sources - run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} + - name: Set buid version number + run: echo UTPLSQL_BUILD_VERSION=$(echo ${UTPLSQL_VERSION} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/") >> $GITHUB_ENV + shell: bash - - name: Install utPLSQL - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .travis/install.sh - - name: Install utPLSQL release - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/install_utplsql_release.sh + - name: Install MkDocs + run: pip install mkdocs - - name: Run Examples - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/run_examples.sh - - - name: Install tests - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./test/install_tests.sh - - - name: Run Tests - run: bash test/run_tests.sh - - - name: Validate utPLSQL reports format - run: bash .travis/validate_report_files.sh - - - name: SonarCloud Scan - uses: SonarSource/sonarcloud-github-action@master - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + - name: Update project version & build number in source code and documentation + run: .travis/update_project_version.sh + shell: bash + + - name: Push version update to repository + uses: test-room-7/action-update-file@v1 + with: + file-path: | + sonar-project.properties + VERSION + source/** + docs/** + commit-msg: Updated project version after build [skip ci] + github-token: ${{ secrets.PUSH_TOKEN }} + branch: ${{ env.CURRENT_BRANCH }} + if: | + ${{ + github.ref_type == 'branch' + && github.repository == 'utPLSQL/utPLSQL' + && ( startsWith(env.CURRENT_BRANCH,'release/') + || env.CURRENT_BRANCH == 'develop' + || env.CURRENT_BRANCH == 'feature/github_actions' + ) + }} + + +# TODO - add slack notifications +# TODO - add push of documentation +# TODO - add building of release archive +# TODO - add publishing of release diff --git a/.travis/push_project_version.sh b/.travis/push_project_version.sh new file mode 100755 index 000000000..1b38e6c24 --- /dev/null +++ b/.travis/push_project_version.sh @@ -0,0 +1,12 @@ +#!/usr/bin/env bash + +set -v +echo Current branch is "${CURRENT_BRANCH}" +echo "Committing version & buildNo into branch (${CURRENT_BRANCH})" +git add sonar-project.properties +git add VERSION +git add source/* +git add docs/* +git commit -m 'Updated project version after build [skip ci]' +echo "Pushing to origin" +git push --quiet origin HEAD:${CURRENT_BRANCH} diff --git a/.travis/push_release_version.sh b/.travis/push_release_version.sh deleted file mode 100755 index f4ca8f819..000000000 --- a/.travis/push_release_version.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/usr/bin/env bash - -# We are updating version number only when: -# - not a pull request -# - branch name is = develop or branch name is like release/vX.X.X... -if [ "${REPO_SLUG}" = "${UTPLSQL_REPO}" ] && [ "${PULL_REQUEST_NAME}" == "false" ] && [[ "${CURRENT_BRANCH}" =~ ^(release/v[0-9]+\.[0-9]+\.[0-9]+.*|develop)$ ]]; then - echo Current branch is "${CURRENT_BRANCH}" - echo "Committing version & buildNo into branch (${CURRENT_BRANCH})" - git add sonar-project.properties - git add VERSION - git add source/* - git add docs/* - git commit -m 'Updated project version after build [skip ci]' - echo "Pushing to origin" - git push --quiet origin HEAD:${CURRENT_BRANCH} -else - echo "Publishing of version skipped for branch ${CURRENT_BRANCH}, pull request ${PULL_REQUEST_NAME}" -fi diff --git a/.travis/update_project_version.sh b/.travis/update_project_version.sh index c4540eef8..bb6f72f00 100755 --- a/.travis/update_project_version.sh +++ b/.travis/update_project_version.sh @@ -5,7 +5,7 @@ UTPLSQL_VERSION_PATTERN="v?([0-9]+\.){3}[0-9]+[^']*" echo Current branch is "${CURRENT_BRANCH}" echo Update version in project source files -find ${UTPLSQL_SOURCES_DIR} -type f -name '*' -exec sed -i -r "s/${UTPLSQL_VERSION_PATTERN}/${UTPLSQL_BUILD_VERSION}/" {} \; +find source -type f -name '*' -exec sed -i -r "s/${UTPLSQL_VERSION_PATTERN}/${UTPLSQL_BUILD_VERSION}/" {} \; echo Source files updated with version tag: ${UTPLSQL_BUILD_VERSION} echo Update version in documentation files From 169f61c80d646e5fd308942790637ea1507c8446 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 6 Jan 2022 15:34:26 +0200 Subject: [PATCH 179/887] Update of token --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f6de8da00..a998a7c91 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -197,7 +197,7 @@ jobs: source/** docs/** commit-msg: Updated project version after build [skip ci] - github-token: ${{ secrets.PUSH_TOKEN }} + github-token: ${{ secrets.API_TOKEN_GITHUB }} branch: ${{ env.CURRENT_BRANCH }} if: | ${{ From 82c4d21a97c29d6fa85df65d9688ad1b70e4677f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 6 Jan 2022 15:52:02 +0200 Subject: [PATCH 180/887] Testing publishing of documentation to gh-pages --- .github/workflows/build.yml | 18 ++++ .travis/push_docs_to_github_io.sh | 134 +++++++++++++++--------------- 2 files changed, 84 insertions(+), 68 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a998a7c91..45956f696 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -209,6 +209,24 @@ jobs: ) }} + - name: Copy and push documentation to utPLSQL-github-io repo + env: + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} + run: .travis/push_docs_to_github_io.sh + shell: bash + if: | + ${{ + github.repository == 'utPLSQL/utPLSQL' + && (github.ref_type == 'branch' + && ( startsWith(env.CURRENT_BRANCH,'release/') + || env.CURRENT_BRANCH == 'develop' + || env.CURRENT_BRANCH == 'feature/github_actions' + ) + || github.ref_type == 'tag' + ) + }} + + # TODO - add slack notifications # TODO - add push of documentation diff --git a/.travis/push_docs_to_github_io.sh b/.travis/push_docs_to_github_io.sh index 5c3fcd672..ae36dc5db 100755 --- a/.travis/push_docs_to_github_io.sh +++ b/.travis/push_docs_to_github_io.sh @@ -17,81 +17,79 @@ LATEST_DOCS_BRANCH="develop" GITHUB_IO_REPO='utPLSQL/utPLSQL.github.io' GITHUB_IO_BRANCH='main' -# TRAVIS_* variables are set by travis directly and only need to be if testing externally -# We deploy only when building on develop branch or on TAG (release) -if [ "${PULL_REQUEST_NAME}" == "false" ] && { [ "${CURRENT_BRANCH}" == "${LATEST_DOCS_BRANCH}" ] || [ -n "${TAG_NAME}" ]; }; then +# ENV Variable checks are to help with configuration troubleshooting, they silently exit with unique message. +# Anyone one of them not set can be used to turn off this functionality. - # ENV Variable checks are to help with configuration troubleshooting, they silently exit with unique message. - # Anyone one of them not set can be used to turn off this functionality. +# If a version of the project is not defined +[[ -n "${UTPLSQL_VERSION}" ]] || { echo "variable UTPLSQL_VERSION is not defines or missing value"; exit 1; } +# Fail if the markdown documentation is not present. +[[ -f ./docs/index.md ]] || { echo "file docs/index.md not found"; exit 1; } - # If a version of the project is not defined - [[ -n "${UTPLSQL_VERSION}" ]] || { echo "variable UTPLSQL_VERSION is not defines or missing value"; exit 1; } - # Fail if the markdown documentation is not present. - [[ -f ./docs/index.md ]] || { echo "file docs/index.md not found"; exit 1; } +# Store latest commit SHA to be used when committing and pushing to github.io repo +SHA=`git rev-parse --verify HEAD` - # Store latest commit SHA to be used when committing and pushing to github.io repo - SHA=`git rev-parse --verify HEAD` +# clone the repository and switch to GITHUB_IO_BRANCH branch +mkdir pages +cd ./pages +git clone --depth 1 https://${API_TOKEN_GITHUB}@github.com/${GITHUB_IO_REPO} -b ${GITHUB_IO_BRANCH} . - # clone the repository and switch to GITHUB_IO_BRANCH branch - mkdir pages - cd ./pages - git clone --depth 1 https://${github_api_token}@github.com/${GITHUB_IO_REPO} -b ${GITHUB_IO_BRANCH} . +git config user.email "github-actions[bot]@users.noreply.github.com" +git config user.name "github-actions[bot]" - mkdir -p utPLSQL - cd ./utPLSQL - #clear out develop documentation directory and copy docs contents to it. - echo "updating 'develop' documentation directory" - mkdir -p ./develop - rm -rf ./develop/**./* || exit 0 - cp -a ../../docs/. ./develop +mkdir -p utPLSQL +cd ./utPLSQL +#clear out develop documentation directory and copy docs contents to it. +echo "updating 'develop' documentation directory" +mkdir -p ./develop +rm -rf ./develop/**./* || exit 0 +cp -a ../../docs/. ./develop - # If a Tagged Build then copy to it's own directory as well and to the 'latest' release directory - if [ -n "${TAG_NAME}" ]; then - echo "Creating directory ./${UTPLSQL_VERSION}" - mkdir -p ./${UTPLSQL_VERSION} - rm -rf ./${UTPLSQL_VERSION}/**./* || exit 0 - cp -a ../../docs/. ./${UTPLSQL_VERSION} - echo "Populating 'latest' directory" - mkdir -p ./latest - rm -rf ./latest/**./* || exit 0 - cp -a ../../docs/. ./latest - fi - # Stage changes for commit - git add . +# If a Tagged Build then copy to it's own directory as well and to the 'latest' release directory +if [ "${GITHUB_REF_TYPE}" == "tag" ]; then + echo "Creating directory ./${UTPLSQL_VERSION}" + mkdir -p ./${UTPLSQL_VERSION} + rm -rf ./${UTPLSQL_VERSION}/**./* || exit 0 + cp -a ../../docs/. ./${UTPLSQL_VERSION} + echo "Populating 'latest' directory" + mkdir -p ./latest + rm -rf ./latest/**./* || exit 0 + cp -a ../../docs/. ./latest +fi +# Stage changes for commit +git add . - #Check if there are doc changes, if none exit the script - if [[ -z `git diff HEAD --exit-code` ]]; then - echo "No changes to docs detected." - exit 0 - fi - #Changes where detected, so we need to update the version log. - now=$(date +"%d %b %Y - %r") - if [ ! -f index.md ]; then - echo "---" >>index.md - echo "layout: default" >>index.md - echo "---" >>index.md - echo "" >>index.md - echo "# Documentation versions" >>index.md - echo "" >>index.md - echo "" >>index.md #- 7th line - placeholder for latest release doc - echo "" >>index.md #- 8th line - placeholder for develop branch doc - echo "" >>index.md - echo "## Released Version Doc History" >>index.md - echo "" >>index.md - fi - #If build running on a TAG - it's a new release - need to add it to documentation - if [ -n "${TAG_NAME}" ]; then - sed -i '7s@.*@'" - [Latest ${TAG_NAME} documentation](latest/) - Created $now"'@' index.md - #add entry to the top of version history (line end of file - ## Released Version Doc History - sed -i '12i'" - [${TAG_NAME} documentation](${UTPLSQL_VERSION}/) - Created $now" index.md - fi - #replace 4th line in log - sed -i '8s@.*@'" - [Latest development version](develop/) - Created $now"'@' index.md - #Add and Commit the changes back to pages repo. - git add . - git commit -m "Deploy to gh-pages branch: base commit ${SHA}" - # Now that we're all set up, we can push. - git push --quiet origin HEAD:${GITHUB_IO_BRANCH} +#Check if there are doc changes, if none exit the script +if [[ -z `git diff HEAD --exit-code` ]]; then + echo "No changes to docs detected." + exit 0 +fi +#Changes where detected, so we need to update the version log. +now=$(date +"%d %b %Y - %r") +if [ ! -f index.md ]; then + echo "---" >>index.md + echo "layout: default" >>index.md + echo "---" >>index.md + echo "" >>index.md + echo "# Documentation versions" >>index.md + echo "" >>index.md + echo "" >>index.md #- 7th line - placeholder for latest release doc + echo "" >>index.md #- 8th line - placeholder for develop branch doc + echo "" >>index.md + echo "## Released Version Doc History" >>index.md + echo "" >>index.md +fi +#If build running on a TAG - it's a new release - need to add it to documentation +if [ "${GITHUB_REF_TYPE}" == "tag" ]; then + sed -i '7s@.*@'" - [Latest ${CURRENT_BRANCH} documentation](latest/) - Created $now"'@' index.md + #add entry to the top of version history (line end of file - ## Released Version Doc History + sed -i '12i'" - [${CURRENT_BRANCH} documentation](${UTPLSQL_VERSION}/) - Created $now" index.md fi +#replace 4th line in log +sed -i '8s@.*@'" - [Latest development version](develop/) - Created $now"'@' index.md +#Add and Commit the changes back to pages repo. +git add . +git commit -m "Deploy to gh-pages branch: base commit ${SHA}" +# Now that we're all set up, we can push. +git push --quiet origin HEAD:${GITHUB_IO_BRANCH} From 532be8d07a63a423eb105fe43a6e411f4853cbfc Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 7 Jan 2022 01:43:57 +0200 Subject: [PATCH 181/887] Externalizing env variables. Cleanup and refactoring. --- .github/scripts/set_version_numbers_env.sh | 10 + .github/variables/.env | 33 +++ .github/workflows/build.yml | 306 +++++++------------- .github/workflows/release_documentation.yml | 56 ++++ .travis/coveralls_uploader.js | 31 -- .travis/coveralls_uploader.sh | 6 - .travis/push_docs_to_github_io.sh | 3 - .travis/run_sonar_scanner.sh | 68 ----- .travis/start_db.sh | 15 - 9 files changed, 209 insertions(+), 319 deletions(-) create mode 100755 .github/scripts/set_version_numbers_env.sh create mode 100644 .github/variables/.env create mode 100644 .github/workflows/release_documentation.yml delete mode 100644 .travis/coveralls_uploader.js delete mode 100755 .travis/coveralls_uploader.sh delete mode 100755 .travis/run_sonar_scanner.sh delete mode 100755 .travis/start_db.sh diff --git a/.github/scripts/set_version_numbers_env.sh b/.github/scripts/set_version_numbers_env.sh new file mode 100755 index 000000000..8f463c49b --- /dev/null +++ b/.github/scripts/set_version_numbers_env.sh @@ -0,0 +1,10 @@ +#!/bin/bash + +UTPLSQL_BUILD_NO=$( expr ${JOB_NUMBER} + ${UTPLSQL_BUILD_NO_OFFSET} ) +UTPLSQL_VERSION=$(.travis/get_project_version.sh) + +echo "UTPLSQL_BUILD_NO=${UTPLSQL_BUILD_NO}" >> $GITHUB_ENV +echo "UTPLSQL_VERSION=${UTPLSQL_VERSION}" >> $GITHUB_ENV +echo UTPLSQL_BUILD_VERSION=$(echo ${UTPLSQL_VERSION} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/") >> $GITHUB_ENV + +echo "CURRENT_BRANCH=${BRANCH_NAME}" >> $GITHUB_ENV diff --git a/.github/variables/.env b/.github/variables/.env new file mode 100644 index 000000000..9f35a080c --- /dev/null +++ b/.github/variables/.env @@ -0,0 +1,33 @@ +#utPLSQL install env +UT3_DEVELOP_SCHEMA=UT3_DEVELOP +UT3_DEVELOP_SCHEMA_PASSWORD=ut3 +UT3_RELEASE_VERSION_SCHEMA=UT3 +UT3_RELEASE_VERSION_SCHEMA_PASSWORD=ut3 +UT3_USER='UT3$USER#' +UT3_USER_PASSWORD=ut3 +UT3_TESTER=UT3_TESTER +UT3_TESTER_PASSWORD=ut3 +UT3_TESTER_HELPER=UT3_TESTER_HELPER +UT3_TESTER_HELPER_PASSWORD=ut3 +UT3_TABLESPACE=users + +# Database Env +SQLCLI="sqlplus" +OJDBC_HOME=ojdbc +OJDBC_URL="https://download.oracle.com/otn-pub/otn_software/jdbc/213" +ORACLE_PWD="oracle" +TZ="Europe/London" + +#Build env +UTPLSQL_CLI_VERSION="3.1.8" +UTPLSQL_DIR="utPLSQL_latest_release" +UTPLSQL_BUILD_NO_OFFSET=3563 + +#Git configuration +GIT_AUTHOR_NAME="github-actions[bot]" +GIT_AUTHOR_EMAIL="github-actions[bot]@users.noreply.github.com" +GIT_COMMITTER_NAME="github-actions[bot]" +GIT_COMMITTER_EMAIL="github-actions[bot]@users.noreply.github.com" + +#Docker environment for running utPLSQL install commands +DOCKER_ENV="-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" \ No newline at end of file diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 45956f696..e509ffe98 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,42 +1,7 @@ -name: Deploy and test +name: Build and test env: - #utPLSQL install env - UT3_DEVELOP_SCHEMA: UT3_DEVELOP - UT3_DEVELOP_SCHEMA_PASSWORD: ut3 - UT3_RELEASE_VERSION_SCHEMA: UT3 - UT3_RELEASE_VERSION_SCHEMA_PASSWORD: ut3 - UT3_USER: 'UT3$USER#' - UT3_USER_PASSWORD: ut3 - UT3_TESTER: UT3_TESTER - UT3_TESTER_PASSWORD: ut3 - UT3_TESTER_HELPER: UT3_TESTER_HELPER - UT3_TESTER_HELPER_PASSWORD: ut3 - UT3_TABLESPACE: users - #Build env BUILD_DIR: ${{github.workspace}} - JOB_ID: ${{github.run_id}} JOB_NUMBER: ${{github.run_number}} - PULL_REQUEST_NAME: ${{github.head_ref}} - PULL_REQUEST_BRANCH: ${{github.head_ref}} - TAG_NAME: ${TRAVIS_TAG} - REPO_SLUG: ${{github.repository}} - PR_SLUG: ${{github.repository}} - UTPLSQL_REPO: "utPLSQL/utPLSQL" - UTPLSQL_BUILD_NO_OFFSET: 3563 - # Database Env - SQLCLI: "sqlplus" - OJDBC_HOME: ${{github.workspace}}/ojdbc - OJDBC_URL: "https://download.oracle.com/otn-pub/otn_software/jdbc/213" - ORACLE_PWD: "oracle" - DOCKHER_HUB_REPO: "utplsqlv3/oracledb" - #utPLSQL released version directory - UTPLSQL_DIR: "utPLSQL_latest_release" - SELFTESTING_BRANCH: ${TRAVIS_BRANCH} - UTPLSQL_CLI_VERSION: "3.1.8" - TZ: "Europe/London" - # Maven - MAVEN_HOME: /usr/local/maven - MAVEN_CFG: $HOME/.m2 on: push: @@ -46,189 +11,138 @@ on: workflow_dispatch: +defaults: + run: + shell: bash + jobs: -# build: -# env: -# ORACLE_VERSION: ${{matrix.oracle-version}} -# CONNECTION_STR: ${{matrix.connection-str}} -# ORACLE_PASSWORD: oracle -# DOCKER_VOLUME: ${{matrix.docker-volume}} -# DOCKER_ENV: "-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" -# -# runs-on: ubuntu-latest -# strategy: -# fail-fast: false -# matrix: -# include: -# - oracle-version: "gvenzl/oracle-xe:11-full" -# connection-str: '127.0.0.1:1521/XE' -## TODO - need to add healthcheck.sh into our containers -## - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" -## connection-str: '127.0.0.1:1521/ORCLCDB' -## - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" -## connection-str: '127.0.0.1:1521/ORCLCDB' -# - oracle-version: "gvenzl/oracle-xe:18-slim" -# connection-str: '127.0.0.1:1521/XE' -## - oracle-version: "utplsqlv3/oracledb:18c-se2-small" -## connection-str: '127.0.0.1:1521/ORCLCDB' -## - oracle-version: "utplsqlv3/oracledb:19c-se2-small" -## connection-str: '127.0.0.1:1521/ORCLCDB' -# - oracle-version: "gvenzl/oracle-xe:21-slim" -# connection-str: '127.0.0.1:1521/XE' -# -# services: -# oracle: -# image: ${{matrix.oracle-version}} -# env: -# ORACLE_PASSWORD: oracle -## credentials: -## username: ${{ secrets.DOCKER_USER }} -## password: ${{ secrets.DOCKER_PASSWORD }} -# ports: -# - 1521:1521 -# options: >- -# --health-cmd healthcheck.sh -# --health-interval 10s -# --health-timeout 5s -# --health-retries 10 -# -e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR -# -# steps: -# - uses: actions/checkout@v2 -# with: -# fetch-depth: 0 -# -# - uses: nelonoel/branch-name@v1.0.1 -# -# - name: Set dynamic environment variables -# run: | -# echo "CURRENT_BRANCH=${BRANCH_NAME}" >> $GITHUB_ENV -# echo "UTPLSQL_BUILD_NO=$( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} )" >> $GITHUB_ENV -# echo "UTPLSQL_VERSION=$(.travis/get_project_version.sh)" >> $GITHUB_ENV -# shell: bash -# -# - name: Set buid version number -# run: echo UTPLSQL_BUILD_VERSION=$(echo ${UTPLSQL_VERSION} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/") >> $GITHUB_ENV -# shell: bash -# -# - name: print variables -# run: | -# echo github.run_number is ${{ github.run_number }} -# echo UTPLSQL_BUILD_NO is $UTPLSQL_BUILD_NO -# echo UTPLSQL_VERSION is $UTPLSQL_VERSION -# echo UTPLSQL_BUILD_VERSION is $UTPLSQL_BUILD_VERSION -# -# - name: Update project version & build number to verify that code is deployable after the update -# run: .travis/update_project_version.sh -# -# - name: Download latest utPLSQL release -# run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR -# -# - name: Add OJDBC home -# run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar -# -# - name: Install utPLSQL-cli -# run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli -# -# - name: Update privileges on sources -# run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} -# -# - name: Install utPLSQL -# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .travis/install.sh -# -# - name: Install utPLSQL release -# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/install_utplsql_release.sh -# -# - name: Run Examples -# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/run_examples.sh -# -# - name: Install tests -# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./test/install_tests.sh -# -# - name: Run Tests -# run: bash test/run_tests.sh -# -# - name: Validate utPLSQL reports format -# run: bash .travis/validate_report_files.sh -# -# - name: SonarCloud Scan -# uses: SonarSource/sonarcloud-github-action@master -# env: -# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any -# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + build: + env: + ORACLE_VERSION: ${{matrix.oracle-version}} + CONNECTION_STR: ${{matrix.connection-str}} + ORACLE_PASSWORD: oracle + DOCKER_VOLUME: ${{matrix.docker-volume}} - publish: -# needs: build runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + include: + - oracle-version: "gvenzl/oracle-xe:11-full" + connection-str: '127.0.0.1:1521/XE' +# TODO - need to add healthcheck.sh into our containers +# - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' +# - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' + - oracle-version: "gvenzl/oracle-xe:18-slim" + connection-str: '127.0.0.1:1521/XE' +# - oracle-version: "utplsqlv3/oracledb:18c-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' +# - oracle-version: "utplsqlv3/oracledb:19c-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' + - oracle-version: "gvenzl/oracle-xe:21-slim" + connection-str: '127.0.0.1:1521/XE' + + services: + oracle: + image: ${{matrix.oracle-version}} + env: + ORACLE_PASSWORD: oracle +# credentials: +# username: ${{ secrets.DOCKER_USER }} +# password: ${{ secrets.DOCKER_PASSWORD }} + ports: + - 1521:1521 + options: >- + --health-cmd healthcheck.sh + --health-interval 10s + --health-timeout 5s + --health-retries 10 steps: - uses: actions/checkout@v2 with: fetch-depth: 0 - - uses: nelonoel/branch-name@v1.0.1 + - uses: c-py/action-dotenv-to-setenv@v2 + with: + env-file: .github/variables/.env + + + - name: Set buid version number env variables + run: .github/scripts/set_version_numbers_env.sh + + - name: Update project version & build number to verify that code is deployable after the update + run: .travis/update_project_version.sh + + - name: Download latest utPLSQL release + run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR + + - name: Add OJDBC home + run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar + + - name: Install utPLSQL-cli + run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli + + - name: Update privileges on sources + run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} + + - name: Install utPLSQL + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .travis/install.sh + + - name: Install utPLSQL release + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/install_utplsql_release.sh - - name: Set dynamic environment variables - run: | - echo "CURRENT_BRANCH=${BRANCH_NAME}" >> $GITHUB_ENV - echo "UTPLSQL_BUILD_NO=$( expr ${{github.run_number}} + ${UTPLSQL_BUILD_NO_OFFSET} )" >> $GITHUB_ENV - echo "UTPLSQL_VERSION=$(.travis/get_project_version.sh)" >> $GITHUB_ENV - shell: bash + - name: Run Examples + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/run_examples.sh - - name: Set buid version number - run: echo UTPLSQL_BUILD_VERSION=$(echo ${UTPLSQL_VERSION} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/") >> $GITHUB_ENV - shell: bash + - name: Install tests + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./test/install_tests.sh + - name: Run Tests + run: bash test/run_tests.sh - - name: Install MkDocs - run: pip install mkdocs + - name: Validate utPLSQL reports format + run: bash .travis/validate_report_files.sh + + - name: SonarCloud Scan + uses: SonarSource/sonarcloud-github-action@master + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + + publish: + needs: build + runs-on: ubuntu-latest + if: | + ${{ github.repository == 'utPLSQL/utPLSQL' && github.base_ref == null + && ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' ) + }} + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + #Populates the value of BRANCH_NAME env variable + - uses: nelonoel/branch-name@v1.0.1 + - uses: c-py/action-dotenv-to-setenv@v2 + with: + env-file: .github/variables/.env + + - name: Set buid version number env variables + run: .github/scripts/set_version_numbers_env.sh - name: Update project version & build number in source code and documentation run: .travis/update_project_version.sh - shell: bash - name: Push version update to repository - uses: test-room-7/action-update-file@v1 - with: - file-path: | - sonar-project.properties - VERSION - source/** - docs/** - commit-msg: Updated project version after build [skip ci] - github-token: ${{ secrets.API_TOKEN_GITHUB }} - branch: ${{ env.CURRENT_BRANCH }} - if: | - ${{ - github.ref_type == 'branch' - && github.repository == 'utPLSQL/utPLSQL' - && ( startsWith(env.CURRENT_BRANCH,'release/') - || env.CURRENT_BRANCH == 'develop' - || env.CURRENT_BRANCH == 'feature/github_actions' - ) - }} + run: .travis/push_project_version.sh - name: Copy and push documentation to utPLSQL-github-io repo env: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} run: .travis/push_docs_to_github_io.sh - shell: bash - if: | - ${{ - github.repository == 'utPLSQL/utPLSQL' - && (github.ref_type == 'branch' - && ( startsWith(env.CURRENT_BRANCH,'release/') - || env.CURRENT_BRANCH == 'develop' - || env.CURRENT_BRANCH == 'feature/github_actions' - ) - || github.ref_type == 'tag' - ) - }} - - # TODO - add slack notifications -# TODO - add push of documentation -# TODO - add building of release archive -# TODO - add publishing of release diff --git a/.github/workflows/release_documentation.yml b/.github/workflows/release_documentation.yml new file mode 100644 index 000000000..8d07e53d8 --- /dev/null +++ b/.github/workflows/release_documentation.yml @@ -0,0 +1,56 @@ +name: Create and publish release artifacts +env: + BUILD_DIR: ${{github.workspace}} + JOB_NUMBER: ${{github.run_number}} + PULL_REQUEST_NAME: ${{github.head_ref}} + PULL_REQUEST_BRANCH: ${{github.head_ref}} + REPO_SLUG: ${{github.repository}} + PR_SLUG: ${{github.repository}} + +on: + release: + types: [ created ] +#See: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions#example-using-multiple-events-with-activity-types-or-configuration + +defaults: + run: + shell: bash + +jobs: + + publish: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + + - uses: nelonoel/branch-name@v1.0.1 + + - name: Set buid version number env variables + run: .github/scripts/set_version_numbers_env.sh + + - name: Setup git config + run: | + git config --global user.email "github-actions[bot]@users.noreply.github.com" + git config --global user.name "github-actions[bot]" + + - name: Install MkDocs + run: pip install mkdocs + + - name: Update project version & build number in source code and documentation + run: .travis/update_project_version.sh + + - name: Push version update to repository + run: .travis/push_project_version.sh + + - name: Copy and push documentation to utPLSQL-github-io repo + env: + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} + run: .travis/push_docs_to_github_io.sh + + +# TODO - add slack notifications +# TODO - add building of release archive +# TODO - add publishing of release diff --git a/.travis/coveralls_uploader.js b/.travis/coveralls_uploader.js deleted file mode 100644 index b76c8f496..000000000 --- a/.travis/coveralls_uploader.js +++ /dev/null @@ -1,31 +0,0 @@ -var fs = require('fs'); -var request = require('request'); -const md5File = require('md5-file'); - -var url -if (process.env.COVERALLS_URL_BASE) { - url = process.env.COVERALLS_URL_BASE+'/api/v1/jobs'; -} else { - url = 'https://coveralls.io/api/v1/jobs'; -} - -fs.readFile('../coverage.json',function (err,data) { - if (err) { - return console.log(err); - } - req = JSON.parse(data); - req.service_job_id = process.env.JOB_ID; - req.service_name = 'github-actions'; - if (process.env.COVERALLS_REPO_TOKEN) { - req.repo_token = process.env.COVERALLS_REPO_TOKEN; - } - - for (var i in req.source_files) { - req.source_files[i].source_digest = md5File.sync("../" + req.source_files[i].name); - } - - var requestStr = JSON.stringify(req); - - request.post({url : url, form : { json:requestStr}}, function(err, response, body){process.stdout.write(body);}); - -}); diff --git a/.travis/coveralls_uploader.sh b/.travis/coveralls_uploader.sh deleted file mode 100755 index 8fcbad58d..000000000 --- a/.travis/coveralls_uploader.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh -e -echo "coveralls_uploader" -npm install request --save -npm install --save md5-file -cd "$(dirname "$(readlink -f "$0")")" -exec node coveralls_uploader.js diff --git a/.travis/push_docs_to_github_io.sh b/.travis/push_docs_to_github_io.sh index ae36dc5db..689cb99c9 100755 --- a/.travis/push_docs_to_github_io.sh +++ b/.travis/push_docs_to_github_io.sh @@ -34,9 +34,6 @@ mkdir pages cd ./pages git clone --depth 1 https://${API_TOKEN_GITHUB}@github.com/${GITHUB_IO_REPO} -b ${GITHUB_IO_BRANCH} . -git config user.email "github-actions[bot]@users.noreply.github.com" -git config user.name "github-actions[bot]" - mkdir -p utPLSQL cd ./utPLSQL #clear out develop documentation directory and copy docs contents to it. diff --git a/.travis/run_sonar_scanner.sh b/.travis/run_sonar_scanner.sh deleted file mode 100755 index f0a2805c1..000000000 --- a/.travis/run_sonar_scanner.sh +++ /dev/null @@ -1,68 +0,0 @@ -#!/usr/bin/env bash - -#Run Sonar based on conditions - -MAIN_DEV_BRANCH="develop" - -BRANCH_SONAR_PROPERTY="sonar.branch.name" -BRANCH_SONAR_TARGET_PROPERTY="sonar.branch.target" - -PR_SONAR_BRANCH_PROPERTY="sonar.pullrequest.branch" -PR_KEY_PROPERTY="sonar.pullrequest.key" -PR_SONAR_BASE_PROPERTY="sonar.pullrequest.base" -PR_SONAR_TOKEN_PROPERTY="sonar.pullrequest.github.token.secured" - -DB_URL_SONAR_PROPERTY="sonar.plsql.jdbc.url" -DB_DRIVER_PATH="sonar.plsql.jdbc.driver.path" - -#Add property to file -function add_sonar_property { - echo "$1=$2" >> sonar-project.properties -} - - -if [ "${PULL_REQUEST_NAME}" == "false" ]; then - BRANCH=${BRANCH_NAME}; - PR_BRANCH="" - echo "BRANCH=$BRANCH" -else - BRANCH=${PULL_REQUEST_BRANCH} - PR_BRANCH=${BRANCH_NAME} - echo "TRAVIS_BRANCH=$TRAVIS_BRANCH, PR=${PULL_REQUEST_NAME}, BRANCH=$BRANCH" - -fi - - -#Are we running on utPLSQL repo and not an external PR? -echo "Check if we running from develop or on branch" -if [ "${REPO_SLUG}" = "${UTPLSQL_REPO}" ] && [[ ! "${BRANCH}" =~ ^(release/v[0-9]+\.[0-9]+\.[0-9]+.*|"${MAIN_DEV_BRANCH}")$ ]]; then - - echo "" >> sonar-project.properties - if [ "${PULL_REQUEST_NAME}" == "false" ]; then - echo "Updating sonar properties to include branch ${BRANCH}" - add_sonar_property "${BRANCH_SONAR_PROPERTY}" "${BRANCH}" - add_sonar_property "${BRANCH_SONAR_TARGET_PROPERTY}" "${MAIN_DEV_BRANCH}" - elif [ "${PR_SLUG}" = "${REPO_SLUG}" ]; then - echo "Updating sonar properties to include pull request ${BRANCH}" - add_sonar_property "${PR_SONAR_TOKEN_PROPERTY}" "${GITHUB_TRAVISCI_TOKEN}" - add_sonar_property "${PR_SONAR_BRANCH_PROPERTY}" "${BRANCH}" - add_sonar_property "${PR_KEY_PROPERTY}" "${PR}" - add_sonar_property "${PR_SONAR_BASE_PROPERTY}" "${PR_BRANCH}" - else - echo "PR from external source no changes to properties." - fi -else - echo "No need to update sonar we building on release or develop" -fi - -#Address issue : Could not find ref 'develop' in refs/heads or refs/remotes/origin -git fetch --no-tags https://github.com/utPLSQL/utPLSQL.git +refs/heads/develop:refs/remotes/origin/develop - -echo "Adding OJDBC Driver Path ${OJDBC_HOME}/ojdbc8.jar" -add_sonar_property "${DB_URL_SONAR_PROPERTY}" "jdbc:oracle:thin:@${CONNECTION_STR}" -add_sonar_property "${DB_DRIVER_PATH}" "${OJDBC_HOME}/ojdbc8.jar" - - -#Execute Sonar scanner -echo "Executing sonar scanner" -sonar-scanner diff --git a/.travis/start_db.sh b/.travis/start_db.sh deleted file mode 100755 index 285f8172f..000000000 --- a/.travis/start_db.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/bash -set -e - -# Private Repo Login -if [ ! -f $CACHE_DIR/.docker/config.json ]; then - docker login -u "$DOCKER_USER" -p "$DOCKER_PASSWORD" - mkdir -p $CACHE_DIR/.docker && cp $HOME/.docker/config.json $CACHE_DIR/.docker/ -else - echo "Using docker login from cache..." - mkdir -p $HOME/.docker && cp $CACHE_DIR/.docker/config.json $HOME/.docker/ -fi - -time docker pull $DOCKHER_HUB_REPO:$ORACLE_VERSION -docker run -d --name $ORACLE_VERSION --mount type=bind,source=${BUILD_DIR},target=${DOCKER_VOLUME} $DOCKER_OPTIONS $DOCKER_ENV -p 1521:1521 $DOCKHER_HUB_REPO:$ORACLE_VERSION -time docker logs -f $ORACLE_VERSION | grep -m 1 "DATABASE IS READY TO USE!" --line-buffered From 12757eaa7eeeb728950f742226956b253c50a716 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 7 Jan 2022 03:19:24 +0200 Subject: [PATCH 182/887] Added job names. Added id for matrix jobs. Adding slack notification. Adding semaphore to prevent concurrency when publishing documentation. --- .github/workflows/build.yml | 64 ++++++++++++++++++--- .github/workflows/release_documentation.yml | 1 + 2 files changed, 57 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e509ffe98..16a5d7094 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,4 @@ -name: Build and test +name: Build, test, deploy documentation env: BUILD_DIR: ${{github.workspace}} JOB_NUMBER: ${{github.run_number}} @@ -11,13 +11,16 @@ on: workflow_dispatch: +concurrency: ${{github.ref}} + defaults: run: shell: bash jobs: - build: + build-and-test: + name: Build and test on ${{matrix.db_version_name}} DB env: ORACLE_VERSION: ${{matrix.oracle-version}} CONNECTION_STR: ${{matrix.connection-str}} @@ -31,19 +34,33 @@ jobs: include: - oracle-version: "gvenzl/oracle-xe:11-full" connection-str: '127.0.0.1:1521/XE' + id: 1 + db_version_name: '11xe' # TODO - need to add healthcheck.sh into our containers # - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' +# id: 2 +# db_version_name: '12.1se' # - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' +# id: 3 +# db_version_name: '12.2se' - oracle-version: "gvenzl/oracle-xe:18-slim" connection-str: '127.0.0.1:1521/XE' + id: 4 + db_version_name: '18xe' # - oracle-version: "utplsqlv3/oracledb:18c-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' +# id: 5 +# db_version_name: '18se' # - oracle-version: "utplsqlv3/oracledb:19c-se2-small" # connection-str: '127.0.0.1:1521/ORCLCDB' +# id: 6 +# db_version_name: '19se' - oracle-version: "gvenzl/oracle-xe:21-slim" connection-str: '127.0.0.1:1521/XE' + id: 7 + db_version_name: '21xe' services: oracle: @@ -71,50 +88,63 @@ jobs: env-file: .github/variables/.env - - name: Set buid version number env variables + - name: Set build version number env variables + id: set-build-version-number-vars run: .github/scripts/set_version_numbers_env.sh - name: Update project version & build number to verify that code is deployable after the update + id: update-project-version run: .travis/update_project_version.sh - name: Download latest utPLSQL release run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR + - name: Update privileges on sources + run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} + - name: Add OJDBC home + id: get-ojdbc run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar - name: Install utPLSQL-cli + id: install-utplsql-cli run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli - - name: Update privileges on sources - run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} - - name: Install utPLSQL + id: install-utplsql run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .travis/install.sh - name: Install utPLSQL release + id: install-utplsql-release run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/install_utplsql_release.sh - name: Run Examples + id: run-examples run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/run_examples.sh - name: Install tests + id: install-tests run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./test/install_tests.sh - name: Run Tests + id: run-tests run: bash test/run_tests.sh - name: Validate utPLSQL reports format + id: validate-reports-format run: bash .travis/validate_report_files.sh - name: SonarCloud Scan + id: sonar uses: SonarSource/sonarcloud-github-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} publish: - needs: build + name: Deploy documentation + needs: [build-and-test] + concurrency: publish runs-on: ubuntu-latest if: | ${{ github.repository == 'utPLSQL/utPLSQL' && github.base_ref == null @@ -132,17 +162,35 @@ jobs: env-file: .github/variables/.env - name: Set buid version number env variables + id: set-build-version-number-vars run: .github/scripts/set_version_numbers_env.sh - name: Update project version & build number in source code and documentation + id: update-project-version run: .travis/update_project_version.sh - name: Push version update to repository + id: push-version-number-update run: .travis/push_project_version.sh - name: Copy and push documentation to utPLSQL-github-io repo + id: push-documentation env: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} run: .travis/push_docs_to_github_io.sh -# TODO - add slack notifications + slack-workflow-status: + if: always() + name: Post Workflow Status To Slack + needs: [build-and-test, publish] + runs-on: ubuntu-latest + steps: + - name: Slack Workflow Notification + uses: Gamesight/slack-workflow-status@master + with: + # Required Input + repo_token: ${{secrets.GITHUB_TOKEN}} + slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} + # Optional Input + name: 'Github Actions[bot]' + icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' diff --git a/.github/workflows/release_documentation.yml b/.github/workflows/release_documentation.yml index 8d07e53d8..fbf31a718 100644 --- a/.github/workflows/release_documentation.yml +++ b/.github/workflows/release_documentation.yml @@ -19,6 +19,7 @@ defaults: jobs: publish: + concurrency: publish runs-on: ubuntu-latest steps: From ddd3862927f54b5e2d6e5d802eda7618a692cb12 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 7 Jan 2022 10:56:23 +0200 Subject: [PATCH 183/887] Fixing multi-line if statement. Refactoring. --- .github/scripts/set_version_numbers_env.sh | 4 +- .github/workflows/build.yml | 59 +++++++++++++++------ .github/workflows/release_documentation.yml | 28 +++++++--- .travis/get_project_version.sh | 6 +-- .travis/install.sh | 3 +- .travis/push_docs_to_github_io.sh | 4 +- .travis/update_project_version.sh | 2 +- .travis/validate_report_files.sh | 4 +- 8 files changed, 73 insertions(+), 37 deletions(-) diff --git a/.github/scripts/set_version_numbers_env.sh b/.github/scripts/set_version_numbers_env.sh index 8f463c49b..ea019ea07 100755 --- a/.github/scripts/set_version_numbers_env.sh +++ b/.github/scripts/set_version_numbers_env.sh @@ -1,10 +1,10 @@ #!/bin/bash -UTPLSQL_BUILD_NO=$( expr ${JOB_NUMBER} + ${UTPLSQL_BUILD_NO_OFFSET} ) +UTPLSQL_BUILD_NO=$( expr ${GITHUB_RUN_NUMBER} + ${UTPLSQL_BUILD_NO_OFFSET} ) UTPLSQL_VERSION=$(.travis/get_project_version.sh) echo "UTPLSQL_BUILD_NO=${UTPLSQL_BUILD_NO}" >> $GITHUB_ENV echo "UTPLSQL_VERSION=${UTPLSQL_VERSION}" >> $GITHUB_ENV echo UTPLSQL_BUILD_VERSION=$(echo ${UTPLSQL_VERSION} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/") >> $GITHUB_ENV -echo "CURRENT_BRANCH=${BRANCH_NAME}" >> $GITHUB_ENV +echo "CURRENT_BRANCH=${CI_ACTION_REF_NAME}" >> $GITHUB_ENV diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 16a5d7094..d09dbb8d4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,7 +1,4 @@ name: Build, test, deploy documentation -env: - BUILD_DIR: ${{github.workspace}} - JOB_NUMBER: ${{github.run_number}} on: push: @@ -12,7 +9,6 @@ on: workflow_dispatch: concurrency: ${{github.ref}} - defaults: run: shell: bash @@ -21,13 +17,12 @@ jobs: build-and-test: name: Build and test on ${{matrix.db_version_name}} DB + runs-on: ubuntu-latest env: ORACLE_VERSION: ${{matrix.oracle-version}} CONNECTION_STR: ${{matrix.connection-str}} ORACLE_PASSWORD: oracle DOCKER_VOLUME: ${{matrix.docker-volume}} - - runs-on: ubuntu-latest strategy: fail-fast: false matrix: @@ -67,9 +62,10 @@ jobs: image: ${{matrix.oracle-version}} env: ORACLE_PASSWORD: oracle -# credentials: -# username: ${{ secrets.DOCKER_USER }} -# password: ${{ secrets.DOCKER_PASSWORD }} + MATRIX_JOB_ID: ${{matrix.id}} + credentials: + username: ${{ secrets.DOCKER_USER }} + password: ${{ secrets.DOCKER_PASSWORD }} ports: - 1521:1521 options: >- @@ -82,11 +78,37 @@ jobs: - uses: actions/checkout@v2 with: fetch-depth: 0 - - uses: nelonoel/branch-name@v1.0.1 - uses: c-py/action-dotenv-to-setenv@v2 with: env-file: .github/variables/.env - + - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action + + - name: Print environment variables + run: | + echo "CI_REPOSITORY_SLUG=$CI_REPOSITORY_SLUG" + echo "CI_REPOSITORY_OWNER=$CI_REPOSITORY_OWNER" + echo "CI_REPOSITORY_OWNER_SLUG=$CI_REPOSITORY_OWNER_SLUG" + echo "CI_REPOSITORY_NAME=$CI_REPOSITORY_NAME" + echo "CI_REPOSITORY_NAME_SLUG=$CI_REPOSITORY_NAME_SLUG" + echo "CI_REPOSITORY=$CI_REPOSITORY" + echo "CI_REF_SLUG=$CI_REF_SLUG" + echo "CI_ACTION_REF_NAME=$CI_ACTION_REF_NAME" + echo "CI_ACTION_REF_NAME_SLUG=$CI_ACTION_REF_NAME_SLUG" + echo "CI_REF_NAME=$CI_REF_NAME" + echo "CI_REF_NAME_SLUG=$CI_REF_NAME_SLUG" + echo "CI_REF=$CI_REF" + echo "CI_HEAD_REF_SLUG=$CI_HEAD_REF_SLUG" + echo "CI_HEAD_REF=$CI_HEAD_REF" + echo "CI_BASE_REF_SLUG=$CI_BASE_REF_SLUG" + echo "CI_BASE_REF=$CI_BASE_REF" + echo "CI_SHA_SHORT=$CI_SHA_SHORT" + echo "CI_SHA=$CI_SHA" + echo "CI_ACTOR=$CI_ACTOR" + echo "CI_EVENT_NAME=$CI_EVENT_NAME" + echo "CI_RUN_ID=$CI_RUN_ID" + echo "CI_RUN_NUMBER=$CI_RUN_NUMBER" + echo "CI_WORKFLOW=$CI_WORKFLOW" + echo "CI_ACTION=$CI_ACTION" - name: Set build version number env variables id: set-build-version-number-vars @@ -147,19 +169,19 @@ jobs: concurrency: publish runs-on: ubuntu-latest if: | - ${{ github.repository == 'utPLSQL/utPLSQL' && github.base_ref == null - && ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' ) - }} + github.repository == 'utPLSQL/utPLSQL' && + github.base_ref == null && + ( startsWith( github.ref, 'refs/heads/release/v' ) || + github.ref == 'refs/heads/develop' ) steps: - uses: actions/checkout@v2 with: fetch-depth: 0 - #Populates the value of BRANCH_NAME env variable - - uses: nelonoel/branch-name@v1.0.1 - uses: c-py/action-dotenv-to-setenv@v2 with: env-file: .github/variables/.env + - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action - name: Set buid version number env variables id: set-build-version-number-vars @@ -171,7 +193,10 @@ jobs: - name: Push version update to repository id: push-version-number-update - run: .travis/push_project_version.sh + run: | + git add sonar-project.properties VERSION source/* docs/* + git commit -m 'Updated project version after build [skip ci]' + git push --quiet origin HEAD:${CI_ACTION_REF_NAME} - name: Copy and push documentation to utPLSQL-github-io repo id: push-documentation diff --git a/.github/workflows/release_documentation.yml b/.github/workflows/release_documentation.yml index fbf31a718..16412aa8f 100644 --- a/.github/workflows/release_documentation.yml +++ b/.github/workflows/release_documentation.yml @@ -1,7 +1,5 @@ name: Create and publish release artifacts env: - BUILD_DIR: ${{github.workspace}} - JOB_NUMBER: ${{github.run_number}} PULL_REQUEST_NAME: ${{github.head_ref}} PULL_REQUEST_BRANCH: ${{github.head_ref}} REPO_SLUG: ${{github.repository}} @@ -26,8 +24,10 @@ jobs: - uses: actions/checkout@v2 with: fetch-depth: 0 - - - uses: nelonoel/branch-name@v1.0.1 + - uses: c-py/action-dotenv-to-setenv@v2 + with: + env-file: .github/variables/.env + - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action - name: Set buid version number env variables run: .github/scripts/set_version_numbers_env.sh @@ -43,15 +43,27 @@ jobs: - name: Update project version & build number in source code and documentation run: .travis/update_project_version.sh - - name: Push version update to repository - run: .travis/push_project_version.sh - - name: Copy and push documentation to utPLSQL-github-io repo env: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} run: .travis/push_docs_to_github_io.sh -# TODO - add slack notifications + slack-workflow-status: + if: always() + name: Post Workflow Status To Slack + needs: [publish] + runs-on: ubuntu-latest + steps: + - name: Slack Workflow Notification + uses: Gamesight/slack-workflow-status@master + with: + # Required Input + repo_token: ${{secrets.GITHUB_TOKEN}} + slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} + # Optional Input + name: 'Github Actions[bot]' + icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' + # TODO - add building of release archive # TODO - add publishing of release diff --git a/.travis/get_project_version.sh b/.travis/get_project_version.sh index 20a658ed9..60fc0a796 100755 --- a/.travis/get_project_version.sh +++ b/.travis/get_project_version.sh @@ -1,13 +1,13 @@ #!/usr/bin/env bash #When building a new version from a release branch, the version is taken from release branch name -if [[ "${CURRENT_BRANCH}" =~ ^release/v[0-9]+\.[0-9]+\.[0-9]+.*$ ]]; then - version=${CURRENT_BRANCH#release\/} +if [[ "${CI_ACTION_REF_NAME}" =~ ^release/v[0-9]+\.[0-9]+\.[0-9]+.*$ ]]; then + version=${CI_ACTION_REF_NAME#release\/} else #Otherwise, version is taken from the VERSION file version=`cat VERSION` #When on develop branch, add "-develop" to the version text - if [[ "${CURRENT_BRANCH}" == "develop" ]]; then + if [[ "${CI_ACTION_REF_NAME}" == "develop" ]]; then version=`sed -E "s/(v?[0-9]+\.[0-9]+\.[0-9]+).*/\1-develop/" <<< "${version}"` fi fi diff --git a/.travis/install.sh b/.travis/install.sh index 603cb7d1e..4db64ccdb 100755 --- a/.travis/install.sh +++ b/.travis/install.sh @@ -20,8 +20,7 @@ alter session set plsql_optimize_level=0; @${INSTALL_FILE} $UT3_DEVELOP_SCHEMA $UT3_DEVELOP_SCHEMA_PASSWORD SQL -#Run this step only on second child job (12.1 - at it's fastest) -if [[ "${JOB_NUMBER}" =~ \.2$ ]]; then +if [[ "${MATRIX_JOB_ID}" == 1 ]]; then #check code-style for errors time "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @../development/utplsql_style_check.sql diff --git a/.travis/push_docs_to_github_io.sh b/.travis/push_docs_to_github_io.sh index 689cb99c9..83babbae7 100755 --- a/.travis/push_docs_to_github_io.sh +++ b/.travis/push_docs_to_github_io.sh @@ -78,9 +78,9 @@ if [ ! -f index.md ]; then fi #If build running on a TAG - it's a new release - need to add it to documentation if [ "${GITHUB_REF_TYPE}" == "tag" ]; then - sed -i '7s@.*@'" - [Latest ${CURRENT_BRANCH} documentation](latest/) - Created $now"'@' index.md + sed -i '7s@.*@'" - [Latest ${CI_ACTION_REF_NAME} documentation](latest/) - Created $now"'@' index.md #add entry to the top of version history (line end of file - ## Released Version Doc History - sed -i '12i'" - [${CURRENT_BRANCH} documentation](${UTPLSQL_VERSION}/) - Created $now" index.md + sed -i '12i'" - [${CI_ACTION_REF_NAME} documentation](${UTPLSQL_VERSION}/) - Created $now" index.md fi #replace 4th line in log sed -i '8s@.*@'" - [Latest development version](develop/) - Created $now"'@' index.md diff --git a/.travis/update_project_version.sh b/.travis/update_project_version.sh index bb6f72f00..586cb5b64 100755 --- a/.travis/update_project_version.sh +++ b/.travis/update_project_version.sh @@ -2,7 +2,7 @@ UTPLSQL_VERSION_PATTERN="v?([0-9]+\.){3}[0-9]+[^']*" -echo Current branch is "${CURRENT_BRANCH}" +echo Current branch is "${CI_ACTION_REF_NAME}" echo Update version in project source files find source -type f -name '*' -exec sed -i -r "s/${UTPLSQL_VERSION_PATTERN}/${UTPLSQL_BUILD_VERSION}/" {} \; diff --git a/.travis/validate_report_files.sh b/.travis/validate_report_files.sh index 7c7d1354d..e9479a42e 100755 --- a/.travis/validate_report_files.sh +++ b/.travis/validate_report_files.sh @@ -1,8 +1,8 @@ #!/usr/bin/env bash GL_VALID=1 -XSD_DIR="$BUILD_DIR/.travis/xsd" -XML_JAR_DIR="$BUILD_DIR/.travis/lib" +XSD_DIR=".travis/xsd" +XML_JAR_DIR=".travis/lib" #XML Validator XML_VALIDATOR="$XML_JAR_DIR/xml_validator.jar" HTML_VALIDATOR_URL="https://validator.w3.org/nu/" From 5b64836a255df7f69846ee7224db7ad1ded6e6e8 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 8 Jan 2022 01:17:09 +0200 Subject: [PATCH 184/887] Implementing Release Action --- .github/workflows/build.yml | 5 +- ...{release_documentation.yml => release.yml} | 57 ++++++++++++++----- .travis/build_docs.sh | 6 -- .travis/build_release_archive.sh | 18 ------ 4 files changed, 47 insertions(+), 39 deletions(-) rename .github/workflows/{release_documentation.yml => release.yml} (55%) delete mode 100755 .travis/build_docs.sh delete mode 100755 .travis/build_release_archive.sh diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d09dbb8d4..55df103ce 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -165,7 +165,7 @@ jobs: publish: name: Deploy documentation - needs: [build-and-test] + needs: [ build-and-test ] concurrency: publish runs-on: ubuntu-latest if: | @@ -207,7 +207,7 @@ jobs: slack-workflow-status: if: always() name: Post Workflow Status To Slack - needs: [build-and-test, publish] + needs: [ build-and-test, publish ] runs-on: ubuntu-latest steps: - name: Slack Workflow Notification @@ -219,3 +219,4 @@ jobs: # Optional Input name: 'Github Actions[bot]' icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' +#TODO - add triggering of builds on other repositories \ No newline at end of file diff --git a/.github/workflows/release_documentation.yml b/.github/workflows/release.yml similarity index 55% rename from .github/workflows/release_documentation.yml rename to .github/workflows/release.yml index 16412aa8f..eb8bf34b5 100644 --- a/.github/workflows/release_documentation.yml +++ b/.github/workflows/release.yml @@ -1,13 +1,7 @@ name: Create and publish release artifacts -env: - PULL_REQUEST_NAME: ${{github.head_ref}} - PULL_REQUEST_BRANCH: ${{github.head_ref}} - REPO_SLUG: ${{github.repository}} - PR_SLUG: ${{github.repository}} - on: release: - types: [ created ] + types: [ released ] #See: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions#example-using-multiple-events-with-activity-types-or-configuration defaults: @@ -17,6 +11,7 @@ defaults: jobs: publish: + name: Deploy documentation concurrency: publish runs-on: ubuntu-latest @@ -37,9 +32,6 @@ jobs: git config --global user.email "github-actions[bot]@users.noreply.github.com" git config --global user.name "github-actions[bot]" - - name: Install MkDocs - run: pip install mkdocs - - name: Update project version & build number in source code and documentation run: .travis/update_project_version.sh @@ -48,11 +40,52 @@ jobs: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} run: .travis/push_docs_to_github_io.sh + upload_artifacts: + name: Upload archives + concurrency: upload + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Update project version & build number in source code and documentation + run: .travis/update_project_version.sh + + - name: Setup git config + run: | + git config --global user.email "github-actions[bot]@users.noreply.github.com" + git config --global user.name "github-actions[bot]" + + - name: Build html documentation + run: | + pip install mkdocs + mkdocs build --clean --strict + rm -rf docs/* + cp -r -v site/* docs + git add . + git commit -m "tmp commit of HTML documentation for building a release archive" + + - name: Build release archives + run: | + git archive --prefix=utPLSQL/ -o utPLSQL.zip --format=zip HEAD + git archive --prefix=utPLSQL/ -o utPLSQL.tar.gz --format=tar.gz HEAD + md5sum utPLSQL.zip --tag > utPLSQL.zip.md5 + md5sum utPLSQL.tar.gz --tag > utPLSQL.tar.gz.md5 + + - name: Release + uses: softprops/action-gh-release@v1 + with: + files: | + utPLSQL.zip + utPLSQL.zip.md5 + utPLSQL.tar.gz + utPLSQL.tar.gz.md5 slack-workflow-status: if: always() name: Post Workflow Status To Slack - needs: [publish] + needs: [ publish, upload_artifacts ] runs-on: ubuntu-latest steps: - name: Slack Workflow Notification @@ -65,5 +98,3 @@ jobs: name: 'Github Actions[bot]' icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' -# TODO - add building of release archive -# TODO - add publishing of release diff --git a/.travis/build_docs.sh b/.travis/build_docs.sh deleted file mode 100755 index db43d7ca9..000000000 --- a/.travis/build_docs.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/bash -# Change working directory to script directory -cd "${0%/*}" -# Change back to root -cd .. -mkdocs build --clean --strict diff --git a/.travis/build_release_archive.sh b/.travis/build_release_archive.sh deleted file mode 100755 index 9667cba7e..000000000 --- a/.travis/build_release_archive.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/bash - -# remove markdown documentation -rm -rf docs/* -# and replace it with generated html documentation from the ignored site folder -cp -r -v site/* docs - -git add . -git commit -m "tmp commit for building a release archive" - -# git archive --prefix="utPLSQL${UTPLSQL_BUILD_VERSION}"/ -o "utPLSQL${UTPLSQL_BUILD_VERSION}".zip --format=zip HEAD -# git archive --prefix="utPLSQL${UTPLSQL_BUILD_VERSION}"/ -o "utPLSQL${UTPLSQL_BUILD_VERSION}".tar.gz --format=tar.gz HEAD - -git archive --prefix=utPLSQL/ -o utPLSQL.zip --format=zip HEAD -git archive --prefix=utPLSQL/ -o utPLSQL.tar.gz --format=tar.gz HEAD -md5sum utPLSQL.zip --tag > utPLSQL.zip.md5 -md5sum utPLSQL.tar.gz --tag > utPLSQL.tar.gz.md5 - From 28cdee35174e069113e3e22048fe53a52501a496 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 9 Jan 2022 01:20:28 +0200 Subject: [PATCH 185/887] Refactoring and adding dispatch of other repositories --- .gitattributes | 1 + .../scripts}/get_project_build_version.sh | 0 .../scripts}/get_project_version.sh | 0 {.travis => .github/scripts}/install.sh | 2 +- .../scripts}/install_utplsql_release.sh | 2 +- .../scripts}/lib/xml_validator.jar | Bin .../scripts}/push_docs_to_github_io.sh | 12 +-- .../scripts}/push_project_version.sh | 0 {.travis => .github/scripts}/run_examples.sh | 2 +- .github/scripts/set_version_numbers_env.sh | 2 +- .../scripts}/update_project_version.sh | 0 .../scripts}/validate_report_files.sh | 6 +- {.travis => .github/scripts}/xsd/junit4.xsd | 0 .../scripts}/xsd/junit_windy.xsd | 0 .github/workflows/build.yml | 93 ++++++++---------- .github/workflows/release.yml | 6 +- development/install.sh | 4 +- readme.md | 1 + 18 files changed, 64 insertions(+), 67 deletions(-) rename {.travis => .github/scripts}/get_project_build_version.sh (100%) rename {.travis => .github/scripts}/get_project_version.sh (100%) rename {.travis => .github/scripts}/install.sh (99%) rename {.travis => .github/scripts}/install_utplsql_release.sh (97%) rename {.travis => .github/scripts}/lib/xml_validator.jar (100%) rename {.travis => .github/scripts}/push_docs_to_github_io.sh (92%) rename {.travis => .github/scripts}/push_project_version.sh (100%) rename {.travis => .github/scripts}/run_examples.sh (87%) rename {.travis => .github/scripts}/update_project_version.sh (100%) rename {.travis => .github/scripts}/validate_report_files.sh (93%) rename {.travis => .github/scripts}/xsd/junit4.xsd (100%) rename {.travis => .github/scripts}/xsd/junit_windy.xsd (100%) diff --git a/.gitattributes b/.gitattributes index 9cf0f2457..abd1d5471 100644 --- a/.gitattributes +++ b/.gitattributes @@ -4,6 +4,7 @@ .travis.yml export-ignore mkdocs.yml export-ignore .travis export-ignore +.github export-ignore sonar-project.properties export-ignore tests export-ignore development export-ignore diff --git a/.travis/get_project_build_version.sh b/.github/scripts/get_project_build_version.sh similarity index 100% rename from .travis/get_project_build_version.sh rename to .github/scripts/get_project_build_version.sh diff --git a/.travis/get_project_version.sh b/.github/scripts/get_project_version.sh similarity index 100% rename from .travis/get_project_version.sh rename to .github/scripts/get_project_version.sh diff --git a/.travis/install.sh b/.github/scripts/install.sh similarity index 99% rename from .travis/install.sh rename to .github/scripts/install.sh index 4db64ccdb..095d33810 100755 --- a/.travis/install.sh +++ b/.github/scripts/install.sh @@ -2,7 +2,7 @@ set -ev SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" -cd ${SCRIPT_DIR}/../source +cd ${SCRIPT_DIR}/../../source INSTALL_FILE="install_headless_with_trigger.sql" if [[ ! -f "${INSTALL_FILE}" ]]; then diff --git a/.travis/install_utplsql_release.sh b/.github/scripts/install_utplsql_release.sh similarity index 97% rename from .travis/install_utplsql_release.sh rename to .github/scripts/install_utplsql_release.sh index fea162f8f..e50718c7b 100755 --- a/.travis/install_utplsql_release.sh +++ b/.github/scripts/install_utplsql_release.sh @@ -2,7 +2,7 @@ set -ev SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" -cd ${SCRIPT_DIR}/../${UTPLSQL_DIR}/source +cd ${SCRIPT_DIR}/../../${UTPLSQL_DIR}/source "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <>index.md echo "layout: default" >>index.md echo "---" >>index.md - echo "" >>index.md + echo "" >>index.md echo "# Documentation versions" >>index.md echo "" >>index.md echo "" >>index.md #- 7th line - placeholder for latest release doc diff --git a/.travis/push_project_version.sh b/.github/scripts/push_project_version.sh similarity index 100% rename from .travis/push_project_version.sh rename to .github/scripts/push_project_version.sh diff --git a/.travis/run_examples.sh b/.github/scripts/run_examples.sh similarity index 87% rename from .travis/run_examples.sh rename to .github/scripts/run_examples.sh index 8eb3d097f..bfa4f7e1a 100755 --- a/.travis/run_examples.sh +++ b/.github/scripts/run_examples.sh @@ -2,7 +2,7 @@ set -ev SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" -cd ${SCRIPT_DIR}/../examples +cd ${SCRIPT_DIR}/../../examples "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR <> $GITHUB_ENV echo "UTPLSQL_VERSION=${UTPLSQL_VERSION}" >> $GITHUB_ENV diff --git a/.travis/update_project_version.sh b/.github/scripts/update_project_version.sh similarity index 100% rename from .travis/update_project_version.sh rename to .github/scripts/update_project_version.sh diff --git a/.travis/validate_report_files.sh b/.github/scripts/validate_report_files.sh similarity index 93% rename from .travis/validate_report_files.sh rename to .github/scripts/validate_report_files.sh index e9479a42e..59376a174 100755 --- a/.travis/validate_report_files.sh +++ b/.github/scripts/validate_report_files.sh @@ -1,8 +1,10 @@ #!/usr/bin/env bash +SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" + GL_VALID=1 -XSD_DIR=".travis/xsd" -XML_JAR_DIR=".travis/lib" +XSD_DIR="${SCRIPT_DIR}/xsd" +XML_JAR_DIR="${SCRIPT_DIR}/lib" #XML Validator XML_VALIDATOR="$XML_JAR_DIR/xml_validator.jar" HTML_VALIDATOR_URL="https://validator.w3.org/nu/" diff --git a/.travis/xsd/junit4.xsd b/.github/scripts/xsd/junit4.xsd similarity index 100% rename from .travis/xsd/junit4.xsd rename to .github/scripts/xsd/junit4.xsd diff --git a/.travis/xsd/junit_windy.xsd b/.github/scripts/xsd/junit_windy.xsd similarity index 100% rename from .travis/xsd/junit_windy.xsd rename to .github/scripts/xsd/junit_windy.xsd diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 55df103ce..c05b81977 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,8 +1,7 @@ name: Build, test, deploy documentation - on: push: - branches: [ develop, feature/github_actions ] + branches-ignore: [ main ] pull_request: branches: [ develop ] @@ -15,7 +14,7 @@ defaults: jobs: - build-and-test: + build: name: Build and test on ${{matrix.db_version_name}} DB runs-on: ubuntu-latest env: @@ -83,43 +82,17 @@ jobs: env-file: .github/variables/.env - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action - - name: Print environment variables - run: | - echo "CI_REPOSITORY_SLUG=$CI_REPOSITORY_SLUG" - echo "CI_REPOSITORY_OWNER=$CI_REPOSITORY_OWNER" - echo "CI_REPOSITORY_OWNER_SLUG=$CI_REPOSITORY_OWNER_SLUG" - echo "CI_REPOSITORY_NAME=$CI_REPOSITORY_NAME" - echo "CI_REPOSITORY_NAME_SLUG=$CI_REPOSITORY_NAME_SLUG" - echo "CI_REPOSITORY=$CI_REPOSITORY" - echo "CI_REF_SLUG=$CI_REF_SLUG" - echo "CI_ACTION_REF_NAME=$CI_ACTION_REF_NAME" - echo "CI_ACTION_REF_NAME_SLUG=$CI_ACTION_REF_NAME_SLUG" - echo "CI_REF_NAME=$CI_REF_NAME" - echo "CI_REF_NAME_SLUG=$CI_REF_NAME_SLUG" - echo "CI_REF=$CI_REF" - echo "CI_HEAD_REF_SLUG=$CI_HEAD_REF_SLUG" - echo "CI_HEAD_REF=$CI_HEAD_REF" - echo "CI_BASE_REF_SLUG=$CI_BASE_REF_SLUG" - echo "CI_BASE_REF=$CI_BASE_REF" - echo "CI_SHA_SHORT=$CI_SHA_SHORT" - echo "CI_SHA=$CI_SHA" - echo "CI_ACTOR=$CI_ACTOR" - echo "CI_EVENT_NAME=$CI_EVENT_NAME" - echo "CI_RUN_ID=$CI_RUN_ID" - echo "CI_RUN_NUMBER=$CI_RUN_NUMBER" - echo "CI_WORKFLOW=$CI_WORKFLOW" - echo "CI_ACTION=$CI_ACTION" - - name: Set build version number env variables id: set-build-version-number-vars run: .github/scripts/set_version_numbers_env.sh - name: Update project version & build number to verify that code is deployable after the update id: update-project-version - run: .travis/update_project_version.sh + run: .github/scripts/update_project_version.sh - - name: Download latest utPLSQL release - run: git clone --depth=1 --branch=main https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR + - name: Download utPLSQL release for testing +# For PR build - test using target branch as framework, for branch build use self as testing framework + run: git clone --depth=1 --branch=${CI_HEAD_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR - name: Update privileges on sources run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} @@ -134,19 +107,19 @@ jobs: - name: Install utPLSQL id: install-utplsql - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .travis/install.sh + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh - name: Install utPLSQL release id: install-utplsql-release - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/install_utplsql_release.sh + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install_utplsql_release.sh - name: Run Examples id: run-examples - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./.travis/run_examples.sh + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/run_examples.sh - name: Install tests id: install-tests - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} ./test/install_tests.sh + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} test/install_tests.sh - name: Run Tests id: run-tests @@ -154,7 +127,7 @@ jobs: - name: Validate utPLSQL reports format id: validate-reports-format - run: bash .travis/validate_report_files.sh + run: bash .github/scripts/validate_report_files.sh - name: SonarCloud Scan id: sonar @@ -165,15 +138,16 @@ jobs: publish: name: Deploy documentation - needs: [ build-and-test ] + needs: [ build ] concurrency: publish runs-on: ubuntu-latest if: | github.repository == 'utPLSQL/utPLSQL' && github.base_ref == null && - ( startsWith( github.ref, 'refs/heads/release/v' ) || - github.ref == 'refs/heads/develop' ) - + ( startsWith( github.ref, 'refs/heads/release/v' ) + || github.ref == 'refs/heads/develop' + || github.ref == 'refs/heads/feature/github_actions' + ) steps: - uses: actions/checkout@v2 with: @@ -182,32 +156,52 @@ jobs: with: env-file: .github/variables/.env - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action - - name: Set buid version number env variables id: set-build-version-number-vars run: .github/scripts/set_version_numbers_env.sh - - name: Update project version & build number in source code and documentation id: update-project-version - run: .travis/update_project_version.sh - + run: .github/scripts/update_project_version.sh - name: Push version update to repository id: push-version-number-update run: | git add sonar-project.properties VERSION source/* docs/* git commit -m 'Updated project version after build [skip ci]' git push --quiet origin HEAD:${CI_ACTION_REF_NAME} - - name: Copy and push documentation to utPLSQL-github-io repo id: push-documentation env: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} - run: .travis/push_docs_to_github_io.sh + run: .github/scripts/push_docs_to_github_io.sh + + dispatch: + name: Dispatch downstream builds + concurrency: trigger + needs: [ build, publish ] + runs-on: ubuntu-latest + if: | + github.repository == 'utPLSQL/utPLSQL' && + github.base_ref == null && + ( startsWith( github.ref, 'refs/heads/release/v' ) + || github.ref == 'refs/heads/develop' + || github.ref == 'refs/heads/feature/github_actions' + ) + strategy: + matrix: + repo: ['utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project'] +# repo: ['utPLSQL/utPLSQL-java-api', 'utPLSQL/utPLSQL-v2-v3-migration', 'utPLSQL/utPLSQL-cli', 'utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project'] + steps: + - name: Repository Dispatch + uses: peter-evans/repository-dispatch@v1 + with: + token: ${{ secrets.API_TOKEN_GITHUB }} + repository: ${{ matrix.repo }} + event-type: utPLSQL-build slack-workflow-status: if: always() name: Post Workflow Status To Slack - needs: [ build-and-test, publish ] + needs: [ build, publish, dispatch ] runs-on: ubuntu-latest steps: - name: Slack Workflow Notification @@ -219,4 +213,3 @@ jobs: # Optional Input name: 'Github Actions[bot]' icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' -#TODO - add triggering of builds on other repositories \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index eb8bf34b5..3d1ecb6b8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -33,12 +33,12 @@ jobs: git config --global user.name "github-actions[bot]" - name: Update project version & build number in source code and documentation - run: .travis/update_project_version.sh + run: .github/scripts/update_project_version.sh - name: Copy and push documentation to utPLSQL-github-io repo env: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} - run: .travis/push_docs_to_github_io.sh + run: .github/scripts/push_docs_to_github_io.sh upload_artifacts: name: Upload archives @@ -50,7 +50,7 @@ jobs: with: fetch-depth: 0 - name: Update project version & build number in source code and documentation - run: .travis/update_project_version.sh + run: .github/scripts/update_project_version.sh - name: Setup git config run: | diff --git a/development/install.sh b/development/install.sh index ff112392f..627bd113d 100755 --- a/development/install.sh +++ b/development/install.sh @@ -10,11 +10,11 @@ if ! development/cleanup.sh; then echo -e ${header}"\nFailed to cleanup utPLSQL environment\n"${header} exit 1 fi -if ! .travis/install.sh; then +if ! .github/scripts/install.sh; then echo -e ${header}"\nFailed to install utPLSQL from current branch into ${UT3_DEVELOP_SCHEMA} schema\n"${header} exit 1 fi -if ! .travis/install_utplsql_release.sh; then +if ! .github/scripts/install_utplsql_release.sh; then echo -e ${header}"\nFailed to install utPLSQL from branch ${SELFTESTING_BRANCH} into ${UT3_RELEASE_VERSION_SCHEMA}\n"${header} exit 1 fi diff --git a/readme.md b/readme.md index 0928f2b95..b3a12d5d6 100644 --- a/readme.md +++ b/readme.md @@ -172,6 +172,7 @@ To sign up to the chat use [this link](https://join.slack.com/t/utplsql/shared_i ---------- __Project Directories__ +* .github - contains files needed for github Actions integration * .travis - contains files needed for travis-ci integration * client_source - Sources to be used on the client-side. Developer workstation or CI platform to run the tests. * development - Set of useful scripts and utilities for development and debugging of utPLSQL From 0e6eb7077727b977081fcb90dac1151e5f4f90aa Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 9 Jan 2022 02:55:40 +0200 Subject: [PATCH 186/887] Testing triggering of build process on other repositories --- .github/workflows/build.yml | 352 ++++++++++++++++++------------------ 1 file changed, 176 insertions(+), 176 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c05b81977..231137bcb 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -14,170 +14,170 @@ defaults: jobs: - build: - name: Build and test on ${{matrix.db_version_name}} DB - runs-on: ubuntu-latest - env: - ORACLE_VERSION: ${{matrix.oracle-version}} - CONNECTION_STR: ${{matrix.connection-str}} - ORACLE_PASSWORD: oracle - DOCKER_VOLUME: ${{matrix.docker-volume}} - strategy: - fail-fast: false - matrix: - include: - - oracle-version: "gvenzl/oracle-xe:11-full" - connection-str: '127.0.0.1:1521/XE' - id: 1 - db_version_name: '11xe' -# TODO - need to add healthcheck.sh into our containers -# - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" -# connection-str: '127.0.0.1:1521/ORCLCDB' -# id: 2 -# db_version_name: '12.1se' -# - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" -# connection-str: '127.0.0.1:1521/ORCLCDB' -# id: 3 -# db_version_name: '12.2se' - - oracle-version: "gvenzl/oracle-xe:18-slim" - connection-str: '127.0.0.1:1521/XE' - id: 4 - db_version_name: '18xe' -# - oracle-version: "utplsqlv3/oracledb:18c-se2-small" -# connection-str: '127.0.0.1:1521/ORCLCDB' -# id: 5 -# db_version_name: '18se' -# - oracle-version: "utplsqlv3/oracledb:19c-se2-small" -# connection-str: '127.0.0.1:1521/ORCLCDB' -# id: 6 -# db_version_name: '19se' - - oracle-version: "gvenzl/oracle-xe:21-slim" - connection-str: '127.0.0.1:1521/XE' - id: 7 - db_version_name: '21xe' - - services: - oracle: - image: ${{matrix.oracle-version}} - env: - ORACLE_PASSWORD: oracle - MATRIX_JOB_ID: ${{matrix.id}} - credentials: - username: ${{ secrets.DOCKER_USER }} - password: ${{ secrets.DOCKER_PASSWORD }} - ports: - - 1521:1521 - options: >- - --health-cmd healthcheck.sh - --health-interval 10s - --health-timeout 5s - --health-retries 10 - - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - uses: c-py/action-dotenv-to-setenv@v2 - with: - env-file: .github/variables/.env - - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action - - - name: Set build version number env variables - id: set-build-version-number-vars - run: .github/scripts/set_version_numbers_env.sh - - - name: Update project version & build number to verify that code is deployable after the update - id: update-project-version - run: .github/scripts/update_project_version.sh - - - name: Download utPLSQL release for testing -# For PR build - test using target branch as framework, for branch build use self as testing framework - run: git clone --depth=1 --branch=${CI_HEAD_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR - - - name: Update privileges on sources - run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} - - - name: Add OJDBC home - id: get-ojdbc - run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar - - - name: Install utPLSQL-cli - id: install-utplsql-cli - run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli - - - name: Install utPLSQL - id: install-utplsql - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh - - - name: Install utPLSQL release - id: install-utplsql-release - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install_utplsql_release.sh - - - name: Run Examples - id: run-examples - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/run_examples.sh - - - name: Install tests - id: install-tests - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} test/install_tests.sh - - - name: Run Tests - id: run-tests - run: bash test/run_tests.sh - - - name: Validate utPLSQL reports format - id: validate-reports-format - run: bash .github/scripts/validate_report_files.sh - - - name: SonarCloud Scan - id: sonar - uses: SonarSource/sonarcloud-github-action@master - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - - publish: - name: Deploy documentation - needs: [ build ] - concurrency: publish - runs-on: ubuntu-latest - if: | - github.repository == 'utPLSQL/utPLSQL' && - github.base_ref == null && - ( startsWith( github.ref, 'refs/heads/release/v' ) - || github.ref == 'refs/heads/develop' - || github.ref == 'refs/heads/feature/github_actions' - ) - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - uses: c-py/action-dotenv-to-setenv@v2 - with: - env-file: .github/variables/.env - - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action - - name: Set buid version number env variables - id: set-build-version-number-vars - run: .github/scripts/set_version_numbers_env.sh - - name: Update project version & build number in source code and documentation - id: update-project-version - run: .github/scripts/update_project_version.sh - - name: Push version update to repository - id: push-version-number-update - run: | - git add sonar-project.properties VERSION source/* docs/* - git commit -m 'Updated project version after build [skip ci]' - git push --quiet origin HEAD:${CI_ACTION_REF_NAME} - - name: Copy and push documentation to utPLSQL-github-io repo - id: push-documentation - env: - API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} - run: .github/scripts/push_docs_to_github_io.sh +# build: +# name: Build and test on ${{matrix.db_version_name}} DB +# runs-on: ubuntu-latest +# env: +# ORACLE_VERSION: ${{matrix.oracle-version}} +# CONNECTION_STR: ${{matrix.connection-str}} +# ORACLE_PASSWORD: oracle +# DOCKER_VOLUME: ${{matrix.docker-volume}} +# strategy: +# fail-fast: false +# matrix: +# include: +# - oracle-version: "gvenzl/oracle-xe:11-full" +# connection-str: '127.0.0.1:1521/XE' +# id: 1 +# db_version_name: '11xe' +## TODO - need to add healthcheck.sh into our containers +## - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" +## connection-str: '127.0.0.1:1521/ORCLCDB' +## id: 2 +## db_version_name: '12.1se' +## - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" +## connection-str: '127.0.0.1:1521/ORCLCDB' +## id: 3 +## db_version_name: '12.2se' +# - oracle-version: "gvenzl/oracle-xe:18-slim" +# connection-str: '127.0.0.1:1521/XE' +# id: 4 +# db_version_name: '18xe' +## - oracle-version: "utplsqlv3/oracledb:18c-se2-small" +## connection-str: '127.0.0.1:1521/ORCLCDB' +## id: 5 +## db_version_name: '18se' +## - oracle-version: "utplsqlv3/oracledb:19c-se2-small" +## connection-str: '127.0.0.1:1521/ORCLCDB' +## id: 6 +## db_version_name: '19se' +# - oracle-version: "gvenzl/oracle-xe:21-slim" +# connection-str: '127.0.0.1:1521/XE' +# id: 7 +# db_version_name: '21xe' +# +# services: +# oracle: +# image: ${{matrix.oracle-version}} +# env: +# ORACLE_PASSWORD: oracle +# MATRIX_JOB_ID: ${{matrix.id}} +# credentials: +# username: ${{ secrets.DOCKER_USER }} +# password: ${{ secrets.DOCKER_PASSWORD }} +# ports: +# - 1521:1521 +# options: >- +# --health-cmd healthcheck.sh +# --health-interval 10s +# --health-timeout 5s +# --health-retries 10 +# +# steps: +# - uses: actions/checkout@v2 +# with: +# fetch-depth: 0 +# - uses: c-py/action-dotenv-to-setenv@v2 +# with: +# env-file: .github/variables/.env +# - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action +# +# - name: Set build version number env variables +# id: set-build-version-number-vars +# run: .github/scripts/set_version_numbers_env.sh +# +# - name: Update project version & build number to verify that code is deployable after the update +# id: update-project-version +# run: .github/scripts/update_project_version.sh +# +# - name: Download utPLSQL release for testing +## For PR build - test using target branch as framework, for branch build use self as testing framework +# run: git clone --depth=1 --branch=${CI_HEAD_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR +# +# - name: Update privileges on sources +# run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} +# +# - name: Add OJDBC home +# id: get-ojdbc +# run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar +# +# - name: Install utPLSQL-cli +# id: install-utplsql-cli +# run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli +# +# - name: Install utPLSQL +# id: install-utplsql +# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh +# +# - name: Install utPLSQL release +# id: install-utplsql-release +# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install_utplsql_release.sh +# +# - name: Run Examples +# id: run-examples +# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/run_examples.sh +# +# - name: Install tests +# id: install-tests +# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} test/install_tests.sh +# +# - name: Run Tests +# id: run-tests +# run: bash test/run_tests.sh +# +# - name: Validate utPLSQL reports format +# id: validate-reports-format +# run: bash .github/scripts/validate_report_files.sh +# +# - name: SonarCloud Scan +# id: sonar +# uses: SonarSource/sonarcloud-github-action@master +# env: +# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any +# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} +# +# publish: +# name: Deploy documentation +# needs: [ build ] +# concurrency: publish +# runs-on: ubuntu-latest +# if: | +# github.repository == 'utPLSQL/utPLSQL' && +# github.base_ref == null && +# ( startsWith( github.ref, 'refs/heads/release/v' ) +# || github.ref == 'refs/heads/develop' +# || github.ref == 'refs/heads/feature/github_actions' +# ) +# steps: +# - uses: actions/checkout@v2 +# with: +# fetch-depth: 0 +# - uses: c-py/action-dotenv-to-setenv@v2 +# with: +# env-file: .github/variables/.env +# - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action +# - name: Set buid version number env variables +# id: set-build-version-number-vars +# run: .github/scripts/set_version_numbers_env.sh +# - name: Update project version & build number in source code and documentation +# id: update-project-version +# run: .github/scripts/update_project_version.sh +# - name: Push version update to repository +# id: push-version-number-update +# run: | +# git add sonar-project.properties VERSION source/* docs/* +# git commit -m 'Updated project version after build [skip ci]' +# git push --quiet origin HEAD:${CI_ACTION_REF_NAME} +# - name: Copy and push documentation to utPLSQL-github-io repo +# id: push-documentation +# env: +# API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} +# run: .github/scripts/push_docs_to_github_io.sh dispatch: name: Dispatch downstream builds concurrency: trigger - needs: [ build, publish ] +# needs: [ build, publish ] runs-on: ubuntu-latest if: | github.repository == 'utPLSQL/utPLSQL' && @@ -195,21 +195,21 @@ jobs: uses: peter-evans/repository-dispatch@v1 with: token: ${{ secrets.API_TOKEN_GITHUB }} - repository: ${{ matrix.repo }} + repository: ${{ matrix.repo }} event-type: utPLSQL-build - slack-workflow-status: - if: always() - name: Post Workflow Status To Slack - needs: [ build, publish, dispatch ] - runs-on: ubuntu-latest - steps: - - name: Slack Workflow Notification - uses: Gamesight/slack-workflow-status@master - with: - # Required Input - repo_token: ${{secrets.GITHUB_TOKEN}} - slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} - # Optional Input - name: 'Github Actions[bot]' - icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' +# slack-workflow-status: +# if: always() +# name: Post Workflow Status To Slack +# needs: [ build, publish, dispatch ] +# runs-on: ubuntu-latest +# steps: +# - name: Slack Workflow Notification +# uses: Gamesight/slack-workflow-status@master +# with: +# # Required Input +# repo_token: ${{secrets.GITHUB_TOKEN}} +# slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} +# # Optional Input +# name: 'Github Actions[bot]' +# icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' From 06f35569d226984d6d929082d9f00a4ee4efc09e Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 10 Jan 2022 10:43:16 +0200 Subject: [PATCH 187/887] Enabling build and slack notification --- .github/workflows/build.yml | 348 ++++++++++++++++++------------------ 1 file changed, 174 insertions(+), 174 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 231137bcb..b09f4de53 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -14,165 +14,165 @@ defaults: jobs: -# build: -# name: Build and test on ${{matrix.db_version_name}} DB -# runs-on: ubuntu-latest -# env: -# ORACLE_VERSION: ${{matrix.oracle-version}} -# CONNECTION_STR: ${{matrix.connection-str}} -# ORACLE_PASSWORD: oracle -# DOCKER_VOLUME: ${{matrix.docker-volume}} -# strategy: -# fail-fast: false -# matrix: -# include: -# - oracle-version: "gvenzl/oracle-xe:11-full" -# connection-str: '127.0.0.1:1521/XE' -# id: 1 -# db_version_name: '11xe' -## TODO - need to add healthcheck.sh into our containers -## - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" -## connection-str: '127.0.0.1:1521/ORCLCDB' -## id: 2 -## db_version_name: '12.1se' -## - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" -## connection-str: '127.0.0.1:1521/ORCLCDB' -## id: 3 -## db_version_name: '12.2se' -# - oracle-version: "gvenzl/oracle-xe:18-slim" -# connection-str: '127.0.0.1:1521/XE' -# id: 4 -# db_version_name: '18xe' -## - oracle-version: "utplsqlv3/oracledb:18c-se2-small" -## connection-str: '127.0.0.1:1521/ORCLCDB' -## id: 5 -## db_version_name: '18se' -## - oracle-version: "utplsqlv3/oracledb:19c-se2-small" -## connection-str: '127.0.0.1:1521/ORCLCDB' -## id: 6 -## db_version_name: '19se' -# - oracle-version: "gvenzl/oracle-xe:21-slim" -# connection-str: '127.0.0.1:1521/XE' -# id: 7 -# db_version_name: '21xe' -# -# services: -# oracle: -# image: ${{matrix.oracle-version}} -# env: -# ORACLE_PASSWORD: oracle -# MATRIX_JOB_ID: ${{matrix.id}} -# credentials: -# username: ${{ secrets.DOCKER_USER }} -# password: ${{ secrets.DOCKER_PASSWORD }} -# ports: -# - 1521:1521 -# options: >- -# --health-cmd healthcheck.sh -# --health-interval 10s -# --health-timeout 5s -# --health-retries 10 -# -# steps: -# - uses: actions/checkout@v2 -# with: -# fetch-depth: 0 -# - uses: c-py/action-dotenv-to-setenv@v2 -# with: -# env-file: .github/variables/.env -# - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action -# -# - name: Set build version number env variables -# id: set-build-version-number-vars -# run: .github/scripts/set_version_numbers_env.sh -# -# - name: Update project version & build number to verify that code is deployable after the update -# id: update-project-version -# run: .github/scripts/update_project_version.sh -# -# - name: Download utPLSQL release for testing -## For PR build - test using target branch as framework, for branch build use self as testing framework -# run: git clone --depth=1 --branch=${CI_HEAD_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR -# -# - name: Update privileges on sources -# run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} -# -# - name: Add OJDBC home -# id: get-ojdbc -# run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar -# -# - name: Install utPLSQL-cli -# id: install-utplsql-cli -# run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli -# -# - name: Install utPLSQL -# id: install-utplsql -# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh -# -# - name: Install utPLSQL release -# id: install-utplsql-release -# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install_utplsql_release.sh -# -# - name: Run Examples -# id: run-examples -# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/run_examples.sh -# -# - name: Install tests -# id: install-tests -# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} test/install_tests.sh -# -# - name: Run Tests -# id: run-tests -# run: bash test/run_tests.sh -# -# - name: Validate utPLSQL reports format -# id: validate-reports-format -# run: bash .github/scripts/validate_report_files.sh -# -# - name: SonarCloud Scan -# id: sonar -# uses: SonarSource/sonarcloud-github-action@master -# env: -# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any -# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} -# -# publish: -# name: Deploy documentation -# needs: [ build ] -# concurrency: publish -# runs-on: ubuntu-latest -# if: | -# github.repository == 'utPLSQL/utPLSQL' && -# github.base_ref == null && -# ( startsWith( github.ref, 'refs/heads/release/v' ) -# || github.ref == 'refs/heads/develop' -# || github.ref == 'refs/heads/feature/github_actions' -# ) -# steps: -# - uses: actions/checkout@v2 -# with: -# fetch-depth: 0 -# - uses: c-py/action-dotenv-to-setenv@v2 -# with: -# env-file: .github/variables/.env -# - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action -# - name: Set buid version number env variables -# id: set-build-version-number-vars -# run: .github/scripts/set_version_numbers_env.sh -# - name: Update project version & build number in source code and documentation -# id: update-project-version -# run: .github/scripts/update_project_version.sh -# - name: Push version update to repository -# id: push-version-number-update -# run: | -# git add sonar-project.properties VERSION source/* docs/* -# git commit -m 'Updated project version after build [skip ci]' -# git push --quiet origin HEAD:${CI_ACTION_REF_NAME} -# - name: Copy and push documentation to utPLSQL-github-io repo -# id: push-documentation -# env: -# API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} -# run: .github/scripts/push_docs_to_github_io.sh + build: + name: Build and test on ${{matrix.db_version_name}} DB + runs-on: ubuntu-latest + env: + ORACLE_VERSION: ${{matrix.oracle-version}} + CONNECTION_STR: ${{matrix.connection-str}} + ORACLE_PASSWORD: oracle + DOCKER_VOLUME: ${{matrix.docker-volume}} + strategy: + fail-fast: false + matrix: + include: + - oracle-version: "gvenzl/oracle-xe:11-full" + connection-str: '127.0.0.1:1521/XE' + id: 1 + db_version_name: '11xe' +# TODO - need to add healthcheck.sh into our containers +# - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' +# id: 2 +# db_version_name: '12.1se' +# - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' +# id: 3 +# db_version_name: '12.2se' + - oracle-version: "gvenzl/oracle-xe:18-slim" + connection-str: '127.0.0.1:1521/XE' + id: 4 + db_version_name: '18xe' +# - oracle-version: "utplsqlv3/oracledb:18c-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' +# id: 5 +# db_version_name: '18se' +# - oracle-version: "utplsqlv3/oracledb:19c-se2-small" +# connection-str: '127.0.0.1:1521/ORCLCDB' +# id: 6 +# db_version_name: '19se' + - oracle-version: "gvenzl/oracle-xe:21-slim" + connection-str: '127.0.0.1:1521/XE' + id: 7 + db_version_name: '21xe' + + services: + oracle: + image: ${{matrix.oracle-version}} + env: + ORACLE_PASSWORD: oracle + MATRIX_JOB_ID: ${{matrix.id}} + credentials: + username: ${{ secrets.DOCKER_USER }} + password: ${{ secrets.DOCKER_PASSWORD }} + ports: + - 1521:1521 + options: >- + --health-cmd healthcheck.sh + --health-interval 10s + --health-timeout 5s + --health-retries 10 + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: c-py/action-dotenv-to-setenv@v2 + with: + env-file: .github/variables/.env + - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action + + - name: Set build version number env variables + id: set-build-version-number-vars + run: .github/scripts/set_version_numbers_env.sh + + - name: Update project version & build number to verify that code is deployable after the update + id: update-project-version + run: .github/scripts/update_project_version.sh + + - name: Download utPLSQL release for testing +# For PR build - test using target branch as framework, for branch build use self as testing framework + run: git clone --depth=1 --branch=${CI_HEAD_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR + + - name: Update privileges on sources + run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} + + - name: Add OJDBC home + id: get-ojdbc + run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar + + - name: Install utPLSQL-cli + id: install-utplsql-cli + run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli + + - name: Install utPLSQL + id: install-utplsql + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh + + - name: Install utPLSQL release + id: install-utplsql-release + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install_utplsql_release.sh + + - name: Run Examples + id: run-examples + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/run_examples.sh + + - name: Install tests + id: install-tests + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} test/install_tests.sh + + - name: Run Tests + id: run-tests + run: bash test/run_tests.sh + + - name: Validate utPLSQL reports format + id: validate-reports-format + run: bash .github/scripts/validate_report_files.sh + + - name: SonarCloud Scan + id: sonar + uses: SonarSource/sonarcloud-github-action@master + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + + publish: + name: Deploy documentation + needs: [ build ] + concurrency: publish + runs-on: ubuntu-latest + if: | + github.repository == 'utPLSQL/utPLSQL' && + github.base_ref == null && + ( startsWith( github.ref, 'refs/heads/release/v' ) + || github.ref == 'refs/heads/develop' + || github.ref == 'refs/heads/feature/github_actions' + ) + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: c-py/action-dotenv-to-setenv@v2 + with: + env-file: .github/variables/.env + - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action + - name: Set buid version number env variables + id: set-build-version-number-vars + run: .github/scripts/set_version_numbers_env.sh + - name: Update project version & build number in source code and documentation + id: update-project-version + run: .github/scripts/update_project_version.sh + - name: Push version update to repository + id: push-version-number-update + run: | + git add sonar-project.properties VERSION source/* docs/* + git commit -m 'Updated project version after build [skip ci]' + git push --quiet origin HEAD:${CI_ACTION_REF_NAME} + - name: Copy and push documentation to utPLSQL-github-io repo + id: push-documentation + env: + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} + run: .github/scripts/push_docs_to_github_io.sh dispatch: name: Dispatch downstream builds @@ -198,18 +198,18 @@ jobs: repository: ${{ matrix.repo }} event-type: utPLSQL-build -# slack-workflow-status: -# if: always() -# name: Post Workflow Status To Slack -# needs: [ build, publish, dispatch ] -# runs-on: ubuntu-latest -# steps: -# - name: Slack Workflow Notification -# uses: Gamesight/slack-workflow-status@master -# with: -# # Required Input -# repo_token: ${{secrets.GITHUB_TOKEN}} -# slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} -# # Optional Input -# name: 'Github Actions[bot]' -# icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' + slack-workflow-status: + if: always() + name: Post Workflow Status To Slack + needs: [ build, publish, dispatch ] + runs-on: ubuntu-latest + steps: + - name: Slack Workflow Notification + uses: Gamesight/slack-workflow-status@master + with: + # Required Input + repo_token: ${{secrets.GITHUB_TOKEN}} + slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} + # Optional Input + name: 'Github Actions[bot]' + icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' From 6cd8b16c19dd1ef6664c63805e289191d710e1fd Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 10 Jan 2022 10:44:21 +0200 Subject: [PATCH 188/887] Update documentation publish condition --- .github/workflows/build.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b09f4de53..25e24259d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -144,10 +144,7 @@ jobs: if: | github.repository == 'utPLSQL/utPLSQL' && github.base_ref == null && - ( startsWith( github.ref, 'refs/heads/release/v' ) - || github.ref == 'refs/heads/develop' - || github.ref == 'refs/heads/feature/github_actions' - ) + ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' ) steps: - uses: actions/checkout@v2 with: From 1fc87de3500301c4f81fcb0fac2c3bcc26db5335 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 10 Jan 2022 10:45:58 +0200 Subject: [PATCH 189/887] Enable dependency on downstream job dispatch --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 25e24259d..a19e638b3 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -174,7 +174,7 @@ jobs: dispatch: name: Dispatch downstream builds concurrency: trigger -# needs: [ build, publish ] + needs: [ build, publish ] runs-on: ubuntu-latest if: | github.repository == 'utPLSQL/utPLSQL' && From 31cc42dda3497a7a57a5c3f14d36cb6442b14fd8 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 13 Jan 2022 23:35:56 +0200 Subject: [PATCH 190/887] Final cleanup of travis build leftovers. --- .github/workflows/build.yml | 10 +-- .github/workflows/release.yml | 2 - .travis/trigger_travis.sh | 69 --------------- old.travis.yml | 153 ---------------------------------- 4 files changed, 2 insertions(+), 232 deletions(-) delete mode 100755 .travis/trigger_travis.sh delete mode 100644 old.travis.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a19e638b3..8c72e5043 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -177,12 +177,8 @@ jobs: needs: [ build, publish ] runs-on: ubuntu-latest if: | - github.repository == 'utPLSQL/utPLSQL' && - github.base_ref == null && - ( startsWith( github.ref, 'refs/heads/release/v' ) - || github.ref == 'refs/heads/develop' - || github.ref == 'refs/heads/feature/github_actions' - ) + github.repository == 'utPLSQL/utPLSQL' && github.base_ref == null && + ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' ) strategy: matrix: repo: ['utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project'] @@ -204,9 +200,7 @@ jobs: - name: Slack Workflow Notification uses: Gamesight/slack-workflow-status@master with: - # Required Input repo_token: ${{secrets.GITHUB_TOKEN}} slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} - # Optional Input name: 'Github Actions[bot]' icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3d1ecb6b8..ad1e782c5 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -91,10 +91,8 @@ jobs: - name: Slack Workflow Notification uses: Gamesight/slack-workflow-status@master with: - # Required Input repo_token: ${{secrets.GITHUB_TOKEN}} slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} - # Optional Input name: 'Github Actions[bot]' icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' diff --git a/.travis/trigger_travis.sh b/.travis/trigger_travis.sh deleted file mode 100755 index 10083dd89..000000000 --- a/.travis/trigger_travis.sh +++ /dev/null @@ -1,69 +0,0 @@ -#!/bin/bash - -# Trigger a new Travis-CI job. -# Ordinarily, a new Travis job is triggered when a commit is pushed to a -# GitHub repository. The trigger-travis.sh script provides a programmatic -# way to trigger a new Travis job. - -# To use this script to trigger a dependent build in Travis, do two things: -# -# 1. Set an environment variable TRAVIS_ACCESS_TOKEN by navigating to -# https://travis-ci.org/MYGITHUBID/MYGITHUBPROJECT/settings -# The TRAVIS_ACCESS_TOKEN environment variable will be set when Travis runs -# the job, but won't be visible to anyone browsing https://travis-ci.org/. -# - -echoerr() { echo "$@" 1>&2; } - -TRAVIS_URL=travis-ci.com -BRANCH=develop -USER="utPLSQL" -RESULT=1 -declare -a REPO_MATRIX=("utPLSQL-java-api" "utPLSQL-v2-v3-migration" "utPLSQL-cli" "utPLSQL-maven-plugin" "utPLSQL-demo-project") - -TOKEN=$1 - -if [ -n "$TRAVIS_REPO_SLUG" ] ; then - MESSAGE=",\"message\": \"Triggered by upstream build of $TRAVIS_REPO_SLUG commit "`git rev-parse --short HEAD`"\"" -else - MESSAGE=",\"message\": \"Triggered manually from shell\"" -fi - -# For debugging: -#echo "MESSAGE=$MESSAGE" - -body="{ -\"request\": { - \"branch\":\"$BRANCH\" - $MESSAGE -}}" - -for DOWNSTREAM_BUILD in "${REPO_MATRIX[@]}"; do - - curl -s -X POST \ - -H "Content-Type: application/json" \ - -H "Accept: application/json" \ - -H "Travis-API-Version: 3" \ - -H "Authorization: token ${TOKEN}" \ - -d "$body" \ - https://api.${TRAVIS_URL}/repo/${USER}%2F${DOWNSTREAM_BUILD}/requests \ - | tee ${DOWNSTREAM_BUILD}-output.txt - - if grep -q '"@type": "error"' ${DOWNSTREAM_BUILD}-output.txt; then - RESULT=0 - echoerr "" - echoerr "ERROR: Failed to start ${DOWNSTREAM_BUILD}" - echoerr "" - fi - if grep -q 'access denied' ${DOWNSTREAM_BUILD}-output.txt; then - RESULT=0 - echoerr "" - echoerr "ERROR: Failed to start ${DOWNSTREAM_BUILD} - access denied" - echoerr "" - fi - -done - -if [[ RESULT -eq 0 ]]; then - exit 1 -fi diff --git a/old.travis.yml b/old.travis.yml deleted file mode 100644 index cd1e8efe0..000000000 --- a/old.travis.yml +++ /dev/null @@ -1,153 +0,0 @@ -sudo: required -language: python -os: linux - -jdk: openjdk10 - -addons: - sonarcloud: - organization: utplsql - token: ${SONAR_TOKEN} - -services: - - docker - -env: - global: - - UT3_DEVELOP_SCHEMA=UT3_DEVELOP - - UT3_DEVELOP_SCHEMA_PASSWORD=ut3 - - UT3_RELEASE_VERSION_SCHEMA=UT3 - - UT3_RELEASE_VERSION_SCHEMA_PASSWORD=ut3 - - UT3_USER="UT3\$USER#" - - UT3_USER_PASSWORD=ut3 - - UT3_TESTER=UT3_TESTER - - UT3_TESTER_PASSWORD=ut3 - - UT3_TESTER_HELPER=UT3_TESTER_HELPER - - UT3_TESTER_HELPER_PASSWORD=ut3 - - UT3_TABLESPACE=users - - BUILD_DIR=${TRAVIS_BUILD_DIR} - - JOB_ID=${TRAVIS_JOB_ID} - - JOB_NUMBER=${TRAVIS_JOB_NUMBER} - - PULL_REQUEST_NAME=${TRAVIS_PULL_REQUEST} - - PULL_REQUEST_BRANCH=${TRAVIS_PULL_REQUEST_BRANCH} - - TAG_NAME=${TRAVIS_TAG} - - REPO_SLUG=${TRAVIS_REPO_SLUG} - - PR_SLUG=${TRAVIS_PULL_REQUEST_SLUG} - - BRANCH_NAME=${TRAVIS_BRANCH} - # Environment for building a release - - CURRENT_BRANCH=${TRAVIS_BRANCH} - - UTPLSQL_REPO="utPLSQL/utPLSQL" - - UTPLSQL_BUILD_NO="${TRAVIS_BUILD_NUMBER:-0}" - - UTPLSQL_VERSION=$(. .travis/get_project_version.sh) - - UTPLSQL_BUILD_VERSION=$(. .travis/get_project_build_version.sh) - - UTPLSQL_SOURCES_DIR='source' - - UTPLSQL_BUILD_USER_NAME="Travis CI" - - CACHE_DIR=$HOME/.cache - # Database Env - - SQLCLI="${BUILD_DIR}/sqlcl/bin/sql" - - OJDBC_HOME="${BUILD_DIR}/ojdbc" - - ORACLE_PWD="oracle" - - DOCKHER_HUB_REPO="utplsqlv3/oracledb" - - DOCKER_VOLUME="/home/oracle/host" - - DOCKER_ENV="-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" - #utPLSQL released version directory - - UTPLSQL_DIR="utPLSQL_latest_release" - - SELFTESTING_BRANCH=${TRAVIS_BRANCH} - - UTPLSQL_CLI_VERSION="3.1.8" - # Maven - - MAVEN_HOME=/usr/local/maven - - MAVEN_CFG=$HOME/.m2 - jobs: - - ORACLE_VERSION="11g-r2-xe" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_VOLUME="/mnt/host" DOCKER_OPTIONS='--shm-size=1g' -# - ORACLE_VERSION="11-full" CONNECTION_STR='127.0.0.1:1521/XE' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle --shm-size=1g' DOCKER_VOLUME="/mnt/host" - - ORACLE_VERSION="12c-r1-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="12c-r2-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="18-slim" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' - - ORACLE_VERSION="18c-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="19c-se2-small" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' - - ORACLE_VERSION="21-full" CONNECTION_STR='127.0.0.1:1521/XEPDB1' DOCKHER_HUB_REPO="gvenzl/oracle-xe" DOCKER_OPTIONS='-e ORACLE_PASSWORD=oracle' - -cache: - pip: true - directories: - - $CACHE_DIR - - /home/travis/.sonar/cache - - node_modules - - $MAVEN_CFG - -before_install: - - #cache to be used between stages. Based on https://github.com/travis-ci/docs-travis-ci-com/issues/1329 - #delete all files in cache that are older than 5 days - - mkdir -p $CACHE_DIR/stages_cache; find $CACHE_DIR/stages_cache/ -mtime +5 -exec rm {} \; - #The update_project_version.sh is done before deployment to validate that the change of project files does not break installation - - bash .travis/update_project_version.sh - #Allow for sonar to blame issues - - git fetch --unshallow - # download latest utPLSQL release - - git clone --depth=1 --branch=${SELFTESTING_BRANCH:-main} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR - # download latest utPLSQL-cli release - - curl -Lk -o utPLSQL-cli.zip https://github.com/utPLSQL/utPLSQL-cli/releases/download/v${UTPLSQL_CLI_VERSION}/utPLSQL-cli.zip - -install: - - unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli -# - curl -Lk -o sqlcl-latest.zip https://download.oracle.com/otn_software/java/sqldeveloper/sqlcl-latest.zip -# - unzip -q sqlcl-latest.zip -d $HOME - - mkdir -p ${OJDBC_HOME} #get JDBC driver and orai18n - - curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar https://download.oracle.com/otn-pub/otn_software/jdbc/213/ojdbc8.jar - - curl -Lk -o ${OJDBC_HOME}/orai18n.jar https://download.oracle.com/otn-pub/otn_software/jdbc/213/orai18n.jar - # Chmod is needed to allow for write access within from docker container volume - - chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} - - if [[ ! $TRAVIS_TAG ]]; then bash .travis/start_db.sh; fi - - if [[ ! $TRAVIS_TAG ]]; then docker exec ${ORACLE_VERSION} ${DOCKER_VOLUME}/.travis/install.sh; fi - - if [[ ! $TRAVIS_TAG ]]; then docker exec ${ORACLE_VERSION} ${DOCKER_VOLUME}/.travis/install_utplsql_release.sh; fi - -before_script: - - if [[ ! $TRAVIS_TAG ]]; then docker exec ${ORACLE_VERSION} ${DOCKER_VOLUME}/.travis/run_examples.sh; fi - - if [[ ! $TRAVIS_TAG ]]; then docker exec ${ORACLE_VERSION} ${DOCKER_VOLUME}/test/install_tests.sh; fi - -script: - - if [[ ! $TRAVIS_TAG ]]; then bash test/run_tests.sh; fi - - if [[ ! $TRAVIS_TAG ]]; then bash .travis/validate_report_files.sh; fi - - if [[ ! $TRAVIS_TAG ]] && [[ ("${TRAVIS_REPO_SLUG}" = "${UTPLSQL_REPO}" && "${TRAVIS_PULL_REQUEST}" == false) || ("${TRAVIS_PULL_REQUEST_SLUG}" = "${UTPLSQL_REPO}") ]]; then bash .travis/run_sonar_scanner.sh; fi - - if [[ ! $TRAVIS_TAG ]]; then bash .travis/coveralls_uploader.sh; fi - -notifications: - slack: - rooms: - - secure: "nemt9n2y5sVCAKqa/s7JDQ8AcM59Xu/XbH/RkMOXvPgc+KtR8lBtVD1LkvJ5BaQhqgjuDT7DNt/uisQJ7k6a2OsrVFbnkypZ1hCvntOBpJyoSpD/YL1X8a9GbGojuJcph0BX76KN21LaOVdyOfY0TSlw53XiYWS8iL5HtjpWCbIwHL1SJ8JT8mhdT4hDoUWZjcZ4s4bLH6BQm4un/bMQOmB4sDoCeg4CllJwxgkswVF7OHpOFjgPetvUp7ps8b/Rj8en6zCj9drb0SVbXFgumo2Wd1bC3HHZB8MAZU0kuEV5VgUdum6EelUL5yfB72hssNQA0+CaT3HjBFkTlqWYJmjC4/xyGN3sseiW82T9FDY0g0GAGayNRW+QSiTQ1hbJEcAnNe0GrBUdRsgXdI6COd76YP5VxzRSF6H7niLfgCZdKbIivKUd1o+wBhuyJmqCFIkRWmT38tMGJqJAzbY1jq5gQXbb6E7gt+KdTjlSjcnJYf7XI7zqm+BRr+fbA0ixfXHvfqOBgZN6g08y9nPlDnIjtSF2NSdrj2zqYQAtKuWSOD1bnTyfDJyrtK7OLffZcMYD5Bcss4c8op8tP7MGTjt1S046SJocboh6H4c/nTokpoMRsWs6MKRdebl8C2RObGf5FebSOJg+oh2ZYS5Z/G9GshiY2BD/81+Hc4Miacc=" - on_success: change - on_failure: always - -jobs: - include: - - stage: deploy - env: ORACLE_VERSION="none" - before_install: skip - install: - - pip install mkdocs - before_script: skip - script: - - bash .travis/update_project_version.sh - - git config --global user.email "builds@travis-ci.com" - - git config --global user.name "${UTPLSQL_BUILD_USER_NAME}" - - git remote rm origin - - git remote add origin https://${github_api_token}@github.com/${UTPLSQL_REPO} - - if [[ ! $TRAVIS_TAG ]]; then bash .travis/push_release_version.sh; fi - - bash .travis/push_docs_to_github_io.sh - - bash .travis/build_docs.sh - - if [[ ($TRAVIS_BRANCH == develop) && ($TRAVIS_PULL_REQUEST == false) ]]; then bash .travis/trigger_travis.sh $TRAVIS_ACCESS_TOKEN; fi - before_deploy: - - bash .travis/build_release_archive.sh - deploy: - provider: releases - api_key: $github_api_token - file: - - utPLSQL.zip - - utPLSQL.tar.gz - - utPLSQL.zip.md5 - - utPLSQL.tar.gz.md5 - skip_cleanup: true - on: - repo: ${UTPLSQL_REPO} - tags: true From b94a3f72dd398ba1c869d44f9cbfdc9980cc7265 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 15 Jan 2022 01:13:40 +0200 Subject: [PATCH 191/887] Addding `utPLSQL-java-api` repo to dispatch post-build. --- .github/workflows/build.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8c72e5043..da5a51cda 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -153,18 +153,22 @@ jobs: with: env-file: .github/variables/.env - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action + - name: Set buid version number env variables id: set-build-version-number-vars run: .github/scripts/set_version_numbers_env.sh + - name: Update project version & build number in source code and documentation id: update-project-version run: .github/scripts/update_project_version.sh + - name: Push version update to repository id: push-version-number-update run: | git add sonar-project.properties VERSION source/* docs/* git commit -m 'Updated project version after build [skip ci]' git push --quiet origin HEAD:${CI_ACTION_REF_NAME} + - name: Copy and push documentation to utPLSQL-github-io repo id: push-documentation env: @@ -181,7 +185,7 @@ jobs: ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' ) strategy: matrix: - repo: ['utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project'] + repo: ['utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project','utPLSQL/utPLSQL-java-api'] # repo: ['utPLSQL/utPLSQL-java-api', 'utPLSQL/utPLSQL-v2-v3-migration', 'utPLSQL/utPLSQL-cli', 'utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project'] steps: - name: Repository Dispatch From 79c3510c600258a0e00f9fde61a187298cb33fd5 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 16 Jan 2022 14:12:23 +0200 Subject: [PATCH 192/887] Fix for releasing version update. --- .github/scripts/push_project_version.sh | 12 ------------ .github/workflows/build.yml | 10 +++++++++- 2 files changed, 9 insertions(+), 13 deletions(-) delete mode 100755 .github/scripts/push_project_version.sh diff --git a/.github/scripts/push_project_version.sh b/.github/scripts/push_project_version.sh deleted file mode 100755 index 1b38e6c24..000000000 --- a/.github/scripts/push_project_version.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/usr/bin/env bash - -set -v -echo Current branch is "${CURRENT_BRANCH}" -echo "Committing version & buildNo into branch (${CURRENT_BRANCH})" -git add sonar-project.properties -git add VERSION -git add source/* -git add docs/* -git commit -m 'Updated project version after build [skip ci]' -echo "Pushing to origin" -git push --quiet origin HEAD:${CURRENT_BRANCH} diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index da5a51cda..0bdda4797 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -141,14 +141,22 @@ jobs: needs: [ build ] concurrency: publish runs-on: ubuntu-latest + env: + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} if: | github.repository == 'utPLSQL/utPLSQL' && github.base_ref == null && ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' ) steps: + - name: 🔍 API_TOKEN_GITHUB + if: env.API_TOKEN_GITHUB == '' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: echo "API_TOKEN_GITHUB=${GITHUB_TOKEN}" >> $GITHUB_ENV - uses: actions/checkout@v2 with: fetch-depth: 0 + token: ${{ env.API_TOKEN_GITHUB }} - uses: c-py/action-dotenv-to-setenv@v2 with: env-file: .github/variables/.env @@ -164,7 +172,7 @@ jobs: - name: Push version update to repository id: push-version-number-update - run: | + run: | git add sonar-project.properties VERSION source/* docs/* git commit -m 'Updated project version after build [skip ci]' git push --quiet origin HEAD:${CI_ACTION_REF_NAME} From 9abdd36c03f3d8f3df7ba8cab0ddbcebe3ffc1ce Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 16 Jan 2022 13:41:39 +0000 Subject: [PATCH 193/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 34b6dc228..28c43e3e6 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 1d85c978a..4e059bce9 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 0790f1356..43ff8fd64 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 3dc0c0412..2d00bd44d 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 0815fafac..248b18014 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index d25411370..ab40cbfb7 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index f5f5c9d06..c27db2f0b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 3fac28b94..b9eb8b5a4 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index e89ad4562..a44cb104c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 5c78ada34..f9e4f8b1e 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0c45df2ea..b51c10384 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 4ab0c3904..59d8822f1 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 227e7c22a..5f66df953 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 81e53b98b..c95d55bbf 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 18e5e307e..500cbb300 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 5bb5b7d6d..de33bd530 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index af4ef241e..eb56d14e6 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3562--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index cf189e768..b20476414 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.12.3562-develop + * secion v3.1.12.3718-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 49e81558e..a014eaf28 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3562-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3718-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 4453b562b0afb62888ca31e9f6205ca75dbf0f7e Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 16 Jan 2022 18:07:30 +0200 Subject: [PATCH 194/887] Fixing badge --- .github/workflows/build.yml | 2 +- readme.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0bdda4797..a0bf8b120 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -194,7 +194,7 @@ jobs: strategy: matrix: repo: ['utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project','utPLSQL/utPLSQL-java-api'] -# repo: ['utPLSQL/utPLSQL-java-api', 'utPLSQL/utPLSQL-v2-v3-migration', 'utPLSQL/utPLSQL-cli', 'utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project'] +# repo: [ 'utPLSQL/utPLSQL-v2-v3-migration', 'utPLSQL/utPLSQL-cli' ] steps: - name: Repository Dispatch uses: peter-evans/repository-dispatch@v1 diff --git a/readme.md b/readme.md index 8367362cd..f96b88d7f 100644 --- a/readme.md +++ b/readme.md @@ -8,7 +8,7 @@ [![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) -[![build](https://travis-ci.com/utPLSQL/utPLSQL.svg?branch=develop)](https://travis-ci.com/utPLSQL/utPLSQL) +[![build](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml/badge.svg)](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml) [![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=sqale_rating)](https://sonarcloud.io/dashboard/index?id=utPLSQL) [![Coverage](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=coverage)](https://sonarcloud.io/summary/new_code?id=utPLSQL) From 2f4e32037006ea8896894d720b70ecb36bac4514 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 17 Jan 2022 10:02:00 +0200 Subject: [PATCH 195/887] REmoved dispatching of projects that depend on utPLSQL-java-api. Those will be dispatched after successful build of utPLSQL-java-api --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a0bf8b120..87d577554 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -193,8 +193,8 @@ jobs: ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' ) strategy: matrix: - repo: ['utPLSQL/utPLSQL-maven-plugin', 'utPLSQL/utPLSQL-demo-project','utPLSQL/utPLSQL-java-api'] -# repo: [ 'utPLSQL/utPLSQL-v2-v3-migration', 'utPLSQL/utPLSQL-cli' ] + repo: [ 'utPLSQL/utPLSQL-demo-project', 'utPLSQL/utPLSQL-java-api' ] +# repo: [ 'utPLSQL/utPLSQL-v2-v3-migration' ] steps: - name: Repository Dispatch uses: peter-evans/repository-dispatch@v1 From f28ae6232c5e3ebac8d4e36938eec4f4d9e19935 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 17 Jan 2022 08:18:58 +0000 Subject: [PATCH 196/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 28c43e3e6..c9ec27342 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 4e059bce9..9f271da68 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 43ff8fd64..307dd5a8b 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 2d00bd44d..78de8ab87 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 248b18014..000fcd906 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index ab40cbfb7..8b1c1ef22 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index c27db2f0b..e2927918f 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b9eb8b5a4..38234be6c 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index a44cb104c..753fc1b5b 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index f9e4f8b1e..784fa65ac 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b51c10384..debcd6025 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 59d8822f1..d2ac915a5 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 5f66df953..87e3dba0c 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c95d55bbf..d41111356 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 500cbb300..67a424c6d 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index de33bd530..9fb53e98f 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index eb56d14e6..92581f966 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3718--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index b20476414..6073eb50b 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.12.3718-develop + * secion v3.1.12.3719-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index a014eaf28..85f621842 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3718-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3719-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From c11aa2456f479fe26194e03b0363ecbf4982268a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 26 Jan 2022 00:37:26 +0000 Subject: [PATCH 197/887] Initial check in. Covers issues of displaying wrong info in diff message for nested objects. Exclude object type from being part of the SQL generation. --- .../data_values/ut_compound_data_helper.pkb | 39 +++++++++++++++---- test/install_ut3_tester_helper.sql | 1 + .../test_dummy_nested_object.tps | 15 +++++++ .../expectations/test_expectation_anydata.pkb | 19 +++++++++ .../expectations/test_expectation_anydata.pks | 4 ++ 5 files changed, 70 insertions(+), 8 deletions(-) create mode 100644 test/ut3_tester_helper/test_dummy_nested_object.tps diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 37d9901ff..bfd0865d4 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -144,7 +144,9 @@ create or replace package body ut_compound_data_helper is l_index := a_pk_table.next(l_index); end loop; end if; - if not(l_exists) then + if a_data_info.column_type in ('OBJECT') then + null; + elsif not(l_exists) then l_sql_stmt := ' (decode(a.'||a_data_info.transformed_name||','||' e.'||a_data_info.transformed_name||',1,0) = 0)'; end if; return l_sql_stmt; @@ -161,7 +163,9 @@ create or replace package body ut_compound_data_helper is if l_pk_tab.count <> 0 then l_index:= l_pk_tab.first; loop - if l_pk_tab(l_index) in (a_data_info.access_path, a_data_info.parent_name) then + if a_data_info.column_type in ('OBJECT') then + null; + elsif l_pk_tab(l_index) in (a_data_info.access_path, a_data_info.parent_name) then --When then table is nested and join is on whole table l_sql_stmt := l_sql_stmt ||' a.'||a_data_info.transformed_name||q'[ = ]'||' e.'||a_data_info.transformed_name; end if; @@ -187,7 +191,9 @@ create or replace package body ut_compound_data_helper is if a_pk_table is not empty then l_index:= a_pk_table.first; loop - if a_pk_table(l_index) in (a_data_info.access_path, a_data_info.parent_name) then + if a_data_info.column_type in ('OBJECT') then + null; + elsif a_pk_table(l_index) in (a_data_info.access_path, a_data_info.parent_name) then --When then table is nested and join is on whole table l_sql_stmt := l_sql_stmt ||a_alias||a_data_info.transformed_name; end if; @@ -195,7 +201,11 @@ create or replace package body ut_compound_data_helper is l_index := a_pk_table.next(l_index); end loop; else - l_sql_stmt := a_alias||a_data_info.transformed_name; + if a_data_info.column_type in ('OBJECT') then + null; + else + l_sql_stmt := a_alias||a_data_info.transformed_name; + end if; end if; return l_sql_stmt; end; @@ -206,7 +216,9 @@ create or replace package body ut_compound_data_helper is l_alias varchar2(10) := a_alias; l_col_syntax varchar2(4000); begin - if a_data_info.is_sql_diffable = 0 then + if a_data_info.column_type in ('OBJECT') then + null; + elsif a_data_info.is_sql_diffable = 0 then l_col_syntax := 'ut_utils.get_hash('||l_alias||a_data_info.transformed_name||'.getClobVal()) as '||a_data_info.transformed_name ; elsif a_data_info.is_sql_diffable = 1 and a_data_info.column_type = 'DATE' then l_col_syntax := 'to_date('||l_alias||a_data_info.transformed_name||') as '|| a_data_info.transformed_name; @@ -238,6 +250,8 @@ create or replace package body ut_compound_data_helper is --We cannot use a precision and scale as dbms_sql.describe_columns3 return precision 0 for dual table -- there is also no need for that as we not process data but only read and compare as they are stored l_col_type := a_data_info.column_type; + elsif a_data_info.column_type in ('OBJECT') then + null; else l_col_type := a_data_info.column_type ||case when a_data_info.column_len is not null @@ -245,7 +259,11 @@ create or replace package body ut_compound_data_helper is else null end; end if; - return a_data_info.transformed_name||' '||l_col_type||q'[ PATH ']'||a_data_info.access_path||q'[']'; + if a_data_info.column_type in ('OBJECT') then + return null; + else + return a_data_info.transformed_name||' '||l_col_type||q'[ PATH ']'||a_data_info.access_path||q'[']'; + end if; end; procedure gen_sql_pieces_out_of_cursor( @@ -398,8 +416,12 @@ create or replace package body ut_compound_data_helper is l_column_list ut_varchar2_list := ut_varchar2_list(); begin for i in 1..a_cursor_info.count loop - l_column_list.extend; - l_column_list(l_column_list.last) := a_cursor_info(i).access_path; + --This avoids extracting single columns from nested objects. + --as we can go down to any level but we will lose visibility of parent. + if a_cursor_info(i).hierarchy_level = 1 then + l_column_list.extend; + l_column_list(l_column_list.last) := a_cursor_info(i).access_path; + end if; end loop; return l_column_list; end; @@ -571,6 +593,7 @@ create or replace package body ut_compound_data_helper is xmlelement( name "ROW", a_diff_tab(idx).act_item_data), a_diff_tab(idx).act_data_id, xmlelement( name "ROW", a_diff_tab(idx).exp_item_data), a_diff_tab(idx).exp_data_id, a_diff_tab(idx).item_no, a_diff_tab(idx).dup_no); + exception when ut_utils.ex_failure_for_all then raise_application_error(ut_utils.gc_dml_for_all,'Failure to insert a diff tmp data.'); diff --git a/test/install_ut3_tester_helper.sql b/test/install_ut3_tester_helper.sql index 9841252a0..7fb9aacf6 100644 --- a/test/install_ut3_tester_helper.sql +++ b/test/install_ut3_tester_helper.sql @@ -6,6 +6,7 @@ alter session set plsql_optimize_level=0; --Install ut3_tester_helper @@ut3_tester_helper/test_dummy_object.tps @@ut3_tester_helper/other_dummy_object.tps +@@ut3_tester_helper/test_dummy_nested_object.tps @@ut3_tester_helper/test_dummy_object_list.tps @@ut3_tester_helper/test_tab_varchar2.tps @@ut3_tester_helper/test_tab_varray.tps diff --git a/test/ut3_tester_helper/test_dummy_nested_object.tps b/test/ut3_tester_helper/test_dummy_nested_object.tps new file mode 100644 index 000000000..6aef3bef8 --- /dev/null +++ b/test/ut3_tester_helper/test_dummy_nested_object.tps @@ -0,0 +1,15 @@ +declare + l_exists integer; +begin + select count(1) into l_exists from user_types where type_name = 'TEST_DUMMY_NESTED_OBJECT'; + if l_exists > 0 then + execute immediate 'drop type test_dummy_nested_object force'; + end if; +end; +/ + +create or replace type test_dummy_nested_object as object ( + first_nested_obj test_dummy_object, + sec_nested_obj test_dummy_object +) +/ \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index be666b284..d783fc86c 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -991,6 +991,25 @@ Rows: [ 60 differences, showing first 20 ] ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; + + procedure failure_nesting_objects is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'B', '0') )); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'C', '0') )); + --Act + l_expected_message := q'[%Actual: ut3_develop.some_item was expected to equal: ut3_develop.some_item +%Diff: +%Rows: [ 1 differences ] +%Row No. 1 - Actual: 1B0 +%Row No. 1 - Expected: 1C0]'; + ut3_develop.ut.expect(g_test_actual).to_equal(g_test_expected); + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; end; / \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectation_anydata.pks b/test/ut3_user/expectations/test_expectation_anydata.pks index a6eeb25fb..f74d15241 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pks +++ b/test/ut3_user/expectations/test_expectation_anydata.pks @@ -203,5 +203,9 @@ create or replace package test_expectation_anydata is --%test ( Empty Array not equal array with space ) procedure arr_empty_nqua_arr_e_unord; + + --%test ( Failure of comparing nesting objects ) + procedure failure_nesting_objects; + end; / From e0ac97ca4ebb3cdb391ebdf09084413961322657 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 26 Jan 2022 01:19:53 +0000 Subject: [PATCH 198/887] Adding test for double nested objects --- .../data_values/ut_compound_data_helper.pkb | 32 ++++--------------- test/install_ut3_tester_helper.sql | 1 + .../test_dummy_double_nested_object.tps | 15 +++++++++ .../expectations/test_expectation_anydata.pkb | 25 +++++++++++++-- .../expectations/test_expectation_anydata.pks | 3 ++ 5 files changed, 48 insertions(+), 28 deletions(-) create mode 100644 test/ut3_tester_helper/test_dummy_double_nested_object.tps diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index bfd0865d4..71c1b9ee2 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -144,9 +144,7 @@ create or replace package body ut_compound_data_helper is l_index := a_pk_table.next(l_index); end loop; end if; - if a_data_info.column_type in ('OBJECT') then - null; - elsif not(l_exists) then + if not(l_exists) then l_sql_stmt := ' (decode(a.'||a_data_info.transformed_name||','||' e.'||a_data_info.transformed_name||',1,0) = 0)'; end if; return l_sql_stmt; @@ -163,9 +161,7 @@ create or replace package body ut_compound_data_helper is if l_pk_tab.count <> 0 then l_index:= l_pk_tab.first; loop - if a_data_info.column_type in ('OBJECT') then - null; - elsif l_pk_tab(l_index) in (a_data_info.access_path, a_data_info.parent_name) then + if l_pk_tab(l_index) in (a_data_info.access_path, a_data_info.parent_name) then --When then table is nested and join is on whole table l_sql_stmt := l_sql_stmt ||' a.'||a_data_info.transformed_name||q'[ = ]'||' e.'||a_data_info.transformed_name; end if; @@ -191,9 +187,7 @@ create or replace package body ut_compound_data_helper is if a_pk_table is not empty then l_index:= a_pk_table.first; loop - if a_data_info.column_type in ('OBJECT') then - null; - elsif a_pk_table(l_index) in (a_data_info.access_path, a_data_info.parent_name) then + if a_pk_table(l_index) in (a_data_info.access_path, a_data_info.parent_name) then --When then table is nested and join is on whole table l_sql_stmt := l_sql_stmt ||a_alias||a_data_info.transformed_name; end if; @@ -201,11 +195,7 @@ create or replace package body ut_compound_data_helper is l_index := a_pk_table.next(l_index); end loop; else - if a_data_info.column_type in ('OBJECT') then - null; - else - l_sql_stmt := a_alias||a_data_info.transformed_name; - end if; + l_sql_stmt := a_alias||a_data_info.transformed_name; end if; return l_sql_stmt; end; @@ -216,9 +206,7 @@ create or replace package body ut_compound_data_helper is l_alias varchar2(10) := a_alias; l_col_syntax varchar2(4000); begin - if a_data_info.column_type in ('OBJECT') then - null; - elsif a_data_info.is_sql_diffable = 0 then + if a_data_info.is_sql_diffable = 0 then l_col_syntax := 'ut_utils.get_hash('||l_alias||a_data_info.transformed_name||'.getClobVal()) as '||a_data_info.transformed_name ; elsif a_data_info.is_sql_diffable = 1 and a_data_info.column_type = 'DATE' then l_col_syntax := 'to_date('||l_alias||a_data_info.transformed_name||') as '|| a_data_info.transformed_name; @@ -250,8 +238,6 @@ create or replace package body ut_compound_data_helper is --We cannot use a precision and scale as dbms_sql.describe_columns3 return precision 0 for dual table -- there is also no need for that as we not process data but only read and compare as they are stored l_col_type := a_data_info.column_type; - elsif a_data_info.column_type in ('OBJECT') then - null; else l_col_type := a_data_info.column_type ||case when a_data_info.column_len is not null @@ -259,11 +245,7 @@ create or replace package body ut_compound_data_helper is else null end; end if; - if a_data_info.column_type in ('OBJECT') then - return null; - else - return a_data_info.transformed_name||' '||l_col_type||q'[ PATH ']'||a_data_info.access_path||q'[']'; - end if; + return a_data_info.transformed_name||' '||l_col_type||q'[ PATH ']'||a_data_info.access_path||q'[']'; end; procedure gen_sql_pieces_out_of_cursor( @@ -296,7 +278,7 @@ create or replace package body ut_compound_data_helper is begin if a_data_info is not empty then for i in 1..a_data_info.count loop - if a_data_info(i).has_nested_col = 0 then + if a_data_info(i).has_nested_col = 0 and a_data_info(i).column_type <> 'OBJECT' then --Get XMLTABLE column list add_element_to_list(l_xmltab_list,generate_xmltab_stmt(a_data_info(i))); --Get Select statment list of columns diff --git a/test/install_ut3_tester_helper.sql b/test/install_ut3_tester_helper.sql index 7fb9aacf6..c31b670bb 100644 --- a/test/install_ut3_tester_helper.sql +++ b/test/install_ut3_tester_helper.sql @@ -7,6 +7,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester_helper/test_dummy_object.tps @@ut3_tester_helper/other_dummy_object.tps @@ut3_tester_helper/test_dummy_nested_object.tps +@@ut3_tester_helper/test_dummy_double_nested_object.tps @@ut3_tester_helper/test_dummy_object_list.tps @@ut3_tester_helper/test_tab_varchar2.tps @@ut3_tester_helper/test_tab_varray.tps diff --git a/test/ut3_tester_helper/test_dummy_double_nested_object.tps b/test/ut3_tester_helper/test_dummy_double_nested_object.tps new file mode 100644 index 000000000..bfd29447c --- /dev/null +++ b/test/ut3_tester_helper/test_dummy_double_nested_object.tps @@ -0,0 +1,15 @@ +declare + l_exists integer; +begin + select count(1) into l_exists from user_types where type_name = 'TEST_DUMMY_DOUBLE_NESTED_OBJECT'; + if l_exists > 0 then + execute immediate 'drop type test_dummy_double_nested_object force'; + end if; +end; +/ + +create or replace type test_dummy_double_nested_object as object ( + first_double_nested_obj test_dummy_nested_object, + "Value" varchar2(30) +) +/ \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index d783fc86c..5c76226da 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -1000,16 +1000,35 @@ Rows: [ 60 differences, showing first 20 ] g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'B', '0') )); g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'C', '0') )); --Act - l_expected_message := q'[%Actual: ut3_develop.some_item was expected to equal: ut3_develop.some_item + l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_nested_object was expected to equal: ut3_tester_helper.test_dummy_nested_object %Diff: %Rows: [ 1 differences ] -%Row No. 1 - Actual: 1B0 -%Row No. 1 - Expected: 1C0]'; +%Row No. 1 - Actual: 1C0 +%Row No. 1 - Expected: 1B0]'; ut3_develop.ut.expect(g_test_actual).to_equal(g_test_expected); l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); end; + procedure failure_double_nested_objects is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_double_nested_object(ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'B', '0') ),'Test')); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_double_nested_object(ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'C', '0') ),'Test')); + --Act + l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_double_nested_object was expected to equal: ut3_tester_helper.test_dummy_double_nested_object +%Diff: +%Rows: [ 1 differences ] +%Row No. 1 - Actual: 1A01C0 +%Row No. 1 - Expected: 1A01B0]'; + ut3_develop.ut.expect(g_test_actual).to_equal(g_test_expected); + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + end; / \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectation_anydata.pks b/test/ut3_user/expectations/test_expectation_anydata.pks index f74d15241..4b24a2ad9 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pks +++ b/test/ut3_user/expectations/test_expectation_anydata.pks @@ -206,6 +206,9 @@ create or replace package test_expectation_anydata is --%test ( Failure of comparing nesting objects ) procedure failure_nesting_objects; + + --%test ( Failure of comparing double nested objects ) + procedure failure_double_nested_objects; end; / From 5e983a847abc93b9de02965270b48a0fb328a1bf Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 26 Jan 2022 01:24:36 +0000 Subject: [PATCH 199/887] Fixing test object name as its too large for 11gR2 (31 char) --- test/ut3_tester_helper/test_dummy_double_nested_object.tps | 6 +++--- test/ut3_user/expectations/test_expectation_anydata.pkb | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/test/ut3_tester_helper/test_dummy_double_nested_object.tps b/test/ut3_tester_helper/test_dummy_double_nested_object.tps index bfd29447c..8f74f7ecb 100644 --- a/test/ut3_tester_helper/test_dummy_double_nested_object.tps +++ b/test/ut3_tester_helper/test_dummy_double_nested_object.tps @@ -1,14 +1,14 @@ declare l_exists integer; begin - select count(1) into l_exists from user_types where type_name = 'TEST_DUMMY_DOUBLE_NESTED_OBJECT'; + select count(1) into l_exists from user_types where type_name = 'TEST_DUMMY_DOUBLE_NESTED_OBJ'; if l_exists > 0 then - execute immediate 'drop type test_dummy_double_nested_object force'; + execute immediate 'drop type test_dummy_double_nested_obj force'; end if; end; / -create or replace type test_dummy_double_nested_object as object ( +create or replace type test_dummy_double_nested_obj as object ( first_double_nested_obj test_dummy_nested_object, "Value" varchar2(30) ) diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index 5c76226da..521734223 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -1016,10 +1016,10 @@ Rows: [ 60 differences, showing first 20 ] l_expected_message varchar2(32767); begin --Arrange - g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_double_nested_object(ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'B', '0') ),'Test')); - g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_double_nested_object(ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'C', '0') ),'Test')); + g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_double_nested_obj(ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'B', '0') ),'Test')); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_double_nested_obj(ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'C', '0') ),'Test')); --Act - l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_double_nested_object was expected to equal: ut3_tester_helper.test_dummy_double_nested_object + l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_double_nested_obj was expected to equal: ut3_tester_helper.test_dummy_double_nested_obj %Diff: %Rows: [ 1 differences ] %Row No. 1 - Actual: 1A01C0 From 3c3d32055457a9c4ab36e61cc79179a536e2f8aa Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 26 Jan 2022 10:46:41 +0000 Subject: [PATCH 200/887] Fixing issue when a hash was tried to be generated on the null value from XML extract causing to fail. Please see #1098 Resolve a situation where a more than two levels of nesting were causing ambiguity on the column name for hash. E.g. Was taking into hash consideration only parent. --- source/core/ut_utils.pkb | 6 ++++-- source/expectations/data_values/ut_cursor_column.tpb | 5 +++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 6073eb50b..51e07a6b5 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -882,12 +882,14 @@ create or replace package body ut_utils is function get_hash(a_data raw, a_hash_type binary_integer := dbms_crypto.hash_sh1) return t_hash is begin - return dbms_crypto.hash(a_data, a_hash_type); + --We cannot run hash on null + return case when a_data is null then null else dbms_crypto.hash(a_data, a_hash_type) end; end; function get_hash(a_data clob, a_hash_type binary_integer := dbms_crypto.hash_sh1) return t_hash is begin - return dbms_crypto.hash(a_data, a_hash_type); + --We cannot run hash on null + return case when a_data is null then null else dbms_crypto.hash(a_data, a_hash_type) end; end; function qualified_sql_name(a_name varchar2) return varchar2 is diff --git a/source/expectations/data_values/ut_cursor_column.tpb b/source/expectations/data_values/ut_cursor_column.tpb index 13b1b3158..3c39c2464 100644 --- a/source/expectations/data_values/ut_cursor_column.tpb +++ b/source/expectations/data_values/ut_cursor_column.tpb @@ -28,12 +28,13 @@ create or replace type body ut_cursor_column as a_access_path||'/'||self.xml_valid_name end; --Access path used for XMLTABLE query self.filter_path := '/'||self.access_path; --Filter path will differ from access path in anydata type + --Transformed name needs to be build on full access path to avoid ambiguity when there is 3 or more levels of nesting. self.transformed_name := case when length(self.xml_valid_name) > 30 then - '"'||ut_compound_data_helper.get_fixed_size_hash(self.parent_name||self.xml_valid_name)||'"' + '"'||ut_compound_data_helper.get_fixed_size_hash(self.access_path)||'"' when self.parent_name is null then '"'||self.xml_valid_name||'"' else - '"'||ut_compound_data_helper.get_fixed_size_hash(self.parent_name||self.xml_valid_name)||'"' + '"'||ut_compound_data_helper.get_fixed_size_hash(self.access_path)||'"' end; --when is nestd we need to hash name to make sure we dont exceed 30 char self.column_type := a_col_type; --column type e.g. user_defined , varchar2 self.column_schema := a_col_schema_name; -- schema name From 14b0b8d7953c62fe4ca94d78d830e20c41c82c13 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 26 Jan 2022 22:41:28 +0000 Subject: [PATCH 201/887] Fixing issue when a collection nested inside object was failing due to fact that there was no name for collection columns as part of cursor only data type. Added extra tests. --- .../data_values/ut_cursor_column.tpb | 7 +- test/install_ut3_tester_helper.sql | 2 + .../test_dummy_nested_object_list.tps | 14 +++ .../test_dummy_object_list.tps | 10 ++ .../test_nested_tab_varray.tps | 14 +++ .../expectations/test_expectation_anydata.pkb | 99 +++++++++++++++++++ .../expectations/test_expectation_anydata.pks | 19 +++- 7 files changed, 162 insertions(+), 3 deletions(-) create mode 100644 test/ut3_tester_helper/test_dummy_nested_object_list.tps create mode 100644 test/ut3_tester_helper/test_nested_tab_varray.tps diff --git a/source/expectations/data_values/ut_cursor_column.tpb b/source/expectations/data_values/ut_cursor_column.tpb index 3c39c2464..a9fb6b0f4 100644 --- a/source/expectations/data_values/ut_cursor_column.tpb +++ b/source/expectations/data_values/ut_cursor_column.tpb @@ -14,8 +14,11 @@ create or replace type body ut_cursor_column as self.column_len := a_col_max_len; --length of column self.column_precision := a_col_precision; self.column_scale := a_col_scale; - self.column_name := TRIM( BOTH '''' FROM a_col_name); --name of the column self.column_type_name := coalesce(a_col_type_name,a_col_type); --type name e.g. test_dummy_object or varchar2 + self.column_name := case when a_col_name is null and a_collection = 1 then + self.column_type_name + else TRIM( BOTH '''' FROM a_col_name) + end; --name of the column, however in nested object for collection name is not defined in cursor. self.xml_valid_name := ut_utils.get_valid_xml_name(self.column_name); self.display_path := case when a_access_path is null then self.column_name @@ -25,7 +28,7 @@ create or replace type body ut_cursor_column as self.access_path := case when a_access_path is null then self.xml_valid_name else - a_access_path||'/'||self.xml_valid_name + a_access_path||'/'||self.xml_valid_name end; --Access path used for XMLTABLE query self.filter_path := '/'||self.access_path; --Filter path will differ from access path in anydata type --Transformed name needs to be build on full access path to avoid ambiguity when there is 3 or more levels of nesting. diff --git a/test/install_ut3_tester_helper.sql b/test/install_ut3_tester_helper.sql index c31b670bb..b2e0d57c4 100644 --- a/test/install_ut3_tester_helper.sql +++ b/test/install_ut3_tester_helper.sql @@ -9,8 +9,10 @@ alter session set plsql_optimize_level=0; @@ut3_tester_helper/test_dummy_nested_object.tps @@ut3_tester_helper/test_dummy_double_nested_object.tps @@ut3_tester_helper/test_dummy_object_list.tps +@@ut3_tester_helper/test_dummy_nested_object_list.tps @@ut3_tester_helper/test_tab_varchar2.tps @@ut3_tester_helper/test_tab_varray.tps +@@ut3_tester_helper/test_nested_tab_varray.tps @@ut3_tester_helper/test_dummy_number.tps @@ut3_tester_helper/ut_test_table.sql @@ut3_tester_helper/test_event_object.tps diff --git a/test/ut3_tester_helper/test_dummy_nested_object_list.tps b/test/ut3_tester_helper/test_dummy_nested_object_list.tps new file mode 100644 index 000000000..ca2c0d6df --- /dev/null +++ b/test/ut3_tester_helper/test_dummy_nested_object_list.tps @@ -0,0 +1,14 @@ +declare + l_exists integer; +begin + select count(1) into l_exists from user_types where type_name = 'TEST_DUMMY_NESTED_OBJECT_LIST'; + if l_exists > 0 then + execute immediate 'drop type test_dummy_nested_object_list force'; + end if; +end; +/ + +create or replace type test_dummy_nested_object_list as object ( + first_nested_obj test_dummy_object_list +) +/ \ No newline at end of file diff --git a/test/ut3_tester_helper/test_dummy_object_list.tps b/test/ut3_tester_helper/test_dummy_object_list.tps index 67bba558e..849974da1 100644 --- a/test/ut3_tester_helper/test_dummy_object_list.tps +++ b/test/ut3_tester_helper/test_dummy_object_list.tps @@ -1,2 +1,12 @@ +declare + l_exists integer; +begin + select count(1) into l_exists from user_types where type_name = 'TEST_DUMMY_OBJECT_LIST'; + if l_exists > 0 then + execute immediate 'drop type test_dummy_object_list force'; + end if; +end; +/ + create or replace type test_dummy_object_list as table of test_dummy_object / diff --git a/test/ut3_tester_helper/test_nested_tab_varray.tps b/test/ut3_tester_helper/test_nested_tab_varray.tps new file mode 100644 index 000000000..9f58d090e --- /dev/null +++ b/test/ut3_tester_helper/test_nested_tab_varray.tps @@ -0,0 +1,14 @@ +declare + l_exists integer; +begin + select count(1) into l_exists from user_types where type_name = 'TEST_NESTED_TAB_VARRAY'; + if l_exists > 0 then + execute immediate 'drop type test_nested_tab_varray force'; + end if; +end; +/ + +create or replace type test_nested_tab_varray as object ( + n_varray t_varray +) +/ diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index 521734223..bd57a860a 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -1029,6 +1029,105 @@ Rows: [ 60 differences, showing first 20 ] --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); end; + + procedure success_nesting_objects is + begin + --Arrange + g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'B', '0') )); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'B', '0') )); + --Act + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + procedure success_double_nested_objects is + begin + --Arrange + g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_double_nested_obj(ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'B', '0') ),'Test')); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_double_nested_obj(ut3_tester_helper.test_dummy_nested_object(ut3_tester_helper.test_dummy_object(1, 'A', '0'),ut3_tester_helper.test_dummy_object(1, 'B', '0') ),'Test')); + --Act + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + + procedure failure_nested_object_list is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + l_actual ut3_tester_helper.test_dummy_object_list; + l_expected ut3_tester_helper.test_dummy_object_list; + begin + --Arrange + select ut3_tester_helper.test_dummy_object( rownum + 1, 'Something '||rownum, rownum) + bulk collect into l_actual + from dual connect by level <=2 + order by rownum desc; + select ut3_tester_helper.test_dummy_object( rownum, 'Something '||rownum, rownum) + bulk collect into l_expected + from dual connect by level <=2 + order by rownum desc; + --Arrange + g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_actual)); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_expected)); + --Act + l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_nested_object_list was expected to equal: ut3_tester_helper.test_dummy_nested_object_list +%Diff: +%Rows: [ 1 differences ] +%Row No. 1 - Actual: 2Something 221Something 11 +%Row No. 1 - Expected: 3Something 222Something 11]'; + ut3_develop.ut.expect(g_test_actual).to_equal(g_test_expected); + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure success_nested_object_list is + l_actual ut3_tester_helper.test_dummy_object_list; + l_expected ut3_tester_helper.test_dummy_object_list; + begin + --Arrange + select ut3_tester_helper.test_dummy_object( rownum , 'Something '||rownum, rownum) + bulk collect into l_actual + from dual connect by level <=2 + order by rownum desc; + select ut3_tester_helper.test_dummy_object( rownum, 'Something '||rownum, rownum) + bulk collect into l_expected + from dual connect by level <=2 + order by rownum desc; + --Arrange + g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_actual)); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_expected)); + --Act + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + + procedure nested_varray_same_data is + begin + --Arrange + g_test_expected := anydata.convertObject( ut3_tester_helper.test_nested_tab_varray(ut3_tester_helper.t_varray(1)) ); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_nested_tab_varray(ut3_tester_helper.t_varray(1)) ); + --Act + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + + procedure nested_varray_diff_data is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Arrange + g_test_expected := anydata.convertObject( ut3_tester_helper.test_nested_tab_varray(ut3_tester_helper.t_varray(1)) ); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_nested_tab_varray(ut3_tester_helper.t_varray(2)) ); + --Act + ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); + l_expected_message := q'[%Actual: ut3_tester_helper.test_nested_tab_varray was expected to equal: ut3_tester_helper.test_nested_tab_varray +%Diff: +%Rows: [ 1 differences ] +%Row No. 1 - Actual: 2 +%Row No. 1 - Expected: 1]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; end; / \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectation_anydata.pks b/test/ut3_user/expectations/test_expectation_anydata.pks index 4b24a2ad9..a073c0701 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pks +++ b/test/ut3_user/expectations/test_expectation_anydata.pks @@ -204,11 +204,28 @@ create or replace package test_expectation_anydata is --%test ( Empty Array not equal array with space ) procedure arr_empty_nqua_arr_e_unord; - --%test ( Failure of comparing nesting objects ) + --%test ( Failure of comparing nested objects ) procedure failure_nesting_objects; --%test ( Failure of comparing double nested objects ) procedure failure_double_nested_objects; + --%test ( Success of comparing nested objects ) + procedure success_nesting_objects; + + --%test ( Success of comparing double nested objects ) + procedure success_double_nested_objects; + + --%test ( Failure of comparing nested object list ) + procedure failure_nested_object_list; + + --%test ( Success of comparing nested object list ) + procedure success_nested_object_list; + + --%test(Nested VARRAYS with same data) + procedure nested_varray_same_data; + + --%test(Nested VARRAYS with different data) + procedure nested_varray_diff_data; end; / From 85b2349a947bafdaf316a152186fb537f3244d44 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 26 Jan 2022 23:06:12 +0000 Subject: [PATCH 202/887] Removing empty line from code. --- source/expectations/data_values/ut_compound_data_helper.pkb | 1 - 1 file changed, 1 deletion(-) diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 71c1b9ee2..6d21aaa21 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -575,7 +575,6 @@ create or replace package body ut_compound_data_helper is xmlelement( name "ROW", a_diff_tab(idx).act_item_data), a_diff_tab(idx).act_data_id, xmlelement( name "ROW", a_diff_tab(idx).exp_item_data), a_diff_tab(idx).exp_data_id, a_diff_tab(idx).item_no, a_diff_tab(idx).dup_no); - exception when ut_utils.ex_failure_for_all then raise_application_error(ut_utils.gc_dml_for_all,'Failure to insert a diff tmp data.'); From bc6da9840cdbcf9c3ffa7a140e3a2b98a5aeec93 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 27 Jan 2022 16:17:12 +0000 Subject: [PATCH 203/887] Adding option to remove a cache for annotations whenever package is modified and annotation removed from procedure. --- .../ut_annotation_cache_manager.pkb | 15 +-- test/ut3_tester/core/test_suite_manager.pkb | 94 +++++++++++++++++++ test/ut3_tester/core/test_suite_manager.pks | 16 ++++ 3 files changed, 119 insertions(+), 6 deletions(-) diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index 17129c316..e1131b3bd 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -32,7 +32,7 @@ create or replace package body ut_annotation_cache_manager as end if; -- if not in trigger, or object has annotations - if ora_sysevent is null or a_object.annotations is not null and a_object.annotations.count > 0 then + if a_object.annotations is not null and a_object.annotations.count > 0 then update /*+ no_parallel */ ut_annotation_cache_info i set i.parse_time = l_timestamp @@ -47,16 +47,19 @@ create or replace package body ut_annotation_cache_manager as values (ut_annotation_cache_seq.nextval, a_object.object_owner, a_object.object_name, a_object.object_type, l_timestamp) returning cache_id into l_cache_id; end if; + + delete /*+ no_parallel */ from ut_annotation_cache c where cache_id = l_cache_id; - end if; - - delete /*+ no_parallel */ from ut_annotation_cache c where cache_id = l_cache_id; - - if a_object.annotations is not null and a_object.annotations.count > 0 then insert /*+ no_parallel */ into ut_annotation_cache (cache_id, annotation_position, annotation_name, annotation_text, subobject_name) select /*+ no_parallel */ l_cache_id, a.position, a.name, a.text, a.subobject_name from table(a_object.annotations) a; + elsif a_object.annotations is null or a_object.annotations.count = 0 then + ut_annotation_cache_manager.remove_from_cache( + ut_annotation_objs_cache_info( + ut_annotation_obj_cache_info(a_object.object_owner, a_object.object_name, a_object.object_type, 'Y', null) + ) + ); end if; commit; end; diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index 11cc7acfe..c8b4a9453 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -1466,5 +1466,99 @@ end;]'; ut.expect(SQLCODE).to_equal(ut3_develop.ut_utils.gc_value_too_large); end; + procedure setup_remove_annot_test is + pragma autonomous_transaction; + begin + execute immediate q'[create or replace package test_removing_annotation as + --%suite + + --%test + procedure test1; + + --%test + procedure test2; + +end;]'; + end; + + procedure remove_annot_from_test is + pragma autonomous_transaction; + begin + execute immediate q'[create or replace package test_removing_annotation as + + procedure test1; + + procedure test2; + +end;]'; + end; + + procedure rem_one_annot_test is + pragma autonomous_transaction; + begin + execute immediate q'[create or replace package test_removing_annotation as + --%suite + + procedure test1; + + --%test + procedure test2; + +end;]'; + execute immediate q'[create or replace package body test_removing_annotation as + + procedure test1 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test2 is + begin + ut.expect(1).to_equal(1); + end; + +end;]'; + end; + + procedure clean_remove_annot_test is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_removing_annotation'; + end; + + procedure test_rem_cache_on_create is + l_test_report ut3_develop.ut_varchar2_list; + begin + + select * bulk collect into l_test_report from table(ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER')||'.test_removing_annotation')); + + -- drop all tests + remove_annot_from_test; + + begin + select * bulk collect into l_test_report from table(ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER') || '.test_removing_annotation')); + exception + when others then + ut.expect(sqlerrm).to_be_like('%ORA-20204: Suite package ut3_tester.test_removing_annotation does not exist%'); + end; + + end; + + procedure test_rem_cache_on_crt_anno is + l_test_report ut3_develop.ut_varchar2_list; + l_results clob; + begin + + select * bulk collect into l_test_report from table(ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER')||'.test_removing_annotation')); + + -- drop single test + rem_one_annot_test; + ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER')|| '.test_removing_annotation',a_reporter => ut3_develop.ut_documentation_reporter() ); + l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); + --Assert + ut.expect( l_results ).to_be_like( '%1 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s)%' ); + + end; + end test_suite_manager; / diff --git a/test/ut3_tester/core/test_suite_manager.pks b/test/ut3_tester/core/test_suite_manager.pks index 90b589b9e..154df9ca6 100644 --- a/test/ut3_tester/core/test_suite_manager.pks +++ b/test/ut3_tester/core/test_suite_manager.pks @@ -170,5 +170,21 @@ create or replace package test_suite_manager is procedure create_dummy_long_test_package; procedure drop_dummy_long_test_package; + + procedure setup_remove_annot_test; + procedure clean_remove_annot_test; + + --%test(Remove cache on package create or replace when all annotations removed) + --%beforetest(setup_remove_annot_test) + --%aftertest(clean_remove_annot_test) + procedure test_rem_cache_on_create; + + + --%test(Remove cache on package create or replace when single annotation removed) + --%beforetest(setup_remove_annot_test) + --%aftertest(clean_remove_annot_test) + procedure test_rem_cache_on_crt_anno; + + end test_suite_manager; / From e3580375ff1d61e24fa345e5661e25cd3ae88e5c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 28 Jan 2022 18:55:40 +0000 Subject: [PATCH 204/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index c9ec27342..232846f54 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 9f271da68..b664a9b7a 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 307dd5a8b..83d1dc066 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 78de8ab87..16164a94b 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 000fcd906..be6b10a3e 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 8b1c1ef22..38498b481 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e2927918f..1b9b4faee 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 38234be6c..999a4ea9d 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 753fc1b5b..6e921c40c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 784fa65ac..830384f2b 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index debcd6025..c07f3782e 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index d2ac915a5..087fd91c1 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 87e3dba0c..aa869dc1e 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d41111356..d805dd936 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 67a424c6d..81cc1c5c8 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 9fb53e98f..e441c8ce6 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 92581f966..bee737ae7 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3719--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 6073eb50b..81a610a0c 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.12.3719-develop + * secion v3.1.12.3731-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 85f621842..c7d20ad0c 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3719-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3731-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 590fb38c589b661a07488310d6a1113f031bbe6c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 28 Jan 2022 23:20:04 +0200 Subject: [PATCH 205/887] Improving test stability (flaky tests) --- test/ut3_tester_helper/coverage_helper.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index e9385d7d9..0abe10a4f 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -173,7 +173,7 @@ create or replace package body coverage_helper is auto_drop => TRUE, comments => 'one-time-job' ); - while (l_status is null or l_status not in ('SUCCEEDED','FAILED')) and i < 30 loop + while (l_status is null or l_status not in ('SUCCEEDED','FAILED')) and i < 150 loop l_status := get_job_status( l_job_name, l_timestamp ); sleep(0.1); i := i + 1; From 5e2642ae2d0b8304bc8132a1015aaa08cf07e1ab Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 28 Jan 2022 23:23:12 +0200 Subject: [PATCH 206/887] Removing reference to ut3_develop schema. Added sql-injection check. --- source/expectations/matchers/ut_be_within_helper.pkb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/source/expectations/matchers/ut_be_within_helper.pkb b/source/expectations/matchers/ut_be_within_helper.pkb index aecaf7179..87fb2940b 100644 --- a/source/expectations/matchers/ut_be_within_helper.pkb +++ b/source/expectations/matchers/ut_be_within_helper.pkb @@ -26,13 +26,13 @@ create or replace package body ut_be_within_helper as :result := case when - treat(:a_value_1 as ut3_develop.]'||a_value_1.self_type||q'[).data_value + treat(:a_value_1 as ]'||dbms_assert.sql_object_name(a_value_1.self_type)||q'[).data_value between - treat(:a_value_2 as ut3_develop.]'||a_value_2.self_type||q'[).data_value - - treat(:a_distance as ut3_develop.]'||a_distance.self_type||q'[).data_value + treat(:a_value_2 as ]'||dbms_assert.sql_object_name(a_value_2.self_type)||q'[).data_value + - treat(:a_distance as ]'||dbms_assert.sql_object_name(a_distance.self_type)||q'[).data_value and - treat(:a_value_2 as ut3_develop.]'||a_value_2.self_type||q'[).data_value - + treat(:a_distance as ut3_develop.]'||a_distance.self_type||q'[).data_value + treat(:a_value_2 as ]'||dbms_assert.sql_object_name(a_value_2.self_type)||q'[).data_value + + treat(:a_distance as ]'||dbms_assert.sql_object_name(a_distance.self_type)||q'[).data_value then 1 else 0 end; From ed06e332faedcc77b1e67250faca258e11c7b4b3 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 28 Jan 2022 23:42:01 +0200 Subject: [PATCH 207/887] Relaxed sql-injection check to work with 11g2 --- source/expectations/matchers/ut_be_within_helper.pkb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/source/expectations/matchers/ut_be_within_helper.pkb b/source/expectations/matchers/ut_be_within_helper.pkb index 87fb2940b..14444ea3e 100644 --- a/source/expectations/matchers/ut_be_within_helper.pkb +++ b/source/expectations/matchers/ut_be_within_helper.pkb @@ -26,13 +26,13 @@ create or replace package body ut_be_within_helper as :result := case when - treat(:a_value_1 as ]'||dbms_assert.sql_object_name(a_value_1.self_type)||q'[).data_value + treat(:a_value_1 as ]'||dbms_assert.simple_sql_name(a_value_1.self_type)||q'[).data_value between - treat(:a_value_2 as ]'||dbms_assert.sql_object_name(a_value_2.self_type)||q'[).data_value - - treat(:a_distance as ]'||dbms_assert.sql_object_name(a_distance.self_type)||q'[).data_value + treat(:a_value_2 as ]'||dbms_assert.simple_sql_name(a_value_2.self_type)||q'[).data_value + - treat(:a_distance as ]'||dbms_assert.simple_sql_name(a_distance.self_type)||q'[).data_value and - treat(:a_value_2 as ]'||dbms_assert.sql_object_name(a_value_2.self_type)||q'[).data_value - + treat(:a_distance as ]'||dbms_assert.sql_object_name(a_distance.self_type)||q'[).data_value + treat(:a_value_2 as ]'||dbms_assert.simple_sql_name(a_value_2.self_type)||q'[).data_value + + treat(:a_distance as ]'||dbms_assert.simple_sql_name(a_distance.self_type)||q'[).data_value then 1 else 0 end; From c14a3adb30358b19e6e8ef67c32bc37fadfdfb09 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 28 Jan 2022 22:49:03 +0000 Subject: [PATCH 208/887] Address PR comments --- .../expectations/test_expectation_anydata.pks | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/test/ut3_user/expectations/test_expectation_anydata.pks b/test/ut3_user/expectations/test_expectation_anydata.pks index a073c0701..b11353ebb 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pks +++ b/test/ut3_user/expectations/test_expectation_anydata.pks @@ -204,28 +204,28 @@ create or replace package test_expectation_anydata is --%test ( Empty Array not equal array with space ) procedure arr_empty_nqua_arr_e_unord; - --%test ( Failure of comparing nested objects ) + --%test ( Reports diff between not equal nested objects ) procedure failure_nesting_objects; - --%test ( Failure of comparing double nested objects ) + --%test ( Reports diff between not equal double nested objects ) procedure failure_double_nested_objects; - --%test ( Success of comparing nested objects ) + --%test (Reports success when comparing identical nested object ) procedure success_nesting_objects; - --%test ( Success of comparing double nested objects ) + --%test ( Reports success when comparing identical double nested object ) procedure success_double_nested_objects; - --%test ( Failure of comparing nested object list ) + --%test ( Reports diff between two not equal nested object list ) procedure failure_nested_object_list; - --%test ( Success of comparing nested object list ) + --%test ( Reports success when comparing identical nested object list ) procedure success_nested_object_list; - --%test(Nested VARRAYS with same data) + --%test ( Reports success when comparing identical nested VARRAYS ) procedure nested_varray_same_data; - --%test(Nested VARRAYS with different data) + --%test ( Reports diff between two not equal nested VARRAYS ) procedure nested_varray_diff_data; end; / From a2cf02e38f3ad38384b938da0521bb669954320b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 29 Jan 2022 19:09:34 +0000 Subject: [PATCH 209/887] Creating regression test scenario for fixed issue 1098 and supporting test types. --- test/install_ut3_tester_helper.sql | 2 + .../test_dummy_dble_nest_lst_obj.tps | 17 ++++ .../test_dummy_double_nested_list.tps | 13 +++ .../test_dummy_nested_object_list.tps | 3 +- .../expectations/test_expectation_anydata.pkb | 90 ++++++++++++++++++- .../expectations/test_expectation_anydata.pks | 8 +- 6 files changed, 127 insertions(+), 6 deletions(-) create mode 100644 test/ut3_tester_helper/test_dummy_dble_nest_lst_obj.tps create mode 100644 test/ut3_tester_helper/test_dummy_double_nested_list.tps diff --git a/test/install_ut3_tester_helper.sql b/test/install_ut3_tester_helper.sql index b2e0d57c4..d9aacdf36 100644 --- a/test/install_ut3_tester_helper.sql +++ b/test/install_ut3_tester_helper.sql @@ -10,6 +10,8 @@ alter session set plsql_optimize_level=0; @@ut3_tester_helper/test_dummy_double_nested_object.tps @@ut3_tester_helper/test_dummy_object_list.tps @@ut3_tester_helper/test_dummy_nested_object_list.tps +@@ut3_tester_helper/test_dummy_double_nested_list.tps +@@ut3_tester_helper/test_dummy_dble_nest_lst_obj.tps @@ut3_tester_helper/test_tab_varchar2.tps @@ut3_tester_helper/test_tab_varray.tps @@ut3_tester_helper/test_nested_tab_varray.tps diff --git a/test/ut3_tester_helper/test_dummy_dble_nest_lst_obj.tps b/test/ut3_tester_helper/test_dummy_dble_nest_lst_obj.tps new file mode 100644 index 000000000..5134fef21 --- /dev/null +++ b/test/ut3_tester_helper/test_dummy_dble_nest_lst_obj.tps @@ -0,0 +1,17 @@ +declare + l_exists integer; +begin + select count(1) into l_exists from user_types where type_name = 'TEST_DUMMY_DBLE_NEST_LST_OBJ'; + if l_exists > 0 then + execute immediate 'drop type test_dummy_dble_nest_lst_obj force'; + end if; +end; +/ + +CREATE TYPE test_dummy_dble_nest_lst_obj AS OBJECT +( + some_number_id NUMBER, + some_name VARCHAR2 (25), + dummy_list test_dummy_double_nested_list +); +/ \ No newline at end of file diff --git a/test/ut3_tester_helper/test_dummy_double_nested_list.tps b/test/ut3_tester_helper/test_dummy_double_nested_list.tps new file mode 100644 index 000000000..625462824 --- /dev/null +++ b/test/ut3_tester_helper/test_dummy_double_nested_list.tps @@ -0,0 +1,13 @@ +declare + l_exists integer; +begin + select count(1) into l_exists from user_types where type_name = 'TEST_DUMMY_DOUBLE_NESTED_LIST'; + if l_exists > 0 then + execute immediate 'drop type test_dummy_double_nested_list force'; + end if; +end; +/ + +CREATE TYPE test_dummy_double_nested_list AS + TABLE OF test_dummy_nested_object_list; +/ diff --git a/test/ut3_tester_helper/test_dummy_nested_object_list.tps b/test/ut3_tester_helper/test_dummy_nested_object_list.tps index ca2c0d6df..fd47b55bd 100644 --- a/test/ut3_tester_helper/test_dummy_nested_object_list.tps +++ b/test/ut3_tester_helper/test_dummy_nested_object_list.tps @@ -9,6 +9,7 @@ end; / create or replace type test_dummy_nested_object_list as object ( - first_nested_obj test_dummy_object_list + first_nested_obj test_dummy_object_list, + somename varchar2(50) ) / \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index bd57a860a..d364afca0 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -1066,8 +1066,8 @@ Rows: [ 60 differences, showing first 20 ] from dual connect by level <=2 order by rownum desc; --Arrange - g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_actual)); - g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_expected)); + g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_actual,'Test')); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_expected,'Test')); --Act l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_nested_object_list was expected to equal: ut3_tester_helper.test_dummy_nested_object_list %Diff: @@ -1094,8 +1094,8 @@ Rows: [ 60 differences, showing first 20 ] from dual connect by level <=2 order by rownum desc; --Arrange - g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_actual)); - g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_expected)); + g_test_expected := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_actual,'Test')); + g_test_actual := anydata.convertObject( ut3_tester_helper.test_dummy_nested_object_list(l_expected,'Test')); --Act ut3_develop.ut.expect( g_test_actual ).to_equal( g_test_expected ); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); @@ -1129,5 +1129,87 @@ Rows: [ 60 differences, showing first 20 ] --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); end; + + procedure user_defined_type_null_issue_1098 is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + l_actual ut3_tester_helper.test_dummy_dble_nest_lst_obj; + l_expected ut3_tester_helper.test_dummy_dble_nest_lst_obj; + begin + l_actual:= ut3_tester_helper.test_dummy_dble_nest_lst_obj( + 1, 'North America', + ut3_tester_helper.test_dummy_double_nested_list ( + ut3_tester_helper.test_dummy_nested_object_list( + ut3_tester_helper.test_dummy_object_list( + ut3_tester_helper.test_dummy_object(1, '100 Broadway', 02474), + ut3_tester_helper.test_dummy_object(2, '200 Indian School Rd', 85016) + ),'USA' + ), + ut3_tester_helper.test_dummy_nested_object_list( + ut3_tester_helper.test_dummy_object_list(),'USA' + ) + ) + ); + + l_expected := ut3_tester_helper.test_dummy_dble_nest_lst_obj( + 1, + 'North America', + ut3_tester_helper.test_dummy_double_nested_list(ut3_tester_helper.test_dummy_nested_object_list(ut3_tester_helper.test_dummy_object_list( + ut3_tester_helper.test_dummy_object(1, '100 Broadway', 02474), + ut3_tester_helper.test_dummy_object(2, '200 Indian School Rd', 85016) + ), 'USA')) + ); + ut3_develop.ut.expect(anydata.convertObject(l_actual)).to_equal(anydata.convertObject(l_expected)).unordered; + + l_expected_message := q'[%Actual: ut3_tester_helper.test_dummy_dble_nest_lst_obj was expected to equal: ut3_tester_helper.test_dummy_dble_nest_lst_obj +%Diff: +%Rows: [ 2 differences ] +%Extra: 1North America1100 Broadway24742200 Indian School Rd85016USAUSA +%Missing: 1North America1100 Broadway24742200 Indian School Rd85016USA]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + + end; + + procedure complex_nested_object_success is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + l_actual ut3_tester_helper.test_dummy_dble_nest_lst_obj; + l_expected ut3_tester_helper.test_dummy_dble_nest_lst_obj; + begin + l_actual:= ut3_tester_helper.test_dummy_dble_nest_lst_obj( + 1, 'North America', + ut3_tester_helper.test_dummy_double_nested_list ( + ut3_tester_helper.test_dummy_nested_object_list( + ut3_tester_helper.test_dummy_object_list( + ut3_tester_helper.test_dummy_object(1, '100 Broadway', 02474), + ut3_tester_helper.test_dummy_object(2, '200 Indian School Rd', 85016) + ),'USA' + ), + ut3_tester_helper.test_dummy_nested_object_list( + ut3_tester_helper.test_dummy_object_list(),'USA' + ) + ) + ); + + l_expected := ut3_tester_helper.test_dummy_dble_nest_lst_obj( + 1, 'North America', + ut3_tester_helper.test_dummy_double_nested_list ( + ut3_tester_helper.test_dummy_nested_object_list( + ut3_tester_helper.test_dummy_object_list( + ut3_tester_helper.test_dummy_object(1, '100 Broadway', 02474), + ut3_tester_helper.test_dummy_object(2, '200 Indian School Rd', 85016) + ),'USA' + ), + ut3_tester_helper.test_dummy_nested_object_list( + ut3_tester_helper.test_dummy_object_list(),'USA' + ) + ) + ); + ut3_develop.ut.expect(anydata.convertObject(l_actual)).to_equal(anydata.convertObject(l_expected)).unordered; + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + + end; end; / \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectation_anydata.pks b/test/ut3_user/expectations/test_expectation_anydata.pks index b11353ebb..c954eed49 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pks +++ b/test/ut3_user/expectations/test_expectation_anydata.pks @@ -226,6 +226,12 @@ create or replace package test_expectation_anydata is procedure nested_varray_same_data; --%test ( Reports diff between two not equal nested VARRAYS ) - procedure nested_varray_diff_data; + procedure nested_varray_diff_data; + + --%test ( Comparision won't fail on user_defined type that is null as per issue 1098 ) + procedure user_defined_type_null_issue_1098; + + --%test ( Reports success when comparing complex nested objects ) + procedure complex_nested_object_success; end; / From b11e799c3f9f329c05befa5087c0d89c7f60bf25 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 29 Jan 2022 19:20:07 +0000 Subject: [PATCH 210/887] Fixing an 11g limit on size of the procedure of 30. --- test/ut3_user/expectations/test_expectation_anydata.pkb | 2 +- test/ut3_user/expectations/test_expectation_anydata.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index d364afca0..98938c107 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -1130,7 +1130,7 @@ Rows: [ 60 differences, showing first 20 ] ut.expect(l_actual_message).to_be_like(l_expected_message); end; - procedure user_defined_type_null_issue_1098 is + procedure user_def_type_null_issue_1098 is l_actual_message varchar2(32767); l_expected_message varchar2(32767); l_actual ut3_tester_helper.test_dummy_dble_nest_lst_obj; diff --git a/test/ut3_user/expectations/test_expectation_anydata.pks b/test/ut3_user/expectations/test_expectation_anydata.pks index c954eed49..2abb48b7f 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pks +++ b/test/ut3_user/expectations/test_expectation_anydata.pks @@ -229,7 +229,7 @@ create or replace package test_expectation_anydata is procedure nested_varray_diff_data; --%test ( Comparision won't fail on user_defined type that is null as per issue 1098 ) - procedure user_defined_type_null_issue_1098; + procedure user_def_type_null_issue_1098; --%test ( Reports success when comparing complex nested objects ) procedure complex_nested_object_success; From f091985ca0cd69eec255ac24919165c9cf6b215d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 29 Jan 2022 21:14:56 +0000 Subject: [PATCH 211/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 232846f54..9d2c26e0b 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index b664a9b7a..67cb1a976 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 83d1dc066..92889b02c 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 16164a94b..33db70018 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index be6b10a3e..a459f259a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 38498b481..340952f7e 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 1b9b4faee..cade9ac97 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 999a4ea9d..270f07a8e 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 6e921c40c..a6037b4e2 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 830384f2b..11cad317f 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c07f3782e..488fbeea9 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 087fd91c1..7610573e5 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index aa869dc1e..548a2cb5a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d805dd936..88a724257 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 81cc1c5c8..dae47df96 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index e441c8ce6..6731fada4 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index bee737ae7..cde37ed6d 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3731--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 5b8a57b3b..af3b3498e 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.12.3731-develop + * secion v3.1.12.3742-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c7d20ad0c..5e0b7820e 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3731-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3742-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 38f3cbc1ff2ea87627e6744481715fa6571ad36a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 31 Jan 2022 01:48:12 +0200 Subject: [PATCH 212/887] Fixed issues with comparison of dates×tamps using interval year-month Improved error handling for null values and incompatible datatypes Improved handling of negative dates (BC) Improved reporting of interval text value Improved datatypes to handle large&small precissions for timestamps --- docs/userguide/expectations.md | 38 ++--- source/core/ut_utils.pkb | 33 +++-- source/core/ut_utils.pks | 6 +- .../data_values/ut_data_value.tps | 1 + .../data_values/ut_data_value_blob.tpb | 1 + .../data_values/ut_data_value_boolean.tpb | 1 + .../data_values/ut_data_value_clob.tpb | 1 + .../data_values/ut_data_value_date.tpb | 1 + .../data_values/ut_data_value_dsinterval.tpb | 1 + .../data_values/ut_data_value_number.tpb | 1 + .../data_values/ut_data_value_refcursor.tpb | 1 + .../data_values/ut_data_value_timestamp.tpb | 1 + .../ut_data_value_timestamp_ltz.tpb | 1 + .../ut_data_value_timestamp_tz.tpb | 1 + .../data_values/ut_data_value_varchar2.tpb | 1 + .../data_values/ut_data_value_xmltype.tpb | 1 + .../data_values/ut_data_value_yminterval.tpb | 1 + source/expectations/matchers/ut_be_within.tpb | 46 +++--- source/expectations/matchers/ut_be_within.tps | 6 +- .../matchers/ut_be_within_helper.pkb | 33 +++-- .../matchers/ut_be_within_helper.pks | 2 +- .../matchers/ut_be_within_pct.tpb | 13 +- .../matchers/ut_be_within_pct.tps | 5 +- test/ut3_tester/core/test_ut_utils.pkb | 8 +- test/ut3_user/api/test_ut_run.pkb | 42 +++--- .../expectations/binary/test_to_be_within.pkb | 136 +++++++++++++++++- .../expectations/binary/test_to_be_within.pks | 29 +++- .../binary/test_to_be_within_pct.pkb | 2 +- .../reporters/test_debug_reporter.pkb | 2 +- 29 files changed, 312 insertions(+), 103 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 851eb9955..833235c24 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -316,25 +316,25 @@ Since NULL is neither *true* nor *false*, both expectations will report failure. The matrix below illustrates the data types supported by different matchers. -| Matcher | blob | boolean | clob | date | number | timestamp | timestamp
with
timezone | timestamp
with
local
timezone | varchar2 | interval
year
to
month | interval
day
to
second | cursor | nested
table
/ varray | object | json | -| :---------------------: | :--: | :-----: | :--: | :--: | :----: | :-------: | :---------------------------: | :------------------------------------: | :------: | :-----------------------------: | :-----------------------------: | :----: | :-------------------------: | :----: | :--: | -| **be_not_null** | X | X | X | X | X | X | X | X | X | X | X | X | X | X | X | -| **be_null** | X | X | X | X | X | X | X | X | X | X | X | X | X | X | X | -| **be_false** | | X | | | | | | | | | | | | | | -| **be_true** | | X | | | | | | | | | | | | | | -| **be_greater_than** | | | | X | X | X | X | X | | X | X | | | | | -| **be_greater_or_equal** | | | | X | X | X | X | X | | X | X | | | | | -| **be_less_or_equal** | | | | X | X | X | X | X | | X | X | | | | | -| **be_less_than** | | | | X | X | X | X | X | | X | X | | | | | -| **be_between** | | | | X | X | X | X | X | X | X | X | | | | | -| **equal** | X | X | X | X | X | X | X | X | X | X | X | X | X | X | X | -| **contain** | | | | | | | | | | | | X | X | X | | -| **match** | | | X | | | | | | X | | | | | | | -| **be_like** | | | X | | | | | | X | | | | | | | -| **be_empty** | X | | X | | | | | | | | | X | X | | X | -| **have_count** | | | | | | | | | | | | X | X | | X | -| **be_within().of_()** | | | | x | x | | | | | | | | | | | -| **be_within_pct().of()**| | | | | x | | | | | | | | | | | +| Matcher | blob | boolean | clob | date | number | timestamp | timestamp
with
timezone | timestamp
with
local
timezone | varchar2 | interval
year
to
month | interval
day
to
second | cursor | nested
table
/ varray | object | json | +| :-----------------------: | :--: | :-----: | :--: | :--: | :----: | :-------: | :---------------------------: | :------------------------------------: | :------: | :-----------------------------: | :-----------------------------: | :----: | :-------------------------: | :----: | :--: | +| **be_not_null** | X | X | X | X | X | X | X | X | X | X | X | X | X | X | X | +| **be_null** | X | X | X | X | X | X | X | X | X | X | X | X | X | X | X | +| **be_false** | | X | | | | | | | | | | | | | | +| **be_true** | | X | | | | | | | | | | | | | | +| **be_greater_than** | | | | X | X | X | X | X | | X | X | | | | | +| **be_greater_or_equal** | | | | X | X | X | X | X | | X | X | | | | | +| **be_less_or_equal** | | | | X | X | X | X | X | | X | X | | | | | +| **be_less_than** | | | | X | X | X | X | X | | X | X | | | | | +| **be_between** | | | | X | X | X | X | X | X | X | X | | | | | +| **equal** | X | X | X | X | X | X | X | X | X | X | X | X | X | X | X | +| **contain** | | | | | | | | | | | | X | X | X | | +| **match** | | | X | | | | | | X | | | | | | | +| **be_like** | | | X | | | | | | X | | | | | | | +| **be_empty** | X | | X | | | | | | | | | X | X | | X | +| **have_count** | | | | | | | | | | | | X | X | | X | +| **be_within().of_()** | | | | x | x | | | | | | | | | | | +| **be_within_pct().of_()** | | | | | x | | | | | | | | | | | # Expecting exceptions diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 1c1943f1d..655b20d3d 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -919,12 +919,20 @@ create or replace package body ut_utils is when l_minute > 1 then ' '||l_minute ||' minutes' end || case - when l_second = 1 then ' '||l_second ||' second' - when l_second > 1 then ' '||l_second ||' seconds' - end; - return trim(leading ' ' from l_result); + when l_second > 1 then ' '||l_second ||' seconds' + when l_second = 1 then ' '||l_second ||' second' + when l_second > 0 then ' '||l_second ||' seconds' + end; + l_result := + case + when a_interval is null then 'NULL' + when l_result is null then '0 seconds' + else ltrim(l_result,' ') + end; + + return l_result; end; - + function interval_to_text(a_interval yminterval_unconstrained) return varchar2 is l_year varchar2(4) := extract(year from a_interval); l_month varchar2(20) := extract(month from a_interval); @@ -935,10 +943,17 @@ create or replace package body ut_utils is when l_year > 1 then l_year ||' years' end || case - when l_month = 1 then ' '||l_month ||' month' - when l_month > 1 then ' '||l_month ||' months' - end; - return trim(leading ' ' from l_result); + when l_month > 1 then ' '||l_month ||' months' + when l_month = 1 then ' '||l_month ||' month' + end; + l_result := + case + when a_interval is null then 'NULL' + when l_result is null then '0 months' + else ltrim(l_result,' ') + end; + + return l_result; end; diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 228500396..4c8b14e3d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -127,9 +127,9 @@ create or replace package ut_utils authid definer is gc_more_data_string constant varchar2(5) := '[...]'; gc_more_data_string_len constant integer := length( gc_more_data_string ); gc_number_format constant varchar2(100) := 'TM9'; - gc_date_format constant varchar2(100) := 'yyyy-mm-dd"T"hh24:mi:ss'; - gc_timestamp_format constant varchar2(100) := 'yyyy-mm-dd"T"hh24:mi:ssxff'; - gc_timestamp_tz_format constant varchar2(100) := 'yyyy-mm-dd"T"hh24:mi:ssxff tzh:tzm'; + gc_date_format constant varchar2(100) := 'syyyy-mm-dd"T"hh24:mi:ss'; + gc_timestamp_format constant varchar2(100) := 'syyyy-mm-dd"T"hh24:mi:ssxff'; + gc_timestamp_tz_format constant varchar2(100) := 'syyyy-mm-dd"T"hh24:mi:ssxff tzh:tzm'; gc_null_string constant varchar2(4) := 'NULL'; gc_empty_string constant varchar2(5) := 'EMPTY'; diff --git a/source/expectations/data_values/ut_data_value.tps b/source/expectations/data_values/ut_data_value.tps index 6864bc52e..beda3d911 100644 --- a/source/expectations/data_values/ut_data_value.tps +++ b/source/expectations/data_values/ut_data_value.tps @@ -16,6 +16,7 @@ create or replace type ut_data_value force authid current_user as object ( limitations under the License. */ data_type varchar2(250 char), + data_type_plsql varchar2(250 char), self_type varchar2(250 char), not instantiable member function is_null return boolean, not instantiable member function to_string return varchar2, diff --git a/source/expectations/data_values/ut_data_value_blob.tpb b/source/expectations/data_values/ut_data_value_blob.tpb index a7b5fbeca..e145a8d4f 100644 --- a/source/expectations/data_values/ut_data_value_blob.tpb +++ b/source/expectations/data_values/ut_data_value_blob.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_blob as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'blob'; + self.data_type_plsql := 'blob'; return; end; diff --git a/source/expectations/data_values/ut_data_value_boolean.tpb b/source/expectations/data_values/ut_data_value_boolean.tpb index 798222e30..867c3c19c 100644 --- a/source/expectations/data_values/ut_data_value_boolean.tpb +++ b/source/expectations/data_values/ut_data_value_boolean.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_boolean as self.data_value := ut_utils.boolean_to_int(a_value); self.self_type := $$plsql_unit; self.data_type := 'boolean'; + self.data_type_plsql := 'boolean'; return; end; diff --git a/source/expectations/data_values/ut_data_value_clob.tpb b/source/expectations/data_values/ut_data_value_clob.tpb index 9cfe9b283..f8a53a035 100644 --- a/source/expectations/data_values/ut_data_value_clob.tpb +++ b/source/expectations/data_values/ut_data_value_clob.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_clob as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'clob'; + self.data_type_plsql := 'clob'; return; end; diff --git a/source/expectations/data_values/ut_data_value_date.tpb b/source/expectations/data_values/ut_data_value_date.tpb index 5b5b1d387..20424d193 100644 --- a/source/expectations/data_values/ut_data_value_date.tpb +++ b/source/expectations/data_values/ut_data_value_date.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_date as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'date'; + self.data_type_plsql := 'date'; return; end; diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tpb b/source/expectations/data_values/ut_data_value_dsinterval.tpb index fd6b03234..026d4970f 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tpb +++ b/source/expectations/data_values/ut_data_value_dsinterval.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_dsinterval as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'interval day to second'; + self.data_type_plsql := 'dsinterval_unconstrained'; return; end; diff --git a/source/expectations/data_values/ut_data_value_number.tpb b/source/expectations/data_values/ut_data_value_number.tpb index c5c4fe2c3..382e6e9aa 100644 --- a/source/expectations/data_values/ut_data_value_number.tpb +++ b/source/expectations/data_values/ut_data_value_number.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_number as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'number'; + self.data_type_plsql := 'number'; return; end; diff --git a/source/expectations/data_values/ut_data_value_refcursor.tpb b/source/expectations/data_values/ut_data_value_refcursor.tpb index 2715614c4..a4f0cf7a0 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tpb +++ b/source/expectations/data_values/ut_data_value_refcursor.tpb @@ -81,6 +81,7 @@ create or replace type body ut_data_value_refcursor as self.self_type := $$plsql_unit; self.data_id := sys_guid(); self.data_type := 'refcursor'; + self.data_type_plsql := 'sys_refcursor'; self.compound_type := 'refcursor'; self.extract_path := '/*'; ut_compound_data_helper.cleanup_diff; diff --git a/source/expectations/data_values/ut_data_value_timestamp.tpb b/source/expectations/data_values/ut_data_value_timestamp.tpb index 79facae4a..318f799a3 100644 --- a/source/expectations/data_values/ut_data_value_timestamp.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_timestamp as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'timestamp'; + self.data_type_plsql := 'timestamp_unconstrained'; return; end; diff --git a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb index f2c5cddbd..6127de5f1 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_timestamp_ltz as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'timestamp with local time zone'; + self.data_type_plsql := 'timestamp_ltz_unconstrained'; return; end; diff --git a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb index 0991e9e9f..d5d5cdd13 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_timestamp_tz as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'timestamp with time zone'; + self.data_type_plsql := 'timestamp_tz_unconstrained'; return; end; diff --git a/source/expectations/data_values/ut_data_value_varchar2.tpb b/source/expectations/data_values/ut_data_value_varchar2.tpb index 307ca583d..d04398697 100644 --- a/source/expectations/data_values/ut_data_value_varchar2.tpb +++ b/source/expectations/data_values/ut_data_value_varchar2.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_varchar2 as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'varchar2'; + self.data_type_plsql := 'varchar2(32767)'; return; end; diff --git a/source/expectations/data_values/ut_data_value_xmltype.tpb b/source/expectations/data_values/ut_data_value_xmltype.tpb index d17896492..4b21a8937 100644 --- a/source/expectations/data_values/ut_data_value_xmltype.tpb +++ b/source/expectations/data_values/ut_data_value_xmltype.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_xmltype as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'xmltype'; + self.data_type_plsql := 'xmltype'; return; end; diff --git a/source/expectations/data_values/ut_data_value_yminterval.tpb b/source/expectations/data_values/ut_data_value_yminterval.tpb index df4a46a5c..a3a1e7a2f 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tpb +++ b/source/expectations/data_values/ut_data_value_yminterval.tpb @@ -21,6 +21,7 @@ create or replace type body ut_data_value_yminterval as self.data_value := a_value; self.self_type := $$plsql_unit; self.data_type := 'interval year to month'; + self.data_type_plsql := 'yminterval_unconstrained'; return; end; diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index c411c4f61..e2aa792d0 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -39,9 +39,9 @@ create or replace type body ut_be_within as begin l_result.expected := ut_data_value_date(a_expected); if l_result.is_negated_flag = 1 then - l_result.expectation.not_to(l_result ); + l_result.expectation.not_to(l_result); else - l_result.expectation.to_(l_result ); + l_result.expectation.to_(l_result); end if; end; @@ -51,33 +51,33 @@ create or replace type body ut_be_within as l_result.expected := ut_data_value_date(a_expected); return l_result; end; - - member procedure of_(self in ut_be_within, a_expected timestamp) is + + member procedure of_(self in ut_be_within, a_expected timestamp_unconstrained) is l_result ut_be_within := self; begin l_result.expected := ut_data_value_timestamp(a_expected); if l_result.is_negated_flag = 1 then - l_result.expectation.not_to(l_result ); + l_result.expectation.not_to(l_result); else - l_result.expectation.to_(l_result ); + l_result.expectation.to_(l_result); end if; end; - member function of_(self in ut_be_within, a_expected timestamp) return ut_be_within is + member function of_(self in ut_be_within, a_expected timestamp_unconstrained) return ut_be_within is l_result ut_be_within := self; begin l_result.expected := ut_data_value_timestamp(a_expected); return l_result; - end; + end; member procedure of_(self in ut_be_within, a_expected timestamp_tz_unconstrained) is l_result ut_be_within := self; begin l_result.expected := ut_data_value_timestamp_tz(a_expected); if l_result.is_negated_flag = 1 then - l_result.expectation.not_to(l_result ); + l_result.expectation.not_to(l_result); else - l_result.expectation.to_(l_result ); + l_result.expectation.to_(l_result); end if; end; @@ -86,16 +86,16 @@ create or replace type body ut_be_within as begin l_result.expected := ut_data_value_timestamp_tz(a_expected); return l_result; - end; - + end; + member procedure of_(self in ut_be_within, a_expected timestamp_ltz_unconstrained) is l_result ut_be_within := self; begin l_result.expected := ut_data_value_timestamp_ltz(a_expected); if l_result.is_negated_flag = 1 then - l_result.expectation.not_to(l_result ); + l_result.expectation.not_to(l_result); else - l_result.expectation.to_(l_result ); + l_result.expectation.to_(l_result); end if; end; @@ -104,17 +104,19 @@ create or replace type body ut_be_within as begin l_result.expected := ut_data_value_timestamp_ltz(a_expected); return l_result; - end; - + end; + overriding member function run_matcher(self in out nocopy ut_be_within, a_actual ut_data_value) return boolean is l_result boolean; begin - if self.expected.data_type = a_actual.data_type then - if self.expected is of (ut_data_value_date, ut_data_value_number, ut_data_value_timestamp, ut_data_value_timestamp_tz, ut_data_value_timestamp_ltz) then - l_result := ut_be_within_helper.values_within_abs_distance(self.expected, a_actual, self.distance_from_expected) ; - else - l_result := (self as ut_matcher).run_matcher(a_actual); - end if; + if self.expected.data_type = a_actual.data_type + and ( + self.expected is of (ut_data_value_date, ut_data_value_timestamp, ut_data_value_timestamp_tz, ut_data_value_timestamp_ltz) + and self.distance_from_expected is of (ut_data_value_yminterval, ut_data_value_dsinterval) + or self.expected is of (ut_data_value_number) and self.distance_from_expected is of (ut_data_value_number) + ) + then + l_result := ut_be_within_helper.values_within_abs_distance( a_actual, self.expected, self.distance_from_expected) ; else l_result := (self as ut_matcher).run_matcher(a_actual); end if; diff --git a/source/expectations/matchers/ut_be_within.tps b/source/expectations/matchers/ut_be_within.tps index 0b14bce44..576f9ff37 100644 --- a/source/expectations/matchers/ut_be_within.tps +++ b/source/expectations/matchers/ut_be_within.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_within under ut_be_within_pct( +create or replace type ut_be_within force under ut_be_within_pct( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -22,8 +22,8 @@ create or replace type ut_be_within under ut_be_within_pct( constructor function ut_be_within(self in out nocopy ut_be_within, a_distance_from_expected yminterval_unconstrained) return self as result, member procedure of_(self in ut_be_within, a_expected date), member function of_(self in ut_be_within, a_expected date) return ut_be_within, - member procedure of_(self in ut_be_within, a_expected timestamp), - member function of_(self in ut_be_within, a_expected timestamp) return ut_be_within, + member procedure of_(self in ut_be_within, a_expected timestamp_unconstrained), + member function of_(self in ut_be_within, a_expected timestamp_unconstrained) return ut_be_within, member procedure of_(self in ut_be_within, a_expected timestamp_tz_unconstrained ), member function of_(self in ut_be_within, a_expected timestamp_tz_unconstrained) return ut_be_within, member procedure of_(self in ut_be_within, a_expected timestamp_ltz_unconstrained), diff --git a/source/expectations/matchers/ut_be_within_helper.pkb b/source/expectations/matchers/ut_be_within_helper.pkb index 14444ea3e..5dd82baa2 100644 --- a/source/expectations/matchers/ut_be_within_helper.pkb +++ b/source/expectations/matchers/ut_be_within_helper.pkb @@ -17,28 +17,37 @@ create or replace package body ut_be_within_helper as */ function values_within_abs_distance( - a_value_1 ut_data_value, a_value_2 ut_data_value, a_distance ut_data_value + a_actual ut_data_value, a_expected ut_data_value, a_distance ut_data_value ) return boolean is l_result integer; + l_YM_conversion varchar2(50) := case when a_distance is of (ut_data_value_yminterval) then ' year to month ' end; + l_formula varchar2(4000); + l_code varchar2(4000); begin - execute immediate q'[ + l_formula := + case + when a_actual is of (ut_data_value_date) + then '( cast(greatest(l_actual, l_expected) as timestamp) - cast(least(l_actual, l_expected) as timestamp) ) '||l_YM_conversion||' <= l_distance' + else '( greatest(l_actual, l_expected) - least(l_actual, l_expected) ) '||l_YM_conversion||' <= l_distance' + end; + l_code := + q'[ + declare + l_actual ]'||dbms_assert.simple_sql_name(a_actual.data_type_plsql)|| q'[ := treat(:a_actual as ]'||dbms_assert.simple_sql_name(a_actual.self_type)||q'[).data_value; + l_expected ]'||dbms_assert.simple_sql_name(a_expected.data_type_plsql)||q'[ := treat(:a_expected as ]'||dbms_assert.simple_sql_name(a_expected.self_type)||q'[).data_value; + l_distance ]'||dbms_assert.simple_sql_name(a_distance.data_type_plsql)||q'[ := treat(:a_distance as ]'||dbms_assert.simple_sql_name(a_distance.self_type)||q'[).data_value; begin :result := case - when - treat(:a_value_1 as ]'||dbms_assert.simple_sql_name(a_value_1.self_type)||q'[).data_value - between - treat(:a_value_2 as ]'||dbms_assert.simple_sql_name(a_value_2.self_type)||q'[).data_value - - treat(:a_distance as ]'||dbms_assert.simple_sql_name(a_distance.self_type)||q'[).data_value - and - treat(:a_value_2 as ]'||dbms_assert.simple_sql_name(a_value_2.self_type)||q'[).data_value - + treat(:a_distance as ]'||dbms_assert.simple_sql_name(a_distance.self_type)||q'[).data_value + when + ]'||l_formula||q'[ then 1 else 0 end; end; - ]' - using out l_result, a_value_1, a_value_2, a_distance; + ]'; + execute immediate l_code + using a_actual, a_expected, a_distance, out l_result; return l_result > 0; end; diff --git a/source/expectations/matchers/ut_be_within_helper.pks b/source/expectations/matchers/ut_be_within_helper.pks index 0cb146a98..41737cc8f 100644 --- a/source/expectations/matchers/ut_be_within_helper.pks +++ b/source/expectations/matchers/ut_be_within_helper.pks @@ -17,7 +17,7 @@ create or replace package ut_be_within_helper authid definer as */ function values_within_abs_distance( - a_value_1 ut_data_value, a_value_2 ut_data_value, a_distance ut_data_value + a_actual ut_data_value, a_expected ut_data_value, a_distance ut_data_value ) return boolean; end; diff --git a/source/expectations/matchers/ut_be_within_pct.tpb b/source/expectations/matchers/ut_be_within_pct.tpb index bf662c066..fabab2d09 100644 --- a/source/expectations/matchers/ut_be_within_pct.tpb +++ b/source/expectations/matchers/ut_be_within_pct.tpb @@ -33,9 +33,9 @@ create or replace type body ut_be_within_pct as begin l_result.expected := ut_data_value_number(a_expected); if l_result.is_negated_flag = 1 then - l_result.expectation.not_to(l_result ); + l_result.expectation.not_to(l_result); else - l_result.expectation.to_(l_result ); + l_result.expectation.to_(l_result); end if; end; @@ -72,5 +72,14 @@ create or replace type body ut_be_within_pct as return rtrim( (self as ut_matcher).failure_message_when_negated(a_actual), 'pct' ) || self.distance_from_expected.to_string ||' % of '|| expected.to_string_report(); end; + overriding member function error_message(a_actual ut_data_value) return varchar2 is + l_result varchar2(32767); + begin + if ut_utils.int_to_boolean(self.is_errored) then + l_result := 'Matcher '''||self.name()||''' cannot be used to compare Actual ('||a_actual.data_type||') with Expected ('||expected.data_type||') using distance ('||self.distance_from_expected.data_type||').'; + end if; + return l_result; + end; + end; / diff --git a/source/expectations/matchers/ut_be_within_pct.tps b/source/expectations/matchers/ut_be_within_pct.tps index b1c7e4dfc..499e9a2d8 100644 --- a/source/expectations/matchers/ut_be_within_pct.tps +++ b/source/expectations/matchers/ut_be_within_pct.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_within_pct under ut_comparison_matcher( +create or replace type ut_be_within_pct force under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2019 utPLSQL Project @@ -28,7 +28,8 @@ create or replace type ut_be_within_pct under ut_comparison_matcher( member function of_(self in ut_be_within_pct, a_expected number) return ut_be_within_pct, overriding member function run_matcher(self in out nocopy ut_be_within_pct, a_actual ut_data_value) return boolean, overriding member function failure_message(a_actual ut_data_value) return varchar2, - overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2 + overriding member function failure_message_when_negated(a_actual ut_data_value) return varchar2, + overriding member function error_message(a_actual ut_data_value) return varchar2 ) not final / diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 61bc61a84..4ed718777 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -159,28 +159,28 @@ end;]' using p_expected_list; procedure to_string_date is l_value date := to_date('2016-12-31 23:59:59', 'yyyy-mm-dd hh24:mi:ss'); - l_expected varchar2(100) := '2016-12-31T23:59:59'; + l_expected varchar2(100) := ' 2016-12-31T23:59:59'; begin ut.expect(ut3_develop.ut_data_value_date(l_value).to_string()).to_equal(l_expected); end; procedure to_string_timestamp is l_value timestamp(9) := to_timestamp('2016-12-31 23:59:59.123456789', 'yyyy-mm-dd hh24:mi:ss.ff'); - l_expected varchar2(100) := '2016-12-31T23:59:59'||gc_delimiter||'123456789'; + l_expected varchar2(100) := ' 2016-12-31T23:59:59'||gc_delimiter||'123456789'; begin ut.expect(ut3_develop.ut_data_value_timestamp(l_value).to_string()).to_equal(l_expected); end; procedure to_string_timestamp_ltz is l_value timestamp(9) with local time zone := to_timestamp('2016-12-31 23:59:59.123456789', 'yyyy-mm-dd hh24:mi:ss.ff'); - l_expected varchar2(100) := '2016-12-31T23:59:59'||gc_delimiter||'123456789'; + l_expected varchar2(100) := ' 2016-12-31T23:59:59'||gc_delimiter||'123456789'; begin ut.expect(ut3_develop.ut_data_value_timestamp_ltz(l_value).to_string()).to_equal(l_expected); end; procedure to_string_timestamp_tz is l_value timestamp(9) with time zone := to_timestamp_tz('2016-12-31 23:59:59.123456789 -8:00', 'yyyy-mm-dd hh24:mi:ss.ff tzh:tzm'); - l_expected varchar2(100) := '2016-12-31T23:59:59'||gc_delimiter||'123456789 -08:00'; + l_expected varchar2(100) := ' 2016-12-31T23:59:59'||gc_delimiter||'123456789 -08:00'; begin ut.expect(ut3_develop.ut_data_value_timestamp_tz(l_value).to_string()).to_equal(l_expected); end; diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index e3af7c5ad..19c69c74e 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1272,7 +1272,7 @@ Failures:% ||'%BEFORE_SUITE:SUITE_DESCRIPTION=Suite description' ||'%BEFORE_SUITE:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%BEFORE_SUITE:SUITE_PATH=some.suite.path.check_context' - ||'%BEFORE_SUITE:SUITE_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_SUITE:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=before_suite%' @@ -1287,14 +1287,14 @@ Failures:% '%BEFORE_CONTEXT:CONTEXT_DESCRIPTION=context description' ||'%BEFORE_CONTEXT:CONTEXT_NAME=some_context' ||'%BEFORE_CONTEXT:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%BEFORE_CONTEXT:CONTEXT_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_CONTEXT:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_CONTEXT:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.before_context' ||'%BEFORE_CONTEXT:CURRENT_EXECUTABLE_TYPE=beforeall' ||'%BEFORE_CONTEXT:RUN_PATHS=check_context' ||'%BEFORE_CONTEXT:SUITE_DESCRIPTION=Suite description' ||'%BEFORE_CONTEXT:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%BEFORE_CONTEXT:SUITE_PATH=some.suite.path.check_context' - ||'%BEFORE_CONTEXT:SUITE_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_CONTEXT:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=before_context%' @@ -1308,17 +1308,17 @@ Failures:% '%BEFORE_EACH_TEST:CONTEXT_DESCRIPTION=context description' ||'%BEFORE_EACH_TEST:CONTEXT_NAME=some_context' ||'%BEFORE_EACH_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%BEFORE_EACH_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_EACH_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_EACH_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.before_each_test' ||'%BEFORE_EACH_TEST:CURRENT_EXECUTABLE_TYPE=beforeeach' ||'%BEFORE_EACH_TEST:RUN_PATHS=check_context' ||'%BEFORE_EACH_TEST:SUITE_DESCRIPTION=Suite description' ||'%BEFORE_EACH_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%BEFORE_EACH_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%BEFORE_EACH_TEST:SUITE_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_EACH_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_EACH_TEST:TEST_DESCRIPTION=Some test description' ||'%BEFORE_EACH_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%BEFORE_EACH_TEST:TEST_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_EACH_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=before_each_test%' @@ -1331,17 +1331,17 @@ Failures:% '%BEFORE_TEST:CONTEXT_DESCRIPTION=context description' ||'%BEFORE_TEST:CONTEXT_NAME=some_context' ||'%BEFORE_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%BEFORE_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.before_test' ||'%BEFORE_TEST:CURRENT_EXECUTABLE_TYPE=beforetest' ||'%BEFORE_TEST:RUN_PATHS=check_context' ||'%BEFORE_TEST:SUITE_DESCRIPTION=Suite description' ||'%BEFORE_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%BEFORE_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%BEFORE_TEST:SUITE_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_TEST:TEST_DESCRIPTION=Some test description' ||'%BEFORE_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%BEFORE_TEST:TEST_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=before_test%' @@ -1354,17 +1354,17 @@ Failures:% '%THE_TEST:CONTEXT_DESCRIPTION=context description' ||'%THE_TEST:CONTEXT_NAME=some_context' ||'%THE_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%THE_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%THE_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%THE_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.the_test' ||'%THE_TEST:CURRENT_EXECUTABLE_TYPE=test' ||'%THE_TEST:RUN_PATHS=check_context' ||'%THE_TEST:SUITE_DESCRIPTION=Suite description' ||'%THE_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%THE_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%THE_TEST:SUITE_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%THE_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%THE_TEST:TEST_DESCRIPTION=Some test description' ||'%THE_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%THE_TEST:TEST_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%THE_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=the_test%' @@ -1377,17 +1377,17 @@ Failures:% '%AFTER_TEST:CONTEXT_DESCRIPTION=context description' ||'%AFTER_TEST:CONTEXT_NAME=some_context' ||'%AFTER_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%AFTER_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%AFTER_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.after_test' ||'%AFTER_TEST:CURRENT_EXECUTABLE_TYPE=aftertest' ||'%AFTER_TEST:RUN_PATHS=check_context' ||'%AFTER_TEST:SUITE_DESCRIPTION=Suite description' ||'%AFTER_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%AFTER_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%AFTER_TEST:SUITE_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%AFTER_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_TEST:TEST_DESCRIPTION=Some test description' ||'%AFTER_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%AFTER_TEST:TEST_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%AFTER_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=after_test%' @@ -1400,17 +1400,17 @@ Failures:% '%AFTER_EACH_TEST:CONTEXT_DESCRIPTION=context description' ||'%AFTER_EACH_TEST:CONTEXT_NAME=some_context' ||'%AFTER_EACH_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%AFTER_EACH_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%AFTER_EACH_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_EACH_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.after_each_test' ||'%AFTER_EACH_TEST:CURRENT_EXECUTABLE_TYPE=aftereach' ||'%AFTER_EACH_TEST:RUN_PATHS=check_context' ||'%AFTER_EACH_TEST:SUITE_DESCRIPTION=Suite description' ||'%AFTER_EACH_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%AFTER_EACH_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%AFTER_EACH_TEST:SUITE_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%AFTER_EACH_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_EACH_TEST:TEST_DESCRIPTION=Some test description' ||'%AFTER_EACH_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%AFTER_EACH_TEST:TEST_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%AFTER_EACH_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=after_each_test%' @@ -1423,14 +1423,14 @@ Failures:% '%AFTER_CONTEXT:CONTEXT_DESCRIPTION=context description' ||'%AFTER_CONTEXT:CONTEXT_NAME=some_context' ||'%AFTER_CONTEXT:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%AFTER_CONTEXT:CONTEXT_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%AFTER_CONTEXT:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_CONTEXT:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.after_context' ||'%AFTER_CONTEXT:CURRENT_EXECUTABLE_TYPE=afterall' ||'%AFTER_CONTEXT:RUN_PATHS=check_context' ||'%AFTER_CONTEXT:SUITE_DESCRIPTION=Suite description' ||'%AFTER_CONTEXT:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%AFTER_CONTEXT:SUITE_PATH=some.suite.path.check_context' - ||'%AFTER_CONTEXT:SUITE_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%AFTER_CONTEXT:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=after_context%' @@ -1447,7 +1447,7 @@ Failures:% ||'%AFTER_SUITE:SUITE_DESCRIPTION=Suite description' ||'%AFTER_SUITE:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%AFTER_SUITE:SUITE_PATH=some.suite.path.check_context' - ||'%AFTER_SUITE:SUITE_START_TIME='||to_char(current_timestamp,'yyyy-mm-dd"T"hh24:mi') + ||'%AFTER_SUITE:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=after_suite%' diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index ae6220d2a..5213bd362 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -62,7 +62,13 @@ create or replace package body test_to_be_within is a_matcher_name,a_data_type, a_actual, a_data_type, a_expected, a_distance,a_distance_data_type, a_matcher_end ); - ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + ut.expect + (ut3_tester_helper.main_helper.get_failed_expectations_num + ,be_within_expectation_block( + a_matcher_name,a_data_type, a_actual, a_data_type, a_expected, + a_distance,a_distance_data_type, a_matcher_end + ) + ).to_equal(0); cleanup_expectations; end; @@ -94,6 +100,9 @@ create or replace package body test_to_be_within is test_to_be_within_success('to_( ut3_develop.be_within','date', 'sysdate', 'sysdate+1','''1 0:00:11.333''','interval day to second', ')'); test_to_be_within_success('to_( ut3_develop.be_within','date', 'sysdate', 'sysdate+200','''1-0''','interval year to month', ')'); test_to_be_within_success('to_( ut3_develop.be_within','date', 'sysdate+200', 'sysdate','''1-0''','interval year to month', ')'); + test_to_be_within_success('to_( ut3_develop.be_within','timestamp', q'[TIMESTAMP '2018-08-09 07:00:00']', q'[TIMESTAMP '2017-08-09 07:00:00']','''1-0''','interval year to month', ')'); + test_to_be_within_success('to_( ut3_develop.be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second', ')'); + test_to_be_within_success('to_( ut3_develop.be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second', ')'); test_to_be_within_fail('not_to_be_within','number', '2', '4','2','number'); test_to_be_within_fail('not_to_be_within','number', '4', '2','2','number'); test_to_be_within_fail('not_to_be_within','date', 'sysdate+1', 'sysdate','''1 0:00:11.333''','interval day to second'); @@ -106,6 +115,9 @@ create or replace package body test_to_be_within is test_to_be_within_fail('not_to( ut3_develop.be_within','date', 'sysdate', 'sysdate+1','''1 0:00:11.333''','interval day to second',')'); test_to_be_within_fail('not_to( ut3_develop.be_within','date', 'sysdate', 'sysdate+200','''1-0''','interval year to month',')'); test_to_be_within_fail('not_to( ut3_develop.be_within','date', 'sysdate+200', 'sysdate','''1-0''','interval year to month',')'); + test_to_be_within_fail('not_to( ut3_develop.be_within','timestamp', q'[TIMESTAMP '2018-08-09 07:00:00']', q'[TIMESTAMP '2017-08-09 07:00:00']','''1-0''','interval year to month', ')'); + test_to_be_within_fail('not_to( ut3_develop.be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second', ')'); + test_to_be_within_fail('not_to( ut3_develop.be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second', ')'); end; procedure failed_tests is @@ -220,6 +232,126 @@ create or replace package body test_to_be_within is ut.expect(l_actual_message).to_be_like(l_expected_message); end; - + procedure fail_msg_wrong_types is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Act + ut3_develop.ut.expect(sysdate).to_be_within(interval '1' second).of_(systimestamp); + --Assert + l_expected_message := q'[Matcher 'be within' cannot be used to compare Actual (date) with Expected (timestamp with time zone) using distance (interval day to second).]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure null_expected is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Act + ut3_develop.ut.expect(sysdate).to_be_within(interval '1' second).of_(to_date(null)); + --Assert + l_expected_message := q'[Actual: % (date) was expected to be within 1 second of NULL (date)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure null_actual_and_expected is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Act + ut3_develop.ut.expect(to_date(null)).to_be_within(interval '1' second).of_(to_date(null)); + --Assert + l_expected_message := q'[Actual: NULL (date) was expected to be within 1 second of NULL (date)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure null_actual is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Act + ut3_develop.ut.expect(to_date(null)).to_be_within(interval '1' second).of_(sysdate); + --Assert + l_expected_message := q'[Actual: NULL (date) was expected to be within 1 second of % (date)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + + procedure null_distance is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Act + ut3_develop.ut.expect(sysdate).to_be_within(cast(null as interval day to second)).of_(sysdate); + --Assert + l_expected_message := q'[Actual: % (date) was expected to be within NULL of % (date)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + + procedure invalid_distance_for_number is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Act + ut3_develop.ut.expect(2).to_be_within(interval '1' second).of_(1); + --Assert + l_expected_message := q'[Matcher 'be within' cannot be used to compare Actual (number) with Expected (number) using distance (interval day to second).]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + + procedure invalid_distance_for_timestamp is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Act + ut3_develop.ut.expect(sysdate).to_be_within(1).of_(sysdate); + --Assert + l_expected_message := q'[Matcher 'be within' cannot be used to compare Actual (date) with Expected (date) using distance (number).]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + procedure failure_on_tiny_time_diff is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Act + ut3_develop.ut.expect(timestamp'2022-01-29 23:23:23.000000009').to_be_within(interval '0.000000001' second).of_(timestamp'2022-01-29 23:23:23.000000001'); + --Assert + l_expected_message := q'[Actual: 2022-01-29T23:23:23.000000009 (timestamp) was expected to be within .000000001 seconds of 2022-01-29T23:23:23.000000001 (timestamp)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + + procedure failure_on_large_years_compare is + l_actual_message varchar2(32767); + l_expected_message varchar2(32767); + begin + --Act + ut3_develop.ut.expect(to_date('-4000-01-01','syyyy-mm-dd')).to_be_within(interval '9990' year).of_(date '9999-12-31'); + --Assert + l_expected_message := q'[Actual: -4000-01-01T00:00:00 (date) was expected to be within 9990 years of 9999-12-31T00:00:00 (date)]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + end; / diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pks b/test/ut3_user/expectations/binary/test_to_be_within.pks index b2f456584..966e9baaf 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pks +++ b/test/ut3_user/expectations/binary/test_to_be_within.pks @@ -9,7 +9,7 @@ create or replace package test_to_be_within is --%test(gives success for values within a distance) procedure success_tests; - --%test(gives failure when number is not within distance) + --%test(gives failure when value is not within distance) procedure failed_tests; --%test(returns well formatted failure message when expectation fails) @@ -30,5 +30,32 @@ create or replace package test_to_be_within is --%test(returns well formatted failure message for simple within) procedure fail_msg_when_not_within; + --%test(returns well formatted failure message when comparing different datatypes) + procedure fail_msg_wrong_types; + + --%test(failure on null expected value) + procedure null_expected; + + --%test(failure on null actual value) + procedure null_actual; + + --%test(failure on null expected and actual value) + procedure null_actual_and_expected; + + --%test(failure on null distance value) + procedure null_distance; + + --%test(failure on invalid distance datatype for number expected) + procedure invalid_distance_for_number; + + --%test(failure on invalid distance datatype for timestamp expected) + procedure invalid_distance_for_timestamp; + + --%test(failure on exceeding difference in day second time by nanosecond) + procedure failure_on_tiny_time_diff; + + --%test(failure when comparing very large year difference) + procedure failure_on_large_years_compare; + end; / diff --git a/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb index a184c3728..d1e71943a 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb @@ -171,7 +171,7 @@ create or replace package body test_to_be_within_pct is test_to_be_within_fail( 'to_be_within_pct','date', 'sysdate', 'number','1', '1','number', - 'Actual (date) cannot be compared to Expected (number) using matcher ''be within pct''' + 'Matcher ''be within pct'' cannot be used to compare Actual (date) with Expected (number) using distance (number).' ); end; diff --git a/test/ut3_user/reporters/test_debug_reporter.pkb b/test/ut3_user/reporters/test_debug_reporter.pkb index ed7e14fcf..a022b5af8 100644 --- a/test/ut3_user/reporters/test_debug_reporter.pkb +++ b/test/ut3_user/reporters/test_debug_reporter.pkb @@ -21,7 +21,7 @@ create or replace package body test_debug_reporter as begin l_expected := '\s+' || '(\s+' || - '[0-9\-]+T[0-9:\.]+<\/TIMESTAMP>\s+' || + ' [0-9\-]+T[0-9:\.]+<\/TIMESTAMP>\s+' || '[0-9 \+:\.]+<\/TIME_FROM_START>\s+' || '[0-9 \+:\.]+<\/TIME_FROM_PREVIOUS>\s+' || '\w+<\/EVENT_NAME>\s+' || From 9b8d7f7e889593777ae46c3485d36d7ae3ef4bf9 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 31 Jan 2022 00:42:59 +0000 Subject: [PATCH 213/887] First commit of adding a new 21c json type. --- source/api/ut.pkb | 5 + source/api/ut.pks | 2 + .../data_values/ut_data_value_json.tpb | 7 + .../data_values/ut_data_value_json.tps | 1 + source/expectations/json_objects_specs.sql | 7 +- source/expectations/matchers/ut_equal.tpb | 6 + source/expectations/matchers/ut_equal.tps | 1 + source/expectations/ut_expectation.tpb | 5 + source/expectations/ut_expectation.tps | 1 + source/expectations/ut_expectation_json.tps | 2 +- .../expectations/test_expectations_json.pkb | 174 ++++++++++++++++++ .../expectations/test_expectations_json.pks | 25 ++- 12 files changed, 232 insertions(+), 4 deletions(-) diff --git a/source/api/ut.pkb b/source/api/ut.pkb index 9e3defe16..ee3d85342 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -98,6 +98,11 @@ create or replace package body ut is return ut_expectation_json(ut_data_value_json(a_actual), a_message); end; + function expect(a_actual in json , a_message varchar2 := null) return ut_expectation_json is + begin + return ut_expectation_json(ut_data_value_json(a_actual), a_message); + end; + procedure fail(a_message in varchar2) is begin ut_expectation_processor.report_failure(a_message); diff --git a/source/api/ut.pks b/source/api/ut.pks index 2cce4e183..df5a8d8e5 100644 --- a/source/api/ut.pks +++ b/source/api/ut.pks @@ -47,6 +47,8 @@ create or replace package ut authid current_user as function expect(a_actual in json_element_t , a_message varchar2 := null) return ut_expectation_json; + function expect(a_actual in json , a_message varchar2 := null) return ut_expectation_json; + procedure fail(a_message in varchar2); function run( diff --git a/source/expectations/data_values/ut_data_value_json.tpb b/source/expectations/data_values/ut_data_value_json.tpb index dfb3275ab..5d7232851 100644 --- a/source/expectations/data_values/ut_data_value_json.tpb +++ b/source/expectations/data_values/ut_data_value_json.tpb @@ -32,6 +32,13 @@ create or replace type body ut_data_value_json as return; end; + constructor function ut_data_value_json(self in out nocopy ut_data_value_json, a_value json) return self as result is + l_value json_element_t := case when a_value is null then cast (null as json_element_t ) else json_element_t.parse(json_query(a_value, '$' returning clob)) end; + begin + init(l_value); + return; + end; + overriding member function is_null return boolean is begin return (ut_utils.int_to_boolean(self.is_data_null)); diff --git a/source/expectations/data_values/ut_data_value_json.tps b/source/expectations/data_values/ut_data_value_json.tps index 135124e64..3b77e54eb 100644 --- a/source/expectations/data_values/ut_data_value_json.tps +++ b/source/expectations/data_values/ut_data_value_json.tps @@ -19,6 +19,7 @@ create or replace type ut_data_value_json under ut_compound_data_value( json_tree ut_json_tree_details, member procedure init (self in out nocopy ut_data_value_json, a_value json_element_t), constructor function ut_data_value_json(self in out nocopy ut_data_value_json, a_value json_element_t) return self as result, + constructor function ut_data_value_json(self in out nocopy ut_data_value_json, a_value json) return self as result, overriding member function is_null return boolean, overriding member function is_empty return boolean, overriding member function to_string return varchar2, diff --git a/source/expectations/json_objects_specs.sql b/source/expectations/json_objects_specs.sql index c0d42e8fb..58877eacd 100644 --- a/source/expectations/json_objects_specs.sql +++ b/source/expectations/json_objects_specs.sql @@ -1,7 +1,12 @@ BEGIN - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then + $if dbms_db_version.version >= 21 $then dbms_output.put_line('Object exists , dont install'); + $elsif dbms_db_version.version = 12 and dbms_db_version.release >= 2 or ( dbms_db_version.version > 12 and dbms_db_version.version < 21 ) $then + dbms_output.put_line('Installing json structures specs.'); + execute immediate q'[create or replace TYPE JSON FORCE AUTHID CURRENT_USER AS OBJECT( + dummyobjt NUMBER +) NOT FINAL NOT INSTANTIABLE;]'; $else dbms_output.put_line('Installing json structures specs.'); execute immediate q'[create or replace TYPE JSON_Element_T FORCE AUTHID CURRENT_USER AS OBJECT( diff --git a/source/expectations/matchers/ut_equal.tpb b/source/expectations/matchers/ut_equal.tpb index 05caf3b09..1519ede5b 100644 --- a/source/expectations/matchers/ut_equal.tpb +++ b/source/expectations/matchers/ut_equal.tpb @@ -158,6 +158,12 @@ create or replace type body ut_equal as return; end; + constructor function ut_equal(self in out nocopy ut_equal, a_expected json, a_nulls_are_equal boolean := null) return self as result is + begin + init(ut_data_value_json(a_expected), a_nulls_are_equal); + return; + end; + member function include(a_items varchar2) return ut_equal is l_result ut_equal := self; begin diff --git a/source/expectations/matchers/ut_equal.tps b/source/expectations/matchers/ut_equal.tps index eecbe8c1d..f348b39c7 100644 --- a/source/expectations/matchers/ut_equal.tps +++ b/source/expectations/matchers/ut_equal.tps @@ -42,6 +42,7 @@ create or replace type ut_equal force under ut_comparison_matcher( constructor function ut_equal(self in out nocopy ut_equal, a_expected yminterval_unconstrained, a_nulls_are_equal boolean := null) return self as result, constructor function ut_equal(self in out nocopy ut_equal, a_expected dsinterval_unconstrained, a_nulls_are_equal boolean := null) return self as result, constructor function ut_equal(self in out nocopy ut_equal, a_expected json_element_t, a_nulls_are_equal boolean := null) return self as result, + constructor function ut_equal(self in out nocopy ut_equal, a_expected json, a_nulls_are_equal boolean := null) return self as result, member function include(a_items varchar2) return ut_equal, member function include(a_items ut_varchar2_list) return ut_equal, member function exclude(a_items varchar2) return ut_equal, diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index dfad630a6..6579e2a00 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -201,6 +201,11 @@ create or replace type body ut_expectation as self.to_( ut_equal(a_expected, a_nulls_are_equal) ); end; + member procedure to_equal(self in ut_expectation, a_expected json, a_nulls_are_equal boolean := null) is + begin + self.to_( ut_equal(a_expected, a_nulls_are_equal) ); + end; + member procedure not_to_equal(self in ut_expectation, a_expected anydata, a_nulls_are_equal boolean := null) is begin self.not_to( ut_equal(a_expected, a_nulls_are_equal) ); diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index 45d768200..57691d109 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -55,6 +55,7 @@ create or replace type ut_expectation authid current_user as object( member procedure to_equal(self in ut_expectation, a_expected yminterval_unconstrained, a_nulls_are_equal boolean := null), member procedure to_equal(self in ut_expectation, a_expected dsinterval_unconstrained, a_nulls_are_equal boolean := null), member procedure to_equal(self in ut_expectation, a_expected json_element_t, a_nulls_are_equal boolean := null), + member procedure to_equal(self in ut_expectation, a_expected json, a_nulls_are_equal boolean := null), member procedure not_to_equal(self in ut_expectation, a_expected anydata, a_nulls_are_equal boolean := null), member procedure not_to_equal(self in ut_expectation, a_expected anydata, a_exclude varchar2, a_nulls_are_equal boolean := null), diff --git a/source/expectations/ut_expectation_json.tps b/source/expectations/ut_expectation_json.tps index f33c6a580..561c5d11f 100644 --- a/source/expectations/ut_expectation_json.tps +++ b/source/expectations/ut_expectation_json.tps @@ -24,4 +24,4 @@ create or replace type ut_expectation_json under ut_expectation( member procedure to_have_count(self in ut_expectation_json, a_expected integer), member procedure not_to_have_count(self in ut_expectation_json, a_expected integer) ) -/ +/ \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectations_json.pkb b/test/ut3_user/expectations/test_expectations_json.pkb index 9516ecb04..731cbcfd9 100644 --- a/test/ut3_user/expectations/test_expectations_json.pkb +++ b/test/ut3_user/expectations/test_expectations_json.pkb @@ -1608,5 +1608,179 @@ create or replace package body test_expectations_json is end; + procedure success_on_same_data_njson + as + l_actual json; + begin + -- Arrange + l_actual := json(' { + "Actors": [ + { + "name": "Tom Cruise", + "age": 56, + "Born At": "Syracuse, NY", + "Birthdate": "July 3, 1962", + "photo": "https://jsonformatter.org/img/tom-cruise.jpg", + "wife": null, + "weight": 67.5, + "hasChildren": true, + "hasGreyHair": false, + "children": [ + "Suri", + "Isabella Jane", + "Connor" + ] + }, + { + "name": "Robert Downey Jr.", + "age": 53, + "Born At": "New York City, NY", + "Birthdate": "April 4, 1965", + "photo": "https://jsonformatter.org/img/Robert-Downey-Jr.jpg", + "wife": "Susan Downey", + "weight": 77.1, + "hasChildren": true, + "hasGreyHair": false, + "children": [ + "Indio Falconer", + "Avri Roel", + "Exton Elias" + ] + } + ] + }'); + + --Act + ut3_develop.ut.expect( l_actual ).to_equal( l_actual ); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + + procedure fail_on_diff_data_njson + as + l_expected json; + l_actual json; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); + begin + -- Arrange + l_expected := json('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); + l_actual := json('{"Aidan Gillen": {"array": ["Game of Thron\"es","The Wire"],"string": "some string","int": 2,"aboolean": true, "boolean": true,"object": {"foo": "bar","object1": {"new prop1": "new prop value"},"object2": {"new prop1": "new prop value"},"object3": {"new prop1": "new prop value"},"object4": {"new prop1": "new prop value"}}},"Amy Ryan": {"one": "In Treatment","two": "The Wire"},"Annie Fitzgerald": ["Big Love","True Blood"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsgard": ["Generation Kill","True Blood"], "Clarke Peters": null}'); + + --Act + ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); + --Assert + l_expected_message := q'[%Missing property: "Alexander Skarsg?rd" on path: $ +%Extra property: "Alexander Skarsgard" on path: $ +%Missing property: "Alice Farmer" on path: $ +%Extra property: "Clarke Peters" on path: $ +%Extra property: "one" on path: $."Amy Ryan" +%Missing property: "The Sopranos" on path: $."Annie Fitzgerald"[2] +%Extra property: "two" on path: $."Amy Ryan" +%Missing property: "Oz" on path: $."Annie Fitzgerald"[3] +%Missing property: "otherint" on path: $."Aidan Gillen" +%Extra property: "object1" on path: $."Aidan Gillen"."object" +%Extra property: "object2" on path: $."Aidan Gillen"."object" +%Extra property: "object3" on path: $."Aidan Gillen"."object" +%Extra property: "object4" on path: $."Aidan Gillen"."object" +%Actual type: 'array' was expected to be: 'object' on path: $."Amy Ryan" +%Actual type: 'string' was expected to be: 'number' on path: $."Aidan Gillen"."int" +%Actual type: 'string' was expected to be: 'boolean' on path: $."Aidan Gillen"."aboolean" +%Actual value: "True Blood" was expected to be: "Big Love" on path: $."Annie Fitzgerald"[0] +%Actual value: "Big Love" was expected to be: "True Blood" on path: $."Annie Fitzgerald"[1] +%Actual value: FALSE was expected to be: TRUE on path: $."Aidan Gillen"."boolean" +%Actual value: "Game of Thrones" was expected to be: "Game of Thron\"es" on path: $."Aidan Gillen"."array"[0]%]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + ut.expect(l_actual_message).to_be_like('%Diff: 20 differences found%'); + ut.expect(l_actual_message).to_be_like('%13 missing properties%'); + ut.expect(l_actual_message).to_be_like('%4 unequal values%'); + ut.expect(l_actual_message).to_be_like('%3 incorrect types%'); + end; + + + --Please note that by the looks of things the call to json() results in null value being returned. + procedure null_json_variable_njson + as + l_expected json ; + begin + -- Arrange + l_expected := cast (null as json ); + + --Act + ut3_develop.ut.expect( l_expected ).to_be_null; + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + + procedure to_have_count_njson as + l_actual json; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); + begin + -- Arrange + l_actual := json('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); + + --Act + ut3_develop.ut.expect( l_actual ).to_have_count( 6 ); + + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + + end; + + procedure fail_to_have_count_njson + as + l_actual json; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); + begin + -- Arrange + l_actual := json('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); + + --Act + ut3_develop.ut.expect( l_actual ).to_have_count( 2 ); + --Assert + l_expected_message := q'[%Actual: (json [ count = 6 ]) was expected to have [ count = 2 ]%]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + + end; + + procedure not_to_have_count_njson + as + l_actual json; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); + begin + -- Arrange + l_actual := json('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); + + --Act + ut3_develop.ut.expect( l_actual ).not_to_have_count( 7 ); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + + procedure fail_not_to_have_count_njson + as + l_actual json; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); + begin + -- Arrange + l_actual := json('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); + + --Act + ut3_develop.ut.expect( l_actual ).not_to_have_count( 6 ); + --Assert + l_expected_message := q'[%Actual: json [ count = 6 ] was expected not to have [ count = 6 ]%]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + end; / diff --git a/test/ut3_user/expectations/test_expectations_json.pks b/test/ut3_user/expectations/test_expectations_json.pks index 64dff42e8..4cee67526 100644 --- a/test/ut3_user/expectations/test_expectations_json.pks +++ b/test/ut3_user/expectations/test_expectations_json.pks @@ -39,13 +39,13 @@ create or replace package test_expectations_json is --%test( Json object to have count ) procedure to_have_count; - --%test( Fail Json object to have count) + --%test( Fail Json object to have count) procedure fail_to_have_count; --%test( Json object not to have count) procedure not_to_have_count; - --%test( Fail Json object not to have count) + --%test( Fail Json object not to have count) procedure fail_not_to_have_count; --%test( Json object to have count on array) @@ -74,6 +74,27 @@ create or replace package test_expectations_json is --%test( Compare two json arrays ) procedure check_json_arrays; + + --%test(Gives success for identical data using native json for 21c and above) + procedure success_on_same_data_njson; + + --%test(Gives failure for different data using native json for 21c and above) + procedure fail_on_diff_data_njson; + + --%test( Json variable is null using native json for 21c and above) + procedure null_json_variable_njson; + + --%test( Json object to have count using native json for 21c and above) + procedure to_have_count_njson; + + --%test( Fail Json object to have count using native json for 21c and above) + procedure fail_to_have_count_njson; + + --%test( Json object not to have count using native json for 21c and above) + procedure not_to_have_count_njson; + + --%test( Fail Json object not to have count using native json for 21c and above) + procedure fail_not_to_have_count_njson; end; / From 3d3f0bee3e9708f6402e59029e9728b0d82bdefc Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 31 Jan 2022 00:50:46 +0000 Subject: [PATCH 214/887] Update install on 11c to add new json type. --- source/expectations/json_objects_specs.sql | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/source/expectations/json_objects_specs.sql b/source/expectations/json_objects_specs.sql index 58877eacd..39c2c4e23 100644 --- a/source/expectations/json_objects_specs.sql +++ b/source/expectations/json_objects_specs.sql @@ -3,11 +3,16 @@ BEGIN $if dbms_db_version.version >= 21 $then dbms_output.put_line('Object exists , dont install'); $elsif dbms_db_version.version = 12 and dbms_db_version.release >= 2 or ( dbms_db_version.version > 12 and dbms_db_version.version < 21 ) $then - dbms_output.put_line('Installing json structures specs.'); + dbms_output.put_line('Installing json structures specs for native json.'); + execute immediate q'[create or replace TYPE JSON FORCE AUTHID CURRENT_USER AS OBJECT( + dummyobjt NUMBER +) NOT FINAL NOT INSTANTIABLE;]'; + $else + dbms_output.put_line('Installing json structures specs for native json.'); execute immediate q'[create or replace TYPE JSON FORCE AUTHID CURRENT_USER AS OBJECT( dummyobjt NUMBER ) NOT FINAL NOT INSTANTIABLE;]'; - $else + dbms_output.put_line('Installing json structures specs.'); execute immediate q'[create or replace TYPE JSON_Element_T FORCE AUTHID CURRENT_USER AS OBJECT( dummyobjt NUMBER, From 86e84c8b349ddc4c0b488f8efada429c08271210 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 31 Jan 2022 23:04:57 +0200 Subject: [PATCH 215/887] Improving code coverage. --- source/expectations/ut_expectation.tpb | 42 +++++++++---------- .../expectations/test_expectations_cursor.pkb | 6 +-- .../expectations/test_expectations_json.pkb | 2 +- 3 files changed, 25 insertions(+), 25 deletions(-) diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index 95a117bc1..cc5bfe0ca 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -718,44 +718,44 @@ create or replace type body ut_expectation as return l_result; end; - member function to_be_within_pct(a_dist natural) return ut_be_within_pct is - l_result ut_be_within_pct; - begin - l_result := ut_be_within_pct(a_dist); - l_result.expectation := self; - return l_result; + member function to_be_within_pct(a_dist natural) return ut_be_within_pct is + l_result ut_be_within_pct; + begin + l_result := ut_be_within_pct(a_dist); + l_result.expectation := self; + return l_result; end; member function not_to_be_within(a_dist natural) return ut_be_within is - l_result ut_matcher; + l_result ut_be_within; begin - l_result := ut_be_within(a_dist).negated(); + l_result := treat( ut_be_within(a_dist).negated() as ut_be_within); l_result.expectation := self; - return treat(l_result as ut_be_within); + return l_result; end; member function not_to_be_within(a_dist dsinterval_unconstrained) return ut_be_within is - l_result ut_matcher; + l_result ut_be_within; begin - l_result := ut_be_within(a_dist).negated(); + l_result := treat( ut_be_within(a_dist).negated() as ut_be_within); l_result.expectation := self; - return treat(l_result as ut_be_within); + return l_result; end; member function not_to_be_within(a_dist yminterval_unconstrained) return ut_be_within is - l_result ut_matcher; + l_result ut_be_within; begin - l_result := ut_be_within(a_dist).negated(); + l_result := treat( ut_be_within(a_dist).negated() as ut_be_within); l_result.expectation := self; - return treat(l_result as ut_be_within); + return l_result; end; - member function not_to_be_within_pct(a_dist natural) return ut_be_within_pct is - l_result ut_matcher; - begin - l_result := ut_be_within_pct(a_dist).negated(); - l_result.expectation := self; - return treat(l_result as ut_be_within_pct); + member function not_to_be_within_pct(a_dist natural) return ut_be_within_pct is + l_result ut_be_within_pct; + begin + l_result := treat( ut_be_within_pct(a_dist).negated() as ut_be_within_pct); + l_result.expectation := self; + return l_result; end; end; diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index f06132009..409c81ace 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -336,7 +336,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as col_1, 2 as col_2 from dual; open l_actual for select 2 as col_2, 1 as col_1 from dual; --Act - ut3_develop.ut.expect( l_actual ).to_equal( l_expected ).unordered_columns; + ut3_develop.ut.expect( l_actual ).to_( ut3_develop.equal( l_expected ).unordered_columns() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -350,7 +350,7 @@ create or replace package body test_expectations_cursor is open l_expected for select 1 as col_1, 2 as col_2 from dual; open l_actual for select 2 as col_2, 1 as col_1 from dual; --Act - ut3_develop.ut.expect( l_actual ).to_equal( l_expected ).uc; + ut3_develop.ut.expect( l_actual ).to_( ut3_develop.equal( l_expected ).uc() ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; @@ -592,7 +592,7 @@ create or replace package body test_expectations_cursor is open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual connect by level < 4; open l_expected for select rownum as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual connect by level < 4; --Act - ut3_develop.ut.expect(l_actual).to_equal(l_expected).include('/ROW/RN|//A_Column|//SOME_COL'); + ut3_develop.ut.expect(l_actual).to_( ut3_develop.equal(l_expected).include('/ROW/RN|//A_Column|//SOME_COL') ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; diff --git a/test/ut3_user/expectations/test_expectations_json.pkb b/test/ut3_user/expectations/test_expectations_json.pkb index 9516ecb04..afc7198a2 100644 --- a/test/ut3_user/expectations/test_expectations_json.pkb +++ b/test/ut3_user/expectations/test_expectations_json.pkb @@ -49,7 +49,7 @@ create or replace package body test_expectations_json is }'); --Act - ut3_develop.ut.expect( l_actual ).to_equal( l_actual ); + ut3_develop.ut.expect( l_actual ).to_( ut3_develop.equal( l_actual ) ); --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; From 718ac0d45b52099d2dfa0a8f2f934cd8e758a00d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 1 Feb 2022 00:14:48 +0200 Subject: [PATCH 216/887] Improved test stability. Added human-readable reporting of tests run-time into `ut_documentation_reporter`. --- .../reporters/ut_documentation_reporter.tpb | 2 +- test/ut3_user/api/test_ut_run.pkb | 44 ++++++++++--------- 2 files changed, 24 insertions(+), 22 deletions(-) diff --git a/source/reporters/ut_documentation_reporter.tpb b/source/reporters/ut_documentation_reporter.tpb index 8b92d447f..30ab8f856 100644 --- a/source/reporters/ut_documentation_reporter.tpb +++ b/source/reporters/ut_documentation_reporter.tpb @@ -198,7 +198,7 @@ create or replace type body ut_documentation_reporter is begin print_failures_details(a_run); print_warnings(a_run); - self.print_text('Finished in ' || a_run.execution_time || ' seconds'); + self.print_text('Finished in ' || ut_utils.interval_to_text(numtodsinterval(a_run.execution_time,'second')) ); l_summary_text := a_run.results_count.total_count || ' tests, ' diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 19c69c74e..8ec19f6d8 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -6,6 +6,7 @@ create or replace package body test_ut_run is gc_client_info constant varchar2(32767) := 'test client info'; g_context_test_results clob; + g_timestamp timestamp; procedure clear_expectations is begin @@ -1260,6 +1261,7 @@ Failures:% begin select * bulk collect into l_lines from table(ut3_develop.ut.run('check_context')); g_context_test_results := ut3_tester_helper.main_helper.table_to_clob(l_lines); + g_timestamp := current_timestamp; end; @@ -1272,7 +1274,7 @@ Failures:% ||'%BEFORE_SUITE:SUITE_DESCRIPTION=Suite description' ||'%BEFORE_SUITE:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%BEFORE_SUITE:SUITE_PATH=some.suite.path.check_context' - ||'%BEFORE_SUITE:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_SUITE:SUITE_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=before_suite%' @@ -1287,14 +1289,14 @@ Failures:% '%BEFORE_CONTEXT:CONTEXT_DESCRIPTION=context description' ||'%BEFORE_CONTEXT:CONTEXT_NAME=some_context' ||'%BEFORE_CONTEXT:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%BEFORE_CONTEXT:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_CONTEXT:CONTEXT_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_CONTEXT:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.before_context' ||'%BEFORE_CONTEXT:CURRENT_EXECUTABLE_TYPE=beforeall' ||'%BEFORE_CONTEXT:RUN_PATHS=check_context' ||'%BEFORE_CONTEXT:SUITE_DESCRIPTION=Suite description' ||'%BEFORE_CONTEXT:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%BEFORE_CONTEXT:SUITE_PATH=some.suite.path.check_context' - ||'%BEFORE_CONTEXT:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_CONTEXT:SUITE_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=before_context%' @@ -1308,17 +1310,17 @@ Failures:% '%BEFORE_EACH_TEST:CONTEXT_DESCRIPTION=context description' ||'%BEFORE_EACH_TEST:CONTEXT_NAME=some_context' ||'%BEFORE_EACH_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%BEFORE_EACH_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_EACH_TEST:CONTEXT_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_EACH_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.before_each_test' ||'%BEFORE_EACH_TEST:CURRENT_EXECUTABLE_TYPE=beforeeach' ||'%BEFORE_EACH_TEST:RUN_PATHS=check_context' ||'%BEFORE_EACH_TEST:SUITE_DESCRIPTION=Suite description' ||'%BEFORE_EACH_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%BEFORE_EACH_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%BEFORE_EACH_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_EACH_TEST:SUITE_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_EACH_TEST:TEST_DESCRIPTION=Some test description' ||'%BEFORE_EACH_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%BEFORE_EACH_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_EACH_TEST:TEST_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=before_each_test%' @@ -1331,17 +1333,17 @@ Failures:% '%BEFORE_TEST:CONTEXT_DESCRIPTION=context description' ||'%BEFORE_TEST:CONTEXT_NAME=some_context' ||'%BEFORE_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%BEFORE_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_TEST:CONTEXT_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.before_test' ||'%BEFORE_TEST:CURRENT_EXECUTABLE_TYPE=beforetest' ||'%BEFORE_TEST:RUN_PATHS=check_context' ||'%BEFORE_TEST:SUITE_DESCRIPTION=Suite description' ||'%BEFORE_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%BEFORE_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%BEFORE_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_TEST:SUITE_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%BEFORE_TEST:TEST_DESCRIPTION=Some test description' ||'%BEFORE_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%BEFORE_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%BEFORE_TEST:TEST_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=before_test%' @@ -1354,17 +1356,17 @@ Failures:% '%THE_TEST:CONTEXT_DESCRIPTION=context description' ||'%THE_TEST:CONTEXT_NAME=some_context' ||'%THE_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%THE_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%THE_TEST:CONTEXT_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%THE_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.the_test' ||'%THE_TEST:CURRENT_EXECUTABLE_TYPE=test' ||'%THE_TEST:RUN_PATHS=check_context' ||'%THE_TEST:SUITE_DESCRIPTION=Suite description' ||'%THE_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%THE_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%THE_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%THE_TEST:SUITE_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%THE_TEST:TEST_DESCRIPTION=Some test description' ||'%THE_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%THE_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%THE_TEST:TEST_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=the_test%' @@ -1377,17 +1379,17 @@ Failures:% '%AFTER_TEST:CONTEXT_DESCRIPTION=context description' ||'%AFTER_TEST:CONTEXT_NAME=some_context' ||'%AFTER_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%AFTER_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%AFTER_TEST:CONTEXT_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.after_test' ||'%AFTER_TEST:CURRENT_EXECUTABLE_TYPE=aftertest' ||'%AFTER_TEST:RUN_PATHS=check_context' ||'%AFTER_TEST:SUITE_DESCRIPTION=Suite description' ||'%AFTER_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%AFTER_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%AFTER_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%AFTER_TEST:SUITE_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_TEST:TEST_DESCRIPTION=Some test description' ||'%AFTER_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%AFTER_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%AFTER_TEST:TEST_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=after_test%' @@ -1400,17 +1402,17 @@ Failures:% '%AFTER_EACH_TEST:CONTEXT_DESCRIPTION=context description' ||'%AFTER_EACH_TEST:CONTEXT_NAME=some_context' ||'%AFTER_EACH_TEST:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%AFTER_EACH_TEST:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%AFTER_EACH_TEST:CONTEXT_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_EACH_TEST:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.after_each_test' ||'%AFTER_EACH_TEST:CURRENT_EXECUTABLE_TYPE=aftereach' ||'%AFTER_EACH_TEST:RUN_PATHS=check_context' ||'%AFTER_EACH_TEST:SUITE_DESCRIPTION=Suite description' ||'%AFTER_EACH_TEST:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%AFTER_EACH_TEST:SUITE_PATH=some.suite.path.check_context' - ||'%AFTER_EACH_TEST:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%AFTER_EACH_TEST:SUITE_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_EACH_TEST:TEST_DESCRIPTION=Some test description' ||'%AFTER_EACH_TEST:TEST_NAME='||gc_owner||'.check_context.the_test' - ||'%AFTER_EACH_TEST:TEST_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%AFTER_EACH_TEST:TEST_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=after_each_test%' @@ -1423,14 +1425,14 @@ Failures:% '%AFTER_CONTEXT:CONTEXT_DESCRIPTION=context description' ||'%AFTER_CONTEXT:CONTEXT_NAME=some_context' ||'%AFTER_CONTEXT:CONTEXT_PATH=some.suite.path.check_context.some_context' - ||'%AFTER_CONTEXT:CONTEXT_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%AFTER_CONTEXT:CONTEXT_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%AFTER_CONTEXT:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.after_context' ||'%AFTER_CONTEXT:CURRENT_EXECUTABLE_TYPE=afterall' ||'%AFTER_CONTEXT:RUN_PATHS=check_context' ||'%AFTER_CONTEXT:SUITE_DESCRIPTION=Suite description' ||'%AFTER_CONTEXT:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%AFTER_CONTEXT:SUITE_PATH=some.suite.path.check_context' - ||'%AFTER_CONTEXT:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%AFTER_CONTEXT:SUITE_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=after_context%' @@ -1447,7 +1449,7 @@ Failures:% ||'%AFTER_SUITE:SUITE_DESCRIPTION=Suite description' ||'%AFTER_SUITE:SUITE_PACKAGE='||gc_owner||'.check_context' ||'%AFTER_SUITE:SUITE_PATH=some.suite.path.check_context' - ||'%AFTER_SUITE:SUITE_START_TIME='||to_char(current_timestamp,'syyyy-mm-dd"T"hh24:mi') + ||'%AFTER_SUITE:SUITE_START_TIME='||to_char(g_timestamp,'syyyy-mm-dd"T"hh24:mi') ||'%APPLICATION_INFO:MODULE=utPLSQL' ||'%APPLICATION_INFO:ACTION=check_context' ||'%APPLICATION_INFO:CLIENT_INFO=after_suite%' From 6dbef20a5b0d7c67d709bd5ea519e5a27b1f049e Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 1 Feb 2022 00:29:16 +0200 Subject: [PATCH 217/887] Fixing build process to build using develop branch as testing framework for Pull Requests --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 87d577554..8703e24d9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -92,7 +92,7 @@ jobs: - name: Download utPLSQL release for testing # For PR build - test using target branch as framework, for branch build use self as testing framework - run: git clone --depth=1 --branch=${CI_HEAD_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR + run: git clone --depth=1 --branch=${CI_BASE_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR - name: Update privileges on sources run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} From 25b55b4cb776e6a4aeb019297e7be12ff6699784 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 1 Feb 2022 00:44:49 +0200 Subject: [PATCH 218/887] Improving test coverage. --- test/ut3_user/expectations/binary/test_to_be_within.pkb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index 5213bd362..d490a8280 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -118,6 +118,9 @@ create or replace package body test_to_be_within is test_to_be_within_fail('not_to( ut3_develop.be_within','timestamp', q'[TIMESTAMP '2018-08-09 07:00:00']', q'[TIMESTAMP '2017-08-09 07:00:00']','''1-0''','interval year to month', ')'); test_to_be_within_fail('not_to( ut3_develop.be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second', ')'); test_to_be_within_fail('not_to( ut3_develop.be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second', ')'); + test_to_be_within_fail('not_to_be_within','timestamp', q'[TIMESTAMP '2018-08-09 07:00:00']', q'[TIMESTAMP '2017-08-09 07:00:00']','''1-0''','interval year to month'); + test_to_be_within_fail('not_to_be_within','timestamp_tz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second'); + test_to_be_within_fail('not_to_be_within','timestamp_ltz_unconstrained', q'[TIMESTAMP '2017-08-09 07:00:00 -7:00']', q'[TIMESTAMP '2017-08-08 05:59:48.668 -8:00']','''1 0:00:11.333''','interval day to second'); end; procedure failed_tests is From 5b5a5c017d70e0a17ffdf872850e757f69ed9ea9 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 1 Feb 2022 01:58:44 +0200 Subject: [PATCH 219/887] Improving matcher documentation --- docs/userguide/expectations.md | 33 +++++++++++++++++++++++++-------- 1 file changed, 25 insertions(+), 8 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 833235c24..88c244977 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -333,8 +333,8 @@ The matrix below illustrates the data types supported by different matchers. | **be_like** | | | X | | | | | | X | | | | | | | | **be_empty** | X | | X | | | | | | | | | X | X | | X | | **have_count** | | | | | | | | | | | | X | X | | X | -| **be_within().of_()** | | | | x | x | | | | | | | | | | | -| **be_within_pct().of_()** | | | | | x | | | | | | | | | | | +| **be_within().of_()** | | | | X | X | X | X | X | | | | | | | | +| **be_within_pct().of_()** | | | | | X | | | | | | | | | | | # Expecting exceptions @@ -1096,17 +1096,34 @@ SUCCESS ## to_be_within of -This matcher is created to determine wheter expected value is approximately equal or "close" to another value. +This matcher determines wheter expected value is within range from another value. -Matcher will allow to compare numbers as well as dates. +The logical formual used for calcuating the matcher is: +`abs( expected - actual ) <= distance` +The matcher will succeed if the `expected` and `actual` are not more than `distance` apart from each other. -When comparing a number the tolerance / distance can be expressed as another postive number or a percentage. +The matcher works with data-type number, date, timestamp, timestamp with time zone, timestamp with local time zone. +The data-types of compared values must match exactly and if type does not match, the expectation will fail. -When comparing a two dates tolerance can be expressed in interval time either Day-To-Second or Year-To-Month. +| expected/actual
data-type | distance data-type | +|:------------------------------:|:----------------------:| +| number | number | +| date | interval day to second | +| date | interval year to month | +| timestamp | interval day to second | +| timestamp | interval year to month | +| timestamp with time zone | interval day to second | +| timestamp with time zone | interval year to month | +| timestamp with local time zone | interval day to second | +| timestamp with local time zone | interval year to month | -Matcher for numbers will calculate a absolute distance between expected and actual and check whether that value is within a tolerance. -When comparing a date a distance is measured in interval, the check is done that actual value is within date range of expected taking into account interval plus and minus. +The distance can be expressed as a postive number or positive interval. + +>Note: +> Interval year-to-moth as a distance is giving sucess if the distance between the given dates/timestamps evaluates to value less or equal of the specified interval +> Keep in mind that a distance of `interval '0-1' year to month` will actuall be successful if the distance isnot greater than a month and a half. +> This is due to how oracle evaluates conversion between timestamp difference converted to `year to month interval`. **Example 1.** ```sql From 9002fbce682677e8983e3a3e1f338f58aecc0817 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 1 Feb 2022 00:14:40 +0000 Subject: [PATCH 220/887] Making tests below 21 compilation conditional so it wont fail. --- .../data_values/ut_compound_data_helper.pkb | 11 +++++++++++ .../data_values/ut_compound_data_helper.pks | 2 ++ .../expectations/data_values/ut_data_value_json.tpb | 2 +- test/ut3_user/expectations/test_expectations_json.pkb | 6 ++++-- test/ut3_user/expectations/test_expectations_json.pks | 5 ++++- 5 files changed, 22 insertions(+), 4 deletions(-) diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 37d9901ff..4847a248c 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -781,6 +781,17 @@ create or replace package body ut_compound_data_helper is return l_diffs; end; + function get_json_object(a_json_t json) return json_element_t is + l_json JSON; + l_obj json_element_t; + begin + $if dbms_db_version.version >= 21 $then + l_obj := case when a_json_t is null then cast (null as json_element_t ) else json_element_t.parse(json_query(a_value, '$' returning clob)) end; + $else + l_obj := null; + $end + end; + begin g_anytype_name_map(dbms_types.typecode_date) := 'DATE'; g_anytype_name_map(dbms_types.typecode_number) := 'NUMBER'; diff --git a/source/expectations/data_values/ut_compound_data_helper.pks b/source/expectations/data_values/ut_compound_data_helper.pks index 53b0846b8..451cd9bac 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pks +++ b/source/expectations/data_values/ut_compound_data_helper.pks @@ -134,5 +134,7 @@ create or replace package ut_compound_data_helper authid definer is function get_json_diffs_type(a_diff_id raw) return tt_json_diff_type_tab; + function get_json_object(a_json_t json) return json_element_t; + end; / diff --git a/source/expectations/data_values/ut_data_value_json.tpb b/source/expectations/data_values/ut_data_value_json.tpb index 5d7232851..40bf81dbb 100644 --- a/source/expectations/data_values/ut_data_value_json.tpb +++ b/source/expectations/data_values/ut_data_value_json.tpb @@ -33,7 +33,7 @@ create or replace type body ut_data_value_json as end; constructor function ut_data_value_json(self in out nocopy ut_data_value_json, a_value json) return self as result is - l_value json_element_t := case when a_value is null then cast (null as json_element_t ) else json_element_t.parse(json_query(a_value, '$' returning clob)) end; + l_value json_element_t := ut_compound_data_helper.get_json_object(a_value); begin init(l_value); return; diff --git a/test/ut3_user/expectations/test_expectations_json.pkb b/test/ut3_user/expectations/test_expectations_json.pkb index 731cbcfd9..3fc28ff03 100644 --- a/test/ut3_user/expectations/test_expectations_json.pkb +++ b/test/ut3_user/expectations/test_expectations_json.pkb @@ -1607,7 +1607,8 @@ create or replace package body test_expectations_json is ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; - + $if dbms_db_version.version >= 21 $then + procedure success_on_same_data_njson as l_actual json; @@ -1781,6 +1782,7 @@ create or replace package body test_expectations_json is --Assert ut.expect(l_actual_message).to_be_like(l_expected_message); end; - + + $end end; / diff --git a/test/ut3_user/expectations/test_expectations_json.pks b/test/ut3_user/expectations/test_expectations_json.pks index 4cee67526..286106a58 100644 --- a/test/ut3_user/expectations/test_expectations_json.pks +++ b/test/ut3_user/expectations/test_expectations_json.pks @@ -75,6 +75,8 @@ create or replace package test_expectations_json is --%test( Compare two json arrays ) procedure check_json_arrays; + $if dbms_db_version.version >= 21 $then + --%test(Gives success for identical data using native json for 21c and above) procedure success_on_same_data_njson; @@ -95,6 +97,7 @@ create or replace package test_expectations_json is --%test( Fail Json object not to have count using native json for 21c and above) procedure fail_not_to_have_count_njson; - + + $end end; / From b270d4e02745ca3455c4b1db2523161d683b369c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 1 Feb 2022 00:26:56 +0000 Subject: [PATCH 221/887] Fixing conditional compilation --- source/expectations/data_values/ut_compound_data_helper.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 4847a248c..fe3dc6946 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -786,7 +786,7 @@ create or replace package body ut_compound_data_helper is l_obj json_element_t; begin $if dbms_db_version.version >= 21 $then - l_obj := case when a_json_t is null then cast (null as json_element_t ) else json_element_t.parse(json_query(a_value, '$' returning clob)) end; + l_obj := case when a_json_t is null then cast (null as json_element_t ) else json_element_t.parse(json_query(a_json_t, '$' returning clob)) end; $else l_obj := null; $end From 5b1c1d38984e08f04467e3a4e44cc6032b2f6fef Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 1 Feb 2022 00:36:02 +0000 Subject: [PATCH 222/887] Missing return from function. --- source/expectations/data_values/ut_compound_data_helper.pkb | 1 + 1 file changed, 1 insertion(+) diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index fe3dc6946..558b007d9 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -790,6 +790,7 @@ create or replace package body ut_compound_data_helper is $else l_obj := null; $end + return l_obj; end; begin From 0d8cbea403026db10e939e942fdca01de98adec0 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 1 Feb 2022 01:01:13 +0000 Subject: [PATCH 223/887] Added mention about new type into userguide. --- docs/userguide/expectations.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c07f3782e..07ff647e5 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1643,7 +1643,7 @@ FAILURE # Comparing Json objects -utPLSQL is capable of comparing json data-types **on Oracle 12.2 and above**. +utPLSQL is capable of comparing json data-types of `json_element_t` **on Oracle 12.2 and above**, and also `json` **on Oracle 21 and above** ### Notes on comparison of json data @@ -1651,10 +1651,11 @@ utPLSQL is capable of comparing json data-types **on Oracle 12.2 and above**. - During comparison of json objects the order doesn't matter. - During comparison of json arrays the index of element is taken into account - To compare json you have to make sure its type of `json_element_t` or its subtypes +- From version 21 and above a native `json` type is supported. -Compare JSON example: +Compare JSON example using `json_element_t`: ```sql declare l_expected json_element_t; @@ -1736,7 +1737,7 @@ FAILURE at "anonymous block", line 59 ``` -Comparing parts of JSON example: +Comparing parts of JSON example using `json_element_t` subtypes: ```sql declare l_actual json_object_t; From 21b3cb39415331a93378ffc61752c149a5481cbf Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 1 Feb 2022 01:15:19 +0000 Subject: [PATCH 224/887] Fixing sonar. --- source/expectations/data_values/ut_compound_data_helper.pkb | 1 - 1 file changed, 1 deletion(-) diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 558b007d9..e29f10279 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -782,7 +782,6 @@ create or replace package body ut_compound_data_helper is end; function get_json_object(a_json_t json) return json_element_t is - l_json JSON; l_obj json_element_t; begin $if dbms_db_version.version >= 21 $then From 075fe522031534e5aceea1f0d33a531dec8b522b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 1 Feb 2022 19:58:30 +0000 Subject: [PATCH 225/887] Adding conditional execution of sonarcloud. --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 87d577554..7d42b08f1 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -131,6 +131,7 @@ jobs: - name: SonarCloud Scan id: sonar + if: ${{ matrix.db_version_name == '21xe' }} uses: SonarSource/sonarcloud-github-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any From dc14dc754505f4d979fd21dcded366bd94c84a84 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 2 Feb 2022 09:39:52 +0000 Subject: [PATCH 226/887] Fixing issue 1113 where the act were inserted into exp --- .../data_values/ut_data_value_json.tpb | 2 +- .../expectations/test_expectations_json.pkb | 39 ++++++++++++++----- .../expectations/test_expectations_json.pks | 4 ++ 3 files changed, 34 insertions(+), 11 deletions(-) diff --git a/source/expectations/data_values/ut_data_value_json.tpb b/source/expectations/data_values/ut_data_value_json.tpb index 40bf81dbb..b703af181 100644 --- a/source/expectations/data_values/ut_data_value_json.tpb +++ b/source/expectations/data_values/ut_data_value_json.tpb @@ -147,7 +147,7 @@ create or replace type body ut_data_value_json as l_result := case when ut_compound_data_helper.insert_json_diffs( - l_diff_id, self.json_tree.json_tree_info, l_other.json_tree.json_tree_info + l_diff_id, l_other.json_tree.json_tree_info, self.json_tree.json_tree_info ) > 0 then 1 else 0 end; diff --git a/test/ut3_user/expectations/test_expectations_json.pkb b/test/ut3_user/expectations/test_expectations_json.pkb index 3fc28ff03..677ba2578 100644 --- a/test/ut3_user/expectations/test_expectations_json.pkb +++ b/test/ut3_user/expectations/test_expectations_json.pkb @@ -62,8 +62,8 @@ create or replace package body test_expectations_json is l_actual_message varchar2(32767); begin -- Arrange - l_expected := json_element_t.parse('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); - l_actual := json_element_t.parse('{"Aidan Gillen": {"array": ["Game of Thron\"es","The Wire"],"string": "some string","int": 2,"aboolean": true, "boolean": true,"object": {"foo": "bar","object1": {"new prop1": "new prop value"},"object2": {"new prop1": "new prop value"},"object3": {"new prop1": "new prop value"},"object4": {"new prop1": "new prop value"}}},"Amy Ryan": {"one": "In Treatment","two": "The Wire"},"Annie Fitzgerald": ["Big Love","True Blood"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsgard": ["Generation Kill","True Blood"], "Clarke Peters": null}'); + l_actual := json_element_t.parse('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); + l_expected := json_element_t.parse('{"Aidan Gillen": {"array": ["Game of Thron\"es","The Wire"],"string": "some string","int": 2,"aboolean": true, "boolean": true,"object": {"foo": "bar","object1": {"new prop1": "new prop value"},"object2": {"new prop1": "new prop value"},"object3": {"new prop1": "new prop value"},"object4": {"new prop1": "new prop value"}}},"Amy Ryan": {"one": "In Treatment","two": "The Wire"},"Annie Fitzgerald": ["Big Love","True Blood"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsgard": ["Generation Kill","True Blood"], "Clarke Peters": null}'); --Act ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); @@ -387,7 +387,7 @@ create or replace package body test_expectations_json is l_actual_message varchar2(32767); begin -- Arrange - l_expected := json_object_t.parse(' { + l_actual := json_object_t.parse(' { "Actors": [ { "name": "Tom Cruise", @@ -424,7 +424,7 @@ create or replace package body test_expectations_json is ] }' ); - l_actual := json_object_t.parse(' { + l_expected := json_object_t.parse(' { "Actors": { "name": "Krzystof Jarzyna", @@ -444,8 +444,8 @@ create or replace package body test_expectations_json is --Act - ut3_develop.ut.expect(json_array_t(json_query(l_actual.stringify,'$.Actors.children'))).to_equal(json_array_t(json_query(l_expected - .stringify,'$.Actors[1].children'))); + ut3_develop.ut.expect(json_array_t(json_query(l_actual.stringify,'$.Actors[1].children'))).to_equal(json_array_t(json_query(l_expected + .stringify,'$.Actors.children'))); --Assert l_expected_message := q'[%Actual: json was expected to equal: json %Diff: 1 differences found @@ -1055,7 +1055,7 @@ create or replace package body test_expectations_json is l_actual_message varchar2(32767); begin -- Arrange - l_expected := json_element_t.parse('[ + l_actual := json_element_t.parse('[ { "_id": "5ce6ec46cb9977b050f15d97", "index": 0, @@ -1282,7 +1282,7 @@ create or replace package body test_expectations_json is "favoriteFruit": "strawberry" } ]'); - l_actual := json_element_t.parse('[ + l_expected := json_element_t.parse('[ { "_id": "5ce6ec6660565269b16cf836", "index": 0, @@ -1665,8 +1665,8 @@ create or replace package body test_expectations_json is l_actual_message varchar2(32767); begin -- Arrange - l_expected := json('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); - l_actual := json('{"Aidan Gillen": {"array": ["Game of Thron\"es","The Wire"],"string": "some string","int": 2,"aboolean": true, "boolean": true,"object": {"foo": "bar","object1": {"new prop1": "new prop value"},"object2": {"new prop1": "new prop value"},"object3": {"new prop1": "new prop value"},"object4": {"new prop1": "new prop value"}}},"Amy Ryan": {"one": "In Treatment","two": "The Wire"},"Annie Fitzgerald": ["Big Love","True Blood"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsgard": ["Generation Kill","True Blood"], "Clarke Peters": null}'); + l_actual := json('{"Aidan Gillen": {"array": ["Game of Thrones","The Wire"],"string": "some string","int": "2","otherint": 4, "aboolean": "true", "boolean": false,"object": {"foo": "bar"}},"Amy Ryan": ["In Treatment","The Wire"],"Annie Fitzgerald": ["True Blood","Big Love","The Sopranos","Oz"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsg?rd": ["Generation Kill","True Blood"],"Alice Farmer": ["The Corner","Oz","The Wire"]}'); + l_expected := json('{"Aidan Gillen": {"array": ["Game of Thron\"es","The Wire"],"string": "some string","int": 2,"aboolean": true, "boolean": true,"object": {"foo": "bar","object1": {"new prop1": "new prop value"},"object2": {"new prop1": "new prop value"},"object3": {"new prop1": "new prop value"},"object4": {"new prop1": "new prop value"}}},"Amy Ryan": {"one": "In Treatment","two": "The Wire"},"Annie Fitzgerald": ["Big Love","True Blood"],"Anwan Glover": ["Treme","The Wire"],"Alexander Skarsgard": ["Generation Kill","True Blood"], "Clarke Peters": null}'); --Act ut3_develop.ut.expect( l_actual ).to_equal( l_expected ); @@ -1784,5 +1784,24 @@ create or replace package body test_expectations_json is end; $end + + procedure p_1113_reg_exp_chg_with_act is + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); + begin + ut3_develop.ut.expect(json_element_t.parse('{"a":"value a"}')).to_equal(json_element_t.parse('{"a":"value b"}')); + + --Assert + l_expected_message := q'[%Actual: json was expected to equal: json +%Diff: 1 differences found +%1 unequal values +%Actual value: "value a" was expected to be: "value b" on path: $."a"%]'; + + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + + end; / diff --git a/test/ut3_user/expectations/test_expectations_json.pks b/test/ut3_user/expectations/test_expectations_json.pks index 286106a58..410c3050b 100644 --- a/test/ut3_user/expectations/test_expectations_json.pks +++ b/test/ut3_user/expectations/test_expectations_json.pks @@ -99,5 +99,9 @@ create or replace package test_expectations_json is procedure fail_not_to_have_count_njson; $end + + --%test( Regression scenario tests for issue #1113 where the expected has been switched with actual) + procedure p_1113_reg_exp_chg_with_act; + end; / From 7fec0f998c59fcd2fac6f4d97f508b53bd6d3d15 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 3 Feb 2022 01:03:18 +0200 Subject: [PATCH 227/887] Added tests for 0 value of actual and expected and actual greater than expected (not only smaller). Updated documentation. --- docs/userguide/expectations.md | 43 +++++++++++-------- .../matchers/ut_be_within_pct.tpb | 5 +-- .../binary/test_to_be_within_pct.pkb | 36 ++++++++++++++++ 3 files changed, 63 insertions(+), 21 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 88c244977..a74e2576e 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1096,13 +1096,17 @@ SUCCESS ## to_be_within of -This matcher determines wheter expected value is within range from another value. +Determines wheter expected value is within range (tolerance) from another value. -The logical formual used for calcuating the matcher is: -`abs( expected - actual ) <= distance` -The matcher will succeed if the `expected` and `actual` are not more than `distance` apart from each other. +The logical formual used for calcuating the matcher is: +``` + result := ( abs( expected - actual ) <= distance ) +``` +The actual formula used for calculation is more complex to handle different data-types of expected/actual values as well as differnet types of distance value. +The matcher will fail if the `expected` and `actual` are more than `distance` apart from each other. +The matcher will fail if the dataypes of `expected` and `actual` are not the same. -The matcher works with data-type number, date, timestamp, timestamp with time zone, timestamp with local time zone. +The matcher works with data-types: `number`, `date`, `timestamp`, `timestamp with time zone`, `timestamp with local time zone` The data-types of compared values must match exactly and if type does not match, the expectation will fail. | expected/actual
data-type | distance data-type | @@ -1118,12 +1122,13 @@ The data-types of compared values must match exactly and if type does not match, | timestamp with local time zone | interval year to month | -The distance can be expressed as a postive number or positive interval. +The distance must be expressed as a non-negative number or non-negative interval. >Note: > Interval year-to-moth as a distance is giving sucess if the distance between the given dates/timestamps evaluates to value less or equal of the specified interval -> Keep in mind that a distance of `interval '0-1' year to month` will actuall be successful if the distance isnot greater than a month and a half. -> This is due to how oracle evaluates conversion between timestamp difference converted to `year to month interval`. +> Keep in mind that a checking for distance of `interval '0-1' year to month` will actuall be successful if the distance is less than a month and 15 days. +> This is due to how oracle evaluates conversion between timestamp difference converted to `year to month interval`. +> The behavior is similar to a call to `months_between()` function with results rounded to full monts ie. round(months_between(date, date)) **Example 1.** ```sql @@ -1172,17 +1177,14 @@ Failures: ## to_be_within_pct of -This matcher is created to determine wheter expected value is approximately equal or "close" to another value within percentage value of expected. - -Matcher will allow to compare numbers. - -When comparing a number the tolerance / distance can be expressed as another postive number or a percentage. - -When comparing a two dates tolerance can be expressed in interval time either Day-To-Second or Year-To-Month. - -Matcher for numbers will calculate a absolute distance between expected and actual and check whether that value is within a tolerance. +Determines wheter actual value is within percentage range of expected value. +The matcher only works with `number` data-type. -When comparing a date a distance is measured in interval, the check is done that actual value is within date range of expected taking into account interval plus and minus. +The percentage deviation (distance) must be expressed as a non-negative number. +The formula used for calcuation of expectation is: +``` + result := ( ( distance ) * expected >= abs( expected - actual ) * 100 ) +``` **Example 1.** ```sql @@ -1192,6 +1194,11 @@ end; / ``` +``` +SUCCESS + Actual: 9 (number) was expected to be within 10 % of 10 (number) +``` + ## Comparing cursors, object types, nested tables and varrays diff --git a/source/expectations/matchers/ut_be_within_pct.tpb b/source/expectations/matchers/ut_be_within_pct.tpb index fabab2d09..8b280ffff 100644 --- a/source/expectations/matchers/ut_be_within_pct.tpb +++ b/source/expectations/matchers/ut_be_within_pct.tpb @@ -52,9 +52,8 @@ create or replace type body ut_be_within_pct as if self.expected.data_type = a_actual.data_type then if self.expected is of (ut_data_value_number) then l_result := - treat(self.distance_from_expected as ut_data_value_number).data_value - >= ( ( treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ) / - treat(self.expected as ut_data_value_number).data_value; + abs(treat(self.distance_from_expected as ut_data_value_number).data_value) * treat(self.expected as ut_data_value_number).data_value + >= abs( ( treat(self.expected as ut_data_value_number).data_value - treat(a_actual as ut_data_value_number).data_value ) * 100 ); end if; else l_result := (self as ut_matcher).run_matcher(a_actual); diff --git a/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb index d1e71943a..5214b540c 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb @@ -125,6 +125,27 @@ create or replace package body test_to_be_within_pct is ut3_develop.ut.expect( 2.987654321 ).not_to( ut3_develop.be_within_pct( 0.1 ).of_(3) ); expect_success; + + ut3_develop.ut.expect( 3.012345679 ).to_be_within_pct( 1 ).of_(3); + expect_success; + + ut3_develop.ut.expect( 3.012345679 ).to_( ut3_develop.be_within_pct( 1 ).of_(3) ); + expect_success; + + ut3_develop.ut.expect( 3.012345679 ).not_to_be_within_pct( 0.1 ).of_(3); + expect_success; + + ut3_develop.ut.expect( 3.012345679 ).not_to( ut3_develop.be_within_pct( 0.1 ).of_(3) ); + expect_success; + + ut3_develop.ut.expect( 0 ).to_be_within_pct( 10 ).of_( 0 ); + expect_success; + + ut3_develop.ut.expect( 0 ).to_be_within_pct( 100 ).of_( 1 ); + expect_success; + + ut3_develop.ut.expect( -1 ).to_be_within_pct( 200 ).of_( 1 ); + expect_success; end; procedure failed_tests is @@ -140,6 +161,21 @@ create or replace package body test_to_be_within_pct is ut3_develop.ut.expect( 2.987654321 ).not_to( ut3_develop.be_within_pct( 1 ).of_(3) ); expect_failure; + + ut3_develop.ut.expect( 3.012345679 ).to_be_within_pct( 0.1 ).of_(3); + expect_failure; + + ut3_develop.ut.expect( 3.012345679 ).to_( ut3_develop.be_within_pct( 0.1 ).of_(3) ); + expect_failure; + + ut3_develop.ut.expect( 3.012345679 ).not_to_be_within_pct( 1 ).of_(3); + expect_failure; + + ut3_develop.ut.expect( 3.012345679 ).not_to( ut3_develop.be_within_pct( 1 ).of_(3) ); + expect_failure; + + ut3_develop.ut.expect( 0.1 ).to_be_within_pct( 10 ).of_( 0 ); + expect_failure; end; procedure fail_for_number_not_within is From fd7ef9c14111a48e03fff7851f990c7192539170 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 3 Feb 2022 01:39:09 +0200 Subject: [PATCH 228/887] Fixed issues with precission of distance. `NATURAL` is a subtype of integer and cannot be used to express a decimal distace value. Improved tests coverage for various scenarios. --- source/expectations/ut_expectation.tpb | 8 ++-- source/expectations/ut_expectation.tps | 10 ++--- .../binary/test_to_be_within_pct.pkb | 42 +++++++++++-------- 3 files changed, 33 insertions(+), 27 deletions(-) diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index cc5bfe0ca..dabe8fbff 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -694,7 +694,7 @@ create or replace type body ut_expectation as self.not_to( ut_contain(a_expected).negated() ); end; - member function to_be_within(a_dist natural) return ut_be_within is + member function to_be_within(a_dist number) return ut_be_within is l_result ut_be_within; begin l_result := ut_be_within(a_dist); @@ -718,7 +718,7 @@ create or replace type body ut_expectation as return l_result; end; - member function to_be_within_pct(a_dist natural) return ut_be_within_pct is + member function to_be_within_pct(a_dist number) return ut_be_within_pct is l_result ut_be_within_pct; begin l_result := ut_be_within_pct(a_dist); @@ -726,7 +726,7 @@ create or replace type body ut_expectation as return l_result; end; - member function not_to_be_within(a_dist natural) return ut_be_within is + member function not_to_be_within(a_dist number) return ut_be_within is l_result ut_be_within; begin l_result := treat( ut_be_within(a_dist).negated() as ut_be_within); @@ -750,7 +750,7 @@ create or replace type body ut_expectation as return l_result; end; - member function not_to_be_within_pct(a_dist natural) return ut_be_within_pct is + member function not_to_be_within_pct(a_dist number) return ut_be_within_pct is l_result ut_be_within_pct; begin l_result := treat( ut_be_within_pct(a_dist).negated() as ut_be_within_pct); diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index ce58fc2e0..86edc9cee 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation under ut_expectation_base( +create or replace type ut_expectation force under ut_expectation_base( /* utPLSQL - Version 3 Copyright 2016 - 2021 utPLSQL Project @@ -164,14 +164,14 @@ create or replace type ut_expectation under ut_expectation_base( member procedure to_contain(self in ut_expectation, a_expected anydata), member procedure not_to_contain(self in ut_expectation, a_expected anydata), - member function to_be_within(a_dist natural) return ut_be_within, + member function to_be_within(a_dist number) return ut_be_within, member function to_be_within(a_dist dsinterval_unconstrained) return ut_be_within, member function to_be_within(a_dist yminterval_unconstrained) return ut_be_within, - member function to_be_within_pct(a_dist natural) return ut_be_within_pct, - member function not_to_be_within(a_dist natural) return ut_be_within, + member function to_be_within_pct(a_dist number) return ut_be_within_pct, + member function not_to_be_within(a_dist number) return ut_be_within, member function not_to_be_within(a_dist dsinterval_unconstrained) return ut_be_within, member function not_to_be_within(a_dist yminterval_unconstrained) return ut_be_within, - member function not_to_be_within_pct(a_dist natural) return ut_be_within_pct + member function not_to_be_within_pct(a_dist number) return ut_be_within_pct ) not final / diff --git a/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb index 5214b540c..da634d90e 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within_pct.pkb @@ -114,31 +114,31 @@ create or replace package body test_to_be_within_pct is procedure success_tests is begin - ut3_develop.ut.expect( 2.987654321 ).to_be_within_pct( 1 ).of_(3); + ut3_develop.ut.expect( 1 ).to_be_within_pct( 0.01 ).of_(1.0001); expect_success; - ut3_develop.ut.expect( 2.987654321 ).to_( ut3_develop.be_within_pct( 1 ).of_(3) ); + ut3_develop.ut.expect( 1.0001 ).to_( ut3_develop.be_within_pct( 0.01 ).of_(1) ); expect_success; - ut3_develop.ut.expect( 2.987654321 ).not_to_be_within_pct( 0.1 ).of_(3); + ut3_develop.ut.expect( 1.0002 ).not_to_be_within_pct( 0.01 ).of_(1); expect_success; - ut3_develop.ut.expect( 2.987654321 ).not_to( ut3_develop.be_within_pct( 0.1 ).of_(3) ); + ut3_develop.ut.expect( 1 ).not_to( ut3_develop.be_within_pct( 0.01 ).of_(1.0002) ); expect_success; - ut3_develop.ut.expect( 3.012345679 ).to_be_within_pct( 1 ).of_(3); + ut3_develop.ut.expect( 1.0001 ).to_be_within_pct( -0.01 ).of_(1); expect_success; - ut3_develop.ut.expect( 3.012345679 ).to_( ut3_develop.be_within_pct( 1 ).of_(3) ); + ut3_develop.ut.expect( 1 ).to_( ut3_develop.be_within_pct( -0.01 ).of_(1.0001) ); expect_success; - ut3_develop.ut.expect( 3.012345679 ).not_to_be_within_pct( 0.1 ).of_(3); + ut3_develop.ut.expect( 1.00000001 ).not_to_be_within_pct( 0 ).of_(1); expect_success; - ut3_develop.ut.expect( 3.012345679 ).not_to( ut3_develop.be_within_pct( 0.1 ).of_(3) ); + ut3_develop.ut.expect( 0 ).not_to( ut3_develop.be_within_pct( 0.01 ).of_(0.000001) ); expect_success; - ut3_develop.ut.expect( 0 ).to_be_within_pct( 10 ).of_( 0 ); + ut3_develop.ut.expect( 0 ).to_be_within_pct( 0 ).of_( 0 ); expect_success; ut3_develop.ut.expect( 0 ).to_be_within_pct( 100 ).of_( 1 ); @@ -150,31 +150,37 @@ create or replace package body test_to_be_within_pct is procedure failed_tests is begin - ut3_develop.ut.expect( 2.987654321 ).to_be_within_pct( 0.1 ).of_(3); + ut3_develop.ut.expect( 1 ).not_to_be_within_pct( 0.01 ).of_(1.0001); expect_failure; - ut3_develop.ut.expect( 2.987654321 ).to_( ut3_develop.be_within_pct( 0.1 ).of_(3) ); + ut3_develop.ut.expect( 1.0001 ).not_to( ut3_develop.be_within_pct( 0.01 ).of_(1) ); expect_failure; - ut3_develop.ut.expect( 2.987654321 ).not_to_be_within_pct( 1 ).of_(3); + ut3_develop.ut.expect( 1.0002 ).to_be_within_pct( 0.01 ).of_(1); expect_failure; - ut3_develop.ut.expect( 2.987654321 ).not_to( ut3_develop.be_within_pct( 1 ).of_(3) ); + ut3_develop.ut.expect( 1 ).to_( ut3_develop.be_within_pct( 0.01 ).of_(1.0002) ); expect_failure; - ut3_develop.ut.expect( 3.012345679 ).to_be_within_pct( 0.1 ).of_(3); + ut3_develop.ut.expect( 1.0001 ).not_to_be_within_pct( -0.01 ).of_(1); expect_failure; - ut3_develop.ut.expect( 3.012345679 ).to_( ut3_develop.be_within_pct( 0.1 ).of_(3) ); + ut3_develop.ut.expect( 1 ).not_to( ut3_develop.be_within_pct( -0.01 ).of_(1.0001) ); expect_failure; - ut3_develop.ut.expect( 3.012345679 ).not_to_be_within_pct( 1 ).of_(3); + ut3_develop.ut.expect( 1.00000001 ).to_be_within_pct( 0 ).of_(1); expect_failure; - ut3_develop.ut.expect( 3.012345679 ).not_to( ut3_develop.be_within_pct( 1 ).of_(3) ); + ut3_develop.ut.expect( 0 ).to_( ut3_develop.be_within_pct( 0.01 ).of_(0.000001) ); expect_failure; - ut3_develop.ut.expect( 0.1 ).to_be_within_pct( 10 ).of_( 0 ); + ut3_develop.ut.expect( 0 ).not_to_be_within_pct( 0 ).of_( 0 ); + expect_failure; + + ut3_develop.ut.expect( 0 ).not_to_be_within_pct( 100 ).of_( 1 ); + expect_failure; + + ut3_develop.ut.expect( -1 ).not_to_be_within_pct( 200 ).of_( 1 ); expect_failure; end; From 3b7b9445ef44faf2d3c32df76efde17ed0009012 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 5 Feb 2022 00:46:57 +0200 Subject: [PATCH 229/887] Composing a separate build string for sonar analysis on parallel builds --- .github/workflows/build.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8703e24d9..5d6c5391f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -135,6 +135,9 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + with: + args: > + -Dsonar.buildString=${{ format( '{0}.{1}', env.UTPLSQL_BUILD_VERSION, matrix.id ) }} publish: name: Deploy documentation From f216a282c98158496261bc8c61a6a25d7852d0ab Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 5 Feb 2022 01:23:07 +0200 Subject: [PATCH 230/887] Adding data-dictionary analysis --- .github/workflows/build.yml | 2 ++ sonar-project.properties | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5d6c5391f..0d5d3267d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -138,6 +138,8 @@ jobs: with: args: > -Dsonar.buildString=${{ format( '{0}.{1}', env.UTPLSQL_BUILD_VERSION, matrix.id ) }} + -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@{0}', env.CONNECTION_STR ) }} + -Dsonar.plsql.jdbc.driver.path=${{ format( '{0}/ojdbc8.jar', env.OJDBC_HOME ) }} publish: name: Deploy documentation diff --git a/sonar-project.properties b/sonar-project.properties index b68d13879..7559b58a1 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -29,9 +29,9 @@ sonar.pullrequest.github.endpoint=https://api.github.com/ sonar.pullrequest.github.repository=utPLSQL/utPLSQL sonar.plsql.jdbc.driver.class=oracle.jdbc.OracleDriver -sonar.plsql.jdbc.user=UT3 +sonar.plsql.jdbc.user=UT3_DEVELOP sonar.plsql.jdbc.password=ut3 -sonar.plsql.defaultSchema=UT3 +sonar.plsql.defaultSchema=UT3_DEVELOP # Encoding of the source code. Default is default system encoding From 3f4d2f601088e399c4f25ae57f72a070851b5233 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 6 Feb 2022 00:47:51 +0200 Subject: [PATCH 231/887] Adding Codecov. Trying to fix Sonar DB level analysis. --- .github/workflows/build.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0d5d3267d..209cb0fe1 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -129,6 +129,15 @@ jobs: id: validate-reports-format run: bash .github/scripts/validate_report_files.sh + - name: Codecov + uses: codecov/codecov-action@v2 + with: + token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos + files: ./cobertura.xml + flags: ${{matrix.db_version_name}} + fail_ci_if_error: true # optional (default = false) + verbose: true # optional (default = false) + - name: SonarCloud Scan id: sonar uses: SonarSource/sonarcloud-github-action@master @@ -138,7 +147,7 @@ jobs: with: args: > -Dsonar.buildString=${{ format( '{0}.{1}', env.UTPLSQL_BUILD_VERSION, matrix.id ) }} - -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@{0}', env.CONNECTION_STR ) }} + -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//{0}', env.CONNECTION_STR ) }} -Dsonar.plsql.jdbc.driver.path=${{ format( '{0}/ojdbc8.jar', env.OJDBC_HOME ) }} publish: From 0e5d40401b0e57a4450d94a402dfb5067fa7a755 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 6 Feb 2022 01:18:53 +0200 Subject: [PATCH 232/887] Trying to fix Sonar DB level analysis. --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 209cb0fe1..a0ed47f21 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -147,7 +147,7 @@ jobs: with: args: > -Dsonar.buildString=${{ format( '{0}.{1}', env.UTPLSQL_BUILD_VERSION, matrix.id ) }} - -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//{0}', env.CONNECTION_STR ) }} + -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//oracle:1521/XE', env.CONNECTION_STR ) }} -Dsonar.plsql.jdbc.driver.path=${{ format( '{0}/ojdbc8.jar', env.OJDBC_HOME ) }} publish: From 6bcf8a4e711af5369bc001178b257060d94bf633 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 6 Feb 2022 01:57:45 +0200 Subject: [PATCH 233/887] Parametrizing Sonar Oracle DB SID --- .github/workflows/build.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a0ed47f21..dcf70799f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -19,6 +19,7 @@ jobs: runs-on: ubuntu-latest env: ORACLE_VERSION: ${{matrix.oracle-version}} + ORACLE_SID: ${{matrix.oracle-sid}} CONNECTION_STR: ${{matrix.connection-str}} ORACLE_PASSWORD: oracle DOCKER_VOLUME: ${{matrix.docker-volume}} @@ -27,31 +28,38 @@ jobs: matrix: include: - oracle-version: "gvenzl/oracle-xe:11-full" + oracle-sid: 'XE' connection-str: '127.0.0.1:1521/XE' id: 1 db_version_name: '11xe' # TODO - need to add healthcheck.sh into our containers # - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" +# oracle-sid: 'ORCLCDB' # connection-str: '127.0.0.1:1521/ORCLCDB' # id: 2 # db_version_name: '12.1se' # - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" +# oracle-sid: 'ORCLCDB' # connection-str: '127.0.0.1:1521/ORCLCDB' # id: 3 # db_version_name: '12.2se' - oracle-version: "gvenzl/oracle-xe:18-slim" + oracle-sid: 'XE' connection-str: '127.0.0.1:1521/XE' id: 4 db_version_name: '18xe' # - oracle-version: "utplsqlv3/oracledb:18c-se2-small" +# oracle-sid: 'ORCLCDB' # connection-str: '127.0.0.1:1521/ORCLCDB' # id: 5 # db_version_name: '18se' # - oracle-version: "utplsqlv3/oracledb:19c-se2-small" +# oracle-sid: 'ORCLCDB' # connection-str: '127.0.0.1:1521/ORCLCDB' # id: 6 # db_version_name: '19se' - oracle-version: "gvenzl/oracle-xe:21-slim" + oracle-sid: 'XE' connection-str: '127.0.0.1:1521/XE' id: 7 db_version_name: '21xe' @@ -147,7 +155,7 @@ jobs: with: args: > -Dsonar.buildString=${{ format( '{0}.{1}', env.UTPLSQL_BUILD_VERSION, matrix.id ) }} - -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//oracle:1521/XE', env.CONNECTION_STR ) }} + -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//oracle:1521/{0}', env.ORACLE_SID ) }} -Dsonar.plsql.jdbc.driver.path=${{ format( '{0}/ojdbc8.jar', env.OJDBC_HOME ) }} publish: From afa7bce4b73e0b1d8223d84d73e13680c5aecea0 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 6 Feb 2022 02:25:54 +0200 Subject: [PATCH 234/887] Adding test results publishing --- .github/workflows/build.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index dcf70799f..4ad7a176d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -146,6 +146,12 @@ jobs: fail_ci_if_error: true # optional (default = false) verbose: true # optional (default = false) + - name: Publish unit test results + uses: EnricoMi/publish-unit-test-result-action@v1.24 + if: always() + with: + files: junit_test_results.xml + - name: SonarCloud Scan id: sonar uses: SonarSource/sonarcloud-github-action@master From 1448ef1e6977ec5adeba67562480367b049e434a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 6 Feb 2022 16:36:22 +0200 Subject: [PATCH 235/887] CodeCov changes --- .github/workflows/build.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4ad7a176d..05fc26c3a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -144,7 +144,6 @@ jobs: files: ./cobertura.xml flags: ${{matrix.db_version_name}} fail_ci_if_error: true # optional (default = false) - verbose: true # optional (default = false) - name: Publish unit test results uses: EnricoMi/publish-unit-test-result-action@v1.24 From 02bf59985086e94732b9d5e5cd8b03f05f8c8040 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 6 Feb 2022 14:53:01 +0000 Subject: [PATCH 236/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 9d2c26e0b..5747ee5e0 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 67cb1a976..01f39d138 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 92889b02c..4294753e7 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 33db70018..adec7b7dc 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index a459f259a..7a11e5132 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 340952f7e..c22fd54bb 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index cade9ac97..f44da6f6a 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 270f07a8e..e4dca3223 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index a6037b4e2..265c65bdb 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 11cad317f..e0ddfa62b 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0db801ccf..08ae9e3a3 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 7610573e5..623abfda5 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 548a2cb5a..17225bc88 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 88a724257..64ab627cf 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index dae47df96..44d5c81a9 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 6731fada4..36ce5aa31 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index cde37ed6d..2370743c8 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3742--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 93bf00bd3..44aaf4e5e 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.12.3742-develop + * secion v3.1.12.3791-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f8a9f6b47..99512e1b4 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3742-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3791-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 987d3911c703ce9da8334b6a4cc3a8c9d0d4c49f Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 6 Feb 2022 15:49:24 +0000 Subject: [PATCH 237/887] Update code. --- docs/userguide/annotations.md | 58 +- source/api/ut_suite_item_info.tpb | 6 +- source/api/ut_suite_item_info.tps | 3 +- source/core/types/ut_logical_suite.tpb | 4 +- source/core/types/ut_logical_suite.tps | 4 +- source/core/types/ut_run.tpb | 2 +- source/core/types/ut_run.tps | 2 +- source/core/types/ut_suite.tpb | 2 +- source/core/types/ut_suite_cache_row.tps | 3 +- source/core/types/ut_suite_item.tpb | 1 + source/core/types/ut_suite_item.tps | 6 +- source/core/types/ut_test.tpb | 5 +- source/core/types/ut_test.tps | 2 +- source/core/ut_suite_builder.pkb | 14 +- source/core/ut_suite_cache_manager.pkb | 12 +- source/core/ut_suite_manager.pkb | 14 +- .../reporters/ut_documentation_reporter.tpb | 6 +- test/install_ut3_tester_tests.sql | 2 + .../test_annot_disabled_reason.pkb | 533 ++++++++++++++++++ .../test_annot_disabled_reason.pks | 31 + test/ut3_user/api/test_ut_runner.pkb | 20 +- 21 files changed, 685 insertions(+), 45 deletions(-) create mode 100644 test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb create mode 100644 test/ut3_tester/core/annotations/test_annot_disabled_reason.pks diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 1b9b4faee..92cae5d71 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -140,7 +140,7 @@ end; | `--%beforetest([[.].][,...])` | Procedure | Denotes that mentioned procedure(s) should be executed before the annotated `%test` procedure. | | `--%aftertest([[.].][,...])` | Procedure | Denotes that mentioned procedure(s) should be executed after the annotated `%test` procedure. | | `--%rollback()` | Package/procedure | Defines transaction control. Supported values: `auto`(default) - a savepoint is created before invocation of each "before block" is and a rollback to specific savepoint is issued after each "after" block; `manual` - rollback is never issued automatically. Property can be overridden for child element (test in suite) | -| `--%disabled` | Package/procedure | Used to disable a suite or a test. Disabled suites/tests do not get executed, they are however marked and reported as disabled in a test run. | +| `--%disabled()` | Package/procedure | Used to disable a suite, whole context or a test. Disabled suites/contexts/tests do not get executed, they are however marked and reported as disabled in a test run. The reason that will be displayed next to disabled tests is decided based on hierarchy suites -> context -> test | | `--%context()` | Package | Denotes start of a named context (sub-suite) in a suite package an optional description for context can be provided. | | `--%name()` | Package | Denotes name for a context. Must be placed after the context annotation and before start of nested context. | | `--%endcontext` | Package | Denotes end of a nested context (sub-suite) in a suite package | @@ -343,12 +343,13 @@ Finished in .008815 seconds ### Disabled Marks annotated suite package or test procedure as disabled. +You can provide the reason why the test is disabled that will be displayed in output. Disabling suite. ```sql create or replace package test_package as --%suite(Tests for a package) - --%disabled + --%disabled(Reason for disabling suite) --%test(Description of tested behavior) procedure some_test; @@ -371,13 +372,58 @@ exec ut.run('test_package'); ``` ``` Tests for a package - Description of tested behavior [0 sec] (DISABLED) - Description of another behavior [0 sec] (DISABLED) + Description of tested behavior [0 sec] (DISABLED - Reason for disabling suite) + Description of another behavior [0 sec] (DISABLED - Reason for disabling suite) Finished in .001441 seconds 2 tests, 0 failed, 0 errored, 2 disabled, 0 warning(s) ``` +Disabling the context(s). +```sql +create or replace package test_package as + --%suite(Tests for a package) + + --%context(Context1) + + --%test(Description of tested behavior) + procedure some_test; + + --%endcontext + + --%context(Context2) + + --%disabled(Reason for disabling context2) + + --%test(Description of another behavior) + procedure other_test; + + --%endcontext +end; +/ +create or replace package body test_package as + + procedure some_test is begin null; end; + + procedure other_test is begin null; end; +end; +/ +``` + +```sql +exec ut.run('test_package'); +``` +``` +Tests for a package + Context1 + Description of tested behavior [.002 sec] + Context2 + Description of another behavior [0 sec] (DISABLED - Reason for disabling context2) + +Finished in .005079 seconds +2 tests, 0 failed, 0 errored, 1 disabled, 0 warning(s) +``` + Disabling individual test(s). ```sql create or replace package test_package as @@ -387,7 +433,7 @@ create or replace package test_package as procedure some_test; --%test(Description of another behavior) - --%disabled + --%disabled(Reason for disabling test) procedure other_test; end; / @@ -406,7 +452,7 @@ exec ut.run('test_package'); ``` Tests for a package Description of tested behavior [.004 sec] - Description of another behavior [0 sec] (DISABLED) + Description of another behavior [0 sec] (DISABLED - Reason for disabling test) Finished in .005868 seconds 2 tests, 0 failed, 0 errored, 1 disabled, 0 warning(s) diff --git a/source/api/ut_suite_item_info.tpb b/source/api/ut_suite_item_info.tpb index 97d931c59..3315f7a16 100644 --- a/source/api/ut_suite_item_info.tpb +++ b/source/api/ut_suite_item_info.tpb @@ -17,7 +17,7 @@ create or replace type body ut_suite_item_info is */ constructor function ut_suite_item_info(a_object_owner varchar2, a_object_name varchar2, a_item_name varchar2, a_item_description varchar2, a_item_type varchar2, a_item_line_no integer, a_path varchar2, a_disabled_flag integer, - a_tags ut_varchar2_rows) return self as result is + a_disabled_reason varchar2, a_tags ut_varchar2_rows) return self as result is begin self.object_owner := a_object_owner; self.object_name := a_object_name; @@ -27,6 +27,10 @@ create or replace type body ut_suite_item_info is self.item_line_no := a_item_line_no; self.path := a_path; self.disabled_flag := a_disabled_flag; + self.disabled_reason := case when + a_disabled_flag = 1 then a_disabled_reason + else null + end; self.tags := case when a_tags is null then null when a_tags.count = 0 then null diff --git a/source/api/ut_suite_item_info.tps b/source/api/ut_suite_item_info.tps index 2c0f16198..2c92f261d 100644 --- a/source/api/ut_suite_item_info.tps +++ b/source/api/ut_suite_item_info.tps @@ -23,9 +23,10 @@ create or replace type ut_suite_item_info as object ( item_line_no integer, -- line_number where annotation identifying the item exists path varchar2( 4000 ),-- suitepath of the item disabled_flag integer, -- 0 (zero) if item is not disabled, 1 if item is disabled by --%disabled annotation + disabled_reason varchar2(4000), -- if disable flag is set then you can pass reason tags varchar2(4000), constructor function ut_suite_item_info(a_object_owner varchar2, a_object_name varchar2, a_item_name varchar2, a_item_description varchar2, a_item_type varchar2, a_item_line_no integer, a_path varchar2, a_disabled_flag integer, - a_tags ut_varchar2_rows) return self as result + a_disabled_reason varchar2, a_tags ut_varchar2_rows) return self as result ) / diff --git a/source/core/types/ut_logical_suite.tpb b/source/core/types/ut_logical_suite.tpb index 486cb83e7..036d40d51 100644 --- a/source/core/types/ut_logical_suite.tpb +++ b/source/core/types/ut_logical_suite.tpb @@ -16,12 +16,12 @@ create or replace type body ut_logical_suite as limitations under the License. */ - overriding member procedure mark_as_skipped(self in out nocopy ut_logical_suite) is + overriding member procedure mark_as_skipped(self in out nocopy ut_logical_suite, a_skip_reason in varchar2) is begin ut_event_manager.trigger_event(ut_event_manager.gc_before_suite, self); self.start_time := current_timestamp; for i in 1 .. self.items.count loop - self.items(i).mark_as_skipped(); + self.items(i).mark_as_skipped(coalesce(a_skip_reason,self.disabled_reason)); end loop; self.end_time := self.start_time; ut_event_manager.trigger_event(ut_event_manager.gc_after_suite, self); diff --git a/source/core/types/ut_logical_suite.tps b/source/core/types/ut_logical_suite.tps index 0f816f26b..c4f2f699b 100644 --- a/source/core/types/ut_logical_suite.tps +++ b/source/core/types/ut_logical_suite.tps @@ -1,4 +1,4 @@ -create or replace type ut_logical_suite under ut_suite_item ( +create or replace type ut_logical_suite force under ut_suite_item ( /* utPLSQL - Version 3 Copyright 2016 - 2021 utPLSQL Project @@ -21,7 +21,7 @@ create or replace type ut_logical_suite under ut_suite_item ( */ items ut_suite_items, - overriding member procedure mark_as_skipped(self in out nocopy ut_logical_suite), + overriding member procedure mark_as_skipped(self in out nocopy ut_logical_suite, a_skip_reason in varchar2), overriding member procedure set_rollback_type(self in out nocopy ut_logical_suite, a_rollback_type integer, a_force boolean := false), overriding member function do_execute(self in out nocopy ut_logical_suite) return boolean, overriding member procedure calc_execution_result(self in out nocopy ut_logical_suite), diff --git a/source/core/types/ut_run.tpb b/source/core/types/ut_run.tpb index 258396427..cdafb30fc 100644 --- a/source/core/types/ut_run.tpb +++ b/source/core/types/ut_run.tpb @@ -39,7 +39,7 @@ create or replace type body ut_run as return; end; - overriding member procedure mark_as_skipped(self in out nocopy ut_run) is + overriding member procedure mark_as_skipped(self in out nocopy ut_run,a_skip_reason in varchar2) is begin null; end; diff --git a/source/core/types/ut_run.tps b/source/core/types/ut_run.tps index f556934ce..debf847cd 100644 --- a/source/core/types/ut_run.tps +++ b/source/core/types/ut_run.tps @@ -36,7 +36,7 @@ create or replace type ut_run under ut_suite_item ( a_random_test_order_seed positive := null, a_run_tags ut_varchar2_rows := null ) return self as result, - overriding member procedure mark_as_skipped(self in out nocopy ut_run), + overriding member procedure mark_as_skipped(self in out nocopy ut_run,a_skip_reason in varchar2), overriding member function do_execute(self in out nocopy ut_run) return boolean, overriding member procedure set_rollback_type(self in out nocopy ut_run, a_rollback_type integer, a_force boolean := false), overriding member procedure calc_execution_result(self in out nocopy ut_run), diff --git a/source/core/types/ut_suite.tpb b/source/core/types/ut_suite.tpb index 2ec1c9ccd..e3a4687d8 100644 --- a/source/core/types/ut_suite.tpb +++ b/source/core/types/ut_suite.tpb @@ -44,7 +44,7 @@ create or replace type body ut_suite as ut_utils.debug_log('ut_suite.execute'); if self.get_disabled_flag() then - self.mark_as_skipped(); + self.mark_as_skipped(a_skip_reason => self.disabled_reason); else self.start_time := current_timestamp; ut_event_manager.trigger_event(ut_event_manager.gc_before_suite, self); diff --git a/source/core/types/ut_suite_cache_row.tps b/source/core/types/ut_suite_cache_row.tps index 9c5990bfd..c147a8757 100644 --- a/source/core/types/ut_suite_cache_row.tps +++ b/source/core/types/ut_suite_cache_row.tps @@ -1,4 +1,4 @@ -create type ut_suite_cache_row as object ( +create or replace type ut_suite_cache_row as object ( /* utPLSQL - Version 3 Copyright 2016 - 2021 utPLSQL Project @@ -26,6 +26,7 @@ create type ut_suite_cache_row as object ( description varchar2(4000 byte), rollback_type number, disabled_flag number, + disabled_reason varchar2(4000 byte), warnings ut_varchar2_rows, before_all_list ut_executables, after_all_list ut_executables, diff --git a/source/core/types/ut_suite_item.tpb b/source/core/types/ut_suite_item.tpb index 12f857cba..648f10dd1 100644 --- a/source/core/types/ut_suite_item.tpb +++ b/source/core/types/ut_suite_item.tpb @@ -26,6 +26,7 @@ create or replace type body ut_suite_item as self.line_no := a_line_no; self.transaction_invalidators := ut_varchar2_list(); self.disabled_flag := ut_utils.boolean_to_int(false); + self.disabled_reason := null; end; member function get_disabled_flag return boolean is diff --git a/source/core/types/ut_suite_item.tps b/source/core/types/ut_suite_item.tps index d96ec8c30..8184f2a63 100644 --- a/source/core/types/ut_suite_item.tps +++ b/source/core/types/ut_suite_item.tps @@ -46,6 +46,10 @@ create or replace type ut_suite_item force under ut_event_item ( */ disabled_flag integer(1), /** + * Indicates reason whysa test is to be disabled by execution + */ + disabled_reason varchar2(4000), + /** * Line no where annotation identifying this item is placed in package */ line_no integer, @@ -66,7 +70,7 @@ create or replace type ut_suite_item force under ut_event_item ( tags ut_varchar2_rows, member procedure init(self in out nocopy ut_suite_item, a_object_owner varchar2, a_object_name varchar2, a_name varchar2, a_line_no integer), member function get_disabled_flag return boolean, - not instantiable member procedure mark_as_skipped(self in out nocopy ut_suite_item), + not instantiable member procedure mark_as_skipped(self in out nocopy ut_suite_item, a_skip_reason in varchar2), member procedure set_rollback_type(self in out nocopy ut_suite_item, a_rollback_type integer, a_force boolean := false), member function get_rollback_type return integer, member function create_savepoint_if_needed return varchar2, diff --git a/source/core/types/ut_test.tpb b/source/core/types/ut_test.tpb index 9a36205c1..946f8990d 100644 --- a/source/core/types/ut_test.tpb +++ b/source/core/types/ut_test.tpb @@ -35,11 +35,12 @@ create or replace type body ut_test as return; end; - overriding member procedure mark_as_skipped(self in out nocopy ut_test) is + overriding member procedure mark_as_skipped(self in out nocopy ut_test, a_skip_reason in varchar2) is begin ut_event_manager.trigger_event(ut_event_manager.gc_before_test, self); self.start_time := current_timestamp; self.result := ut_utils.gc_disabled; + self.disabled_reason := coalesce(a_skip_reason,self.disabled_reason); ut_utils.debug_log('ut_test.execute - disabled'); self.results_count.set_counter_values(self.result); self.end_time := self.start_time; @@ -54,7 +55,7 @@ create or replace type body ut_test as ut_utils.debug_log('ut_test.execute'); if self.get_disabled_flag() then - mark_as_skipped(); + mark_as_skipped(self.disabled_reason); else self.start_time := current_timestamp; ut_event_manager.trigger_event(ut_event_manager.gc_before_test, self); diff --git a/source/core/types/ut_test.tps b/source/core/types/ut_test.tps index 07958ec0f..dbba64961 100644 --- a/source/core/types/ut_test.tps +++ b/source/core/types/ut_test.tps @@ -59,7 +59,7 @@ create or replace type ut_test force under ut_suite_item ( self in out nocopy ut_test, a_object_owner varchar2 := null, a_object_name varchar2, a_name varchar2, a_line_no integer, a_expected_error_codes ut_varchar2_rows := null, a_tags ut_varchar2_rows := null ) return self as result, - overriding member procedure mark_as_skipped(self in out nocopy ut_test), + overriding member procedure mark_as_skipped(self in out nocopy ut_test, a_skip_reason in varchar2), overriding member function do_execute(self in out nocopy ut_test) return boolean, overriding member procedure calc_execution_result(self in out nocopy ut_test), overriding member procedure mark_as_errored(self in out nocopy ut_test, a_error_stack_trace varchar2), diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 2dac6b4ad..7ad24bd57 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -355,6 +355,7 @@ create or replace package body ut_suite_builder is l_annotation_texts tt_annotation_texts; l_proc_annotations tt_annotations_by_name := a_annotations.by_proc(a_procedure_name); begin + if not l_proc_annotations.exists(gc_test) then return; end if; @@ -412,6 +413,12 @@ create or replace package body ut_suite_builder is end if; l_test.disabled_flag := ut_utils.boolean_to_int( l_proc_annotations.exists( gc_disabled)); + if l_proc_annotations.exists(gc_disabled) then + l_annotation_texts := l_proc_annotations( gc_disabled); + --take the last definition if more than one was provided + l_test.disabled_reason := l_annotation_texts(l_annotation_texts.first); + end if; + a_suite_items.extend; a_suite_items( a_suite_items.last ) := l_test; @@ -560,8 +567,13 @@ create or replace package body ut_suite_builder is if a_annotations.by_name.exists(gc_tags) then add_tags_to_suite_item(a_suite, a_annotations.by_name(gc_tags),a_suite.tags); end if; + a_suite.disabled_flag := ut_utils.boolean_to_int(a_annotations.by_name.exists(gc_disabled)); - + if a_annotations.by_name.exists(gc_disabled) then + l_annotation_text := trim(a_annotations.by_name(gc_disabled)(a_annotations.by_name(gc_disabled).first)); + a_suite.disabled_reason := l_annotation_text; + end if; + --process procedure annotations for suite get_annotated_procedures(a_annotations, a_suite, a_suite_items, l_before_each_list, l_after_each_list, l_before_all_list, l_after_all_list); diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 0ae8d7104..ad1634c10 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -67,7 +67,7 @@ create or replace package body ut_suite_cache_manager is select ut_suite_cache_row( null, s.self_type, s.path, s.object_owner, s.object_name, - s.object_name, null, null, null, null, 0, + s.object_name, null, null, null, null, 0,null, ut_varchar2_rows(), s.x, s.x, s.x, s.x, s.x, s.x, s.y, null, s.z @@ -325,7 +325,7 @@ create or replace package body ut_suite_cache_manager is ( id, self_type, path, object_owner, object_name, name, line_no, parse_time, description, - rollback_type, disabled_flag, warnings, + rollback_type, disabled_flag,disabled_reason, warnings, before_all_list, after_all_list, before_each_list, after_each_list, before_test_list, after_test_list, @@ -339,7 +339,7 @@ create or replace package body ut_suite_cache_manager is select /*+ no_parallel */ ut_suite_cache_seq.nextval, s.i.self_type as self_type, s.i.path as path, upper(s.i.object_owner) as object_owner, upper(s.i.object_name) as object_name, upper(s.i.name) as name, s.i.line_no as line_no, s.i.parse_time as parse_time, s.i.description as description, - s.i.rollback_type as rollback_type, s.i.disabled_flag as disabled_flag, s.i.warnings as warnings, + s.i.rollback_type as rollback_type, s.i.disabled_flag as disabled_flag,s.i.disabled_reason as disabled_reason, s.i.warnings as warnings, s.i.before_all_list as before_all_list, s.i.after_all_list as after_all_list, null before_each_list, null after_each_list, null before_test_list, null after_test_list, @@ -351,7 +351,7 @@ create or replace package body ut_suite_cache_manager is ( id, self_type, path, object_owner, object_name, name, line_no, parse_time, description, - rollback_type, disabled_flag, warnings, + rollback_type, disabled_flag,disabled_reason, warnings, before_all_list, after_all_list, before_each_list, after_each_list, before_test_list, after_test_list, @@ -365,7 +365,7 @@ create or replace package body ut_suite_cache_manager is select /*+ no_parallel */ ut_suite_cache_seq.nextval, s.t.self_type as self_type, s.t.path as path, upper(s.t.object_owner) as object_owner, upper(s.t.object_name) as object_name, upper(s.t.name) as name, s.t.line_no as line_no, s.t.parse_time as parse_time, s.t.description as description, - s.t.rollback_type as rollback_type, s.t.disabled_flag as disabled_flag, s.t.warnings as warnings, + s.t.rollback_type as rollback_type, s.t.disabled_flag as disabled_flag, s.t.disabled_reason as disabled_reason, s.t.warnings as warnings, null before_all_list, null after_all_list, s.t.before_each_list as before_each_list, s.t.after_each_list as after_each_list, s.t.before_test_list as before_test_list, s.t.after_test_list as after_test_list, @@ -408,7 +408,7 @@ create or replace package body ut_suite_cache_manager is select /*+ no_parallel */ ut_suite_item_info( c.object_owner, c.object_name, c.name, c.description, c.self_type, c.line_no, - c.path, c.disabled_flag, c.tags + c.path, c.disabled_flag, c.disabled_reason, c.tags ) bulk collect into l_results from table(l_cache_rows) c; diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 8a5bcb9b8..4bcb83afa 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -187,7 +187,7 @@ create or replace package body ut_suite_manager is self_type => a_rows( a_idx ).self_type, object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), @@ -200,7 +200,7 @@ create or replace package body ut_suite_manager is self_type => a_rows( a_idx ).self_type, object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), @@ -216,7 +216,7 @@ create or replace package body ut_suite_manager is self_type => a_rows( a_idx ).self_type, object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), @@ -229,7 +229,7 @@ create or replace package body ut_suite_manager is self_type => a_rows( a_idx ).self_type, object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), @@ -245,7 +245,7 @@ create or replace package body ut_suite_manager is self_type => a_rows( a_idx ).self_type, object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), @@ -256,7 +256,7 @@ create or replace package body ut_suite_manager is self_type => a_rows( a_idx ).self_type, object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), @@ -269,7 +269,7 @@ create or replace package body ut_suite_manager is self_type => a_rows(a_idx).self_type, object_owner => a_rows(a_idx).object_owner, object_name => lower(a_rows(a_idx).object_name), name => lower(a_rows(a_idx).name), description => a_rows(a_idx).description, path => a_rows(a_idx).path, - rollback_type => a_rows(a_idx).rollback_type, disabled_flag => a_rows(a_idx).disabled_flag, + rollback_type => a_rows(a_idx).rollback_type, disabled_flag => a_rows(a_idx).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, line_no => a_rows(a_idx).line_no, parse_time => a_rows(a_idx).parse_time, start_time => null, end_time => null, result => null, warnings => a_rows(a_idx).warnings, results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), diff --git a/source/reporters/ut_documentation_reporter.tpb b/source/reporters/ut_documentation_reporter.tpb index 8b92d447f..1dbe0cb92 100644 --- a/source/reporters/ut_documentation_reporter.tpb +++ b/source/reporters/ut_documentation_reporter.tpb @@ -68,7 +68,11 @@ create or replace type body ut_documentation_reporter is l_message := coalesce(a_test.description, a_test.name)||' ['||round(a_test.execution_time,3)||' sec]'; --if test failed, then add it to the failures list, print failure with number if a_test.result = ut_utils.gc_disabled then - self.print_yellow_text(l_message || ' (DISABLED)'); + self.print_yellow_text(l_message || ' (DISABLED'|| + case when a_test.disabled_reason is not null + then ' - '||a_test.disabled_reason + else null + end || ')'); elsif a_test.result = ut_utils.gc_success then self.print_green_text(l_message); elsif a_test.result > ut_utils.gc_success then diff --git a/test/install_ut3_tester_tests.sql b/test/install_ut3_tester_tests.sql index 9548d5148..8163a39f2 100644 --- a/test/install_ut3_tester_tests.sql +++ b/test/install_ut3_tester_tests.sql @@ -14,6 +14,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core/annotations/test_annot_throws_exception.pks @@ut3_tester/core/annotations/test_annotation_manager.pks @@ut3_tester/core/annotations/test_annotation_cache.pks +@@ut3_tester/core/annotations/test_annot_disabled_reason.pks @@ut3_tester/core/expectations/test_expectation_processor.pks @@ut3_tester/core/test_ut_utils.pks @@ut3_tester/core/test_ut_test.pks @@ -31,6 +32,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core/annotations/test_annotation_manager.pkb @@ut3_tester/core/annotations/test_annot_throws_exception.pkb @@ut3_tester/core/annotations/test_annotation_cache.pkb +@@ut3_tester/core/annotations/test_annot_disabled_reason.pkb @@ut3_tester/core/expectations/test_expectation_processor.pkb @@ut3_tester/core/test_ut_utils.pkb @@ut3_tester/core/test_ut_test.pkb diff --git a/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb b/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb new file mode 100644 index 000000000..70015484f --- /dev/null +++ b/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb @@ -0,0 +1,533 @@ +create or replace package body test_annot_disabled_reason +is + + procedure compile_dummy_packages is + pragma autonomous_transaction; + begin + execute immediate q'[create or replace package test_package_1 is + + --%suite + --%displayname(disable_test_suite_level) + --%suitepath(tests) + --%rollback(manual) + + --%disabled( Tests are disabled on suite level ) + + --%context( First context ) + + --%test(Test1 from test package 1) + procedure test1; + + --%test(Test2 from test package 1) + procedure test2; + + --%endcontext + + --%context( Second context ) + + --%test(Test3 from test package 1) + procedure test3; + + --%test(Test4 from test package 1) + procedure test4; + + --%endcontext + +end test_package_1;]'; + + execute immediate q'[create or replace package body test_package_1 is + + procedure test1 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test2 is + begin + ut.expect(2).to_equal(2); + end; + + procedure test3 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test4 is + begin + ut.expect(2).to_equal(2); + end; + +end test_package_1;]'; + + execute immediate q'[create or replace package test_package_2 is + + --%suite + --%displayname(Disable on context level) + --%suitepath(tests) + --%rollback(manual) + + --%context( First context ) + + --%disabled( Tests and disabled on first context level ) + + --%test(Test1 from test package 2) + procedure test1; + + --%test(Test2 from test package 2) + procedure test2; + + --%endcontext + + --%context( Second context ) + + --%test(Test3 from test package 2) + procedure test3; + + --%test(Test4 from test package 3) + procedure test4; + + --%endcontext + +end test_package_2;]'; + + execute immediate q'[create or replace package body test_package_2 is + + procedure test1 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test2 is + begin + ut.expect(2).to_equal(2); + end; + + procedure test3 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test4 is + begin + ut.expect(2).to_equal(2); + end; + +end test_package_2;]'; + + execute immediate q'[create or replace package test_package_3 is + + --%suite + --%displayname(Disable tests on test level) + --%suitepath(tests) + --%rollback(manual) + + --%context( First context ) + + --%test(Test1 from test package 3) + --%disabled( Test1 disabled from first context ) + procedure test1; + + --%test(Test2 from test package 3) + procedure test2; + + --%endcontext + + --%context( Second context ) + + --%test(Test3 from test package 3) + procedure test3; + + --%test(Test4 from test package 3) + --%disabled( Test4 disabled from second context ) + procedure test4; + + --%endcontext + +end test_package_3;]'; + + execute immediate q'[create or replace package body test_package_3 is + + procedure test1 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test2 is + begin + ut.expect(2).to_equal(2); + end; + + procedure test3 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test4 is + begin + ut.expect(2).to_equal(2); + end; + +end test_package_3;]'; + + execute immediate q'[create or replace package test_package_4 is + + --%suite + --%displayname(Disable reason is very long or have special characters) + --%suitepath(tests) + --%rollback(manual) + + + --%test(Test1 from test package 4) + --%disabled( $#?!%*&-/\^ ) + procedure test1; + + --%test(Test2 from test package 4) --%disabled(verylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtext) + procedure test2; + +end test_package_4;]'; + + execute immediate q'[create or replace package body test_package_4 is + + procedure test1 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test2 is + begin + ut.expect(2).to_equal(2); + end; + +end test_package_4;]'; + + execute immediate q'[create or replace package test_package_5 is + + --%suite + --%displayname(Disable tests on suite level overriding rest) + --%suitepath(tests) + --%rollback(manual) + + --%disabled( Disable on suite level ) + + --%context( First context ) + + --%disabled( Disable on 1st context level ) + + --%test(Test1 from test package 3) + --%disabled( Disable on 1st test level ) + procedure test1; + + --%test(Test2 from test package 3) + --%disabled( Disable on 2nd test level ) + procedure test2; + + --%endcontext + + --%context( Second context ) + + --%disabled( Disable on 2nd context level ) + + --%test(Test3 from test package 3) + --%disabled( Disable on 3rd test level ) + procedure test3; + + --%test(Test4 from test package 3) + --%disabled( Disable on 4th test level ) + procedure test4; + + --%endcontext + +end test_package_5;]'; + + execute immediate q'[create or replace package body test_package_5 is + + procedure test1 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test2 is + begin + ut.expect(2).to_equal(2); + end; + + procedure test3 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test4 is + begin + ut.expect(2).to_equal(2); + end; + +end test_package_5;]'; + + execute immediate q'[create or replace package test_package_6 is + + --%suite + --%displayname(Disable tests on each of ctx level overriding rest) + --%suitepath(tests) + --%rollback(manual) + + --%context( First context ) + + --%disabled( Disable on 1st context level ) + + --%test(Test1 from test package 3) + --%disabled( Disable on 1st test level ) + procedure test1; + + --%test(Test2 from test package 3) + --%disabled( Disable on 2nd test level ) + procedure test2; + + --%endcontext + + --%context( Second context ) + + --%disabled( Disable on 2nd context level ) + + --%test(Test3 from test package 3) + --%disabled( Disable on 3rd test level ) + procedure test3; + + --%test(Test4 from test package 3) + --%disabled( Disable on 4th test level ) + procedure test4; + + --%endcontext + +end test_package_6;]'; + + execute immediate q'[create or replace package body test_package_6 is + + procedure test1 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test2 is + begin + ut.expect(2).to_equal(2); + end; + + procedure test3 is + begin + ut.expect(1).to_equal(1); + end; + + procedure test4 is + begin + ut.expect(2).to_equal(2); + end; + +end test_package_6;]'; + + end; + + + procedure drop_dummy_packages is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_package_1'; + execute immediate 'drop package test_package_2'; + execute immediate 'drop package test_package_3'; + execute immediate 'drop package test_package_4'; + execute immediate 'drop package test_package_5'; + execute immediate 'drop package test_package_6'; + end; + + procedure test_disable_on_suite_level is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_1'; + l_objects_to_run ut3_develop.ut_suite_items; + + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_suite; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); + + ut.expect(l_test1_suite.items(1).name).to_equal('test1'); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Tests are disabled on suite level'); + + ut.expect(l_test1_suite.items(2).name).to_equal('test2'); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('Tests are disabled on suite level'); + + ut.expect(l_test1_suite.items(3).name).to_equal('test3'); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_equal('Tests are disabled on suite level'); + + ut.expect(l_test1_suite.items(4).name).to_equal('test4'); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_equal('Tests are disabled on suite level'); + + end; + + procedure test_dis_on_1st_ctx_level is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_2'; + l_objects_to_run ut3_develop.ut_suite_items; + + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_suite; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); + + ut.expect(l_test1_suite.items(1).name).to_equal('test1'); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Tests and disabled on first context level'); + + ut.expect(l_test1_suite.items(2).name).to_equal('test2'); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('Tests and disabled on first context level'); + + ut.expect(l_test1_suite.items(3).name).to_equal('test3'); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(0); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_be_null; + + ut.expect(l_test1_suite.items(4).name).to_equal('test4'); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(0); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_be_null; + + end; + + procedure test_disable_tests_level is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_3'; + l_objects_to_run ut3_develop.ut_suite_items; + + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_suite; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); + + ut.expect(l_test1_suite.items(1).name).to_equal('test1'); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Test1 disabled from first context'); + + ut.expect(l_test1_suite.items(2).name).to_equal('test2'); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(0); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_be_null; + + ut.expect(l_test1_suite.items(3).name).to_equal('test3'); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(0); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_be_null; + + ut.expect(l_test1_suite.items(4).name).to_equal('test4'); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_equal('Test4 disabled from second context'); + + end; + + procedure test_long_text_spec_chr is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_4'; + l_objects_to_run ut3_develop.ut_suite_items; + + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_suite; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); + + ut.expect(l_test1_suite.items(1).name).to_equal('test1'); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('$#?!%*&-/\^'); + + ut.expect(l_test1_suite.items(2).name).to_equal('test2'); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('verylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtext'); + + + end; + + procedure test_disable_suite_ctx_tst is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_5'; + l_objects_to_run ut3_develop.ut_suite_items; + + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_suite; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); + + ut.expect(l_test1_suite.items(1).name).to_equal('test1'); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on suite level'); + + ut.expect(l_test1_suite.items(2).name).to_equal('test2'); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on suite level'); + + ut.expect(l_test1_suite.items(3).name).to_equal('test3'); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on suite level'); + + ut.expect(l_test1_suite.items(4).name).to_equal('test4'); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on suite level'); + + end; + + procedure test_disable_ctx_tst is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_6'; + l_objects_to_run ut3_develop.ut_suite_items; + + l_test0_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_suite; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); + + ut.expect(l_test1_suite.items(1).name).to_equal('test1'); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on 1st context level'); + + ut.expect(l_test1_suite.items(2).name).to_equal('test2'); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on 1st context level'); + + ut.expect(l_test1_suite.items(3).name).to_equal('test3'); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on 2nd context level'); + + ut.expect(l_test1_suite.items(4).name).to_equal('test4'); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(1); + ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on 2nd context level'); + + end; + +end; +/ diff --git a/test/ut3_tester/core/annotations/test_annot_disabled_reason.pks b/test/ut3_tester/core/annotations/test_annot_disabled_reason.pks new file mode 100644 index 000000000..cae5da1ee --- /dev/null +++ b/test/ut3_tester/core/annotations/test_annot_disabled_reason.pks @@ -0,0 +1,31 @@ +create or replace package test_annot_disabled_reason +is + --%suite(annotations - disabled) + --%suitepath(utplsql.ut3_tester.core.annotations) + + --%beforeall + procedure compile_dummy_packages; + + --%afterall + procedure drop_dummy_packages; + + --%test(Disable all tests under the suite displaying suite level reason) + procedure test_disable_on_suite_level; + + --%test(Disable all tests under one of two contexts displaying context level reason) + procedure test_dis_on_1st_ctx_level; + + --%test(Disable a single tests from each of the contexts displaying test level reason) + procedure test_disable_tests_level; + + --%test(Disable tests with reason using special characters and long reason) + procedure test_long_text_spec_chr; + + --%test(Disable tests on suite , context and test level and display suite level reason) + procedure test_disable_suite_ctx_tst; + + --%test(Disable tests on context and test level and display context level reason) + procedure test_disable_ctx_tst; + +end; +/ diff --git a/test/ut3_user/api/test_ut_runner.pkb b/test/ut3_user/api/test_ut_runner.pkb index 2aa624ed8..a24fc2d51 100644 --- a/test/ut3_user/api/test_ut_runner.pkb +++ b/test/ut3_user/api/test_ut_runner.pkb @@ -267,22 +267,22 @@ end;'; select 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, 'dummy_test_suite' item_description, 'UT_SUITE' item_type, 2 item_line_no, - 'some.path.dummy_test_package' path, 0 disabled_flag,null tags + 'some.path.dummy_test_package' path, 0 disabled_flag, null disabled_reason,null tags from dual union all select 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, 'dummy_test' item_description, 'UT_TEST' item_type, 6 item_line_no, - 'some.path.dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag,null tags + 'some.path.dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason,null tags from dual union all select 'UT3$USER#' object_owner, 'PATH' object_name, 'PATH' item_name, null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, - 'some.path' path, 0 disabled_flag, null tags + 'some.path' path, 0 disabled_flag, null disabled_reason, null tags from dual union all select 'UT3$USER#' object_owner, 'SOME' object_name, 'SOME' item_name, null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, - 'some' path, 0 disabled_flag, null tags + 'some' path, 0 disabled_flag, null disabled_reason, null tags from dual; --Act open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); @@ -299,22 +299,22 @@ end;'; select 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, 'dummy_test_suite' item_description, 'UT_SUITE' item_type, 2 item_line_no, - 'some.path.dummy_test_package' path, 0 disabled_flag,'dummy' tags + 'some.path.dummy_test_package' path, 0 disabled_flag, null disabled_reason,'dummy' tags from dual union all select 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, 'dummy_test' item_description, 'UT_TEST' item_type, 7 item_line_no, - 'some.path.dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag,'testtag' tags + 'some.path.dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason,'testtag' tags from dual union all select 'UT3$USER#' object_owner, 'PATH' object_name, 'PATH' item_name, null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, - 'some.path' path, 0 disabled_flag, null tags + 'some.path' path, 0 disabled_flag, null disabled_reason, null tags from dual union all select 'UT3$USER#' object_owner, 'SOME' object_name, 'SOME' item_name, null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, - 'some' path, 0 disabled_flag, null tags + 'some' path, 0 disabled_flag, null disabled_reason, null tags from dual; --Act open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); @@ -331,12 +331,12 @@ end;'; select 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, 'dummy_test_suite' item_description, 'UT_SUITE' item_type, 2 item_line_no, - 'dummy_test_package' path, 0 disabled_flag,'suitetag1,suitetag2' tags + 'dummy_test_package' path, 0 disabled_flag, null disabled_reason,'suitetag1,suitetag2' tags from dual union all select 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, 'dummy_test' item_description, 'UT_TEST' item_type, 6 item_line_no, - 'dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag,'testtag1,testtag2' tags + 'dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason,'testtag1,testtag2' tags from dual; --Act open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); From cbe03e830810da8ce588368eacc6504f1e42dd22 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 6 Feb 2022 16:09:07 +0000 Subject: [PATCH 238/887] Update test coverage and documentation --- docs/userguide/expectations.md | 4 ++++ source/expectations/data_values/ut_compound_data_helper.pkb | 2 -- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 07ff647e5..52e233125 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1645,6 +1645,10 @@ FAILURE utPLSQL is capable of comparing json data-types of `json_element_t` **on Oracle 12.2 and above**, and also `json` **on Oracle 21 and above** +**Note:** +> Whenever a database is upgraded to compatible version the utPLSQL needs to be reinstalled to pick up json changes. E.g. upgrade from 18c to 21c to enable `json` type compare. + + ### Notes on comparison of json data - Json data can contain objects, scalar or arrays. diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index e29f10279..94c7c1ab8 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -786,8 +786,6 @@ create or replace package body ut_compound_data_helper is begin $if dbms_db_version.version >= 21 $then l_obj := case when a_json_t is null then cast (null as json_element_t ) else json_element_t.parse(json_query(a_json_t, '$' returning clob)) end; - $else - l_obj := null; $end return l_obj; end; From 08bb27b790945c664387867f62ed91d2733816a8 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 6 Feb 2022 16:54:30 +0000 Subject: [PATCH 239/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 5747ee5e0..20a49b3bc 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 01f39d138..27b93a7d2 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 4294753e7..9a0ff9234 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index adec7b7dc..606a59eb0 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 7a11e5132..697f2e525 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index c22fd54bb..98df0e6f3 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index f44da6f6a..8b0924d25 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index e4dca3223..9f74d801f 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 265c65bdb..08e2ccd1e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e0ddfa62b..c70fac545 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 1a19a2d67..90f3a3798 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 623abfda5..220f650cd 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 17225bc88..3503d645a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 64ab627cf..c96aed1ac 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 44d5c81a9..8e8786f6b 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 36ce5aa31..649337d63 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 2370743c8..707de2e7e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3791--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 44aaf4e5e..36db42f05 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -788,7 +788,7 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.12.3791-develop + * secion v3.1.12.3796-develop */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 99512e1b4..c8b434592 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3791-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3796-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From fddde601f3895f2e7ab24866dd5b9dc4213647ee Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 6 Feb 2022 17:09:07 +0000 Subject: [PATCH 240/887] Updating testss --- .../test_annot_disabled_reason.pkb | 261 +++++++----------- 1 file changed, 106 insertions(+), 155 deletions(-) diff --git a/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb b/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb index 70015484f..e3df44425 100644 --- a/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb +++ b/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb @@ -1,6 +1,7 @@ create or replace package body test_annot_disabled_reason is + procedure compile_dummy_packages is pragma autonomous_transaction; begin @@ -181,7 +182,8 @@ end test_package_3;]'; --%disabled( $#?!%*&-/\^ ) procedure test1; - --%test(Test2 from test package 4) --%disabled(verylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtext) + --%test(Test2 from test package 4) + --%disabled(verylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtext) procedure test2; end test_package_4;]'; @@ -339,193 +341,142 @@ end test_package_6;]'; end; procedure test_disable_on_suite_level is - c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_1'; - l_objects_to_run ut3_develop.ut_suite_items; - - l_test0_suite ut3_develop.ut_logical_suite; - l_test1_suite ut3_develop.ut_suite; + l_test_results ut3_develop.ut_varchar2_list; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); begin --Act - l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); - - --Assert - ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); - l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); - - ut.expect(l_test1_suite.items(1).name).to_equal('test1'); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Tests are disabled on suite level'); - - ut.expect(l_test1_suite.items(2).name).to_equal('test2'); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('Tests are disabled on suite level'); - - ut.expect(l_test1_suite.items(3).name).to_equal('test3'); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_equal('Tests are disabled on suite level'); - - ut.expect(l_test1_suite.items(4).name).to_equal('test4'); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_equal('Tests are disabled on suite level'); + + select * bulk collect into l_test_results from table(ut3_develop.ut.run((sys_context('USERENV', 'CURRENT_USER')||'.test_package_1'))); + + l_actual_message := ut3_develop.ut_utils.table_to_clob(l_test_results); + + l_expected_message := q'[%tests +%disable_test_suite_level +%First context +%Test1 from test package 1 [0 sec] (DISABLED - Tests are disabled on suite level) +%Test2 from test package 1 [0 sec] (DISABLED - Tests are disabled on suite level) +%Second context +%Test3 from test package 1 [0 sec] (DISABLED - Tests are disabled on suite level) +%Test4 from test package 1 [0 sec] (DISABLED - Tests are disabled on suite level)%]'; + ut.expect(l_actual_message).to_be_like(l_expected_message); end; procedure test_dis_on_1st_ctx_level is - c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_2'; - l_objects_to_run ut3_develop.ut_suite_items; - - l_test0_suite ut3_develop.ut_logical_suite; - l_test1_suite ut3_develop.ut_suite; + l_test_results ut3_develop.ut_varchar2_list; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); begin --Act - l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); - - --Assert - ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); - l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); - - ut.expect(l_test1_suite.items(1).name).to_equal('test1'); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Tests and disabled on first context level'); - - ut.expect(l_test1_suite.items(2).name).to_equal('test2'); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('Tests and disabled on first context level'); - - ut.expect(l_test1_suite.items(3).name).to_equal('test3'); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(0); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_be_null; - - ut.expect(l_test1_suite.items(4).name).to_equal('test4'); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(0); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_be_null; + + select * bulk collect into l_test_results from table(ut3_develop.ut.run((sys_context('USERENV', 'CURRENT_USER')||'.test_package_2'))); + + l_actual_message := ut3_develop.ut_utils.table_to_clob(l_test_results); + + l_expected_message := q'[%tests +%Disable on context level +%First context +%Test1 from test package 2 [0 sec] (DISABLED - Tests and disabled on first context level) +%Test2 from test package 2 [0 sec] (DISABLED - Tests and disabled on first context level) +%Second context +%Test3 from test package 2 [% sec] +%Test4 from test package 3 [% sec]%]'; + + ut.expect(l_actual_message).to_be_like(l_expected_message); end; procedure test_disable_tests_level is - c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_3'; - l_objects_to_run ut3_develop.ut_suite_items; - - l_test0_suite ut3_develop.ut_logical_suite; - l_test1_suite ut3_develop.ut_suite; + l_test_results ut3_develop.ut_varchar2_list; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); begin --Act - l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); - - --Assert - ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); - l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); - - ut.expect(l_test1_suite.items(1).name).to_equal('test1'); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Test1 disabled from first context'); - - ut.expect(l_test1_suite.items(2).name).to_equal('test2'); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(0); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_be_null; - - ut.expect(l_test1_suite.items(3).name).to_equal('test3'); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(0); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_be_null; - - ut.expect(l_test1_suite.items(4).name).to_equal('test4'); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_equal('Test4 disabled from second context'); + + select * bulk collect into l_test_results from table(ut3_develop.ut.run((sys_context('USERENV', 'CURRENT_USER')||'.test_package_3'))); + + l_actual_message := ut3_develop.ut_utils.table_to_clob(l_test_results); + + l_expected_message := q'[%tests +%Disable tests on test level +%First context +%Test1 from test package 3 [0 sec] (DISABLED - Test1 disabled from first context) +%Test2 from test package 3 [% sec] +%Second context +%Test3 from test package 3 [% sec] +%Test4 from test package 3 [0 sec] (DISABLED - Test4 disabled from second context)%]'; + + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; procedure test_long_text_spec_chr is - c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_4'; - l_objects_to_run ut3_develop.ut_suite_items; - - l_test0_suite ut3_develop.ut_logical_suite; - l_test1_suite ut3_develop.ut_suite; + l_test_results ut3_develop.ut_varchar2_list; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); begin --Act - l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); - - --Assert - ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); - l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); - - ut.expect(l_test1_suite.items(1).name).to_equal('test1'); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('$#?!%*&-/\^'); - - ut.expect(l_test1_suite.items(2).name).to_equal('test2'); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('verylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtext'); + + select * bulk collect into l_test_results from table(ut3_develop.ut.run((sys_context('USERENV', 'CURRENT_USER')||'.test_package_4'))); + l_actual_message := ut3_develop.ut_utils.table_to_clob(l_test_results); + + l_expected_message := q'[%tests +%Disable reason is very long or have special characters +%Test1 from test package 4 [0 sec] (DISABLED - $#?!%*&-/\^) +%Test2 from test package 4 [0 sec] (DISABLED - verylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtextverylongtext)%]'; + ut.expect(l_actual_message).to_be_like(l_expected_message); end; procedure test_disable_suite_ctx_tst is - c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_5'; - l_objects_to_run ut3_develop.ut_suite_items; - - l_test0_suite ut3_develop.ut_logical_suite; - l_test1_suite ut3_develop.ut_suite; + l_test_results ut3_develop.ut_varchar2_list; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); begin --Act - l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); - - --Assert - ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); - l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); - - ut.expect(l_test1_suite.items(1).name).to_equal('test1'); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on suite level'); - - ut.expect(l_test1_suite.items(2).name).to_equal('test2'); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on suite level'); - - ut.expect(l_test1_suite.items(3).name).to_equal('test3'); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on suite level'); - - ut.expect(l_test1_suite.items(4).name).to_equal('test4'); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on suite level'); + + select * bulk collect into l_test_results from table(ut3_develop.ut.run((sys_context('USERENV', 'CURRENT_USER')||'.test_package_5'))); + + l_actual_message := ut3_develop.ut_utils.table_to_clob(l_test_results); + + l_expected_message := q'[%tests +%Disable tests on suite level overriding rest +%First context +%Test1 from test package 3 [0 sec] (DISABLED - Disable on suite level) +%Test2 from test package 3 [0 sec] (DISABLED - Disable on suite level) +%Second context +%Test3 from test package 3 [0 sec] (DISABLED - Disable on suite level) +%Test4 from test package 3 [0 sec] (DISABLED - Disable on suite level)%]'; + + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; procedure test_disable_ctx_tst is - c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_6'; - l_objects_to_run ut3_develop.ut_suite_items; - - l_test0_suite ut3_develop.ut_logical_suite; - l_test1_suite ut3_develop.ut_suite; + l_test_results ut3_develop.ut_varchar2_list; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); begin --Act - l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); - - --Assert - ut.expect(l_objects_to_run.count).to_equal(1); - l_test0_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); - l_test1_suite := treat(l_test0_suite.items(1) as ut3_develop.ut_suite); - - ut.expect(l_test1_suite.items(1).name).to_equal('test1'); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(1) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on 1st context level'); - - ut.expect(l_test1_suite.items(2).name).to_equal('test2'); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(2) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on 1st context level'); - - ut.expect(l_test1_suite.items(3).name).to_equal('test3'); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(3) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on 2nd context level'); - - ut.expect(l_test1_suite.items(4).name).to_equal('test4'); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_flag).to_equal(1); - ut.expect(treat(l_test1_suite.items(4) as ut3_develop.ut_test).disabled_reason).to_equal('Disable on 2nd context level'); + + select * bulk collect into l_test_results from table(ut3_develop.ut.run((sys_context('USERENV', 'CURRENT_USER')||'.test_package_6'))); + + l_actual_message := ut3_develop.ut_utils.table_to_clob(l_test_results); + + l_expected_message := q'[%tests +%Disable tests on each of ctx level overriding rest +%First context +%Test1 from test package 3 [0 sec] (DISABLED - Disable on 1st context level) +%Test2 from test package 3 [0 sec] (DISABLED - Disable on 1st context level) +%Second context +%Test3 from test package 3 [0 sec] (DISABLED - Disable on 2nd context level) +%Test4 from test package 3 [0 sec] (DISABLED - Disable on 2nd context level)%]'; + + ut.expect(l_actual_message).to_be_like(l_expected_message); end; From 201050f33a5010ddffa891ef2c9a3099f04e2c51 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 7 Feb 2022 00:48:25 +0200 Subject: [PATCH 241/887] Gather coverage on code calling DBMS_STATS. Implemented a workaround that allows for running utPLSQL tests with code coverage on source with calls to DBMS_STATS. Resolves: #1097 Resolves: #1094 --- .../coverage/ut_coverage_helper_block.pkb | 8 ++++ test/ut3_tester_helper/coverage_helper.pkb | 44 +++++++++++++++++++ test/ut3_tester_helper/coverage_helper.pks | 3 ++ .../test_coverage/test_extended_coverage.pkb | 23 ++++++++++ .../test_coverage/test_extended_coverage.pks | 6 +++ 5 files changed, 84 insertions(+) diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index 25cb00f90..fb4d4812e 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -39,6 +39,14 @@ create or replace package body ut_coverage_helper_block is $else null; $end + exception + when others then + if sqlcode = -08402 then + dbms_output.put_line('Unable to finish gathering coverage with DBMS_PLSQL_CODE_COVERAGE. '); + dbms_output.put_line('Encountered exception `ORA-08402` when calling procedure `DBMS_PLSQL_CODE_COVERAGE.STOP_COVERAGE()`.'); + dbms_output.put_line('Coverage report will only include line-level code-coverage (without branches).'); + dbms_output.put_line('Please reference following issue for details on possible causes: https://github.com/utPLSQL/utPLSQL/issues/1097 '); + end if; end; function block_results(a_object ut_coverage_helper.t_tmp_table_object, a_coverage_run_id raw) return t_block_rows is diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 0abe10a4f..137c7e953 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -123,6 +123,50 @@ create or replace package body coverage_helper is begin execute immediate q'[drop package ut3_develop.test_dummy_coverage_1]'; exception when others then null; end; end; + procedure create_cov_with_dbms_stats is + pragma autonomous_transaction; + begin + execute immediate q'[create table ut3_develop.table_to_test_stats as select * from user_objects]'; + + execute immediate q'[create or replace package ut3_develop.stats is + procedure gather; + end;]'; + + execute immediate q'[create or replace package body ut3_develop.stats is + procedure gather is + begin + dbms_Stats.gather_table_stats('UT3_DEVELOP','TABLE_TO_TEST_STATS'); + end; + end;]'; + + execute immediate q'[create or replace package ut3_develop.test_stats is + --%suite(stats gathering coverage test) + --%suitepath(coverage_testing) + + --%test + procedure test_stats_gather; + + end;]'; + + execute immediate q'[create or replace package body ut3_develop.test_stats is + procedure test_stats_gather is + begin + stats.gather; + ut.expect(1).to_equal(1); + end; + end;]'; + + end; + + procedure drop_cov_with_dbms_stats is + pragma autonomous_transaction; + begin + begin execute immediate q'[drop package ut3_develop.test_stats]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.stats]'; exception when others then null; end; + begin execute immediate q'[drop table ut3_develop.table_to_test_stats]'; exception when others then null; end; + end; + + procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer) is begin ut3_develop.ut_runner.coverage_start(a_coverage_run_id); diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index 9a3bd1db6..1db09a01b 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -14,6 +14,9 @@ create or replace package coverage_helper is procedure create_dummy_coverage_1; procedure drop_dummy_coverage_1; + procedure create_cov_with_dbms_stats; + procedure drop_cov_with_dbms_stats; + procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer); procedure run_coverage_job(a_coverage_run_id raw, a_input integer); diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index ec95c0bfb..a8d104e28 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -83,5 +83,28 @@ create or replace package body test_extended_coverage is ut.expect(l_actual).to_be_like(l_expected); end; + procedure coverage_with_dbms_stats is + l_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%' || + '%%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_stats', + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_coverage_schemes => ut3_develop.ut_varchar2_list( 'ut3_develop' ), + a_include_objects => ut3_develop.ut_varchar2_list('stats') + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + end; + end; / diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks index 600a87e16..c575c240c 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks @@ -11,6 +11,12 @@ create or replace package test_extended_coverage is --%test(Coverage is gathered for specified file - extended coverage type) procedure coverage_for_file; + + --%beforetest(ut3_tester_helper.coverage_helper.create_cov_with_dbms_stats) + --%aftertest(ut3_tester_helper.coverage_helper.drop_cov_with_dbms_stats) + --%tags(#1097,#1094) + --%test(Extended coverage does not fail the test run then tested code calls DBMS_STATS) + procedure coverage_with_dbms_stats; end; / From 449bb708c6584a2d4f682366e9a1546380e13961 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 7 Feb 2022 00:57:22 +0200 Subject: [PATCH 242/887] Testing reporting of failing tests in branch and PR builds. --- test/ut3_user/expectations.pkb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/ut3_user/expectations.pkb b/test/ut3_user/expectations.pkb index 30af48a44..b4dfe5b41 100644 --- a/test/ut3_user/expectations.pkb +++ b/test/ut3_user/expectations.pkb @@ -28,7 +28,8 @@ SUCCESS Actual: 0 (number) was expected to equal: 0 (number) ]'; - ut.expect(l_actual).to_be_like(l_expected); + --deliberate change to make a test fail + ut.expect(l_actual).not_to_be_like(l_expected); rollback; end; From 2f29162369713529e69879056bd61e4a3372242b Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 7 Feb 2022 01:16:00 +0200 Subject: [PATCH 243/887] Reorganizing matrix variables. --- .github/workflows/build.yml | 42 ++++++++++++++----------------------- 1 file changed, 16 insertions(+), 26 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9048db4ee..8f11522fd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -20,49 +20,39 @@ jobs: env: ORACLE_VERSION: ${{matrix.oracle-version}} ORACLE_SID: ${{matrix.oracle-sid}} - CONNECTION_STR: ${{matrix.connection-str}} + CONNECTION_STR: ${{ format( '127.0.0.1:1521/{0}', matrix.oracle-sid ) }} ORACLE_PASSWORD: oracle DOCKER_VOLUME: ${{matrix.docker-volume}} strategy: fail-fast: false matrix: include: - - oracle-version: "gvenzl/oracle-xe:11-full" + - id: 1 + db_version_name: '11XE' oracle-sid: 'XE' - connection-str: '127.0.0.1:1521/XE' - id: 1 - db_version_name: '11xe' + oracle-version: "gvenzl/oracle-xe:11-full" # TODO - need to add healthcheck.sh into our containers -# - oracle-version: "utplsqlv3/oracledb:12c-r1-se2-small" +# - id: 2 +# db_version_name: '12.1EE' # oracle-sid: 'ORCLCDB' -# connection-str: '127.0.0.1:1521/ORCLCDB' -# id: 2 -# db_version_name: '12.1se' +# oracle-version: "utplsqlv3/oracledb:12c-r1-ee-small" # - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" # oracle-sid: 'ORCLCDB' # connection-str: '127.0.0.1:1521/ORCLCDB' # id: 3 # db_version_name: '12.2se' - - oracle-version: "gvenzl/oracle-xe:18-slim" + - id: 4 + db_version_name: '18XE' oracle-sid: 'XE' - connection-str: '127.0.0.1:1521/XE' - id: 4 - db_version_name: '18xe' -# - oracle-version: "utplsqlv3/oracledb:18c-se2-small" -# oracle-sid: 'ORCLCDB' -# connection-str: '127.0.0.1:1521/ORCLCDB' -# id: 5 -# db_version_name: '18se' -# - oracle-version: "utplsqlv3/oracledb:19c-se2-small" -# oracle-sid: 'ORCLCDB' -# connection-str: '127.0.0.1:1521/ORCLCDB' -# id: 6 + oracle-version: "gvenzl/oracle-xe:18-slim" +# - id: 5 # db_version_name: '19se' - - oracle-version: "gvenzl/oracle-xe:21-slim" +# oracle-sid: 'ORCLCDB' +# oracle-version: "utplsqlv3/oracledb:19c-se2-small" + - id: 6 + db_version_name: '21XE' oracle-sid: 'XE' - connection-str: '127.0.0.1:1521/XE' - id: 7 - db_version_name: '21xe' + oracle-version: "gvenzl/oracle-xe:21-slim" services: oracle: From 79da316a860c4eb2dd7aa11253b377aa3e4a3772 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 7 Feb 2022 09:06:00 +0000 Subject: [PATCH 244/887] Resolving a code comments --- source/core/ut_suite_builder.pkb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 7ad24bd57..ebb113370 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -570,8 +570,7 @@ create or replace package body ut_suite_builder is a_suite.disabled_flag := ut_utils.boolean_to_int(a_annotations.by_name.exists(gc_disabled)); if a_annotations.by_name.exists(gc_disabled) then - l_annotation_text := trim(a_annotations.by_name(gc_disabled)(a_annotations.by_name(gc_disabled).first)); - a_suite.disabled_reason := l_annotation_text; + a_suite.disabled_reason := a_annotations.by_name(gc_disabled)(a_annotations.by_name(gc_disabled).first); end if; --process procedure annotations for suite From ed156d791f979196b3a0dd4b986f2e527733059f Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 7 Feb 2022 13:32:50 +0000 Subject: [PATCH 245/887] Updating reporters --- source/reporters/ut_junit_reporter.tpb | 8 +++++++- source/reporters/ut_teamcity_reporter.tpb | 2 +- source/reporters/ut_teamcity_reporter_helper.pkb | 5 ++++- source/reporters/ut_teamcity_reporter_helper.pks | 2 +- source/reporters/ut_tfs_junit_reporter.tpb | 6 ++++++ test/ut3_user/reporters.pkb | 2 +- test/ut3_user/reporters/test_documentation_reporter.pkb | 2 +- test/ut3_user/reporters/test_junit_reporter.pkb | 4 +++- 8 files changed, 24 insertions(+), 7 deletions(-) diff --git a/source/reporters/ut_junit_reporter.tpb b/source/reporters/ut_junit_reporter.tpb index 94ea5c5e6..44affa030 100644 --- a/source/reporters/ut_junit_reporter.tpb +++ b/source/reporters/ut_junit_reporter.tpb @@ -44,7 +44,13 @@ create or replace type body ut_junit_reporter is ' status="' || ut_utils.test_result_to_char(a_test.result) || '"' end || '>' ); if a_test.result = ut_utils.gc_disabled then - ut_utils.append_to_list( l_results, '' ); + if a_test.disabled_reason is not null then + ut_utils.append_to_list( l_results, '' ); + ut_utils.append_to_list( l_results, ut_utils.to_cdata( a_test.disabled_reason ) ); + ut_utils.append_to_list( l_results, '' ); + else + ut_utils.append_to_list( l_results, '' ); + end if; end if; if a_test.result = ut_utils.gc_error then ut_utils.append_to_list( l_results, ''); diff --git a/source/reporters/ut_teamcity_reporter.tpb b/source/reporters/ut_teamcity_reporter.tpb index 3e1a4bcf8..95bea32b8 100644 --- a/source/reporters/ut_teamcity_reporter.tpb +++ b/source/reporters/ut_teamcity_reporter.tpb @@ -84,7 +84,7 @@ create or replace type body ut_teamcity_reporter is lower(a_test.item.procedure_name); if a_test.result = ut_utils.gc_disabled then - ut_utils.append_to_list( l_results, ut_teamcity_reporter_helper.test_disabled(l_test_full_name)); + ut_utils.append_to_list( l_results, ut_teamcity_reporter_helper.test_disabled(l_test_full_name,a_test.disabled_reason)); else ut_utils.append_to_list( l_results, a_test.get_serveroutputs()); diff --git a/source/reporters/ut_teamcity_reporter_helper.pkb b/source/reporters/ut_teamcity_reporter_helper.pkb index 3a4679cb4..84a9d19e8 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pkb +++ b/source/reporters/ut_teamcity_reporter_helper.pkb @@ -89,10 +89,13 @@ create or replace package body ut_teamcity_reporter_helper is return message('testFinished', l_props); end; - function test_disabled(a_test_name varchar2, a_flow_id varchar2 default null) return varchar2 is + function test_disabled(a_test_name varchar2,a_msg varchar2 default null, a_flow_id varchar2 default null) return varchar2 is l_props t_props; begin l_props('name') := a_test_name; + if a_msg is not null then + l_props('message') := a_msg; + end if; l_props('flowId') := a_flow_id; return message('testIgnored', l_props); end; diff --git a/source/reporters/ut_teamcity_reporter_helper.pks b/source/reporters/ut_teamcity_reporter_helper.pks index d94099411..d7fa86cdc 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pks +++ b/source/reporters/ut_teamcity_reporter_helper.pks @@ -21,7 +21,7 @@ create or replace package ut_teamcity_reporter_helper is function test_started(a_test_name varchar2, a_capture_standard_output boolean default null, a_flow_id varchar2 default null) return varchar2; function test_finished(a_test_name varchar2, a_test_duration_milisec number default null, a_flow_id varchar2 default null) return varchar2; - function test_disabled(a_test_name varchar2, a_flow_id varchar2 default null) return varchar2; + function test_disabled(a_test_name varchar2,a_msg varchar2 default null, a_flow_id varchar2 default null) return varchar2; function test_failed(a_test_name varchar2, a_msg in varchar2 default null, a_details varchar2 default null, a_flow_id varchar2 default null, a_actual varchar2 default null, a_expected varchar2 default null) return varchar2; function test_std_err(a_test_name varchar2, a_out in varchar2, a_flow_id in varchar2 default null) return varchar2; diff --git a/source/reporters/ut_tfs_junit_reporter.tpb b/source/reporters/ut_tfs_junit_reporter.tpb index e14af1d4d..710c3bc7f 100644 --- a/source/reporters/ut_tfs_junit_reporter.tpb +++ b/source/reporters/ut_tfs_junit_reporter.tpb @@ -69,6 +69,12 @@ create or replace type body ut_tfs_junit_reporter is ut_utils.append_to_list( l_results, ut_utils.to_cdata( ut_utils.convert_collection( a_test.get_error_stack_traces() ) ) ); ut_utils.append_to_list( l_results, ''); -- Do not count error as failure + elsif a_test.result = ut_utils.gc_disabled then + if a_test.disabled_reason is not null then + ut_utils.append_to_list( l_results, ''); + else + ut_utils.append_to_list( l_results, '' ); + end if; elsif a_test.result = ut_utils.gc_failure then ut_utils.append_to_list( l_results, ''); ut_utils.append_to_list( l_results, ut_utils.to_cdata( a_test.get_failed_expectation_lines() ) ); diff --git a/test/ut3_user/reporters.pkb b/test/ut3_user/reporters.pkb index edd26189c..d33adce23 100644 --- a/test/ut3_user/reporters.pkb +++ b/test/ut3_user/reporters.pkb @@ -35,7 +35,7 @@ as procedure erroring_test; --%test(a disabled test) - --%disabled + --%disabled(Disabled for testing purpose) procedure disabled_test; --%aftereach diff --git a/test/ut3_user/reporters/test_documentation_reporter.pkb b/test/ut3_user/reporters/test_documentation_reporter.pkb index 03759fe6a..4d44d2f63 100644 --- a/test/ut3_user/reporters/test_documentation_reporter.pkb +++ b/test/ut3_user/reporters/test_documentation_reporter.pkb @@ -24,7 +24,7 @@ create or replace package body test_documentation_reporter as - a disabled test [0 sec] (DISABLED) + a disabled test [0 sec] (DISABLED - Disabled for testing purpose) % Failures: diff --git a/test/ut3_user/reporters/test_junit_reporter.pkb b/test/ut3_user/reporters/test_junit_reporter.pkb index 8f015e80b..24012f6bb 100644 --- a/test/ut3_user/reporters/test_junit_reporter.pkb +++ b/test/ut3_user/reporters/test_junit_reporter.pkb @@ -249,7 +249,9 @@ create or replace package body test_junit_reporter as - + + + From 2ea9a53d3bc67588ffa0b1078deb141695833ad1 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 7 Feb 2022 13:41:41 +0000 Subject: [PATCH 246/887] Updates to junit xsd --- .github/scripts/xsd/junit_windy.xsd | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/.github/scripts/xsd/junit_windy.xsd b/.github/scripts/xsd/junit_windy.xsd index fe134662a..320779edd 100644 --- a/.github/scripts/xsd/junit_windy.xsd +++ b/.github/scripts/xsd/junit_windy.xsd @@ -1,6 +1,6 @@ - - @@ -71,10 +71,11 @@ Permission to waive conditions of this license may be requested from Windy Road - - - Indicates that the test errored. An errored test is one that had an unanticipated problem. e.g., an unchecked throwable; or a problem with the implementation of the test. Contains as a text node relevant data for the error, e.g., a stack trace - + + + + Indicates that the test errored. An errored test is one that had an unanticipated problem. e.g., an unchecked throwable; or a problem with the implementation of the test. Contains as a text node relevant data for the error, e.g., a stack trace + @@ -93,9 +94,9 @@ Permission to waive conditions of this license may be requested from Windy Road - - Indicates that the test failed. A failure is a test which the code has explicitly failed by using the mechanisms for that purpose. e.g., via an assertEquals. Contains as a text node relevant data for the failure, e.g., a stack trace - + + Indicates that the test failed. A failure is a test which the code has explicitly failed by using the mechanisms for that purpose. e.g., via an assertEquals. Contains as a text node relevant data for the failure, e.g., a stack trace + @@ -192,6 +193,11 @@ Permission to waive conditions of this license may be requested from Windy Road The total number of tests in the suite that errored. An errored test is one that had an unanticipated problem. e.g., an unchecked throwable; or a problem with the implementation of the test. + + + The total number of ignored or skipped tests in the suite. + + Time taken (in seconds) to execute the tests in the suite @@ -203,4 +209,4 @@ Permission to waive conditions of this license may be requested from Windy Road - + \ No newline at end of file From 78cfb830176d5eb0d6456f4c83244586225b4b3e Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 7 Feb 2022 14:19:48 +0000 Subject: [PATCH 247/887] Update coverage --- test/ut3_user/reporters.pkb | 11 +++++++++++ .../reporters/test_documentation_reporter.pkb | 3 ++- test/ut3_user/reporters/test_junit_reporter.pkb | 17 +++++++++++------ 3 files changed, 24 insertions(+), 7 deletions(-) diff --git a/test/ut3_user/reporters.pkb b/test/ut3_user/reporters.pkb index d33adce23..76d345a3d 100644 --- a/test/ut3_user/reporters.pkb +++ b/test/ut3_user/reporters.pkb @@ -38,6 +38,10 @@ as --%disabled(Disabled for testing purpose) procedure disabled_test; + --%test(a disabled test with no reason) + --%disabled + procedure disabled_test_no_reason; + --%aftereach procedure aftereach; @@ -100,6 +104,13 @@ as ut3_develop.ut.expect(1,'this should not execute').to_equal(1); end; + procedure disabled_test_no_reason + is + begin + dbms_output.put_line(''); + ut3_develop.ut.expect(1,'this should not execute').to_equal(1); + end; + procedure beforeall is begin dbms_output.put_line(''); diff --git a/test/ut3_user/reporters/test_documentation_reporter.pkb b/test/ut3_user/reporters/test_documentation_reporter.pkb index 4d44d2f63..a627d26b4 100644 --- a/test/ut3_user/reporters/test_documentation_reporter.pkb +++ b/test/ut3_user/reporters/test_documentation_reporter.pkb @@ -25,6 +25,7 @@ create or replace package body test_documentation_reporter as a disabled test [0 sec] (DISABLED - Disabled for testing purpose) + a disabled test with no reason [0 sec] (DISABLED) % Failures: @@ -40,7 +41,7 @@ Failures: ORA-06512: at "UT3$USER#.TEST_REPORTERS", line 44% ORA-06512: at line 6 Finished in % seconds -4 tests, 1 failed, 1 errored, 1 disabled, 0 warning(s)%]'; +5 tests, 1 failed, 1 errored, 2 disabled, 0 warning(s)%]'; begin select * diff --git a/test/ut3_user/reporters/test_junit_reporter.pkb b/test/ut3_user/reporters/test_junit_reporter.pkb index 24012f6bb..4a574591c 100644 --- a/test/ut3_user/reporters/test_junit_reporter.pkb +++ b/test/ut3_user/reporters/test_junit_reporter.pkb @@ -219,12 +219,12 @@ create or replace package body test_junit_reporter as l_results ut3_develop.ut_varchar2_list; l_actual clob; l_expected varchar2(32767):=q'[ - - - - - - + + + + + + % @@ -255,6 +255,11 @@ create or replace package body test_junit_reporter as + + + + + % From 9912dfac23a1d3d964e11ae7102fd30fecd4652c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 7 Feb 2022 22:42:10 +0200 Subject: [PATCH 248/887] Removing comment line that keeps getting updated with update_project_version action --- source/core/ut_utils.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 36db42f05..3675e834d 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -787,9 +787,9 @@ create or replace package body ut_utils is /** * Change string into unicode to match xmlgen format _00_ + * See the section of Oracle documentation called: Escape of Characters in Generated XML Data * https://docs.oracle.com/en/database/oracle/oracle-database/12.2/adxdb/generation-of-XML-data-from-relational-data.html#GUID-5BE09A7D-80D8-4734-B9AF-4A61F27FA9B2 - * secion v3.1.12.3796-develop - */ + */ function char_to_xmlgen_unicode(a_character varchar2) return varchar2 is begin return '_x00'||rawtohex(utl_raw.cast_to_raw(a_character))||'_'; From 2a0b2c96a308bb4dd13863a6ebba2b29694ff655 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 8 Feb 2022 00:14:14 +0200 Subject: [PATCH 249/887] Reorganizing install scripts to make the code-style chech, uninstall validate, create test users and reinstall steps explicit in deployment pipeline --- .github/scripts/create_test_users.sh | 115 +++++++++++++ .github/scripts/install.sh | 155 ------------------ .github/scripts/uninstall_validate_utplsql.sh | 32 ++++ .github/workflows/build.yml | 21 ++- development/install.sh | 4 + 5 files changed, 171 insertions(+), 156 deletions(-) create mode 100755 .github/scripts/create_test_users.sh create mode 100755 .github/scripts/uninstall_validate_utplsql.sh diff --git a/.github/scripts/create_test_users.sh b/.github/scripts/create_test_users.sh new file mode 100755 index 000000000..43f64784d --- /dev/null +++ b/.github/scripts/create_test_users.sh @@ -0,0 +1,115 @@ +#!/bin/bash + +set -ev +SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" +cd ${SCRIPT_DIR}/../../source + +time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL +set feedback off +whenever sqlerror exit failure rollback + +-------------------------------------------------------------------------------- +PROMPT Adding back create-trigger privilege to $UT3_DEVELOP_SCHEMA for testing +grant administer database trigger to $UT3_DEVELOP_SCHEMA; + +-------------------------------------------------------------------------------- +PROMPT Creating $UT3_TESTER - Power-user for testing internal framework code + +create user $UT3_TESTER identified by "$UT3_TESTER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; +grant create session, create procedure, create type, create table to $UT3_TESTER; + +grant execute on dbms_lock to $UT3_TESTER; + +PROMPT Granting $UT3_DEVELOP_SCHEMA code to $UT3_TESTER + +begin + for i in ( + select object_name from all_objects t + where t.object_type in ('PACKAGE','TYPE') + and owner = '$UT3_DEVELOP_SCHEMA' + and generated = 'N' + and object_name not like 'SYS%') + loop + execute immediate 'grant execute on $UT3_DEVELOP_SCHEMA."'||i.object_name||'" to $UT3_TESTER'; + end loop; +end; +/ + +PROMPT Granting $UT3_DEVELOP_SCHEMA tables to $UT3_TESTER + +begin + for i in ( select table_name from all_tables t where owner = '$UT3_DEVELOP_SCHEMA' and nested = 'NO' and iot_name is null) + loop + execute immediate 'grant select on $UT3_DEVELOP_SCHEMA.'||i.table_name||' to $UT3_TESTER'; + end loop; +end; +/ + + +-------------------------------------------------------------------------------- +PROMPT Creating $UT3_USER - minimal privileges user for API testing + +create user $UT3_USER identified by "$UT3_USER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; +grant create session, create procedure, create type, create table to $UT3_USER; + +PROMPT Grants for starting a debugging session from $UT3_USER +grant debug connect session to $UT3_USER; +grant debug any procedure to $UT3_USER; +begin + \$if dbms_db_version.version <= 11 \$then + null; -- no addition action necessary + \$else + -- necessary on 12c or higher + dbms_network_acl_admin.append_host_ace ( + host =>'*', + ace => sys.xs\$ace_type( + privilege_list => sys.xs\$name_list('JDWP') , + principal_name => '$UT3_USER', + principal_type => sys.xs_acl.ptype_db + ) + ); + \$end +end; +/ + +-------------------------------------------------------------------------------- +PROMPT Creating $UT3_TESTER_HELPER - provides functions to allow min grant test user setup tests. + +create user $UT3_TESTER_HELPER identified by "$UT3_TESTER_HELPER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; +grant create session, create procedure, create type, create table to $UT3_TESTER_HELPER; + +PROMPT Grants for testing distributed transactions +grant create public database link to $UT3_TESTER_HELPER; +grant drop public database link to $UT3_TESTER_HELPER; + +PROMPT Grants for testing coverage outside of main $UT3_DEVELOP_SCHEMA schema. +grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type, + select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table, + select any dictionary, create any synonym, drop any synonym, + grant any object privilege, grant any privilege, create public synonym, drop public synonym, create any trigger + to $UT3_TESTER_HELPER; + +grant create job to $UT3_TESTER_HELPER; + +PROMPT Additional grants for disabling DDL trigger and testing parser without trigger enabled/present + +grant alter any trigger to $UT3_TESTER_HELPER; +grant administer database trigger to $UT3_TESTER_HELPER; +grant execute on dbms_lock to $UT3_TESTER_HELPER; + +create user ut3_cache_test_owner identified by ut3; +grant create session, create procedure to ut3_cache_test_owner; + +create user ut3_no_extra_priv_user identified by ut3; +grant create session, create procedure to ut3_no_extra_priv_user; + +create user ut3_select_catalog_user identified by ut3; +grant create session, create procedure, select_catalog_role to ut3_select_catalog_user; + +create user ut3_select_any_table_user identified by ut3; +grant create session, create procedure, select any table to ut3_select_any_table_user; + +create user ut3_execute_any_proc_user identified by ut3; +grant create session, create procedure, execute any procedure to ut3_execute_any_proc_user; +exit +SQL diff --git a/.github/scripts/install.sh b/.github/scripts/install.sh index 095d33810..46750b89c 100755 --- a/.github/scripts/install.sh +++ b/.github/scripts/install.sh @@ -19,158 +19,3 @@ set verify off alter session set plsql_optimize_level=0; @${INSTALL_FILE} $UT3_DEVELOP_SCHEMA $UT3_DEVELOP_SCHEMA_PASSWORD SQL - -if [[ "${MATRIX_JOB_ID}" == 1 ]]; then - - #check code-style for errors - time "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @../development/utplsql_style_check.sql - - #test install/uninstall process - time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL - set feedback off - set verify off - whenever sqlerror exit failure rollback - - @uninstall_all.sql $UT3_DEVELOP_SCHEMA - whenever sqlerror exit failure rollback - declare - v_leftover_objects_count integer; - begin - select sum(cnt) - into v_leftover_objects_count - from ( - select count(1) cnt from dba_objects where owner = '$UT3_DEVELOP_SCHEMA' - where object_name not like 'PLSQL_PROFILER%' and object_name not like 'DBMSPCC_%' - union all - select count(1) cnt from dba_synonyms where table_owner = '$UT3_DEVELOP_SCHEMA' - where table_name not like 'PLSQL_PROFILER%' and table_name not like 'DBMSPCC_%' - ); - if v_leftover_objects_count > 0 then - raise_application_error(-20000, 'Not all objects were successfully uninstalled - leftover objects count='||v_leftover_objects_count); - end if; - end; - / -SQL - - time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL - set feedback off - set verify off - - alter session set plsql_optimize_level=0; - @install.sql $UT3_DEVELOP_SCHEMA - @install_ddl_trigger.sql $UT3_DEVELOP_SCHEMA - @create_synonyms_and_grants_for_public.sql $UT3_DEVELOP_SCHEMA -SQL - -fi - - -time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL -set feedback off -whenever sqlerror exit failure rollback - --------------------------------------------------------------------------------- -PROMPT Adding back create-trigger privilege to $UT3_DEVELOP_SCHEMA for testing -grant administer database trigger to $UT3_DEVELOP_SCHEMA; - --------------------------------------------------------------------------------- -PROMPT Creating $UT3_TESTER - Power-user for testing internal framework code - -create user $UT3_TESTER identified by "$UT3_TESTER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; -grant create session, create procedure, create type, create table to $UT3_TESTER; - -grant execute on dbms_lock to $UT3_TESTER; - -PROMPT Granting $UT3_DEVELOP_SCHEMA code to $UT3_TESTER - -begin - for i in ( - select object_name from all_objects t - where t.object_type in ('PACKAGE','TYPE') - and owner = '$UT3_DEVELOP_SCHEMA' - and generated = 'N' - and object_name not like 'SYS%') - loop - execute immediate 'grant execute on $UT3_DEVELOP_SCHEMA."'||i.object_name||'" to $UT3_TESTER'; - end loop; -end; -/ - -PROMPT Granting $UT3_DEVELOP_SCHEMA tables to $UT3_TESTER - -begin - for i in ( select table_name from all_tables t where owner = '$UT3_DEVELOP_SCHEMA' and nested = 'NO' and iot_name is null) - loop - execute immediate 'grant select on $UT3_DEVELOP_SCHEMA.'||i.table_name||' to $UT3_TESTER'; - end loop; -end; -/ - - --------------------------------------------------------------------------------- -PROMPT Creating $UT3_USER - minimal privileges user for API testing - -create user $UT3_USER identified by "$UT3_USER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; -grant create session, create procedure, create type, create table to $UT3_USER; - -PROMPT Grants for starting a debugging session from $UT3_USER -grant debug connect session to $UT3_USER; -grant debug any procedure to $UT3_USER; -begin - \$if dbms_db_version.version <= 11 \$then - null; -- no addition action necessary - \$else - -- necessary on 12c or higher - dbms_network_acl_admin.append_host_ace ( - host =>'*', - ace => sys.xs\$ace_type( - privilege_list => sys.xs\$name_list('JDWP') , - principal_name => '$UT3_USER', - principal_type => sys.xs_acl.ptype_db - ) - ); - \$end -end; -/ - --------------------------------------------------------------------------------- -PROMPT Creating $UT3_TESTER_HELPER - provides functions to allow min grant test user setup tests. - -create user $UT3_TESTER_HELPER identified by "$UT3_TESTER_HELPER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; -grant create session, create procedure, create type, create table to $UT3_TESTER_HELPER; - -PROMPT Grants for testing distributed transactions -grant create public database link to $UT3_TESTER_HELPER; -grant drop public database link to $UT3_TESTER_HELPER; - -PROMPT Grants for testing coverage outside of main $UT3_DEVELOP_SCHEMA schema. -grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type, - select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table, - select any dictionary, create any synonym, drop any synonym, - grant any object privilege, grant any privilege, create public synonym, drop public synonym, create any trigger - to $UT3_TESTER_HELPER; - -grant create job to $UT3_TESTER_HELPER; - -PROMPT Additional grants for disabling DDL trigger and testing parser without trigger enabled/present - -grant alter any trigger to $UT3_TESTER_HELPER; -grant administer database trigger to $UT3_TESTER_HELPER; -grant execute on dbms_lock to $UT3_TESTER_HELPER; - -create user ut3_cache_test_owner identified by ut3; -grant create session, create procedure to ut3_cache_test_owner; - -create user ut3_no_extra_priv_user identified by ut3; -grant create session, create procedure to ut3_no_extra_priv_user; - -create user ut3_select_catalog_user identified by ut3; -grant create session, create procedure, select_catalog_role to ut3_select_catalog_user; - -create user ut3_select_any_table_user identified by ut3; -grant create session, create procedure, select any table to ut3_select_any_table_user; - -create user ut3_execute_any_proc_user identified by ut3; -grant create session, create procedure, execute any procedure to ut3_execute_any_proc_user; -exit -SQL diff --git a/.github/scripts/uninstall_validate_utplsql.sh b/.github/scripts/uninstall_validate_utplsql.sh new file mode 100755 index 000000000..d8a34999a --- /dev/null +++ b/.github/scripts/uninstall_validate_utplsql.sh @@ -0,0 +1,32 @@ +#!/bin/bash + +set -ev +SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" +cd ${SCRIPT_DIR}/../../source + +time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL + set feedback off + set verify off + whenever sqlerror exit failure rollback + + @uninstall_all.sql $UT3_DEVELOP_SCHEMA + whenever sqlerror exit failure rollback + declare + v_leftover_objects_count integer; + begin + select sum(cnt) + into v_leftover_objects_count + from ( + select count(1) cnt from dba_objects where owner = '$UT3_DEVELOP_SCHEMA' + where object_name not like 'PLSQL_PROFILER%' and object_name not like 'DBMSPCC_%' + union all + select count(1) cnt from dba_synonyms where table_owner = '$UT3_DEVELOP_SCHEMA' + where table_name not like 'PLSQL_PROFILER%' and table_name not like 'DBMSPCC_%' + ); + if v_leftover_objects_count > 0 then + raise_application_error(-20000, 'Not all objects were successfully uninstalled - leftover objects count='||v_leftover_objects_count); + end if; + end; + / + drop user $UT3_DEVELOP_SCHEMA cascade; +SQL diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8f11522fd..11f2e1383 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -107,6 +107,25 @@ jobs: id: install-utplsql run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh + - name: Check code style + if: ${{ matrix.id == 1 }} + id: check-coding-style + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @development/utplsql_style_check.sql + + - name: Validate utPLSQL uninstall + if: ${{ matrix.id == 1 }} + id: validate-uninstall + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/uninstall_validate_utplsql.sh + + - name: Reinstall utPLSQL + if: ${{ matrix.id == 1 }} + id: reinstall-utplsql + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh + + - name: Create test users + id: create-test-users + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/create_test_users.sh + - name: Install utPLSQL release id: install-utplsql-release run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install_utplsql_release.sh @@ -143,7 +162,7 @@ jobs: - name: SonarCloud Scan id: sonar - if: ${{ matrix.db_version_name == '21xe' }} + if: ${{ matrix.db_version_name == '21XE' }} uses: SonarSource/sonarcloud-github-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any diff --git a/development/install.sh b/development/install.sh index 627bd113d..f3a62b0ec 100755 --- a/development/install.sh +++ b/development/install.sh @@ -14,6 +14,10 @@ if ! .github/scripts/install.sh; then echo -e ${header}"\nFailed to install utPLSQL from current branch into ${UT3_DEVELOP_SCHEMA} schema\n"${header} exit 1 fi +if ! .github/scripts/create_test_users.sh; then + echo -e ${header}"\nFailed to create test users from current branch\n"${header} + exit 1 +fi if ! .github/scripts/install_utplsql_release.sh; then echo -e ${header}"\nFailed to install utPLSQL from branch ${SELFTESTING_BRANCH} into ${UT3_RELEASE_VERSION_SCHEMA}\n"${header} exit 1 From 07fcf3582fcbce236112cfc1dae44ea7da4ccbb3 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 8 Feb 2022 00:59:41 +0200 Subject: [PATCH 250/887] Adding and testing diagnostics steps --- .github/workflows/build.yml | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 11f2e1383..e6b07e114 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -59,10 +59,11 @@ jobs: image: ${{matrix.oracle-version}} env: ORACLE_PASSWORD: oracle - MATRIX_JOB_ID: ${{matrix.id}} credentials: username: ${{ secrets.DOCKER_USER }} password: ${{ secrets.DOCKER_PASSWORD }} + volumes: + - ${{github.workspace}}:/utPLSQL ports: - 1521:1521 options: >- @@ -70,6 +71,7 @@ jobs: --health-interval 10s --health-timeout 5s --health-retries 10 + --name oracle steps: - uses: actions/checkout@v2 @@ -142,6 +144,20 @@ jobs: id: run-tests run: bash test/run_tests.sh +#Needed to diagnose occasional failures of DB on test runs + - name: Get ORACLE_BASE/diag data + id: get-oracle-diag-data + if: ${{ always() && steps.run-tests.outcome == 'failure' }} + run: docker exec oracle bash -c "cp -r ${ORACLE_BASE}/diag /utPLSQL/database-diag" +#Needed to diagnose occasional failures of DB on test runs + - name: Upload ORACLE_BASE/diag data Artifact + id: upload + if: ${{ always() && steps.run-tests.outcome == 'failure' }} + uses: actions/upload-artifact@v2 + with: + name: my-artifact$-${{matrix.db_version_name}} + path: ${{github.workspace}}/database-diag + - name: Validate utPLSQL reports format id: validate-reports-format run: bash .github/scripts/validate_report_files.sh From 75ca38eef0d07a1976d786873b846fef61915395 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 8 Feb 2022 01:38:18 +0200 Subject: [PATCH 251/887] Fixing check of code style --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e6b07e114..eb853b652 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -112,7 +112,7 @@ jobs: - name: Check code style if: ${{ matrix.id == 1 }} id: check-coding-style - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @development/utplsql_style_check.sql + run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint "$SQLCLI" ${DOCKER_ENV} ${ORACLE_VERSION} $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @development/utplsql_style_check.sql - name: Validate utPLSQL uninstall if: ${{ matrix.id == 1 }} From cb26d102a21a5cdd69e858251f36e0b94d232d1d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 8 Feb 2022 01:42:42 +0200 Subject: [PATCH 252/887] Fixing gathering of diag data --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index eb853b652..efa4fe403 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -148,7 +148,7 @@ jobs: - name: Get ORACLE_BASE/diag data id: get-oracle-diag-data if: ${{ always() && steps.run-tests.outcome == 'failure' }} - run: docker exec oracle bash -c "cp -r ${ORACLE_BASE}/diag /utPLSQL/database-diag" + run: docker exec oracle bash -c "cp -r /opt/oracle/diag /utPLSQL/database-diag" #Needed to diagnose occasional failures of DB on test runs - name: Upload ORACLE_BASE/diag data Artifact id: upload From 610067fc74710f308b2dc22d5235d664013588fe Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 8 Feb 2022 03:09:04 +0200 Subject: [PATCH 253/887] Fixing gathering of diag data Fixing uninstall validation --- .github/scripts/uninstall_validate_utplsql.sh | 4 ++++ .github/workflows/build.yml | 10 ++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.github/scripts/uninstall_validate_utplsql.sh b/.github/scripts/uninstall_validate_utplsql.sh index d8a34999a..ee3fd3f40 100755 --- a/.github/scripts/uninstall_validate_utplsql.sh +++ b/.github/scripts/uninstall_validate_utplsql.sh @@ -10,6 +10,10 @@ time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL whenever sqlerror exit failure rollback @uninstall_all.sql $UT3_DEVELOP_SCHEMA +SQL +time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL + set feedback off + set verify off whenever sqlerror exit failure rollback declare v_leftover_objects_count integer; diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index efa4fe403..66a3a64b7 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -144,12 +144,17 @@ jobs: id: run-tests run: bash test/run_tests.sh -#Needed to diagnose occasional failures of DB on test runs +#Start Needed to diagnose occasional failures of DB on test runs + - name: Prepare diagnostic directory + id: preapre-oracle-diag-dir + if: ${{ always() && steps.run-tests.outcome == 'failure' }} + run: | + mkdir database-diag + chmod +777 database-diag - name: Get ORACLE_BASE/diag data id: get-oracle-diag-data if: ${{ always() && steps.run-tests.outcome == 'failure' }} run: docker exec oracle bash -c "cp -r /opt/oracle/diag /utPLSQL/database-diag" -#Needed to diagnose occasional failures of DB on test runs - name: Upload ORACLE_BASE/diag data Artifact id: upload if: ${{ always() && steps.run-tests.outcome == 'failure' }} @@ -157,6 +162,7 @@ jobs: with: name: my-artifact$-${{matrix.db_version_name}} path: ${{github.workspace}}/database-diag +#End Needed to diagnose occasional failures of DB on test runs - name: Validate utPLSQL reports format id: validate-reports-format From 14d61bcf80b6d4d01bf18365825c209902b04188 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 8 Feb 2022 03:21:17 +0200 Subject: [PATCH 254/887] Fixing uninstall validation --- .github/scripts/uninstall_validate_utplsql.sh | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/scripts/uninstall_validate_utplsql.sh b/.github/scripts/uninstall_validate_utplsql.sh index ee3fd3f40..2863e1fe2 100755 --- a/.github/scripts/uninstall_validate_utplsql.sh +++ b/.github/scripts/uninstall_validate_utplsql.sh @@ -21,11 +21,13 @@ time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL select sum(cnt) into v_leftover_objects_count from ( - select count(1) cnt from dba_objects where owner = '$UT3_DEVELOP_SCHEMA' - where object_name not like 'PLSQL_PROFILER%' and object_name not like 'DBMSPCC_%' + select count(1) cnt from dba_objects + where owner = '$UT3_DEVELOP_SCHEMA' + and object_name not like 'PLSQL_PROFILER%' and object_name not like 'DBMSPCC_%' union all - select count(1) cnt from dba_synonyms where table_owner = '$UT3_DEVELOP_SCHEMA' - where table_name not like 'PLSQL_PROFILER%' and table_name not like 'DBMSPCC_%' + select count(1) cnt from dba_synonyms + where table_owner = '$UT3_DEVELOP_SCHEMA' + and table_name not like 'PLSQL_PROFILER%' and table_name not like 'DBMSPCC_%' ); if v_leftover_objects_count > 0 then raise_application_error(-20000, 'Not all objects were successfully uninstalled - leftover objects count='||v_leftover_objects_count); From 7b71d0237800f4912882daff5a6db414e65a5ad1 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 8 Feb 2022 03:25:00 +0200 Subject: [PATCH 255/887] Fixing oracle diag --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 66a3a64b7..03e06f2f9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -154,7 +154,7 @@ jobs: - name: Get ORACLE_BASE/diag data id: get-oracle-diag-data if: ${{ always() && steps.run-tests.outcome == 'failure' }} - run: docker exec oracle bash -c "cp -r /opt/oracle/diag /utPLSQL/database-diag" + run: docker exec oracle bash -c "chmod -R +777 /opt/oracle/diag && cp -r /opt/oracle/diag /utPLSQL/database-diag" - name: Upload ORACLE_BASE/diag data Artifact id: upload if: ${{ always() && steps.run-tests.outcome == 'failure' }} From 82ac7f4e0f2b6e23fd28b5484ac390b25aaead42 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 8 Feb 2022 08:40:49 +0000 Subject: [PATCH 256/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 20a49b3bc..3c63cb962 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 27b93a7d2..4fa5004bb 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 9a0ff9234..a33f67842 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 606a59eb0..3ad731d81 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 697f2e525..b1eb78458 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 98df0e6f3..67f922c58 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8b0924d25..54551e0df 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 9f74d801f..aff07ac72 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 08e2ccd1e..8951b3621 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index c70fac545..0e4da487d 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 90f3a3798..7f396910a 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 220f650cd..35406ddc9 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 3503d645a..469ea1071 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c96aed1ac..aa22452ae 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 8e8786f6b..c8c02daf5 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 649337d63..c231955af 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 707de2e7e..403e1eedd 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3796--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c8b434592..907aa7ccc 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3796-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3843-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From c762920238473c1792fa1163e6e5f25724c89021 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 8 Feb 2022 10:06:14 +0000 Subject: [PATCH 257/887] Update sonar --- source/reporters/ut_sonar_test_reporter.tpb | 2 +- test/ut3_user/reporters/test_sonar_test_reporter.pkb | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/source/reporters/ut_sonar_test_reporter.tpb b/source/reporters/ut_sonar_test_reporter.tpb index 8b043832a..20624fae9 100644 --- a/source/reporters/ut_sonar_test_reporter.tpb +++ b/source/reporters/ut_sonar_test_reporter.tpb @@ -47,7 +47,7 @@ create or replace type body ut_sonar_test_reporter is begin ut_utils.append_to_list( l_results, ''); if a_test.result = ut_utils.gc_disabled then - ut_utils.append_to_list( l_results, ''); + ut_utils.append_to_list( l_results, ''); elsif a_test.result = ut_utils.gc_error then ut_utils.append_to_list( l_results, ''); ut_utils.append_to_list( l_results, ut_utils.to_cdata( ut_utils.convert_collection( a_test.get_error_stack_traces() ) ) ); diff --git a/test/ut3_user/reporters/test_sonar_test_reporter.pkb b/test/ut3_user/reporters/test_sonar_test_reporter.pkb index 5821b2071..7c30fd91d 100644 --- a/test/ut3_user/reporters/test_sonar_test_reporter.pkb +++ b/test/ut3_user/reporters/test_sonar_test_reporter.pkb @@ -9,7 +9,8 @@ create or replace package body test_sonar_test_reporter as % %%% %%% -%% +%% +%% ]'; From 8c91c7b784fac9cf1a9c0010e5bbb5ba31fe88ef Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 8 Feb 2022 13:02:53 +0000 Subject: [PATCH 258/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 3c63cb962..16f90c86e 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 4fa5004bb..357f2db99 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index a33f67842..96b4a1125 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 3ad731d81..72279191f 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b1eb78458..b6088eceb 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 67f922c58..cd616bde0 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 99a8c0a37..e778b8d8c 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index aff07ac72..95591d7ef 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 8951b3621..89a17d5ef 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 0e4da487d..97209655a 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 7f396910a..ea4b37e3d 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 35406ddc9..83e06cf8a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 469ea1071..2a09222be 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index aa22452ae..9bceca36a 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index c8c02daf5..bc18b0035 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c231955af..20cecb601 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 403e1eedd..25252df0a 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3843--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 907aa7ccc..a2a3528ca 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3843-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3846-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 9010fcb18451c7af7882078ff80d382d1005f16d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 9 Feb 2022 00:31:40 +0200 Subject: [PATCH 259/887] Fixing gaps in uninstall process. --- .github/scripts/uninstall_validate_utplsql.sh | 17 ++++++++++++++++- source/expectations/json_objects_specs.sql | 14 ++++---------- source/uninstall_objects.sql | 15 ++++++++++++--- 3 files changed, 32 insertions(+), 14 deletions(-) diff --git a/.github/scripts/uninstall_validate_utplsql.sh b/.github/scripts/uninstall_validate_utplsql.sh index 2863e1fe2..d0a2070a8 100755 --- a/.github/scripts/uninstall_validate_utplsql.sh +++ b/.github/scripts/uninstall_validate_utplsql.sh @@ -15,6 +15,21 @@ time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL set feedback off set verify off whenever sqlerror exit failure rollback + set serverout on + begin + for i in ( + select o.object_type||' '||o.owner||'.'||o.object_name as obj + from dba_objects o + where owner = '$UT3_DEVELOP_SCHEMA' + union all + select 'SYNONYM '||s.owner||'.'||s.synonym_name||' FOR '||s.table_owner||'.'||s.table_name as obj + from dba_synonyms s + where table_owner = '$UT3_DEVELOP_SCHEMA' + ) loop + dbms_output.put_line(i.obj); + end loop; + end; + / declare v_leftover_objects_count integer; begin @@ -34,5 +49,5 @@ time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL end if; end; / - drop user $UT3_DEVELOP_SCHEMA cascade; + drop user $UT3_DEVELOP_SCHEMA; SQL diff --git a/source/expectations/json_objects_specs.sql b/source/expectations/json_objects_specs.sql index 39c2c4e23..a5d936afb 100644 --- a/source/expectations/json_objects_specs.sql +++ b/source/expectations/json_objects_specs.sql @@ -1,18 +1,12 @@ BEGIN - - $if dbms_db_version.version >= 21 $then - dbms_output.put_line('Object exists , dont install'); - $elsif dbms_db_version.version = 12 and dbms_db_version.release >= 2 or ( dbms_db_version.version > 12 and dbms_db_version.version < 21 ) $then - dbms_output.put_line('Installing json structures specs for native json.'); - execute immediate q'[create or replace TYPE JSON FORCE AUTHID CURRENT_USER AS OBJECT( - dummyobjt NUMBER -) NOT FINAL NOT INSTANTIABLE;]'; - $else + null; + $if dbms_db_version.version < 21 $then dbms_output.put_line('Installing json structures specs for native json.'); execute immediate q'[create or replace TYPE JSON FORCE AUTHID CURRENT_USER AS OBJECT( dummyobjt NUMBER ) NOT FINAL NOT INSTANTIABLE;]'; - + $end + $if dbms_db_version.version = 12 and dbms_db_version.release = 1 or dbms_db_version.version < 12 $then dbms_output.put_line('Installing json structures specs.'); execute immediate q'[create or replace TYPE JSON_Element_T FORCE AUTHID CURRENT_USER AS OBJECT( dummyobjt NUMBER, diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index bc41cb63a..4d77d9993 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -156,6 +156,10 @@ drop type ut_comparison_matcher force; drop type ut_matcher force; +drop type ut_expectation_base force; + +drop type ut_matcher_base force; + drop type ut_data_value_yminterval force; drop type ut_data_value_varchar2 force; @@ -245,10 +249,15 @@ drop package ut_metadata; drop package ut_ansiconsole_helper; begin + null; + $if dbms_db_version.version < 21 $then + begin execute immediate 'drop type json force'; exception when others then null; end; + $end $if dbms_db_version.version = 12 and dbms_db_version.release = 1 or dbms_db_version.version < 12 $then - execute immediate 'drop type json_element_t force'; - $else - dbms_output.put_line('Nothing to drop'); + begin execute immediate 'drop type json_element_t force'; exception when others then null; end; + begin execute immediate 'drop type json_object_t force'; exception when others then null; end; + begin execute immediate 'drop type json_array_t force'; exception when others then null; end; + begin execute immediate 'drop type json_key_list force'; exception when others then null; end; $end end; / From 54af5faea9f12c3ec622f01c151796c5ef8a9fd5 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 9 Feb 2022 00:36:28 +0200 Subject: [PATCH 260/887] Fixes and improvements to uninstall doc --- docs/userguide/install.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 3503d645a..601b3ca08 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -184,10 +184,9 @@ If the installing user and utPLSQL owner is one and the same, the user must have - ALTER SESSION - CREATE TRIGGER -In addition the user must be granted the execute privilege on `DBMS_LOCK` and `DBMS_CRYPTO` packages. +In addition, the user must be granted the execute privilege on `DBMS_LOCK` and `DBMS_CRYPTO` packages. utPLSQL is using [DBMS_PROFILER tables](https://docs.oracle.com/cd/E18283_01/appdev.112/e16760/d_profil.htm#i999476) for code coverage. The tables required by DBMS_PROFILER will be created in the installation schema unless they already exist. -The uninstall process will **not** drop profiler tables, as they can potentially be shared and reused for profiling PLSQL code. It is up to DBA to maintain the storage of the profiler tables. @@ -297,7 +296,7 @@ cd source sqlplus admin/admins_password@database @uninstall.sql ut3 ``` -The uninstall script will remove all the objects installed by the install script. +The uninstall script will remove all the objects installed by the installation script. Additionally, all the public and private synonyms pointing to the objects in the utPLSQL schema will be removed. If you have extended any utPLSQL types such as a custom reporter, these will need to be dropped before the uninstall, otherwise the uninstall script might fail. @@ -305,7 +304,7 @@ If you have extended any utPLSQL types such as a custom reporter, these will nee The uninstall script does not drop the schema. **In order for the uninstall to be successful, you need to use the uninstall script that was provided with the exact utPLSQL version installed on your database.** -i.e. the uninstall script provided with version 3.0.1 will probably not work if you want to remove version 3.0.0 from your database. +i.e. the uninstall script provided with version 3.1.11 will not work correctly if you want to remove version 3.0.0 from your database. Alternatively you can drop the user that owns utPLSQL and re-create it using headless install. From d999d31266fd62b54705eb8cb340c4442b09b911 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 9 Feb 2022 00:37:17 +0200 Subject: [PATCH 261/887] Revert "Testing reporting of failing tests in branch and PR builds." This reverts commit 449bb708c6584a2d4f682366e9a1546380e13961. --- test/ut3_user/expectations.pkb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/test/ut3_user/expectations.pkb b/test/ut3_user/expectations.pkb index b4dfe5b41..30af48a44 100644 --- a/test/ut3_user/expectations.pkb +++ b/test/ut3_user/expectations.pkb @@ -28,8 +28,7 @@ SUCCESS Actual: 0 (number) was expected to equal: 0 (number) ]'; - --deliberate change to make a test fail - ut.expect(l_actual).not_to_be_like(l_expected); + ut.expect(l_actual).to_be_like(l_expected); rollback; end; From cb64865fd7c9399557173fc36e97a30ce5a92d85 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 9 Feb 2022 01:04:01 +0200 Subject: [PATCH 262/887] Fixing oracle-diag dir --- .github/workflows/build.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 03e06f2f9..dbac6b4fe 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,6 +31,7 @@ jobs: db_version_name: '11XE' oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:11-full" + oracle-base: '/u01/app/oracle' # TODO - need to add healthcheck.sh into our containers # - id: 2 # db_version_name: '12.1EE' @@ -45,6 +46,7 @@ jobs: db_version_name: '18XE' oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:18-slim" + oracle-base: '/opt/oracle' # - id: 5 # db_version_name: '19se' # oracle-sid: 'ORCLCDB' @@ -53,6 +55,7 @@ jobs: db_version_name: '21XE' oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:21-slim" + oracle-base: '/opt/oracle' services: oracle: @@ -154,7 +157,7 @@ jobs: - name: Get ORACLE_BASE/diag data id: get-oracle-diag-data if: ${{ always() && steps.run-tests.outcome == 'failure' }} - run: docker exec oracle bash -c "chmod -R +777 /opt/oracle/diag && cp -r /opt/oracle/diag /utPLSQL/database-diag" + run: docker exec oracle bash -c "chmod -R +777 ${{matrix.oracle-base}}/diag && cp -r ${{matrix.oracle-base}}/diag /utPLSQL/database-diag" - name: Upload ORACLE_BASE/diag data Artifact id: upload if: ${{ always() && steps.run-tests.outcome == 'failure' }} From 8761ff59f0f24f550f1c8bd7553fdfb2f9901088 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 9 Feb 2022 01:31:28 +0200 Subject: [PATCH 263/887] Adding 12.1EE again --- .github/workflows/build.yml | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index dbac6b4fe..e31c6f198 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -32,25 +32,27 @@ jobs: oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:11-full" oracle-base: '/u01/app/oracle' -# TODO - need to add healthcheck.sh into our containers -# - id: 2 -# db_version_name: '12.1EE' -# oracle-sid: 'ORCLCDB' -# oracle-version: "utplsqlv3/oracledb:12c-r1-ee-small" -# - oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" -# oracle-sid: 'ORCLCDB' -# connection-str: '127.0.0.1:1521/ORCLCDB' -# id: 3 + - id: 2 + db_version_name: '12.1EE' + oracle-sid: 'ORCLCDB' + oracle-version: "utplsqlv3/oracledb:12c-r1-ee-small" + oracle-base: '/opt/oracle' +# - id: 3 # db_version_name: '12.2se' +# oracle-sid: 'ORCLCDB' +# oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" +# oracle-base: '/opt/oracle' - id: 4 db_version_name: '18XE' oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:18-slim" oracle-base: '/opt/oracle' +# TODO - need to add healthcheck.sh into our containers # - id: 5 # db_version_name: '19se' # oracle-sid: 'ORCLCDB' # oracle-version: "utplsqlv3/oracledb:19c-se2-small" +# oracle-base: '/opt/oracle' - id: 6 db_version_name: '21XE' oracle-sid: 'XE' From 5fe9a0e21e04af84fd48d7e29a59447b453b7434 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 9 Feb 2022 15:08:53 +0200 Subject: [PATCH 264/887] Testing without explicit call to ``--health-cmd healthcheck.sh` --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e31c6f198..0c9789173 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -72,11 +72,11 @@ jobs: ports: - 1521:1521 options: >- - --health-cmd healthcheck.sh --health-interval 10s --health-timeout 5s --health-retries 10 --name oracle +# --health-cmd healthcheck.sh steps: - uses: actions/checkout@v2 From 0c57a9cbb495d7d152e60068b28d21926b1ba7af Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 9 Feb 2022 21:03:44 +0000 Subject: [PATCH 265/887] Initial checkin for exclude objects regex. --- docs/userguide/coverage.md | 11 +- source/api/ut.pkb | 175 ++++++++++++++++++---- source/api/ut.pks | 72 +++++++-- source/api/ut_runner.pkb | 14 +- source/api/ut_runner.pks | 6 +- source/core/coverage/ut_coverage.pkb | 33 +++- source/core/types/ut_coverage_options.tpb | 13 +- source/core/types/ut_coverage_options.tps | 10 +- 8 files changed, 278 insertions(+), 56 deletions(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 8951b3621..59baf5a04 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -128,16 +128,19 @@ exec ut.run('unit_test_schema', ut_coverage_html_reporter(), a_coverage_schemes #### Filtering objects in coverage reports -There are two options that can be used to narrow down the scope of coverage report: -- `a_include_objects` - list of `[object_owner.].object_name` to be included in the coverage report +There are six options that can be used to narrow down the scope of coverage report: +- `a_include_objects` - list of `[object_owner.].object_name` to be included in the coverage report. - `a_exclude_objects` - list of `[object_owner.].object_name` to be excluded from the coverage report +- `a_include_schema_expr` - string of regex expression of schemas to be included in the coverage report. It will override `a_include_objects` +- `a_include_object_expr` - string of regex expression of objects ( no schema names included ) to be included in the coverage report. It will override `a_include_objects` +- `a_exclude_schema_expr` - string of regex expression of schemas to be excluded from the coverage report. It will override `a_exclude_objects` +- `a_exclude_object_expr` - string of regex expression of objects to be excluded from the coverage report. It will override `a_exclude_objects` -You may specify both _include_ and _exclude_ object lists to gain more control over what needs to be included / excluded from the coverage report. +You may specify both _include_ and _exclude_ options to gain more control over what needs to be included / excluded from the coverage report. The object owner is optional in the object list. If you do not provide an object owner, the _include_/_exclude_ list will be considered for every schema used for coverage gathering (as described above). - Example: Limiting coverage by object name, for tested code located in the same schema as the unit tests. ```sql exec ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_include_objects=>ut_varchar2_list('award_bonus')); diff --git a/source/api/ut.pkb b/source/api/ut.pkb index ee3d85342..5c91e54d4 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -131,7 +131,11 @@ create or replace package body ut is a_client_character_set varchar2, a_random_test_order integer, a_random_test_order_seed positive, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) is pragma autonomous_transaction; begin @@ -150,7 +154,11 @@ create or replace package body ut is false, ut_utils.int_to_boolean(a_random_test_order), a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); rollback; end; @@ -167,10 +175,15 @@ create or replace package body ut is a_client_character_set varchar2, a_random_test_order integer, a_random_test_order_seed positive, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) is pragma autonomous_transaction; begin + a_reporter := coalesce(a_reporter,ut_documentation_reporter()); ut_runner.run( a_paths, @@ -186,7 +199,11 @@ create or replace package body ut is false, ut_utils.int_to_boolean(a_random_test_order), a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); rollback; end; @@ -227,7 +244,11 @@ create or replace package body ut is a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -244,7 +265,11 @@ create or replace package body ut is a_client_character_set, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -266,7 +291,11 @@ create or replace package body ut is a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -283,7 +312,11 @@ create or replace package body ut is a_client_character_set, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -306,7 +339,11 @@ create or replace package body ut is a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -323,7 +360,11 @@ create or replace package body ut is a_client_character_set, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -346,7 +387,11 @@ create or replace package body ut is a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -363,7 +408,11 @@ create or replace package body ut is a_client_character_set, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -386,7 +435,11 @@ create or replace package body ut is a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -403,7 +456,11 @@ create or replace package body ut is a_client_character_set, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -426,7 +483,11 @@ create or replace package body ut is a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -443,7 +504,11 @@ create or replace package body ut is a_client_character_set, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -467,7 +532,11 @@ create or replace package body ut is a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) is l_reporter ut_reporter_base := a_reporter; begin @@ -487,7 +556,11 @@ create or replace package body ut is a_force_manual_rollback, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); else run_autonomous( @@ -502,7 +575,11 @@ create or replace package body ut is a_client_character_set, ut_utils.boolean_to_int(a_random_test_order), a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); end if; if l_reporter is of (ut_output_reporter_base) then @@ -524,7 +601,11 @@ create or replace package body ut is a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) is l_reporter ut_reporter_base := a_reporter; begin @@ -541,7 +622,11 @@ create or replace package body ut is a_force_manual_rollback, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); end; @@ -557,7 +642,11 @@ create or replace package body ut is a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) is begin ut.run( @@ -573,7 +662,11 @@ create or replace package body ut is a_force_manual_rollback, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); end; @@ -589,7 +682,11 @@ create or replace package body ut is a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) is begin ut.run( @@ -605,7 +702,11 @@ create or replace package body ut is a_force_manual_rollback, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); end; @@ -622,7 +723,11 @@ create or replace package body ut is a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) is begin ut.run( @@ -638,7 +743,11 @@ create or replace package body ut is a_force_manual_rollback, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); end; @@ -655,7 +764,11 @@ create or replace package body ut is a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) is begin ut.run( @@ -671,7 +784,11 @@ create or replace package body ut is a_force_manual_rollback, a_random_test_order, a_random_test_order_seed, - a_tags + a_tags, + a_include_schema_expr, + a_include_object_expr, + a_exclude_schema_expr, + a_exclude_object_expr ); end; diff --git a/source/api/ut.pks b/source/api/ut.pks index df5a8d8e5..f72c82a0c 100644 --- a/source/api/ut.pks +++ b/source/api/ut.pks @@ -62,7 +62,11 @@ create or replace package ut authid current_user as a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined; function run( @@ -76,7 +80,11 @@ create or replace package ut authid current_user as a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined; function run( @@ -91,7 +99,11 @@ create or replace package ut authid current_user as a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined; function run( @@ -106,7 +118,11 @@ create or replace package ut authid current_user as a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined; function run( @@ -121,7 +137,11 @@ create or replace package ut authid current_user as a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined; function run( @@ -136,7 +156,11 @@ create or replace package ut authid current_user as a_client_character_set varchar2 := null, a_random_test_order integer := 0, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) return ut_varchar2_rows pipelined; procedure run( @@ -151,7 +175,11 @@ create or replace package ut authid current_user as a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ); procedure run( @@ -166,7 +194,11 @@ create or replace package ut authid current_user as a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ); procedure run( @@ -182,7 +214,11 @@ create or replace package ut authid current_user as a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ); procedure run( @@ -198,7 +234,11 @@ create or replace package ut authid current_user as a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ); procedure run( @@ -214,7 +254,11 @@ create or replace package ut authid current_user as a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ); procedure run( @@ -230,7 +274,11 @@ create or replace package ut authid current_user as a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ); /** diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index d2bd74b91..af168fe5d 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -69,7 +69,11 @@ create or replace package body ut_runner is a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ) is l_run ut_run; l_coverage_schema_names ut_varchar2_rows; @@ -120,7 +124,6 @@ create or replace package body ut_runner is ut_utils.trim_list_elements(ut_utils.filter_list(ut_utils.string_to_table(a_tags,','),ut_utils.gc_word_no_space)) ); end if; - l_run := ut_run( a_run_paths => l_paths, a_coverage_options => ut_coverage_options( @@ -128,7 +131,11 @@ create or replace package body ut_runner is schema_names => l_coverage_schema_names, exclude_objects => ut_utils.convert_collection(a_exclude_objects), include_objects => ut_utils.convert_collection(a_include_objects), - file_mappings => set(a_source_file_mappings) + file_mappings => set(a_source_file_mappings), + include_schema_expr => a_include_schema_expr, + include_object_expr => a_include_object_expr, + exclude_schema_expr => a_exclude_schema_expr, + exclude_object_expr => a_exclude_object_expr ), a_test_file_mappings => set(a_test_file_mappings), a_client_character_set => a_client_character_set, @@ -142,7 +149,6 @@ create or replace package body ut_runner is end if; l_run.do_execute(); - finish_run(l_run, a_force_manual_rollback); exception when others then diff --git a/source/api/ut_runner.pks b/source/api/ut_runner.pks index 75aa12f8f..3170dedee 100644 --- a/source/api/ut_runner.pks +++ b/source/api/ut_runner.pks @@ -71,7 +71,11 @@ create or replace package ut_runner authid current_user is a_force_manual_rollback boolean := false, a_random_test_order boolean := false, a_random_test_order_seed positive := null, - a_tags varchar2 := null + a_tags varchar2 := null, + a_include_schema_expr varchar2 := null, + a_include_object_expr varchar2 := null, + a_exclude_schema_expr varchar2 := null, + a_exclude_object_expr varchar2 := null ); /** diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index ddcdeaf2e..b3667bb26 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -30,11 +30,12 @@ create or replace package body ut_coverage is end; function get_cov_sources_sql(a_coverage_options ut_coverage_options, a_skip_objects ut_object_names) return varchar2 is - l_result varchar2(32767); + l_result varchar2(32767); --QUESTION: Given fact that we can pass large regex filters same as objects filter should we consider a clob ? l_full_name varchar2(32767); l_join_mappings varchar2(32767); l_filters varchar2(32767); l_mappings_cardinality integer := 0; + l_regex_exc_filters varchar2(32767); begin l_result := q'[ with @@ -82,8 +83,9 @@ create or replace package body ut_coverage is -- Exclude calls to utPLSQL framework, Unit Test packages and objects from a_exclude_list parameter of coverage reporter where (s.owner, s.name) not in ( select /*+ cardinality(el {skipped_objects_cardinality})*/el.owner, el.name from table(:l_skipped_objects) el ) and line > 0 + {regex_filters} ]'; - + if a_coverage_options.file_mappings is not empty then l_mappings_cardinality := ut_utils.scale_cardinality(cardinality(a_coverage_options.file_mappings)); l_full_name := 'f.file_name'; @@ -92,6 +94,15 @@ create or replace package body ut_coverage is on s.name = f.object_name and s.type = f.object_type and s.owner = f.object_owner'; + elsif a_coverage_options.include_schema_expr is not null or a_coverage_options.include_object_expr is not null then + l_full_name := q'[lower(s.type||' '||s.owner||'.'||s.name)]'; + if a_coverage_options.include_schema_expr is not null then + l_filters := q'[and regexp_like(s.owner,']'||a_coverage_options.include_schema_expr||q'[','i')]'; + end if; + + if a_coverage_options.include_object_expr is not null then + l_filters := l_filters|| q'[ and regexp_like(s.name,']'||a_coverage_options.include_object_expr||q'[','i')]'; + end if; else l_full_name := q'[lower(s.type||' '||s.owner||'.'||s.name)]'; l_filters := case @@ -109,13 +120,27 @@ create or replace package body ut_coverage is end; end if; + + if a_coverage_options.exclude_schema_expr is not null then + l_regex_exc_filters := l_regex_exc_filters||q'[and not regexp_like(s.owner,']'||a_coverage_options.exclude_schema_expr||q'[,'i') + ]'; + end if; + + if a_coverage_options.exclude_object_expr is not null then + l_regex_exc_filters := l_regex_exc_filters||q'[and not regexp_like(s.name,']'||a_coverage_options.exclude_object_expr||q'[,'i') + ]'; + end if; + + + l_result := replace(l_result, '{sources_view}', ut_metadata.get_source_view_name()); l_result := replace(l_result, '{l_full_name}', l_full_name); l_result := replace(l_result, '{join_file_mappings}', l_join_mappings); l_result := replace(l_result, '{filters}', l_filters); l_result := replace(l_result, '{mappings_cardinality}', l_mappings_cardinality); l_result := replace(l_result, '{skipped_objects_cardinality}', ut_utils.scale_cardinality(cardinality(a_skip_objects))); - + l_result := replace(l_result, '{regex_filters}', l_regex_exc_filters); + return l_result; end; @@ -138,6 +163,8 @@ create or replace package body ut_coverage is open l_cursor for l_sql using a_coverage_options.file_mappings, l_skip_objects; elsif a_coverage_options.include_objects is not empty then open l_cursor for l_sql using a_coverage_options.include_objects, a_coverage_options.include_objects, l_skip_objects; + elsif a_coverage_options.include_schema_expr is not null or a_coverage_options.include_object_expr is not null then + open l_cursor for l_sql using l_skip_objects; else open l_cursor for l_sql using a_coverage_options.schema_names, a_coverage_options.schema_names, l_skip_objects; end if; diff --git a/source/core/types/ut_coverage_options.tpb b/source/core/types/ut_coverage_options.tpb index 308c75553..a091802af 100644 --- a/source/core/types/ut_coverage_options.tpb +++ b/source/core/types/ut_coverage_options.tpb @@ -22,7 +22,11 @@ create or replace type body ut_coverage_options as schema_names ut_varchar2_rows := null, exclude_objects ut_varchar2_rows := null, include_objects ut_varchar2_rows := null, - file_mappings ut_file_mappings := null + file_mappings ut_file_mappings := null, + include_schema_expr varchar2 := null, + include_object_expr varchar2 := null, + exclude_schema_expr varchar2 := null, + exclude_object_expr varchar2 := null ) return self as result is function to_ut_object_list(a_names ut_varchar2_rows, a_schema_names ut_varchar2_rows) return ut_object_names is l_result ut_object_names; @@ -54,10 +58,15 @@ create or replace type body ut_coverage_options as if exclude_objects is not empty then self.exclude_objects := to_ut_object_list(exclude_objects, self.schema_names); end if; --- self.exclude_objects := self.exclude_objects multiset union all ut_suite_manager.get_schema_ut_packages(schema_names); self.include_objects := to_ut_object_list(include_objects, self.schema_names); + self.include_schema_expr := include_schema_expr; + self.include_object_expr := include_object_expr; + self.exclude_schema_expr := exclude_schema_expr; + self.exclude_object_expr := exclude_object_expr; + + return; end; end; diff --git a/source/core/types/ut_coverage_options.tps b/source/core/types/ut_coverage_options.tps index 1be518c5e..245539179 100644 --- a/source/core/types/ut_coverage_options.tps +++ b/source/core/types/ut_coverage_options.tps @@ -21,13 +21,21 @@ create or replace type ut_coverage_options force as object ( exclude_objects ut_object_names, include_objects ut_object_names, file_mappings ut_file_mappings, + include_schema_expr varchar2(32767), + include_object_expr varchar2(32767), + exclude_schema_expr varchar2(32767), + exclude_object_expr varchar2(32767), constructor function ut_coverage_options( self in out nocopy ut_coverage_options, coverage_run_id raw, schema_names ut_varchar2_rows := null, exclude_objects ut_varchar2_rows := null, include_objects ut_varchar2_rows := null, - file_mappings ut_file_mappings := null + file_mappings ut_file_mappings := null, + include_schema_expr varchar2 := null, + include_object_expr varchar2 := null, + exclude_schema_expr varchar2 := null, + exclude_object_expr varchar2 := null ) return self as result ) / From ddf775fa1e0fa4a7475de147fd20dd25fdfcaa60 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 10 Feb 2022 10:41:17 +0200 Subject: [PATCH 266/887] Testing after fixing the workdir for 12.1EE image --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0c9789173..cf36d4c55 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -76,7 +76,7 @@ jobs: --health-timeout 5s --health-retries 10 --name oracle -# --health-cmd healthcheck.sh + --health-cmd healthcheck.sh steps: - uses: actions/checkout@v2 @@ -159,7 +159,7 @@ jobs: - name: Get ORACLE_BASE/diag data id: get-oracle-diag-data if: ${{ always() && steps.run-tests.outcome == 'failure' }} - run: docker exec oracle bash -c "chmod -R +777 ${{matrix.oracle-base}}/diag && cp -r ${{matrix.oracle-base}}/diag /utPLSQL/database-diag" + run: docker exec oracle bash -c "chmod -R +777 ./diag && cp -r ./diag /utPLSQL/database-diag" - name: Upload ORACLE_BASE/diag data Artifact id: upload if: ${{ always() && steps.run-tests.outcome == 'failure' }} From 7ecc9b2d52ca091aad74309ce07a8d1e38042b70 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 11 Feb 2022 00:08:45 +0000 Subject: [PATCH 267/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 16f90c86e..de17e4487 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 357f2db99..ffbf00693 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 96b4a1125..c3bc234bc 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 72279191f..c8a8a5bed 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b6088eceb..a6961d57a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index cd616bde0..0c9a7c63f 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e778b8d8c..e1c55833e 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 95591d7ef..bf1283e69 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 89a17d5ef..cbf2a2df6 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 97209655a..90b0e6b3f 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index ea4b37e3d..444568c54 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 83e06cf8a..a29262da0 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index f6f46c8a2..2c5e7cdfb 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 9bceca36a..5cc980f3f 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index bc18b0035..6904fb346 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 20cecb601..40171c205 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 25252df0a..91d9bc914 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3846--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index a2a3528ca..4974306a3 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3846-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3865-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 51dbe87604a626b76aef4c9b3b9be5a24c6913e1 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 14 Feb 2022 01:23:15 +0200 Subject: [PATCH 268/887] Improved get_cov_sources SQL query. References #1169 --- source/core/coverage/ut_coverage.pkb | 30 +++++++++++++++------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index ddcdeaf2e..8bdcec4eb 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -38,22 +38,20 @@ create or replace package body ut_coverage is begin l_result := q'[ with - trigger_source_offsets as ( - select min(s.line) - 1 offset, s.owner, s.name, s.type - from {sources_view} s - where s.type = 'TRIGGER' - {filters} - and (lower(s.text) like '%begin%' or lower(s.text) like '%declare%' or lower(s.text) like '%compound%') - group by s.owner, s.name, s.type - ), sources as ( select /*+ cardinality(f {mappings_cardinality}) */ {l_full_name} as full_name, s.owner, s.name, s.type, - s.line - case when s.type = 'TRIGGER' then o.offset else 0 end as line, + s.line + - case + when s.type = 'TRIGGER' + then + /* calculate offset of line number for trigger source in coverage reporting */ + min(case when lower(s.text) like '%begin%' or lower(s.text) like '%declare%' or lower(s.text) like '%compound%' then s.line-1 end) + over (partition by s.owner, s.type, s.name) + else 0 + end as line, s.text from {sources_view} s {join_file_mappings} - left join trigger_source_offsets o - on (s.owner = o.owner and s.name = o.name and s.type = o.type) where s.type in ('PACKAGE BODY', 'TYPE BODY', 'PROCEDURE', 'FUNCTION', 'TRIGGER') {filters} ), @@ -80,7 +78,11 @@ create or replace package body ut_coverage is select /*+ no_parallel */ full_name, owner, name, type, line, to_be_skipped, text from coverage_sources s -- Exclude calls to utPLSQL framework, Unit Test packages and objects from a_exclude_list parameter of coverage reporter - where (s.owner, s.name) not in ( select /*+ cardinality(el {skipped_objects_cardinality})*/el.owner, el.name from table(:l_skipped_objects) el ) + where not exists ( + select /*+ cardinality(el {skipped_objects_cardinality})*/ 1 + from table(:l_skipped_objects) el + where s.owner = el.owner and s.name = el.name + ) and line > 0 ]'; @@ -137,9 +139,9 @@ create or replace package body ut_coverage is if a_coverage_options.file_mappings is not empty then open l_cursor for l_sql using a_coverage_options.file_mappings, l_skip_objects; elsif a_coverage_options.include_objects is not empty then - open l_cursor for l_sql using a_coverage_options.include_objects, a_coverage_options.include_objects, l_skip_objects; + open l_cursor for l_sql using a_coverage_options.include_objects, l_skip_objects; else - open l_cursor for l_sql using a_coverage_options.schema_names, a_coverage_options.schema_names, l_skip_objects; + open l_cursor for l_sql using a_coverage_options.schema_names, l_skip_objects; end if; return l_cursor; end; From 4515e0b5a3b4b0de0c2198db3235ef8614bff4d8 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 14 Feb 2022 10:13:50 +0000 Subject: [PATCH 269/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index de17e4487..37bf4e2d1 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index ffbf00693..f064966b3 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index c3bc234bc..7979e1c23 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index c8a8a5bed..4772a25de 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index a6961d57a..537da5148 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 0c9a7c63f..617e888ac 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e1c55833e..e46c20029 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index bf1283e69..dc4a8ffda 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index cbf2a2df6..0fabf61bd 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 90b0e6b3f..be7e9b125 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 444568c54..a50797b2e 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index a29262da0..c4b2b1a0b 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 2c5e7cdfb..27b2989cf 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 5cc980f3f..d6e75700c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 6904fb346..ebc28ec38 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 40171c205..03fe03f3e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 91d9bc914..177f13589 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3865--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4974306a3..4401742f8 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3865-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3872-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 8370aa98ee48c2a2d4dc5f6cacf75d519a4a6e54 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 22 Feb 2022 11:21:22 +0000 Subject: [PATCH 270/887] commit changes --- source/core/coverage/ut_coverage.pkb | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index b3667bb26..93439daea 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -122,13 +122,11 @@ create or replace package body ut_coverage is if a_coverage_options.exclude_schema_expr is not null then - l_regex_exc_filters := l_regex_exc_filters||q'[and not regexp_like(s.owner,']'||a_coverage_options.exclude_schema_expr||q'[,'i') - ]'; + l_regex_exc_filters := l_regex_exc_filters||q'[ and not regexp_like(s.owner,']'||a_coverage_options.exclude_schema_expr||q'[,'i')]'; end if; if a_coverage_options.exclude_object_expr is not null then - l_regex_exc_filters := l_regex_exc_filters||q'[and not regexp_like(s.name,']'||a_coverage_options.exclude_object_expr||q'[,'i') - ]'; + l_regex_exc_filters := l_regex_exc_filters||q'[ and not regexp_like(s.name,']'||a_coverage_options.exclude_object_expr||q'[,'i')]'; end if; From b52f97d11d0b1fe65ad0a98ea515b1862653ce6f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 23 Feb 2022 01:24:48 +0200 Subject: [PATCH 271/887] Update of releasing.md --- development/releasing.md | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/development/releasing.md b/development/releasing.md index f85e18c3c..ef8edbfc2 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -1,17 +1,17 @@ ## Release process -With every build, the build process on Travis updates files with an appropriate version number before deployment into the database. -This step is performed, to confirm that the update of versions works properly. +To create a release follow the below steps -## To create a release - - - create release branch from development branch and make sure to name the release branch: `release/vX.Y.Z` - - update, commit and push at least one file change in the release branch, to kickoff a Travis build - - wait for th build to complete successfully - - merge the release branch to main and wait for main build to complete successfully (do not use Squash/rebase for merge operation) - - create a Github release from the main branch using [github releases page](https://github.com/utPLSQL/utPLSQL/releases) and populate release description using information found on the issues and pull requests since previous release. +## Release preparation + - create a draft of Release from the `main` branch using [github releases page](https://github.com/utPLSQL/utPLSQL/releases) and populate release description using information found on the issues and pull requests **since previous release**. To find issues closed after certain date use [advanced filters](https://help.github.com/articles/searching-issues-and-pull-requests/#search-by-open-or-closed-state). Example: [`is:issue closed:>2018-07-22`](https://github.com/utPLSQL/utPLSQL/issues?utf8=%E2%9C%93&q=is%3Aissue+closed%3A%3E2018-07-22+) + +## Performing a release + - create release branch from development branch and make sure to name the release branch: `release/vX.Y.Z` + - update, commit and push at least one file change in the release branch, to kick off a build on [GithubActions](https://github.com/utPLSQL/utPLSQL/actions) + - wait for the build to complete successfully + - merge the release branch to `main` branch and wait for build on `main` branch to complete successfully (do not use Squash/rebase for merge operation) - After A build was completed on a TAG (github release) was successful, merge main branch back into develop branch. - At this point, main branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. - After develop branch was built, update version number in `VERSION` file to represent next planned release version. @@ -19,11 +19,11 @@ This step is performed, to confirm that the update of versions works properly. The following will happen: - build executed on branch `release/vX.Y.Z-[something]` updates files `sonar-project.properties`, `VERSION` with project version derived from the release branch name - - changes to those two files are committed and pushed back to release branch by Travis + - changes to those two files are committed and pushed back to release branch - builds on main branch are **not getting executed** - when a Github release is created, a new tag is added in on the repository and a tag build is executed - the documentation for new release is published on `utplsql.github.io` and installation archives are added to the tag. -Note: -The sources for release are provided in separate zip files delivered from the Travis build process. +# Note: +The sources for release are provided in separate zip files delivered by the build process. The built zip files include HTML documentation generated from MD files. From 6ba87ac94d644f7afbc7f6727bce12c35bfd0deb Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 22 Feb 2022 23:31:23 +0000 Subject: [PATCH 272/887] Updated project version after build [skip ci] --- VERSION | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pks | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/VERSION b/VERSION index a0d004aa2..8ecb8bfc6 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.12-develop +v3.1.12 diff --git a/docs/about/authors.md b/docs/about/authors.md index 37bf4e2d1..19bb1c0e0 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index f064966b3..f1021f44e 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 7979e1c23..436e8879e 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 4772a25de..b9ac72097 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 537da5148..3163d3bc0 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 617e888ac..8d55bb8fc 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e46c20029..aa45f16aa 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index dc4a8ffda..e8d91bd95 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0fabf61bd..98503395f 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index be7e9b125..2c1c1fdde 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index a50797b2e..b4b5e54be 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c4b2b1a0b..341c36f4c 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 27b2989cf..662021e0c 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d6e75700c..ee88a45d3 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ebc28ec38..203dac782 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 03fe03f3e..ed6bc8956 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 177f13589..3d47d8313 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index 7559b58a1..0d7f7c9ce 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -3,7 +3,7 @@ sonar.organization=utplsql sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.12-develop +sonar.projectVersion=v3.1.12 # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4401742f8..7a4899df5 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3872-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3873'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From c62d69ca50e80a37573d8811d8e93facfb9b9c79 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 24 Feb 2022 00:34:21 +0200 Subject: [PATCH 273/887] Updated releasing.md and .gitattributes files. --- .gitattributes | 13 ++++++------- development/releasing.md | 23 ++++++++++++----------- 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/.gitattributes b/.gitattributes index abd1d5471..5e0c801de 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,17 +1,16 @@ +.github export-ignore +.idea export-ignore +development export-ignore +test export-ignore .gitattributes export-ignore .gitignore export-ignore .gitmodules export-ignore -.travis.yml export-ignore mkdocs.yml export-ignore -.travis export-ignore -.github export-ignore sonar-project.properties export-ignore -tests export-ignore -development export-ignore -node_modules export-ignore -^docs/* linguist-documentation +^docs/** linguist-documentation *.pkb linguist-language=PLSQL *.pks linguist-language=PLSQL *.sql linguist-language=PLSQL *.tpb linguist-language=PLSQL *.tps linguist-language=PLSQL +*.sh text eol=lf diff --git a/development/releasing.md b/development/releasing.md index ef8edbfc2..bcc89067a 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -3,27 +3,28 @@ To create a release follow the below steps ## Release preparation - - create a draft of Release from the `main` branch using [github releases page](https://github.com/utPLSQL/utPLSQL/releases) and populate release description using information found on the issues and pull requests **since previous release**. + - Create a **draft** of Release from the `main` branch using [github releases page](https://github.com/utPLSQL/utPLSQL/releases) and populate release description using information found on the issues and pull requests **since previous release**. To find issues closed after certain date use [advanced filters](https://help.github.com/articles/searching-issues-and-pull-requests/#search-by-open-or-closed-state). Example: [`is:issue closed:>2018-07-22`](https://github.com/utPLSQL/utPLSQL/issues?utf8=%E2%9C%93&q=is%3Aissue+closed%3A%3E2018-07-22+) ## Performing a release - - create release branch from development branch and make sure to name the release branch: `release/vX.Y.Z` - - update, commit and push at least one file change in the release branch, to kick off a build on [GithubActions](https://github.com/utPLSQL/utPLSQL/actions) - - wait for the build to complete successfully + - create the release branch from `develop` branch and make sure to name the release branch: `release/vX.Y.Z` + - update, commit and push at least one file change in the release branch, to kick off a build on [GithubActions](https://github.com/utPLSQL/utPLSQL/actions) or kick-off a build manually for that branch after it was created on github. + - wait for the build to complete successfully as it will update the version to be release number (without develop) - merge the release branch to `main` branch and wait for build on `main` branch to complete successfully (do not use Squash/rebase for merge operation) - - After A build was completed on a TAG (github release) was successful, merge main branch back into develop branch. + - Publish the release on the `main` branch and tag it with version number `vX.Y.Z` + - Wait for the release build to finish successfully on Github Actions as this will upload release artifacts (`zip` and `tar.gz` files along with `md5`) + - After A Release build was completed successfully, merge main branch back into develop branch. - At this point, main branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. - - After develop branch was built, update version number in `VERSION` file to represent next planned release version. + - After develop branch was built, increase the version number in `VERSION` file to represent next planned release version. - Clone `utplsql.githug.io` project and add a new announcement about next version being released in `_posts`. Use previous announcements as a template. Make sure to set date, time and post title properly. The following will happen: - build executed on branch `release/vX.Y.Z-[something]` updates files `sonar-project.properties`, `VERSION` with project version derived from the release branch name - changes to those two files are committed and pushed back to release branch - - builds on main branch are **not getting executed** - - when a Github release is created, a new tag is added in on the repository and a tag build is executed - - the documentation for new release is published on `utplsql.github.io` and installation archives are added to the tag. + - when a Github release is published, a new tag is added in on the repository and a release build is executed + - With Release build, the documentation for new release is published on `utplsql.github.io` and installation archives are added to the release. # Note: -The sources for release are provided in separate zip files delivered by the build process. -The built zip files include HTML documentation generated from MD files. +The utPLSQL installation files are uploaded by the release build process as release artifacts (separate `zip` and `tar.gz` files). +The release artifacts include HTML documentation generated from MD files, sources and tests From c677c5ce0e95a86f5b99c1b2101c29c40bac19af Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 23 Feb 2022 22:55:42 +0000 Subject: [PATCH 274/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 19bb1c0e0..305bf5ed4 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index f1021f44e..92d2cc380 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 436e8879e..1d11c0dd1 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index b9ac72097..837c895fc 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 3163d3bc0..637615fef 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 8d55bb8fc..dea2d2a81 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index aa45f16aa..b1d09d24e 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index e8d91bd95..0180f940a 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 98503395f..ed615a4a2 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 2c1c1fdde..cd14c0841 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b4b5e54be..2ee5c440a 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 341c36f4c..c366b06d1 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 662021e0c..429bec5da 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index ee88a45d3..818219fcc 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 203dac782..94ffd569a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index ed6bc8956..b14caec93 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 3d47d8313..079ed06ef 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3873-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3876-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 7a4899df5..d43c1c813 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3873'; + gc_version constant varchar2(50) := 'v3.1.12.3876'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 7b9e0859438765be9585de966777cd043b4932a5 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 25 Feb 2022 00:05:47 +0000 Subject: [PATCH 275/887] Making more changes --- source/core/coverage/ut_coverage.pkb | 33 +++++---- test/ut3_tester_helper/coverage_helper.pkb | 22 ++++-- .../test_coverage/test_extended_coverage.pkb | 71 +++++++++++++++++++ .../test_coverage/test_extended_coverage.pks | 16 ++++- 4 files changed, 122 insertions(+), 20 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 18d359b72..cdef6dd04 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -55,6 +55,7 @@ create or replace package body ut_coverage is from {sources_view} s {join_file_mappings} where s.type in ('PACKAGE BODY', 'TYPE BODY', 'PROCEDURE', 'FUNCTION', 'TRIGGER') {filters} + {regex_exc_filters} ), coverage_sources as ( select full_name, owner, name, type, line, text, @@ -85,7 +86,6 @@ create or replace package body ut_coverage is where s.owner = el.owner and s.name = el.name ) and line > 0 - {regex_filters} ]'; if a_coverage_options.file_mappings is not empty then @@ -99,11 +99,14 @@ create or replace package body ut_coverage is elsif a_coverage_options.include_schema_expr is not null or a_coverage_options.include_object_expr is not null then l_full_name := q'[lower(s.type||' '||s.owner||'.'||s.name)]'; if a_coverage_options.include_schema_expr is not null then - l_filters := q'[and regexp_like(s.owner,']'||a_coverage_options.include_schema_expr||q'[','i')]'; - end if; - + l_filters := q'[and regexp_like(s.owner,:a_include_schema_expr,'i')]'; + else + l_filters := 'and :a_include_schema_expr is null'; + end if; if a_coverage_options.include_object_expr is not null then - l_filters := l_filters|| q'[ and regexp_like(s.name,']'||a_coverage_options.include_object_expr||q'[','i')]'; + l_filters := l_filters|| q'[ and regexp_like(s.name,:a_include_object_expr,'i')]'; + else + l_filters := l_filters|| 'and :a_include_object_expr is null'; end if; else l_full_name := q'[lower(s.type||' '||s.owner||'.'||s.name)]'; @@ -124,11 +127,15 @@ create or replace package body ut_coverage is if a_coverage_options.exclude_schema_expr is not null then - l_regex_exc_filters := l_regex_exc_filters||q'[ and not regexp_like(s.owner,']'||a_coverage_options.exclude_schema_expr||q'[,'i')]'; + l_regex_exc_filters := q'[ and not regexp_like(s.owner,:a_exclude_schema_expr,'i')]'; + else + l_regex_exc_filters := ' and :a_exclude_schema_expr is null '; end if; if a_coverage_options.exclude_object_expr is not null then - l_regex_exc_filters := l_regex_exc_filters||q'[ and not regexp_like(s.name,']'||a_coverage_options.exclude_object_expr||q'[,'i')]'; + l_regex_exc_filters := l_regex_exc_filters||q'[ and not regexp_like(s.name,:a_exclude_obj_expr:,'i')]'; + else + l_regex_exc_filters := l_regex_exc_filters||'and :a_exclude_obj_expr is null '; end if; @@ -139,7 +146,7 @@ create or replace package body ut_coverage is l_result := replace(l_result, '{filters}', l_filters); l_result := replace(l_result, '{mappings_cardinality}', l_mappings_cardinality); l_result := replace(l_result, '{skipped_objects_cardinality}', ut_utils.scale_cardinality(cardinality(a_skip_objects))); - l_result := replace(l_result, '{regex_filters}', l_regex_exc_filters); + l_result := replace(l_result, '{regex_exc_filters}', l_regex_exc_filters); return l_result; @@ -160,13 +167,15 @@ create or replace package body ut_coverage is ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_key_anyvalues().put('l_sql',l_sql) ); if a_coverage_options.file_mappings is not empty then - open l_cursor for l_sql using a_coverage_options.file_mappings, l_skip_objects; + open l_cursor for l_sql using a_coverage_options.file_mappings,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; elsif a_coverage_options.include_objects is not empty then - open l_cursor for l_sql using a_coverage_options.include_objects, l_skip_objects; + open l_cursor for l_sql using a_coverage_options.include_objects,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; elsif a_coverage_options.include_schema_expr is not null or a_coverage_options.include_object_expr is not null then - open l_cursor for l_sql using l_skip_objects; + open l_cursor for l_sql using a_coverage_options.include_schema_expr,a_coverage_options.include_object_expr, + a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr, + l_skip_objects; else - open l_cursor for l_sql using a_coverage_options.schema_names, l_skip_objects; + open l_cursor for l_sql using a_coverage_options.schema_names,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; end if; return l_cursor; end; diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 4be062645..bbf288ed4 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -200,14 +200,14 @@ create or replace package body coverage_helper is begin execute immediate q'[drop package ut3_develop.test_regex_dummy_cov]'; exception when others then null; end; end; - procedure create_regex_dummy_cov_schema is + procedure create_regex_dummy_for_schema(p_schema in varchar2) is pragma autonomous_transaction; begin - execute immediate q'[create or replace package ut3_develop.]'||covered_package_name||q'[ is + execute immediate q'[create or replace package ]'||p_schema||q'[.regex_dummy_cov_schema is procedure do_stuff(i_input in number); end;]'; - execute immediate q'[create or replace package body ut3_develop.]'||covered_package_name||q'[ is + execute immediate q'[create or replace package body ]'||p_schema||q'[.regex_dummy_cov_schema is procedure do_stuff(i_input in number) is begin if i_input = 2 then dbms_output.put_line('should not get here'); elsif i_input = 1 then dbms_output.put_line('should get here'); @@ -217,7 +217,7 @@ create or replace package body coverage_helper is end; end;]'; - execute immediate q'[create or replace package ut3_develop.test_dummy_coverage is + execute immediate q'[create or replace package ]'||p_schema||q'[.test_regex_dummy_cov_schema is --%suite(dummy coverage test) --%suitepath(coverage_testing) @@ -228,10 +228,10 @@ create or replace package body coverage_helper is procedure zero_coverage; end;]'; - execute immediate q'[create or replace package body ut3_develop.test_dummy_coverage is + execute immediate q'[create or replace package body ]'||p_schema||q'[.test_regex_dummy_cov_schema is procedure test_do_stuff is begin - ]'||covered_package_name||q'[.do_stuff(1); + regex_dummy_cov_schema.do_stuff(1); ut.expect(1).to_equal(1); end; procedure zero_coverage is @@ -241,11 +241,19 @@ create or replace package body coverage_helper is end;]'; end; + procedure create_regex_dummy_cov_schema is + begin + create_regex_dummy_for_schema('ut3_develop'); + create_regex_dummy_for_schema('ut3_tester_helper'); + end; + procedure drop_regex_dummy_cov_schema is pragma autonomous_transaction; begin - begin execute immediate q'[drop package ut3_helper.regex_dummy_cov_schema]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.regex_dummy_cov_schema]'; exception when others then null; end; begin execute immediate q'[drop package ut3_develop.test_regex_dummy_cov_schema]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_tester_helper.regex_dummy_cov_schema]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_tester_helper.test_regex_dummy_cov_schema]'; exception when others then null; end; end; diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index a8d104e28..5aea2e184 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -106,5 +106,76 @@ create or replace package body test_extended_coverage is ut.expect(l_actual).to_be_like(l_expected); end; + procedure coverage_regex_include_schema is + l_expected_ut3 clob; + l_expected_help clob; + l_actual_ut3 clob; + l_actual_help clob; + l_actual_both clob; + + begin + --Arrange + l_expected_ut3 := '%' || + '%%'; + l_expected_help := '%' || + '%%'; + --Act + l_actual_ut3 := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov_schema', 'ut3_tester_helper.test_regex_dummy_cov_schema'), + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_schema_expr => '^ut3_develop' + ) + ]' + ); + /* + l_actual_help := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov_schema', 'ut3_tester_helper.test_regex_dummy_cov_schema'), + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_schema_expr => '^ut3_tester_helper' + ) + ]' + ); + + l_actual_both := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov_schema', 'ut3_tester_helper.test_regex_dummy_cov_schema'), + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_include_schema_expr => '^ut3_tester_helper||^ut3_tester_helper' + ) + ]' + ); + */ + --Assert + ut.expect(l_actual_ut3).to_be_like(l_expected_ut3); + ut.expect(l_actual_ut3).not_to_be_like(l_expected_help); + --ut.expect(l_actual_help).to_be_like(l_expected_help); + --ut.expect(l_actual_help).not_to_be_like(l_expected_ut3); + --ut.expect(l_actual_both).to_be_like(l_expected_ut3); + --ut.expect(l_actual_both).to_be_like(l_expected_help); + end; + + procedure coverage_regex_include_object is + begin + null; + end; + + procedure coverage_regex_exclude_schema is + begin + null; + end; + + procedure coverage_regex_exclude_object is + begin + null; + end; + end; / diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks index c575c240c..a8c71f442 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks @@ -17,6 +17,20 @@ create or replace package test_extended_coverage is --%tags(#1097,#1094) --%test(Extended coverage does not fail the test run then tested code calls DBMS_STATS) procedure coverage_with_dbms_stats; - + + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov_schema) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov_schema) + --%test(Collect coverage for objects with schema regex include) + procedure coverage_regex_include_schema; + + --%test(Collect coverage for objects with schema regex include) + procedure coverage_regex_include_object; + + --%test(Collect coverage for objects with schema regex include) + procedure coverage_regex_exclude_schema; + + --%test(Collect coverage for objects with schema regex include) + procedure coverage_regex_exclude_object; + end; / From 1a5b2647297f50cb960f58d68ab360d934c2b53c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 25 Feb 2022 00:09:06 +0000 Subject: [PATCH 276/887] The env are not set for archives files. Between each job looks like all settings and env needs to be set again. --- .github/workflows/release.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ad1e782c5..bd977d447 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -49,6 +49,14 @@ jobs: - uses: actions/checkout@v2 with: fetch-depth: 0 + - uses: c-py/action-dotenv-to-setenv@v2 + with: + env-file: .github/variables/.env + - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action + + - name: Set buid version number env variables + run: .github/scripts/set_version_numbers_env.sh + - name: Update project version & build number in source code and documentation run: .github/scripts/update_project_version.sh From b3dba1905941d3ef778d1ebf8372026e7aad97ea Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 25 Feb 2022 00:46:31 +0000 Subject: [PATCH 277/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 37bf4e2d1..8c02ce441 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index f064966b3..1fd31b877 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 7979e1c23..05a2abdde 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 4772a25de..9a746a84c 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 537da5148..1ce42648a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 617e888ac..941f5c364 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e46c20029..104e82f7c 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index dc4a8ffda..65e044fd8 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0fabf61bd..b9a0a70a0 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index be7e9b125..c7b9a3847 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index a50797b2e..f95607466 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c4b2b1a0b..476b826fd 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 27b2989cf..70441da7e 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d6e75700c..78735f144 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ebc28ec38..ee366861f 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 03fe03f3e..1313dc90b 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 177f13589..516850fec 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3872--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4401742f8..24ea09d0d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3872-develop'; + gc_version constant varchar2(50) := 'v3.1.12.3879-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ca3dec790a9821cc2bdbf1bd2e12c33615339b52 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 25 Feb 2022 17:47:58 +0200 Subject: [PATCH 278/887] Updated project version to 3.1.13 --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index a0d004aa2..d0237db61 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.12-develop +v3.1.13-develop From fd81df2439703943825cbf2d4f98e37f31568fa9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 25 Feb 2022 15:56:06 +0000 Subject: [PATCH 279/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 8c02ce441..70bdb2613 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 1fd31b877..cdc5d1330 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 05a2abdde..99b9f26d4 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 9a746a84c..fea1bfcad 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 1ce42648a..99a7df954 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 941f5c364..685449c27 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 104e82f7c..6667189e2 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 65e044fd8..415b477b6 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index b9a0a70a0..4cda2c9d4 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index c7b9a3847..645d17c89 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index f95607466..5b5d3079f 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 476b826fd..edaf0310d 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 70441da7e..9bbe8a452 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 78735f144..09cfd0029 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ee366861f..27b37c276 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 1313dc90b..308788d62 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 516850fec..0ec9e80ee 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.12.3879--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index 7559b58a1..5d6cefe12 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -3,7 +3,7 @@ sonar.organization=utplsql sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.12-develop +sonar.projectVersion=v3.1.13-develop # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 24ea09d0d..69955bab0 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.12.3879-develop'; + gc_version constant varchar2(50) := 'v3.1.13.3880-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 7e680eeaa67b94bcface6034ecca7e2ed7684f7e Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 25 Feb 2022 18:49:42 +0200 Subject: [PATCH 280/887] Added disabledReason to `ut_realtime_reporter` --- source/reporters/ut_realtime_reporter.tpb | 1 + .../reporters/test_realtime_reporter.pkb | 38 ++++++++++++++++--- .../reporters/test_realtime_reporter.pks | 3 ++ 3 files changed, 37 insertions(+), 5 deletions(-) diff --git a/source/reporters/ut_realtime_reporter.tpb b/source/reporters/ut_realtime_reporter.tpb index 837643b0b..9c2af57ec 100644 --- a/source/reporters/ut_realtime_reporter.tpb +++ b/source/reporters/ut_realtime_reporter.tpb @@ -43,6 +43,7 @@ create or replace type body ut_realtime_reporter is self.print_node('objectName', a_test.item.object_name); self.print_node('procedureName', a_test.item.procedure_name); self.print_node('disabled', case when a_test.get_disabled_flag() then 'true' else 'false' end); + self.print_node('disabledReason', a_test.disabled_reason); self.print_node('name', a_test.name); self.print_node('description', a_test.description); self.print_node('testNumber', to_char(total_number_of_tests)); diff --git a/test/ut3_user/reporters/test_realtime_reporter.pkb b/test/ut3_user/reporters/test_realtime_reporter.pkb index ad354133b..2dafa71d0 100644 --- a/test/ut3_user/reporters/test_realtime_reporter.pkb +++ b/test/ut3_user/reporters/test_realtime_reporter.pkb @@ -45,6 +45,10 @@ create or replace package body test_realtime_reporter as --%test --%disabled procedure test_5; + + --%test + --%disabled(Cannot run this item at this time runtime > 10 mins.) + procedure test_6_disabled_reason; end;]'; execute immediate q'[create or replace package body check_realtime_reporting2 is procedure test_3_ok is @@ -62,6 +66,11 @@ create or replace package body test_realtime_reporter as begin null; end; + + procedure test_6_disabled_reason is + begin + null; + end; end;]'; execute immediate q'[create or replace package check_realtime_reporting3 is @@ -179,6 +188,8 @@ create or replace package body test_realtime_reporter as select 'post-test' as event_type, 'realtime_reporting.check_realtime_reporting2.test_4_nok' as item_id from dual union all select 'pre-test' as event_type, 'realtime_reporting.check_realtime_reporting2.test_5' as item_id from dual union all select 'post-test' as event_type, 'realtime_reporting.check_realtime_reporting2.test_5' as item_id from dual union all + select 'pre-test' as event_type, 'realtime_reporting.check_realtime_reporting2.test_6_disabled_reason' as item_id from dual union all + select 'post-test' as event_type, 'realtime_reporting.check_realtime_reporting2.test_6_disabled_reason' as item_id from dual union all select 'post-suite' as event_type, 'realtime_reporting.check_realtime_reporting2' as item_id from dual union all select 'pre-suite' as event_type, 'realtime_reporting.check_realtime_reporting1' as item_id from dual union all select 'pre-suite' as event_type, 'realtime_reporting.check_realtime_reporting1.test_context' as item_id from dual union all @@ -226,6 +237,7 @@ create or replace package body test_realtime_reporter as select 'event/items/suite/items/suite/items/test' as node_path from dual union all select 'event/items/suite/items/suite/items/test' as node_path from dual union all select 'event/items/suite/items/suite/items/test' as node_path from dual union all + select 'event/items/suite/items/suite/items/test' as node_path from dual union all select 'event/items/suite/items/suite' as node_path from dual union all select 'event/items/suite/items/suite/items' as node_path from dual union all select 'event/items/suite/items/suite/items/suite' as node_path from dual union all @@ -237,7 +249,7 @@ create or replace package body test_realtime_reporter as procedure total_number_of_tests is l_actual integer; - l_expected integer := 8; + l_expected integer := 9; begin select t.event_doc.extract('/event/totalNumberOfTests/text()').getnumberval() into l_actual @@ -283,9 +295,9 @@ create or replace package body test_realtime_reporter as and t.event_doc.extract('//test/@id').getstringval() is not null; open l_expected for select level as test_number, - 8 as total_number_of_tests + 9 as total_number_of_tests from dual - connect by level <= 8; + connect by level <= 9; ut.expect(l_actual).to_equal(l_expected).unordered; end pre_test_nodes; @@ -311,9 +323,9 @@ create or replace package body test_realtime_reporter as and t.event_doc.extract('//test/counter/warning/text()').getnumberval() is not null; open l_expected for select level as test_number, - 8 as total_number_of_tests + 9 as total_number_of_tests from dual - connect by level <= 8; + connect by level <= 9; ut.expect(l_actual).to_equal(l_expected).unordered; end post_test_nodes; @@ -494,6 +506,22 @@ create or replace package body test_realtime_reporter as ut.expect(l_xml is not null).to_be_true(); end; + procedure disabled_reason is + l_actual varchar2(32767); + l_expected varchar2(80) := dbms_xmlgen.convert('Cannot run this item at this time runtime > 10 mins.'); + begin + select t.event_doc.extract( + '//test/disabledReason/text()' + ).getstringval() + into l_actual + from table(g_events) t + where xmlexists( + '/event[@type="pre-run"]/*//test[@id="realtime_reporting.check_realtime_reporting2.test_6_disabled_reason"]' + passing t.event_doc + ); + ut.expect(l_actual).to_equal(l_expected); + end; + procedure remove_test_suites is pragma autonomous_transaction; begin diff --git a/test/ut3_user/reporters/test_realtime_reporter.pks b/test/ut3_user/reporters/test_realtime_reporter.pks index 453824ca5..087713f79 100644 --- a/test/ut3_user/reporters/test_realtime_reporter.pks +++ b/test/ut3_user/reporters/test_realtime_reporter.pks @@ -57,6 +57,9 @@ create or replace package test_realtime_reporter as --%test(Escape nested CDATA sections in test output) procedure nested_cdata_output; + --%test(Provide reason disabled test) + procedure disabled_reason; + --%afterall procedure remove_test_suites; From 4eec03e223c942471112ee9e68303b962e0cd25d Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 25 Feb 2022 20:19:42 +0000 Subject: [PATCH 281/887] Update to code to address sql injection concerns. Dealing with precedence. Adding some more tests. --- source/core/coverage/ut_coverage.pkb | 14 ++- test/ut3_tester_helper/coverage_helper.pkb | 52 ++++---- test/ut3_tester_helper/coverage_helper.pks | 3 - .../test_coverage/test_extended_coverage.pkb | 115 ++++++++++++------ .../test_coverage/test_extended_coverage.pks | 16 ++- 5 files changed, 123 insertions(+), 77 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index cdef6dd04..3c5bde7af 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -133,7 +133,7 @@ create or replace package body ut_coverage is end if; if a_coverage_options.exclude_object_expr is not null then - l_regex_exc_filters := l_regex_exc_filters||q'[ and not regexp_like(s.name,:a_exclude_obj_expr:,'i')]'; + l_regex_exc_filters := l_regex_exc_filters||q'[ and not regexp_like(s.name,:a_exclude_obj_expr,'i')]'; else l_regex_exc_filters := l_regex_exc_filters||'and :a_exclude_obj_expr is null '; end if; @@ -147,7 +147,7 @@ create or replace package body ut_coverage is l_result := replace(l_result, '{mappings_cardinality}', l_mappings_cardinality); l_result := replace(l_result, '{skipped_objects_cardinality}', ut_utils.scale_cardinality(cardinality(a_skip_objects))); l_result := replace(l_result, '{regex_exc_filters}', l_regex_exc_filters); - + return l_result; end; @@ -159,7 +159,11 @@ create or replace package body ut_coverage is begin if not is_develop_mode() then --skip all the utplsql framework objects and all the unit test packages that could potentially be reported by coverage. - l_skip_objects := ut_utils.get_utplsql_objects_list() multiset union all coalesce(a_coverage_options.exclude_objects, ut_object_names()); + l_skip_objects := coalesce(ut_utils.get_utplsql_objects_list(),ut_object_names()); + --Regex exclusion override the standard exclusion objects. + if a_coverage_options.exclude_schema_expr is null and a_coverage_options.exclude_object_expr is null then + l_skip_objects := l_skip_objects multiset union all coalesce(a_coverage_options.exclude_objects, ut_object_names()); + end if; end if; l_sql := get_cov_sources_sql(a_coverage_options, l_skip_objects); @@ -168,12 +172,12 @@ create or replace package body ut_coverage is if a_coverage_options.file_mappings is not empty then open l_cursor for l_sql using a_coverage_options.file_mappings,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; - elsif a_coverage_options.include_objects is not empty then - open l_cursor for l_sql using a_coverage_options.include_objects,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; elsif a_coverage_options.include_schema_expr is not null or a_coverage_options.include_object_expr is not null then open l_cursor for l_sql using a_coverage_options.include_schema_expr,a_coverage_options.include_object_expr, a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr, l_skip_objects; + elsif a_coverage_options.include_objects is not empty then + open l_cursor for l_sql using a_coverage_options.include_objects,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; else open l_cursor for l_sql using a_coverage_options.schema_names,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; end if; diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index bbf288ed4..5f255a2e6 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -158,14 +158,14 @@ create or replace package body coverage_helper is end; - procedure create_regex_dummy_cov is + procedure create_regex_dummy_for_schema(p_schema in varchar2) is pragma autonomous_transaction; begin - execute immediate q'[create or replace package ut3_develop.regex_dummy_cov is + execute immediate q'[create or replace package ]'||p_schema||q'[.regex_dummy_cov is procedure do_stuff(i_input in number); end;]'; - execute immediate q'[create or replace package body ut3_develop.regex_dummy_cov is + execute immediate q'[create or replace package body ]'||p_schema||q'[.regex_dummy_cov is procedure do_stuff(i_input in number) is begin if i_input = 2 then dbms_output.put_line('should not get here'); elsif i_input = 1 then dbms_output.put_line('should get here'); @@ -175,39 +175,38 @@ create or replace package body coverage_helper is end; end;]'; - execute immediate q'[create or replace package ut3_develop.test_regex_dummy_cov is + execute immediate q'[create or replace package ]'||p_schema||q'[.test_regex_dummy_cov is --%suite(dummy coverage test) --%suitepath(coverage_testing) --%test procedure test_do_stuff; + --%test + procedure zero_coverage; end;]'; - execute immediate q'[create or replace package body ut3_develop.test_regex_dummy_cov is + execute immediate q'[create or replace package body ]'||p_schema||q'[.test_regex_dummy_cov is procedure test_do_stuff is begin regex_dummy_cov.do_stuff(1); ut.expect(1).to_equal(1); end; + procedure zero_coverage is + begin + null; + end; end;]'; end; - - procedure drop_regex_dummy_cov is - pragma autonomous_transaction; - begin - begin execute immediate q'[drop package ut3_develop.regex_dummy_cov]'; exception when others then null; end; - begin execute immediate q'[drop package ut3_develop.test_regex_dummy_cov]'; exception when others then null; end; - end; - procedure create_regex_dummy_for_schema(p_schema in varchar2) is + procedure create_regex_dummy_obj is pragma autonomous_transaction; begin - execute immediate q'[create or replace package ]'||p_schema||q'[.regex_dummy_cov_schema is + execute immediate q'[create or replace package ut3_develop.regex123_dummy_cov is procedure do_stuff(i_input in number); end;]'; - execute immediate q'[create or replace package body ]'||p_schema||q'[.regex_dummy_cov_schema is + execute immediate q'[create or replace package body ut3_develop.regex123_dummy_cov is procedure do_stuff(i_input in number) is begin if i_input = 2 then dbms_output.put_line('should not get here'); elsif i_input = 1 then dbms_output.put_line('should get here'); @@ -217,7 +216,7 @@ create or replace package body coverage_helper is end; end;]'; - execute immediate q'[create or replace package ]'||p_schema||q'[.test_regex_dummy_cov_schema is + execute immediate q'[create or replace package ut3_develop.test_regex123_dummy_cov is --%suite(dummy coverage test) --%suitepath(coverage_testing) @@ -228,10 +227,10 @@ create or replace package body coverage_helper is procedure zero_coverage; end;]'; - execute immediate q'[create or replace package body ]'||p_schema||q'[.test_regex_dummy_cov_schema is + execute immediate q'[create or replace package body ut3_develop.test_regex123_dummy_cov is procedure test_do_stuff is begin - regex_dummy_cov_schema.do_stuff(1); + regex123_dummy_cov.do_stuff(1); ut.expect(1).to_equal(1); end; procedure zero_coverage is @@ -240,20 +239,23 @@ create or replace package body coverage_helper is end; end;]'; end; - - procedure create_regex_dummy_cov_schema is + + procedure create_regex_dummy_cov is begin create_regex_dummy_for_schema('ut3_develop'); create_regex_dummy_for_schema('ut3_tester_helper'); + create_regex_dummy_obj; end; - procedure drop_regex_dummy_cov_schema is + procedure drop_regex_dummy_cov is pragma autonomous_transaction; begin - begin execute immediate q'[drop package ut3_develop.regex_dummy_cov_schema]'; exception when others then null; end; - begin execute immediate q'[drop package ut3_develop.test_regex_dummy_cov_schema]'; exception when others then null; end; - begin execute immediate q'[drop package ut3_tester_helper.regex_dummy_cov_schema]'; exception when others then null; end; - begin execute immediate q'[drop package ut3_tester_helper.test_regex_dummy_cov_schema]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.regex_dummy_cov]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.test_regex_dummy_cov]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_tester_helper.regex_dummy_cov]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_tester_helper.test_regex_dummy_cov]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.regex123_dummy_cov]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.test_regex123_dummy_cov]'; exception when others then null; end; end; diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index 04bb0029c..c5e862612 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -17,9 +17,6 @@ create or replace package coverage_helper is procedure create_regex_dummy_cov; procedure drop_regex_dummy_cov; - procedure create_regex_dummy_cov_schema; - procedure drop_regex_dummy_cov_schema; - procedure create_cov_with_dbms_stats; procedure drop_cov_with_dbms_stats; diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index 5aea2e184..f14eac984 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -107,74 +107,111 @@ create or replace package body test_extended_coverage is end; procedure coverage_regex_include_schema is - l_expected_ut3 clob; - l_expected_help clob; - l_actual_ut3 clob; - l_actual_help clob; - l_actual_both clob; - + l_expected clob; + l_not_expected clob; + l_actual clob; begin --Arrange - l_expected_ut3 := '%' || + l_expected := '%' || '%%'; - l_expected_help := '%' || + l_not_expected := '%' || '%%'; --Act - l_actual_ut3 := + l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( q'[ ut3_develop.ut.run( - a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov_schema', 'ut3_tester_helper.test_regex_dummy_cov_schema'), + a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov', 'ut3_tester_helper.test_regex_dummy_cov'), a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_schema_expr => '^ut3_develop' + a_include_schema_expr => '^ut3_develop', + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) ) ]' - ); - /* - l_actual_help := + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_like(l_not_expected); + end; + + procedure coverage_regex_include_object is + l_expected clob; + l_not_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%' || + '%%'; + l_not_expected := '%' || + '%%'; + --Act + l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( q'[ ut3_develop.ut.run( - a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov_schema', 'ut3_tester_helper.test_regex_dummy_cov_schema'), + a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov', 'ut3_develop.test_regex123_dummy_cov'), a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_schema_expr => '^ut3_tester_helper' + a_include_object_expr => 'regex123', + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.regex_dummy_cov' ) ) ]' - ); + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_like(l_not_expected); + end; - l_actual_both := + procedure coverage_regex_exclude_schema is + l_expected clob; + l_not_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%' || + '%%'; + l_not_expected := '%' || + '%%'; + --Act + l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( q'[ ut3_develop.ut.run( - a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov_schema', 'ut3_tester_helper.test_regex_dummy_cov_schema'), + a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov', 'ut3_tester_helper.test_regex_dummy_cov'), a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_schema_expr => '^ut3_tester_helper||^ut3_tester_helper' + a_exclude_schema_expr => '^ut3_tester', + a_exclude_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.regex_dummy_cov' ) ) ]' - ); - */ + ); --Assert - ut.expect(l_actual_ut3).to_be_like(l_expected_ut3); - ut.expect(l_actual_ut3).not_to_be_like(l_expected_help); - --ut.expect(l_actual_help).to_be_like(l_expected_help); - --ut.expect(l_actual_help).not_to_be_like(l_expected_ut3); - --ut.expect(l_actual_both).to_be_like(l_expected_ut3); - --ut.expect(l_actual_both).to_be_like(l_expected_help); - end; - - procedure coverage_regex_include_object is - begin - null; - end; - - procedure coverage_regex_exclude_schema is - begin - null; + ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_like(l_not_expected); end; procedure coverage_regex_exclude_object is + l_expected clob; + l_not_expected clob; + l_actual clob; begin - null; + --Arrange + l_expected := '%' || + '%%'; + l_not_expected := '%' || + '%%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov', 'ut3_develop.test_regex123_dummy_cov'), + a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), + a_exclude_object_expr => 'regex123', + a_exclude_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.regex_dummy_cov' ) + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_like(l_not_expected); end; end; diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks index a8c71f442..99d7c5db4 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks @@ -18,18 +18,24 @@ create or replace package test_extended_coverage is --%test(Extended coverage does not fail the test run then tested code calls DBMS_STATS) procedure coverage_with_dbms_stats; - --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov_schema) - --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov_schema) + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) --%test(Collect coverage for objects with schema regex include) procedure coverage_regex_include_schema; - --%test(Collect coverage for objects with schema regex include) + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) + --%test(Collect coverage for objects with object regex include) procedure coverage_regex_include_object; - --%test(Collect coverage for objects with schema regex include) + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) + --%test(Collect coverage for objects with schema regex exclude) procedure coverage_regex_exclude_schema; - --%test(Collect coverage for objects with schema regex include) + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) + --%test(Collect coverage for objects with object regex exclude) procedure coverage_regex_exclude_object; end; From e7d59b4b3eea36cea8fbbaeb7640b1f82ec8ba7b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 25 Feb 2022 20:55:36 +0000 Subject: [PATCH 282/887] Splitting skipped framework objects and excluded objects into separate table types. Update docs. --- docs/userguide/coverage.md | 32 +++++++++++++++++++--- source/core/coverage/ut_coverage.pkb | 40 +++++++++++++++++++--------- 2 files changed, 55 insertions(+), 17 deletions(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 1f6cc4be5..29651b68c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -131,10 +131,34 @@ exec ut.run('unit_test_schema', ut_coverage_html_reporter(), a_coverage_schemes There are six options that can be used to narrow down the scope of coverage report: - `a_include_objects` - list of `[object_owner.].object_name` to be included in the coverage report. - `a_exclude_objects` - list of `[object_owner.].object_name` to be excluded from the coverage report -- `a_include_schema_expr` - string of regex expression of schemas to be included in the coverage report. It will override `a_include_objects` -- `a_include_object_expr` - string of regex expression of objects ( no schema names included ) to be included in the coverage report. It will override `a_include_objects` -- `a_exclude_schema_expr` - string of regex expression of schemas to be excluded from the coverage report. It will override `a_exclude_objects` -- `a_exclude_object_expr` - string of regex expression of objects to be excluded from the coverage report. It will override `a_exclude_objects` +- `a_include_schema_expr` - string of regex expression of schemas to be included in the coverage report. It will override `a_include_objects` for example : + ```sql + a_include_schema_expr => '^ut3_develop', + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) + ``` + Will result in showing coverage for all schemas that match regular expression `^ut3_develop` and ignore objectes defined by parameter `a_include_objects` + +- `a_include_object_expr` - string of regex expression of objects ( no schema names included ) to be included in the coverage report. It will override `a_include_objects` for example: + ```sql + a_include_object_expr => 'regex123', + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) + ``` + Will result in showing coverage for all objects that name match regular expression `regex123` and ignore objectes defined by parameter `a_include_objects` + +- `a_exclude_schema_expr` - string of regex expression of schemas to be excluded from the coverage report. It will override `a_exclude_objects` for example: + ```sql + a_exclude_schema_expr => '^ut3_tester', + a_exclude_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.regex_dummy_cov' ) + ``` + Will result in showing coverage for all objects that schema is not matching regular expression `^ut3_tester` and ignore exclusion defined by parameter `a_exclude_objects` + +- `a_exclude_object_expr` - string of regex expression of objects to be excluded from the coverage report. It will override `a_exclude_objects` for example + ```sql + a_exclude_object_expr => 'regex123', + a_exclude_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.regex_dummy_cov' ) + ``` + Will result in showing coverage for all objects that name is not matching regular expression `regex123` and ignore exclusion defined by parameter `a_exclude_objects` + You may specify both _include_ and _exclude_ options to gain more control over what needs to be included / excluded from the coverage report. diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 3c5bde7af..06951fc2f 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -30,7 +30,7 @@ create or replace package body ut_coverage is end; function get_cov_sources_sql(a_coverage_options ut_coverage_options, a_skip_objects ut_object_names) return varchar2 is - l_result varchar2(32767); --QUESTION: Given fact that we can pass large regex filters same as objects filter should we consider a clob ? + l_result varchar2(32767); l_full_name varchar2(32767); l_join_mappings varchar2(32767); l_filters varchar2(32767); @@ -55,7 +55,12 @@ create or replace package body ut_coverage is from {sources_view} s {join_file_mappings} where s.type in ('PACKAGE BODY', 'TYPE BODY', 'PROCEDURE', 'FUNCTION', 'TRIGGER') {filters} - {regex_exc_filters} + {regex_exc_filters} + and not exists ( + select /*+ cardinality(el {excuded_objects_cardinality})*/ 1 + from table(:l_excluded_objects) el + where s.owner = el.owner and s.name = el.name + ) ), coverage_sources as ( select full_name, owner, name, type, line, text, @@ -146,6 +151,7 @@ create or replace package body ut_coverage is l_result := replace(l_result, '{filters}', l_filters); l_result := replace(l_result, '{mappings_cardinality}', l_mappings_cardinality); l_result := replace(l_result, '{skipped_objects_cardinality}', ut_utils.scale_cardinality(cardinality(a_skip_objects))); + l_result := replace(l_result, '{excuded_objects_cardinality}', ut_utils.scale_cardinality(cardinality(coalesce(a_coverage_options.exclude_objects, ut_object_names())))); l_result := replace(l_result, '{regex_exc_filters}', l_regex_exc_filters); return l_result; @@ -153,33 +159,41 @@ create or replace package body ut_coverage is end; function get_cov_sources_cursor(a_coverage_options in ut_coverage_options) return sys_refcursor is - l_cursor sys_refcursor; - l_skip_objects ut_object_names; - l_sql varchar2(32767); + l_cursor sys_refcursor; + l_skip_objects ut_object_names; + l_excluded_objects ut_object_names; + l_sql varchar2(32767); begin if not is_develop_mode() then --skip all the utplsql framework objects and all the unit test packages that could potentially be reported by coverage. l_skip_objects := coalesce(ut_utils.get_utplsql_objects_list(),ut_object_names()); - --Regex exclusion override the standard exclusion objects. - if a_coverage_options.exclude_schema_expr is null and a_coverage_options.exclude_object_expr is null then - l_skip_objects := l_skip_objects multiset union all coalesce(a_coverage_options.exclude_objects, ut_object_names()); - end if; end if; + --Regex exclusion override the standard exclusion objects. + if a_coverage_options.exclude_schema_expr is null and a_coverage_options.exclude_object_expr is null then + l_excluded_objects := coalesce(a_coverage_options.exclude_objects, ut_object_names()); + end if; + l_sql := get_cov_sources_sql(a_coverage_options, l_skip_objects); ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_key_anyvalues().put('l_sql',l_sql) ); if a_coverage_options.file_mappings is not empty then - open l_cursor for l_sql using a_coverage_options.file_mappings,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; + open l_cursor for l_sql using a_coverage_options.file_mappings,a_coverage_options.exclude_schema_expr, + a_coverage_options.exclude_object_expr,l_excluded_objects, + l_skip_objects; elsif a_coverage_options.include_schema_expr is not null or a_coverage_options.include_object_expr is not null then open l_cursor for l_sql using a_coverage_options.include_schema_expr,a_coverage_options.include_object_expr, a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr, - l_skip_objects; + l_excluded_objects,l_skip_objects; elsif a_coverage_options.include_objects is not empty then - open l_cursor for l_sql using a_coverage_options.include_objects,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; + open l_cursor for l_sql using a_coverage_options.include_objects,a_coverage_options.exclude_schema_expr, + a_coverage_options.exclude_object_expr,l_excluded_objects, + l_skip_objects; else - open l_cursor for l_sql using a_coverage_options.schema_names,a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr,l_skip_objects; + open l_cursor for l_sql using a_coverage_options.schema_names,a_coverage_options.exclude_schema_expr, + a_coverage_options.exclude_object_expr,l_excluded_objects, + l_skip_objects; end if; return l_cursor; end; From 9f229b8f34750f5e6da31fa0bf6070b49b0f48eb Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 25 Feb 2022 22:58:15 +0000 Subject: [PATCH 283/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 70bdb2613..34f00c50c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index cdc5d1330..43a9c7144 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 99b9f26d4..48ece4cc6 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index fea1bfcad..0da2b42fe 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 99a7df954..2437aa9c1 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 685449c27..bfd2a13da 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 6667189e2..d3ae90eca 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 415b477b6..b4052a74a 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4cda2c9d4..813815239 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 645d17c89..a78657be0 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 5b5d3079f..91d8d02b3 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index edaf0310d..91099d1bb 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 9bbe8a452..05fed3990 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 09cfd0029..a4e8f1a5d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 27b37c276..1961e5f98 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 308788d62..ba552ef2d 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 0ec9e80ee..14ac4988c 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3880--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 69955bab0..9d31d71b3 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.3880-develop'; + gc_version constant varchar2(50) := 'v3.1.13.3889-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 6f5b2dc81148c7723a1d174992603c5203af1dbd Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 26 Feb 2022 01:25:02 +0200 Subject: [PATCH 284/887] Update of coverage documentation --- docs/userguide/coverage.md | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 29651b68c..42f35c08a 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -780,6 +780,10 @@ ut_coverage_options( exclude_objects ut_varchar2_rows := null, include_objects ut_varchar2_rows := null, file_mappings ut_file_mappings := null + include_schema_expr varchar2(4000) := null, + include_object_expr varchar2(4000) := null, + exclude_schema_expr varchar2(4000) := null, + exclude_object_expr varchar2(4000) := null ); ``` @@ -795,6 +799,10 @@ The `a_coverage_options` parameter is used to control the scope and formatting o - `exclude_objects` - optional - list of object names to exclude from report - data-type `UT_VARCHAR2_ROWS` - `include_objects` - optional - list of object names to gather coverage on - data-type `UT_VARCHAR2_ROWS` - `file_mappings` - optional - list of schema names to gather coverage on - data-type `UT_FILE_MAPPINGS` +- `include_schema_expr` - optional - regular expression to match against schema name to include in coverage - data-type `VARCHAR2(4000)` +- `include_object_expr` - optional - regular expression to match against object name to include in coverage - data-type `VARCHAR2(4000)` +- `exclude_schema_expr` - optional - regular expression to match against schema name to exclude in coverage - data-type `VARCHAR2(4000)` +- `exclude_object_expr` - optional - regular expression to match against object name to exclude in coverage - data-type `VARCHAR2(4000)` `coverage_run_id` parameter identifies a common coverage run. The valid value type for that parameter is RAW(32). It is recommended to use `sys_guid()` to generate a common, unique identifier for a specific coverage run. @@ -802,4 +810,10 @@ If the identifier is not unique, previous runs of coverage that used the same `c For details on the meaning of `schema_names`, `exclude_objects`, `include_objects`, `file_mappings` see sections above. Note that data-types of include/exclude/schema lists are different when calling `ut.run` vs. calling `get_report/get_report_cursor`. - + +The order of priority is for evaluation of include/exclude is as follows. +- if `file_mappings` is specified then all include/exclude parameters are ignored +- else if `..._expr` is specified then include_objects/exclude_objects parameters are ignored +- else if `schema_names` is specified then the coverage is gathered on all object of specified schemas +- else coverage is gathered on all schemas specified in paths passed to run procedure +- if no paths were specified, the coverage is gathered on current schema of the session running the tests From b430b437d8f7c98a54e082cc1260b93cec1d9d28 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 26 Feb 2022 01:36:19 +0200 Subject: [PATCH 285/887] Fixed typo in documentation --- docs/userguide/coverage.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 42f35c08a..663df7f3d 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -730,7 +730,7 @@ exec ut_runner.coverage_stop(); ```sql --SESSION 1 or SESSION2 2 or SESSION 3 --- run after calls in SESSION 1 & 2 are finshed +-- run after calls in SESSION 1 & 2 are finished -- retrieve coverage report in HTML format coverage_run_id value select * from table( @@ -744,7 +744,7 @@ select * ```sql --SESSION 1 or SESSION2 2 or SESSION 3 --- run after calls in SESSION 1 & 2 are finshed +-- run after calls in SESSION 1 & 2 are finished declare l_results_cursor sys_refcursor; begin From b8a3fb6c02e0e52dca57d608aab8f27647f0a62a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 26 Feb 2022 02:14:17 +0200 Subject: [PATCH 286/887] Adding COVERAGE_RUN_ID to the utPLSQL context to allow for more accurate coverage reporting when runnign tests against the coverage module of the framework. --- docs/userguide/annotations.md | 3 ++- source/core/session_context/ut_session_info.tpb | 2 ++ test/ut3_user/api/test_ut_run.pkb | 3 ++- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index d3ae90eca..72ae33e10 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -2121,7 +2121,8 @@ It can be accessed from any procecure invoked as part of utPLSQL test execution. > For example if utPLSQL is installed into `HR` schema, the context name will be `HR_INFO` Following attributes are populated: -- Always: +- For entire duration of the test-run: + - `sys_context( 'UT3_INFO', 'COVERAGE_RUN_ID' );` - Value of COVERAGE_RUN_ID used by utPLSQL internally for coverage gathering - `sys_context( 'UT3_INFO', 'RUN_PATHS' );` - list of suitepaths / suitenames used as input parameters for call to `ut.run(...)` or `ut_runner.run(...)` - `sys_context( 'UT3_INFO', 'SUITE_DESCRIPTION' );` - the description of test suite that is currently being executed - `sys_context( 'UT3_INFO', 'SUITE_PACKAGE' );` - the owner and name of test suite package that is currently being executed diff --git a/source/core/session_context/ut_session_info.tpb b/source/core/session_context/ut_session_info.tpb index c7fe7dc5f..7d469651a 100644 --- a/source/core/session_context/ut_session_info.tpb +++ b/source/core/session_context/ut_session_info.tpb @@ -28,12 +28,14 @@ create or replace type body ut_session_info as member procedure before_calling_run(self in out nocopy ut_session_info, a_run in ut_run) is begin ut_session_context.set_context( 'run_paths', ut_utils.to_string( ut_utils.table_to_clob( a_run.run_paths,',' ), null ) ); + ut_session_context.set_context( 'coverage_run_id', rawtohex( a_run.coverage_options.coverage_run_id ) ); dbms_application_info.set_module( 'utPLSQL', null ); end; member procedure after_calling_run(self in out nocopy ut_session_info, a_run in ut_run) is begin ut_session_context.clear_context( 'run_paths' ); + ut_session_context.clear_context( 'coverage_run_id' ); dbms_application_info.set_module( module, action ); dbms_application_info.set_client_info( client_info ); end; diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 8ec19f6d8..b4f5a5238 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1268,7 +1268,8 @@ Failures:% procedure sys_ctx_on_suite_beforeall is begin ut.expect(g_context_test_results).to_be_like( - '%BEFORE_SUITE:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.before_suite' + '%BEFORE_SUITE:COVERAGE_RUN_ID=________________________________%' + ||'%BEFORE_SUITE:CURRENT_EXECUTABLE_NAME='||gc_owner||'.check_context.before_suite' ||'%BEFORE_SUITE:CURRENT_EXECUTABLE_TYPE=beforeall' ||'%BEFORE_SUITE:RUN_PATHS=check_context' ||'%BEFORE_SUITE:SUITE_DESCRIPTION=Suite description' From 4602023a08403869b4b80124f7e24e08a67d514d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 26 Feb 2022 01:04:42 +0000 Subject: [PATCH 287/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 34f00c50c..ceff64be9 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 43a9c7144..110f3197c 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 48ece4cc6..7b4a67750 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 0da2b42fe..4fc3f72f7 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 2437aa9c1..f7b8f7a26 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index bfd2a13da..93da6013e 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 72ae33e10..af996f73c 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b4052a74a..b5b7cb286 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 813815239..3e541ffbe 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a78657be0..fd6cc6f98 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 91d8d02b3..1335b1d98 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 91099d1bb..b5b9d09f1 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 05fed3990..9f92b7c6a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index a4e8f1a5d..aac098805 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 1961e5f98..06eefcede 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index ba552ef2d..73e469da3 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 14ac4988c..f0ef68ab2 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3889--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 9d31d71b3..b9917f2a7 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.3889-develop'; + gc_version constant varchar2(50) := 'v3.1.13.3896-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From f3ea9e5c5859a271de0738d1db1c6b3fe6c46b3d Mon Sep 17 00:00:00 2001 From: Philipp Salvisberg Date: Sat, 26 Feb 2022 15:18:37 +0100 Subject: [PATCH 288/887] fix typo, "can be provided" instead of "can by provided" --- docs/userguide/annotations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index af996f73c..f28e0cd5b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -127,7 +127,7 @@ end; | `--%suite()` | Package | Mandatory. Marks package as a test suite. Optional suite description can be provided (see `displayname`). | | `--%suitepath()` | Package | Similar to java package. The annotation allows logical grouping of suites into hierarchies. | | `--%displayname()` | Package/procedure | Human-readable and meaningful description of a context/suite/test. Overrides the `` provided with `suite`/`test`/`context` annotation. This annotation is redundant and might be removed in future releases. | -| `--%test()` | Procedure | Denotes that the annotated procedure is a unit test procedure. Optional test description can by provided (see `displayname`). | +| `--%test()` | Procedure | Denotes that the annotated procedure is a unit test procedure. Optional test description can be provided (see `displayname`). | | `--%throws([,...])`| Procedure | Denotes that the annotated test procedure must throw one of the exceptions provided. Supported forms of exceptions are: numeric literals, numeric constant names, exception constant names, predefined Oracle exception names. | | `--%beforeall` | Procedure | Denotes that the annotated procedure should be executed once before all elements of the suite. | | `--%beforeall([[.].][,...])` | Package | Denotes that the mentioned procedure(s) should be executed once before all elements of the suite. | From 5ff7f44ee583b356e635949b95695933fa86927a Mon Sep 17 00:00:00 2001 From: Philipp Salvisberg Date: Sat, 26 Feb 2022 16:24:09 +0100 Subject: [PATCH 289/887] fix typo in expectations.md, whether instead of wheter --- docs/userguide/expectations.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 1335b1d98..3bd3e090b 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1096,7 +1096,7 @@ SUCCESS ## to_be_within of -Determines wheter expected value is within range (tolerance) from another value. +Determines whether expected value is within range (tolerance) from another value. The logical formual used for calcuating the matcher is: ``` @@ -1177,7 +1177,7 @@ Failures: ## to_be_within_pct of -Determines wheter actual value is within percentage range of expected value. +Determines whether actual value is within percentage range of expected value. The matcher only works with `number` data-type. The percentage deviation (distance) must be expressed as a non-negative number. From 4ab0f5875d3da51a8fdf17964f9018b71d04845b Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 26 Feb 2022 18:11:49 +0200 Subject: [PATCH 290/887] Added ability to publish coverage generated by test jobs running utPLSQL with coverage into main testing session coverage. --- source/api/ut_runner.pkb | 2 +- source/core/coverage/ut_coverage.pkb | 13 ++++- source/core/coverage/ut_coverage.pks | 2 + test/ut3_tester_helper/coverage_helper.pkb | 67 +++++++++++++++++++++- 4 files changed, 78 insertions(+), 6 deletions(-) diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index af168fe5d..cbf1971e7 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -127,7 +127,7 @@ create or replace package body ut_runner is l_run := ut_run( a_run_paths => l_paths, a_coverage_options => ut_coverage_options( - coverage_run_id => sys_guid(), + coverage_run_id => ut_coverage.get_coverage_run_id(), schema_names => l_coverage_schema_names, exclude_objects => ut_utils.convert_collection(a_exclude_objects), include_objects => ut_utils.convert_collection(a_include_objects), diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 06951fc2f..eeedfc665 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -18,6 +18,7 @@ create or replace package body ut_coverage is g_develop_mode boolean not null := false; g_is_started boolean not null := false; + g_coverage_run_id raw(32); procedure set_develop_mode(a_develop_mode in boolean) is begin @@ -231,6 +232,7 @@ create or replace package body ut_coverage is l_block_coverage_id integer; begin if not is_develop_mode() and not g_is_started then + g_coverage_run_id := a_coverage_run_id; l_line_coverage_id := ut_coverage_helper_profiler.coverage_start( l_run_comment ); l_block_coverage_id := ut_coverage_helper_block.coverage_start( l_run_comment ); g_is_started := true; @@ -256,7 +258,6 @@ create or replace package body ut_coverage is g_is_started := false; ut_coverage_helper_block.coverage_stop(); ut_coverage_helper_profiler.coverage_stop(); - g_is_started := false; end if; end; @@ -314,7 +315,15 @@ create or replace package body ut_coverage is $end return l_result_profiler_enrich; - end get_coverage_data; + end get_coverage_data; + + function get_coverage_run_id return raw is + begin + if g_coverage_run_id is null then + g_coverage_run_id := sys_guid(); + end if; + return g_coverage_run_id; + end; end; / diff --git a/source/core/coverage/ut_coverage.pks b/source/core/coverage/ut_coverage.pks index 210cb13f6..21f3b1f9e 100644 --- a/source/core/coverage/ut_coverage.pks +++ b/source/core/coverage/ut_coverage.pks @@ -74,5 +74,7 @@ create or replace package ut_coverage authid current_user is function get_coverage_data(a_coverage_options ut_coverage_options) return t_coverage; + function get_coverage_run_id return raw; + end; / diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 5f255a2e6..ab5a09515 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -381,14 +381,75 @@ create or replace package body coverage_helper is return l_result_clob; end; + procedure copy_coverage_data_to_ut3(a_coverage_run_id raw) is + pragma autonomous_transaction; + l_current_coverage_run_id raw(32) := hextoraw(sys_context('UT3_INFO','COVERAGE_RUN_ID')); + begin + insert into ut3.ut_coverage_runs(coverage_run_id, line_coverage_id, block_coverage_id) + select l_current_coverage_run_id, -line_coverage_id, -block_coverage_id + from ut3_develop.ut_coverage_runs + where coverage_run_id = a_coverage_run_id; + + insert into ut3.plsql_profiler_runs(runid, related_run, run_owner, run_date, run_comment, run_total_time, run_system_info, run_comment1, spare1) + select -runid, related_run, run_owner, run_date, run_comment, run_total_time, run_system_info, run_comment1, spare1 + from ut3_develop.plsql_profiler_runs c + join ut3_develop.ut_coverage_runs r + on r.line_coverage_id = c.runid + where r.coverage_run_id = a_coverage_run_id; + + insert into ut3.plsql_profiler_units(runid, unit_number, unit_type, unit_owner, unit_name, unit_timestamp, total_time, spare1, spare2) + select -runid, unit_number, unit_type, unit_owner, unit_name, unit_timestamp, total_time, spare1, spare2 + from ut3_develop.plsql_profiler_units c + join ut3_develop.ut_coverage_runs r + on r.line_coverage_id = c.runid + where r.coverage_run_id = a_coverage_run_id; + + insert into ut3.plsql_profiler_data(runid, unit_number, line#, total_occur, total_time, min_time, max_time, spare1, spare2, spare3, spare4) + select -runid, unit_number, line#, total_occur, total_time, min_time, max_time, spare1, spare2, spare3, spare4 + from ut3_develop.plsql_profiler_data c + join ut3_develop.ut_coverage_runs r + on r.line_coverage_id = c.runid + where r.coverage_run_id = a_coverage_run_id; + + insert into ut3.dbmspcc_runs(run_id, run_comment, run_owner, run_timestamp) + select -run_id, run_comment, run_owner, run_timestamp + from ut3_develop.dbmspcc_runs c + join ut3_develop.ut_coverage_runs r + on r.block_coverage_id = c.run_id + where r.coverage_run_id = a_coverage_run_id; + + insert into ut3.dbmspcc_units(run_id, object_id, owner, name, type, last_ddl_time) + select -run_id, object_id, owner, name, type, last_ddl_time + from ut3_develop.dbmspcc_units c + join ut3_develop.ut_coverage_runs r + on r.block_coverage_id = c.run_id + where r.coverage_run_id = a_coverage_run_id; + + insert into ut3.dbmspcc_blocks(run_id, object_id, block, line, col, covered, not_feasible) + select -run_id, object_id, block, line, col, covered, not_feasible + from ut3_develop.dbmspcc_blocks c + join ut3_develop.ut_coverage_runs r + on r.block_coverage_id = c.run_id + where r.coverage_run_id = a_coverage_run_id; + + commit; + end; + function run_tests_as_job( a_run_command varchar2 ) return clob is l_plsql_block varchar2(32767); l_result_clob clob; - pragma autonomous_transaction; + l_coverage_id raw(32) := sys_guid(); begin - l_plsql_block := 'begin insert into test_results select * from table( {a_run_command} ); commit; end;'; + l_plsql_block := q'[ + begin + ut3_develop.ut_runner.coverage_start(']'||rawtohex(l_coverage_id)||q'['); + insert into test_results select * from table( {a_run_command} ); + commit; + end;]'; l_plsql_block := replace(l_plsql_block,'{a_run_command}',a_run_command); - return run_code_as_job( l_plsql_block ); + l_result_clob := run_code_as_job( l_plsql_block ); + copy_coverage_data_to_ut3(l_coverage_id); + return l_result_clob; end; procedure create_dup_object_name is From 311d5a7250e94decfa79f3a65280153fe5fe95d3 Mon Sep 17 00:00:00 2001 From: Felipe Zorzo Date: Sat, 26 Feb 2022 16:18:03 -0300 Subject: [PATCH 291/887] Fix links to SonarCloud projects and SonarQube documentation --- docs/index.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/reporters.md | 2 +- readme.md | 2 +- source/reporters/ut_coverage_sonar_reporter.tpb | 6 +++--- source/reporters/ut_coverage_sonar_reporter.tps | 2 +- source/reporters/ut_coveralls_reporter.tps | 2 +- source/reporters/ut_sonar_test_reporter.tpb | 6 +++--- 8 files changed, 12 insertions(+), 12 deletions(-) diff --git a/docs/index.md b/docs/index.md index 537da5148..b079557ed 100644 --- a/docs/index.md +++ b/docs/index.md @@ -31,7 +31,7 @@ The framework follows industry standards and best patterns of modern Unit Testin Have a look at our [demo project](https://github.com/utPLSQL/utPLSQL-demo-project/). -It uses [Travis CI](https://travis-ci.org/utPLSQL/utPLSQL-demo-project) to build on every commit, runs all tests, publishes test results and code coverage to [SonarQube](https://sonarqube.com/dashboard?id=utPLSQL%3AutPLSQL-demo-project%3Adevelop). +It uses [Travis CI](https://travis-ci.org/utPLSQL/utPLSQL-demo-project) to build on every commit, runs all tests, publishes test results and code coverage to [SonarCloud](https://sonarcloud.io/project/overview?id=utPLSQL:utPLSQL-demo-project). # Three steps diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0fabf61bd..0da111301 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -17,7 +17,7 @@ To obtain information about code coverage for unit tests, run utPLSQL with one o The following code coverage reporters are supplied with utPLSQL: * `ut_coverage_html_reporter` - generates a HTML coverage report providing summary and detailed information on code coverage. The HTML reporter is based on the open-source [simplecov-html](https://github.com/colszowka/simplecov-html) reporter for Ruby. It includes source code of the code that was covered (if possible) * `ut_coveralls_reporter` - generates a [Coveralls compatible JSON](https://coveralls.zendesk.com/hc/en-us/articles/201774865-API-Introduction) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by cloud services like [Coveralls](https://coveralls.io) -* `ut_coverage_sonar_reporter` - generates a [Sonar Compatible XML](https://docs.sonarqube.org/display/SONAR/Generic+Test+Data) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by services like [SonarQube/SonarCloud](https://about.sonarcloud.io/) +* `ut_coverage_sonar_reporter` - generates a [Sonar Compatible XML](https://docs.sonarqube.org/latest/analysis/generic-test/) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by services like [SonarQube](https://www.sonarqube.org/) and [SonarCloud](https://about.sonarcloud.io/) * `ut_coverage_cobertura_reporter` - generates a basic Cobertura coverage (http://cobertura.sourceforge.net/xml/coverage-04.dtd) report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by services like TFS and Jenkins. Check this link for an example of XML generated by Java: https://raw.githubusercontent.com/jenkinsci/cobertura-plugin/master/src/test/resources/hudson/plugins/cobertura/coverage-with-data.xml ## Security model diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ebc28ec38..176027a99 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -84,7 +84,7 @@ Example of failure report details # Sonar test reporter -If you are using [SonarQube](https://about.sonarqube.com/) to do static code analysis for you PLSQL projects, your code analysis can benefit from code coverage and test results. +If you are using [SonarQube](https://www.sonarqube.org/) or [SonarCloud](https://about.sonarcloud.io/) to do static code analysis for you PLSQL projects, your code analysis can benefit from code coverage and test results. utPLSQL provides two reporters to for SonarQube: - `ut_sonar_test_reporter` - provides an XML output of each test executed per each project test file (package) - `ut_coverage_sonar_reporter` - provides XML output of code coverage per each project source file diff --git a/readme.md b/readme.md index f96b88d7f..141c68ffe 100644 --- a/readme.md +++ b/readme.md @@ -9,7 +9,7 @@ [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) [![build](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml/badge.svg)](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml) -[![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=sqale_rating)](https://sonarcloud.io/dashboard/index?id=utPLSQL) +[![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=sqale_rating)](https://sonarcloud.io/summary/new_code?id=utPLSQL) [![Coverage](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=coverage)](https://sonarcloud.io/summary/new_code?id=utPLSQL) ---------- diff --git a/source/reporters/ut_coverage_sonar_reporter.tpb b/source/reporters/ut_coverage_sonar_reporter.tpb index 4bde1a88d..8ee78dc24 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tpb +++ b/source/reporters/ut_coverage_sonar_reporter.tpb @@ -96,9 +96,9 @@ create or replace type body ut_coverage_sonar_reporter is overriding member function get_description return varchar2 as begin - return 'Generates a JSON coverage report providing information on code coverage with line numbers.' || chr(10) || - 'Designed for [SonarQube](https://about.sonarqube.com/) to report coverage.' || chr(10) || - 'JSON format returned conforms with the Sonar specification: https://docs.sonarqube.org/display/SONAR/Generic+Test+Data'; + return 'Generates a XML coverage report providing information on code coverage with line numbers.' || chr(10) || + 'Designed for [SonarQube](https://www.sonarqube.org/) to report coverage.' || chr(10) || + 'XML format returned conforms with the Sonar specification: https://docs.sonarqube.org/latest/analysis/generic-test/'; end; end; diff --git a/source/reporters/ut_coverage_sonar_reporter.tps b/source/reporters/ut_coverage_sonar_reporter.tps index f3076368f..715bdefd2 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tps +++ b/source/reporters/ut_coverage_sonar_reporter.tps @@ -18,7 +18,7 @@ create or replace type ut_coverage_sonar_reporter under ut_coverage_reporter_bas /** * Builds a coverage XML report that follows rules described in - * https://docs.sonarqube.org/display/SONAR/Generic+Test+Data + * https://docs.sonarqube.org/latest/analysis/generic-test/ */ constructor function ut_coverage_sonar_reporter( self in out nocopy ut_coverage_sonar_reporter diff --git a/source/reporters/ut_coveralls_reporter.tps b/source/reporters/ut_coveralls_reporter.tps index f3cad3a4e..74363b751 100644 --- a/source/reporters/ut_coveralls_reporter.tps +++ b/source/reporters/ut_coveralls_reporter.tps @@ -18,7 +18,7 @@ create or replace type ut_coveralls_reporter under ut_coverage_reporter_base( /** * Builds a coverage XML report that follows rules described in - * https://docs.sonarqube.org/display/SONAR/Generic+Test+Data + * https://docs.coveralls.io/api-introduction */ constructor function ut_coveralls_reporter( self in out nocopy ut_coveralls_reporter diff --git a/source/reporters/ut_sonar_test_reporter.tpb b/source/reporters/ut_sonar_test_reporter.tpb index 20624fae9..a3ec72241 100644 --- a/source/reporters/ut_sonar_test_reporter.tpb +++ b/source/reporters/ut_sonar_test_reporter.tpb @@ -106,9 +106,9 @@ create or replace type body ut_sonar_test_reporter is overriding member function get_description return varchar2 as begin - return 'Generates a JSON report providing detailed information on test execution.' || chr(10) || - 'Designed for [SonarQube](https://about.sonarqube.com/) to report test execution.' || chr(10) || - 'JSON format returned conforms with the Sonar specification: https://docs.sonarqube.org/display/SONAR/Generic+Test+Data'; + return 'Generates a XML report providing detailed information on test execution.' || chr(10) || + 'Designed for [SonarQube](https://www.sonarqube.org/) to report test execution.' || chr(10) || + 'XML format returned conforms with the Sonar specification: https://docs.sonarqube.org/latest/analysis/generic-test/'; end; end; From 25af9edbcd5b7a9627c667225105bf70ede6a010 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 26 Feb 2022 22:11:18 +0000 Subject: [PATCH 292/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index ceff64be9..c8e1f017a 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 110f3197c..7b95eee4f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 7b4a67750..2e0d31c99 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 4fc3f72f7..5cbe4dbda 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 2380c0473..695a3e0fb 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 93da6013e..6f382970a 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index f28e0cd5b..192ea7b8d 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b5b7cb286..4c203e73d 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index f6cdcbc93..2c59a8126 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index fd6cc6f98..484681b9b 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3bd3e090b..1000b7747 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index b5b9d09f1..548359f7f 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 9f92b7c6a..c4c5ac903 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index aac098805..e8d36cd72 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 1e0f134b6..5777b36b0 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 73e469da3..4bbd665cd 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index f0ef68ab2..631dc1d56 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3896--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index b9917f2a7..8ef9cff39 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.3896-develop'; + gc_version constant varchar2(50) := 'v3.1.13.3905-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 969f52ee0b374a3a491526f49dad09baa9724629 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 27 Feb 2022 00:26:52 +0200 Subject: [PATCH 293/887] Testing local html validator (as a container) --- .github/scripts/validate_report_files.sh | 2 +- .github/workflows/build.yml | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/scripts/validate_report_files.sh b/.github/scripts/validate_report_files.sh index 59376a174..722a9220a 100755 --- a/.github/scripts/validate_report_files.sh +++ b/.github/scripts/validate_report_files.sh @@ -7,7 +7,7 @@ XSD_DIR="${SCRIPT_DIR}/xsd" XML_JAR_DIR="${SCRIPT_DIR}/lib" #XML Validator XML_VALIDATOR="$XML_JAR_DIR/xml_validator.jar" -HTML_VALIDATOR_URL="https://validator.w3.org/nu/" +HTML_VALIDATOR_URL="http://localhost:8888/" HTML_FILENAME="coverage.html" declare -A XML_FILES diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index cf36d4c55..816f0ab39 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -60,6 +60,10 @@ jobs: oracle-base: '/opt/oracle' services: + html_checker: + image: ghcr.io/validator/validator:latest + options: >- + -p 8888:8888 oracle: image: ${{matrix.oracle-version}} env: From b4d72e391f2e7f5d920ec08744a30431ef201027 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 26 Feb 2022 23:07:21 +0000 Subject: [PATCH 294/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index c8e1f017a..002c7ee3b 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 7b95eee4f..fa782b2ad 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 2e0d31c99..400ead44a 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 5cbe4dbda..11beecd51 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 695a3e0fb..89c4b41b4 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 6f382970a..d7c5b6bb0 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 192ea7b8d..c36b06450 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 4c203e73d..35485e4db 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 2c59a8126..664fb78cb 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 484681b9b..dbd70d9a0 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 1000b7747..96fd4e2c4 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 548359f7f..548994f5b 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index c4c5ac903..88b4d0942 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index e8d36cd72..6140f2cc7 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 5777b36b0..a6f37d0a6 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 4bbd665cd..88fa7ad0c 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 631dc1d56..1cc6dd58b 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3905--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 8ef9cff39..a19bd82dd 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.3905-develop'; + gc_version constant varchar2(50) := 'v3.1.13.3908-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From a84246be72ffa0196d4ebb408b1afda0966158c9 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 27 Feb 2022 17:47:35 +0000 Subject: [PATCH 295/887] Adding extra tests for code coverage --- source/core/coverage/ut_coverage.pkb | 4 +- test/ut3_tester_helper/coverage_helper.pkb | 40 +++++++++ test/ut3_tester_helper/coverage_helper.pks | 1 + .../test_coverage/test_extended_coverage.pkb | 84 ++++++++++++++++++- .../test_coverage/test_extended_coverage.pks | 28 ++++++- 5 files changed, 149 insertions(+), 8 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index eeedfc665..b606a6dc1 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -102,7 +102,7 @@ create or replace package body ut_coverage is on s.name = f.object_name and s.type = f.object_type and s.owner = f.object_owner'; - elsif a_coverage_options.include_schema_expr is not null or a_coverage_options.include_object_expr is not null then + elsif coalesce(a_coverage_options.include_schema_expr,a_coverage_options.include_object_expr) is not null then l_full_name := q'[lower(s.type||' '||s.owner||'.'||s.name)]'; if a_coverage_options.include_schema_expr is not null then l_filters := q'[and regexp_like(s.owner,:a_include_schema_expr,'i')]'; @@ -183,7 +183,7 @@ create or replace package body ut_coverage is open l_cursor for l_sql using a_coverage_options.file_mappings,a_coverage_options.exclude_schema_expr, a_coverage_options.exclude_object_expr,l_excluded_objects, l_skip_objects; - elsif a_coverage_options.include_schema_expr is not null or a_coverage_options.include_object_expr is not null then + elsif coalesce(a_coverage_options.include_schema_expr,a_coverage_options.include_object_expr) is not null then open l_cursor for l_sql using a_coverage_options.include_schema_expr,a_coverage_options.include_object_expr, a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr, l_excluded_objects,l_skip_objects; diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index ab5a09515..e59fde122 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -435,6 +435,46 @@ create or replace package body coverage_helper is commit; end; + function gather_coverage_on_coverage( a_cov_options varchar2) return clob is + pragma autonomous_transaction; + l_plsql_block varchar2(32767); + l_result_clob clob; + l_coverage_id raw(32) := sys_guid(); + begin + l_plsql_block := q'[ + declare + l_coverage_options ut3_develop.ut_coverage_options; + l_coverage_run_id raw(32) := ']'||rawtohex(l_coverage_id)||q'['; + l_result ut3_develop.ut_coverage.t_coverage; + begin + ut3_develop.ut_runner.coverage_start(l_coverage_run_id); + ut3_develop.ut_coverage.set_develop_mode(a_develop_mode => true); + l_coverage_options := {a_cov_options}; + l_result := ut3_develop.ut_coverage.get_coverage_data(l_coverage_options); + ut3_develop.ut_coverage.set_develop_mode(a_develop_mode => false); + ut3_develop.ut_runner.coverage_stop(); + insert into test_results select owner||'.'||name from ut3_develop.ut_coverage_sources_tmp; + commit; + end;]'; + l_plsql_block := replace(l_plsql_block,'{a_cov_options}',a_cov_options); + run_job_and_wait_for_finish( l_plsql_block ); + execute immediate q'[ + declare + l_results ut3_develop.ut_varchar2_list; + begin + select * + bulk collect into l_results + from test_results; + delete from test_results; + commit; + :clob_results := ut3_tester_helper.main_helper.table_to_clob(l_results); + end; + ]' + using out l_result_clob; + copy_coverage_data_to_ut3(l_coverage_id); + return l_result_clob; + end; + function run_tests_as_job( a_run_command varchar2 ) return clob is l_plsql_block varchar2(32767); l_result_clob clob; diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index c5e862612..8d2c1c150 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -23,6 +23,7 @@ create or replace package coverage_helper is procedure run_standalone_coverage(a_coverage_run_id raw, a_input integer); procedure run_coverage_job(a_coverage_run_id raw, a_input integer); + function gather_coverage_on_coverage( a_cov_options varchar2) return clob; function run_tests_as_job( a_run_command varchar2 ) return clob; function run_code_as_job( a_plsql_block varchar2 ) return clob; procedure create_test_results_table; diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index f14eac984..d22570df0 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -141,7 +141,7 @@ create or replace package body test_extended_coverage is --Arrange l_expected := '%' || '%%'; - l_not_expected := '%' || + l_not_expected := '%' || '%%'; --Act l_actual := @@ -195,7 +195,7 @@ create or replace package body test_extended_coverage is --Arrange l_expected := '%' || '%%'; - l_not_expected := '%' || + l_not_expected := '%' || '%%'; --Act l_actual := @@ -214,5 +214,85 @@ create or replace package body test_extended_coverage is ut.expect(l_actual).not_to_be_like(l_not_expected); end; + procedure cove_rgx_inc_schema_norun is + l_expected clob; + l_not_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%UT3_DEVELOP.REGEX_DUMMY_COV%'; + l_not_expected := '%UT3_TESTER_HELPER.REGEX123_DUMMY_COV%'; + --Act + l_actual := ut3_tester_helper.coverage_helper.gather_coverage_on_coverage( + q'[ut3_develop.ut_coverage_options( + coverage_run_id => l_coverage_run_id, + include_schema_expr => '^ut3_develop' + )]'); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_like(l_not_expected); + end; + + procedure cove_rgx_inc_object_norun is + l_expected clob; + l_not_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%UT3_DEVELOP.REGEX123_DUMMY_COV%'; + l_not_expected := '%UT3_DEVELOP.REGEX_DUMMY_COV%'; + --Act + l_actual := ut3_tester_helper.coverage_helper.gather_coverage_on_coverage( + q'[ut3_develop.ut_coverage_options( + coverage_run_id => l_coverage_run_id, + include_object_expr => 'regex123' + )]'); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_like(l_not_expected); + end; + + procedure cove_rgx_exc_schema_norun is + l_expected clob; + l_not_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%UT3_DEVELOP.REGEX_DUMMY_COV%'; + l_not_expected := '%UT3_TESTER_HELPER.REGEX_DUMMY_COV%'; + --Act + l_actual := ut3_tester_helper.coverage_helper.gather_coverage_on_coverage( + q'[ut3_develop.ut_coverage_options( + coverage_run_id => l_coverage_run_id, + schema_names => ut3_develop.ut_varchar2_rows( 'UT3_DEVELOP','UT3_TESTER_HELPER' ), + exclude_schema_expr => '^ut3_tester', + exclude_objects => ut3_develop.ut_varchar2_rows( 'ut3_develop.regex_dummy_cov' ) + )]'); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_like(l_not_expected); + end; + + procedure cove_rgx_exc_object_norun is + l_expected clob; + l_not_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%UT3_DEVELOP.REGEX_DUMMY_COV%'; + l_not_expected := '%UT3_DEVELOP.REGEX123_DUMMY_COV%'; + --Act + l_actual := ut3_tester_helper.coverage_helper.gather_coverage_on_coverage( + q'[ut3_develop.ut_coverage_options( + coverage_run_id => l_coverage_run_id, + schema_names => ut3_develop.ut_varchar2_rows( 'UT3_DEVELOP' ), + exclude_object_expr => 'regex123', + exclude_objects => ut3_develop.ut_varchar2_rows( 'ut3_develop.regex_dummy_cov' ) + )]'); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_like(l_not_expected); + end; + end; / diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks index 99d7c5db4..108c5ae52 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks @@ -20,23 +20,43 @@ create or replace package test_extended_coverage is --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) - --%test(Collect coverage for objects with schema regex include) + --%test(Collect coverage for objects with schema regex include with ut_run) procedure coverage_regex_include_schema; --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) - --%test(Collect coverage for objects with object regex include) + --%test(Collect coverage for objects with object regex include with ut_run) procedure coverage_regex_include_object; --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) - --%test(Collect coverage for objects with schema regex exclude) + --%test(Collect coverage for objects with schema regex exclude with ut_run) procedure coverage_regex_exclude_schema; --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) - --%test(Collect coverage for objects with object regex exclude) + --%test(Collect coverage for objects with object regex exclude with ut_run) procedure coverage_regex_exclude_object; + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) + --%test(Collect coverage for objects with schema regex include without ut_run) + procedure cove_rgx_inc_schema_norun; + + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) + --%test(Collect coverage for objects with object regex include without ut_run) + procedure cove_rgx_inc_object_norun; + + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) + --%test(Collect coverage for objects with schema regex exclude without ut_run) + procedure cove_rgx_exc_schema_norun; + + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) + --%test(Collect coverage for objects with object regex exclude without ut_run) + procedure cove_rgx_exc_object_norun; + end; / From 090207c6dadf985d9c88ec646c0fee327785d5fd Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 27 Feb 2022 19:52:16 +0000 Subject: [PATCH 296/887] Added extra coverage for file mapping. --- .../test_coverage/test_extended_coverage.pkb | 17 +++++++++++++++++ .../test_coverage/test_extended_coverage.pks | 4 ++++ 2 files changed, 21 insertions(+) diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index d22570df0..3c8781bc4 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -294,5 +294,22 @@ create or replace package body test_extended_coverage is ut.expect(l_actual).not_to_be_like(l_not_expected); end; + procedure cov_file_mapping_no_utrun is + l_expected clob; + l_not_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%UT3_DEVELOP.REGEX_DUMMY_COV%'; + --Act + l_actual := ut3_tester_helper.coverage_helper.gather_coverage_on_coverage( + q'[ut3_develop.ut_coverage_options( + coverage_run_id => l_coverage_run_id, + file_mappings => ut3_develop.ut_file_mappings( ut3_develop.ut_file_mapping('C:\tests\helpers\core.pkb','UT3_DEVELOP','REGEX_DUMMY_COV','PACKAGE BODY')) + )]'); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + end; + end; / diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks index 108c5ae52..82b19fbed 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pks @@ -58,5 +58,9 @@ create or replace package test_extended_coverage is --%test(Collect coverage for objects with object regex exclude without ut_run) procedure cove_rgx_exc_object_norun; + --%beforetest(ut3_tester_helper.coverage_helper.create_regex_dummy_cov) + --%aftertest(ut3_tester_helper.coverage_helper.drop_regex_dummy_cov) + --%test(Collect coverage for file mapping without ut_run) + procedure cov_file_mapping_no_utrun; end; / From df31fba9decf27bd5308a1df49655200de5238b1 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 28 Feb 2022 01:45:42 +0200 Subject: [PATCH 297/887] g_coverage_run_id is now reset after coverage collection is stopped. --- source/core/coverage/ut_coverage.pkb | 1 + 1 file changed, 1 insertion(+) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index b606a6dc1..1bd88a186 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -256,6 +256,7 @@ create or replace package body ut_coverage is begin if not is_develop_mode() then g_is_started := false; + g_coverage_run_id := null; ut_coverage_helper_block.coverage_stop(); ut_coverage_helper_profiler.coverage_stop(); end if; From 0a2f478aa0c68753be358db0c9a4857a25c1361b Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 28 Feb 2022 01:47:10 +0200 Subject: [PATCH 298/887] Improved coverage collection scope and stability on self-tests for utPLSQL --- test/ut3_tester_helper/coverage_helper.pkb | 22 +++++++++++++------ .../test_coverage/test_proftab_coverage.pkb | 4 ++-- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index e59fde122..fdfa32364 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -341,7 +341,7 @@ create or replace package body coverage_helper is e_exists exception; pragma exception_init ( e_exists, -955 ); begin - execute immediate 'create table test_results (text varchar2(4000))'; + execute immediate 'create table test_results (id integer, text varchar2(4000))'; exception when e_exists then null; @@ -368,9 +368,10 @@ create or replace package body coverage_helper is declare l_results ut3_develop.ut_varchar2_list; begin - select * + select text bulk collect into l_results - from test_results; + from test_results + order by id; delete from test_results; commit; :clob_results := ut3_tester_helper.main_helper.table_to_clob(l_results); @@ -453,7 +454,7 @@ create or replace package body coverage_helper is l_result := ut3_develop.ut_coverage.get_coverage_data(l_coverage_options); ut3_develop.ut_coverage.set_develop_mode(a_develop_mode => false); ut3_develop.ut_runner.coverage_stop(); - insert into test_results select owner||'.'||name from ut3_develop.ut_coverage_sources_tmp; + insert into test_results select rownum, owner||'.'||name from ut3_develop.ut_coverage_sources_tmp; commit; end;]'; l_plsql_block := replace(l_plsql_block,'{a_cov_options}',a_cov_options); @@ -462,9 +463,10 @@ create or replace package body coverage_helper is declare l_results ut3_develop.ut_varchar2_list; begin - select * + select text bulk collect into l_results - from test_results; + from test_results + order by id; delete from test_results; commit; :clob_results := ut3_tester_helper.main_helper.table_to_clob(l_results); @@ -483,7 +485,13 @@ create or replace package body coverage_helper is l_plsql_block := q'[ begin ut3_develop.ut_runner.coverage_start(']'||rawtohex(l_coverage_id)||q'['); - insert into test_results select * from table( {a_run_command} ); + ut3_develop.ut_coverage.set_develop_mode(a_develop_mode => true); + --gather coverage on the command executed + begin {a_run_command}; end; + ut3_develop.ut_coverage.set_develop_mode(a_develop_mode => false); + ut3_develop.ut_runner.coverage_stop(); + --get the actual results of the command gathering the coverage + insert into test_results select rownum as id, x.* from table( {a_run_command} ) x; commit; end;]'; l_plsql_block := replace(l_plsql_block,'{a_run_command}',a_run_command); diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index 7256fc202..7cad0a67e 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -137,14 +137,14 @@ create or replace package body test_proftab_coverage is --Act insert into test_results - select * + select rownum, x.* from table( ut3_develop.ut.run( a_path => 'ut3_develop:coverage_testing', a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.{p}' ) ) - ); + ) x; commit; end; ]'; From bd05e4cb19ea7a77ad1bc629124e58a714c13226 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 2 Mar 2022 01:23:47 +0200 Subject: [PATCH 299/887] Coverage documentation improvements. Fixed datatype for ut_coverage_options.tps attributes Formatting. --- docs/userguide/coverage.md | 122 ++++++++++++++-------- source/core/coverage/ut_coverage.pkb | 21 ++-- source/core/types/ut_coverage_options.tps | 8 +- 3 files changed, 91 insertions(+), 60 deletions(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index b09eaf124..26b00bd85 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,7 +1,7 @@ ![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) # Coverage -utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses DBMS_PROFILER package provided with Oracle database. +utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: * package bodies * type bodies @@ -15,7 +15,7 @@ Code coverage is gathered for the following source types: To obtain information about code coverage for unit tests, run utPLSQL with one of built-in code coverage reporters. The following code coverage reporters are supplied with utPLSQL: -* `ut_coverage_html_reporter` - generates a HTML coverage report providing summary and detailed information on code coverage. The HTML reporter is based on the open-source [simplecov-html](https://github.com/colszowka/simplecov-html) reporter for Ruby. It includes source code of the code that was covered (if possible) +* `ut_coverage_html_reporter` - generates a HTML coverage report providing summary and detailed information on code coverage. The HTML reporter is based on the open-source [simplecov-html](https://github.com/colszowka/simplecov-html) reporter for Ruby. It includes source code of the code that was covered (if the code is accessible for test user) * `ut_coveralls_reporter` - generates a [Coveralls compatible JSON](https://coveralls.zendesk.com/hc/en-us/articles/201774865-API-Introduction) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by cloud services like [Coveralls](https://coveralls.io) * `ut_coverage_sonar_reporter` - generates a [Sonar Compatible XML](https://docs.sonarqube.org/latest/analysis/generic-test/) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by services like [SonarQube](https://www.sonarqube.org/) and [SonarCloud](https://about.sonarcloud.io/) * `ut_coverage_cobertura_reporter` - generates a basic Cobertura coverage (http://cobertura.sourceforge.net/xml/coverage-04.dtd) report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by services like TFS and Jenkins. Check this link for an example of XML generated by Java: https://raw.githubusercontent.com/jenkinsci/cobertura-plugin/master/src/test/resources/hudson/plugins/cobertura/coverage-with-data.xml @@ -30,7 +30,7 @@ In order to be able to gather coverage information, the user executing unit test If you have `execute` privilege on the code that is being tested, but do not have `create any procedure` system privilege, then the code that is being tested will be reported as not covered (coverage = 0%). If you have `execute` privilege only on the unit tests, but do not have `execute` privilege on the code that is being tested, the code will not be reported by coverage - as if it did not exist in the database. -If the code that is being tested is complied as NATIVE, the code coverage will not be reported as well. +If the code that is being tested is compiled as NATIVE, the code coverage will not be reported as well. ## Running unit tests with coverage Using the code coverage functionality is as easy as using any other [reporter](reporters.md) for the utPLSQL test-run. You just run your tests from your preferred SQL tool and save the reporter results to a file. @@ -65,6 +65,7 @@ Due to security model of `dbms_plsql_code_coverage` package, utPLSQL grants acce The access and synonyms will be public when using the headless installation. This approach avoids complexity of forcing every user of utPLSQL framework to create tables on their own. Sample output: + ![Package Coverage Summary](../images/extended_coverage_html_summary.png) ![Line Coverage Details](../images/extended_coverage_html_line.png) @@ -128,42 +129,80 @@ exec ut.run('unit_test_schema', ut_coverage_html_reporter(), a_coverage_schemes #### Filtering objects in coverage reports -There are six options that can be used to narrow down the scope of coverage report: -- `a_include_objects` - list of `[object_owner.].object_name` to be included in the coverage report. -- `a_exclude_objects` - list of `[object_owner.].object_name` to be excluded from the coverage report -- `a_include_schema_expr` - string of regex expression of schemas to be included in the coverage report. It will override `a_include_objects` for example : - ```sql - a_include_schema_expr => '^ut3_develop', - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) - ``` - Will result in showing coverage for all schemas that match regular expression `^ut3_develop` and ignore objectes defined by parameter `a_include_objects` - -- `a_include_object_expr` - string of regex expression of objects ( no schema names included ) to be included in the coverage report. It will override `a_include_objects` for example: - ```sql - a_include_object_expr => 'regex123', - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) - ``` - Will result in showing coverage for all objects that name match regular expression `regex123` and ignore objectes defined by parameter `a_include_objects` - -- `a_exclude_schema_expr` - string of regex expression of schemas to be excluded from the coverage report. It will override `a_exclude_objects` for example: - ```sql - a_exclude_schema_expr => '^ut3_tester', - a_exclude_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.regex_dummy_cov' ) - ``` - Will result in showing coverage for all objects that schema is not matching regular expression `^ut3_tester` and ignore exclusion defined by parameter `a_exclude_objects` - -- `a_exclude_object_expr` - string of regex expression of objects to be excluded from the coverage report. It will override `a_exclude_objects` for example - ```sql - a_exclude_object_expr => 'regex123', - a_exclude_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.regex_dummy_cov' ) - ``` - Will result in showing coverage for all objects that name is not matching regular expression `regex123` and ignore exclusion defined by parameter `a_exclude_objects` - +There are multiple parameters that can be used to define the scope of coverage report: +- `a_source_file_mappings ( ut_file_mappings )` - map of filenames to database objects. It is used for file-based coverage - see below. +- `a_include_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be included in the coverage report. +- `a_include_object_expr ( varchar(4000) )` - string of regex expression of objects ( without schema name ) to be included in the coverage report. +- `a_exclude_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be excluded from the coverage report. +- `a_exclude_object_expr ( varchar(4000) )` - string of regex expression of objects to be excluded from the coverage report. +- `a_coverage_schemes ( ut_varchar2_list )` - List of database schema names to gather coverage on. +- `a_include_objects ( ut_varchar2_list )` - list of `[object_owner.]object_name` to be included in the coverage report. +- `a_exclude_objects ( ut_varchar2_list )` - list of `[object_owner.]object_name` to be excluded from the coverage report. You may specify both _include_ and _exclude_ options to gain more control over what needs to be included / excluded from the coverage report. -The object owner is optional in the object list. -If you do not provide an object owner, the _include_/_exclude_ list will be considered for every schema used for coverage gathering (as described above). +**Important notes** +The order of priority is for evaluation of include/exclude filter parameters is as follows. +- if `a_source_file_mappings` is defined then all include/exclude parameters are ignored (see section below for usage of `a_source_file_mappings` parameter ) +- else if `a_include_schema_expr` or `a_include_object_expr` parameter is specified then parameters `a_coverage_schemes` and `a_include_objects` are ignored +- else if `a_include_objects` is specified then the coverage is gathered only on specified database objects. + - if `a_coverage_schemes` is specified then those schemas are used for objects in `a_include_objects` without schema name + - if `a_coverage_schemes` is not specified then schema from paths (`a_paths`) parameter are used for objects in `a_include_objects` without schema name +- else if, only the `a_coverage_schemes` is specified then the coverage is gathered only on specified database schemas +- else if no coverage specific parameters are provided coverage is gathered on all schemas specified in paths passed to run procedure +- else if no paths were specified, the coverage is gathered on current schema of the session running the tests + + +Example: Limiting coverage by schema regex. +```sql +begin + ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), + a_include_schema_expr => '^ut3_develop' + ); +end; +``` +Will result in showing coverage for all schemas that match regular expression `^ut3_develop` + +```sql +begin + ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), + a_include_schema_expr => '^ut3_develop', a_include_objects => ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) + ); +end; +``` +Will result in showing coverage for all schemas that match regular expression `^ut3_develop`. +Will ignore the `a_include_objects` parameter + +```sql +begin + ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), + a_include_object_expr => 'regex123', a_include_objects => ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) + ); +end; +``` +Will result in showing coverage for all objects that name match regular expression `regex123`. +Will ignore the `a_include_objects` parameter. + +```sql +begin + ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), + a_exclude_schema_expr => '^ut3_tester', a_exclude_objects => ut_varchar2_list( 'regex_dummy_cov' ) + ); +end; +``` +Will result in showing coverage for objects in all schema except schemas that are matching regular expression `^ut3_tester` +Will ignore exclusion defined by parameter `a_exclude_objects` + +```sql +begin + ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), + a_exclude_object_expr => 'regex123', a_exclude_objects => ut_varchar2_list( 'regex_dummy_cov' ) + ); +end; +``` +Will result in showing coverage for all objects that name is not matching regular expression `regex123`. +Will ignore exclusion defined by parameter `a_exclude_objects`. + Example: Limiting coverage by object name, for tested code located in the same schema as the unit tests. ```sql @@ -214,7 +253,8 @@ Executes test `test_award_bonus` in schema `unit_test_schema`. Coverage will be **Note** > When running coverage on schema objects, all source code of package bodies, functions, procedures, type bodies and triggers that were not executed will be reported as having 0% code coverage and all source code lines will show as uncovered. -> This is different than the behavior when gathering coverage on project files. +> This is different from the behavior when gathering coverage on project files. + ### Project based Coverage @@ -687,7 +727,7 @@ begin end; ``` -## Reporting coverage outside of utPLSQL +## Reporting coverage outside utPLSQL and in parallel sessions utPSLQL allows fo standalone reporting code coverage across multiple database sessions. This functionality enables coverage reporting for external testing tools. @@ -811,9 +851,3 @@ If the identifier is not unique, previous runs of coverage that used the same `c For details on the meaning of `schema_names`, `exclude_objects`, `include_objects`, `file_mappings` see sections above. Note that data-types of include/exclude/schema lists are different when calling `ut.run` vs. calling `get_report/get_report_cursor`. -The order of priority is for evaluation of include/exclude is as follows. -- if `file_mappings` is specified then all include/exclude parameters are ignored -- else if `..._expr` is specified then include_objects/exclude_objects parameters are ignored -- else if `schema_names` is specified then the coverage is gathered on all object of specified schemas -- else coverage is gathered on all schemas specified in paths passed to run procedure -- if no paths were specified, the coverage is gathered on current schema of the session running the tests diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 1bd88a186..f5eccc893 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -180,21 +180,18 @@ create or replace package body ut_coverage is ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_key_anyvalues().put('l_sql',l_sql) ); if a_coverage_options.file_mappings is not empty then - open l_cursor for l_sql using a_coverage_options.file_mappings,a_coverage_options.exclude_schema_expr, - a_coverage_options.exclude_object_expr,l_excluded_objects, - l_skip_objects; + open l_cursor for l_sql using a_coverage_options.file_mappings, a_coverage_options.exclude_schema_expr, + a_coverage_options.exclude_object_expr, l_excluded_objects, l_skip_objects; elsif coalesce(a_coverage_options.include_schema_expr,a_coverage_options.include_object_expr) is not null then - open l_cursor for l_sql using a_coverage_options.include_schema_expr,a_coverage_options.include_object_expr, - a_coverage_options.exclude_schema_expr,a_coverage_options.exclude_object_expr, - l_excluded_objects,l_skip_objects; + open l_cursor for l_sql using a_coverage_options.include_schema_expr, a_coverage_options.include_object_expr, + a_coverage_options.exclude_schema_expr, a_coverage_options.exclude_object_expr, + l_excluded_objects, l_skip_objects; elsif a_coverage_options.include_objects is not empty then - open l_cursor for l_sql using a_coverage_options.include_objects,a_coverage_options.exclude_schema_expr, - a_coverage_options.exclude_object_expr,l_excluded_objects, - l_skip_objects; + open l_cursor for l_sql using a_coverage_options.include_objects, a_coverage_options.exclude_schema_expr, + a_coverage_options.exclude_object_expr, l_excluded_objects, l_skip_objects; else - open l_cursor for l_sql using a_coverage_options.schema_names,a_coverage_options.exclude_schema_expr, - a_coverage_options.exclude_object_expr,l_excluded_objects, - l_skip_objects; + open l_cursor for l_sql using a_coverage_options.schema_names, a_coverage_options.exclude_schema_expr, + a_coverage_options.exclude_object_expr, l_excluded_objects, l_skip_objects; end if; return l_cursor; end; diff --git a/source/core/types/ut_coverage_options.tps b/source/core/types/ut_coverage_options.tps index 245539179..a8e3d5129 100644 --- a/source/core/types/ut_coverage_options.tps +++ b/source/core/types/ut_coverage_options.tps @@ -21,10 +21,10 @@ create or replace type ut_coverage_options force as object ( exclude_objects ut_object_names, include_objects ut_object_names, file_mappings ut_file_mappings, - include_schema_expr varchar2(32767), - include_object_expr varchar2(32767), - exclude_schema_expr varchar2(32767), - exclude_object_expr varchar2(32767), + include_schema_expr varchar2(4000), + include_object_expr varchar2(4000), + exclude_schema_expr varchar2(4000), + exclude_object_expr varchar2(4000), constructor function ut_coverage_options( self in out nocopy ut_coverage_options, coverage_run_id raw, From 3b9b6260a75d47332611bce939f317b295a36ba7 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 2 Mar 2022 01:26:48 +0200 Subject: [PATCH 300/887] Coverage documentation improvements. --- docs/userguide/coverage.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 26b00bd85..20210ab47 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -152,6 +152,7 @@ The order of priority is for evaluation of include/exclude filter parameters is - else if no coverage specific parameters are provided coverage is gathered on all schemas specified in paths passed to run procedure - else if no paths were specified, the coverage is gathered on current schema of the session running the tests +The exclude parameters are not mutually-exclusive and can be mixed together. All of exclude parameters are always applied. Example: Limiting coverage by schema regex. ```sql From 3bdb9d05dffb2456d004849c870e660f8113a337 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 2 Mar 2022 12:57:42 +0200 Subject: [PATCH 301/887] Fixing flaky test --- test/ut3_user/expectations/binary/test_to_be_within.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index d490a8280..032b684a5 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -199,7 +199,7 @@ create or replace package body test_to_be_within is begin --Arrange --Act - ut3_develop.ut.expect(sysdate).to_be_within(INTERVAL '1' MONTH).of_(sysdate+ 45); + ut3_develop.ut.expect(sysdate).to_be_within(INTERVAL '1' MONTH).of_(sysdate+ 46); --Assert l_expected_message := q'[Actual: % (date) was expected to be within 1 month of % (date)]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); From 1d86276dd76d64b87f81cebc3287397912ce1eaa Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 3 Mar 2022 00:24:21 +0200 Subject: [PATCH 302/887] Fix for unit-test results reporting into Sonar --- .github/variables/.env | 2 +- CONTRIBUTING.md | 2 +- docs/userguide/expectations.md | 8 ++--- docs/userguide/running-unit-tests.md | 2 +- test/install_ut3_tester_helper.sql | 2 +- test/run_tests.sh | 6 +++- .../annotations/test_annotation_manager.pkb | 16 ++++----- .../annotations/test_annotation_manager.pks | 8 ++--- test/ut3_tester_helper/main_helper.pkb | 12 +++---- test/ut3_tester_helper/main_helper.pks | 6 ++-- test/ut3_tester_helper/run_helper.pkb | 34 +++++++++---------- test/ut3_tester_helper/run_helper.pks | 4 +-- test/ut3_user/api/test_ut_run.pkb | 10 +++--- test/ut3_user/api/test_ut_run.pks | 20 +++++------ test/ut3_user/api/test_ut_runner.pkb | 24 ++++++------- test/ut3_user/expectations.pkb | 6 ++-- test/ut3_user/reporters.pkb | 2 +- .../reporters/test_documentation_reporter.pkb | 4 +-- .../reporters/test_teamcity_reporter.pkb | 34 +++++++++---------- 19 files changed, 103 insertions(+), 99 deletions(-) diff --git a/.github/variables/.env b/.github/variables/.env index 9f35a080c..e0a579d52 100644 --- a/.github/variables/.env +++ b/.github/variables/.env @@ -3,7 +3,7 @@ UT3_DEVELOP_SCHEMA=UT3_DEVELOP UT3_DEVELOP_SCHEMA_PASSWORD=ut3 UT3_RELEASE_VERSION_SCHEMA=UT3 UT3_RELEASE_VERSION_SCHEMA_PASSWORD=ut3 -UT3_USER='UT3$USER#' +UT3_USER='UT3_USER' UT3_USER_PASSWORD=ut3 UT3_TESTER=UT3_TESTER UT3_TESTER_PASSWORD=ut3 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index a65b7b685..41a86ecdd 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -46,7 +46,7 @@ We use four different database accounts (users) for development process. * `ut3` - holds latest released version of utPLSQL. This schema holds the testing framework used for self-testing of utPLSQL development. * `ut3_develop` - holds the version of utPLSQL of your current branch. This is the schema you will be working on. * `ut3_tester` - holds unit test packages for development of utPLSQL. -* `ut3$user#` - used for testing accessibility to schema names with special characters. +* `ut3_user` - used for testing accessibility to schema names with special characters. * `ut3_tester_helper` - elevated privileges user, used for creating and dropping objects in other schemas during test run. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 96fd4e2c4..387149138 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -249,13 +249,13 @@ Failures: 1) the_test "Checking table ALL_USERS" Actual: 28 (number) was expected to equal: 0 (number) - at "UT3$USER#.SHARED_EXPECTATION_TEST.TABLE_IS_EMPTY", line 6 ut.expect( l_count, 'Checking table '||p_table_name ).to_equal(0); - at "UT3$USER#.SHARED_EXPECTATION_TEST.THE_TEST", line 11 + at "UT3_USER.SHARED_EXPECTATION_TEST.TABLE_IS_EMPTY", line 6 ut.expect( l_count, 'Checking table '||p_table_name ).to_equal(0); + at "UT3_USER.SHARED_EXPECTATION_TEST.THE_TEST", line 11 "Checking table ALL_TABLES" Actual: 55 (number) was expected to equal: 0 (number) - at "UT3$USER#.SHARED_EXPECTATION_TEST.TABLE_IS_EMPTY", line 6 ut.expect( l_count, 'Checking table '||p_table_name ).to_equal(0); - at "UT3$USER#.SHARED_EXPECTATION_TEST.THE_TEST", line 12 + at "UT3_USER.SHARED_EXPECTATION_TEST.TABLE_IS_EMPTY", line 6 ut.expect( l_count, 'Checking table '||p_table_name ).to_equal(0); + at "UT3_USER.SHARED_EXPECTATION_TEST.THE_TEST", line 12 Finished in .066344 seconds 1 tests, 1 failed, 0 errored, 0 disabled, 0 warning(s) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 88fa7ad0c..ec9cb0d83 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -195,7 +195,7 @@ declare begin l_reporter.set_reporter_id( 'd8a79e85915640a6a4e1698fdf90ba74' ); l_reporter.output_buffer.init(); - ut_runner.run (ut_varchar2_list ('ut3_tester','ut3$user#'), ut_reporters( l_reporter ) ); + ut_runner.run (ut_varchar2_list ('ut3_tester','ut3_user'), ut_reporters( l_reporter ) ); end; / ``` diff --git a/test/install_ut3_tester_helper.sql b/test/install_ut3_tester_helper.sql index d9aacdf36..b78221627 100644 --- a/test/install_ut3_tester_helper.sql +++ b/test/install_ut3_tester_helper.sql @@ -35,7 +35,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester_helper/annotation_cache_helper.pks @@ut3_tester_helper/annotation_cache_helper.pkb create or replace synonym ut3_tester.annotation_cache_helper for ut3_tester_helper.annotation_cache_helper; -create or replace synonym ut3$user#.coverage_helper for ut3_tester_helper.coverage_helper; +create or replace synonym ut3_user.coverage_helper for ut3_tester_helper.coverage_helper; set linesize 200 set define on diff --git a/test/run_tests.sh b/test/run_tests.sh index 0edc4d96d..ae4a739d9 100755 --- a/test/run_tests.sh +++ b/test/run_tests.sh @@ -6,8 +6,12 @@ git rev-parse && cd "$(git rev-parse --show-cdup)" time utPLSQL-cli/bin/utplsql run ${UT3_TESTER_HELPER}/${UT3_TESTER_HELPER_PASSWORD}@${CONNECTION_STR} \ -source_path=source -owner=ut3_develop \ --p='ut3_tester,ut3$user#' \ +-p='ut3_tester,ut3_user' \ -test_path=test -c \ + -regex_expression="test/(\w+)(/(\w+))*/(\w+)\.(.{3})$" \ + -owner_subexpression=1 \ + -type_subexpression=5 \ + -name_subexpression=4 \ -f=ut_coverage_sonar_reporter -o=coverage.xml \ -f=ut_coverage_cobertura_reporter -o=cobertura.xml \ -f=ut_coverage_html_reporter -o=coverage.html \ diff --git a/test/ut3_tester/core/annotations/test_annotation_manager.pkb b/test/ut3_tester/core/annotations/test_annotation_manager.pkb index a5503f841..8eb3c2f6d 100644 --- a/test/ut3_tester/core/annotations/test_annotation_manager.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_manager.pkb @@ -71,19 +71,19 @@ create or replace package body test_annotation_manager is exec_autonomous(q'[alter package dummy_test_package compile]'); end; - procedure create_parse_proc_as_ut3$user# is + procedure create_parse_proc_as_ut3_user is begin - ut3_tester_helper.main_helper.create_parse_proc_as_ut3$user#(); + ut3_tester_helper.main_helper.create_parse_proc_as_ut3_user(); end; - procedure parse_dummy_test_as_ut3$user# is + procedure parse_dummy_test_as_ut3_user is begin - ut3_tester_helper.main_helper.parse_dummy_test_as_ut3$user#(); + ut3_tester_helper.main_helper.parse_dummy_test_as_ut3_user(); end; - procedure drop_parse_proc_as_ut3$user# is + procedure drop_parse_proc_as_ut3_user is begin - ut3_tester_helper.main_helper.drop_parse_proc_as_ut3$user#(); + ut3_tester_helper.main_helper.drop_parse_proc_as_ut3_user(); exception when others then null; @@ -400,10 +400,10 @@ create or replace package body test_annotation_manager is l_start_date date; begin l_start_date := sysdate; - parse_dummy_test_as_ut3$user#(); + parse_dummy_test_as_ut3_user(); drop_dummy_test_package(); --Act - parse_dummy_test_as_ut3$user#(); + parse_dummy_test_as_ut3_user(); --Assert select count(1) into l_cache_count diff --git a/test/ut3_tester/core/annotations/test_annotation_manager.pks b/test/ut3_tester/core/annotations/test_annotation_manager.pks index 5d7464fd2..7207917f3 100644 --- a/test/ut3_tester/core/annotations/test_annotation_manager.pks +++ b/test/ut3_tester/core/annotations/test_annotation_manager.pks @@ -14,9 +14,9 @@ create or replace package test_annotation_manager is procedure create_dummy_test_package; - procedure create_parse_proc_as_ut3$user#; + procedure create_parse_proc_as_ut3_user; - procedure drop_parse_proc_as_ut3$user#; + procedure drop_parse_proc_as_ut3_user; procedure drop_dummy_test_package; @@ -85,8 +85,8 @@ create or replace package test_annotation_manager is procedure update_modified_test_package; --%test(Keeps annotations in cache when object was removed but user can't see whole schema) - --%beforetest(create_dummy_test_package,create_parse_proc_as_ut3$user#) - --%aftertest(drop_parse_proc_as_ut3$user#) + --%beforetest(create_dummy_test_package,create_parse_proc_as_ut3_user) + --%aftertest(drop_parse_proc_as_ut3_user) procedure keep_dropped_data_in_cache; --%test(Does not return data for dropped object) diff --git a/test/ut3_tester_helper/main_helper.pkb b/test/ut3_tester_helper/main_helper.pkb index 76245ea12..f1dadec66 100644 --- a/test/ut3_tester_helper/main_helper.pkb +++ b/test/ut3_tester_helper/main_helper.pkb @@ -104,26 +104,26 @@ create or replace package body main_helper is commit; end; - procedure create_parse_proc_as_ut3$user# is + procedure create_parse_proc_as_ut3_user is pragma autonomous_transaction; begin execute immediate q'[ - create or replace procedure ut3$user#.parse_annotations is + create or replace procedure ut3_user.parse_annotations is begin ut3_develop.ut_runner.rebuild_annotation_cache('UT3_TESTER','PACKAGE'); end;]'; end; - procedure drop_parse_proc_as_ut3$user# is + procedure drop_parse_proc_as_ut3_user is pragma autonomous_transaction; begin - execute immediate 'drop procedure ut3$user#.parse_annotations'; + execute immediate 'drop procedure ut3_user.parse_annotations'; end; - procedure parse_dummy_test_as_ut3$user# is + procedure parse_dummy_test_as_ut3_user is pragma autonomous_transaction; begin - execute immediate 'begin ut3$user#.parse_annotations; end;'; + execute immediate 'begin ut3_user.parse_annotations; end;'; end; procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_list, a_item varchar2) is diff --git a/test/ut3_tester_helper/main_helper.pks b/test/ut3_tester_helper/main_helper.pks index 6dd453446..7decad88d 100644 --- a/test/ut3_tester_helper/main_helper.pks +++ b/test/ut3_tester_helper/main_helper.pks @@ -29,11 +29,11 @@ create or replace package main_helper is procedure cleanup_annotation_cache; - procedure create_parse_proc_as_ut3$user#; + procedure create_parse_proc_as_ut3_user; - procedure drop_parse_proc_as_ut3$user#; + procedure drop_parse_proc_as_ut3_user; - procedure parse_dummy_test_as_ut3$user#; + procedure parse_dummy_test_as_ut3_user; procedure append_to_list(a_list in out nocopy ut3_develop.ut_varchar2_list, a_item varchar2); diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index c2a50170e..95f93f751 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -3,7 +3,7 @@ create or replace package body run_helper is procedure setup_cache_objects is pragma autonomous_transaction; begin - execute immediate q'[create or replace package ut3$user#.dummy_test_package as + execute immediate q'[create or replace package ut3_user.dummy_test_package as --%suite(dummy_test_suite) --%suitepath(some.path) --%rollback(manual) @@ -12,7 +12,7 @@ create or replace package body run_helper is --%beforetest(some_procedure) procedure some_dummy_test_procedure; end;]'; - execute immediate q'[create or replace procedure ut3$user#.dummy_test_procedure as + execute immediate q'[create or replace procedure ut3_user.dummy_test_procedure as --%some_annotation(some_text) --%rollback(manual) begin @@ -27,7 +27,7 @@ create or replace package body run_helper is execute immediate q'[grant execute on ut3_tester_helper.dummy_test_procedure to public]'; - execute immediate q'[create or replace package ut3$user#.bad_test_package as + execute immediate q'[create or replace package ut3_user.bad_test_package as --%rollback(manual) --%test(dummy_test) procedure some_dummy_test_procedure; @@ -37,7 +37,7 @@ create or replace package body run_helper is procedure setup_cache_objectstag is pragma autonomous_transaction; begin - execute immediate q'[create or replace package ut3$user#.dummy_test_package as + execute immediate q'[create or replace package ut3_user.dummy_test_package as --%suite(dummy_test_suite) --%suitepath(some.path) --%tags(dummy) @@ -48,7 +48,7 @@ create or replace package body run_helper is --%beforetest(some_procedure) procedure some_dummy_test_procedure; end;]'; - execute immediate q'[create or replace procedure ut3$user#.dummy_test_procedure as + execute immediate q'[create or replace procedure ut3_user.dummy_test_procedure as --%some_annotation(some_text) --%rollback(manual) begin @@ -67,7 +67,7 @@ create or replace package body run_helper is procedure setup_cache_twotags is pragma autonomous_transaction; begin - execute immediate q'[create or replace package ut3$user#.dummy_test_package as + execute immediate q'[create or replace package ut3_user.dummy_test_package as --%suite(dummy_test_suite) --%tags(suitetag1,suitetag2) --%rollback(manual) @@ -77,7 +77,7 @@ create or replace package body run_helper is --%beforetest(some_procedure) procedure some_dummy_test_procedure; end;]'; - execute immediate q'[create or replace procedure ut3$user#.dummy_test_procedure as + execute immediate q'[create or replace procedure ut3_user.dummy_test_procedure as --%some_annotation(some_text) --%rollback(manual) begin @@ -141,8 +141,8 @@ create or replace package body run_helper is pragma autonomous_transaction; begin setup_cache_objects(); - ut3_develop.ut_annotation_manager.rebuild_annotation_cache('UT3$USER#','PACKAGE'); - ut3_develop.ut_annotation_manager.rebuild_annotation_cache('UT3$USER#','PROCEDURE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache('UT3_USER','PACKAGE'); + ut3_develop.ut_annotation_manager.rebuild_annotation_cache('UT3_USER','PROCEDURE'); ut3_develop.ut_annotation_manager.rebuild_annotation_cache('UT3_TESTER_HELPER','PROCEDURE'); end; @@ -150,10 +150,10 @@ create or replace package body run_helper is pragma autonomous_transaction; begin delete from ut3_develop.ut_annotation_cache_info - where object_type = 'PROCEDURE' and object_owner in ('UT3$USER#','UT3_TESTER_HELPER') + where object_type = 'PROCEDURE' and object_owner in ('UT3_USER','UT3_TESTER_HELPER') or object_type = 'PACKAGE' and object_owner = user and object_name = 'DUMMY_TEST_PACKAGE'; - execute immediate q'[drop package ut3$user#.dummy_test_package]'; - execute immediate q'[drop procedure ut3$user#.dummy_test_procedure]'; + execute immediate q'[drop package ut3_user.dummy_test_package]'; + execute immediate q'[drop procedure ut3_user.dummy_test_procedure]'; execute immediate q'[drop procedure ut3_tester_helper.dummy_test_procedure]'; end; @@ -185,7 +185,7 @@ create or replace package body run_helper is begin create_db_link; execute immediate q'[ - create or replace package ut3$user#.test_db_link is + create or replace package ut3_user.test_db_link is --%suite --%test @@ -193,7 +193,7 @@ create or replace package body run_helper is end;]'; execute immediate q'[ - create or replace package body ut3$user#.test_db_link is + create or replace package body ut3_user.test_db_link is procedure runs_with_db_link is a_value integer; begin @@ -208,7 +208,7 @@ create or replace package body run_helper is procedure db_link_cleanup is begin drop_db_link; - begin execute immediate 'drop package ut3$user#.test_db_link'; exception when others then null; end; + begin execute immediate 'drop package ut3_user.test_db_link'; exception when others then null; end; end; procedure create_suite_with_link is @@ -258,7 +258,7 @@ create or replace package body run_helper is execute immediate 'drop package test_distributed_savepoint'; end; - procedure create_ut3$user#_tests is + procedure create_ut3_user_tests is pragma autonomous_transaction; begin execute immediate q'[create or replace package test_package_1 is @@ -348,7 +348,7 @@ create or replace package body run_helper is execute immediate q'[grant execute on test_package_3 to public]'; end; - procedure drop_ut3$user#_tests is + procedure drop_ut3_user_tests is pragma autonomous_transaction; begin execute immediate q'[drop package test_package_1]'; diff --git a/test/ut3_tester_helper/run_helper.pks b/test/ut3_tester_helper/run_helper.pks index 0657c1a51..ad0f615e5 100644 --- a/test/ut3_tester_helper/run_helper.pks +++ b/test/ut3_tester_helper/run_helper.pks @@ -17,8 +17,8 @@ create or replace package run_helper is procedure create_suite_with_link; procedure drop_suite_with_link; - procedure create_ut3$user#_tests; - procedure drop_ut3$user#_tests; + procedure create_ut3_user_tests; + procedure drop_ut3_user_tests; procedure create_test_suite; procedure drop_test_suite; diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index b4f5a5238..7b47193c9 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -13,14 +13,14 @@ create or replace package body test_ut_run is ut3_tester_helper.main_helper.clear_expectations(); end; - procedure create_ut3$user#_tests is + procedure create_ut3_user_tests is begin - ut3_tester_helper.run_helper.create_ut3$user#_tests(); + ut3_tester_helper.run_helper.create_ut3_user_tests(); end; - procedure drop_ut3$user#_tests is + procedure drop_ut3_user_tests is begin - ut3_tester_helper.run_helper.drop_ut3$user#_tests(); + ut3_tester_helper.run_helper.drop_ut3_user_tests(); end; procedure ut_version is @@ -257,7 +257,7 @@ create or replace package body test_ut_run is ut.expect(l_results).to_be_like( '%1) does_stuff%' || 'ORA-01403: no data found%' || - 'ORA-06512: at "UT3$USER#.PARENT_SUITE%' + 'ORA-06512: at "UT3_USER.PARENT_SUITE%' ); end; diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index 753af79da..b3be8700d 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -4,8 +4,8 @@ create or replace package test_ut_run is procedure clear_expectations; - procedure create_ut3$user#_tests; - procedure drop_ut3$user#_tests; + procedure create_ut3_user_tests; + procedure drop_ut3_user_tests; --%test(ut.version() returns version of the framework) procedure ut_version; @@ -17,8 +17,8 @@ create or replace package test_ut_run is --%context(ut_run_procedure) --%displayname(ut.run() procedure options) - --%beforeall(create_ut3$user#_tests) - --%afterall(drop_ut3$user#_tests) + --%beforeall(create_ut3_user_tests) + --%afterall(drop_ut3_user_tests) --%test(Runs all tests in current schema with default reporter when no parameters given) procedure run_proc_no_params; @@ -88,8 +88,8 @@ create or replace package test_ut_run is --%context(ut_run_function) --%displayname(ut.run() function options) - --%beforeall(create_ut3$user#_tests) - --%afterall(drop_ut3$user#_tests) + --%beforeall(create_ut3_user_tests) + --%afterall(drop_ut3_user_tests) --%test(Runs all tests in current schema with default reporter when no parameters given) procedure run_func_no_params; @@ -167,8 +167,8 @@ create or replace package test_ut_run is --%context(random_order) --%displayname(Random test execution order) - --%beforeall(create_ut3$user#_tests) - --%afterall(drop_ut3$user#_tests) + --%beforeall(create_ut3_user_tests) + --%afterall(drop_ut3_user_tests) --%test(Runs tests in random order) procedure run_with_random_order; @@ -184,8 +184,8 @@ create or replace package test_ut_run is --%context(run with tags) --%displayname(Call ut.run with #tags) - --%beforeall(create_ut3$user#_tests) - --%afterall(drop_ut3$user#_tests) + --%beforeall(create_ut3_user_tests) + --%afterall(drop_ut3_user_tests) --%test(Execute test by tag ut_run) procedure test_run_by_one_tag; diff --git a/test/ut3_user/api/test_ut_runner.pkb b/test/ut3_user/api/test_ut_runner.pkb index a24fc2d51..6774698f2 100644 --- a/test/ut3_user/api/test_ut_runner.pkb +++ b/test/ut3_user/api/test_ut_runner.pkb @@ -265,27 +265,27 @@ end;'; --Arrange open l_expected for select - 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, 'dummy_test_suite' item_description, 'UT_SUITE' item_type, 2 item_line_no, 'some.path.dummy_test_package' path, 0 disabled_flag, null disabled_reason,null tags from dual union all select - 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, 'dummy_test' item_description, 'UT_TEST' item_type, 6 item_line_no, 'some.path.dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason,null tags from dual union all select - 'UT3$USER#' object_owner, 'PATH' object_name, 'PATH' item_name, + 'UT3_USER' object_owner, 'PATH' object_name, 'PATH' item_name, null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, 'some.path' path, 0 disabled_flag, null disabled_reason, null tags from dual union all select - 'UT3$USER#' object_owner, 'SOME' object_name, 'SOME' item_name, + 'UT3_USER' object_owner, 'SOME' object_name, 'SOME' item_name, null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, 'some' path, 0 disabled_flag, null disabled_reason, null tags from dual; --Act - open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); + open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3_USER','DUMMY_TEST_PACKAGE')); --Assert ut.expect(l_actual).to_equal(l_expected); end; @@ -297,27 +297,27 @@ end;'; --Arrange open l_expected for select - 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, 'dummy_test_suite' item_description, 'UT_SUITE' item_type, 2 item_line_no, 'some.path.dummy_test_package' path, 0 disabled_flag, null disabled_reason,'dummy' tags from dual union all select - 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, 'dummy_test' item_description, 'UT_TEST' item_type, 7 item_line_no, 'some.path.dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason,'testtag' tags from dual union all select - 'UT3$USER#' object_owner, 'PATH' object_name, 'PATH' item_name, + 'UT3_USER' object_owner, 'PATH' object_name, 'PATH' item_name, null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, 'some.path' path, 0 disabled_flag, null disabled_reason, null tags from dual union all select - 'UT3$USER#' object_owner, 'SOME' object_name, 'SOME' item_name, + 'UT3_USER' object_owner, 'SOME' object_name, 'SOME' item_name, null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, 'some' path, 0 disabled_flag, null disabled_reason, null tags from dual; --Act - open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); + open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3_USER','DUMMY_TEST_PACKAGE')); --Assert ut.expect(l_actual).to_equal(l_expected); end; @@ -329,12 +329,12 @@ end;'; --Arrange open l_expected for select - 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, 'dummy_test_suite' item_description, 'UT_SUITE' item_type, 2 item_line_no, 'dummy_test_package' path, 0 disabled_flag, null disabled_reason,'suitetag1,suitetag2' tags from dual union all select - 'UT3$USER#' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, 'dummy_test' item_description, 'UT_TEST' item_type, 6 item_line_no, 'dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason,'testtag1,testtag2' tags from dual; diff --git a/test/ut3_user/expectations.pkb b/test/ut3_user/expectations.pkb index 30af48a44..be8627712 100644 --- a/test/ut3_user/expectations.pkb +++ b/test/ut3_user/expectations.pkb @@ -16,14 +16,14 @@ create or replace package body expectations as l_expected := q'[FAILURE Actual: 1 (number) was expected to equal: 0 (number) - at "UT3$USER#.SOME_PKG%", line 4 ut3_develop.ut.expect(1).to_equal(0); + at "UT3_USER.SOME_PKG%", line 4 ut3_develop.ut.expect(1).to_equal(0); at "anonymous block", line 1 - at "UT3$USER#.EXPECTATIONS%", line 10 + at "UT3_USER.EXPECTATIONS%", line 10 SUCCESS Actual: 0 (number) was expected to equal: 0 (number) FAILURE Actual: 1 (number) was expected to equal: 0 (number) - at "UT3$USER#.EXPECTATIONS%", line 11 ut3_develop.ut.expect(1).to_equal(0); + at "UT3_USER.EXPECTATIONS%", line 11 ut3_develop.ut.expect(1).to_equal(0); SUCCESS Actual: 0 (number) was expected to equal: 0 (number) ]'; diff --git a/test/ut3_user/reporters.pkb b/test/ut3_user/reporters.pkb index 76d345a3d..b6d43b144 100644 --- a/test/ut3_user/reporters.pkb +++ b/test/ut3_user/reporters.pkb @@ -188,7 +188,7 @@ end;]'; --Assert ut.expect(l_actual).to_be_like('%' (varchar2)%]' - ||q'[at "UT3$USER#.CHECK_FAIL_ESCAPE%", line % ut3_develop.ut.expect('test').to_equal('');]' + ||q'[at "UT3_USER.CHECK_FAIL_ESCAPE%", line % ut3_develop.ut.expect('test').to_equal('');]' ||'%]]>%' ); end; diff --git a/test/ut3_user/reporters/test_documentation_reporter.pkb b/test/ut3_user/reporters/test_documentation_reporter.pkb index a627d26b4..6ace70c49 100644 --- a/test/ut3_user/reporters/test_documentation_reporter.pkb +++ b/test/ut3_user/reporters/test_documentation_reporter.pkb @@ -33,12 +33,12 @@ Failures: 1) failing_test "Fails as values are different" Actual: 'number [1] ' (varchar2) was expected to equal: 'number [2] ' (varchar2)% - at "UT3$USER#.TEST_REPORTERS%", line 36 ut3_develop.ut.expect('number [1] ','Fails as values are different').to_equal('number [2] '); + at "UT3_USER.TEST_REPORTERS%", line 36 ut3_develop.ut.expect('number [1] ','Fails as values are different').to_equal('number [2] '); % % 2) erroring_test ORA-06502: PL/SQL: numeric or value error: character to number conversion error - ORA-06512: at "UT3$USER#.TEST_REPORTERS", line 44% + ORA-06512: at "UT3_USER.TEST_REPORTERS", line 44% ORA-06512: at line 6 Finished in % seconds 5 tests, 1 failed, 1 errored, 2 disabled, 0 warning(s)%]'; diff --git a/test/ut3_user/reporters/test_teamcity_reporter.pkb b/test/ut3_user/reporters/test_teamcity_reporter.pkb index 6d471b2b0..ff550e488 100644 --- a/test/ut3_user/reporters/test_teamcity_reporter.pkb +++ b/test/ut3_user/reporters/test_teamcity_reporter.pkb @@ -45,29 +45,29 @@ create or replace package body test_teamcity_reporter as %##teamcity[testSuiteStarted timestamp='%' name='org.utplsql.tests.helpers'] %##teamcity[testSuiteStarted timestamp='%' name='A suite for testing different outcomes from reporters'] %##teamcity[testSuiteStarted timestamp='%' name='A description of some context'] -%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3$user#.test_reporters.passing_test'] +%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3_user.test_reporters.passing_test'] -%##teamcity[testFinished timestamp='%' duration='%' name='ut3$user#.test_reporters.passing_test'] +%##teamcity[testFinished timestamp='%' duration='%' name='ut3_user.test_reporters.passing_test'] %##teamcity[testSuiteFinished timestamp='%' name='A description of some context'] -%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3$user#.test_reporters.failing_test'] +%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3_user.test_reporters.failing_test'] -%##teamcity[testFailed timestamp='%' details='Actual: |'number |[1|] |' (varchar2) was expected to equal: |'number |[2|] |' (varchar2)' message='Fails as values are different' name='ut3$user#.test_reporters.failing_test'] -%##teamcity[testFinished timestamp='%' duration='%' name='ut3$user#.test_reporters.failing_test'] -%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3$user#.test_reporters.erroring_test'] +%##teamcity[testFailed timestamp='%' details='Actual: |'number |[1|] |' (varchar2) was expected to equal: |'number |[2|] |' (varchar2)' message='Fails as values are different' name='ut3_user.test_reporters.failing_test'] +%##teamcity[testFinished timestamp='%' duration='%' name='ut3_user.test_reporters.failing_test'] +%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3_user.test_reporters.erroring_test'] -%##teamcity[testStdErr timestamp='%' name='ut3$user#.test_reporters.erroring_test' out='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|n'] -%##teamcity[testFailed timestamp='%' details='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3$USER#.TEST_REPORTERS", line %|nORA-06512: at %|n' message='Error occured' name='ut3$user#.test_reporters.erroring_test'] -%##teamcity[testFinished timestamp='%' duration='%' name='ut3$user#.test_reporters.erroring_test'] -%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3$user#.test_reporters.disabled_test'] -%##teamcity[testIgnored timestamp='%' name='ut3$user#.test_reporters.disabled_test'] +%##teamcity[testStdErr timestamp='%' name='ut3_user.test_reporters.erroring_test' out='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3_USER.TEST_REPORTERS", line %|nORA-06512: at %|n'] +%##teamcity[testFailed timestamp='%' details='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3_USER.TEST_REPORTERS", line %|nORA-06512: at %|n' message='Error occured' name='ut3_user.test_reporters.erroring_test'] +%##teamcity[testFinished timestamp='%' duration='%' name='ut3_user.test_reporters.erroring_test'] +%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3_user.test_reporters.disabled_test'] +%##teamcity[testIgnored timestamp='%' name='ut3_user.test_reporters.disabled_test'] %##teamcity[testSuiteFinished timestamp='%' name='A suite for testing different outcomes from reporters'] %##teamcity[testSuiteFinished timestamp='%' name='org.utplsql.tests.helpers'] %##teamcity[testSuiteFinished timestamp='%' name='org.utplsql.tests'] @@ -88,9 +88,9 @@ create or replace package body test_teamcity_reporter as l_expected varchar2(32767); begin l_expected := q'{%##teamcity[testSuiteStarted timestamp='%' name='A suite with |'quote|''] -%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3$user#.check_escape_special_chars.test_do_stuff'] -%##teamcity[testFailed timestamp='%' details='Actual: (varchar2)|n |' |[ |r|n |] |'|n was expected to be null' name='ut3$user#.check_escape_special_chars.test_do_stuff'] -%##teamcity[testFinished timestamp='%' duration='%' name='ut3$user#.check_escape_special_chars.test_do_stuff'] +%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3_user.check_escape_special_chars.test_do_stuff'] +%##teamcity[testFailed timestamp='%' details='Actual: (varchar2)|n |' |[ |r|n |] |'|n was expected to be null' name='ut3_user.check_escape_special_chars.test_do_stuff'] +%##teamcity[testFinished timestamp='%' duration='%' name='ut3_user.check_escape_special_chars.test_do_stuff'] %##teamcity[testSuiteFinished timestamp='%' name='A suite with |'quote|'']}'; --act select * @@ -107,9 +107,9 @@ create or replace package body test_teamcity_reporter as l_expected varchar2(32767); begin l_expected := q'{%##teamcity[testSuiteStarted timestamp='%' name='check_trims_long_output'] -%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3$user#.check_trims_long_output.long_output'] -%##teamcity[testFailed timestamp='%' details='Actual: (varchar2)|n |'aVarcharaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|[...|]' name='ut3$user#.check_trims_long_output.long_output'] -%##teamcity[testFinished timestamp='%' duration='%' name='ut3$user#.check_trims_long_output.long_output'] +%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3_user.check_trims_long_output.long_output'] +%##teamcity[testFailed timestamp='%' details='Actual: (varchar2)|n |'aVarcharaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|[...|]' name='ut3_user.check_trims_long_output.long_output'] +%##teamcity[testFinished timestamp='%' duration='%' name='ut3_user.check_trims_long_output.long_output'] %##teamcity[testSuiteFinished timestamp='%' name='check_trims_long_output']}'; --act select * From 7cca6b468bc31194f2ecd0d9b2812982037c0578 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 3 Mar 2022 00:58:59 +0200 Subject: [PATCH 303/887] Update of coverage.md --- docs/userguide/coverage.md | 73 +++++++++++++++++++++++++++----------- 1 file changed, 53 insertions(+), 20 deletions(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 20210ab47..cdc573758 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -32,18 +32,19 @@ If you have `execute` privilege on the code that is being tested, but do not hav If you have `execute` privilege only on the unit tests, but do not have `execute` privilege on the code that is being tested, the code will not be reported by coverage - as if it did not exist in the database. If the code that is being tested is compiled as NATIVE, the code coverage will not be reported as well. -## Running unit tests with coverage -Using the code coverage functionality is as easy as using any other [reporter](reporters.md) for the utPLSQL test-run. You just run your tests from your preferred SQL tool and save the reporter results to a file. -All you need to do is pass the constructor of the reporter to the `ut.run` procedure call. +## Manually running unit tests with coverage +Using the code coverage functionality is as easy as using any other [reporter](reporters.md) for the utPLSQL test-run. Run your tests from your preferred SQL tool and save the reporter results to a file. +All you need to do, is pass the constructor of the reporter to the `ut.run` procedure call. Example: ```sql +set serveroutput on begin ut.run(ut_coverage_html_reporter()); end; / ``` -The above command executes all unit tests in the **current schema**, gathers information about code coverage and outputs the HTML report as text into DBMS_OUTPUT. +The above command executes all unit tests in the **current schema**, gathers information about code coverage for all sources in that schema and outputs the HTML report as text into DBMS_OUTPUT. The `ut_coverage_html_reporter` will produce an interactive HTML report. You can see a sample of code coverage for the utPLSQL project [here](https://utplsql.github.io/utPLSQL-coverage-html/) The report provides summary information with a list of source code that should be covered. @@ -79,14 +80,14 @@ There are two distinct ways to gather code coverage: - Coverage on project files Those two options are mutually exclusive and cannot be mixed. -By default, when using one of coverage reporters, coverage is gathered on schema(s). +By default, when using one of coverage reporters, coverage is gathered on schema(s). +The database schema(s) containing the tests that were executed during the run will be reported on by coverage reporter. The parameters used to execute tests determine if utPLSQL will be using one approach or the other. +If parameter `a_source_file_mappings` or `a_source_files` is provided, then coverage is gathered on project files provided, otherwise coverage is gathered on schemas. -The database schema(s) containing the tests that were executed during the run will be reported on by coverage reporter. **Note** - > Regardless of the options provided, all unit test packages are excluded from the coverage report. Coverage reports provide information only about the **tested** code. The default behavior of coverage reporting can be altered using invocation parameters. @@ -131,10 +132,10 @@ exec ut.run('unit_test_schema', ut_coverage_html_reporter(), a_coverage_schemes There are multiple parameters that can be used to define the scope of coverage report: - `a_source_file_mappings ( ut_file_mappings )` - map of filenames to database objects. It is used for file-based coverage - see below. -- `a_include_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be included in the coverage report. -- `a_include_object_expr ( varchar(4000) )` - string of regex expression of objects ( without schema name ) to be included in the coverage report. -- `a_exclude_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be excluded from the coverage report. -- `a_exclude_object_expr ( varchar(4000) )` - string of regex expression of objects to be excluded from the coverage report. +- `a_include_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be included in the coverage report. Case-insensitive. +- `a_include_object_expr ( varchar(4000) )` - string of regex expression of objects ( without schema name ) to be included in the coverage report. Case-insensitive. +- `a_exclude_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be excluded from the coverage report. Case-insensitive. +- `a_exclude_object_expr ( varchar(4000) )` - string of regex expression of objects ( without schema name ) to be excluded from the coverage report. Case-insensitive. - `a_coverage_schemes ( ut_varchar2_list )` - List of database schema names to gather coverage on. - `a_include_objects ( ut_varchar2_list )` - list of `[object_owner.]object_name` to be included in the coverage report. - `a_exclude_objects ( ut_varchar2_list )` - list of `[object_owner.]object_name` to be excluded from the coverage report. @@ -164,6 +165,7 @@ end; ``` Will result in showing coverage for all schemas that match regular expression `^ut3_develop` +Example: Limiting coverage by schema regex with parameter `a_include_objects` ignored. ```sql begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), @@ -172,37 +174,68 @@ begin end; ``` Will result in showing coverage for all schemas that match regular expression `^ut3_develop`. -Will ignore the `a_include_objects` parameter +Example: Limiting coverage by object regex. ```sql begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_include_object_expr => 'regex123', a_include_objects => ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) + a_include_object_expr => 'regex123' ); end; ``` Will result in showing coverage for all objects that name match regular expression `regex123`. -Will ignore the `a_include_objects` parameter. +Example: Limiting coverage by object regex with parameter `a_include_objects` ignored. +```sql +begin + ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), + a_include_object_expr => 'utl', a_include_objects => ut_varchar2_list( 'user_2.utils_package' ) + ); +end; +``` +Will result in showing coverage for all objects that name match regular expression `utl`. + +Example: Limiting coverage by excluding schema with regex. +```sql +begin + ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), + a_exclude_schema_expr => 'er_1$' + ); +end; +``` +Will result in showing coverage for objects in all schema except schemas that are matching regular expression `er_1$` + +Example: Limiting coverage by excluding schema with regex and excluding specific object. +```sql +begin + ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), + a_exclude_schema_expr => 'er_1$', a_exclude_objects => ut_varchar2_list( 'user_2.utils_package' ) + ); +end; +``` +Will result in showing coverage for objects in all schemas except schemas that are matching regular expression `er_1$` +Will also exclude object `user_2.utils_package` from coverage report + +Example: Limiting coverage by excluding objects with regex. ```sql begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_exclude_schema_expr => '^ut3_tester', a_exclude_objects => ut_varchar2_list( 'regex_dummy_cov' ) + a_exclude_object_expr => 'utl' ); end; ``` -Will result in showing coverage for objects in all schema except schemas that are matching regular expression `^ut3_tester` -Will ignore exclusion defined by parameter `a_exclude_objects` +Will result in showing coverage for all objects that name is not matching regular expression `utl`. +Example: Limiting coverage by excluding objects with regex with parameter `a_exclude_objects` ignored. ```sql begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_exclude_object_expr => 'regex123', a_exclude_objects => ut_varchar2_list( 'regex_dummy_cov' ) + a_exclude_object_expr => 'utl', a_exclude_objects => ut_varchar2_list( 'user_2.utils_package' ) ); end; ``` -Will result in showing coverage for all objects that name is not matching regular expression `regex123`. -Will ignore exclusion defined by parameter `a_exclude_objects`. +Will result in showing coverage for all objects that name is not matching regular expression `utl`. +Will also exclude object `user_2.utils_package` from coverage report Example: Limiting coverage by object name, for tested code located in the same schema as the unit tests. From a0462a7584113c494d37fd2c6ceb1bbfec404b35 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 3 Mar 2022 01:12:55 +0200 Subject: [PATCH 304/887] Fixing tests after schema rename. Make sure SONAR runs, even if build fails. --- .github/workflows/build.yml | 2 +- test/ut3_user/api/test_ut_run.pkb | 2 +- test/ut3_user/api/test_ut_runner.pkb | 28 +++++++++---------- .../expectations/test_expectations_cursor.pkb | 4 +-- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 816f0ab39..a0aae6b64 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -193,7 +193,7 @@ jobs: - name: SonarCloud Scan id: sonar - if: ${{ matrix.db_version_name == '21XE' }} + if: ${{ always() && matrix.db_version_name == '21XE' }} uses: SonarSource/sonarcloud-github-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 7b47193c9..492efcba2 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -625,7 +625,7 @@ Failures:% begin execute immediate q'[select count(1) from all_objects o where o.owner = :object_owner and o.object_type = 'PACKAGE' and o.status = 'INVALID' and o.object_name= :object_name]' into l_is_invalid - using 'UT3$USER#','INVALID_PCKAG_THAT_REVALIDATES'; + using 'UT3_USER','INVALID_PCKAG_THAT_REVALIDATES'; select * bulk collect into l_results from table(ut3_develop.ut.run('invalid_pckag_that_revalidates')); diff --git a/test/ut3_user/api/test_ut_runner.pkb b/test/ut3_user/api/test_ut_runner.pkb index 6774698f2..80b1cd60b 100644 --- a/test/ut3_user/api/test_ut_runner.pkb +++ b/test/ut3_user/api/test_ut_runner.pkb @@ -339,7 +339,7 @@ end;'; 'dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason,'testtag1,testtag2' tags from dual; --Act - open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3$USER#','DUMMY_TEST_PACKAGE')); + open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3_USER','DUMMY_TEST_PACKAGE')); --Assert ut.expect(l_actual).to_equal(l_expected); end; @@ -571,20 +571,20 @@ end;'; begin ut.expect( ut3_develop.ut_runner.is_test( - a_owner => 'UT3$USER#', + a_owner => 'UT3_USER', a_package_name => 'DUMMY_TEST_PACKAGE', a_procedure_name => 'SOME_DUMMY_TEST_PROCEDURE' ) ).to_be_true(); - ut.expect( ut3_develop.ut_runner.is_test( 'ut3$user#','dummy_test_package','some_dummy_test_procedure' ) ).to_be_true(); + ut.expect( ut3_develop.ut_runner.is_test( 'ut3_user','dummy_test_package','some_dummy_test_procedure' ) ).to_be_true(); end; procedure is_test_false is begin - ut.expect( ut3_develop.ut_runner.is_test( 'UT3$USER#','DUMMY_TEST_PACKAGE', 'BAD' ) ).to_be_false(); - ut.expect( ut3_develop.ut_runner.is_test( 'UT3$USER#','BAD_TEST_PACKAGE', 'some_dummy_test_procedure' ) ).to_be_false(); - ut.expect( ut3_develop.ut_runner.is_test( 'UT3$USER#','DUMMY_TEST_PACKAGE', null ) ).to_be_false(); - ut.expect( ut3_develop.ut_runner.is_test( 'UT3$USER#',null,'some_dummy_test_procedure' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_test( 'UT3_USER','DUMMY_TEST_PACKAGE', 'BAD' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_test( 'UT3_USER','BAD_TEST_PACKAGE', 'some_dummy_test_procedure' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_test( 'UT3_USER','DUMMY_TEST_PACKAGE', null ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_test( 'UT3_USER',null,'some_dummy_test_procedure' ) ).to_be_false(); ut.expect( ut3_develop.ut_runner.is_test( null,'DUMMY_TEST_PACKAGE','some_dummy_test_procedure' ) ).to_be_false(); end; @@ -592,26 +592,26 @@ end;'; begin ut.expect( ut3_develop.ut_runner.is_suite( - a_owner => 'UT3$USER#', + a_owner => 'UT3_USER', a_package_name => 'DUMMY_TEST_PACKAGE' ) ).to_be_true(); - ut.expect( ut3_develop.ut_runner.is_suite( 'ut3$user#','dummy_test_package' ) ).to_be_true(); + ut.expect( ut3_develop.ut_runner.is_suite( 'ut3_user','dummy_test_package' ) ).to_be_true(); end; procedure is_suite_false is begin - ut.expect( ut3_develop.ut_runner.is_suite( 'UT3$USER#','BAD' ) ).to_be_false(); - ut.expect( ut3_develop.ut_runner.is_suite( 'UT3$USER#', null ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_suite( 'UT3_USER','BAD' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_suite( 'UT3_USER', null ) ).to_be_false(); ut.expect( ut3_develop.ut_runner.is_suite( null,'DUMMY_TEST_PACKAGE' ) ).to_be_false(); - ut.expect( ut3_develop.ut_runner.is_suite( 'UT3$USER#','bad_test_package' ) ).to_be_false(); + ut.expect( ut3_develop.ut_runner.is_suite( 'UT3_USER','bad_test_package' ) ).to_be_false(); end; procedure has_suites_true is begin - ut.expect( ut3_develop.ut_runner.has_suites( a_owner => 'UT3$USER#' ) ).to_be_true(); - ut.expect( ut3_develop.ut_runner.has_suites( 'ut3$user#' ) ).to_be_true(); + ut.expect( ut3_develop.ut_runner.has_suites( a_owner => 'UT3_USER' ) ).to_be_true(); + ut.expect( ut3_develop.ut_runner.has_suites( 'ut3_user' ) ).to_be_true(); end; procedure has_suites_false is diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index 409c81ace..952084fd3 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -2507,7 +2507,7 @@ Diff:% begin l_exp_message :='ORA-20218: SQL exception thrown when fetching data from cursor: ORA-01476: divisor is equal to zero -at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line % ut3_develop.ut.expect(l_actual).to_equal(l_expected);% +at "UT3_USER.TEST_EXPECTATIONS_CURSOR%", line % ut3_develop.ut.expect(l_actual).to_equal(l_expected);% Check the query and data for errors.'; open l_actual for @@ -2532,7 +2532,7 @@ Check the query and data for errors.'; l_exp_message :='ORA-20218: SQL exception thrown when fetching data from cursor: ORA-01476: divisor is equal to zero -at "UT3$USER#.TEST_EXPECTATIONS_CURSOR%", line % ut3_develop.ut.expect(l_actual).to_equal(l_expected);% +at "UT3_USER.TEST_EXPECTATIONS_CURSOR%", line % ut3_develop.ut.expect(l_actual).to_equal(l_expected);% Check the query and data for errors.'; open l_expected for From 25336385a0d7192d704fcfe67860f5efd5af5d24 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 3 Mar 2022 01:17:09 +0200 Subject: [PATCH 305/887] Update coverage.md --- docs/userguide/coverage.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index cdc573758..664c972d1 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -130,7 +130,7 @@ exec ut.run('unit_test_schema', ut_coverage_html_reporter(), a_coverage_schemes #### Filtering objects in coverage reports -There are multiple parameters that can be used to define the scope of coverage report: +Multiple parameters can be used to define the scope of coverage report. - `a_source_file_mappings ( ut_file_mappings )` - map of filenames to database objects. It is used for file-based coverage - see below. - `a_include_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be included in the coverage report. Case-insensitive. - `a_include_object_expr ( varchar(4000) )` - string of regex expression of objects ( without schema name ) to be included in the coverage report. Case-insensitive. From 79fcf85bf07b4694f34c2d6821b8694233427226 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 2 Mar 2022 23:54:33 +0000 Subject: [PATCH 306/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 002c7ee3b..718422bd7 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index fa782b2ad..dce7a66bd 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 400ead44a..73bb5df36 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 11beecd51..c11655c2f 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 89c4b41b4..cec5f8eb4 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index d7c5b6bb0..420c72cfe 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index c36b06450..c7f1f152f 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 35485e4db..cf2e1cc1c 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 664c972d1..6415b538d 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index dbd70d9a0..f4cc81754 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 96fd4e2c4..71311c2c9 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 548994f5b..6e29a82da 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 88b4d0942..6a7562b8c 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 6140f2cc7..7a164257c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index a6f37d0a6..3b8510f89 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 88fa7ad0c..538d2be49 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 1cc6dd58b..825c122cf 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3908--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index a19bd82dd..c233b22f7 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.3908-develop'; + gc_version constant varchar2(50) := 'v3.1.13.3931-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ed936458138849bd4c38009cc45ea75f05fe0b1d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 4 Mar 2022 00:48:22 +0200 Subject: [PATCH 307/887] Fixing stability of data setup rename of test_package_3 to testing_package_3 to avoid odd behavior on 11g --- .../annotations/test_annot_disabled_reason.pkb | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb b/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb index e3df44425..7f1e068a8 100644 --- a/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb +++ b/test/ut3_tester/core/annotations/test_annot_disabled_reason.pkb @@ -115,7 +115,7 @@ end test_package_2;]'; end test_package_2;]'; - execute immediate q'[create or replace package test_package_3 is + execute immediate q'[create or replace package testing_package_3 is --%suite --%displayname(Disable tests on test level) @@ -144,9 +144,9 @@ end test_package_2;]'; --%endcontext -end test_package_3;]'; +end testing_package_3;]'; - execute immediate q'[create or replace package body test_package_3 is + execute immediate q'[create or replace package body testing_package_3 is procedure test1 is begin @@ -168,7 +168,7 @@ end test_package_3;]'; ut.expect(2).to_equal(2); end; -end test_package_3;]'; +end testing_package_3;]'; execute immediate q'[create or replace package test_package_4 is @@ -334,10 +334,10 @@ end test_package_6;]'; begin execute immediate 'drop package test_package_1'; execute immediate 'drop package test_package_2'; - execute immediate 'drop package test_package_3'; - execute immediate 'drop package test_package_4'; - execute immediate 'drop package test_package_5'; - execute immediate 'drop package test_package_6'; + execute immediate 'drop package testing_package_3'; + execute immediate 'drop package test_package_4'; + execute immediate 'drop package test_package_5'; + execute immediate 'drop package test_package_6'; end; procedure test_disable_on_suite_level is @@ -394,7 +394,7 @@ end test_package_6;]'; begin --Act - select * bulk collect into l_test_results from table(ut3_develop.ut.run((sys_context('USERENV', 'CURRENT_USER')||'.test_package_3'))); + select * bulk collect into l_test_results from table(ut3_develop.ut.run((sys_context('USERENV', 'CURRENT_USER')||'.testing_package_3'))); l_actual_message := ut3_develop.ut_utils.table_to_clob(l_test_results); From 85fd36d222680ebe1420d0fe40ed34520595a0b2 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 3 Mar 2022 22:56:23 +0000 Subject: [PATCH 308/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 718422bd7..846862073 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index dce7a66bd..c03c53846 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 73bb5df36..7a49d944f 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index c11655c2f..af0c3f5f1 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index cec5f8eb4..e87cd94d9 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 420c72cfe..ae00602cf 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index c7f1f152f..53d291fa3 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index cf2e1cc1c..4d7517f7d 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 6415b538d..82c4c34b2 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index f4cc81754..5fbec44a0 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index e13de9936..7129cd87c 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 6e29a82da..9668b49ef 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 6a7562b8c..42ff5ddd1 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 7a164257c..a68c427a4 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3b8510f89..804cd64f6 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 46499273b..92d77cdba 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 825c122cf..b7399c1f6 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3931--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c233b22f7..27979bf38 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.3931-develop'; + gc_version constant varchar2(50) := 'v3.1.13.3935-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 61ce1bb2380e7335132f206dba7ad7008c0f61ed Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 14 Mar 2022 01:13:46 +0200 Subject: [PATCH 309/887] Removed test users env variables Those variables are not needed and bring no real benefit asu the usernames actually cannot be configured and even if they were, there would be no real benefit to it. --- .github/scripts/create_test_users.sh | 50 ++++++++++++++-------------- .github/variables/.env | 8 +---- development/cleanup.sh | 6 ++-- development/template.env.sh | 7 ---- test/install_tests.sh | 6 ++-- test/run_tests.sh | 2 +- 6 files changed, 33 insertions(+), 46 deletions(-) diff --git a/.github/scripts/create_test_users.sh b/.github/scripts/create_test_users.sh index 43f64784d..fe43b7467 100755 --- a/.github/scripts/create_test_users.sh +++ b/.github/scripts/create_test_users.sh @@ -13,14 +13,14 @@ PROMPT Adding back create-trigger privilege to $UT3_DEVELOP_SCHEMA for testing grant administer database trigger to $UT3_DEVELOP_SCHEMA; -------------------------------------------------------------------------------- -PROMPT Creating $UT3_TESTER - Power-user for testing internal framework code +PROMPT Creating UT3_TESTER - Power-user for testing internal framework code -create user $UT3_TESTER identified by "$UT3_TESTER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; -grant create session, create procedure, create type, create table to $UT3_TESTER; +create user UT3_TESTER identified by "ut3" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; +grant create session, create procedure, create type, create table to UT3_TESTER; -grant execute on dbms_lock to $UT3_TESTER; +grant execute on dbms_lock to UT3_TESTER; -PROMPT Granting $UT3_DEVELOP_SCHEMA code to $UT3_TESTER +PROMPT Granting $UT3_DEVELOP_SCHEMA code to UT3_TESTER begin for i in ( @@ -30,31 +30,31 @@ begin and generated = 'N' and object_name not like 'SYS%') loop - execute immediate 'grant execute on $UT3_DEVELOP_SCHEMA."'||i.object_name||'" to $UT3_TESTER'; + execute immediate 'grant execute on $UT3_DEVELOP_SCHEMA."'||i.object_name||'" to UT3_TESTER'; end loop; end; / -PROMPT Granting $UT3_DEVELOP_SCHEMA tables to $UT3_TESTER +PROMPT Granting $UT3_DEVELOP_SCHEMA tables to UT3_TESTER begin for i in ( select table_name from all_tables t where owner = '$UT3_DEVELOP_SCHEMA' and nested = 'NO' and iot_name is null) loop - execute immediate 'grant select on $UT3_DEVELOP_SCHEMA.'||i.table_name||' to $UT3_TESTER'; + execute immediate 'grant select on $UT3_DEVELOP_SCHEMA.'||i.table_name||' to UT3_TESTER'; end loop; end; / -------------------------------------------------------------------------------- -PROMPT Creating $UT3_USER - minimal privileges user for API testing +PROMPT Creating UT3_USER - minimal privileges user for API testing -create user $UT3_USER identified by "$UT3_USER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; -grant create session, create procedure, create type, create table to $UT3_USER; +create user UT3_USER identified by "ut3" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; +grant create session, create procedure, create type, create table to UT3_USER; -PROMPT Grants for starting a debugging session from $UT3_USER -grant debug connect session to $UT3_USER; -grant debug any procedure to $UT3_USER; +PROMPT Grants for starting a debugging session from UT3_USER +grant debug connect session to UT3_USER; +grant debug any procedure to UT3_USER; begin \$if dbms_db_version.version <= 11 \$then null; -- no addition action necessary @@ -64,7 +64,7 @@ begin host =>'*', ace => sys.xs\$ace_type( privilege_list => sys.xs\$name_list('JDWP') , - principal_name => '$UT3_USER', + principal_name => 'UT3_USER', principal_type => sys.xs_acl.ptype_db ) ); @@ -73,29 +73,29 @@ end; / -------------------------------------------------------------------------------- -PROMPT Creating $UT3_TESTER_HELPER - provides functions to allow min grant test user setup tests. +PROMPT Creating UT3_TESTER_HELPER - provides functions to allow min grant test user setup tests. -create user $UT3_TESTER_HELPER identified by "$UT3_TESTER_HELPER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; -grant create session, create procedure, create type, create table to $UT3_TESTER_HELPER; +create user UT3_TESTER_HELPER identified by "ut3" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; +grant create session, create procedure, create type, create table to UT3_TESTER_HELPER; PROMPT Grants for testing distributed transactions -grant create public database link to $UT3_TESTER_HELPER; -grant drop public database link to $UT3_TESTER_HELPER; +grant create public database link to UT3_TESTER_HELPER; +grant drop public database link to UT3_TESTER_HELPER; PROMPT Grants for testing coverage outside of main $UT3_DEVELOP_SCHEMA schema. grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type, select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table, select any dictionary, create any synonym, drop any synonym, grant any object privilege, grant any privilege, create public synonym, drop public synonym, create any trigger - to $UT3_TESTER_HELPER; + to UT3_TESTER_HELPER; -grant create job to $UT3_TESTER_HELPER; +grant create job to UT3_TESTER_HELPER; PROMPT Additional grants for disabling DDL trigger and testing parser without trigger enabled/present -grant alter any trigger to $UT3_TESTER_HELPER; -grant administer database trigger to $UT3_TESTER_HELPER; -grant execute on dbms_lock to $UT3_TESTER_HELPER; +grant alter any trigger to UT3_TESTER_HELPER; +grant administer database trigger to UT3_TESTER_HELPER; +grant execute on dbms_lock to UT3_TESTER_HELPER; create user ut3_cache_test_owner identified by ut3; grant create session, create procedure to ut3_cache_test_owner; diff --git a/.github/variables/.env b/.github/variables/.env index e0a579d52..7bb5003e8 100644 --- a/.github/variables/.env +++ b/.github/variables/.env @@ -3,12 +3,6 @@ UT3_DEVELOP_SCHEMA=UT3_DEVELOP UT3_DEVELOP_SCHEMA_PASSWORD=ut3 UT3_RELEASE_VERSION_SCHEMA=UT3 UT3_RELEASE_VERSION_SCHEMA_PASSWORD=ut3 -UT3_USER='UT3_USER' -UT3_USER_PASSWORD=ut3 -UT3_TESTER=UT3_TESTER -UT3_TESTER_PASSWORD=ut3 -UT3_TESTER_HELPER=UT3_TESTER_HELPER -UT3_TESTER_HELPER_PASSWORD=ut3 UT3_TABLESPACE=users # Database Env @@ -30,4 +24,4 @@ GIT_COMMITTER_NAME="github-actions[bot]" GIT_COMMITTER_EMAIL="github-actions[bot]@users.noreply.github.com" #Docker environment for running utPLSQL install commands -DOCKER_ENV="-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" \ No newline at end of file +DOCKER_ENV="-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" \ No newline at end of file diff --git a/development/cleanup.sh b/development/cleanup.sh index c13ddb4aa..33358302a 100755 --- a/development/cleanup.sh +++ b/development/cleanup.sh @@ -20,9 +20,9 @@ end; drop user ${UT3_DEVELOP_SCHEMA} cascade; drop user ${UT3_RELEASE_VERSION_SCHEMA} cascade; -drop user ${UT3_TESTER} cascade; -drop user ${UT3_TESTER_HELPER} cascade; -drop user ${UT3_USER} cascade; +drop user ut3_tester cascade; +drop user ut3_tester_helper cascade; +drop user ut3_user cascade; drop user ut3_cache_test_owner cascade; drop user ut3_no_extra_priv_user cascade; drop user ut3_select_catalog_user cascade; diff --git a/development/template.env.sh b/development/template.env.sh index 521d9343d..e69aa81aa 100755 --- a/development/template.env.sh +++ b/development/template.env.sh @@ -12,11 +12,4 @@ export UT3_DEVELOP_SCHEMA=UT3_DEVELOP export UT3_DEVELOP_SCHEMA_PASSWORD=ut3 export UT3_RELEASE_VERSION_SCHEMA=UT3 export UT3_RELEASE_VERSION_SCHEMA_PASSWORD=ut3 -export UT3_TESTER=UT3_TESTER -export UT3_TESTER_PASSWORD=ut3 -export UT3_TESTER_HELPER=UT3_TESTER_HELPER -export UT3_TESTER_HELPER_PASSWORD=ut3 export UT3_TABLESPACE=users -export UT3_USER="UT3\$USER#" -export UT3_USER_PASSWORD=ut3 -export DOCKER_ENV="-e SQLCLI=sqlplus -e UT3_DEVELOP_SCHEMA -e UT3_DEVELOP_SCHEMA_PASSWORD -e UT3_RELEASE_VERSION_SCHEMA -e UT3_RELEASE_VERSION_SCHEMA_PASSWORD -e UT3_USER -e UT3_USER_PASSWORD -e UT3_TESTER -e UT3_TESTER_PASSWORD -e UT3_TESTER_HELPER -e UT3_TESTER_HELPER_PASSWORD -e UT3_TABLESPACE -e ORACLE_PWD -e CONNECTION_STR -e UTPLSQL_DIR" diff --git a/test/install_tests.sh b/test/install_tests.sh index 4ccc312e8..1b97ec33d 100755 --- a/test/install_tests.sh +++ b/test/install_tests.sh @@ -5,9 +5,9 @@ SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd ) cd ${SCRIPT_DIR} -"$SQLCLI" ${UT3_TESTER_HELPER}/${UT3_TESTER_HELPER_PASSWORD}@//${CONNECTION_STR} @install_ut3_tester_helper.sql +"$SQLCLI" UT3_TESTER_HELPER/ut3@//${CONNECTION_STR} @install_ut3_tester_helper.sql -"$SQLCLI" ${UT3_USER}/${UT3_USER_PASSWORD}@//${CONNECTION_STR} @install_ut3_user_tests.sql +"$SQLCLI" UT3_USER/ut3@//${CONNECTION_STR} @install_ut3_user_tests.sql -"$SQLCLI" ${UT3_TESTER}/${UT3_TESTER_PASSWORD}@//${CONNECTION_STR} @install_ut3_tester_tests.sql +"$SQLCLI" UT3_TESTER/ut3@//${CONNECTION_STR} @install_ut3_tester_tests.sql diff --git a/test/run_tests.sh b/test/run_tests.sh index ae4a739d9..118bab920 100755 --- a/test/run_tests.sh +++ b/test/run_tests.sh @@ -4,7 +4,7 @@ set -ev #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" -time utPLSQL-cli/bin/utplsql run ${UT3_TESTER_HELPER}/${UT3_TESTER_HELPER_PASSWORD}@${CONNECTION_STR} \ +time utPLSQL-cli/bin/utplsql run UT3_TESTER_HELPER/ut3@${CONNECTION_STR} \ -source_path=source -owner=ut3_develop \ -p='ut3_tester,ut3_user' \ -test_path=test -c \ From 8e54e91a844d87ea8029212269ab830910fccf65 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 14 Mar 2022 08:48:00 +0000 Subject: [PATCH 310/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 846862073..b93720226 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index c03c53846..a96043438 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 7a49d944f..1402d09ad 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index af0c3f5f1..9c2e9ee4a 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index e87cd94d9..740bc199a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index ae00602cf..72aca4936 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 53d291fa3..3017acdc5 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 4d7517f7d..8a7045e9c 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 82c4c34b2..018b206bd 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 5fbec44a0..7a1445c2d 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 7129cd87c..34f0970d5 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 9668b49ef..28cc3de62 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 42ff5ddd1..f1e96e50d 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index a68c427a4..2d947f391 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 804cd64f6..3ba397177 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 92d77cdba..f392dd1e5 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index b7399c1f6..5137e6490 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3935--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 27979bf38..aeff16dd8 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.3935-develop'; + gc_version constant varchar2(50) := 'v3.1.13.3940-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 86d4d0a76475a8a2eb78c1a1ae72e930c3afbf33 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 18 Mar 2022 16:33:57 +0000 Subject: [PATCH 311/887] Initial check-in. There is still no error handling. --- source/core/types/ut_path_item.tpb | 42 ++++++ source/core/types/ut_path_item.tps | 26 ++++ source/core/types/ut_path_items.tps | 19 +++ source/core/ut_suite_cache_manager.pkb | 182 ++++++++++++++++++++++++- source/core/ut_suite_cache_manager.pks | 6 + source/core/ut_suite_manager.pkb | 134 +++++++++--------- source/install.sql | 4 +- source/uninstall_objects.sql | 4 + 8 files changed, 354 insertions(+), 63 deletions(-) create mode 100644 source/core/types/ut_path_item.tpb create mode 100644 source/core/types/ut_path_item.tps create mode 100644 source/core/types/ut_path_items.tps diff --git a/source/core/types/ut_path_item.tpb b/source/core/types/ut_path_item.tpb new file mode 100644 index 000000000..3878b544c --- /dev/null +++ b/source/core/types/ut_path_item.tpb @@ -0,0 +1,42 @@ +create or replace type body ut_path_item as + /* + utPLSQL - Version 3 + Copyright 2016 - 2021 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2) return self as result is + begin + self.schema_name := schema_name; + self.object_name := object_name; + self.procedure_name := procedure_name; + return; + end; + + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2,suite_path varchar2) return self as result is + begin + self.schema_name := schema_name; + self.suite_path := suite_path; + return; + end; + + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2) return self as result is + begin + self.schema_name := schema_name; + self.object_name := object_name; + self.procedure_name := procedure_name; + self.suite_path := suite_path; + return; + end; +end; +/ \ No newline at end of file diff --git a/source/core/types/ut_path_item.tps b/source/core/types/ut_path_item.tps new file mode 100644 index 000000000..9a5ef51d0 --- /dev/null +++ b/source/core/types/ut_path_item.tps @@ -0,0 +1,26 @@ +create or replace type ut_path_item as object ( + /* + utPLSQL - Version 3 + Copyright 2016 - 2021 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + schema_name varchar2(4000), + object_name varchar2(250), + procedure_name varchar2(250), + suite_path varchar2(4000), + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2) return self as result, + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2,suite_path varchar2) return self as result, + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2) return self as result +) +/ \ No newline at end of file diff --git a/source/core/types/ut_path_items.tps b/source/core/types/ut_path_items.tps new file mode 100644 index 000000000..0c87cf28c --- /dev/null +++ b/source/core/types/ut_path_items.tps @@ -0,0 +1,19 @@ +create or replace type ut_path_items as + /* + utPLSQL - Version 3 + Copyright 2016 - 2021 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + table of ut_path_item +/ diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index ad1634c10..cc5cd0f19 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -20,7 +20,7 @@ create or replace package body ut_suite_cache_manager is * Private code */ - gc_get_cache_suite_sql constant varchar2(32767) := + gc_get_cache_suite_sql constant varchar2(32767) := q'[with suite_items as ( select /*+ cardinality(c 500) */ value(c) as obj @@ -83,6 +83,87 @@ create or replace package body ut_suite_cache_manager is from items c order by c.obj.object_owner,{:random_seed:}]'; + + gc_get_bulk_cache_suite_sql constant varchar2(32767) := + q'[with + suite_paths_tabs as ( + select schema_name,object_name,procedure_name,suite_path + from table(:l_schema_paths) + ), + suite_items as ( + select /*+ cardinality(c 500) */ value(c) as obj + from ut_suite_cache c, + suite_paths_tabs sp + where c.object_owner = upper(sp.schema_name) + and sp.suite_path is not null + and ( + sp.suite_path||'.' like c.path||'.%' /*all parents and self*/ + or + ( + c.path||'.' like sp.suite_path||'.%' /*all children and self*/ + and c.object_name like nvl(upper(sp.object_name),c.object_name) + and c.name like nvl(upper(sp.procedure_name),c.name) + ) + ) + union all + select /*+ cardinality(c 500) */ value(c) as obj + from ut_suite_cache c, + suite_paths_tabs sp + where c.object_owner = upper(sp.schema_name) + and sp.suite_path is null + and c.object_name like nvl(upper(replace(sp.object_name,'*','%')),c.object_name) + and c.name like nvl(upper(replace(sp.procedure_name,'*','%')),c.name) + ), + {:tags:} + suitepaths as ( + select distinct substr(c.obj.path,1,instr(c.obj.path,'.',-1)-1) as suitepath, + c.obj.path as path, + c.obj.object_owner as object_owner + from {:suite_item_name:} c + where c.obj.self_type = 'UT_SUITE' + ), + gen as ( + select rownum as pos + from xmltable('1 to 20') + ), + suitepath_part AS ( + select distinct + substr(b.suitepath, 1, instr(b.suitepath || '.', '.', 1, g.pos) -1) as path, + object_owner + from suitepaths b + join gen g + on g.pos <= regexp_count(b.suitepath, '\w+') + ), + logical_suite_data as ( + select 'UT_LOGICAL_SUITE' as self_type, p.path, p.object_owner, + upper( substr(p.path, instr( p.path, '.', -1 ) + 1 ) ) as object_name, + cast(null as ut_executables) as x, + cast(null as ut_varchar2_rows) as y, + cast(null as ut_executable_test) as z + from suitepath_part p + where p.path + not in (select s.path from suitepaths s) + ), + logical_suites as ( + select ut_suite_cache_row( + null, + s.self_type, s.path, s.object_owner, s.object_name, + s.object_name, null, null, null, null, 0,null, + ut_varchar2_rows(), + s.x, s.x, s.x, s.x, s.x, s.x, + s.y, null, s.z + ) as obj + from logical_suite_data s + ), + items as ( + select obj from {:suite_item_name:} + union all + select obj from logical_suites + ) + select /*+ no_parallel */ c.obj + from items c + order by c.obj.object_owner,{:random_seed:}]'; + function get_missing_cache_objects(a_object_owner varchar2) return ut_varchar2_rows is l_result ut_varchar2_rows; l_data ut_annotation_objs_cache_info; @@ -190,6 +271,29 @@ create or replace package body ut_suite_cache_manager is ) desc nulls last' end; end; + + --Possible move logic to type + function group_paths_by_schema(a_paths ut_varchar2_list) return ut_path_items is + c_package_path_regex constant varchar2(100) := '^([A-Za-z0-9$#_]+)(\.([A-Za-z0-9$#_\*]+))?(\.([A-Za-z0-9$#_\*]+))?$'; + l_results ut_path_items := ut_path_items(); + l_path_item ut_path_item; + begin + for i in 1 .. a_paths.count loop + l_results.extend; + if a_paths(i) like '%:%' then + l_path_item := ut_path_item(upper(regexp_substr(a_paths(i),'^[^.:]+')), + ltrim(regexp_substr(a_paths(i),'[.:].*$'),':')); + l_results(l_results.last) := l_path_item; + else + l_path_item := ut_path_item(regexp_substr(a_paths(i), c_package_path_regex, subexpression => 1), + regexp_substr(a_paths(i), c_package_path_regex, subexpression => 3), + regexp_substr(a_paths(i), c_package_path_regex, subexpression => 5)); + l_results(l_results.last) := l_path_item; + end if; + end loop; + + return l_results; + end; @@ -254,6 +358,82 @@ create or replace package body ut_suite_cache_manager is using upper(l_object_owner), l_path, l_path, upper(a_object_name), upper(a_procedure_name), l_include_tags, l_include_tags, l_exclude_tags, a_random_seed; return l_results; end; + + function expand_paths(a_schema_paths ut_path_items) return ut_path_items is + l_schema_paths ut_path_items:= ut_path_items(); + begin + with paths_to_expand as ( + select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(sp.object_name,c.object_name) as object_name,sp.procedure_name as procedure_name + from ut_suite_cache c, + table(a_schema_paths) sp + where c.object_owner = upper(sp.schema_name) + and c.object_name like nvl(replace(upper(sp.object_name),'*','%'),c.object_name) + and c.name like nvl(replace(upper(sp.procedure_name),'*','%'), c.name) + and sp.suite_path is null + group by sp.schema_name,nvl(sp.object_name,c.object_name),sp.procedure_name + union all + select /*+ no_parallel */ c.path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name + from + ut_suite_cache c, + table(a_schema_paths) sp + where c.object_owner = upper(sp.schema_name) + and sp.suite_path is not null + and instr(sp.suite_path,'*') > 0 + and c.path like replace(sp.suite_path,'*','%') + union all + select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name + from table(a_schema_paths) sp + where sp.suite_path is not null + and instr(sp.suite_path,'*') = 0 + ) + select ut_path_item(schema_name,object_name,procedure_name,suite_path) + bulk collect into l_schema_paths + from paths_to_expand; + return l_schema_paths; + end; + + function get_cached_suite_rows( + a_paths ut_varchar2_list, + a_random_seed positive := null, + a_tags ut_varchar2_rows := null + ) return ut_suite_cache_rows is + l_results ut_suite_cache_rows := ut_suite_cache_rows(); + l_schema_paths ut_path_items; + l_tags ut_varchar2_rows := coalesce(a_tags,ut_varchar2_rows()); + l_include_tags ut_varchar2_rows; + l_exclude_tags ut_varchar2_rows; + l_suite_item_name varchar2(20); + l_paths ut_varchar2_rows; + l_schema varchar2(4000); + l_sql varchar2(32767); + begin + select /*+ no_parallel */ column_value + bulk collect into l_include_tags + from table(l_tags) + where column_value not like '-%'; + + select /*+ no_parallel */ ltrim(column_value,'-') + bulk collect into l_exclude_tags + from table(l_tags) + where column_value like '-%'; + + l_schema_paths := expand_paths(group_paths_by_schema(a_paths)); + --We still need to turn this into qualified SQL name....maybe as part of results ? + l_suite_item_name := case when l_tags.count > 0 then 'suite_items_tags' else 'suite_items' end; + + l_sql := gc_get_bulk_cache_suite_sql; + l_sql := replace(l_sql,'{:suite_item_name:}',l_suite_item_name); + l_sql := replace(l_sql,'{:tags:}',get_tags_sql(l_tags.count)); + l_sql := replace(l_sql,'{:random_seed:}',get_random_seed_sql(a_random_seed)); + ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_key_anyvalues().put('l_sql',l_sql) ); + + execute immediate l_sql + bulk collect into l_results + using l_schema_paths, l_include_tags, l_include_tags, l_exclude_tags, a_random_seed; + return l_results; + end; + + function get_schema_parse_time(a_schema_name varchar2) return timestamp result_cache is l_cache_parse_time timestamp; diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 0a38851fe..10444a4d2 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -53,6 +53,12 @@ create or replace package ut_suite_cache_manager authid definer is a_random_seed positive := null, a_tags ut_varchar2_rows := null ) return ut_suite_cache_rows; + + function get_cached_suite_rows( + a_paths ut_varchar2_list, + a_random_seed positive := null, + a_tags ut_varchar2_rows := null + ) return ut_suite_cache_rows; /* * Retrieves suite item info rows from cache. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 4bcb83afa..2f081d2c2 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -18,14 +18,6 @@ create or replace package body ut_suite_manager is gc_suitpath_error_message constant varchar2(100) := 'Suitepath exceeds 1000 CHAR on: '; - type t_path_item is record ( - object_name varchar2(250), - procedure_name varchar2(250), - suite_path varchar2(4000) - ); - type t_path_items is table of t_path_item; - type t_schema_paths is table of t_path_items index by varchar2(250 char); - cursor c_cached_suites_cursor is select * from table(ut_suite_cache_rows()); type tt_cached_suites is table of c_cached_suites_cursor%rowtype; type t_cached_suites_cursor is ref cursor return c_cached_suites_cursor%rowtype; @@ -41,7 +33,8 @@ create or replace package body ut_suite_manager is else for i in 1 .. a_paths.count loop l_path := a_paths(i); - if l_path is null or not (regexp_like(l_path, '^[A-Za-z0-9$#_]+(\.[A-Za-z0-9$#_]+){0,2}$') or regexp_like(l_path, '^([A-Za-z0-9$#_]+)?:[A-Za-z0-9$#_]+(\.[A-Za-z0-9$#_]+)*$')) then + if l_path is null or not ( + regexp_like(l_path, '^[A-Za-z0-9$#_\*]+(\.[A-Za-z0-9$#_\*]+){0,2}$') or regexp_like(l_path, '^([A-Za-z0-9$#_]+)?:[A-Za-z0-9$#_\*]+(\.[A-Za-z0-9$#_\*]+)*$')) then raise_application_error(ut_utils.gc_invalid_path_format, 'Invalid path format: ' || nvl(l_path, 'NULL')); end if; end loop; @@ -84,12 +77,17 @@ create or replace package body ut_suite_manager is -- get schema name / object.[procedure] name -- When path is one of: schema or schema.package[.object] or package[.object] -- transform it back to schema[.package[.object]] + -- Object name or procedure is allowed to have filter char + -- However this is not allowed on schema begin - l_object := regexp_substr(a_paths(i), '^[A-Za-z0-9$#_]+'); + l_object := regexp_substr(a_paths(i), '^[A-Za-z0-9$#_\*]+'); l_schema := sys.dbms_assert.schema_name(upper(l_object)); exception when sys.dbms_assert.invalid_schema_name then - if ut_metadata.package_exists_in_cur_schema(upper(l_object)) then + if l_object like '%*%' then + a_paths(i) := c_current_schema || '.' || a_paths(i); + l_schema := c_current_schema; + elsif ut_metadata.package_exists_in_cur_schema(upper(l_object)) then a_paths(i) := c_current_schema || '.' || a_paths(i); l_schema := c_current_schema; else @@ -110,34 +108,6 @@ create or replace package body ut_suite_manager is l_schema_names := resolve_schema_names(a_paths); end; - function group_paths_by_schema(a_paths ut_varchar2_list) return t_schema_paths is - c_package_path_regex constant varchar2(100) := '^([A-Za-z0-9$#_]+)(\.([A-Za-z0-9$#_]+))?(\.([A-Za-z0-9$#_]+))?$'; - l_schema varchar2(4000); - l_empty_result t_path_item; - l_result t_path_item; - l_results t_schema_paths; - begin - for i in 1 .. a_paths.count loop - l_result := l_empty_result; - if a_paths(i) like '%:%' then - l_schema := upper(regexp_substr(a_paths(i),'^[^.:]+')); - l_result.suite_path := ltrim(regexp_substr(a_paths(i),'[.:].*$'),':'); - else - l_schema := regexp_substr(a_paths(i), c_package_path_regex, subexpression => 1); - l_result.object_name := regexp_substr(a_paths(i), c_package_path_regex, subexpression => 3); - l_result.procedure_name := regexp_substr(a_paths(i), c_package_path_regex, subexpression => 5); - end if; - if l_results.exists(l_schema) then - l_results(l_schema).extend; - l_results(l_schema)(l_results(l_schema).last) := l_result; - else - l_results(l_schema) := t_path_items(l_result); - end if; - end loop; - return l_results; - end; - - function sort_by_seq_no( a_list ut_executables ) return ut_executables is @@ -370,6 +340,45 @@ create or replace package body ut_suite_manager is return l_result; end; + function get_cached_suite_data( + a_paths ut_varchar2_list, + a_random_seed positive, + a_tags ut_varchar2_rows := null + ) return t_cached_suites_cursor is + l_unfiltered_rows ut_suite_cache_rows; + l_result t_cached_suites_cursor; + begin + l_unfiltered_rows := ut_suite_cache_manager.get_cached_suite_rows( + a_paths, + a_random_seed, + a_tags + ); + + if ut_metadata.user_has_execute_any_proc() then + open l_result for + select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c; + else + open l_result for + select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c + where sys_context( 'userenv', 'current_user' ) = upper(c.object_owner) + union all + select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c + where sys_context( 'userenv', 'current_user' ) != upper(c.object_owner) + and ( exists + ( select 1 + from all_objects a + where a.object_name = c.object_name + and a.owner = c.object_owner + and a.object_type = 'PACKAGE' + ) + or c.self_type = 'UT_LOGICAL_SUITE'); + + end if; + return l_result; + + return l_result; + end; + function can_skip_all_objects_scan( a_owner_name varchar2 ) return boolean is @@ -442,31 +451,21 @@ create or replace package body ut_suite_manager is ut_event_manager.trigger_event('refresh_cache - end'); end; - procedure add_suites_for_path( - a_owner_name varchar2, - a_path varchar2 := null, - a_object_name varchar2 := null, - a_procedure_name varchar2 := null, + procedure add_suites_for_paths( + a_paths ut_varchar2_list, a_suites in out nocopy ut_suite_items, a_random_seed positive, a_tags ut_varchar2_rows := null ) is begin - refresh_cache(a_owner_name); - reconstruct_from_cache( a_suites, get_cached_suite_data( - a_owner_name, - a_path, - a_object_name, - a_procedure_name, - can_skip_all_objects_scan(a_owner_name), + a_paths, a_random_seed, a_tags ) ); - end; ----------------------------------------------- @@ -530,20 +529,32 @@ create or replace package body ut_suite_manager is a_tags ut_varchar2_rows := ut_varchar2_rows() ) is l_paths ut_varchar2_list := a_paths; - l_path_items t_path_items; - l_path_item t_path_item; + l_schema_names ut_varchar2_rows; l_schema varchar2(4000); l_suites_count pls_integer := 0; l_index varchar2(4000 char); - l_schema_paths t_schema_paths; begin ut_event_manager.trigger_event('configure_execution_by_path - start'); - a_suites := ut_suite_items(); + a_suites := ut_suite_items(); --resolve schema names from paths and group paths by schema name - resolve_schema_names(l_paths); - - l_schema_paths := group_paths_by_schema(l_paths); + l_schema_names := resolve_schema_names(l_paths); + --refresh cache + l_schema := l_schema_names.first; + while l_schema is not null loop + refresh_cache(upper(l_schema_names(l_schema))); + l_schema := l_schema_names.next(l_schema); + end loop; + + --We will get a single list of paths rather than loop by loop. + add_suites_for_paths( + l_paths, + a_suites, + a_random_seed, + a_tags + ); + + /* l_schema := l_schema_paths.first; while l_schema is not null loop l_path_items := l_schema_paths(l_schema); @@ -571,8 +582,9 @@ create or replace package body ut_suite_manager is l_suites_count := a_suites.count; end loop; l_schema := l_schema_paths.next(l_schema); - end loop; - + end loop;*/ + + --propagate rollback type to suite items after organizing suites into hierarchy for i in 1 .. a_suites.count loop a_suites(i).set_rollback_type( a_suites(i).get_rollback_type() ); diff --git a/source/install.sql b/source/install.sql index cda057bdf..6f3c16801 100644 --- a/source/install.sql +++ b/source/install.sql @@ -89,7 +89,8 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/types/ut_run.tps' @@install_component.sql 'core/types/ut_reporter_base.tps' @@install_component.sql 'core/types/ut_reporters.tps' - +@@install_component.sql 'core/types/ut_path_item.tps' +@@install_component.sql 'core/types/ut_path_items.tps' @@install_component.sql 'expectations/json_objects_specs.sql' @@install_component.sql 'expectations/matchers/ut_matcher_options_items.tps' @@ -207,6 +208,7 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'core/types/ut_executable_test.tpb' @@install_component.sql 'core/types/ut_console_reporter_base.tps' @@install_component.sql 'core/types/ut_console_reporter_base.tpb' +@@install_component.sql 'core/types/ut_path_item.tpb' --expectations and matchers @@install_component.sql 'expectations/data_values/ut_compound_data_tmp.sql' diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 4d77d9993..ab4069497 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -88,6 +88,10 @@ drop type ut_suite_items_info force; drop type ut_suite_item_info force; +drop type ut_path_items force; + +drop type ut_path_item force; + drop package ut_suite_manager; drop package ut_suite_builder; From f1f6d71db4728e89413b5ab52a0e973cd3ff5f58 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 19 Mar 2022 14:12:28 +0000 Subject: [PATCH 312/887] Tidy up code to make sure we got distinct set of expanded tests. Addressing issue of WITH error ORA-32036: unsupported case for inlining of query name in WITH clause --- source/core/ut_suite_cache_manager.pkb | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index cc5cd0f19..562435e0f 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -85,15 +85,11 @@ create or replace package body ut_suite_cache_manager is gc_get_bulk_cache_suite_sql constant varchar2(32767) := - q'[with - suite_paths_tabs as ( - select schema_name,object_name,procedure_name,suite_path - from table(:l_schema_paths) - ), + q'[with suite_items as ( select /*+ cardinality(c 500) */ value(c) as obj from ut_suite_cache c, - suite_paths_tabs sp + table(:l_schema_paths) sp where c.object_owner = upper(sp.schema_name) and sp.suite_path is not null and ( @@ -108,7 +104,7 @@ create or replace package body ut_suite_cache_manager is union all select /*+ cardinality(c 500) */ value(c) as obj from ut_suite_cache c, - suite_paths_tabs sp + table(:l_schema_paths) sp where c.object_owner = upper(sp.schema_name) and sp.suite_path is null and c.object_name like nvl(upper(replace(sp.object_name,'*','%')),c.object_name) @@ -388,7 +384,11 @@ create or replace package body ut_suite_cache_manager is ) select ut_path_item(schema_name,object_name,procedure_name,suite_path) bulk collect into l_schema_paths - from paths_to_expand; + from + (select schema_name,object_name,procedure_name,suite_path, + row_number() over ( partition by schema_name,object_name,procedure_name,suite_path order by 1) r_num + from paths_to_expand) + where r_num = 1 ; return l_schema_paths; end; @@ -429,7 +429,7 @@ create or replace package body ut_suite_cache_manager is execute immediate l_sql bulk collect into l_results - using l_schema_paths, l_include_tags, l_include_tags, l_exclude_tags, a_random_seed; + using l_schema_paths, l_schema_paths, l_include_tags, l_include_tags, l_exclude_tags, a_random_seed; return l_results; end; From 01ec694a0289562f7434699493fa6dbed5af7022 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 19 Mar 2022 17:14:08 +0000 Subject: [PATCH 313/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index b93720226..ad0cad34c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index a96043438..9641132fd 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 1402d09ad..c1eefa2dd 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 9c2e9ee4a..5812e2cab 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 740bc199a..140c3e3dd 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 72aca4936..9e4528342 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 3017acdc5..a2612c3b8 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 8a7045e9c..9c90a1865 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 018b206bd..2c262abbf 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 7a1445c2d..27dfc6c1f 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 34f0970d5..8e1872497 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 28cc3de62..3aa97dcb8 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index f1e96e50d..08308bc8a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 2d947f391..11e08be1d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3ba397177..373830f95 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index f392dd1e5..d3fcfd520 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 5137e6490..bf5cf8c7b 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3940--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index aeff16dd8..027a06c21 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.3940-develop'; + gc_version constant varchar2(50) := 'v3.1.13.3943-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 1454221535f2dc53e2e776a1bbf97bc09da8a079 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 23 Mar 2022 19:45:20 +0000 Subject: [PATCH 314/887] Adding extra fields. --- source/core/types/ut_path_item.tpb | 9 ++- source/core/types/ut_path_item.tps | 15 +++-- source/core/ut_suite_cache_manager.pkb | 67 +++++++++++-------- source/core/ut_suite_cache_manager.pks | 4 +- source/core/ut_suite_manager.pkb | 93 ++++++++++++++++++-------- source/core/ut_suite_manager.pks | 4 ++ 6 files changed, 126 insertions(+), 66 deletions(-) diff --git a/source/core/types/ut_path_item.tpb b/source/core/types/ut_path_item.tpb index 3878b544c..2973b3412 100644 --- a/source/core/types/ut_path_item.tpb +++ b/source/core/types/ut_path_item.tpb @@ -15,27 +15,30 @@ create or replace type body ut_path_item as See the License for the specific language governing permissions and limitations under the License. */ - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2) return self as result is + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2, originated_path varchar2) return self as result is begin self.schema_name := schema_name; self.object_name := object_name; self.procedure_name := procedure_name; + self.originated_path := originated_path; return; end; - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2,suite_path varchar2) return self as result is + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2,suite_path varchar2, originated_path varchar2) return self as result is begin self.schema_name := schema_name; self.suite_path := suite_path; + self.originated_path := originated_path; return; end; - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2) return self as result is + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2, originated_path varchar2) return self as result is begin self.schema_name := schema_name; self.object_name := object_name; self.procedure_name := procedure_name; self.suite_path := suite_path; + self.originated_path := originated_path; return; end; end; diff --git a/source/core/types/ut_path_item.tps b/source/core/types/ut_path_item.tps index 9a5ef51d0..c4b751abc 100644 --- a/source/core/types/ut_path_item.tps +++ b/source/core/types/ut_path_item.tps @@ -15,12 +15,13 @@ create or replace type ut_path_item as object ( See the License for the specific language governing permissions and limitations under the License. */ - schema_name varchar2(4000), - object_name varchar2(250), - procedure_name varchar2(250), - suite_path varchar2(4000), - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2) return self as result, - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2,suite_path varchar2) return self as result, - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2) return self as result + schema_name varchar2(4000), + object_name varchar2(250), + procedure_name varchar2(250), + suite_path varchar2(4000), + originated_path varchar2(4000), + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2, originated_path varchar2) return self as result, + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, suite_path varchar2, originated_path varchar2) return self as result, + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2, originated_path varchar2) return self as result ) / \ No newline at end of file diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 562435e0f..aea6fc24b 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -277,13 +277,15 @@ create or replace package body ut_suite_cache_manager is for i in 1 .. a_paths.count loop l_results.extend; if a_paths(i) like '%:%' then - l_path_item := ut_path_item(upper(regexp_substr(a_paths(i),'^[^.:]+')), - ltrim(regexp_substr(a_paths(i),'[.:].*$'),':')); + l_path_item := ut_path_item(schema_name => upper(regexp_substr(a_paths(i),'^[^.:]+')), + suite_path => ltrim(regexp_substr(a_paths(i),'[.:].*$'),':'), + originated_path => a_paths(i)); l_results(l_results.last) := l_path_item; else - l_path_item := ut_path_item(regexp_substr(a_paths(i), c_package_path_regex, subexpression => 1), - regexp_substr(a_paths(i), c_package_path_regex, subexpression => 3), - regexp_substr(a_paths(i), c_package_path_regex, subexpression => 5)); + l_path_item := ut_path_item(schema_name => regexp_substr(a_paths(i), c_package_path_regex, subexpression => 1), + object_name => regexp_substr(a_paths(i), c_package_path_regex, subexpression => 3), + procedure_name => regexp_substr(a_paths(i), c_package_path_regex, subexpression => 5), + originated_path => a_paths(i)); l_results(l_results.last) := l_path_item; end if; end loop; @@ -359,41 +361,50 @@ create or replace package body ut_suite_cache_manager is l_schema_paths ut_path_items:= ut_path_items(); begin with paths_to_expand as ( - select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(sp.object_name,c.object_name) as object_name,sp.procedure_name as procedure_name - from ut_suite_cache c, - table(a_schema_paths) sp - where c.object_owner = upper(sp.schema_name) - and c.object_name like nvl(replace(upper(sp.object_name),'*','%'),c.object_name) - and c.name like nvl(replace(upper(sp.procedure_name),'*','%'), c.name) - and sp.suite_path is null - group by sp.schema_name,nvl(sp.object_name,c.object_name),sp.procedure_name + select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(sp.object_name,c.object_name) as object_name, + sp.procedure_name as procedure_name,sp.originated_path + from table(a_schema_paths) sp left outer join ut_suite_cache c + on ( c.object_owner = upper(sp.schema_name) + and c.object_name like replace(upper(sp.object_name),'*','%') + and c.name like nvl(replace(upper(sp.procedure_name),'*','%'), c.name)) + where sp.suite_path is null + and sp.object_name is not null + group by sp.schema_name,nvl(sp.object_name,c.object_name),sp.procedure_name,sp.originated_path union all - select /*+ no_parallel */ c.path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name - from - ut_suite_cache c, - table(a_schema_paths) sp - where c.object_owner = upper(sp.schema_name) - and sp.suite_path is not null - and instr(sp.suite_path,'*') > 0 - and c.path like replace(sp.suite_path,'*','%') + select /*+ no_parallel */ c.path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name,sp.originated_path + from + table(a_schema_paths) sp left outer join ut_suite_cache c on + ( c.object_owner = upper(sp.schema_name) + and sp.suite_path is not null + and instr(sp.suite_path,'*') > 0) + where c.path like replace(sp.suite_path,'*','%') union all - select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name - from table(a_schema_paths) sp + select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name,sp.originated_path + from table(a_schema_paths) sp where sp.suite_path is not null - and instr(sp.suite_path,'*') = 0 + and instr(sp.suite_path,'*') = 0 + union all + select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name,sp.originated_path + from table(a_schema_paths) sp + where sp.suite_path is null and sp.object_name is null ) - select ut_path_item(schema_name,object_name,procedure_name,suite_path) + select ut_path_item(schema_name,object_name,procedure_name,suite_path,originated_path) bulk collect into l_schema_paths from - (select schema_name,object_name,procedure_name,suite_path, + (select schema_name,object_name,procedure_name,suite_path,originated_path, row_number() over ( partition by schema_name,object_name,procedure_name,suite_path order by 1) r_num from paths_to_expand) where r_num = 1 ; return l_schema_paths; end; + function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items is + begin + return expand_paths(group_paths_by_schema(a_paths)); + end; + function get_cached_suite_rows( - a_paths ut_varchar2_list, + a_schema_paths ut_path_items, a_random_seed positive := null, a_tags ut_varchar2_rows := null ) return ut_suite_cache_rows is @@ -417,7 +428,7 @@ create or replace package body ut_suite_cache_manager is from table(l_tags) where column_value like '-%'; - l_schema_paths := expand_paths(group_paths_by_schema(a_paths)); + l_schema_paths := a_schema_paths; --We still need to turn this into qualified SQL name....maybe as part of results ? l_suite_item_name := case when l_tags.count > 0 then 'suite_items_tags' else 'suite_items' end; diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 10444a4d2..3e2ac6451 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -54,8 +54,10 @@ create or replace package ut_suite_cache_manager authid definer is a_tags ut_varchar2_rows := null ) return ut_suite_cache_rows; + function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items; + function get_cached_suite_rows( - a_paths ut_varchar2_list, + a_schema_paths ut_path_items, a_random_seed positive := null, a_tags ut_varchar2_rows := null ) return ut_suite_cache_rows; diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 2f081d2c2..2f019438c 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -18,10 +18,7 @@ create or replace package body ut_suite_manager is gc_suitpath_error_message constant varchar2(100) := 'Suitepath exceeds 1000 CHAR on: '; - cursor c_cached_suites_cursor is select * from table(ut_suite_cache_rows()); - type tt_cached_suites is table of c_cached_suites_cursor%rowtype; type t_cached_suites_cursor is ref cursor return c_cached_suites_cursor%rowtype; - type t_item_levels is table of ut_suite_items index by binary_integer; ------------------ @@ -339,30 +336,20 @@ create or replace package body ut_suite_manager is return l_result; end; - - function get_cached_suite_data( - a_paths ut_varchar2_list, - a_random_seed positive, - a_tags ut_varchar2_rows := null - ) return t_cached_suites_cursor is - l_unfiltered_rows ut_suite_cache_rows; + + function get_filtered_cursor(a_unfiltered_rows in ut_suite_cache_rows) + return t_cached_suites_cursor is l_result t_cached_suites_cursor; begin - l_unfiltered_rows := ut_suite_cache_manager.get_cached_suite_rows( - a_paths, - a_random_seed, - a_tags - ); - if ut_metadata.user_has_execute_any_proc() then open l_result for - select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c; + select /*+ no_parallel */ c.* from table(a_unfiltered_rows) c; else open l_result for - select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c + select /*+ no_parallel */ c.* from table(a_unfiltered_rows) c where sys_context( 'userenv', 'current_user' ) = upper(c.object_owner) union all - select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c + select /*+ no_parallel */ c.* from table(a_unfiltered_rows) c where sys_context( 'userenv', 'current_user' ) != upper(c.object_owner) and ( exists ( select 1 @@ -371,13 +358,61 @@ create or replace package body ut_suite_manager is and a.owner = c.object_owner and a.object_type = 'PACKAGE' ) - or c.self_type = 'UT_LOGICAL_SUITE'); - - end if; - return l_result; - + or c.self_type = 'UT_LOGICAL_SUITE'); + end if; return l_result; end; + + procedure reconcile_paths_and_suites( + a_schema_paths ut_path_items, + a_filtered_rows t_cached_suites_cursor + ) is + l_rows_tmp tt_cached_suites:= tt_cached_suites(); + l_rows tt_cached_suites := tt_cached_suites(); + l_limit number := 5000; + begin + loop + fetch a_filtered_rows bulk collect into l_rows_tmp limit l_limit; + l_rows := l_rows multiset union l_rows_tmp; + exit when a_filtered_rows%NOTFOUND; + end loop; + close a_filtered_rows; + + for i in ( select /*+ no_parallel */sp.schema_name,sp.object_name,sp.procedure_name, + sp.suite_path,sp.originated_path,sc.path + from table(a_schema_paths) sp left outer join + table(l_rows) sc on + (( upper(sp.schema_name) = upper(sc.object_owner) and upper(sp.object_name) = upper(sc.object_name) + and nvl(upper(sp.procedure_name),sc.name) = sc.name ) + or (sc.path = sp.suite_path)) + where sc.path is null) + loop + if i.suite_path is not null then + raise_application_error(ut_utils.gc_suite_package_not_found,'No suite packages found for path '||i.schema_name||':'||i.suite_path|| '.'); + elsif i.procedure_name is not null then + raise_application_error(ut_utils.gc_suite_package_not_found,'Suite test '||i.schema_name||'.'||i.object_name|| '.'||i.procedure_name||' does not exist'); + elsif i.object_name is not null then + raise_application_error(ut_utils.gc_suite_package_not_found,'Suite package '||i.schema_name||'.'||i.object_name|| ' does not exist'); + end if; + end loop; + end; + + function get_cached_suite_data( + a_schema_paths ut_path_items, + a_random_seed positive, + a_tags ut_varchar2_rows := null + ) return t_cached_suites_cursor is + l_unfiltered_rows ut_suite_cache_rows; + l_result t_cached_suites_cursor; + begin + l_unfiltered_rows := ut_suite_cache_manager.get_cached_suite_rows( + a_schema_paths, + a_random_seed, + a_tags + ); + reconcile_paths_and_suites(a_schema_paths,get_filtered_cursor(l_unfiltered_rows)); + return get_filtered_cursor(l_unfiltered_rows); + end; function can_skip_all_objects_scan( a_owner_name varchar2 @@ -452,7 +487,7 @@ create or replace package body ut_suite_manager is end; procedure add_suites_for_paths( - a_paths ut_varchar2_list, + a_schema_paths ut_path_items, a_suites in out nocopy ut_suite_items, a_random_seed positive, a_tags ut_varchar2_rows := null @@ -461,7 +496,7 @@ create or replace package body ut_suite_manager is reconstruct_from_cache( a_suites, get_cached_suite_data( - a_paths, + a_schema_paths, a_random_seed, a_tags ) @@ -530,6 +565,8 @@ create or replace package body ut_suite_manager is ) is l_paths ut_varchar2_list := a_paths; l_schema_names ut_varchar2_rows; + l_schema_paths ut_path_items; + l_reconcile_paths ut_path_items; l_schema varchar2(4000); l_suites_count pls_integer := 0; l_index varchar2(4000 char); @@ -546,9 +583,11 @@ create or replace package body ut_suite_manager is l_schema := l_schema_names.next(l_schema); end loop; + l_schema_paths := ut_suite_cache_manager.get_schema_paths(l_paths); + --We will get a single list of paths rather than loop by loop. add_suites_for_paths( - l_paths, + l_schema_paths, a_suites, a_random_seed, a_tags diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 5ae98d72a..e4160f599 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -20,6 +20,10 @@ create or replace package ut_suite_manager authid current_user is * Resposible for building hierarhy of sutes from individual suites created by suite_builder */ + cursor c_cached_suites_cursor is select * from table(ut_suite_cache_rows()); + type tt_cached_suites is table of c_cached_suites_cursor%rowtype; + + /** * @private * From ce4df285da6cd303fd38df345b0d68389dcaf348 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 29 Mar 2022 17:30:36 +0100 Subject: [PATCH 315/887] Stage 3. Fixing error calls. --- source/core/types/ut_path_item.tpb | 9 +- source/core/types/ut_path_item.tps | 7 +- source/core/ut_suite_cache_manager.pkb | 25 ++-- source/core/ut_suite_manager.pkb | 196 ++++++++++++++++++++++--- source/core/ut_suite_manager.pks | 3 - 5 files changed, 194 insertions(+), 46 deletions(-) diff --git a/source/core/types/ut_path_item.tpb b/source/core/types/ut_path_item.tpb index 2973b3412..3878b544c 100644 --- a/source/core/types/ut_path_item.tpb +++ b/source/core/types/ut_path_item.tpb @@ -15,30 +15,27 @@ create or replace type body ut_path_item as See the License for the specific language governing permissions and limitations under the License. */ - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2, originated_path varchar2) return self as result is + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2) return self as result is begin self.schema_name := schema_name; self.object_name := object_name; self.procedure_name := procedure_name; - self.originated_path := originated_path; return; end; - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2,suite_path varchar2, originated_path varchar2) return self as result is + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2,suite_path varchar2) return self as result is begin self.schema_name := schema_name; self.suite_path := suite_path; - self.originated_path := originated_path; return; end; - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2, originated_path varchar2) return self as result is + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2) return self as result is begin self.schema_name := schema_name; self.object_name := object_name; self.procedure_name := procedure_name; self.suite_path := suite_path; - self.originated_path := originated_path; return; end; end; diff --git a/source/core/types/ut_path_item.tps b/source/core/types/ut_path_item.tps index c4b751abc..f6c64195c 100644 --- a/source/core/types/ut_path_item.tps +++ b/source/core/types/ut_path_item.tps @@ -19,9 +19,8 @@ create or replace type ut_path_item as object ( object_name varchar2(250), procedure_name varchar2(250), suite_path varchar2(4000), - originated_path varchar2(4000), - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2, originated_path varchar2) return self as result, - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, suite_path varchar2, originated_path varchar2) return self as result, - constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2, originated_path varchar2) return self as result + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2) return self as result, + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, suite_path varchar2) return self as result, + constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2) return self as result ) / \ No newline at end of file diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index aea6fc24b..a83be01a0 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -278,14 +278,12 @@ create or replace package body ut_suite_cache_manager is l_results.extend; if a_paths(i) like '%:%' then l_path_item := ut_path_item(schema_name => upper(regexp_substr(a_paths(i),'^[^.:]+')), - suite_path => ltrim(regexp_substr(a_paths(i),'[.:].*$'),':'), - originated_path => a_paths(i)); + suite_path => ltrim(regexp_substr(a_paths(i),'[.:].*$'),':')); l_results(l_results.last) := l_path_item; else l_path_item := ut_path_item(schema_name => regexp_substr(a_paths(i), c_package_path_regex, subexpression => 1), object_name => regexp_substr(a_paths(i), c_package_path_regex, subexpression => 3), - procedure_name => regexp_substr(a_paths(i), c_package_path_regex, subexpression => 5), - originated_path => a_paths(i)); + procedure_name => regexp_substr(a_paths(i), c_package_path_regex, subexpression => 5)); l_results(l_results.last) := l_path_item; end if; end loop; @@ -359,19 +357,19 @@ create or replace package body ut_suite_cache_manager is function expand_paths(a_schema_paths ut_path_items) return ut_path_items is l_schema_paths ut_path_items:= ut_path_items(); - begin + begin with paths_to_expand as ( select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(sp.object_name,c.object_name) as object_name, - sp.procedure_name as procedure_name,sp.originated_path + sp.procedure_name as procedure_name from table(a_schema_paths) sp left outer join ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) and c.object_name like replace(upper(sp.object_name),'*','%') and c.name like nvl(replace(upper(sp.procedure_name),'*','%'), c.name)) where sp.suite_path is null and sp.object_name is not null - group by sp.schema_name,nvl(sp.object_name,c.object_name),sp.procedure_name,sp.originated_path + group by sp.schema_name,nvl(sp.object_name,c.object_name),sp.procedure_name union all - select /*+ no_parallel */ c.path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name,sp.originated_path + select /*+ no_parallel */ c.path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name from table(a_schema_paths) sp left outer join ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) @@ -379,22 +377,25 @@ create or replace package body ut_suite_cache_manager is and instr(sp.suite_path,'*') > 0) where c.path like replace(sp.suite_path,'*','%') union all - select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name,sp.originated_path + select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name from table(a_schema_paths) sp where sp.suite_path is not null and instr(sp.suite_path,'*') = 0 union all - select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name,sp.originated_path + select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name from table(a_schema_paths) sp where sp.suite_path is null and sp.object_name is null ) - select ut_path_item(schema_name,object_name,procedure_name,suite_path,originated_path) + select ut_path_item(schema_name,object_name,procedure_name,suite_path) bulk collect into l_schema_paths from - (select schema_name,object_name,procedure_name,suite_path,originated_path, + (select schema_name,object_name,procedure_name,suite_path, row_number() over ( partition by schema_name,object_name,procedure_name,suite_path order by 1) r_num from paths_to_expand) where r_num = 1 ; + + + return l_schema_paths; end; diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 2f019438c..2f21cdb67 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -17,7 +17,8 @@ create or replace package body ut_suite_manager is */ gc_suitpath_error_message constant varchar2(100) := 'Suitepath exceeds 1000 CHAR on: '; - + cursor c_cached_suites_cursor is select * from table(ut_suite_cache_rows()); + type tt_cached_suites is table of c_cached_suites_cursor%rowtype; type t_cached_suites_cursor is ref cursor return c_cached_suites_cursor%rowtype; type t_item_levels is table of ut_suite_items index by binary_integer; ------------------ @@ -252,6 +253,121 @@ create or replace package body ut_suite_manager is return l_result; end; + function get_logical_suite( + a_rows ut_suite_cache_rows, + a_idx pls_integer, + a_level pls_integer, + a_prev_level pls_integer, + a_items_at_level t_item_levels + ) return ut_suite_item is + l_result ut_suite_item; + begin + case a_rows( a_idx ).self_type + when 'UT_SUITE' then + l_result := + case when a_prev_level > a_level then + ut_suite( + self_type => a_rows( a_idx ).self_type, + object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), + name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + items => a_items_at_level(a_prev_level), + before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( + a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags + ) + else + ut_suite( + self_type => a_rows( a_idx ).self_type, + object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), + name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + items => ut_suite_items(), + before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( + a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags + ) + end; + when 'UT_SUITE_CONTEXT' then + l_result := + case when a_prev_level > a_level then + ut_suite_context( + self_type => a_rows( a_idx ).self_type, + object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), + name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + items => a_items_at_level(a_prev_level), + before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( + a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags + ) + else + ut_suite_context( + self_type => a_rows( a_idx ).self_type, + object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), + name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + items => ut_suite_items(), + before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( + a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags + ) + end; + when 'UT_LOGICAL_SUITE' then + l_result := + case when a_prev_level > a_level then + ut_logical_suite( + self_type => a_rows( a_idx ).self_type, + object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), + name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + items => a_items_at_level(a_prev_level), tags => null + ) + else + ut_logical_suite( + self_type => a_rows( a_idx ).self_type, + object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), + name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + items => ut_suite_items(), tags => null + ) + end; + when 'UT_TEST' then + l_result := + ut_test( + self_type => a_rows(a_idx).self_type, + object_owner => a_rows(a_idx).object_owner, object_name => lower(a_rows(a_idx).object_name), + name => lower(a_rows(a_idx).name), description => a_rows(a_idx).description, path => a_rows(a_idx).path, + rollback_type => a_rows(a_idx).rollback_type, disabled_flag => a_rows(a_idx).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows(a_idx).line_no, parse_time => a_rows(a_idx).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows(a_idx).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + before_each_list => sort_by_seq_no(a_rows(a_idx).before_each_list), before_test_list => sort_by_seq_no(a_rows(a_idx).before_test_list), + item => a_rows(a_idx).item, + after_test_list => sort_by_seq_no(a_rows(a_idx).after_test_list), after_each_list => sort_by_seq_no(a_rows(a_idx).after_each_list), + all_expectations => ut_expectation_results(), failed_expectations => ut_expectation_results(), + parent_error_stack_trace => null, expected_error_codes => a_rows(a_idx).expected_error_codes, + tags => a_rows(a_idx).tags + ); + end case; + l_result.results_count.warnings_count := l_result.warnings.count; + return l_result; + end; + procedure reconstruct_from_cache( a_suites in out nocopy ut_suite_items, a_suite_data_cursor sys_refcursor @@ -298,6 +414,47 @@ create or replace package body ut_suite_manager is close a_suite_data_cursor; end reconstruct_from_cache; + procedure reconstruct_from_cache( + a_suites in out nocopy ut_suite_items, + a_suite_data_cursor ut_suite_cache_rows + ) is + c_bulk_limit constant pls_integer := 1000; + l_items_at_level t_item_levels; + l_rows ut_suite_cache_rows := a_suite_data_cursor; + l_level pls_integer; + l_prev_level pls_integer; + l_idx integer; + begin + l_idx := l_rows.first; + while l_idx is not null loop + l_level := length(l_rows(l_idx).path) - length( replace(l_rows(l_idx).path, '.') ) + 1; + if l_level > 1 then + if not l_items_at_level.exists(l_level) then + l_items_at_level(l_level) := ut_suite_items(); + end if; + l_items_at_level(l_level).extend; + pragma inline(get_logical_suite, 'YES'); + l_items_at_level(l_level)(l_items_at_level(l_level).last) := get_logical_suite(l_rows, l_idx, l_level,l_prev_level, l_items_at_level ); + else + a_suites.extend; + pragma inline(get_logical_suite, 'YES'); + a_suites(a_suites.last) := get_logical_suite(l_rows, l_idx, l_level,l_prev_level, l_items_at_level ); + end if; + if l_prev_level > l_level then + l_items_at_level(l_prev_level).delete; + end if; + l_prev_level := l_level; + l_idx := l_rows.next(l_idx); + end loop; + + reverse_list_order( a_suites ); + + for i in 1 .. a_suites.count loop + a_suites( i ).set_rollback_type( a_suites( i ).get_rollback_type ); + end loop; + end reconstruct_from_cache; + + function get_cached_suite_data( a_object_owner varchar2, a_path varchar2 := null, @@ -338,14 +495,13 @@ create or replace package body ut_suite_manager is end; function get_filtered_cursor(a_unfiltered_rows in ut_suite_cache_rows) - return t_cached_suites_cursor is - l_result t_cached_suites_cursor; + return ut_suite_cache_rows is + l_result ut_suite_cache_rows := ut_suite_cache_rows(); begin if ut_metadata.user_has_execute_any_proc() then - open l_result for - select /*+ no_parallel */ c.* from table(a_unfiltered_rows) c; + l_result := a_unfiltered_rows; else - open l_result for + for i in ( select /*+ no_parallel */ c.* from table(a_unfiltered_rows) c where sys_context( 'userenv', 'current_user' ) = upper(c.object_owner) union all @@ -358,30 +514,29 @@ create or replace package body ut_suite_manager is and a.owner = c.object_owner and a.object_type = 'PACKAGE' ) - or c.self_type = 'UT_LOGICAL_SUITE'); + or c.self_type = 'UT_LOGICAL_SUITE')) + loop + l_result.extend; + l_result(l_result.last) := ut_suite_cache_row(i.id,i.self_type,i.path,i.object_owner,i.object_name,i.name,i.line_no,i.parse_time, + i.description,i.rollback_type,i.disabled_flag,i.disabled_reason,i.warnings,i.before_all_list,i.after_all_list,i.before_each_list, + i.before_test_list,i.after_each_list,i.after_test_list,i.expected_error_codes,i.tags,i.item); + end loop; end if; return l_result; end; procedure reconcile_paths_and_suites( a_schema_paths ut_path_items, - a_filtered_rows t_cached_suites_cursor + a_filtered_rows ut_suite_cache_rows ) is l_rows_tmp tt_cached_suites:= tt_cached_suites(); l_rows tt_cached_suites := tt_cached_suites(); l_limit number := 5000; - begin - loop - fetch a_filtered_rows bulk collect into l_rows_tmp limit l_limit; - l_rows := l_rows multiset union l_rows_tmp; - exit when a_filtered_rows%NOTFOUND; - end loop; - close a_filtered_rows; - - for i in ( select /*+ no_parallel */sp.schema_name,sp.object_name,sp.procedure_name, - sp.suite_path,sp.originated_path,sc.path + begin + for i in ( select /*+ no_parallel */ sp.schema_name,sp.object_name,sp.procedure_name, + sp.suite_path,sc.path from table(a_schema_paths) sp left outer join - table(l_rows) sc on + table(a_filtered_rows) sc on (( upper(sp.schema_name) = upper(sc.object_owner) and upper(sp.object_name) = upper(sc.object_name) and nvl(upper(sp.procedure_name),sc.name) = sc.name ) or (sc.path = sp.suite_path)) @@ -401,9 +556,8 @@ create or replace package body ut_suite_manager is a_schema_paths ut_path_items, a_random_seed positive, a_tags ut_varchar2_rows := null - ) return t_cached_suites_cursor is + ) return ut_suite_cache_rows is l_unfiltered_rows ut_suite_cache_rows; - l_result t_cached_suites_cursor; begin l_unfiltered_rows := ut_suite_cache_manager.get_cached_suite_rows( a_schema_paths, diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index e4160f599..acc298516 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -20,9 +20,6 @@ create or replace package ut_suite_manager authid current_user is * Resposible for building hierarhy of sutes from individual suites created by suite_builder */ - cursor c_cached_suites_cursor is select * from table(ut_suite_cache_rows()); - type tt_cached_suites is table of c_cached_suites_cursor%rowtype; - /** * @private From 273962b39c864cfcc38616f3827d434e6fc4879b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 30 Mar 2022 00:13:11 +0100 Subject: [PATCH 316/887] Fixing issue with a non visible tests. --- source/core/ut_suite_manager.pkb | 173 ++----------------------------- 1 file changed, 11 insertions(+), 162 deletions(-) diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 2f21cdb67..45eec7c14 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -253,121 +253,6 @@ create or replace package body ut_suite_manager is return l_result; end; - function get_logical_suite( - a_rows ut_suite_cache_rows, - a_idx pls_integer, - a_level pls_integer, - a_prev_level pls_integer, - a_items_at_level t_item_levels - ) return ut_suite_item is - l_result ut_suite_item; - begin - case a_rows( a_idx ).self_type - when 'UT_SUITE' then - l_result := - case when a_prev_level > a_level then - ut_suite( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => a_items_at_level(a_prev_level), - before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( - a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags - ) - else - ut_suite( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => ut_suite_items(), - before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( - a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags - ) - end; - when 'UT_SUITE_CONTEXT' then - l_result := - case when a_prev_level > a_level then - ut_suite_context( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => a_items_at_level(a_prev_level), - before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( - a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags - ) - else - ut_suite_context( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => ut_suite_items(), - before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( - a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags - ) - end; - when 'UT_LOGICAL_SUITE' then - l_result := - case when a_prev_level > a_level then - ut_logical_suite( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => a_items_at_level(a_prev_level), tags => null - ) - else - ut_logical_suite( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => ut_suite_items(), tags => null - ) - end; - when 'UT_TEST' then - l_result := - ut_test( - self_type => a_rows(a_idx).self_type, - object_owner => a_rows(a_idx).object_owner, object_name => lower(a_rows(a_idx).object_name), - name => lower(a_rows(a_idx).name), description => a_rows(a_idx).description, path => a_rows(a_idx).path, - rollback_type => a_rows(a_idx).rollback_type, disabled_flag => a_rows(a_idx).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows(a_idx).line_no, parse_time => a_rows(a_idx).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows(a_idx).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - before_each_list => sort_by_seq_no(a_rows(a_idx).before_each_list), before_test_list => sort_by_seq_no(a_rows(a_idx).before_test_list), - item => a_rows(a_idx).item, - after_test_list => sort_by_seq_no(a_rows(a_idx).after_test_list), after_each_list => sort_by_seq_no(a_rows(a_idx).after_each_list), - all_expectations => ut_expectation_results(), failed_expectations => ut_expectation_results(), - parent_error_stack_trace => null, expected_error_codes => a_rows(a_idx).expected_error_codes, - tags => a_rows(a_idx).tags - ); - end case; - l_result.results_count.warnings_count := l_result.warnings.count; - return l_result; - end; - procedure reconstruct_from_cache( a_suites in out nocopy ut_suite_items, a_suite_data_cursor sys_refcursor @@ -414,47 +299,7 @@ create or replace package body ut_suite_manager is close a_suite_data_cursor; end reconstruct_from_cache; - procedure reconstruct_from_cache( - a_suites in out nocopy ut_suite_items, - a_suite_data_cursor ut_suite_cache_rows - ) is - c_bulk_limit constant pls_integer := 1000; - l_items_at_level t_item_levels; - l_rows ut_suite_cache_rows := a_suite_data_cursor; - l_level pls_integer; - l_prev_level pls_integer; - l_idx integer; - begin - l_idx := l_rows.first; - while l_idx is not null loop - l_level := length(l_rows(l_idx).path) - length( replace(l_rows(l_idx).path, '.') ) + 1; - if l_level > 1 then - if not l_items_at_level.exists(l_level) then - l_items_at_level(l_level) := ut_suite_items(); - end if; - l_items_at_level(l_level).extend; - pragma inline(get_logical_suite, 'YES'); - l_items_at_level(l_level)(l_items_at_level(l_level).last) := get_logical_suite(l_rows, l_idx, l_level,l_prev_level, l_items_at_level ); - else - a_suites.extend; - pragma inline(get_logical_suite, 'YES'); - a_suites(a_suites.last) := get_logical_suite(l_rows, l_idx, l_level,l_prev_level, l_items_at_level ); - end if; - if l_prev_level > l_level then - l_items_at_level(l_prev_level).delete; - end if; - l_prev_level := l_level; - l_idx := l_rows.next(l_idx); - end loop; - - reverse_list_order( a_suites ); - - for i in 1 .. a_suites.count loop - a_suites( i ).set_rollback_type( a_suites( i ).get_rollback_type ); - end loop; - end reconstruct_from_cache; - - + function get_cached_suite_data( a_object_owner varchar2, a_path varchar2 := null, @@ -529,9 +374,6 @@ create or replace package body ut_suite_manager is a_schema_paths ut_path_items, a_filtered_rows ut_suite_cache_rows ) is - l_rows_tmp tt_cached_suites:= tt_cached_suites(); - l_rows tt_cached_suites := tt_cached_suites(); - l_limit number := 5000; begin for i in ( select /*+ no_parallel */ sp.schema_name,sp.object_name,sp.procedure_name, sp.suite_path,sc.path @@ -556,16 +398,23 @@ create or replace package body ut_suite_manager is a_schema_paths ut_path_items, a_random_seed positive, a_tags ut_varchar2_rows := null - ) return ut_suite_cache_rows is + ) return t_cached_suites_cursor is l_unfiltered_rows ut_suite_cache_rows; + l_filtered_rows ut_suite_cache_rows; + l_result t_cached_suites_cursor; begin l_unfiltered_rows := ut_suite_cache_manager.get_cached_suite_rows( a_schema_paths, a_random_seed, a_tags ); - reconcile_paths_and_suites(a_schema_paths,get_filtered_cursor(l_unfiltered_rows)); - return get_filtered_cursor(l_unfiltered_rows); + + l_filtered_rows := get_filtered_cursor(l_unfiltered_rows); + reconcile_paths_and_suites(a_schema_paths,l_filtered_rows); + + open l_result for + select * from table(l_filtered_rows); + return l_result; end; function can_skip_all_objects_scan( From a753e66aa3f8062d0aa6aa3fc2d7386e61fc6176 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 30 Mar 2022 09:54:03 +0100 Subject: [PATCH 317/887] Fixing ORA-600 --- source/core/ut_suite_cache_manager.pkb | 123 ++++++++++++++++--------- 1 file changed, 80 insertions(+), 43 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index a83be01a0..154af6f0c 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -88,34 +88,12 @@ create or replace package body ut_suite_cache_manager is q'[with suite_items as ( select /*+ cardinality(c 500) */ value(c) as obj - from ut_suite_cache c, - table(:l_schema_paths) sp - where c.object_owner = upper(sp.schema_name) - and sp.suite_path is not null - and ( - sp.suite_path||'.' like c.path||'.%' /*all parents and self*/ - or - ( - c.path||'.' like sp.suite_path||'.%' /*all children and self*/ - and c.object_name like nvl(upper(sp.object_name),c.object_name) - and c.name like nvl(upper(sp.procedure_name),c.name) - ) - ) - union all - select /*+ cardinality(c 500) */ value(c) as obj - from ut_suite_cache c, - table(:l_schema_paths) sp - where c.object_owner = upper(sp.schema_name) - and sp.suite_path is null - and c.object_name like nvl(upper(replace(sp.object_name,'*','%')),c.object_name) - and c.name like nvl(upper(replace(sp.procedure_name,'*','%')),c.name) - ), - {:tags:} + from table(:suite_items) c), suitepaths as ( select distinct substr(c.obj.path,1,instr(c.obj.path,'.',-1)-1) as suitepath, c.obj.path as path, c.obj.object_owner as object_owner - from {:suite_item_name:} c + from suite_items c where c.obj.self_type = 'UT_SUITE' ), gen as ( @@ -152,7 +130,7 @@ create or replace package body ut_suite_cache_manager is from logical_suite_data s ), items as ( - select obj from {:suite_item_name:} + select obj from suite_items union all select obj from logical_suites ) @@ -404,44 +382,103 @@ create or replace package body ut_suite_cache_manager is return expand_paths(group_paths_by_schema(a_paths)); end; + function get_suite_items ( + a_schema_paths ut_path_items + ) return ut_suite_cache_rows is + l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); + begin + select /*+ cardinality(c 500) */ value(c) as obj + bulk collect into l_suite_items + from ut_suite_cache c, + table(a_schema_paths) sp + where c.object_owner = upper(sp.schema_name) + and ( + (sp.suite_path is not null and + sp.suite_path||'.' like c.path||'.%' /*all parents and self*/ + or + ( c.path||'.' like sp.suite_path||'.%' /*all children and self*/ + and c.object_name like nvl(upper(sp.object_name),c.object_name) + and c.name like nvl(upper(sp.procedure_name),c.name) ) ) + or + ( sp.suite_path is null + and c.object_name like nvl(upper(replace(sp.object_name,'*','%')),c.object_name) + and c.name like nvl(upper(replace(sp.procedure_name,'*','%')),c.name) + )); + return l_suite_items; + end; + + function get_tags_suites ( + a_suite_items ut_suite_cache_rows, + a_tags ut_varchar2_rows + ) return ut_suite_cache_rows is + l_suite_tags ut_suite_cache_rows := ut_suite_cache_rows(); + l_include_tags ut_varchar2_rows; + l_exclude_tags ut_varchar2_rows; + begin + + select /*+ no_parallel */ column_value + bulk collect into l_include_tags + from table(a_tags) + where column_value not like '-%'; + + select /*+ no_parallel */ ltrim(column_value,'-') + bulk collect into l_exclude_tags + from table(a_tags) + where column_value like '-%'; + + with included_tags as ( + select c.path as path + from table(a_suite_items) c + where c.tags multiset intersect l_include_tags is not empty or l_include_tags is empty + ), + excluded_tags as ( + select c.path as path + from table(a_suite_items) c + where c.tags multiset intersect l_exclude_tags is not empty + ) + select value(c) as obj + bulk collect into l_suite_tags + from table(a_suite_items) c + where exists ( + select 1 from included_tags t + where t.path||'.' like c.path || '.%' /*all parents and self*/ + or c.path||'.' like t.path || '.%' /*all children and self*/ + ) + and not exists ( + select 1 from excluded_tags t + where c.path||'.' like t.path || '.%' /*all children and self*/ + ); + return l_suite_tags; + end; + function get_cached_suite_rows( a_schema_paths ut_path_items, a_random_seed positive := null, a_tags ut_varchar2_rows := null ) return ut_suite_cache_rows is l_results ut_suite_cache_rows := ut_suite_cache_rows(); + l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); l_schema_paths ut_path_items; l_tags ut_varchar2_rows := coalesce(a_tags,ut_varchar2_rows()); - l_include_tags ut_varchar2_rows; - l_exclude_tags ut_varchar2_rows; + l_suite_item_name varchar2(20); l_paths ut_varchar2_rows; l_schema varchar2(4000); l_sql varchar2(32767); begin - select /*+ no_parallel */ column_value - bulk collect into l_include_tags - from table(l_tags) - where column_value not like '-%'; - - select /*+ no_parallel */ ltrim(column_value,'-') - bulk collect into l_exclude_tags - from table(l_tags) - where column_value like '-%'; l_schema_paths := a_schema_paths; - --We still need to turn this into qualified SQL name....maybe as part of results ? - l_suite_item_name := case when l_tags.count > 0 then 'suite_items_tags' else 'suite_items' end; - l_sql := gc_get_bulk_cache_suite_sql; - l_sql := replace(l_sql,'{:suite_item_name:}',l_suite_item_name); - l_sql := replace(l_sql,'{:tags:}',get_tags_sql(l_tags.count)); l_sql := replace(l_sql,'{:random_seed:}',get_random_seed_sql(a_random_seed)); + l_suite_items := get_suite_items(a_schema_paths); + if l_tags.count > 0 then + l_suite_items := get_tags_suites(l_suite_items,l_tags); + end if; ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_key_anyvalues().put('l_sql',l_sql) ); - + execute immediate l_sql bulk collect into l_results - using l_schema_paths, l_schema_paths, l_include_tags, l_include_tags, l_exclude_tags, a_random_seed; + using l_suite_items, a_random_seed; return l_results; end; From 0d8d34dae7636626f30da9c285127ad4d3ecc31b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 30 Mar 2022 13:34:12 +0100 Subject: [PATCH 318/887] Cleanup Phase1. --- source/core/ut_suite_cache_manager.pkb | 220 ++++--------------------- source/core/ut_suite_manager.pkb | 95 ++--------- 2 files changed, 41 insertions(+), 274 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 154af6f0c..b0b3f7d71 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -20,70 +20,6 @@ create or replace package body ut_suite_cache_manager is * Private code */ - gc_get_cache_suite_sql constant varchar2(32767) := - q'[with - suite_items as ( - select /*+ cardinality(c 500) */ value(c) as obj - from ut_suite_cache c - where 1 = 1 - and c.object_owner = :l_object_owner - and ( {:path:} - and {:object_name:} - and {:procedure_name:} - ) - ) - ), - {:tags:} - suitepaths as ( - select distinct substr(c.obj.path,1,instr(c.obj.path,'.',-1)-1) as suitepath, - c.obj.path as path, - c.obj.object_owner as object_owner - from {:suite_item_name:} c - where c.obj.self_type = 'UT_SUITE' - ), - gen as ( - select rownum as pos - from xmltable('1 to 20') - ), - suitepath_part AS ( - select distinct - substr(b.suitepath, 1, instr(b.suitepath || '.', '.', 1, g.pos) -1) as path, - object_owner - from suitepaths b - join gen g - on g.pos <= regexp_count(b.suitepath, '\w+') - ), - logical_suite_data as ( - select 'UT_LOGICAL_SUITE' as self_type, p.path, p.object_owner, - upper( substr(p.path, instr( p.path, '.', -1 ) + 1 ) ) as object_name, - cast(null as ut_executables) as x, - cast(null as ut_varchar2_rows) as y, - cast(null as ut_executable_test) as z - from suitepath_part p - where p.path - not in (select s.path from suitepaths s) - ), - logical_suites as ( - select ut_suite_cache_row( - null, - s.self_type, s.path, s.object_owner, s.object_name, - s.object_name, null, null, null, null, 0,null, - ut_varchar2_rows(), - s.x, s.x, s.x, s.x, s.x, s.x, - s.y, null, s.z - ) as obj - from logical_suite_data s - ), - items as ( - select obj from {:suite_item_name:} - union all - select obj from logical_suites - ) - select /*+ no_parallel */ c.obj - from items c - order by c.obj.object_owner,{:random_seed:}]'; - - gc_get_bulk_cache_suite_sql constant varchar2(32767) := q'[with suite_items as ( @@ -157,61 +93,6 @@ create or replace package body ut_suite_cache_manager is return l_result; end; - - function get_path_sql(a_path in varchar2) return varchar2 is - begin - return case when a_path is not null then q'[ - :l_path||'.' like c.path || '.%' /*all parents and self*/ - or ( c.path||'.' like :l_path || '.%' /*all children and self*/ - ]' - else ' :l_path is null and ( :l_path is null ' end; - end; - - function get_object_name_sql(a_object_name in varchar2) return varchar2 is - begin - return case when a_object_name is not null - then ' c.object_name = :a_object_name ' - else ' :a_object_name is null' end; - end; - - function get_procedure_name_sql(a_procedure_name in varchar2) return varchar2 is - begin - return case when a_procedure_name is not null - then ' c.name = :a_procedure_name' - else ' :a_procedure_name is null' end; - end; - - function get_tags_sql(a_tags_count in integer) return varchar2 is - begin - return case when a_tags_count > 0 then - q'[included_tags as ( - select c.obj.path as path - from suite_items c - where c.obj.tags multiset intersect :a_include_tag_list is not empty or :a_include_tag_list is empty - ), - excluded_tags as ( - select c.obj.path as path - from suite_items c - where c.obj.tags multiset intersect :a_exclude_tag_list is not empty - ), - suite_items_tags as ( - select c.* - from suite_items c - where exists ( - select 1 from included_tags t - where t.path||'.' like c.obj.path || '.%' /*all parents and self*/ - or c.obj.path||'.' like t.path || '.%' /*all children and self*/ - ) - and not exists ( - select 1 from excluded_tags t - where c.obj.path||'.' like t.path || '.%' /*all children and self*/ - ) - ),]' - else - q'[dummy as (select 'x' from dual where :a_include_tag_list is null and :a_include_tag_list is null and :a_exclude_tag_list is null),]' - end; - end; - function get_random_seed_sql(a_random_seed positive) return varchar2 is begin return case @@ -269,70 +150,6 @@ create or replace package body ut_suite_cache_manager is return l_results; end; - - - /* - * Public code - */ - function get_cached_suite_rows( - a_object_owner varchar2, - a_path varchar2 := null, - a_object_name varchar2 := null, - a_procedure_name varchar2 := null, - a_random_seed positive := null, - a_tags ut_varchar2_rows := null - ) return ut_suite_cache_rows is - l_path varchar2(4000); - l_results ut_suite_cache_rows := ut_suite_cache_rows(); - l_sql varchar2(32767); - l_suite_item_name varchar2(20); - l_tags ut_varchar2_rows := coalesce(a_tags,ut_varchar2_rows()); - l_include_tags ut_varchar2_rows; - l_exclude_tags ut_varchar2_rows; - l_object_owner varchar2(250) := ut_utils.qualified_sql_name(a_object_owner); - l_object_name varchar2(250) := ut_utils.qualified_sql_name(a_object_name); - l_procedure_name varchar2(250) := ut_utils.qualified_sql_name(a_procedure_name); - begin - - select /*+ no_parallel */ column_value - bulk collect into l_include_tags - from table(l_tags) - where column_value not like '-%'; - - select /*+ no_parallel */ ltrim(column_value,'-') - bulk collect into l_exclude_tags - from table(l_tags) - where column_value like '-%'; - - if a_path is null and a_object_name is not null then - select /*+ no_parallel */ min(c.path) - into l_path - from ut_suite_cache c - where c.object_owner = upper(l_object_owner) - and c.object_name = upper(l_object_name) - and c.name = nvl(upper(l_procedure_name), c.name); - else - l_path := lower(ut_utils.qualified_sql_name(a_path)); - end if; - l_suite_item_name := case when l_tags.count > 0 then 'suite_items_tags' else 'suite_items' end; - - l_sql := gc_get_cache_suite_sql; - l_sql := replace(l_sql,'{:suite_item_name:}',l_suite_item_name); - l_sql := replace(l_sql,'{:object_owner:}',upper(l_object_owner)); - l_sql := replace(l_sql,'{:path:}',get_path_sql(l_path)); - l_sql := replace(l_sql,'{:object_name:}',get_object_name_sql(l_object_name)); - l_sql := replace(l_sql,'{:procedure_name:}',get_procedure_name_sql(l_procedure_name)); - l_sql := replace(l_sql,'{:tags:}',get_tags_sql(l_tags.count)); - l_sql := replace(l_sql,'{:random_seed:}',get_random_seed_sql(a_random_seed)); - - ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_key_anyvalues().put('l_sql',l_sql) ); - - execute immediate l_sql - bulk collect into l_results - using upper(l_object_owner), l_path, l_path, upper(a_object_name), upper(a_procedure_name), l_include_tags, l_include_tags, l_exclude_tags, a_random_seed; - return l_results; - end; - function expand_paths(a_schema_paths ut_path_items) return ut_path_items is l_schema_paths ut_path_items:= ut_path_items(); begin @@ -371,17 +188,9 @@ create or replace package body ut_suite_cache_manager is row_number() over ( partition by schema_name,object_name,procedure_name,suite_path order by 1) r_num from paths_to_expand) where r_num = 1 ; - - - return l_schema_paths; end; - - function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items is - begin - return expand_paths(group_paths_by_schema(a_paths)); - end; - + function get_suite_items ( a_schema_paths ut_path_items ) return ut_suite_cache_rows is @@ -451,6 +260,33 @@ create or replace package body ut_suite_cache_manager is return l_suite_tags; end; + /* + * Public code + */ + + function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items is + begin + return expand_paths(group_paths_by_schema(a_paths)); + end; + + function get_cached_suite_rows( + a_object_owner varchar2, + a_path varchar2 := null, + a_object_name varchar2 := null, + a_procedure_name varchar2 := null, + a_random_seed positive := null, + a_tags ut_varchar2_rows := null + ) return ut_suite_cache_rows is + l_tags ut_varchar2_rows := coalesce(a_tags,ut_varchar2_rows()); + l_object_owner varchar2(250) := ut_utils.qualified_sql_name(a_object_owner); + l_object_name varchar2(250) := ut_utils.qualified_sql_name(a_object_name); + l_procedure_name varchar2(250) := ut_utils.qualified_sql_name(a_procedure_name); + l_schema_paths ut_path_items; + begin + l_schema_paths := ut_path_items(ut_path_item(a_object_owner,a_object_name,a_procedure_name,a_path)); + return get_cached_suite_rows(l_schema_paths,a_random_seed,l_tags); + end; + function get_cached_suite_rows( a_schema_paths ut_path_items, a_random_seed positive := null, diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 45eec7c14..16beb0e36 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -299,51 +299,14 @@ create or replace package body ut_suite_manager is close a_suite_data_cursor; end reconstruct_from_cache; - - function get_cached_suite_data( - a_object_owner varchar2, - a_path varchar2 := null, - a_object_name varchar2 := null, - a_procedure_name varchar2 := null, - a_skip_all_objects boolean := false, - a_random_seed positive, - a_tags ut_varchar2_rows := null - ) return t_cached_suites_cursor is - l_unfiltered_rows ut_suite_cache_rows; - l_result t_cached_suites_cursor; - begin - l_unfiltered_rows := ut_suite_cache_manager.get_cached_suite_rows( - a_object_owner, - a_path, - a_object_name, - a_procedure_name, - a_random_seed, - a_tags - ); - if a_skip_all_objects then - open l_result for - select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c; - else - open l_result for - select /*+ no_parallel */ c.* from table(l_unfiltered_rows) c - where exists - ( select 1 - from all_objects a - where a.object_name = c.object_name - and a.owner = c.object_owner - and a.object_type = 'PACKAGE' - ) - or c.self_type = 'UT_LOGICAL_SUITE'; - end if; - - return l_result; - end; - - function get_filtered_cursor(a_unfiltered_rows in ut_suite_cache_rows) + function get_filtered_cursor( + a_unfiltered_rows in ut_suite_cache_rows, + a_skip_all_objects boolean := false + ) return ut_suite_cache_rows is l_result ut_suite_cache_rows := ut_suite_cache_rows(); begin - if ut_metadata.user_has_execute_any_proc() then + if ut_metadata.user_has_execute_any_proc() or a_skip_all_objects then l_result := a_unfiltered_rows; else for i in ( @@ -397,7 +360,8 @@ create or replace package body ut_suite_manager is function get_cached_suite_data( a_schema_paths ut_path_items, a_random_seed positive, - a_tags ut_varchar2_rows := null + a_tags ut_varchar2_rows := null, + a_skip_all_objects boolean := false ) return t_cached_suites_cursor is l_unfiltered_rows ut_suite_cache_rows; l_filtered_rows ut_suite_cache_rows; @@ -409,7 +373,7 @@ create or replace package body ut_suite_manager is a_tags ); - l_filtered_rows := get_filtered_cursor(l_unfiltered_rows); + l_filtered_rows := get_filtered_cursor(l_unfiltered_rows,a_skip_all_objects); reconcile_paths_and_suites(a_schema_paths,l_filtered_rows); open l_result for @@ -519,19 +483,17 @@ create or replace package body ut_suite_manager is a_skip_all_objects boolean := false ) return ut_suite_items is l_suites ut_suite_items := ut_suite_items(); + l_schema_paths ut_path_items; begin build_and_cache_suites(a_owner_name, a_annotated_objects); - + l_schema_paths := ut_path_items(ut_path_item(a_owner_name,a_object_name,a_procedure_name,a_path)); reconstruct_from_cache( l_suites, get_cached_suite_data( - a_owner_name, - a_path, - a_object_name, - a_procedure_name, - a_skip_all_objects, + l_schema_paths, null, - null + null, + a_skip_all_objects ) ); return l_suites; @@ -596,37 +558,6 @@ create or replace package body ut_suite_manager is a_tags ); - /* - l_schema := l_schema_paths.first; - while l_schema is not null loop - l_path_items := l_schema_paths(l_schema); - for i in 1 .. l_path_items.count loop - l_path_item := l_path_items(i); - add_suites_for_path( - upper(l_schema), - l_path_item.suite_path, - l_path_item.object_name, - l_path_item.procedure_name, - a_suites, - a_random_seed, - a_tags - ); - if a_suites.count = l_suites_count then - if l_path_item.suite_path is not null then - raise_application_error(ut_utils.gc_suite_package_not_found,'No suite packages found for path '||l_schema||':'||l_path_item.suite_path|| '.'); - elsif l_path_item.procedure_name is not null then - raise_application_error(ut_utils.gc_suite_package_not_found,'Suite test '||l_schema||'.'||l_path_item.object_name|| '.'||l_path_item.procedure_name||' does not exist'); - elsif l_path_item.object_name is not null then - raise_application_error(ut_utils.gc_suite_package_not_found,'Suite package '||l_schema||'.'||l_path_item.object_name|| ' does not exist'); - end if; - end if; - l_index := a_suites.first; - l_suites_count := a_suites.count; - end loop; - l_schema := l_schema_paths.next(l_schema); - end loop;*/ - - --propagate rollback type to suite items after organizing suites into hierarchy for i in 1 .. a_suites.count loop a_suites(i).set_rollback_type( a_suites(i).get_rollback_type() ); From 95ddec1e535aa720a4383affecdb7ac158cba91e Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 31 Mar 2022 11:53:03 +0100 Subject: [PATCH 319/887] Adding tests. modifying code to cater for path with wildcard that can result in large item duplication due to parent/child search. --- source/core/ut_suite_cache_manager.pkb | 65 +++++--- source/core/ut_suite_manager.pks | 1 - test/ut3_tester/core/test_suite_manager.pkb | 162 ++++++++++++++++++++ test/ut3_tester/core/test_suite_manager.pks | 22 ++- 4 files changed, 225 insertions(+), 25 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index b0b3f7d71..fe0aaabae 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -127,7 +127,6 @@ create or replace package body ut_suite_cache_manager is end; end; - --Possible move logic to type function group_paths_by_schema(a_paths ut_varchar2_list) return ut_path_items is c_package_path_regex constant varchar2(100) := '^([A-Za-z0-9$#_]+)(\.([A-Za-z0-9$#_\*]+))?(\.([A-Za-z0-9$#_\*]+))?$'; l_results ut_path_items := ut_path_items(); @@ -152,34 +151,41 @@ create or replace package body ut_suite_cache_manager is function expand_paths(a_schema_paths ut_path_items) return ut_path_items is l_schema_paths ut_path_items:= ut_path_items(); - begin + begin with paths_to_expand as ( - select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(sp.object_name,c.object_name) as object_name, - sp.procedure_name as procedure_name + /* + The object name is populate but suitepath not + We will use that object and try to match. + We can pass also a wildcard this will result in one to many. + */ + select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, + nvl2(sp.procedure_name,c.name,null) as procedure_name from table(a_schema_paths) sp left outer join ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) and c.object_name like replace(upper(sp.object_name),'*','%') and c.name like nvl(replace(upper(sp.procedure_name),'*','%'), c.name)) - where sp.suite_path is null - and sp.object_name is not null - group by sp.schema_name,nvl(sp.object_name,c.object_name),sp.procedure_name + where sp.suite_path is null and sp.object_name is not null + group by sp.schema_name,nvl(c.object_name,sp.object_name),nvl2(sp.procedure_name,c.name,null) union all - select /*+ no_parallel */ c.path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name + select /*+ no_parallel */ nvl(c.path,sp.suite_path) as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name from table(a_schema_paths) sp left outer join ut_suite_cache c on - ( c.object_owner = upper(sp.schema_name) - and sp.suite_path is not null - and instr(sp.suite_path,'*') > 0) - where c.path like replace(sp.suite_path,'*','%') + ( c.object_owner = upper(sp.schema_name) + and c.path like replace(sp.suite_path,'*','%')) + where sp.suite_path is not null and instr(sp.suite_path,'*') > 0 union all + /* + Get all data that do not have an wildcard and not require expanding. + We will take them as they are. + a)suite path is populated + b)suite path and object is empty so schema name is by default ( or passed) + */ select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name from table(a_schema_paths) sp - where sp.suite_path is not null - and instr(sp.suite_path,'*') = 0 - union all - select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name - from table(a_schema_paths) sp - where sp.suite_path is null and sp.object_name is null + where + (sp.suite_path is not null and instr(sp.suite_path,'*') = 0) + or + (sp.suite_path is null and sp.object_name is null) ) select ut_path_item(schema_name,object_name,procedure_name,suite_path) bulk collect into l_schema_paths @@ -190,14 +196,25 @@ create or replace package body ut_suite_cache_manager is where r_num = 1 ; return l_schema_paths; end; - + + /* + Get a suite items rows that matching our criteria like + path,object_name etc. + We need to consider also an wildcard character on our procedures and object + names. + Were the path is populated we need to make sure we dont return duplicates + as the wildcard can produce multiple results from same path and + parents and child for each can be same resulting in duplicates + TODO: Verify that this not duplicate with a expand paths. + */ function get_suite_items ( a_schema_paths ut_path_items ) return ut_suite_cache_rows is l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); begin - select /*+ cardinality(c 500) */ value(c) as obj - bulk collect into l_suite_items + select obj bulk collect into l_suite_items + from ( + select /*+ cardinality(c 500) */ value(c) as obj,row_number() over ( partition by path order by path asc) r_num from ut_suite_cache c, table(a_schema_paths) sp where c.object_owner = upper(sp.schema_name) @@ -212,10 +229,14 @@ create or replace package body ut_suite_cache_manager is ( sp.suite_path is null and c.object_name like nvl(upper(replace(sp.object_name,'*','%')),c.object_name) and c.name like nvl(upper(replace(sp.procedure_name,'*','%')),c.name) - )); + ))) where r_num = 1; return l_suite_items; end; + /* + Having a base set of suites we will do a further filter down if there are + any tags defined. + */ function get_tags_suites ( a_suite_items ut_suite_cache_rows, a_tags ut_varchar2_rows diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index acc298516..5ae98d72a 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -20,7 +20,6 @@ create or replace package ut_suite_manager authid current_user is * Resposible for building hierarhy of sutes from individual suites created by suite_builder */ - /** * @private * diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index c8b4a9453..48ecf91f0 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -945,6 +945,26 @@ end;]'; ut.expect(sqlerrm).to_be_like('%failing_non_existing%'); end; + procedure test_search_nonex_pck_wild is + l_objects_to_run ut3_develop.ut_suite_items; + begin + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('ut3_develop.failing_non_*')); + ut.fail('Non existing package did not raise exception'); + exception + when others then + ut.expect(sqlerrm).to_be_like('%failing_non_*%'); + end; + + procedure test_search_nonex_path_wild is + l_objects_to_run ut3_develop.ut_suite_items; + begin + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('ut3_develop:failing_non_*')); + ut.fail('Non existing path did not raise exception'); + exception + when others then + ut.expect(sqlerrm).to_be_like('%:failing_non_*%'); + end; + procedure test_search_nonexist_sch_pck is l_objects_to_run ut3_develop.ut_suite_items; begin @@ -1560,5 +1580,147 @@ end;]'; end; + procedure test_wild_card_obj_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_*'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; + l_ctx_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(3); + + + for i in 1 .. 3 loop + l_test_suite := treat(l_objects_to_run(i) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name in ('test_package_with_ctx','tests', 'tests2')).to_be_true; + + case l_test_suite.name + when 'test_package_with_ctx' then + ut.expect(l_test_suite.items.count).to_equal(1); + l_ctx_suite:= treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); + ut.expect(l_ctx_suite.name).to_equal('some_context'); + ut.expect(l_ctx_suite.description).to_equal('Some context description'); + ut.expect(l_ctx_suite.items.count).to_equal(1); + l_test_proc := treat(l_ctx_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test_proc.name).to_equal('test1'); + when 'tests' then + l_test1_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test1_suite.name).to_equal('test_package_1'); + ut.expect(l_test1_suite.items.count).to_equal(3); + ut.expect(l_test1_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); + l_test2_suite := treat(l_test1_suite.items(1) as ut3_develop.ut_logical_suite); + + ut.expect(l_test2_suite.name).to_equal('test_package_2'); + ut.expect(l_test2_suite.items.count).to_equal(3); + ut.expect(l_test2_suite.rollback_type).to_equal(ut3_develop.ut_utils.gc_rollback_manual); + when 'tests2' then + l_test1_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test1_suite.name).to_equal('test_package_3'); + ut.expect(l_test1_suite.items.count).to_equal(3); + end case; + + end loop; + + end; + + procedure test_wild_card_prc_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_1.test*'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('tests'); + + l_test1_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test1_suite.name).to_equal('test_package_1'); + ut.expect(l_test1_suite.items.count).to_equal(2); + + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('test1'); + + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('test2'); + end; + + procedure test_wild_card_path_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':tests*'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; + l_test3_suite ut3_develop.ut_logical_suite; + l_ctx_suite ut3_develop.ut_logical_suite; + l_test_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(2); + + + for i in 1 .. 2 loop + l_test_suite := treat(l_objects_to_run(i) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name in ('tests', 'tests2')).to_be_true; + + case l_test_suite.name + when 'tests' then + l_test1_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test1_suite.name).to_equal('test_package_1'); + ut.expect(l_test1_suite.items.count).to_equal(3); + + for i in 1 ..3 loop + --l_test2_suite := treat(l_test1_suite.items(i) as ut3_develop.ut_logical_suite); + --ut.expect(l_test2_suite.name).to_equal('test_package_2'); + --ut.expect(l_test2_suite.items.count).to_equal(3); + case l_test1_suite.items(i).self_type + when 'UT_SUITE' then + l_test2_suite := treat(l_test1_suite.items(i) as ut3_develop.ut_logical_suite); + ut.expect(l_test2_suite.name).to_equal('test_package_2'); + ut.expect(l_test2_suite.items.count).to_equal(3); + + l_test_proc := treat(l_test2_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test_proc.name in ('test1', 'test2','context_test')).to_be_true; + + l_test_proc := treat(l_test2_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test_proc.name in ('test1', 'test2','context_test')).to_be_true; + + l_test_proc := treat(l_test2_suite.items(3) as ut3_develop.ut_test); + ut.expect(l_test_proc.name in ('test1', 'test2','context_test')).to_be_true; + + when 'UT_TEST' then + l_test_proc := treat(l_test1_suite.items(i) as ut3_develop.ut_test); + ut.expect(l_test_proc.name in ('test1', 'test2')).to_be_true; + end case; + end loop; + when 'tests2' then + ut.expect(l_test_suite.items.count).to_equal(1); + l_test1_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test1_suite.name).to_equal('test_package_3'); + ut.expect(l_test1_suite.items.count).to_equal(3); + for i in 1 .. 3 loop + l_test_proc := treat(l_test1_suite.items(i) as ut3_develop.ut_test); + ut.expect(l_test_proc.name in ('test1', 'test2','disabled_test')).to_be_true; + end loop; + end case; + + end loop; + + end; + end test_suite_manager; / diff --git a/test/ut3_tester/core/test_suite_manager.pks b/test/ut3_tester/core/test_suite_manager.pks index 154df9ca6..bea8faf96 100644 --- a/test/ut3_tester/core/test_suite_manager.pks +++ b/test/ut3_tester/core/test_suite_manager.pks @@ -75,8 +75,14 @@ create or replace package test_suite_manager is --%test(Prepare runner for nonexisting package with schema) procedure test_search_nonexisting_pck; - - --%test(Prepare runner for nonexisting package without schema) + + --%test(Prepare runner for nonexisting package using wildcard filter) + procedure test_search_nonex_pck_wild; + + --%test(Prepare runner for nonexisting path using wildcard filter) + procedure test_search_nonex_path_wild; + + --%test(Prepare runner for nonexisting package without schema) procedure test_search_nonexist_sch_pck; --%test(Test description with comma) @@ -185,6 +191,18 @@ create or replace package test_suite_manager is --%aftertest(clean_remove_annot_test) procedure test_rem_cache_on_crt_anno; + --%context(wildcard_filters) + + --%test(Execute test_packages using a object_name with wildcard ) + procedure test_wild_card_obj_name; + + --%test(Execute test_packages using a procedure name with wildcard ) + procedure test_wild_card_prc_name; + + --%test(Execute test_packages using a path name with wildcard ) + procedure test_wild_card_path_name; + + --%endcontext end test_suite_manager; / From 83dbdaa4ba7ef57dcc8d86771cdb66d6eec19e7c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 31 Mar 2022 15:40:28 +0100 Subject: [PATCH 320/887] Updating documentation. Adding get_suites_info override. --- docs/userguide/querying_suites.md | 10 +++++ docs/userguide/running-unit-tests.md | 28 +++++++++++++ source/api/ut_runner.pkb | 23 ++++++++++- source/api/ut_runner.pks | 9 ++++- source/core/ut_suite_cache_manager.pkb | 42 ++++++++++---------- source/core/ut_suite_cache_manager.pks | 9 +++-- source/core/ut_suite_manager.pkb | 55 ++++++++++++-------------- source/core/ut_suite_manager.pks | 10 ++--- 8 files changed, 122 insertions(+), 64 deletions(-) diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 2d947f391..b47b62083 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -39,6 +39,16 @@ To get a full information about suite `TEST_STUFF` including suite description, select * from table(ut_runner.get_suites_info(USER, 'TEST_STUFF')) where item_type = 'UT_TEST'; ``` +To get a full information about suites that have a path like `ut3:tests.test_package_*` including suite description, all contexts and tests in a suite +```sql +select * from table(ut_runner.get_suites_info('ut3:tests.test_package_*') where item_type = 'UT_TEST'; +``` + +To get a full information about suites that have object name like `test_package_*` including suite description, all contexts and tests in a suite +```sql +select * from table(ut_runner.get_suites_info('test_package_*')); +``` + ## Checking if schema contains tests Function `ut_runner.has_suites(a_owner)` returns boolean value indicating if given schema contains test suites. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index f392dd1e5..2a8f8e151 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -45,6 +45,10 @@ The **functions** can only be used in SELECT statements. They execute the specif ## ut.run procedures The examples below illustrate different ways and options to invoke `ut.run` procedures. +As part of the syntax you can use a wildcard character `*` to call test by part of his name or to call few tests that match a call. +Schema name is still mandatory and cannot contain a wildcard character whether is a suitepath or object. + + ```sql alter session set current_schema=hr; @@ -75,6 +79,14 @@ end; Executes all tests from all packages that are on the _com.my_org.my_project_ suitepath. Check the [annotations documentation](annotations.md) to find out about suitepaths and how they can be used to organize test packages for your project. +```sql +set serveroutput on +begin + ut.run('hr:com*'); +end; +``` + +Executes all tests from all packages that are on suitepath starting with _com_. ```sql set serveroutput on @@ -124,6 +136,22 @@ Using a list of items to execute allows you to execute a fine-grained set of tes List can be passed as a comma separated list or a list of *ut_varchar2_list objects* or as a list within ut_varchar2_list. +```sql +set serveroutput on +begin + ut.run('hr.test*'); +end; +``` +Executes all tests from schema _hr_ starting with name _test_. + +```sql +set serveroutput on +begin + ut.run('hr.test_apply_bonus.bonus_*'); +end; +``` +Executes all test procedures from package _hr.test_apply_bonus_ that starting with _bonus_. + **Note:** diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index cbf1971e7..c49f895a3 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -172,12 +172,31 @@ create or replace package body ut_runner is ut_annotation_manager.purge_cache(a_object_owner, a_object_type); end; - function get_suites_info(a_owner varchar2 := null, a_package_name varchar2 := null) return ut_suite_items_info pipelined is + function get_suites_info(a_owner varchar2, a_package_name varchar2) return ut_suite_items_info pipelined is l_cursor sys_refcursor; l_results ut_suite_items_info; c_bulk_limit constant integer := 100; + l_path varchar2(4000) := nvl(a_owner,sys_context('userenv', 'current_schema'))||'.'||nvl(a_package_name,'*'); begin - l_cursor := ut_suite_manager.get_suites_info( nvl(a_owner,sys_context('userenv', 'current_schema')), a_package_name ); + + l_cursor := ut_suite_manager.get_suites_info(ut_varchar2_list(l_path)); + loop + fetch l_cursor bulk collect into l_results limit c_bulk_limit; + for i in 1 .. l_results.count loop + pipe row (l_results(i)); + end loop; + exit when l_cursor%notfound; + end loop; + close l_cursor; + return; + end; + + function get_suites_info(a_path varchar2 := null) return ut_suite_items_info pipelined is + l_cursor sys_refcursor; + l_results ut_suite_items_info; + c_bulk_limit constant integer := 100; + begin + l_cursor := ut_suite_manager.get_suites_info(ut_varchar2_list(nvl(a_path,sys_context('userenv', 'current_schema')))); loop fetch l_cursor bulk collect into l_results limit c_bulk_limit; for i in 1 .. l_results.count loop diff --git a/source/api/ut_runner.pks b/source/api/ut_runner.pks index 3170dedee..e5afce691 100644 --- a/source/api/ut_runner.pks +++ b/source/api/ut_runner.pks @@ -104,7 +104,14 @@ create or replace package ut_runner authid current_user is * @param a_package_name name of unit test package to retrieve (optional), if NULL all unit test packages are returned * @return ut_suite_items_info table of objects */ - function get_suites_info(a_owner varchar2 := null, a_package_name varchar2 := null) return ut_suite_items_info pipelined; + function get_suites_info(a_owner varchar2, a_package_name varchar2) return ut_suite_items_info pipelined; + + /** + * Returns a pipelined collection containing information about unit test suites and the tests contained in them + * + * @param a_path a path from which we lookg for object or suite + */ + function get_suites_info(a_path varchar2 := null) return ut_suite_items_info pipelined; /** diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index fe0aaabae..95615e2d5 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -148,16 +148,20 @@ create or replace package body ut_suite_cache_manager is return l_results; end; - + /* + The object name is populate but suitepath not + We will use that object and try to match. + We can pass also a wildcard this will result in one to many. + + Get all data that do not have an wildcard and not require expanding. + We will take them as they are. + a)suite path is populated + b)suite path and object is empty so schema name is by default ( or passed) + */ function expand_paths(a_schema_paths ut_path_items) return ut_path_items is l_schema_paths ut_path_items:= ut_path_items(); begin - with paths_to_expand as ( - /* - The object name is populate but suitepath not - We will use that object and try to match. - We can pass also a wildcard this will result in one to many. - */ + with paths_to_expand as ( select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, nvl2(sp.procedure_name,c.name,null) as procedure_name from table(a_schema_paths) sp left outer join ut_suite_cache c @@ -174,12 +178,6 @@ create or replace package body ut_suite_cache_manager is and c.path like replace(sp.suite_path,'*','%')) where sp.suite_path is not null and instr(sp.suite_path,'*') > 0 union all - /* - Get all data that do not have an wildcard and not require expanding. - We will take them as they are. - a)suite path is populated - b)suite path and object is empty so schema name is by default ( or passed) - */ select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name from table(a_schema_paths) sp where @@ -205,7 +203,6 @@ create or replace package body ut_suite_cache_manager is Were the path is populated we need to make sure we dont return duplicates as the wildcard can produce multiple results from same path and parents and child for each can be same resulting in duplicates - TODO: Verify that this not duplicate with a expand paths. */ function get_suite_items ( a_schema_paths ut_path_items @@ -484,22 +481,25 @@ create or replace package body ut_suite_cache_manager is end; function get_cached_suite_info( - a_object_owner varchar2, - a_object_name varchar2 + a_schema_paths ut_path_items + ) return ut_suite_cache_rows is + begin + return get_cached_suite_rows( a_schema_paths ); + end; + + function get_suite_items_info( + a_suite_cache_items ut_suite_cache_rows ) return ut_suite_items_info is - l_cache_rows ut_suite_cache_rows; l_results ut_suite_items_info; begin - l_cache_rows := get_cached_suite_rows( a_object_owner => a_object_owner, a_object_name =>a_object_name ); select /*+ no_parallel */ ut_suite_item_info( c.object_owner, c.object_name, c.name, c.description, c.self_type, c.line_no, c.path, c.disabled_flag, c.disabled_reason, c.tags ) bulk collect into l_results - from table(l_cache_rows) c; - - return l_results; + from table(a_suite_cache_items) c; + return l_results; end; function get_cached_packages( diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 3e2ac6451..05bff7af9 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -68,10 +68,13 @@ create or replace package ut_suite_cache_manager authid definer is * Not to be used publicly. Used internally for building suites info. */ function get_cached_suite_info( - a_object_owner varchar2, - a_object_name varchar2 + a_schema_paths ut_path_items + ) return ut_suite_cache_rows; + + function get_suite_items_info( + a_suite_cache_items ut_suite_cache_rows ) return ut_suite_items_info; - + /* * Retrieves list of cached suite packages. * Returned data is not filtered by user access rights. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 16beb0e36..cab24e607 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -533,8 +533,6 @@ create or replace package body ut_suite_manager is l_schema_paths ut_path_items; l_reconcile_paths ut_path_items; l_schema varchar2(4000); - l_suites_count pls_integer := 0; - l_index varchar2(4000 char); begin ut_event_manager.trigger_event('configure_execution_by_path - start'); a_suites := ut_suite_items(); @@ -567,37 +565,34 @@ create or replace package body ut_suite_manager is end configure_execution_by_path; function get_suites_info( - a_owner_name varchar2, - a_package_name varchar2 := null + a_paths ut_varchar2_list ) return sys_refcursor is - l_result sys_refcursor; - l_all_suite_info ut_suite_items_info; - l_owner_name varchar2(250) := ut_utils.qualified_sql_name(a_owner_name); - l_package_name varchar2(250) := ut_utils.qualified_sql_name(a_package_name); + l_result sys_refcursor; + l_all_suite_info ut_suite_items_info; + l_schema_names ut_varchar2_rows; + l_schema_paths ut_path_items; + l_paths ut_varchar2_list := a_paths; + l_schema varchar2(4000); + l_unfiltered_rows ut_suite_cache_rows; + l_filtered_rows ut_suite_cache_rows; + begin + l_schema_names := resolve_schema_names(l_paths); + --refresh cache + l_schema := l_schema_names.first; + while l_schema is not null loop + refresh_cache(upper(l_schema_names(l_schema))); + l_schema := l_schema_names.next(l_schema); + end loop; + l_schema_paths := ut_suite_cache_manager.get_schema_paths(l_paths); + l_unfiltered_rows := ut_suite_cache_manager.get_cached_suite_info(l_schema_paths); + l_filtered_rows := get_filtered_cursor(l_unfiltered_rows); + l_all_suite_info := ut_suite_cache_manager.get_suite_items_info(l_filtered_rows); + open l_result for + select /*+ no_parallel */ value(c) + from table(l_all_suite_info) c + order by c.object_owner, c.object_name, c.item_line_no; - refresh_cache(l_owner_name); - - l_all_suite_info := ut_suite_cache_manager.get_cached_suite_info( l_owner_name, l_package_name ); - if can_skip_all_objects_scan( l_owner_name ) then - open l_result for - select /*+ no_parallel */ value(c) - from table(l_all_suite_info) c - order by c.object_owner, c.object_name, c.item_line_no; - else - open l_result for - select /*+ no_parallel */ value(c) - from table(l_all_suite_info) c - where exists - ( select 1 - from all_objects a - where a.object_name = c.object_name - and a.owner = c.object_owner - and a.object_type = 'PACKAGE' - ) - or c.item_type = 'UT_LOGICAL_SUITE' - order by c.object_owner, c.object_name, c.item_line_no; - end if; return l_result; end; diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 5ae98d72a..6c96500b3 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -79,15 +79,11 @@ create or replace package ut_suite_manager authid current_user is /** * Returns a ref cursor containing information about unit test suites and the tests contained in them * - * @param a_owner owner of unit tests to retrieve - * @param a_package_name name of test package (optional) - * @param a_procedure_name name of test procedure (optional) - * @return ut_suite_items_info table of objects + * @param a_paths list of paths to be resolved and return a suites. */ function get_suites_info( - a_owner_name varchar2, - a_package_name varchar2 := null - ) return sys_refcursor; + a_paths ut_varchar2_list + ) return sys_refcursor; /** * Returns true if given suite item exists From 52c0307bbb5d9c7de5d3a6bc334558377f424f4e Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 1 Apr 2022 00:33:09 +0100 Subject: [PATCH 321/887] Addresing sonar issues --- source/api/ut_runner.pkb | 5 ++++- source/core/ut_suite_cache_manager.pkb | 17 ++++++++--------- source/core/ut_suite_manager.pkb | 6 +----- 3 files changed, 13 insertions(+), 15 deletions(-) diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index c49f895a3..b05e93056 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -195,12 +195,15 @@ create or replace package body ut_runner is l_cursor sys_refcursor; l_results ut_suite_items_info; c_bulk_limit constant integer := 100; + i pls_integer; begin l_cursor := ut_suite_manager.get_suites_info(ut_varchar2_list(nvl(a_path,sys_context('userenv', 'current_schema')))); loop fetch l_cursor bulk collect into l_results limit c_bulk_limit; - for i in 1 .. l_results.count loop + i := l_results.first; + while (i is not null) loop pipe row (l_results(i)); + i := l_results.next(i); end loop; exit when l_cursor%notfound; end loop; diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 95615e2d5..ba4510e62 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -131,8 +131,10 @@ create or replace package body ut_suite_cache_manager is c_package_path_regex constant varchar2(100) := '^([A-Za-z0-9$#_]+)(\.([A-Za-z0-9$#_\*]+))?(\.([A-Za-z0-9$#_\*]+))?$'; l_results ut_path_items := ut_path_items(); l_path_item ut_path_item; + i pls_integer; begin - for i in 1 .. a_paths.count loop + i := a_paths.first; + while (i is not null) loop l_results.extend; if a_paths(i) like '%:%' then l_path_item := ut_path_item(schema_name => upper(regexp_substr(a_paths(i),'^[^.:]+')), @@ -143,7 +145,8 @@ create or replace package body ut_suite_cache_manager is object_name => regexp_substr(a_paths(i), c_package_path_regex, subexpression => 3), procedure_name => regexp_substr(a_paths(i), c_package_path_regex, subexpression => 5)); l_results(l_results.last) := l_path_item; - end if; + end if; + i := a_paths.next(i); end loop; return l_results; @@ -189,7 +192,7 @@ create or replace package body ut_suite_cache_manager is bulk collect into l_schema_paths from (select schema_name,object_name,procedure_name,suite_path, - row_number() over ( partition by schema_name,object_name,procedure_name,suite_path order by 1) r_num + row_number() over ( partition by schema_name,object_name,procedure_name,suite_path order by 1) as r_num from paths_to_expand) where r_num = 1 ; return l_schema_paths; @@ -211,7 +214,7 @@ create or replace package body ut_suite_cache_manager is begin select obj bulk collect into l_suite_items from ( - select /*+ cardinality(c 500) */ value(c) as obj,row_number() over ( partition by path order by path asc) r_num + select /*+ cardinality(c 500) */ value(c) as obj,row_number() over ( partition by path order by path asc) as r_num from ut_suite_cache c, table(a_schema_paths) sp where c.object_owner = upper(sp.schema_name) @@ -301,7 +304,7 @@ create or replace package body ut_suite_cache_manager is l_procedure_name varchar2(250) := ut_utils.qualified_sql_name(a_procedure_name); l_schema_paths ut_path_items; begin - l_schema_paths := ut_path_items(ut_path_item(a_object_owner,a_object_name,a_procedure_name,a_path)); + l_schema_paths := ut_path_items(ut_path_item(l_object_owner,l_object_name,l_procedure_name,a_path)); return get_cached_suite_rows(l_schema_paths,a_random_seed,l_tags); end; @@ -314,10 +317,6 @@ create or replace package body ut_suite_cache_manager is l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); l_schema_paths ut_path_items; l_tags ut_varchar2_rows := coalesce(a_tags,ut_varchar2_rows()); - - l_suite_item_name varchar2(20); - l_paths ut_varchar2_rows; - l_schema varchar2(4000); l_sql varchar2(32767); begin diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index cab24e607..43df7f255 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -82,12 +82,9 @@ create or replace package body ut_suite_manager is l_schema := sys.dbms_assert.schema_name(upper(l_object)); exception when sys.dbms_assert.invalid_schema_name then - if l_object like '%*%' then + if l_object like '%*%' or ut_metadata.package_exists_in_cur_schema(upper(l_object)) then a_paths(i) := c_current_schema || '.' || a_paths(i); l_schema := c_current_schema; - elsif ut_metadata.package_exists_in_cur_schema(upper(l_object)) then - a_paths(i) := c_current_schema || '.' || a_paths(i); - l_schema := c_current_schema; else raise; end if; @@ -531,7 +528,6 @@ create or replace package body ut_suite_manager is l_paths ut_varchar2_list := a_paths; l_schema_names ut_varchar2_rows; l_schema_paths ut_path_items; - l_reconcile_paths ut_path_items; l_schema varchar2(4000); begin ut_event_manager.trigger_event('configure_execution_by_path - start'); From 8f8d257fc9de8f71eb6ed83bb62194f9fadef359 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 1 Apr 2022 01:02:39 +0100 Subject: [PATCH 322/887] Extra tests and cleanup of old code. --- source/core/ut_suite_cache_manager.pkb | 18 --------------- source/core/ut_suite_cache_manager.pks | 11 +-------- test/ut3_user/api/test_ut_runner.pkb | 32 ++++++++++++++++++++++++++ test/ut3_user/api/test_ut_runner.pks | 5 ++++ 4 files changed, 38 insertions(+), 28 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index ba4510e62..c045310c0 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -290,24 +290,6 @@ create or replace package body ut_suite_cache_manager is return expand_paths(group_paths_by_schema(a_paths)); end; - function get_cached_suite_rows( - a_object_owner varchar2, - a_path varchar2 := null, - a_object_name varchar2 := null, - a_procedure_name varchar2 := null, - a_random_seed positive := null, - a_tags ut_varchar2_rows := null - ) return ut_suite_cache_rows is - l_tags ut_varchar2_rows := coalesce(a_tags,ut_varchar2_rows()); - l_object_owner varchar2(250) := ut_utils.qualified_sql_name(a_object_owner); - l_object_name varchar2(250) := ut_utils.qualified_sql_name(a_object_name); - l_procedure_name varchar2(250) := ut_utils.qualified_sql_name(a_procedure_name); - l_schema_paths ut_path_items; - begin - l_schema_paths := ut_path_items(ut_path_item(l_object_owner,l_object_name,l_procedure_name,a_path)); - return get_cached_suite_rows(l_schema_paths,a_random_seed,l_tags); - end; - function get_cached_suite_rows( a_schema_paths ut_path_items, a_random_seed positive := null, diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 05bff7af9..6b12e7439 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -46,22 +46,13 @@ create or replace package ut_suite_cache_manager authid definer is * Not to be used publicly. Used internally for building suites at runtime. */ function get_cached_suite_rows( - a_object_owner varchar2, - a_path varchar2 := null, - a_object_name varchar2 := null, - a_procedure_name varchar2 := null, + a_schema_paths ut_path_items, a_random_seed positive := null, a_tags ut_varchar2_rows := null ) return ut_suite_cache_rows; function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items; - function get_cached_suite_rows( - a_schema_paths ut_path_items, - a_random_seed positive := null, - a_tags ut_varchar2_rows := null - ) return ut_suite_cache_rows; - /* * Retrieves suite item info rows from cache. * Returned data is not filtered by user access rights. diff --git a/test/ut3_user/api/test_ut_runner.pkb b/test/ut3_user/api/test_ut_runner.pkb index 80b1cd60b..b6b7c67e7 100644 --- a/test/ut3_user/api/test_ut_runner.pkb +++ b/test/ut3_user/api/test_ut_runner.pkb @@ -344,6 +344,38 @@ end;'; ut.expect(l_actual).to_equal(l_expected); end; + procedure test_get_suites_info_by_path is + l_expected sys_refcursor; + l_actual sys_refcursor; + begin + --Arrange + open l_expected for + select + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, + 'dummy_test_suite' item_description, 'UT_SUITE' item_type, 2 item_line_no, + 'some.path.dummy_test_package' path, 0 disabled_flag, null disabled_reason,null tags + from dual union all + select + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, + 'dummy_test' item_description, 'UT_TEST' item_type, 6 item_line_no, + 'some.path.dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason,null tags + from dual union all + select + 'UT3_USER' object_owner, 'PATH' object_name, 'PATH' item_name, + null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, + 'some.path' path, 0 disabled_flag, null disabled_reason, null tags + from dual union all + select + 'UT3_USER' object_owner, 'SOME' object_name, 'SOME' item_name, + null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, + 'some' path, 0 disabled_flag, null disabled_reason, null tags + from dual; + --Act + open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('ut3_user:some.path.dummy_test_package')); + --Assert + ut.expect(l_actual).to_equal(l_expected); + end; + procedure test_get_reporters_list is l_expected sys_refcursor; l_actual sys_refcursor; diff --git a/test/ut3_user/api/test_ut_runner.pks b/test/ut3_user/api/test_ut_runner.pks index 08282e997..e003ba852 100644 --- a/test/ut3_user/api/test_ut_runner.pks +++ b/test/ut3_user/api/test_ut_runner.pks @@ -65,6 +65,11 @@ create or replace package test_ut_runner is --%aftertest(cleanup_cache) procedure test_get_suites_info_twotag; + --%test(get_suites_info returns a cursor containing records for a newly created test with passed path) + --%beforetest(setup_cache_objects) + --%aftertest(cleanup_cache) + procedure test_get_suites_info_by_path; + --%test(get_reporters_list returns a cursor containing all built-in reporters and information about output-reporter) --%beforetest(setup_cache_objects) --%aftertest(cleanup_cache) From 12be1234bdff3e0abd5b48e237a68519d5466b99 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 1 Apr 2022 07:39:34 +0100 Subject: [PATCH 323/887] Adding extra tests --- test/ut3_tester/core/test_suite_manager.pkb | 10 ++++++++++ test/ut3_tester/core/test_suite_manager.pks | 5 ++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index 48ecf91f0..5baf5779d 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -955,6 +955,16 @@ end;]'; ut.expect(sqlerrm).to_be_like('%failing_non_*%'); end; + procedure test_search_nonex_prc_wild is + l_objects_to_run ut3_develop.ut_suite_items; + begin + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('ut3_develop.test_package_1.nonexist*')); + ut.fail('Non existing package did not raise exception'); + exception + when others then + ut.expect(sqlerrm).to_be_like('%failing_non_*%'); + end; + procedure test_search_nonex_path_wild is l_objects_to_run ut3_develop.ut_suite_items; begin diff --git a/test/ut3_tester/core/test_suite_manager.pks b/test/ut3_tester/core/test_suite_manager.pks index bea8faf96..ccd4d586c 100644 --- a/test/ut3_tester/core/test_suite_manager.pks +++ b/test/ut3_tester/core/test_suite_manager.pks @@ -78,7 +78,10 @@ create or replace package test_suite_manager is --%test(Prepare runner for nonexisting package using wildcard filter) procedure test_search_nonex_pck_wild; - + + --%test(Prepare runner for nonexisting procedure using wildcard filter) + procedure test_search_nonex_prc_wild; + --%test(Prepare runner for nonexisting path using wildcard filter) procedure test_search_nonex_path_wild; From d5ee6cad38b05e94e58e3811ba0917ca3d8f6d2c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 1 Apr 2022 11:19:11 +0100 Subject: [PATCH 324/887] Updating SQL to expand paths and extract suites. --- source/core/ut_suite_cache_manager.pkb | 50 +++++++++++++-------- test/ut3_tester/core/test_suite_manager.pkb | 4 +- 2 files changed, 33 insertions(+), 21 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index c045310c0..7bd8e3423 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -151,28 +151,41 @@ create or replace package body ut_suite_cache_manager is return l_results; end; + /* - The object name is populate but suitepath not - We will use that object and try to match. - We can pass also a wildcard this will result in one to many. + First SQL queries for objects where procedure is null or its only wildcard. + We split that due to fact that we can use func min to combine rows. + + Second union is responsible expanding paths where the procedure filter is given + We cannot select min here as filter can cover only half of tests within + package. Even if the filter doesnt return anything we still capture a proc filter + name for error reporting later on. - Get all data that do not have an wildcard and not require expanding. - We will take them as they are. - a)suite path is populated - b)suite path and object is empty so schema name is by default ( or passed) + Third SQL cover scenario where a suitapath only is populated and wildcard is given + + Fourth SQL cover scenario where suitepath is populated with no filters */ function expand_paths(a_schema_paths ut_path_items) return ut_path_items is l_schema_paths ut_path_items:= ut_path_items(); begin with paths_to_expand as ( select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, - nvl2(sp.procedure_name,c.name,null) as procedure_name + null as procedure_name + from table(a_schema_paths) sp left outer join ut_suite_cache c + on ( c.object_owner = upper(sp.schema_name) + and c.object_name like replace(upper(sp.object_name),'*','%')) + where sp.suite_path is null and sp.object_name is not null + and ( sp.procedure_name is null or sp.procedure_name = '*') + group by sp.schema_name,nvl(c.object_name,sp.object_name) + union all + select /*+ no_parallel */ path as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, + nvl(c.name,sp.procedure_name) as procedure_name from table(a_schema_paths) sp left outer join ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) and c.object_name like replace(upper(sp.object_name),'*','%') and c.name like nvl(replace(upper(sp.procedure_name),'*','%'), c.name)) where sp.suite_path is null and sp.object_name is not null - group by sp.schema_name,nvl(c.object_name,sp.object_name),nvl2(sp.procedure_name,c.name,null) + and (sp.procedure_name is not null and sp.procedure_name != '*') union all select /*+ no_parallel */ nvl(c.path,sp.suite_path) as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name from @@ -218,18 +231,17 @@ create or replace package body ut_suite_cache_manager is from ut_suite_cache c, table(a_schema_paths) sp where c.object_owner = upper(sp.schema_name) - and ( - (sp.suite_path is not null and - sp.suite_path||'.' like c.path||'.%' /*all parents and self*/ - or - ( c.path||'.' like sp.suite_path||'.%' /*all children and self*/ - and c.object_name like nvl(upper(sp.object_name),c.object_name) - and c.name like nvl(upper(sp.procedure_name),c.name) ) ) + and ((sp.suite_path is not null and sp.suite_path||'.' like c.path||'.%' /*all parents and self*/ + or + ( + c.path||'.' like sp.suite_path||'.%' /*all children and self*/ + and c.object_name like nvl(upper(sp.object_name),c.object_name) + and c.name like nvl(upper(sp.procedure_name),c.name) + )) or ( sp.suite_path is null - and c.object_name like nvl(upper(replace(sp.object_name,'*','%')),c.object_name) - and c.name like nvl(upper(replace(sp.procedure_name,'*','%')),c.name) - ))) where r_num = 1; + and c.object_name = nvl(upper(sp.object_name),c.object_name) + and c.name = nvl(upper(sp.procedure_name),c.name)))) where r_num =1; return l_suite_items; end; diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index 5baf5779d..684cc14fe 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -958,11 +958,11 @@ end;]'; procedure test_search_nonex_prc_wild is l_objects_to_run ut3_develop.ut_suite_items; begin - l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('ut3_develop.test_package_1.nonexist*')); + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('ut3_tester.test_package_1.nonexist*')); ut.fail('Non existing package did not raise exception'); exception when others then - ut.expect(sqlerrm).to_be_like('%failing_non_*%'); + ut.expect(sqlerrm).to_be_like('%nonexist*%'); end; procedure test_search_nonex_path_wild is From 2db8d635765b2c8e0d4d891a28bfce4d3d3f10ca Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 7 Apr 2022 00:24:16 +0100 Subject: [PATCH 325/887] Addressing issue with reconstruct_cache knocking off other levels. Solution was to introduce a sort order that work from bottom to top. --- source/core/ut_suite_cache_manager.pkb | 54 +++++++++++++++++++++----- 1 file changed, 44 insertions(+), 10 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 7bd8e3423..8777910b9 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -64,15 +64,10 @@ create or replace package body ut_suite_cache_manager is s.y, null, s.z ) as obj from logical_suite_data s - ), - items as ( - select obj from suite_items - union all - select obj from logical_suites ) - select /*+ no_parallel */ c.obj - from items c - order by c.obj.object_owner,{:random_seed:}]'; + select /*+ no_parallel */obj from suite_items + union all + select /*+ no_parallel */ obj from logical_suites]'; function get_missing_cache_objects(a_object_owner varchar2) return ut_varchar2_rows is l_result ut_varchar2_rows; @@ -293,6 +288,43 @@ create or replace package body ut_suite_cache_manager is return l_suite_tags; end; + /* + We will sort a suites in hierarchical structure. + Sorting from bottom to top so when we consolidate + we will go in proper order. + For random seed we will add an extra sort that can be null + */ + procedure sort_and_randomize_tests( + a_suite_rows in out ut_suite_cache_rows, + a_random_seed positive := null) + is + l_suite_rows ut_suite_cache_rows; + begin + with + extract_parent_child as ( + select s.path, substr(s.path,1,instr(s.path,'.',-1,1)-1) as parent_path,s.object_owner,s.line_no,a_random_seed random_seed + from table(a_suite_rows) s), + t1(path,parent_path,object_owner,line_no,random_seed) as ( + --Anchor memeber + select s.path, parent_path,s.object_owner,s.line_no,random_seed + from extract_parent_child s + where parent_path is null + union all + --Recursive member + select t2.path, t2.parent_path,t2.object_owner,t2.line_no,t2.random_seed + from t1,extract_parent_child t2 + where t2.parent_path = t1.path + and t1.object_owner = t2.object_owner) + search depth first by line_no desc,random_seed set order1 + select value(i) as obj + bulk collect into l_suite_rows + from t1 c + join table(a_suite_rows) i on i.object_owner = c.object_owner and i.path = c.path + order by order1 desc; + + a_suite_rows := l_suite_rows; + end; + /* * Public code */ @@ -308,6 +340,7 @@ create or replace package body ut_suite_cache_manager is a_tags ut_varchar2_rows := null ) return ut_suite_cache_rows is l_results ut_suite_cache_rows := ut_suite_cache_rows(); + l_results2 ut_suite_cache_rows := ut_suite_cache_rows(); l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); l_schema_paths ut_path_items; l_tags ut_varchar2_rows := coalesce(a_tags,ut_varchar2_rows()); @@ -316,7 +349,6 @@ create or replace package body ut_suite_cache_manager is l_schema_paths := a_schema_paths; l_sql := gc_get_bulk_cache_suite_sql; - l_sql := replace(l_sql,'{:random_seed:}',get_random_seed_sql(a_random_seed)); l_suite_items := get_suite_items(a_schema_paths); if l_tags.count > 0 then l_suite_items := get_tags_suites(l_suite_items,l_tags); @@ -325,7 +357,9 @@ create or replace package body ut_suite_cache_manager is execute immediate l_sql bulk collect into l_results - using l_suite_items, a_random_seed; + using l_suite_items; + + sort_and_randomize_tests(l_results,a_random_seed); return l_results; end; From d3396fef1fce55d8e25828e99aa2556ad3e336e5 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 7 Apr 2022 11:27:59 +0100 Subject: [PATCH 326/887] Update tests for random order --- source/core/ut_suite_cache_manager.pkb | 40 +++----------------------- test/ut3_user/api/test_ut_run.pkb | 2 +- 2 files changed, 5 insertions(+), 37 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 8777910b9..c76260212 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -88,40 +88,6 @@ create or replace package body ut_suite_cache_manager is return l_result; end; - function get_random_seed_sql(a_random_seed positive) return varchar2 is - begin - return case - when a_random_seed is null then q'[ - nlssort( - replace( - /*suite path until objects name (excluding contexts and test path) with trailing dot (full stop)*/ - substr( c.obj.path, 1, instr( c.obj.path, lower(c.obj.object_name), -1 ) + length(c.obj.object_name) ), - '.', - /*'.' replaced with chr(0) to assure that child elements come before parent when sorting in descending order*/ - chr(0) - ), - 'nls_sort=binary' - )desc nulls last, - case when c.obj.self_type = 'UT_SUITE_CONTEXT' then - ( select /*+ no_parallel */ max( x.line_no ) + 1 - from ut_suite_cache x - where c.obj.object_owner = x.object_owner - and c.obj.object_name = x.object_name - and x.path like c.obj.path || '.%' - ) - else - c.obj.line_no - end, - /*assures that child contexts come before parent contexts*/ - regexp_count(c.obj.path,'\.') desc, - :a_random_seed]' - else - ' ut_runner.hash_suite_path( - c.obj.path, :a_random_seed - ) desc nulls last' - end; - end; - function group_paths_by_schema(a_paths ut_varchar2_list) return ut_path_items is c_package_path_regex constant varchar2(100) := '^([A-Za-z0-9$#_]+)(\.([A-Za-z0-9$#_\*]+))?(\.([A-Za-z0-9$#_\*]+))?$'; l_results ut_path_items := ut_path_items(); @@ -302,7 +268,9 @@ create or replace package body ut_suite_cache_manager is begin with extract_parent_child as ( - select s.path, substr(s.path,1,instr(s.path,'.',-1,1)-1) as parent_path,s.object_owner,s.line_no,a_random_seed random_seed + select s.path, substr(s.path,1,instr(s.path,'.',-1,1)-1) as parent_path,s.object_owner, + case when a_random_seed is null then s.line_no else null end line_no, + case when a_random_seed is null then null else ut_runner.hash_suite_path(s.path, a_random_seed) end random_seed from table(a_suite_rows) s), t1(path,parent_path,object_owner,line_no,random_seed) as ( --Anchor memeber @@ -315,7 +283,7 @@ create or replace package body ut_suite_cache_manager is from t1,extract_parent_child t2 where t2.parent_path = t1.path and t1.object_owner = t2.object_owner) - search depth first by line_no desc,random_seed set order1 + search depth first by line_no desc,random_seed desc nulls last set order1 select value(i) as obj bulk collect into l_suite_rows from t1 c diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 492efcba2..41b969359 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -854,7 +854,7 @@ Failures:% l_results ut3_develop.ut_varchar2_list; begin select * bulk collect into l_random_results - from table ( ut3_develop.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 3 ) ) + from table ( ut3_develop.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 6 ) ) where trim(column_value) is not null and column_value not like 'Finished in %' and column_value not like '%Tests were executed with random order %'; From 02d41a64b391781b911bca572f0f835bc1cee929 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 7 Apr 2022 11:39:03 +0100 Subject: [PATCH 327/887] Removing a hash function from api into utils package which is more suited for it. --- source/api/ut_runner.pkb | 31 -------------------------- source/api/ut_runner.pks | 5 ----- source/core/ut_suite_cache_manager.pkb | 2 +- source/core/ut_utils.pkb | 31 ++++++++++++++++++++++++++ source/core/ut_utils.pks | 5 +++++ 5 files changed, 37 insertions(+), 37 deletions(-) diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index b05e93056..b69a51a04 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -265,37 +265,6 @@ create or replace package body ut_runner is end loop; end; - function hash_suite_path(a_path varchar2, a_random_seed positiven) return varchar2 is - l_start_pos pls_integer := 1; - l_end_pos pls_integer := 1; - l_result varchar2(4000); - l_item varchar2(4000); - l_at_end boolean := false; - begin - if a_random_seed is null then - l_result := a_path; - end if; - if a_path is not null then - loop - l_end_pos := instr(a_path,'.',l_start_pos); - if l_end_pos = 0 then - l_end_pos := length(a_path)+1; - l_at_end := true; - end if; - l_item := substr(a_path,l_start_pos,l_end_pos-l_start_pos); - if l_item is not null then - l_result := - l_result || - ut_utils.get_hash( to_char( dbms_utility.get_hash_value( l_item, 1, a_random_seed ) ) ); - end if; - exit when l_at_end; - l_result := l_result || chr(0); - l_start_pos := l_end_pos + 1; - end loop; - end if; - return l_result; - end; - procedure coverage_start(a_coverage_run_id raw) is begin ut_coverage.coverage_start(a_coverage_run_id); diff --git a/source/api/ut_runner.pks b/source/api/ut_runner.pks index e5afce691..85eff1c93 100644 --- a/source/api/ut_runner.pks +++ b/source/api/ut_runner.pks @@ -151,11 +151,6 @@ create or replace package ut_runner authid current_user is */ function get_reporters_list return tt_reporters_info pipelined; - /* - * Returns a hash value of suitepath based on input path and random seed - */ - function hash_suite_path(a_path varchar2, a_random_seed positiven) return varchar2; - procedure coverage_start(a_coverage_run_id raw); procedure coverage_stop; diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index c76260212..d76a6412e 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -270,7 +270,7 @@ create or replace package body ut_suite_cache_manager is extract_parent_child as ( select s.path, substr(s.path,1,instr(s.path,'.',-1,1)-1) as parent_path,s.object_owner, case when a_random_seed is null then s.line_no else null end line_no, - case when a_random_seed is null then null else ut_runner.hash_suite_path(s.path, a_random_seed) end random_seed + case when a_random_seed is null then null else ut_utils.hash_suite_path(s.path, a_random_seed) end random_seed from table(a_suite_rows) s), t1(path,parent_path,object_owner,line_no,random_seed) as ( --Anchor memeber diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 3675e834d..10d9d2393 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -892,6 +892,37 @@ create or replace package body ut_utils is return case when a_data is null then null else dbms_crypto.hash(a_data, a_hash_type) end; end; + function hash_suite_path(a_path varchar2, a_random_seed positiven) return varchar2 is + l_start_pos pls_integer := 1; + l_end_pos pls_integer := 1; + l_result varchar2(4000); + l_item varchar2(4000); + l_at_end boolean := false; + begin + if a_random_seed is null then + l_result := a_path; + end if; + if a_path is not null then + loop + l_end_pos := instr(a_path,'.',l_start_pos); + if l_end_pos = 0 then + l_end_pos := length(a_path)+1; + l_at_end := true; + end if; + l_item := substr(a_path,l_start_pos,l_end_pos-l_start_pos); + if l_item is not null then + l_result := + l_result || + ut_utils.get_hash( to_char( dbms_utility.get_hash_value( l_item, 1, a_random_seed ) ) ); + end if; + exit when l_at_end; + l_result := l_result || chr(0); + l_start_pos := l_end_pos + 1; + end loop; + end if; + return l_result; + end; + function qualified_sql_name(a_name varchar2) return varchar2 is begin return diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index aeff16dd8..e5f48eb95 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -452,6 +452,11 @@ create or replace package ut_utils authid definer is */ function get_hash(a_data clob, a_hash_type binary_integer := dbms_crypto.hash_sh1) return t_hash; + /* + * Returns a hash value of suitepath based on input path and random seed + */ + function hash_suite_path(a_path varchar2, a_random_seed positiven) return varchar2; + /* * Verifies that the input string is a qualified SQL name using sys.dbms_assert.qualified_sql_name * If null value passed returns null From 274d80a3b93cad1401a305509b41df4a34a83215 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 7 Apr 2022 12:38:41 +0100 Subject: [PATCH 328/887] Fixing ordering --- source/core/ut_suite_cache_manager.pkb | 6 +++--- source/core/ut_suite_manager.pkb | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index d76a6412e..d1d5b2e5c 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -259,6 +259,7 @@ create or replace package body ut_suite_cache_manager is Sorting from bottom to top so when we consolidate we will go in proper order. For random seed we will add an extra sort that can be null + TODO: Verify object owner join */ procedure sort_and_randomize_tests( a_suite_rows in out ut_suite_cache_rows, @@ -281,14 +282,13 @@ create or replace package body ut_suite_cache_manager is --Recursive member select t2.path, t2.parent_path,t2.object_owner,t2.line_no,t2.random_seed from t1,extract_parent_child t2 - where t2.parent_path = t1.path - and t1.object_owner = t2.object_owner) + where t2.parent_path = t1.path) search depth first by line_no desc,random_seed desc nulls last set order1 select value(i) as obj bulk collect into l_suite_rows from t1 c join table(a_suite_rows) i on i.object_owner = c.object_owner and i.path = c.path - order by order1 desc; + order by order1 desc; a_suite_rows := l_suite_rows; end; diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 43df7f255..bcf2fc417 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -279,7 +279,7 @@ create or replace package body ut_suite_manager is pragma inline(get_logical_suite, 'YES'); a_suites(a_suites.last) := get_logical_suite(l_rows, l_idx, l_level,l_prev_level, l_items_at_level ); end if; - if l_prev_level > l_level then + if l_prev_level > l_level then l_items_at_level(l_prev_level).delete; end if; l_prev_level := l_level; From 39377379eaed235e47962465f5240fee706f46cf Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 7 Apr 2022 13:00:02 +0100 Subject: [PATCH 329/887] Fixing a documentation --- docs/userguide/running-unit-tests.md | 8 +++----- source/core/types/ut_path_item.tpb | 2 +- source/core/types/ut_path_item.tps | 2 +- source/core/ut_suite_cache_manager.pkb | 6 ++++-- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 2a8f8e151..8a43e8386 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -45,10 +45,8 @@ The **functions** can only be used in SELECT statements. They execute the specif ## ut.run procedures The examples below illustrate different ways and options to invoke `ut.run` procedures. -As part of the syntax you can use a wildcard character `*` to call test by part of his name or to call few tests that match a call. -Schema name is still mandatory and cannot contain a wildcard character whether is a suitepath or object. - - +You can use a wildcard character `*` to call tests by part of their name or to call tests that are located on paths matched by part of path string. +Schema name cannot contain a wildcard character whether is in a suitepath call or call by object name. ```sql alter session set current_schema=hr; @@ -142,7 +140,7 @@ begin ut.run('hr.test*'); end; ``` -Executes all tests from schema _hr_ starting with name _test_. +Executes all tests in schema `hr` located in packages starting with name `test`. ```sql set serveroutput on diff --git a/source/core/types/ut_path_item.tpb b/source/core/types/ut_path_item.tpb index 3878b544c..6cdb2b8ad 100644 --- a/source/core/types/ut_path_item.tpb +++ b/source/core/types/ut_path_item.tpb @@ -39,4 +39,4 @@ create or replace type body ut_path_item as return; end; end; -/ \ No newline at end of file +/ diff --git a/source/core/types/ut_path_item.tps b/source/core/types/ut_path_item.tps index f6c64195c..c8ec81be5 100644 --- a/source/core/types/ut_path_item.tps +++ b/source/core/types/ut_path_item.tps @@ -23,4 +23,4 @@ create or replace type ut_path_item as object ( constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, suite_path varchar2) return self as result, constructor function ut_path_item(self in out nocopy ut_path_item, schema_name varchar2, object_name varchar2,procedure_name varchar2,suite_path varchar2) return self as result ) -/ \ No newline at end of file +/ diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index d1d5b2e5c..f7e89eb96 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -258,8 +258,10 @@ create or replace package body ut_suite_cache_manager is We will sort a suites in hierarchical structure. Sorting from bottom to top so when we consolidate we will go in proper order. - For random seed we will add an extra sort that can be null - TODO: Verify object owner join + For random seed we will add an extra sort that can be null. + The object owner is irrelevant on joing via path as we already + resolved a list of test we want to use so as long they share a suitepath + they are correct. */ procedure sort_and_randomize_tests( a_suite_rows in out ut_suite_cache_rows, From 9296f382dc5a858032ed292a46611abe4cd91a3f Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 7 Apr 2022 13:24:42 +0100 Subject: [PATCH 330/887] Fixing indent --- source/core/ut_utils.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 10d9d2393..162e50f8f 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -901,7 +901,7 @@ create or replace package body ut_utils is begin if a_random_seed is null then l_result := a_path; - end if; + end if; if a_path is not null then loop l_end_pos := instr(a_path,'.',l_start_pos); From 6ff7f38ba80a1bbc063feb7b696d0236f243dd40 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 12 Apr 2022 23:14:15 +0100 Subject: [PATCH 331/887] Peer review changes --- source/core/ut_suite_cache_manager.pkb | 27 ++++++++--------- source/core/ut_suite_cache_manager.pks | 9 ++++++ source/core/ut_suite_manager.pkb | 40 ++++++++++++-------------- source/core/ut_suite_manager.pks | 1 + source/create_grants.sql | 1 + 5 files changed, 42 insertions(+), 36 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index f7e89eb96..4f8cb8f62 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -19,12 +19,11 @@ create or replace package body ut_suite_cache_manager is /* * Private code */ - - gc_get_bulk_cache_suite_sql constant varchar2(32767) := - q'[with + cursor c_get_bulk_cache_suite(cp_suite_items in ut_suite_cache_rows) is + with suite_items as ( select /*+ cardinality(c 500) */ value(c) as obj - from table(:suite_items) c), + from table(cp_suite_items) c), suitepaths as ( select distinct substr(c.obj.path,1,instr(c.obj.path,'.',-1)-1) as suitepath, c.obj.path as path, @@ -65,9 +64,9 @@ create or replace package body ut_suite_cache_manager is ) as obj from logical_suite_data s ) - select /*+ no_parallel */obj from suite_items + select /*+ no_parallel */ obj from suite_items union all - select /*+ no_parallel */ obj from logical_suites]'; + select /*+ no_parallel */ obj from logical_suites; function get_missing_cache_objects(a_object_owner varchar2) return ut_varchar2_rows is l_result ut_varchar2_rows; @@ -126,6 +125,9 @@ create or replace package body ut_suite_cache_manager is Fourth SQL cover scenario where suitepath is populated with no filters */ + + --TODO: Przenies w osobny with clause z nazwami jako opis. + -- i with clause na tablice. function expand_paths(a_schema_paths ut_path_items) return ut_path_items is l_schema_paths ut_path_items:= ut_path_items(); begin @@ -310,26 +312,21 @@ create or replace package body ut_suite_cache_manager is a_tags ut_varchar2_rows := null ) return ut_suite_cache_rows is l_results ut_suite_cache_rows := ut_suite_cache_rows(); - l_results2 ut_suite_cache_rows := ut_suite_cache_rows(); l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); l_schema_paths ut_path_items; l_tags ut_varchar2_rows := coalesce(a_tags,ut_varchar2_rows()); - l_sql varchar2(32767); begin l_schema_paths := a_schema_paths; - l_sql := gc_get_bulk_cache_suite_sql; l_suite_items := get_suite_items(a_schema_paths); if l_tags.count > 0 then l_suite_items := get_tags_suites(l_suite_items,l_tags); end if; - ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_key_anyvalues().put('l_sql',l_sql) ); - - execute immediate l_sql - bulk collect into l_results - using l_suite_items; + + open c_get_bulk_cache_suite(l_suite_items); + fetch c_get_bulk_cache_suite bulk collect into l_results; + close c_get_bulk_cache_suite; - sort_and_randomize_tests(l_results,a_random_seed); return l_results; end; diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 6b12e7439..974babca5 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -40,6 +40,15 @@ create or replace package ut_suite_cache_manager authid definer is */ procedure remove_missing_objs_from_cache(a_schema_name varchar2); + /* + * We will sort a suites in hierarchical structure. + * Sorting from bottom to top so when we consolidate + * we will go in proper order. + */ + procedure sort_and_randomize_tests( + a_suite_rows in out ut_suite_cache_rows, + a_random_seed positive := null); + /* * Retrieves suite items data from cache. * Returned data is not filtered by user access rights. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index bcf2fc417..b29b8134c 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -295,7 +295,8 @@ create or replace package body ut_suite_manager is end loop; close a_suite_data_cursor; end reconstruct_from_cache; - + + --TODO: daj do public ut_suite_cache_rows i zmienic na SQL function get_filtered_cursor( a_unfiltered_rows in ut_suite_cache_rows, a_skip_all_objects boolean := false @@ -306,26 +307,21 @@ create or replace package body ut_suite_manager is if ut_metadata.user_has_execute_any_proc() or a_skip_all_objects then l_result := a_unfiltered_rows; else - for i in ( - select /*+ no_parallel */ c.* from table(a_unfiltered_rows) c - where sys_context( 'userenv', 'current_user' ) = upper(c.object_owner) - union all - select /*+ no_parallel */ c.* from table(a_unfiltered_rows) c - where sys_context( 'userenv', 'current_user' ) != upper(c.object_owner) - and ( exists - ( select 1 - from all_objects a - where a.object_name = c.object_name - and a.owner = c.object_owner - and a.object_type = 'PACKAGE' - ) - or c.self_type = 'UT_LOGICAL_SUITE')) - loop - l_result.extend; - l_result(l_result.last) := ut_suite_cache_row(i.id,i.self_type,i.path,i.object_owner,i.object_name,i.name,i.line_no,i.parse_time, - i.description,i.rollback_type,i.disabled_flag,i.disabled_reason,i.warnings,i.before_all_list,i.after_all_list,i.before_each_list, - i.before_test_list,i.after_each_list,i.after_test_list,i.expected_error_codes,i.tags,i.item); - end loop; + select obj bulk collect into l_result + from ( + select /*+ no_parallel */ value(c) as obj from table(a_unfiltered_rows) c + where sys_context( 'userenv', 'current_user' ) = upper(c.object_owner) + union all + select /*+ no_parallel */ value(c) as obj from table(a_unfiltered_rows) c + where sys_context( 'userenv', 'current_user' ) != upper(c.object_owner) + and ( exists + ( select 1 + from all_objects a + where a.object_name = c.object_name + and a.owner = c.object_owner + and a.object_type = 'PACKAGE' + ) + or c.self_type = 'UT_LOGICAL_SUITE')); end if; return l_result; end; @@ -373,6 +369,8 @@ create or replace package body ut_suite_manager is l_filtered_rows := get_filtered_cursor(l_unfiltered_rows,a_skip_all_objects); reconcile_paths_and_suites(a_schema_paths,l_filtered_rows); + ut_suite_cache_manager.sort_and_randomize_tests(l_filtered_rows,a_random_seed); + open l_result for select * from table(l_filtered_rows); return l_result; diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 6c96500b3..170b83f05 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -39,6 +39,7 @@ create or replace package ut_suite_manager authid current_user is * @return array containing root suites-ready to be executed * */ + --TODO:Zerknij czy mozna wywalic function configure_execution_by_path(a_paths ut_varchar2_list, a_random_seed positive := null) return ut_suite_items; /** diff --git a/source/create_grants.sql b/source/create_grants.sql index 6401b1522..8a44ab371 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -60,6 +60,7 @@ grant execute on &&ut3_owner..ut_file_mapping to &ut3_user; grant execute on &&ut3_owner..ut_file_mapper to &ut3_user; grant execute on &&ut3_owner..ut_suite_items_info to &ut3_user; grant execute on &&ut3_owner..ut_suite_item_info to &ut3_user; +grant execute on &&ut3_owner..ut_suite_cache_rows to &ut3_user; grant execute on &&ut3_owner..ut_run_info to &ut3_user; grant execute on &&ut3_owner..ut_coverage_options to &ut3_user; From ee7a98b97357667fd7229c3f6711e4bd7cb2576c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 12 Apr 2022 23:24:56 +0100 Subject: [PATCH 332/887] Moving a SQL to be more readable. --- source/core/ut_suite_cache_manager.pkb | 38 +++++++++++++++++--------- source/core/ut_suite_manager.pkb | 1 - 2 files changed, 25 insertions(+), 14 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 4f8cb8f62..ae34e1344 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -125,51 +125,63 @@ create or replace package body ut_suite_cache_manager is Fourth SQL cover scenario where suitepath is populated with no filters */ - - --TODO: Przenies w osobny with clause z nazwami jako opis. - -- i with clause na tablice. function expand_paths(a_schema_paths ut_path_items) return ut_path_items is l_schema_paths ut_path_items:= ut_path_items(); begin - with paths_to_expand as ( + with + schema_paths as ( + select * from table(a_schema_paths) + ), + paths_for_object as ( select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, null as procedure_name - from table(a_schema_paths) sp left outer join ut_suite_cache c + from schema_paths sp left outer join ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) and c.object_name like replace(upper(sp.object_name),'*','%')) where sp.suite_path is null and sp.object_name is not null and ( sp.procedure_name is null or sp.procedure_name = '*') group by sp.schema_name,nvl(c.object_name,sp.object_name) - union all + ), + paths_for_procedures as ( select /*+ no_parallel */ path as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, nvl(c.name,sp.procedure_name) as procedure_name - from table(a_schema_paths) sp left outer join ut_suite_cache c + from schema_paths sp left outer join ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) and c.object_name like replace(upper(sp.object_name),'*','%') and c.name like nvl(replace(upper(sp.procedure_name),'*','%'), c.name)) where sp.suite_path is null and sp.object_name is not null and (sp.procedure_name is not null and sp.procedure_name != '*') - union all + ), + paths_for_suite_path_with_ast as ( select /*+ no_parallel */ nvl(c.path,sp.suite_path) as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name - from - table(a_schema_paths) sp left outer join ut_suite_cache c on + from schema_paths sp left outer join ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) and c.path like replace(sp.suite_path,'*','%')) where sp.suite_path is not null and instr(sp.suite_path,'*') > 0 - union all + ), + straigth_suite_paths as ( select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name - from table(a_schema_paths) sp + from schema_paths sp where (sp.suite_path is not null and instr(sp.suite_path,'*') = 0) or (sp.suite_path is null and sp.object_name is null) + ), + all_suitepaths_together as ( + select * from paths_for_object + union all + select * from paths_for_procedures + union all + select * from paths_for_suite_path_with_ast + union all + select * from straigth_suite_paths ) select ut_path_item(schema_name,object_name,procedure_name,suite_path) bulk collect into l_schema_paths from (select schema_name,object_name,procedure_name,suite_path, row_number() over ( partition by schema_name,object_name,procedure_name,suite_path order by 1) as r_num - from paths_to_expand) + from all_suitepaths_together) where r_num = 1 ; return l_schema_paths; end; diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index b29b8134c..4c3542f23 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -296,7 +296,6 @@ create or replace package body ut_suite_manager is close a_suite_data_cursor; end reconstruct_from_cache; - --TODO: daj do public ut_suite_cache_rows i zmienic na SQL function get_filtered_cursor( a_unfiltered_rows in ut_suite_cache_rows, a_skip_all_objects boolean := false From a53cefa29e9d49d6b60255f0ded327e843c4502f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 13 Apr 2022 10:46:57 +0100 Subject: [PATCH 333/887] Apply suggestions from code review --- docs/userguide/running-unit-tests.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 8a43e8386..1a26ca203 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -84,7 +84,7 @@ begin end; ``` -Executes all tests from all packages that are on suitepath starting with _com_. +Executes all tests in schema `hr` from all packages that are on suitepath starting with `com`. ```sql set serveroutput on @@ -148,7 +148,7 @@ begin ut.run('hr.test_apply_bonus.bonus_*'); end; ``` -Executes all test procedures from package _hr.test_apply_bonus_ that starting with _bonus_. +Executes test procedures with names starting with `bonus` in package `hr.test_apply_bonus` . **Note:** From 011970f8f642e2d63d94c0f02027d7e59cf74cb5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 13 Apr 2022 17:16:18 +0300 Subject: [PATCH 334/887] Apply suggestions from code review --- source/core/ut_suite_cache_manager.pkb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index ae34e1344..4c738ab64 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -258,12 +258,12 @@ create or replace package body ut_suite_cache_manager is from table(a_suite_items) c where exists ( select 1 from included_tags t - where t.path||'.' like c.path || '.%' /*all parents and self*/ - or c.path||'.' like t.path || '.%' /*all children and self*/ + where t.path||'.' like c.path || '.%' /*all ancestors and self*/ + or c.path||'.' like t.path || '.%' /*all descendants and self*/ ) and not exists ( select 1 from excluded_tags t - where c.path||'.' like t.path || '.%' /*all children and self*/ + where c.path||'.' like t.path || '.%' /*all descendants and self*/ ); return l_suite_tags; end; From 3437b689e2097b1bdae4b0daf22b09549e5eabee Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 15 Apr 2022 23:25:52 +0300 Subject: [PATCH 335/887] Fixed issue where schema last parse time was wrongly populated --- source/core/annotations/ut_annotation_manager.pkb | 8 +++----- source/core/ut_suite_cache_manager.pkb | 2 +- source/core/ut_suite_manager.pkb | 4 ++-- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 95d944843..16923bc23 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -61,15 +61,15 @@ create or replace package body ut_annotation_manager as l_refresh_needed boolean; l_objects_view varchar2(200) := ut_metadata.get_objects_view_name(); l_cached_objects ut_annotation_objs_cache_info; - l_result ut_annotation_objs_cache_info; + l_result ut_annotation_objs_cache_info := ut_annotation_objs_cache_info(); begin - ut_event_manager.trigger_event( 'get_objects_to_refresh - start' ); + ut_event_manager.trigger_event( 'get_objects_to_refresh - start', ut_key_anyvalues().put('ut_trigger_check.is_alive()',ut_trigger_check.is_alive()) ); l_refresh_needed := ( ut_trigger_check.is_alive() = false ) or a_modified_after is null; - l_cached_objects := ut_annotation_cache_manager.get_cached_objects_list( a_object_owner, a_object_type, a_modified_after ); if l_refresh_needed then --limit the list to objects that exist and are visible to the invoking user --enrich the list by info about cache validity + l_cached_objects := ut_annotation_cache_manager.get_cached_objects_list( a_object_owner, a_object_type, a_modified_after ); execute immediate 'select /*+ no_parallel cardinality(i '||ut_utils.scale_cardinality(cardinality(l_cached_objects))||') */ '||l_ut_owner||q'[.ut_annotation_obj_cache_info( @@ -94,8 +94,6 @@ create or replace package body ut_annotation_manager as else 'o.last_ddl_time >= cast(:a_modified_after as date)' end bulk collect into l_result using l_cached_objects, a_modified_after; - else - l_result := l_cached_objects; end if; ut_event_manager.trigger_event('get_objects_to_refresh - end (count='||l_result.count||')'); return l_result; diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index ad1634c10..1023a515b 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -297,7 +297,7 @@ create or replace package body ut_suite_cache_manager is if a_parse_time > l_cached_parse_time or l_cached_parse_time is null then update /*+ no_parallel */ ut_suite_cache_schema t - set t.parse_time = a_parse_time + set t.parse_time = greatest(t.parse_time,a_parse_time) where object_owner = l_object_owner; if sql%rowcount = 0 then diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 4bcb83afa..a11b0249c 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -366,7 +366,7 @@ create or replace package body ut_suite_manager is ) or c.self_type = 'UT_LOGICAL_SUITE'; end if; - + return l_result; end; @@ -578,7 +578,7 @@ create or replace package body ut_suite_manager is a_suites(i).set_rollback_type( a_suites(i).get_rollback_type() ); end loop; - ut_event_manager.trigger_event('configure_execution_by_path - start'); + ut_event_manager.trigger_event('configure_execution_by_path - end'); end configure_execution_by_path; function get_suites_info( From 6751290e503b45c589d83931743a2fa7dc402b12 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 15 Apr 2022 22:19:15 +0100 Subject: [PATCH 336/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index ad0cad34c..4594b9864 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 9641132fd..746421e4a 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index c1eefa2dd..590fce081 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 5812e2cab..6400be9d1 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 140c3e3dd..e1a5cd7dd 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 9e4528342..085c06221 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index a2612c3b8..68a26ce8b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 9c90a1865..645eda5f1 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 2c262abbf..0112c44d8 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 27dfc6c1f..a84d80f11 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 8e1872497..9dabeb2fd 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 3aa97dcb8..c29a40c7b 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 08308bc8a..1c631d0d5 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 11e08be1d..976630ae9 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 373830f95..8f4d0765a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index d3fcfd520..e2f308c47 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index bf5cf8c7b..a5fb8a669 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.3943--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 027a06c21..3635bccad 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.3943-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4003-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 221c2de768de9120dd3031a795dae82c5f6a6586 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 16 Apr 2022 02:31:56 +0100 Subject: [PATCH 337/887] Address issue of not recognizing a correct nested level of suitepath. Added extra tests for different scenarios. --- source/core/ut_suite_cache_manager.pkb | 3 +- test/ut3_tester/core/test_suite_manager.pkb | 495 +++++++++++++++++++- test/ut3_tester/core/test_suite_manager.pks | 36 +- 3 files changed, 525 insertions(+), 9 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 4c738ab64..b12f415d2 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -156,7 +156,8 @@ create or replace package body ut_suite_cache_manager is select /*+ no_parallel */ nvl(c.path,sp.suite_path) as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name from schema_paths sp left outer join ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) - and c.path like replace(sp.suite_path,'*','%')) + --and c.path like replace(sp.suite_path,'*','%')) + and regexp_like(c.path,'^'||replace(sp.suite_path,'*','[A-Za-z0-9$#_]*'))) where sp.suite_path is not null and instr(sp.suite_path,'*') > 0 ), straigth_suite_paths as ( diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index 684cc14fe..fbac0f3f5 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -278,8 +278,167 @@ end test_package_with_ctx;]'; end; end test_package_with_ctx;]'; + + execute immediate q'[create or replace package test1_frontwildcard is + + --%suite + --%displayname(test1_frontwildcard) + --%suitepath(front_wildcard) + --%rollback(manual) + + --%test + --%displayname(Test1 from test test1_frontwildcard) + procedure first_test; + + --%test + --%displayname(Test2 from test test1_frontwildcard) + procedure second_test; + +end test1_frontwildcard;]'; + + execute immediate q'[create or replace package body test1_frontwildcard is + + procedure first_test is + begin + ut.expect(1).to_equal(1); + end; + + procedure second_test is + begin + ut.expect(1).to_equal(2); + end; + +end test1_frontwildcard;]'; + + execute immediate q'[create or replace package test2_frontwildcard is + + --%suite + --%displayname(test2_frontwildcard) + --%suitepath(front_wildcard) + --%rollback(manual) + + --%test + --%displayname(Test1 from test package test2_frontwildcard) + procedure first_test; + +end test2_frontwildcard;]'; + + execute immediate q'[create or replace package body test2_frontwildcard is + + procedure first_test is + begin + ut.expect(1).to_equal(1); + end; + +end test2_frontwildcard;]'; + + execute immediate q'[create or replace package middle_test1_wildcard is + + --%suite + --%displayname(middle_test1_wildcard) + --%suitepath(wild_middle_card) + --%rollback(manual) + + --%test + --%displayname(Test1 from test middle_test1_wildcard) + procedure middle_first_test; + + --%test + --%displayname(Test2 from test middle_test1_wildcard) + procedure middle_second_test; + +end middle_test1_wildcard;]'; + + execute immediate q'[create or replace package body middle_test1_wildcard is + + procedure middle_first_test is + begin + ut.expect(1).to_equal(1); + end; + + procedure middle_second_test is + begin + ut.expect(1).to_equal(2); end; +end middle_test1_wildcard;]'; + + execute immediate q'[create or replace package middle_test2_wildcard is + + --%suite + --%displayname(middle_test2_wildcard) + --%suitepath(wild_middle_card) + --%rollback(manual) + + --%test + --%displayname(Test1 from test package middle_test2_wildcard) + procedure middle_first_test; + +end middle_test2_wildcard;]'; + + execute immediate q'[create or replace package body middle_test2_wildcard is + + procedure middle_first_test is + begin + ut.expect(1).to_equal(1); + end; + +end middle_test2_wildcard;]'; + + execute immediate q'[create or replace package test1_multi_wildcard is + + --%suite + --%displayname(test1_multi_wildcard) + --%suitepath(wildcard_multi_asterisks) + --%rollback(manual) + + --%test + --%displayname(Test1 from test test1_multi_wildcard) + procedure first_multi_test1; + + --%test + --%displayname(Test2 from test test1_multi_wildcard) + procedure second_multi_test2; + +end test1_multi_wildcard;]'; + + execute immediate q'[create or replace package body test1_multi_wildcard is + + procedure first_multi_test1 is + begin + ut.expect(1).to_equal(1); + end; + + procedure second_multi_test2 is + begin + ut.expect(1).to_equal(2); + end; + +end test1_multi_wildcard;]'; + + execute immediate q'[create or replace package test2_multi_wildcard is + + --%suite + --%displayname(test2_multi_wildcard) + --%suitepath(wildcard_multi_asterisks) + --%rollback(manual) + + --%test + --%displayname(Test1 from test package test2_multi_wildcard) + procedure first_multi_test1; + +end test2_multi_wildcard;]'; + + execute immediate q'[create or replace package body test2_multi_wildcard is + + procedure first_multi_test1 is + begin + ut.expect(1).to_equal(1); + end; + +end test2_multi_wildcard;]'; + + end; procedure drop_dummy_packages is pragma autonomous_transaction; @@ -288,6 +447,12 @@ end test_package_with_ctx;]'; execute immediate 'drop package test_package_2'; execute immediate 'drop package test_package_3'; execute immediate 'drop package test_package_with_ctx'; + execute immediate 'drop package test1_frontwildcard'; + execute immediate 'drop package test2_frontwildcard'; + execute immediate 'drop package middle_test1_wildcard'; + execute immediate 'drop package middle_test2_wildcard'; + execute immediate 'drop package test1_multi_wildcard'; + execute immediate 'drop package test2_multi_wildcard'; end; procedure test_schema_run is @@ -1671,8 +1836,7 @@ end;]'; l_objects_to_run ut3_develop.ut_suite_items; l_test_suite ut3_develop.ut_logical_suite; l_test1_suite ut3_develop.ut_logical_suite; - l_test2_suite ut3_develop.ut_logical_suite; - l_test3_suite ut3_develop.ut_logical_suite; + l_test2_suite ut3_develop.ut_logical_suite; l_ctx_suite ut3_develop.ut_logical_suite; l_test_proc ut3_develop.ut_test; begin @@ -1694,9 +1858,6 @@ end;]'; ut.expect(l_test1_suite.items.count).to_equal(3); for i in 1 ..3 loop - --l_test2_suite := treat(l_test1_suite.items(i) as ut3_develop.ut_logical_suite); - --ut.expect(l_test2_suite.name).to_equal('test_package_2'); - --ut.expect(l_test2_suite.items.count).to_equal(3); case l_test1_suite.items(i).self_type when 'UT_SUITE' then l_test2_suite := treat(l_test1_suite.items(i) as ut3_develop.ut_logical_suite); @@ -1732,5 +1893,329 @@ end;]'; end; + procedure test_wild_card_front_obj_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.*_frontwildcard'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('front_wildcard'); + ut.expect(l_test_suite.items.count).to_equal(2); + + for i in 1 .. 2 loop + l_test1_suite := treat(l_test_suite.items(i) as ut3_develop.ut_logical_suite); + case l_test1_suite.name + when 'test1_frontwildcard' then + ut.expect(l_test1_suite.items.count).to_equal(2); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_test'); + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('second_test'); + when 'test2_frontwildcard' then + ut.expect(l_test1_suite.items.count).to_equal(1); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_test'); + end case; + + end loop; + end; + + procedure test_wild_card_front_prc_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test1_frontwildcard.*_test'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('front_wildcard'); + + l_test1_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test1_suite.name).to_equal('test1_frontwildcard'); + ut.expect(l_test1_suite.items.count).to_equal(2); + + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_test'); + + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('second_test'); + end; + + procedure test_wild_card_front_path_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':*_wildcard'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('front_wildcard'); + ut.expect(l_test_suite.items.count).to_equal(2); + + for i in 1 .. 2 loop + l_test1_suite := treat(l_test_suite.items(i) as ut3_develop.ut_logical_suite); + case l_test1_suite.name + when 'test1_frontwildcard' then + ut.expect(l_test1_suite.items.count).to_equal(2); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_test'); + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('second_test'); + when 'test2_frontwildcard' then + ut.expect(l_test1_suite.items.count).to_equal(1); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_test'); + end case; + + end loop; + end; + + procedure test_wild_card_mid_obj_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.middle_*_wildcard'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('wild_middle_card'); + ut.expect(l_test_suite.items.count).to_equal(2); + + for i in 1 .. 2 loop + l_test1_suite := treat(l_test_suite.items(i) as ut3_develop.ut_logical_suite); + case l_test1_suite.name + when 'middle_test1_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(2); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('middle_first_test'); + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('middle_second_test'); + when 'middle_test2_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(1); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('middle_first_test'); + end case; + + end loop; + end; + + procedure test_wild_card_mid_prc_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.middle_test1_wildcard.middle_*_test'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('wild_middle_card'); + + l_test1_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test1_suite.name).to_equal('middle_test1_wildcard'); + ut.expect(l_test1_suite.items.count).to_equal(2); + + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('middle_first_test'); + + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('middle_second_test'); + end; + + procedure test_wild_card_mid_path_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':wild_*card'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('wild_middle_card'); + ut.expect(l_test_suite.items.count).to_equal(2); + + for i in 1 .. 2 loop + l_test1_suite := treat(l_test_suite.items(i) as ut3_develop.ut_logical_suite); + case l_test1_suite.name + when 'middle_test1_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(2); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('middle_first_test'); + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('middle_second_test'); + when 'middle_test2_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(1); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('middle_first_test'); + end case; + + end loop; + end; + + procedure test_wild_card_mul_obj_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.*_multi_*card'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('wildcard_multi_asterisks'); + ut.expect(l_test_suite.items.count).to_equal(2); + + for i in 1 .. 2 loop + l_test1_suite := treat(l_test_suite.items(i) as ut3_develop.ut_logical_suite); + case l_test1_suite.name + when 'test1_multi_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(2); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_multi_test1'); + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('second_multi_test2'); + when 'test2_multi_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(1); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_multi_test1'); + end case; + + end loop; + end; + + procedure test_wild_card_mul_prc_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test1_multi_wildcard.*_multi_*'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('wildcard_multi_asterisks'); + + l_test1_suite := treat(l_test_suite.items(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test1_suite.name).to_equal('test1_multi_wildcard'); + ut.expect(l_test1_suite.items.count).to_equal(2); + + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_multi_test1'); + + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('second_multi_test2'); + end; + + procedure test_wild_card_mul_path_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':wild*_multi_*risks'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('wildcard_multi_asterisks'); + ut.expect(l_test_suite.items.count).to_equal(2); + + for i in 1 .. 2 loop + l_test1_suite := treat(l_test_suite.items(i) as ut3_develop.ut_logical_suite); + case l_test1_suite.name + when 'test1_multi_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(2); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_multi_test1'); + l_test2_proc := treat(l_test1_suite.items(2) as ut3_develop.ut_test); + ut.expect(l_test2_proc.name).to_equal('second_multi_test2'); + when 'test2_multi_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(1); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_multi_test1'); + end case; + + end loop; + end; + + procedure tst_wild_card_mul_lv_path_name is + c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||':wild*_multi_*risks.*_multi_wildcard.*_multi_test1'; + l_objects_to_run ut3_develop.ut_suite_items; + l_test_suite ut3_develop.ut_logical_suite; + l_test1_suite ut3_develop.ut_logical_suite; + l_test1_proc ut3_develop.ut_test; + l_test2_proc ut3_develop.ut_test; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_path)); + + --Assert + ut.expect(l_objects_to_run.count).to_equal(1); + l_test_suite := treat(l_objects_to_run(1) as ut3_develop.ut_logical_suite); + ut.expect(l_test_suite.name).to_equal('wildcard_multi_asterisks'); + ut.expect(l_test_suite.items.count).to_equal(2); + + for i in 1 .. 2 loop + l_test1_suite := treat(l_test_suite.items(i) as ut3_develop.ut_logical_suite); + case l_test1_suite.name + when 'test1_multi_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(1); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_multi_test1'); + when 'test2_multi_wildcard' then + ut.expect(l_test1_suite.items.count).to_equal(1); + l_test1_proc := treat(l_test1_suite.items(1) as ut3_develop.ut_test); + ut.expect(l_test1_proc.name).to_equal('first_multi_test1'); + end case; + + end loop; + end; + end test_suite_manager; / diff --git a/test/ut3_tester/core/test_suite_manager.pks b/test/ut3_tester/core/test_suite_manager.pks index ccd4d586c..d9d4efc09 100644 --- a/test/ut3_tester/core/test_suite_manager.pks +++ b/test/ut3_tester/core/test_suite_manager.pks @@ -196,15 +196,45 @@ create or replace package test_suite_manager is --%context(wildcard_filters) - --%test(Execute test_packages using a object_name with wildcard ) + --%test(Execute test_packages using a object_name with wildcard at the end ) procedure test_wild_card_obj_name; - --%test(Execute test_packages using a procedure name with wildcard ) + --%test(Execute test_packages using a procedure name with wildcard at the end) procedure test_wild_card_prc_name; - --%test(Execute test_packages using a path name with wildcard ) + --%test(Execute test_packages using a path name with wildcard at the end) procedure test_wild_card_path_name; + --%test(Execute test_packages using a object_name with wildcard in the front) + procedure test_wild_card_front_obj_name; + + --%test(Execute test_packages using a procedure name with wildcard in the front) + procedure test_wild_card_front_prc_name; + + -- %test(Execute test_packages using a path name with wildcard in the front) + procedure test_wild_card_front_path_name; + + --%test(Execute test_packages using a object_name with wildcard in the middle) + procedure test_wild_card_mid_obj_name; + + --%test(Execute test_packages using a procedure name with wildcard in the middle) + procedure test_wild_card_mid_prc_name; + + -- %test(Execute test_packages using a path name with wildcard in the middle) + procedure test_wild_card_mid_path_name; + + --%test(Execute test_packages using a object_name with multiple wildcards) + procedure test_wild_card_mul_obj_name; + + --%test(Execute test_packages using a procedure name with multiple wildcards) + procedure test_wild_card_mul_prc_name; + + -- %test(Execute test_packages using a path name with multiple wildcards) + procedure test_wild_card_mul_path_name; + + -- %test(Execute test_packages using a path name with multiple wildcards on different level) + procedure tst_wild_card_mul_lv_path_name; + --%endcontext end test_suite_manager; From 51439d8eb4b81c1e1ab53c2430692c8db3c6eae7 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 16 Apr 2022 02:39:48 +0100 Subject: [PATCH 338/887] Update documentation --- docs/userguide/running-unit-tests.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c0efeba52..2288bf3f1 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -46,6 +46,7 @@ The **functions** can only be used in SELECT statements. They execute the specif The examples below illustrate different ways and options to invoke `ut.run` procedures. You can use a wildcard character `*` to call tests by part of their name or to call tests that are located on paths matched by part of path string. +Wildcard character can be placed anywhere on the path and can occur mutliple times. Schema name cannot contain a wildcard character whether is in a suitepath call or call by object name. ```sql @@ -86,6 +87,15 @@ end; Executes all tests in schema `hr` from all packages that are on suitepath starting with `com`. +```sql +set serveroutput on +begin + ut.run('hr:co*.my_*.my_*'); +end; +``` + +Executes all tests in schema `hr` from all packages that starting with `my_` and all tests starting with `my_*` that are on suitepath starting with `co` . + ```sql set serveroutput on begin From 0fc7ff6d4717e7208ce2fd73d831b55e2c4316f8 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 16 Apr 2022 16:22:09 +0100 Subject: [PATCH 339/887] Fixing issue where parition by only path caused a duplicate level 1 across two owners being removed. --- source/core/ut_suite_cache_manager.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index e525be7ea..6ed4f50f0 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -203,7 +203,7 @@ create or replace package body ut_suite_cache_manager is begin select obj bulk collect into l_suite_items from ( - select /*+ cardinality(c 500) */ value(c) as obj,row_number() over ( partition by path order by path asc) as r_num + select /*+ cardinality(c 500) */ value(c) as obj,row_number() over ( partition by path,object_owner order by path,object_owner asc) as r_num from ut_suite_cache c, table(a_schema_paths) sp where c.object_owner = upper(sp.schema_name) From 647b830df119f6931347bf5d37475e645c252896 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 17 Apr 2022 03:33:30 +0300 Subject: [PATCH 340/887] Fixed issue with suites getting duplicated when running tests across multiple schemas --- source/core/ut_suite_cache_manager.pkb | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 6ed4f50f0..d3e832a9b 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -287,11 +287,11 @@ create or replace package body ut_suite_cache_manager is with extract_parent_child as ( select s.path, substr(s.path,1,instr(s.path,'.',-1,1)-1) as parent_path,s.object_owner, - case when a_random_seed is null then s.line_no else null end line_no, - case when a_random_seed is null then null else ut_utils.hash_suite_path(s.path, a_random_seed) end random_seed + case when a_random_seed is null then s.line_no end line_no, + case when a_random_seed is not null then ut_utils.hash_suite_path(s.path, a_random_seed) end random_seed from table(a_suite_rows) s), t1(path,parent_path,object_owner,line_no,random_seed) as ( - --Anchor memeber + --Anchor member select s.path, parent_path,s.object_owner,s.line_no,random_seed from extract_parent_child s where parent_path is null @@ -299,7 +299,8 @@ create or replace package body ut_suite_cache_manager is --Recursive member select t2.path, t2.parent_path,t2.object_owner,t2.line_no,t2.random_seed from t1,extract_parent_child t2 - where t2.parent_path = t1.path) + where t2.parent_path = t1.path + and t2.object_owner = t1.object_owner) search depth first by line_no desc,random_seed desc nulls last set order1 select value(i) as obj bulk collect into l_suite_rows From 58f69979f8676aa1808b09ff09af30aa9f9e6f9d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 23 Apr 2022 10:47:40 +0100 Subject: [PATCH 341/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 4594b9864..d0998977b 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 746421e4a..77de81572 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 590fce081..446fface8 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 6400be9d1..cc759f3ff 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index e1a5cd7dd..e3cd96e35 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 085c06221..08301acfe 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 68a26ce8b..7e40371fc 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 645eda5f1..48da86cac 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0112c44d8..d3b0d3fee 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a84d80f11..19a6e2da7 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 9dabeb2fd..23bfa4105 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c29a40c7b..8fab1969a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 1c631d0d5..4c334ae8a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 0cfd513f3..460d024c6 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 8f4d0765a..3bd5662cf 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 2288bf3f1..6029aced1 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index a5fb8a669..e13a7e59d 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4003--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 995d83c10..21f6424d8 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4003-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4014-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From d88dd2d740919856853edd208ca11bb03133d515 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 26 May 2022 12:31:28 +0300 Subject: [PATCH 342/887] Updated slack link in feature request --- .github/ISSUE_TEMPLATE/feature_request.md | 2 +- docs/about/support.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index 4cd72f51c..681bc7f3a 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -23,4 +23,4 @@ Add any other context or screenshots about the feature request here. > Please do not create issues for generic SQL or PL/SQL questions. There are other forums and communities to help you with those. See [ASKTom](https://asktom.oracle.com) for example. **Want to discuss** -If you want to discuss your issue, join [our SLACK chat](https://join.slack.com/t/utplsql/shared_invite/zt-d6zor80g-WWqAhbLWioJZUtLYeXetzA). +If you want to discuss your issue, join [our SLACK chat](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww). diff --git a/docs/about/support.md b/docs/about/support.md index cc759f3ff..178412fdb 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -3,4 +3,4 @@ # How to get support - Feel free to post questions, bugs or issues in the [issues area of GitHub](https://github.com/utPLSQL/utPLSQL/issues) -- [Join](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) developers team on utPLSQL [Slack](https://utplsql.slack.com/) +- [Join](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) developers team on [utPLSQL Slack](https://utplsql.slack.com/) From fc5c4af28ad9416de894670a92cdc3fe9081f4f4 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 26 May 2022 10:50:51 +0100 Subject: [PATCH 343/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index d0998977b..1de762d74 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 77de81572..5030fff0a 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 446fface8..71178988b 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 178412fdb..1c0679440 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index e3cd96e35..b79c845f5 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 08301acfe..2faf98dec 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 7e40371fc..933b1b119 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 48da86cac..85a4351ce 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index d3b0d3fee..b66b5dff7 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 19a6e2da7..6a8b3d4e3 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 23bfa4105..20f641e45 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8fab1969a..cd2f41af6 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 4c334ae8a..fbe3b44a1 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 460d024c6..136770405 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3bd5662cf..14d411aa6 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 6029aced1..d833b6c94 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e13a7e59d..14e35a5b5 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4014--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 21f6424d8..6ef2c4a9a 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4014-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4015-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 4f944a6d223e9a5d037e42e97dad8c5e92e88b40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 28 Jul 2022 12:52:39 +0100 Subject: [PATCH 344/887] Fix uninstall scripts Fixing problem with uninstall script buffer overflow on DBMS_OUTPUT. Reolves: #1220 --- source/uninstall_objects.sql | 1 - 1 file changed, 1 deletion(-) diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index ab4069497..571d187a2 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -1,5 +1,4 @@ set echo off -set serverout on declare procedure drop_if_exists(a_object_type varchar2, a_object_name varchar2) is l_count integer; From aa9d2737be7c789c6d779a481edc6175d81677d2 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 8 Aug 2022 13:24:24 +0100 Subject: [PATCH 345/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 1de762d74..50660b2f2 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 5030fff0a..87d1283e6 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 71178988b..f05c9c428 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 1c0679440..fd4009308 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b79c845f5..90deef32c 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 2faf98dec..74fbdd89f 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 933b1b119..4bd01a6d3 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 85a4351ce..efbdae53c 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index b66b5dff7..f623877f7 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 6a8b3d4e3..644cad22e 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 20f641e45..fc8355f64 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index cd2f41af6..2a61ee10b 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index fbe3b44a1..eca9fd6d6 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 136770405..9e21d3635 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 14d411aa6..68b7694cd 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index d833b6c94..0f1e182ad 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 14e35a5b5..707ff8f4e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4015--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6ef2c4a9a..f7493229f 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4015-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4018-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 4e82973abad2e1b6dc8d91088f71a5a15d08f29d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Kukie=C5=82a?= <53443372+kukimik@users.noreply.github.com> Date: Mon, 8 Aug 2022 14:55:49 +0200 Subject: [PATCH 346/887] Fix dropped synonyms counter. --- source/uninstall_synonyms.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/uninstall_synonyms.sql b/source/uninstall_synonyms.sql index 569e5057d..2c96c03a4 100644 --- a/source/uninstall_synonyms.sql +++ b/source/uninstall_synonyms.sql @@ -15,10 +15,10 @@ begin and not exists (select 1 from all_objects o where o.owner = s.table_owner and o.object_name = s.table_name) ) loop - i := i + 1; begin execute immediate 'drop '||syn.syn_name; dbms_output.put_line('Dropped '||syn.syn_name||' for object '||syn.for_object); + i := i + 1; exception when others then dbms_output.put_line('FAILED to drop '||syn.syn_name||' for object '||syn.for_object); From 1bd302881bcadeefc4501f69c1aca9caafbf73fc Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 15 Aug 2022 11:41:39 +0100 Subject: [PATCH 347/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 50660b2f2..a465b7968 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 87d1283e6..208f59141 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index f05c9c428..a538b25f3 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index fd4009308..6416b668a 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 90deef32c..7c71123d4 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 74fbdd89f..ac712002c 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 4bd01a6d3..8dd117676 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index efbdae53c..acfc0559f 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index f623877f7..303a1a6d7 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 644cad22e..5a8cf3361 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index fc8355f64..65b9af484 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 2a61ee10b..c4dccfb51 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index eca9fd6d6..56f4d573b 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 9e21d3635..f3f4f3c1c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 68b7694cd..3b4802357 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 0f1e182ad..5946f70b0 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 707ff8f4e..3d5b9d7ce 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4018--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f7493229f..bc5d28826 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4018-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4021-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 53dc4d8526fa0a562fd11172315412da18168906 Mon Sep 17 00:00:00 2001 From: kukimik Date: Sun, 14 Aug 2022 22:52:34 +0200 Subject: [PATCH 348/887] Add a section on custom reporters. --- docs/userguide/reporters.md | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 68b7694cd..8431582a4 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -161,5 +161,20 @@ Some of the information in debug log might be redundant. > - db object names > - etc. - - \ No newline at end of file +# Custom reporters + +It is possible to add your own reporters by creating an appropriate object type. In principle, it has to be a subtype of `ut_reporter_base`. However, if the reporter is expected to produce output consumable by a client oustside of the database (e.g. the data has to be reported to the screen or to a file), then you should base it on `ut_output_reporter_base` (which is a subtype of `ut_reporter_base`). In contrast, if you would like to create a reporter that, for example, saves the data to a database table, then it should be based directly on `ut_reporter_base`. (Currently, all reporters in the utPLSQL framework are based on `ut_output_reporter_base`.) Coverage reporters are based on `ut_coverage_reporter_base` (a subtype of `ut_output_reporter_base`). + +If need to produce a colored text output from the custom reporter, then you can build it basing on `ut_console_reporter_base` (a subtype of `ut_output_reporter_base`). In many cases it may also be more convenient to create the custom reporter type under a more specialized type, like `ut_documentation_reporter` or `ut_junit_reporter`, and override just some of the functionality. + +It is recommended to create the reporter type in the schema where utPLSQL is installed (by default it is the `UT3` schema). Note that before running the utPLSQL uninstall scripts, all custom reporters should be dropped (cf. [the installation documentation](install.md)). In particular, when upgrading to a newer version of utPLSQL, one has to drop the custom reporters and recreate them after the upgrade. + +**Note:** +> It is possible, but cumbersome, to use another schema for storing the custom reporters. This requires to create a synonym for the base reporter type in the schema that is going to own the custom reporter, and to provide appropriate grants both to the owner of the custom reporter and to the user running the reporter. After upgrading or reinstalling utPLSQL, the extra privileges need to be recreated. This approach is not recommended. + +Assuming that the custom reporter type is created in the `UT3` schema, to run the tests using a custom reporter just call: `exec ut.run(ut3.custom_reporter_name());`, optionally providing parameter values to the `custom_reporter_name` constructor. + +One may get acquainted with the source code of the standard reporters bundled with utPLSQL (including the coverage reporters) by browsing the [`source/reporters/`](https://github.com/utPLSQL/utPLSQL/tree/develop/source/reporters) directory. The base reporter types `ut_reporter_base`, `ut_output_reporter_base` and `ut_console_reporter_base` are defined in [`source/core/types`](https://github.com/utPLSQL/utPLSQL/tree/develop/source/core/types). The base coverage reporter type `ut_coverage_reporter_base` is in [`source/core/coverage`](https://github.com/utPLSQL/utPLSQL/tree/develop/source/core/coverage). There are also two examples of custom reporters in [`examples/custom_reporters/`](https://github.com/utPLSQL/utPLSQL/tree/develop/examples/custom_reporters), both extending the functionality of `ut_documentation_reporter`: + +* `ut_custom_reporter` accepts an integer parameter `a_tab_size`; it alters the behaviour of `ut_documentation_reporter` by changing the size of the indentation according to the parameter value (by default the indentation is increased). +* `ut_expectations_reporter` accepts a `varchar2` parameter `a_report_all_expectations`; if its value is `'Y'` (which is the default), then the reporter shows the results of all expectations that are run. This stays in contrast with `ut_documentation_reporter`, which shows the results of all tests that are run, but only of the expectations that failed (keep in mind that a single test may consist of several expectations). From 3b003561e5f0a3eba46a4e4983e4970d9cc064aa Mon Sep 17 00:00:00 2001 From: Neil Barsema Date: Wed, 31 Aug 2022 11:21:34 +0200 Subject: [PATCH 349/887] Add explicit grants for public packages The privileges on the referenced packages are often revoked from PUBLIC as database hardening. Not relying on these grants being available makes the install script more robust. --- source/create_utplsql_owner.sql | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/source/create_utplsql_owner.sql b/source/create_utplsql_owner.sql index 1af2cf168..64bcb52ce 100644 --- a/source/create_utplsql_owner.sql +++ b/source/create_utplsql_owner.sql @@ -41,6 +41,11 @@ end; / grant execute on dbms_crypto to &ut3_owner_schema; +grant execute on dbms_lob to &ut3_owner_schema; +grant execute on dbms_xmlgen to &ut3_owner_schema; +grant execute on dbms_sql to &ut3_owner_schema; +grant execute on dbms_random to &ut3_owner_schema; + grant alter session to &ut3_owner_schema; From 4cdc7d424a8851b25b8c48bf15c22d6177c783d6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 9 Sep 2022 13:24:54 +0100 Subject: [PATCH 350/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index a465b7968..d5edb4d77 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 208f59141..ec84e3b88 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index a538b25f3..d1734ae77 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 6416b668a..53b96d4b1 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 7c71123d4..0985a7c28 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index ac712002c..93e5fba8a 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8dd117676..00f0303e7 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index acfc0559f..04d24629b 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 303a1a6d7..fca2bcbc7 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 5a8cf3361..7ddbde478 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 65b9af484..9121fa721 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c4dccfb51..4294ebd2a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 56f4d573b..37dc6c163 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index f3f4f3c1c..ccb5fea24 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 0d3626a04..cc23ca67f 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 5946f70b0..22d1ce405 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 3d5b9d7ce..bde427999 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4021--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index bc5d28826..029bc17f3 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4021-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4036-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From b77ae3c119d58e4a0042eb7ac74f56d4fb3702c5 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 19 Sep 2022 13:49:16 +0300 Subject: [PATCH 351/887] Fixing utPLSQL-cli download script documentation --- docs/userguide/running-unit-tests.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 22d1ce405..ca8ab0b4a 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -24,7 +24,7 @@ You may download the latest release of the command line client from [here](https ```bash #!/bin/bash # Get the url to latest release "zip" file -DOWNLOAD_URL=$(curl --silent https://api.github.com/repos/utPLSQL/utPLSQL-cli/releases/latest | awk '/zipball_url/ { print $2 }' | sed -r 's/"|,//g') +DOWNLOAD_URL=$(curl --silent https://api.github.com/repos/utPLSQL/utPLSQL-cli/releases/latest | awk '/browser_download_url/ { print $2 }' | grep ".zip\"" | sed 's/"//g') # Download the latest release "zip" file curl -Lk "${DOWNLOAD_URL}" -o utplsql-cli.zip # Extract downloaded "zip" file From 051c5257dd04c39561a23e7f403b778d43df094f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 19 Sep 2022 11:57:50 +0100 Subject: [PATCH 352/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index d5edb4d77..25d6fbf77 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index ec84e3b88..b860bf718 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index d1734ae77..5dad05ae0 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 53b96d4b1..2be6c96ac 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 0985a7c28..c770d7fe5 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Introduction to utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 93e5fba8a..41511efed 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 00f0303e7..0f74c4692 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Annotations diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 04d24629b..422a294f0 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Best Practices diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index fca2bcbc7..430d2473e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 7ddbde478..498ce88ef 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Exception handling and reporting diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 9121fa721..5762793b9 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Expectation concepts Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 4294ebd2a..3e5564e44 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 37dc6c163..2ba60144c 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index ccb5fea24..15f9952be 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Qyerying for test suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index cc23ca67f..b82ec7d32 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index ca8ab0b4a..7fa8263ad 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Running tests diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index bde427999..68256fa4f 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 029bc17f3..d25c365da 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4036-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4037-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From eb14593ac07e3f7a82f5bfdb4c2b8fb4a3ab3fdd Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 11 Oct 2022 22:32:46 +0300 Subject: [PATCH 353/887] Introducing MkDocs documentation --- mkdocs.yml | 74 +++++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 68 insertions(+), 6 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index f9a2687a8..e675c93f4 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -1,17 +1,79 @@ # Format documented here # http://www.mkdocs.org/user-guide/configuration/ -site_name: utPLSQL +site_url: http://utPLSQL.org/ +site_name: utPLSQL-framework site_description: utPLSQL Ultimate Unit Testing Framework for Oracle PL/SQL -copyright: Copyright © 2016 - 2018 utPLSQL Team -repo_url: https://github.com/utPLSQL/utPLSQL -theme: mkdocs +copyright: Copyright © 2016 - 2022 utPLSQL Team +#repo_url: https://github.com/utPLSQL/utPLSQL # disable for offline docs +theme: + name: material + palette: + # Palette toggle for light mode + - media: "(prefers-color-scheme: light)" + scheme: default + toggle: + icon: material/lightbulb-outline + name: Switch to dark mode + # Palette toggle for dark mode + - media: "(prefers-color-scheme: dark)" + scheme: slate + toggle: + icon: material/lightbulb + name: Switch to light mode + logo: assets/icon-transparent.png + favicon: assets/favicon.png + features: + - navigation.instant # disable for offline docs +# - navigation.indexes + - navigation.tabs + - navigation.tracking + - toc.follow + - toc.integrate + - search.suggest + - search.highlight +extra: +# homepage: http://jgebal.github.io/ +# homepage: http://utPLSQL.org/ + social: + - icon: fontawesome/brands/twitter + link: https://twitter.com/utPLSQL + - icon: fontawesome/brands/slack + link: https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww + - icon: fontawesome/brands/github + link: https://github.com/utPLSQL + - icon: fontawesome/solid/envelope + link: mailto:utPLSQL@utPLSQL.org + consent: + title: Cookie consent + description: >- + We use cookies to recognize your repeated visits and preferences, as well + as to measure the effectiveness of our documentation and whether users + find what they're searching for. With your consent, you're helping us to + make our documentation better. + version: # disable for offline docs + provider: mike # disable for offline docs +markdown_extensions: + - pymdownx.highlight: + anchor_linenums: true + - pymdownx.inlinehilite + - pymdownx.snippets + - pymdownx.superfences + - toc: + permalink: true use_directory_urls: false strict: true +plugins: + - search + - mike + - git-revision-date-localized: # disable for offline docs + enable_creation_date: true # disable for offline docs + type: datetime # disable for offline docs + nav: - - Home: index.md - User Guide: + - index.md - Installation: userguide/install.md - Getting Started: userguide/getting-started.md - Annotations: userguide/annotations.md @@ -23,8 +85,8 @@ nav: - Upgrade utPLSQL: userguide/upgrade.md - Reporting: - Using reporters: userguide/reporters.md - - Reporting errors: userguide/exception-reporting.md - Code coverage: userguide/coverage.md + - Error handling and reporting: userguide/exception-reporting.md - About: - Project Details: about/project-details.md - License: about/license.md From c5ce09bffbf02b7fd41681b0f43f6c97f0d65f4f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 11 Oct 2022 22:50:22 +0300 Subject: [PATCH 354/887] Adjusting documentation to work well with new MkDocs --- docs/index.md | 34 ++++--------------- docs/userguide/annotations.md | 4 +-- docs/userguide/best-practices.md | 2 -- docs/userguide/coverage.md | 7 +++- docs/userguide/exception-reporting.md | 3 +- docs/userguide/expectations.md | 17 ++++++---- docs/userguide/getting-started.md | 28 ++++++++-------- docs/userguide/install.md | 47 ++++++++++++++------------- docs/userguide/querying_suites.md | 3 -- docs/userguide/reporters.md | 20 ++++++------ docs/userguide/running-unit-tests.md | 24 +++++++------- 11 files changed, 83 insertions(+), 106 deletions(-) diff --git a/docs/index.md b/docs/index.md index 0985a7c28..f9b648b43 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,39 +1,17 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) -# Introduction to utPLSQL +## What is utPLSQL utPLSQL is a Unit Testing framework for Oracle PL/SQL. The framework follows industry standards and best patterns of modern Unit Testing frameworks like [JUnit](http://junit.org/junit4/) and [RSpec](http://rspec.info/) - - - User Guide - - [Installation](userguide/install.md) - - [Getting Started](userguide/getting-started.md) - - [Annotations](userguide/annotations.md) - - [Expectations](userguide/expectations.md) - - [Advanced data comparison](userguide/advanced_data_comparison.md) - - [Running unit tests](userguide/running-unit-tests.md) - - [Querying for test suites](userguide/querying_suites.md) - - [Testing best practices](userguide/best-practices.md) - - [Upgrade utPLSQL](userguide/upgrade.md) - - Reporting - - [Using reporters](userguide/reporters.md) - - [Reporting errors](userguide/exception-reporting.md) - - [Code coverage](userguide/coverage.md) - - [Cheat-sheet](https://www.cheatography.com/jgebal/cheat-sheets/utplsql-v3-1-2/#downloads) - - About - - [Project Details](about/project-details.md) - - [License](about/license.md) - - [Support](about/support.md) - - [Authors](about/authors.md) - - [Version 2 to Version 3 Comparison](compare_version2_to_3.md) - -# Demo project + +## Demo project Have a look at our [demo project](https://github.com/utPLSQL/utPLSQL-demo-project/). It uses [Travis CI](https://travis-ci.org/utPLSQL/utPLSQL-demo-project) to build on every commit, runs all tests, publishes test results and code coverage to [SonarCloud](https://sonarcloud.io/project/overview?id=utPLSQL:utPLSQL-demo-project). -# Three steps +## Three steps With just three simple steps you can define and run your unit tests for PLSQL code. @@ -48,7 +26,7 @@ Here is how you can simply create tested code, unit tests and execute the tests Check out the sections on [annotations](userguide/annotations.md) and [expectations](userguide/expectations.md) to see how to define your tests. -# Command line +## Command line You can use the utPLSQL command line client [utPLSQL-cli](https://github.com/utPLSQL/utPLSQL-cli) to run tests without the need for Oracle Client or any IDE like SQLDeveloper/TOAD etc. @@ -60,7 +38,7 @@ Amongst many benefits they provide ability to: Download the [latest client](https://github.com/utPLSQL/utPLSQL-cli/releases/latest) and you are good to go. See [project readme](https://github.com/utPLSQL/utPLSQL-cli/blob/develop/README.md) for details. -# Coverage +## Coverage If you want to have code coverage gathered on your code , it's best to use `ut_run` to execute your tests with multiple reporters and have both test execution report as well as coverage report saved to a file. diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 00f0303e7..0a9a2d15d 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,7 +1,5 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) -# Annotations - Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. The framework runner searches for all the suitable annotated packages, automatically configures suites, forms the suite hierarchy, executes it and reports results in specified formats. @@ -38,7 +36,7 @@ There **can not** be any empty lines or comments between annotation line and pro There can be many annotations for a procedure. Valid procedure annotations example: -```sql +```sql linenums="1" package test_package is --%suite diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 04d24629b..a1924b8de 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,7 +1,5 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) -# Best Practices - The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. ## Test Isolation and Dependency diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index fca2bcbc7..7d77cb7ed 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,8 +1,8 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) -# Coverage utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: + * package bodies * type bodies * triggers @@ -15,6 +15,7 @@ Code coverage is gathered for the following source types: To obtain information about code coverage for unit tests, run utPLSQL with one of built-in code coverage reporters. The following code coverage reporters are supplied with utPLSQL: + * `ut_coverage_html_reporter` - generates a HTML coverage report providing summary and detailed information on code coverage. The HTML reporter is based on the open-source [simplecov-html](https://github.com/colszowka/simplecov-html) reporter for Ruby. It includes source code of the code that was covered (if the code is accessible for test user) * `ut_coveralls_reporter` - generates a [Coveralls compatible JSON](https://coveralls.zendesk.com/hc/en-us/articles/201774865-API-Introduction) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by cloud services like [Coveralls](https://coveralls.io) * `ut_coverage_sonar_reporter` - generates a [Sonar Compatible XML](https://docs.sonarqube.org/latest/analysis/generic-test/) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by services like [SonarQube](https://www.sonarqube.org/) and [SonarCloud](https://about.sonarcloud.io/) @@ -23,6 +24,7 @@ The following code coverage reporters are supplied with utPLSQL: ## Security model utPLSQL code coverage uses DBMS_PROFILER to gather information about the execution of code under test and therefore follows the [DBMS_PROFILER's Security Model](https://docs.oracle.com/database/121/ARPLS/d_profil.htm#ARPLS67465). In order to be able to gather coverage information, the user executing unit tests needs to be either: + * The owner of the code that is being tested * Have the following privileges to be able to gather coverage on code owned by other users: * `create any procedure` system privilege @@ -144,6 +146,7 @@ You may specify both _include_ and _exclude_ options to gain more control over w **Important notes** The order of priority is for evaluation of include/exclude filter parameters is as follows. + - if `a_source_file_mappings` is defined then all include/exclude parameters are ignored (see section below for usage of `a_source_file_mappings` parameter ) - else if `a_include_schema_expr` or `a_include_object_expr` parameter is specified then parameters `a_coverage_schemes` and `a_include_objects` are ignored - else if `a_include_objects` is specified then the coverage is gathered only on specified database objects. @@ -300,6 +303,7 @@ They are abstracted from database, schema names, packages, procedures and functi To be able to effectively use reporters dedicated for those tools, utPLSQL provides functionality for mapping database object names to project files. There are a few significant differences when running coverage on project files compared to running coverage on schema(s). + - Coverage is only reported on objects that were successfully mapped to project files. - Project files (database objects) that were not executed at all are not reported as fully uncovered. It is up to the consumer (Sonar/Coveralls) to determine if project file should be considered as 0% coverage or just ignored. @@ -335,6 +339,7 @@ C: ``` By default, utPLSQL will convert file paths into database objects using the following regular expression `/(((\w|[$#])+)\.)?((\w|[$#])+)\.(\w{3})$` + - object owner (if it is present) is identified by the expression in the second set of brackets - object name is identified by the expression in the fourth set of brackets - object type is identified by the expression in the sixth set of brackets diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 7ddbde478..b4cb033e7 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,12 +1,11 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) -# Exception handling and reporting - The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. To achieve rerunability, the package state invalidation exceptions (ORA-04068, ORA-04061) are not handled and test execution will be interrupted if such exceptions are encountered. This is because of how Oracle behaves on those exceptions. Test execution can fail for different reasons. The failures on different exceptions are handled as follows: + * A test package without body - each `--%test` is reported as failed with exception, nothing is executed * A test package with _invalid body_ - each `--%test` is reported as failed with exception, nothing is executed * A test package with _invalid spec_ - package is not considered a valid unit test package and is excluded from execution. When trying to run a test package with invalid spec explicitly, exception is raised. Only valid specifications are parsed for annotations diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 9121fa721..5856b77a1 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,6 +1,7 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) -# Expectation concepts +## Expectation concepts + Validation of the code under test (the tested logic of procedure/function etc.) is performed by comparing the actual data against the expected data. utPLSQL uses expectations and matchers to perform the check on the data. @@ -82,12 +83,14 @@ SUCCESS **Note:** > The examples in the document will be only using shortcut syntax, to keep the document brief. -# Using expectations +## Using expectations + There are two ways to use expectations: - by invoking utPLSQL framework to execute suite(s) of utPLSQL tests - without invoking the utPLSQL framework - running expectations standalone ## Running expectations within utPLSQL framework + When expectations are ran as a part of a test suite, the framework tracks: - status of each expectation - outcomes (messages) produced by each expectation @@ -166,7 +169,7 @@ When expectations are invoked outside of utPLSQL framework the outputs from expe **Note:** > The examples in the document will be only using standalone expectations, to keep the document brief. -# Matchers +## Matchers utPLSQL provides the following matchers to perform checks on the expected and actual values. - `be_between( a_upper_bound {data-type}, a_lower_bound {data-type} )` @@ -312,7 +315,7 @@ FAILURE ``` Since NULL is neither *true* nor *false*, both expectations will report failure. -# Supported data types +## Supported data types The matrix below illustrates the data types supported by different matchers. @@ -336,7 +339,7 @@ The matrix below illustrates the data types supported by different matchers. | **be_within().of_()** | | | | X | X | X | X | X | | | | | | | | | **be_within_pct().of_()** | | | | | X | | | | | | | | | | | -# Expecting exceptions +## Expecting exceptions Testing is not limited to checking for happy-path scenarios. When writing tests, you often want to validate that in specific scenarios, an exception is thrown. @@ -385,7 +388,7 @@ Finished in .009229 seconds For more details see documentation of the [`--%throws` annotation.](annotations.md#throws-annotation) -# Matchers +## Matchers You can choose different matchers to validate that your PL/SQL code is working as expected. @@ -1747,7 +1750,7 @@ FAILURE at "anonymous block", line 32 ``` -# Comparing Json objects +## Comparing Json objects utPLSQL is capable of comparing json data-types of `json_element_t` **on Oracle 12.2 and above**, and also `json` **on Oracle 21 and above** diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 4294ebd2a..42b6b3641 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -7,7 +7,7 @@ utPLSQL is designed in a way that allows you to follow Below is an example of building a simple function with TDD. -# Gather requirements +## Gather requirements We have a requirement to build a function that will return a substring of a string that is passed to the function. @@ -17,12 +17,12 @@ The function should accept three parameters: - start_position - end_position -# Create a test +## Create a test We will start from the bare minimum and move step by step, executing tests every time we make minimal progress. This way, we assure we don't jump ahead too much and produce code that is untested or untestable. -## Create test package +### Create test package ```sql create or replace package test_betwnstr as @@ -43,7 +43,7 @@ Finished in .451423 seconds 0 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s) ``` -## Define specification for the test +### Define specification for the test ```sql create or replace package test_betwnstr as @@ -76,7 +76,7 @@ Finished in .509673 seconds Well our test is failing as the package specification requires a body. -## Define body of first test +### Define body of first test ```sql create or replace package body test_betwnstr as @@ -110,9 +110,9 @@ Finished in .415851 seconds Our test is failing as the test suite package body is invalid. Looks like we need to define the function we want to test. -# Implement code to fulfill the requirement +## Implement code to fulfill the requirement -## Define tested function +### Define tested function ```sql create or replace function betwnstr( a_string varchar2, a_start_pos integer, a_end_pos integer ) return varchar2 @@ -143,7 +143,7 @@ Finished in .375178 seconds So now we see that our test works but the function does not return the expected results. Let us fix this and continue from here. -## Fix the tested function +### Fix the tested function The function returned a string one character short, so we need to add 1 to the substr parameter. @@ -169,14 +169,14 @@ Finished in .006077 seconds So our test is now passing, great! -# Refactor +## Refactor Once our tests are passing, we can safely refactor (restructure) the code as we have a safety harness in place to ensure that after the restructuring and cleanup of the code, everything is still working. One thing worth mentioning is that refactoring of tests is as important as refactoring of code. Maintainability of both is equally important. -# Further requirements +## Further requirements It seems like our work is done. We have a function that returns a substring from start position to end position. As we move through the process of adding tests, it's very important to think about edge cases. @@ -195,7 +195,7 @@ Here is a list of edge cases for our function: We should define expected behavior for each of these edge cases. Once defined we can start implementing tests for those behaviors and adjust the tested function to meet the requirements specified in the tests. -## Add test for additional requirement +### Add test for additional requirement A new requirement was added: Start position zero - should be treated as start position one @@ -250,7 +250,7 @@ Finished in .232584 seconds Looks like our function does not work as expected for zero start position. -## Implementing the requirement +### Implementing the requirement Let's fix our function so that the new requirement is met @@ -281,7 +281,7 @@ Finished in .012718 seconds Great! We have made some visible progress. -## Refactoring +### Refactoring When all tests are passing we can proceed with a safe cleanup of our code. @@ -308,7 +308,7 @@ Finished in .013739 seconds 2 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s) ``` -# Remaining requirements +## Remaining requirements You may continue on with the remaining edge cases from here. diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 37dc6c163..dce1a2e2e 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,8 +1,9 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) -# Supported database versions +## Supported database versions utPLSQL is continuously tested against following versions of Oracle databases + * 11g R2 * 12c * 12c R2 @@ -11,17 +12,17 @@ utPLSQL is continuously tested against following versions of Oracle databases We do our best to assure full compatibility with supported versions of Oracle databases [See](http://www.oracle.com/us/support/library/lifetime-support-technology-069183.pdf#page=6) -# Requirements +## Requirements utPLSQL will run on any Oracle Database version 11g relase 2 or above. -## Licensed features required +### Licensed features required utPLSQL doesn't require any extra licensed features of Oracle database. It can be installed on any Standard Edition Oracle Database. In fact, it even supports Oracle 11g XE which is a free Oracle Database version with minimal features and storage limits. -## Storage requirements +### Storage requirements utPLSQL will use tablespace for the following: - storage of annotation cache @@ -38,9 +39,9 @@ Profiler results may require regular purging to assure low space consumption. utPLSQl does not purge profiler tables as those tables can can be shared with other tools. -# Downloading utPLSQL +## Downloading utPLSQL -## Manual download +### Manual download - Go to GitHub releases page for utPLSQL [`https://github.com/utPLSQL/utPLSQL/releases`](https://github.com/utPLSQL/utPLSQL/releases) - Choose the version to download - latest is always greatest @@ -51,13 +52,13 @@ utPLSQl does not purge profiler tables as those tables can can be shared with ot The files have identical content but use different compression (tar / zip ) so choose whichever you prefer depending on your platform (Win/Mac/Unix/Linux). -## Scripted download of latest utPLSQL version +### Scripted download of latest utPLSQL version The below snippets can be used to download latest version of utPLSQL from github releases. After downloading follow the installation instructions in next sections of this document. -### Unix/Linux +#### Unix/Linux ```bash #!/bin/bash @@ -75,7 +76,7 @@ You may download with a one-liner if that is more convenient. curl -LOk $(curl --silent https://api.github.com/repos/utPLSQL/utPLSQL/releases/latest | awk '/browser_download_url/ { print $2 }' | grep ".zip\"" | sed 's/"//g') ``` -### Windows +#### Windows To run the script on windows you will need [PowerShell 3.0](https://blogs.technet.microsoft.com/heyscriptingguy/2013/06/02/weekend-scripter-install-powershell-3-0-on-windows-7/) or above. You will also need .NET 4.0 Framework or above. @@ -104,7 +105,7 @@ foreach ($i in $urlList) { } ``` -# Headless installation +## Headless installation utPLSQL can be installed with DDL trigger, to enable tracking of DDL changes to your unit test packages. This is the recommended installation approach, when you want to compile and run unit test packages in a schema containing huge amount of database packages (for example Oracle EBS installation schema). @@ -136,7 +137,7 @@ For Oracle 11g following users are excluded: > select username from all_users where oracle_maintained='Y'; >``` -## Installation without DDL trigger +### Installation without DDL trigger To install the utPLSQL into a new database schema and grant it to public, execute the script `install_headless.sql` as SYSDBA. @@ -152,7 +153,7 @@ cd source sqlplus sys/sys_pass@db as sysdba @install_headless.sql utp3 my_verySecret_password utp3_tablespace ``` -## Installation with DDL trigger +### Installation with DDL trigger To install the utPLSQL into a new database schema and grant it to public, execute the script `install_headless_with_trigger.sql` as SYSDBA. @@ -168,7 +169,7 @@ cd source sqlplus sys/sys_pass@db as sysdba @install_headless_with_trigger.sql utp3 my_verySecret_password utp3_tablespace ``` -# Recommended Schema +## Recommended Schema It is highly recommended to install utPLSQL in it's own schema. You are free to choose any name for this schema. Installing uPLSQL into a shared schema is really not recommended as you loose isolation of framework. @@ -190,9 +191,9 @@ utPLSQL is using [DBMS_PROFILER tables](https://docs.oracle.com/cd/E18283_01/app It is up to DBA to maintain the storage of the profiler tables. -# Manual installation procedure +## Manual installation procedure -## Creating schema for utPLSQL +### Creating schema for utPLSQL To create the utPLSQL schema and grant all the required privileges execute script `create_utplsql_owner.sql` from the `source` directory with parameters: - `user name` - the name of the user that will own of utPLSQL object @@ -205,7 +206,7 @@ cd source sqlplus sys/sys_password@database as sysdba @create_utPLSQL_owner.sql ut3 ut3 users ``` -## Installing utPLSQL +### Installing utPLSQL To install the utPLSQL framework into your database, go to `source` directory, run the `install.sql` providing the `schema_name` for utPLSQL as parameter. Schema must be created prior to calling the `install` script. You may install utPLSQL from any account that has sufficient privileges to create objects in other users schema. @@ -216,7 +217,7 @@ cd source sqlplus admin/admins_password@database @install.sql ut3 ``` -## Installing DDL trigger +### Installing DDL trigger To minimize startup time of utPLSQL framework (especially on a database with large schema) it is recommended to install utPLSQL DDL trigger to enable utPLSQL annotation to be updated at compile-time. It's recommended to install DDL trigger when connected as `SYSDBA` user. Trigger is created in utPLSQL schema. @@ -235,7 +236,7 @@ sqlplus admin/admins_password@database @install_ddl_trigger.sql ut3 >Trigger can be installed ant any point in time. -## Allowing other users to access the utPLSQL framework +### Allowing other users to access the utPLSQL framework In order to allow other users to access utPLSQL, synonyms must be created and privileges granted. You have two options: @@ -264,7 +265,7 @@ The following tools that support the SQL*Plus commands can be used to run the in - [SQLcl](http://www.oracle.com/technetwork/developer-tools/sqlcl/overview/index.html) - [Oracle SQL Developer](http://www.oracle.com/technetwork/developer-tools/sql-developer/overview/index.html) -# Checking environment and utPLSQL version +## Checking environment and utPLSQL version To check the framework version execute the following query: ```sql @@ -278,7 +279,7 @@ select from dual; ``` -# Additional requirements +## Additional requirements In order to use the Code Coverage functionality of utPLSQL, users executing the tests must have the CREATE privilege on the PLSQL code that the coverage is gathered on. This is a requirement of [DBMS_PROFILER package](https://docs.oracle.com/cd/E18283_01/appdev.112/e16760/d_profil.htm#i999476). @@ -286,7 +287,7 @@ This is a requirement of [DBMS_PROFILER package](https://docs.oracle.com/cd/E182 In practice, user running tests for PLSQL code that he does not own, needs to have CREATE ANY PROCEDURE/CREATE ANY TRIGGER privileges. Running code coverage on objects that the user does not own will **not produce any coverage information** without those privileges. -# Uninstalling utPLSQL +## Uninstalling utPLSQL To uninstall run `uninstall.sql` and provide `schema_name` where utPLSQL is installed. @@ -308,11 +309,11 @@ i.e. the uninstall script provided with version 3.1.11 will not work correctly Alternatively you can drop the user that owns utPLSQL and re-create it using headless install. -# Version upgrade +## Version upgrade Currently, the only way to upgrade version of utPLSQL v3.0.0 and above is to remove the previous version and install the new version. -# Working with utPLSQL v2 +## Working with utPLSQL v2 If you are using utPLSQL v2, you can still install utPLSQL v3. The only requirement is that utPLSQL v3 needs to be installed in a different schema than utPLSQL v2. diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index ccb5fea24..317b9c766 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,8 +1,5 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) -# Qyerying for test suites - - ## Obtaining information about suites utPLSQL framework provides ability to read inforamtion about unit test suites that exist in a schema. diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index cc23ca67f..08d7252d1 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -2,7 +2,7 @@ utPLSQL provides the following reporting formats. -# Documentation reporter +## Documentation reporter The `ut_documentation_reporter` is the default reporting format used by the framework. It provides a human readable test results. @@ -26,7 +26,7 @@ The documentation report provides the following information. - Summary with total number of tests, number of tests with status and timing for the execution -## Color output from documentation reporter +### Color output from documentation reporter When invoking tests with documentation reporter and your command line supports ANSICONSOLE (default on Unix) [available for Windows](http://adoxa.altervista.org/ansicon/), you can obtain the coloured outputs from the documentation reporter. @@ -41,7 +41,7 @@ Example outputs from documentation reporter. ![doc_reporter_outputs](../images/documentation_reporter_color.png) -# JUnit reporter +## JUnit reporter Most of continuous integration servers (like Jenkins) are capable of consuming unit test execution results in [JUnit](https://en.wikipedia.org/wiki/JUnit) format. The `ut_junit_reporter` in earlier version referred as `ut_xunit_reporter` is producing outcomes as JUnit-compatible XML unit test report, that can be used by CI servers to display their custom reports and provide metrics (like tests execution trends). @@ -63,7 +63,7 @@ Example of failure report details -# Teamcity reporter +## Teamcity reporter [Teamcity](https://www.jetbrains.com/teamcity/) is a CI server by Jetbrains. It supports JUnit reporting and additionally has it's own format of reporting that allows tracking of progress of a CI step/task as it executes. The TeamCity format developed by Jetbrains is supported by utPLSQL with `ut_teamcity_reporter`. @@ -83,7 +83,7 @@ Example of failure report details ![junit_reporter_outputs_errors](../images/teamcity_report_example_errors.png) -# Sonar test reporter +## Sonar test reporter If you are using [SonarQube](https://www.sonarqube.org/) or [SonarCloud](https://about.sonarcloud.io/) to do static code analysis for you PLSQL projects, your code analysis can benefit from code coverage and test results. utPLSQL provides two reporters to for SonarQube: - `ut_sonar_test_reporter` - provides an XML output of each test executed per each project test file (package) @@ -99,7 +99,7 @@ Providing invalid paths or paths to non-existing files will result in failure wh For details on how to invoke reporter with paths, see the **Coverage reporters** section. -# TFS / VSTS Reporter +## TFS / VSTS Reporter If you are using [TFS](https://www.visualstudio.com/tfs/) or [VSTS](https://www.visualstudio.com/team-services/) to do static code analysis for you PLSQL projects and run builds, your code analysis can benefit from code coverage and test results. TFS reporter is designed specifically to [work with Microsoft Team Fundation Server](https://docs.microsoft.com/en-us/vsts/build-release/tasks/test/publish-test-results?view=vsts) report format which is very old version of [JUnit](https://github.com/windyroad/JUnit-Schema/blob/master/JUnit.xsd). Main diffrence between standard JUnit is that elements cannot be nested and attribute skipped is not present. @@ -117,12 +117,12 @@ Details: ![tfs_junit_reporter_outputs](../images/tfs_details.png) -# Coverage reporters +## Coverage reporters utPLSQL comes with a set of build-in coverage reporters. Have a look into the [coverage documentation](coverage.md) to learn more about them. -# Debug reporter +## Debug reporter The `ut_debug_reporter` provides a highly verbose output containing thorough details about framework and test execution. @@ -161,11 +161,11 @@ Some of the information in debug log might be redundant. > - db object names > - etc. -# Custom reporters +## Custom reporters It is possible to add your own reporters by creating an appropriate object type. In principle, it has to be a subtype of `ut_reporter_base`. However, if the reporter is expected to produce output consumable by a client oustside of the database (e.g. the data has to be reported to the screen or to a file), then you should base it on `ut_output_reporter_base` (which is a subtype of `ut_reporter_base`). In contrast, if you would like to create a reporter that, for example, saves the data to a database table, then it should be based directly on `ut_reporter_base`. (Currently, all reporters in the utPLSQL framework are based on `ut_output_reporter_base`.) Coverage reporters are based on `ut_coverage_reporter_base` (a subtype of `ut_output_reporter_base`). -If need to produce a colored text output from the custom reporter, then you can build it basing on `ut_console_reporter_base` (a subtype of `ut_output_reporter_base`). In many cases it may also be more convenient to create the custom reporter type under a more specialized type, like `ut_documentation_reporter` or `ut_junit_reporter`, and override just some of the functionality. +If you need to produce a colored text output from the custom reporter, then you can build it basing on `ut_console_reporter_base` (a subtype of `ut_output_reporter_base`). In many cases it may also be more convenient to create the custom reporter type under a more specialized type, like `ut_documentation_reporter` or `ut_junit_reporter`, and override just some of the functionality. It is recommended to create the reporter type in the schema where utPLSQL is installed (by default it is the `UT3` schema). Note that before running the utPLSQL uninstall scripts, all custom reporters should be dropped (cf. [the installation documentation](install.md)). In particular, when upgrading to a newer version of utPLSQL, one has to drop the custom reporters and recreate them after the upgrade. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index ca8ab0b4a..bfaa287c7 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,7 +1,5 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4036--develop-blue.svg) -# Running tests - utPLSQL framework provides two main entry points to run unit tests from within the database: - `ut.run` procedures and functions @@ -10,7 +8,7 @@ utPLSQL framework provides two main entry points to run unit tests from within t These two entry points differ in purpose and behavior. Most of the time you will want to use `ut.run` as `ut_runner.run` is designed for API integration and does not display the results to the screen. -# Running from CI servers and command line +## Running from CI servers and command line The best way to run your tests from CI server or command line is to use the [utPLSQL-cli](https://github.com/utPLSQL/utPLSQL-cli) command line client. @@ -32,7 +30,7 @@ unzip -q utplsql-cli.zip ``` -# ut.run +## ut.run The `ut` package contains overloaded `run` procedures and functions. The `run` API is designed to be called directly by a developer when using an IDE/SQL console to execute unit tests. @@ -42,7 +40,7 @@ A single line call is enough to execute a set of tests from one or more schemes. The **procedures** execute the specified tests and produce output to DBMS_OUTPUT using the specified reporter. The **functions** can only be used in SELECT statements. They execute the specified tests and produce outputs as a pipelined data stream to be consumed by a select statement. -## ut.run procedures +### ut.run procedures The examples below illustrate different ways and options to invoke `ut.run` procedures. You can use a wildcard character `*` to call tests by part of their name or to call tests that are located on paths matched by part of path string. @@ -179,7 +177,7 @@ Executes all tests from package _HR.TEST_APPLY_BONUS_ and provide outputs to DBM For details on build-in reporters look at [reporters documentation](reporters.md). -## ut.run functions +### ut.run functions The `ut.run` functions provide exactly the same functionality as the `ut.run` procedures. You may use the same sets of parameters with both functions and procedures. @@ -195,7 +193,7 @@ Example. select * from table(ut.run('hr.test_apply_bonus', ut_junit_reporter())); ``` -# ut_runner.run procedures +## ut_runner.run procedures The `ut_runner` package provides an API for integrating utPLSQL with other products. Maven, Jenkins, SQL Develper, PL/SQL Developer, TOAD and others can leverage this API to call utPLSQL. @@ -262,16 +260,16 @@ select ``` -# Order of test execution +## Order of test execution -## Default order +### Default order When unit tests are executed without random order, they are ordered by: - schema name - suite path or test package name if `--%suitepath` was not specified for that package - `--%test` line number in package -## Random order +### Random order You can force a test run to execute tests in random order by providing one of options to `ut.run`: - `a_random_test_order` - true/false for procedures and 1/0 for functions @@ -317,7 +315,7 @@ select * from table(ut.run('hr.test_apply_bonus', a_random_test_order_seed => 30 **Note** >Random order seed must be a positive number within range of 1 .. 1 000 000 000. -# Run by Tags +## Run by Tags In addition to the path, you can filter the tests to be run by specifying tags. Tags are defined in the test / context / suite with the `--%tags`-annotation ([Read more](annotations.md#tags)). Multiple tags are separated by comma. @@ -338,7 +336,7 @@ You can also exclude specific tags by adding a `-` (dash) in front of the tag select * from table(ut.run('hr.test_apply_bonus', a_tags => '-suite1')) ``` -# Keeping uncommitted data after test-run +## Keeping uncommitted data after test-run utPLSQL by default runs tests in autonomous transaction and performs automatic rollback to assure that tests do not impact one-another and do not have impact on the current session in your IDE. @@ -359,7 +357,7 @@ end; **Note:** >This option is not available when running tests using `ut.run` as a table function. -# Reports character-set encoding +## Reports character-set encoding To get properly encoded reports, when running utPLSQL with HTML/XML reports on data containing national characters you need to provide your client character set when calling `ut.run` functions and procedures. From 9afa968557aecfad696767f0301785df75e87744 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 12 Oct 2022 00:33:51 +0300 Subject: [PATCH 355/887] Adjusting MkDocs configuration --- mkdocs.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index e675c93f4..f88e451f0 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -1,11 +1,12 @@ # Format documented here # http://www.mkdocs.org/user-guide/configuration/ +# https://squidfunk.github.io/mkdocs-material/getting-started/ site_url: http://utPLSQL.org/ site_name: utPLSQL-framework -site_description: utPLSQL Ultimate Unit Testing Framework for Oracle PL/SQL +site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL copyright: Copyright © 2016 - 2022 utPLSQL Team -#repo_url: https://github.com/utPLSQL/utPLSQL # disable for offline docs +repo_url: https://github.com/utPLSQL/utPLSQL theme: name: material palette: @@ -70,7 +71,7 @@ plugins: - git-revision-date-localized: # disable for offline docs enable_creation_date: true # disable for offline docs type: datetime # disable for offline docs - + nav: - User Guide: - index.md @@ -81,7 +82,7 @@ nav: - Advanced data comparison: userguide/advanced_data_comparison.md - Running unit tests: userguide/running-unit-tests.md - Querying for test suites: userguide/querying_suites.md - - Testing best pracitces: userguide/best-practices.md + - Testing best practices: userguide/best-practices.md - Upgrade utPLSQL: userguide/upgrade.md - Reporting: - Using reporters: userguide/reporters.md From 169d3b259ff1eb7b05f0baadf53ed5d197ca3509 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 14 Oct 2022 23:11:01 +0300 Subject: [PATCH 356/887] Added color stylesheet for mkdocs --- docs/stylesheets/extra.css | 12 ++++++++++++ mkdocs.yml | 6 +++++- 2 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 docs/stylesheets/extra.css diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css new file mode 100644 index 000000000..7f05ab831 --- /dev/null +++ b/docs/stylesheets/extra.css @@ -0,0 +1,12 @@ +[data-md-color-scheme="default"] { + --md-primary-fg-color: #2f8bff; + --md-accent-fg-color: #1f5db0; + --md-accent-fg-color--transparent: #1f5db0; +} + +[data-md-color-scheme="slate"] { + --md-hue: 200; + --md-primary-fg-color: #2f8bff; + --md-accent-fg-color: #1f5db0; + --md-accent-fg-color--transparent: #1f5db0; +} diff --git a/mkdocs.yml b/mkdocs.yml index f88e451f0..ffa090034 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -6,7 +6,8 @@ site_url: http://utPLSQL.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL copyright: Copyright © 2016 - 2022 utPLSQL Team -repo_url: https://github.com/utPLSQL/utPLSQL +extra_css: + - stylesheets/extra.css theme: name: material palette: @@ -60,6 +61,9 @@ markdown_extensions: - pymdownx.inlinehilite - pymdownx.snippets - pymdownx.superfences + - pymdownx.caret + - pymdownx.mark + - pymdownx.tilde - toc: permalink: true use_directory_urls: false From 1e710da8cdcac43ff18a202af3f5d6edcb1970f7 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 14 Oct 2022 21:22:21 +0100 Subject: [PATCH 357/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 25d6fbf77..b376d5d4c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index b860bf718..2e50760e4 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 5dad05ae0..dc6d9e59d 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 2be6c96ac..fd0cfce15 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 8bce25886..eeaf1b002 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 41511efed..9805b2b13 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 83fe89885..e36e37d70 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 4ed6f48be..6e3d1f0c7 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 01c27981d..453f2f794 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 362d60d3b..1aa179680 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 25b304cdf..8744077fa 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 1b6dcab3c..99409fd95 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 8c35d4ca5..bcab40387 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 46da230a4..bd3eea917 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index f55e77e88..94c13908a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index b8fe358c5..f20d8722c 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 68256fa4f..461702a47 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4037--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index d25c365da..08a6d95c7 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4037-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4041-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 519f06b8bca56d8a7c4166b728ae0c48392d3a23 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 14 Oct 2022 23:45:08 +0300 Subject: [PATCH 358/887] Adding back repo-url --- mkdocs.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/mkdocs.yml b/mkdocs.yml index ffa090034..8543b4030 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -6,6 +6,7 @@ site_url: http://utPLSQL.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL copyright: Copyright © 2016 - 2022 utPLSQL Team +repo_url: https://github.com/utPLSQL/utPLSQL extra_css: - stylesheets/extra.css theme: From e1690f0dd2b522464129cfa063ff544bb6b91a1d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 18 Aug 2022 21:19:12 +0300 Subject: [PATCH 359/887] Exclude Unit Test packages from coverage --- source/core/coverage/ut_coverage.pkb | 2 +- test/ut3_tester_helper/coverage_helper.pkb | 15 +++++++++++++++ .../test_coverage/test_extended_coverage.pkb | 16 ++++++++-------- .../test_coverage/test_proftab_coverage.pkb | 1 + 4 files changed, 25 insertions(+), 9 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index f5eccc893..2f38803ad 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -167,7 +167,7 @@ create or replace package body ut_coverage is begin if not is_develop_mode() then --skip all the utplsql framework objects and all the unit test packages that could potentially be reported by coverage. - l_skip_objects := coalesce(ut_utils.get_utplsql_objects_list(),ut_object_names()); + l_skip_objects := coalesce( ut_utils.get_utplsql_objects_list() multiset union all ut_suite_manager.get_schema_ut_packages(a_coverage_options.schema_names) , ut_object_names() ); end if; --Regex exclusion override the standard exclusion objects. diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index fdfa32364..99f26e9f8 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -48,6 +48,20 @@ create or replace package body coverage_helper is end; end;]'; + execute immediate q'[create or replace package ut3_develop.some_other_package is + procedure do_stuff(i_input in number); + end;]'; + + execute immediate q'[create or replace package body ut3_develop.some_other_package is + procedure do_stuff(i_input in number) is + begin + if i_input = 2 then dbms_output.put_line('should not get here'); elsif i_input = 1 then dbms_output.put_line('should get here'); + else + dbms_output.put_line('should not get here'); + end if; + end; + end;]'; + execute immediate q'[create or replace package ut3_develop.test_dummy_coverage is --%suite(dummy coverage test) --%suitepath(coverage_testing) @@ -77,6 +91,7 @@ create or replace package body coverage_helper is pragma autonomous_transaction; begin begin execute immediate q'[drop package ut3_develop.test_dummy_coverage]'; exception when others then null; end; + begin execute immediate q'[drop package ut3_develop.some_other_package]'; exception when others then null; end; begin execute immediate q'[drop package ut3_develop.]'||covered_package_name; exception when others then null; end; end; diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index 3c8781bc4..af029e254 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -113,9 +113,9 @@ create or replace package body test_extended_coverage is begin --Arrange l_expected := '%' || - '%%'; + '%%'; l_not_expected := '%' || - '%%'; + '%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( @@ -140,9 +140,9 @@ create or replace package body test_extended_coverage is begin --Arrange l_expected := '%' || - '%%'; + '%%'; l_not_expected := '%' || - '%%'; + '%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( @@ -167,9 +167,9 @@ create or replace package body test_extended_coverage is begin --Arrange l_expected := '%' || - '%%'; + '%%'; l_not_expected := '%' || - '%%'; + '%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( @@ -194,9 +194,9 @@ create or replace package body test_extended_coverage is begin --Arrange l_expected := '%' || - '%%'; + '%%'; l_not_expected := '%' || - '%%'; + '%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index 7cad0a67e..f3aad5702 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -66,6 +66,7 @@ create or replace package body test_proftab_coverage is ); --Assert ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_like('%%'); end; procedure coverage_for_file is From 8ac32d7b2fae363924f22f84e685f30c6e62fdc4 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 6 Sep 2022 23:34:30 +0300 Subject: [PATCH 360/887] Exclude Unit Test packages from coverage --- source/core/coverage/ut_coverage.pkb | 2 +- source/core/ut_suite_manager.pkb | 16 ++++++++++++---- source/core/ut_suite_manager.pks | 2 +- test/ut3_tester_helper/run_helper.pkb | 2 +- .../test_coverage/test_extended_coverage.pkb | 9 +++++---- 5 files changed, 20 insertions(+), 11 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 2f38803ad..7eb5a34c2 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -167,7 +167,7 @@ create or replace package body ut_coverage is begin if not is_develop_mode() then --skip all the utplsql framework objects and all the unit test packages that could potentially be reported by coverage. - l_skip_objects := coalesce( ut_utils.get_utplsql_objects_list() multiset union all ut_suite_manager.get_schema_ut_packages(a_coverage_options.schema_names) , ut_object_names() ); + l_skip_objects := coalesce( ut_utils.get_utplsql_objects_list() multiset union all ut_suite_manager.get_schema_ut_packages(a_coverage_options.schema_names, a_coverage_options.include_schema_expr) , ut_object_names() ); end if; --Regex exclusion override the standard exclusion objects. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 805fd608b..86f68c076 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -493,13 +493,21 @@ create or replace package body ut_suite_manager is return l_suites; end; - function get_schema_ut_packages(a_schema_names ut_varchar2_rows) return ut_object_names is + function get_schema_ut_packages(a_schema_names ut_varchar2_rows, a_schema_name_expr varchar2) return ut_object_names is + l_schema_names ut_varchar2_rows := a_schema_names; begin - for i in 1 .. a_schema_names.count loop - refresh_cache(a_schema_names(i)); + if a_schema_name_expr is not null then + select username + bulk collect into l_schema_names + from all_users + where regexp_like(username,a_schema_name_expr,'i'); + end if; + + for i in 1 .. l_schema_names.count loop + refresh_cache(l_schema_names(i)); end loop; - return ut_suite_cache_manager.get_cached_packages( a_schema_names ); + return ut_suite_cache_manager.get_cached_packages( l_schema_names ); end; function get_schema_names(a_paths ut_varchar2_list) return ut_varchar2_rows is diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 170b83f05..65b3c0654 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -30,7 +30,7 @@ create or replace package ut_suite_manager authid current_user is * @param a_schema_names list of schemas to return the information for * @return array containing unit test schema and object names */ - function get_schema_ut_packages(a_schema_names ut_varchar2_rows) return ut_object_names; + function get_schema_ut_packages(a_schema_names ut_varchar2_rows, a_schema_name_expr varchar2) return ut_object_names; /** * Builds a hierarchical suites based on given suite-paths diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index 95f93f751..a132f4943 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -616,7 +616,7 @@ create or replace package body run_helper is function get_schema_ut_packages(a_owner in varchar2) return ut3_develop.ut_object_names is begin - return ut3_develop.ut_suite_manager.get_schema_ut_packages(ut3_develop.ut_varchar2_rows(a_owner)); + return ut3_develop.ut_suite_manager.get_schema_ut_packages(ut3_develop.ut_varchar2_rows(a_owner), null); end; function ut_output_buffer_tmp return t_out_buff_tab pipelined is diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index af029e254..488ee3a20 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -112,9 +112,9 @@ create or replace package body test_extended_coverage is l_actual clob; begin --Arrange - l_expected := '%' || + l_expected := '%' || '%%'; - l_not_expected := '%' || + l_not_expected := '%' || '%%'; --Act l_actual := @@ -123,14 +123,15 @@ create or replace package body test_extended_coverage is ut3_develop.ut.run( a_paths => ut3_develop.ut_varchar2_list('ut3_develop.test_regex_dummy_cov', 'ut3_tester_helper.test_regex_dummy_cov'), a_reporter=> ut3_develop.ut_coverage_sonar_reporter( ), - a_include_schema_expr => '^ut3_develop', - a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) + a_include_schema_expr => '^ut3_tester_hel.*', + a_include_objects => ut3_develop.ut_varchar2_list( 'ut3_develop.regex_dummy_cov' ) ) ]' ); --Assert ut.expect(l_actual).to_be_like(l_expected); ut.expect(l_actual).not_to_be_like(l_not_expected); + ut.expect(l_actual).not_to_be_like('%ut3_tester_helper.test_regex_dummy_cov%'); end; procedure coverage_regex_include_object is From d825156df00b3e313ae4679d9706f09424fab17a Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 17 Oct 2022 00:45:14 +0300 Subject: [PATCH 361/887] Fixing failing test on 11g XE --- .../reporters/test_coverage/test_extended_coverage.pkb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index 488ee3a20..d7f1b61d7 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -128,8 +128,10 @@ create or replace package body test_extended_coverage is ) ]' ); + --Assert - ut.expect(l_actual).to_be_like(l_expected); + --The below is a workaround for problem with large CLOB like comparison on 11g XE db. + ut.expect(to_char(substr(l_actual,instr(l_actual,''),2000))).to_be_like(l_expected); ut.expect(l_actual).not_to_be_like(l_not_expected); ut.expect(l_actual).not_to_be_like('%ut3_tester_helper.test_regex_dummy_cov%'); end; From a552566232bccb28cc266964e49e0057feceb87e Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 17 Oct 2022 08:29:01 +0100 Subject: [PATCH 362/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index b376d5d4c..d29968ea0 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 2e50760e4..3b2561064 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index dc6d9e59d..93ff86f47 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index fd0cfce15..8f5e3d012 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index eeaf1b002..4fe82c351 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 9805b2b13..71b468da7 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e36e37d70..41532a7bb 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 6e3d1f0c7..64edde630 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 453f2f794..bc73e60b2 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 1aa179680..d1bbd9f9e 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 8744077fa..e52a4ac7d 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 99409fd95..4a949a5b5 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index bcab40387..f63c08f2a 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index bd3eea917..a52a432f8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 94c13908a..92afa5ca3 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index f20d8722c..5cc8dcea3 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 461702a47..54381ca25 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4041--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 08a6d95c7..66e1acdfd 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4041-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4049-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 10fd9e02d23ec95f7d9fec9810587a072217c02c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 17 Oct 2022 08:42:03 +0100 Subject: [PATCH 363/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index d29968ea0..c5624601b 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 3b2561064..7338271be 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 93ff86f47..d8b755459 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 8f5e3d012..a3a4d3de7 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 4fe82c351..a30a4d6de 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 71b468da7..fc5ba1063 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 41532a7bb..022f4896c 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 64edde630..9ac021c0e 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index bc73e60b2..62c4d75ac 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index d1bbd9f9e..e6fd25e98 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index e52a4ac7d..871bebcdf 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 4a949a5b5..aa92a6bdd 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index f63c08f2a..ade43890d 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index a52a432f8..84f87c175 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 92afa5ca3..0f3c49a59 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 5cc8dcea3..f45fb2c17 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 54381ca25..87320dd6b 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4049--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 66e1acdfd..3b6b56bbd 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4049-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4050-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 48505fbe05364660b65fca7e6934a652e4b74a03 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 17 Oct 2022 18:28:38 +0300 Subject: [PATCH 364/887] Adding support for long type names in tests. Resolves: #1235 --- .../data_values/ut_cursor_details.tpb | 4 ++++ .../expectations/test_expectation_anydata.pkb | 15 +++++++++++++++ .../expectations/test_expectation_anydata.pks | 6 ++++++ 3 files changed, 25 insertions(+) diff --git a/source/expectations/data_values/ut_cursor_details.tpb b/source/expectations/data_values/ut_cursor_details.tpb index adc705f65..b823ff944 100644 --- a/source/expectations/data_values/ut_cursor_details.tpb +++ b/source/expectations/data_values/ut_cursor_details.tpb @@ -91,7 +91,11 @@ create or replace type body ut_cursor_details as a_cursor_number in number ) return self as result is l_columns_count pls_integer; + $if dbms_db_version.version = 12 and dbms_db_version.release = 1 or dbms_db_version.version < 12 $then l_columns_desc dbms_sql.desc_tab3; + $else + l_columns_desc dbms_sql.desc_tab4; + $end l_is_collection boolean; l_hierarchy_level integer := 1; begin diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index 98938c107..bbac14ea2 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -1211,5 +1211,20 @@ Rows: [ 60 differences, showing first 20 ] ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; + + $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then + procedure long_names_object_types is + pragma autonomous_transaction; + begin + execute immediate 'create or replace type tp_r_ug_sportsman_invitation_result is object ( code number(18) )'; + execute immediate 'begin ut.expect(anydata.convertObject(tp_r_ug_sportsman_invitation_result(1))).to_equal(anydata.convertObject(tp_r_ug_sportsman_invitation_result(1))); end;'; + execute immediate 'drop type tp_r_ug_sportsman_invitation_result'; + exception + when others then + execute immediate 'drop type tp_r_ug_sportsman_invitation_result'; + raise; + end; + $end + end; / \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectation_anydata.pks b/test/ut3_user/expectations/test_expectation_anydata.pks index 2abb48b7f..81dea74eb 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pks +++ b/test/ut3_user/expectations/test_expectation_anydata.pks @@ -233,5 +233,11 @@ create or replace package test_expectation_anydata is --%test ( Reports success when comparing complex nested objects ) procedure complex_nested_object_success; + + $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then + --%test ( Compares object types with long names - Issue #1235 ) + procedure long_names_object_types; + $end + end; / From 1eb52e1e209945477c4066004cdd2f5293290297 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 17 Oct 2022 20:33:42 +0300 Subject: [PATCH 365/887] Fixing unit test - needs to use ut3_develop sourcecode in test. --- .../expectations/test_expectation_anydata.pkb | 20 +++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index bbac14ea2..c56c31930 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -1216,12 +1216,24 @@ Rows: [ 60 differences, showing first 20 ] procedure long_names_object_types is pragma autonomous_transaction; begin - execute immediate 'create or replace type tp_r_ug_sportsman_invitation_result is object ( code number(18) )'; - execute immediate 'begin ut.expect(anydata.convertObject(tp_r_ug_sportsman_invitation_result(1))).to_equal(anydata.convertObject(tp_r_ug_sportsman_invitation_result(1))); end;'; - execute immediate 'drop type tp_r_ug_sportsman_invitation_result'; + execute immediate q'[create or replace type + very_long_type_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it + is object ( + code number(18) + )]'; + execute immediate q'[ + begin + ut3_develop.ut.expect(anydata.convertObject( + very_long_type_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it(1) + )).to_equal(anydata.convertObject( + very_long_type_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it(1) + )); + end;]'; + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + execute immediate 'drop type very_long_type_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it'; exception when others then - execute immediate 'drop type tp_r_ug_sportsman_invitation_result'; + execute immediate 'drop type very_long_type_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it'; raise; end; $end From de65f14d2f9f9debe88437468c7544d30d357742 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 17 Oct 2022 20:36:49 +0300 Subject: [PATCH 366/887] Improvements to local development scripts --- development/cleanup.sh | 4 ++-- development/install.sh | 4 ++-- development/refresh_sources.sh | 4 ++-- development/refresh_ut3.sh | 2 +- development/template.env.sh | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/development/cleanup.sh b/development/cleanup.sh index 33358302a..65f3ab0c1 100755 --- a/development/cleanup.sh +++ b/development/cleanup.sh @@ -1,9 +1,9 @@ -#!/usr/bin/env bash +#!/bin/bash #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" -. development/env.sh +. ./development/env.sh "${SQLCLI}" sys/${ORACLE_PWD}@//${CONNECTION_STR} AS SYSDBA <<-SQL set echo on diff --git a/development/install.sh b/development/install.sh index f3a62b0ec..468bafd38 100755 --- a/development/install.sh +++ b/development/install.sh @@ -1,9 +1,9 @@ -#!/usr/bin/env bash +#!/bin/bash #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" -. development/env.sh +. ./development/env.sh header="******************************************************************************************" if ! development/cleanup.sh; then diff --git a/development/refresh_sources.sh b/development/refresh_sources.sh index 7af3aaec0..b6ef51ef9 100755 --- a/development/refresh_sources.sh +++ b/development/refresh_sources.sh @@ -1,9 +1,9 @@ -#!/usr/bin/env bash +#!/bin/bash #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" -. development/env.sh +. ./development/env.sh # remove sub-direcotry containing main branch shallow copy rm -rf ${UTPLSQL_DIR:-utPLSQL_latest_release} diff --git a/development/refresh_ut3.sh b/development/refresh_ut3.sh index 570d3c86a..827af827d 100755 --- a/development/refresh_ut3.sh +++ b/development/refresh_ut3.sh @@ -1,4 +1,4 @@ -#!/usr/bin/env bash +#!/bin/bash #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" diff --git a/development/template.env.sh b/development/template.env.sh index e69aa81aa..7761a70c4 100755 --- a/development/template.env.sh +++ b/development/template.env.sh @@ -1,4 +1,4 @@ -#!/usr/bin/env bash +#!/bin/bash export SQLCLI=sql # For sqlcl client #export SQLCLI=sqlplus # For sqlplus client From 689bbd0e365ed919315c29727bc10fbfc0dadce8 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 17 Oct 2022 22:24:40 +0300 Subject: [PATCH 367/887] Fixing documentation build process Resolves: #1237 --- .github/workflows/build.yml | 12 ++-- .github/workflows/release.yml | 40 +++---------- mkdocs.yml | 3 + mkdocs_offline.yml | 103 ++++++++++++++++++++++++++++++++++ 4 files changed, 120 insertions(+), 38 deletions(-) create mode 100644 mkdocs_offline.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a0aae6b64..078d45e3b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -245,11 +245,13 @@ jobs: git commit -m 'Updated project version after build [skip ci]' git push --quiet origin HEAD:${CI_ACTION_REF_NAME} - - name: Copy and push documentation to utPLSQL-github-io repo - id: push-documentation - env: - API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} - run: .github/scripts/push_docs_to_github_io.sh + - name: Build and publish documentation + run: | + pip install mkdocs + pip install mkdocs-git-revision-date-localized-plugin + pip install mkdocs-material + pip install mike + mike deploy -p develop dispatch: name: Dispatch downstream builds diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index bd977d447..acac5f1aa 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,36 +10,6 @@ defaults: jobs: - publish: - name: Deploy documentation - concurrency: publish - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - uses: c-py/action-dotenv-to-setenv@v2 - with: - env-file: .github/variables/.env - - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action - - - name: Set buid version number env variables - run: .github/scripts/set_version_numbers_env.sh - - - name: Setup git config - run: | - git config --global user.email "github-actions[bot]@users.noreply.github.com" - git config --global user.name "github-actions[bot]" - - - name: Update project version & build number in source code and documentation - run: .github/scripts/update_project_version.sh - - - name: Copy and push documentation to utPLSQL-github-io repo - env: - API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} - run: .github/scripts/push_docs_to_github_io.sh - upload_artifacts: name: Upload archives concurrency: upload @@ -54,7 +24,7 @@ jobs: env-file: .github/variables/.env - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action - - name: Set buid version number env variables + - name: Set build version number env variables run: .github/scripts/set_version_numbers_env.sh - name: Update project version & build number in source code and documentation @@ -65,10 +35,14 @@ jobs: git config --global user.email "github-actions[bot]@users.noreply.github.com" git config --global user.name "github-actions[bot]" - - name: Build html documentation + - name: Build and publish documentation run: | pip install mkdocs - mkdocs build --clean --strict + pip install mkdocs-git-revision-date-localized-plugin + pip install mkdocs-material + pip install mike + mike deploy -p -u ${UTPLSQL_VERSION} latest + mkdocs build --clean -f mkdocs_offline.yml rm -rf docs/* cp -r -v site/* docs git add . diff --git a/mkdocs.yml b/mkdocs.yml index 8543b4030..487505097 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -1,7 +1,10 @@ # Format documented here # http://www.mkdocs.org/user-guide/configuration/ # https://squidfunk.github.io/mkdocs-material/getting-started/ +# See this document for list of plugins to disable for offline (local) documentation +# https://squidfunk.github.io/mkdocs-material/setup/building-for-offline-usage/ +edit_uri: "" site_url: http://utPLSQL.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml new file mode 100644 index 000000000..fe2255e59 --- /dev/null +++ b/mkdocs_offline.yml @@ -0,0 +1,103 @@ +# Format documented here +# http://www.mkdocs.org/user-guide/configuration/ +# https://squidfunk.github.io/mkdocs-material/getting-started/ +# See this document for list of plugins to disable for offline (local) documentation +# https://squidfunk.github.io/mkdocs-material/setup/building-for-offline-usage/ + +edit_uri: "" +site_url: http://utPLSQL.org/ +site_name: utPLSQL-framework +site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL +copyright: Copyright © 2016 - 2022 utPLSQL Team +#repo_url: https://github.com/utPLSQL/utPLSQL # disable for offline docs +extra_css: + - stylesheets/extra.css +theme: + name: material + palette: + # Palette toggle for light mode + - media: "(prefers-color-scheme: light)" + scheme: default + toggle: + icon: material/lightbulb-outline + name: Switch to dark mode + # Palette toggle for dark mode + - media: "(prefers-color-scheme: dark)" + scheme: slate + toggle: + icon: material/lightbulb + name: Switch to light mode + logo: assets/icon-transparent.png + favicon: assets/favicon.png + features: +# - navigation.instant # disable for offline docs +# - navigation.indexes + - navigation.tabs + - navigation.tracking + - toc.follow + - toc.integrate + - search.suggest + - search.highlight +extra: +# homepage: http://jgebal.github.io/ +# homepage: http://utPLSQL.org/ + social: + - icon: fontawesome/brands/twitter + link: https://twitter.com/utPLSQL + - icon: fontawesome/brands/slack + link: https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww + - icon: fontawesome/brands/github + link: https://github.com/utPLSQL + - icon: fontawesome/solid/envelope + link: mailto:utPLSQL@utPLSQL.org + consent: + title: Cookie consent + description: >- + We use cookies to recognize your repeated visits and preferences, as well + as to measure the effectiveness of our documentation and whether users + find what they're searching for. With your consent, you're helping us to + make our documentation better. +# version: # disable for offline docs +# provider: mike # disable for offline docs +markdown_extensions: + - pymdownx.highlight: + anchor_linenums: true + - pymdownx.inlinehilite + - pymdownx.snippets + - pymdownx.superfences + - pymdownx.caret + - pymdownx.mark + - pymdownx.tilde + - toc: + permalink: true +use_directory_urls: false +strict: true + +plugins: +# - search # disable for offline docs + - mike +# - git-revision-date-localized: # disable for offline docs +# enable_creation_date: true # disable for offline docs +# type: datetime # disable for offline docs + +nav: + - User Guide: + - index.md + - Installation: userguide/install.md + - Getting Started: userguide/getting-started.md + - Annotations: userguide/annotations.md + - Expectations: userguide/expectations.md + - Advanced data comparison: userguide/advanced_data_comparison.md + - Running unit tests: userguide/running-unit-tests.md + - Querying for test suites: userguide/querying_suites.md + - Testing best practices: userguide/best-practices.md + - Upgrade utPLSQL: userguide/upgrade.md + - Reporting: + - Using reporters: userguide/reporters.md + - Code coverage: userguide/coverage.md + - Error handling and reporting: userguide/exception-reporting.md + - About: + - Project Details: about/project-details.md + - License: about/license.md + - Support: about/support.md + - Authors: about/authors.md From 4223e0c889ca7ebbfa1003f6ee68ac0a25d8c666 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 17 Oct 2022 20:57:02 +0100 Subject: [PATCH 368/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index c5624601b..6ca52629d 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 7338271be..9396f76fd 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index d8b755459..bbc477c40 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index a3a4d3de7..c880d0bcf 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index a30a4d6de..3ac670e12 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index fc5ba1063..348b9a0fc 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 022f4896c..1ef87e075 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 9ac021c0e..5f9695a74 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 62c4d75ac..e059fc62e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e6fd25e98..9490f36d0 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 871bebcdf..b4bd7af17 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index aa92a6bdd..07310dd4f 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ade43890d..ced4f00a8 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 84f87c175..d943e01f2 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 0f3c49a59..fb19cb65c 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index f45fb2c17..b86332e13 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 87320dd6b..c1128b84c 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4050--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 3b6b56bbd..227a359bb 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4050-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4055-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 8a3554d4e28e7e50e16418a1e61797c0ab6d488f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 17 Oct 2022 22:59:22 +0300 Subject: [PATCH 369/887] Fixing documentation build process --- .github/workflows/build.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 078d45e3b..92bf0752e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -245,6 +245,11 @@ jobs: git commit -m 'Updated project version after build [skip ci]' git push --quiet origin HEAD:${CI_ACTION_REF_NAME} + - name: Setup git config + run: | + git config --global user.email "github-actions[bot]@users.noreply.github.com" + git config --global user.name "github-actions[bot]" + - name: Build and publish documentation run: | pip install mkdocs From 65cfab5dd0a47a2bb10ded89e7ea0c91e84a0d34 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 17 Oct 2022 21:10:44 +0100 Subject: [PATCH 370/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 6ca52629d..5aba8c785 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 9396f76fd..afcd11531 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index bbc477c40..61e52a3ee 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index c880d0bcf..a152f7f22 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 3ac670e12..c95745506 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 348b9a0fc..f7eb1d054 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 1ef87e075..854190837 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 5f9695a74..afab60ca0 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index e059fc62e..efba68e78 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 9490f36d0..11526888a 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b4bd7af17..5984f4379 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 07310dd4f..4216e832a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ced4f00a8..439a0fe5d 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d943e01f2..5e037ef9d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index fb19cb65c..9f7239f13 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index b86332e13..c095f468f 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index c1128b84c..259b03f4c 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4055--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 227a359bb..8de2fcc6f 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4055-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4056-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 4e448448b138c93b1215764bdc1e95fb1038dbbb Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 17 Oct 2022 23:32:42 +0300 Subject: [PATCH 371/887] Adding missing images --- docs/assets/favicon.png | Bin 0 -> 76887 bytes docs/assets/icon-transparent.png | Bin 0 -> 33228 bytes 2 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 docs/assets/favicon.png create mode 100644 docs/assets/icon-transparent.png diff --git a/docs/assets/favicon.png b/docs/assets/favicon.png new file mode 100644 index 0000000000000000000000000000000000000000..7c34109d0bb66a2279905822ae733eaf4c5fed6c GIT binary patch literal 76887 zcmeGFcT`jP_CF5W8AZTR5$QH8AfQqrH6S7aQWTUXpfV7V5~%?~5(NdNh>C*rCW1&2 z=^#W01?fF>BGLk(lTbp+?<5ofaqisv`L6Z+^URuAv&K=+Iq$R2F0ZnEtgWfSvV&{K zh7B87R4<;tvSGs}BJdC4k8Qw@`0;%^4*YA2!#P#mKY+j7|M=?>@ZTF9uBe>bkXp?% zNdKP@MGeIb8`1-q$v3wG|GoY0MFWQo8$!zI|7`4e_WBU;gPe}a`i?qK3rE;Zd-Dx2 z7)->{*2=-`=3R3Us68ZXRF(_)NeAgaNy*;)rlTd)_JFRXjroQ%r%p>rpE@Ib8g$^a zxU~3LX)%d;i_OIwHqew*&nxP>m<&^xqpzF0js>8{LJJ)Z-``R!@TbT2T?e}FD15vj zrJy^s^}R45Jo}bSO1Pns;n;Mh_Zv!t4*W7cep(A(7e#C_Rn>myp=^8lk2?=_x9%1{ zckg=Mv8M_m@ESK-O(^ksnP%4jqANrK+bWh3rN!N4U{y3lk)KMIu#$rpWSH$$zWo3H z`~SBm;I<2|r+hiTa!#nTmLSY+F2^gllU#HY~Q4}`h_}pOPjGdW!8_p zqP7fT47sv94-#BpZJD`+GOV5>U zvC2WIc+S~vI`3`9g(xGtuWx%(j+Y;ZRw_Jm_j(a|Vo>z2f`G~k8HWc;B-zQmaK2W~_J9ZkGZ zIBvB|>c!PhLt8n;vMnwDWKUw-dKoJ9>T2{Iz8bTE4%;@{ofJ&S$X7Lw0UYz=5%B}E z%JFjDABM}4U9RV7<%PPQfq#~>YiMHjq*-~!9`EsHC90X;oyfsxL{1L(nuV7=al%x_ zh1II3IEiP5wK{Uuyy4!(GTi?MSEXh9r4y!E;AdeLy>HbX71`g_-uRBg{L+@>hWah+ z$s93%^g$K+^vd=N8X(Nt5a;x~9yy>b#6rYSB9BPJ30Aq5G-PW7%&K?O25#t_` z#NNK6#67c<#ipMB#FZDLz)98b`8Ze+P|d|B$$Z@;%t{P&3}k!X$zo$fj6+0*1CG_6 zhhUKTS>hF!XL3x*lJ?U|Cn)?|~X zr_I8G_Fc|05Gl0groe=Z8*!x&jHBd;L~N_AT=&*+lguyS?VR!nZ-prg!}iu%DCZrv@w`~Gxi8z+->L*OAbeSR|65n=H}k0$0b z7S=+J(c9_o;*j@;9gLSDDJ&f8LHwL{^2l9_F9td3v!g{~&T=FARv)Z2CU~hC{HC+t zKA20++)@r1$7!c!D)&G-V47fwoH4Q)rlx{FH;du6V?uv77NGv66ZZVwdeh%8KdZH0YjIdz@naMYM*Ks-`*SD~WB z7GIMEU>uw77BG`5Ic(0lF4`+QT6aL}szGG)dEM?U48r-Zgo zQMj=Pk|ZrNcIOu9MyAtK$Tmop-LeHdU`K zDvnz#+oLNw^gNUO(E6VM1?HWoAjbLG^6nvM(!{SuPEW8Q1pd4{#+%`xQ{3pcshMx9{JCE&YvhOFEaxsaC*lJLWsJSb(}_3y#@{L|uN-rQl7HADHY* zmAsW5IcSYIVI$&H5~;;>l^Qa8t&UqaFfom%9C!x$k!5B++R^0gk(dL7t+oU{UFc6l z-}mTESD}g=0mg>Uqt6i!4H?mMrttoPlA2!Zjg?yqa%4c5gp?hhLOuR$zr|Npv$ds%(8Ql2w3t<`Mh0pK?Xk*-_r7Xend>@zY z=OJazJsa^W!g$j)(QmKPHPn3*e-^6@6H#>_x1CK?XfmpeHya3VS1c$}4Q%ExrF=P& zGc@)^PuicADED_*5gC`vaqHqo zv+mVaWE8*V!s@)L>K2-e^(1N*1K$T8nh{hJ0KO@e)VvaNu(Zw8L&sfR%3;Cv(r?`@ zP7Vt&ImI;GFIr9!aUz#O<9lgM0-%0Sz*n4G%OIb%%dRwQiK^mEVr+Ci42<*WUhaPAB1g zv)rg!AY(+E5;7n#p1(J>8!PT?F3C4aB&RFL0XC zL&CVv+`77thm`-@uo+2ke2|`F0Fj?dO3<7Oq7D~62P*6hMrM@je@_cFZ=JtAMX*mJ zpN6mx>OH~$vH2J$#FVi^zv@8GJsY3${!Rs3gVB}Y8mtPp7YqjKam-n{p9~t(0+cKhQiGu ze?mGr!YhJ0N%INT6Y!VYfq1d8pPTe%Z8r*=G{JZ9U*?9)c5W1O|6)YBn-B|1JbKx5 zRZqUqm;jxp#Z$Xal5!_v9{~NAV*NQ!!G%`EIA*iPFP;3=hxUUhMGBicv11`GD8!_9 zn#l68Ye)A>H|Bh!&r`_>InJYd{6on7iwv<_p3xeS%42}*tdmGt3F~G;-9#S7&rYem zzgr=%(ZgR-3}ru6pf&eAeP83Q_~zOe`TM5%$f+`?9(nT=L~naS6Yk z^!oKqgs&j;h~h&aS>&ASTZpHJtm5~Hu@g}R;Z9?DeR2uZ+;lC@+m49=<3i0gucXiD z&hJ9_&)*zs{0lA9z4p5XsTOzMdu7QEbe-rLPfJq_y~l0G_?oDO7KfgeoT)Cb$x6WN^a1E=?| zF1-FAz<9}vGZ5c~EZk}Q9<0Rq2~3)8en($_MoC*MQg6=${j?1p zlIy2eTzcgLtRCWGNZPxIL7oO%lPn5Nf|e`Vz>^3@J0&x%dZ(2clMhBU>G;wtTF->d zcdA9jDal+3zzuAmZ@JHHdcQ7py4u7;+Z)5D zCD)eid&jthn!gBYLsgha%M%BoLqYT&5Yl>oWKDDU@lwk0U<9pz%oiUJ@*evZO120y zoW5)|!ar+#Gs#{5k820fnLyip^=A`Up!iE}|IMVhwiroVG{nij6f-SLDIChini4Xx zaRkmi_K9eMRamunp0OsBdLAuw=_?!ayNmPTSwJpU`*lA2S2OC`D+3dWytZO{*riTN zjuCCVQHCNCAMom~5=FqY)y2Gj7`)#qVb1twY}7*x`1t%&(>6XgPeGu|rb9U^`cXy` z@h@Alr3Uag>`6TdZ9=Jx1vjJ5x0_yi6;m{87glFDeS)hWI|!RN4`#MOYVYU`&h}pS zf&b+|ymHd>+3b9!0Q&7hXFC*$eOohYtQH`4(2JCFJ;w=|5`>EA8nHxjXc01M`;t_1Oj(3n(IyIEW%OdheF2mZCNh$d8IKk4nlV(swkr15*{f zLy1!}8~l-uzqmU|@iLY%U(l-#P)Cmbwg8@Udn?i4Uxl8`*Gic?&Kt0Oj`Yi##rPkt4f`d79czN`d|RWQo(?XMo1Ygh43%vqx{LC z2ENIH7j_m0fQusgo=H{j>^ujBq+{7tWMkUN?;UZTyI&93YJ2RU*Xn;2y{k~C-^`P- z4MgcF{YdjP^vH}>Ud`C$l4nJ<5l}GF247(hA{+DK+7H}le|BVf5T^r^|M+FD?jYI! zFkB~xT~3owX?G{cq|q8FY2)x0cCXXWI;d7XV7$&VRvo*Q%6Mw{aPgIBP$KZLF0>|e z*mhm0aOL|hJh=>5)bPsuY^Y{9p)dn#z7dK>fRnS&uo6aKL#RQLaA{qhV+Je1X4f(f zu+?MVe})7ZLsOqw@P(C?aUY?hP;)tlb)7B|vx)4SBx!XOe1Qt}D44Pmfpcw0&#Tfi zGz*w25Iht$ksK?-A5{J4(#01iN9Em#QX@8hEI@VV782F(ff=nX{Gn(dacVGduWkMi zX)~x>CpJZ{2`Xg#W{mOa)a4xoVNaJ-&lLP6h}73thJjBuz5R>Z_4E=T31HIefF~Ow zZzo^h^G=~K0x9FX&;nd|SyI2)G)6DJ8IXlFggXrDR+rE$LXdeOQm>~(`D*GmRBP>s zyI?iE39bI-hxfy)eih#Fn^tfa3$T(_SM-XzUxV8Hnvz!qb&5jmrfbmW6PL3iu>`Mx zw1}RZmm+l_B}zMbeEh|U24_@*zQY@=z#h4o-aUa={l>iGo%S;zu7znMv0fi&H+CAMr_ttT)7USQRxsg5Xclp^cX0;{c zcM0!U_+ZwDrx|$hy1!}#O43kTofqLMj3U~gQ6&guK>ba($x^5f)=}qOlO9e1d+5Kp z@U;WC*Kl9!R)65-Ju-ug5Uj=L%j*NW9A07L9A8E93`NN~&WbsXH&EYpvxdVIeUYT- z^B2|k=>FQsG%@|jAooUpq^mDrtN%K!9S(@dI@Wd~kQQ>rjZ})Be;LU=BuXjoht*%E z*`PU9WXF2Q$5*4fH1(cD6#g}sFp7%8YD-_# zLc|j=Y1VQQpt(-n#=U6YpOX>msWR9;IauMzN5?M%oyQvnBuA%k*Sve4Y+ffx z_(+PLDCs`-nzTZVdjjV^aLvEcM&0)^-<`)pqa^|VsT(Bs$ zH(v=DQZ^GRwZVN4Em3AEQpM28M*|V=w>&hBBO^a5Dl14F9|~h2(sUAcU8-_js>1Mo zG(cv)IQ{2)&0k`L;w-w~2@W3N7vhaRh9vjb<3UArTyUictpH#?`ZA>{e|l-gUO@Z) zU0Gg9LCL|=_N?Lq&Ww#T+fw3mXkc`_?u`y_5(DB4)5?$HE6VKHbI@(H?AXzF^r1`+ z_Dtvzofuee5L<}|EpUV@Mtroa>Dq)V zWs;M(77`yF(|oq&jwYOYZKwBX&r)JuKtJiTMc#dr4NXgBn4WfaSbDPzWTD0bUheS2 zYtw-6bq|!729b|y5v-qTUHX4KVKWdTbDpCos`5dm1Q>Wu0v(@OmP?t{m<;GVU$bpa z_a=LygW&?fu!aU*Y)JpRa9TB=jwru`mp|$Cg#uKN)-11@uU|WC$OchQi&bVK?Oj>t zSEGu}JGKbZk(1)r@!JJ|(N(Nh?JsVUNGSBDTy=Jqe?dvXYPSId9?-8gXP>llrSfB1 zLa|P#>M|7Nuj(te8DIb!?_bXI|0;}_-&xy==JypQbd7>u?!%E_LumlFaukM2+l*Lf zrKSA+eHJCUmfw(R~{+!#^h+zcruK1A^vv z*BKNSSmFJ$GAOC(=WDz&bp#UCz!ioJ=)Y(cGr#b)tZAwKBjfSQubTUzQ$3O#67vv? z9E(js20T~LL+gM)!f{$o(HuAaL7A`?^~u_#$h?}=U#odp?86p@hIz302qB-7!i%?n{!0P^MHr~z~kHu7NJ*@Blklay1W+H{)2m$xsoQ|^lRy8-T z&y`h&g5S&}gN^t%N;aa2LfobyRAaZf;~73Xj$M2qg3_;l^l|^f3tNyY{EAfnY%9^c zGRsrVU>@FF@%-aE+KZ&H?-^Dd0O%A9vi6tji490|^~CCK`s79GFh~91-@$Z6zC1bh z$M(Mg#%_5S`+pZtL%L-c#24_DO$tPEaUU3AySxv_%Ra%+{fL z0d#$#_Wuu%OjEagir7FW@M(@thLs}~igcpPTj5U8ShkX7-PeDgU6&Mvqm$|ChgUXJ z06}bWEOA3$e@S68SeG@r2m6-x5}(a;`b@86t=<(Ka_WZ3%NFeS_PoANA0rp}=>dSF z{HfLg`Z>mTv;sHWy?)#0mS*+cUI&B`{y0*YkTz4WSF04LCx#U$Jtj9chNABu=lXR3 zzMpO1!aTmBw?8nMg=xg0$EM*gC^#H!2vW>uMTMfTw>8~>}0 z{eR;;?pDizWX1bh!ct9U!?E$Zcqy8cz>FtUb3?~y$bVl(drqxO_r{P89Adx=ZiOeM zJ~bP{ao@g0n$CpzB*ZBdW=tDXyEne(?Tg;w>~U|k`s+X7Nb5-Q)>iLd+nTbROU|)?p+9sN&52oFYrbS~r*ytta{hlo=1+Kpv^5u}j;dY|6sOehv2`T*W z@s|Y=B2Nxi=SO4~`o1Vgv6Bgxh@%RyB&W-SJDANFWCT;^KVmzgMuI%ZJ=+Lv#xF8t zYAyvy!Czqu*&vfjIB+1@!n338pj*{Ww88TRek;~^y~c80fxXVJ>{uu_2`t6D<}NMshiE5>~Lrh<0NK3q83C zXN)!CufM*?S$TV1@IGo@GnxWzhgZCWcx@Zs{&lW7nI{z4=)oD+I;G>~Wu=3kt0jcm z6+6jDH}qv492$sm_U?Jj#&0?=mw*qt()J&;NM=#5@ukqN=`OJ%9O#%h zFXxbGA#%$8OnwJ+_vAC6MG1WE%OA8_=eZV0tNZL0;n0pVeE)J=mQ6{Y5pH+JOOafo z+b->QrmVv%I)d78^fSB95Xj)9>Vd_3Xhk29& z2HiuIA+0>p<^v>t?pVrsrkd{44EFv%;%K~X^_}*3c#TUT_EoJe-;k&&we}`F<3zx- zXEdgS-osUb+Q%OMMr{I!RS%_f{khxrjnn2qekY9Whici#c5>OtG@G(vT;O4+nJ*gX z!tt^zsmD9JtD0>i`-fx#_}=!Zw0H2`w3aLlB_Gev;MGW&mX+2Dh!g#z-vIszt9Vh7 zY@Iomr#@eqrBc(0UrXOFsP1IQN3zmvRaE*rNihOOh!o=c(E8(rHL5~c%gjZdwCc&t$;x_M{M|%SbuLj2|=?i_4U+9ac>u+qlC z$ovZensluz71Q+_K9m_0V5D=rFvLs;grxQ8e194*EjRdtPyIIa)I!KCj^t-nF-90* z_RH`c)XDjVDn%8wj$t7;!P)QeTYgHYnh!AavkV9>b(wc2#l{AO>DVG^gJ5FVp66;x z6mua-3e0|%30?L#-|n@?xMs{|`;wPJ2r*K^lft*nROV)-N@n&CJ5BK!WLNG(r(D1M zLd2fR!54YPy!T;G$~)om2m=NF`mdN4Wycdnxnq#Io6Xx-h|JcZrR#6?Rg))d#$+g> z6wHIy_4L8YA7o@@Iso!~@4aQAywfL%bw;Ke7rv1;lJ0f^Y;M4|2TtNA$-__I)_^mA z_~^{Iy^K9BSBB75 zSkqk2)lX~FiORw+jh$vChBOB+rs9?7^|LFKz0BkWiH!eDLFSjG#WSWvO-#|9n-FhFn+Z6^ zW5Y%aHbD=92EUq)hcSKr&80U!;bj@llgOT}NCL+M)6Qnh6&eWB%9?5IkGa(!#vb1j zQW0Fx_9Ov?yka{9smuCtvW;k;Z(n-{60{?r3;#PMOl$;!Hio7k5>S<6A$K!r5hV7o z)C4`+2dwNLsolF)&_AB8!xzFGX6godya^lUPj^P6KD2A(jRgq}$c{zn?NwI&5nDsG zR-M~2$(T;_cZ0*B*iA#y08aH=|k!RJP zAfKDKzrsp*=@-jrqFEmPDlYVam*=Haw=@wf4Q(dLng#Ik8Nj{~FFFfhSH3J=Uati{ z1xvIr4J;tb=Cg^$7_0kbQTgv#KeIIzeMg^&SL26(ApdOQ{sIR_@pt^`Ljl!oqdCX+ z+OQCVQ(GLLW%XY}OL;x;g0b@A!q(Uos3!#BX<4IuBwUB(b>zT%JK98+kk)Y|+sD}B z<+-)9EV6Lth(7!IJNasbL8*Fas-%kC?|6X+i(-7Xa!^_lV?bBFosdBzX3s=9M_@y> zGbI{Lohfeu8YWfxt_Ajb!8SEA#jo$Zy2<`BKT!S%I2tl0Si}r=Djzo{1?#gb4?6kq zx4+GEn}{GcpEaw=z?_`adbuGrn5BMa+u=n@Zz=D8E~-QfX3s>}#baM-XU;{C{Mq!a zw5G#Y46R(09iySE91Iv;b|qQLOabAu{@{nUkp`~;iVMB&MqS&hJg81b8_gzT>X=i~ zIqC(*&gIW@&uQx&s}SYu0A{MbEQJq&5RR$X z1~NnOecGhmohT8c{#tvLs%7;^49z_tQ%EeVv#4(_0hvom%1|L^_{1LHTvm_Lces@j zX^cxQcq%CxZTJ1rWXS%%ud+Kn4wzr17G07CJqWfiaK;Fu9ESoZ{SRV*I{AT}8&#}7 zFM#G8ediwD2I$~c$c*$u#YS)9D}_ZIaxhbMP%I()Va;3u;CwuK1Ug$8`n9?ZBm)Vq zzj0SygQ=K$BH%8Icc;u6$KS&xXV7+u1_U+07KPW1rAu9-XJhz z*n&ii(jn!zW@zD$SqMc3IC8Z^&DVQAjPVm2GQumc=fco;s#?%m-UYDPC2V1#7hbl9 zWNM44Mj^`5!H6;+q10E}sAH)>WerZn+F!SwRFSS54+5^fK+iAWuo|B36Z1dNH?65z zmc^pU*8y`QeBshexwrf9;Sdg~mYNF8LJZjq8#AIi!yTi1S}O%4FK0h=elgCg_ul#wb=vej-JzNteTzZa?(;C9>dSE-b7O%Cb^T~~wJdb-$E7-@&F(!}>{~Yv~A85X6yP~=hCB7Nz z{=(!;4K(PJ=B`B};tI|1J!$7WBbyJy{0Td?=7QPvc(NMCt^%>-_NW;(eP2MN25WBl zDWOWKyl@l6ISsITEP%-`@lG-qqTv1GS1UwbouV-#C$(uoc**dmO&_A>tJdu~A|ynR znvt6I>>=+Eqj>b`F?qBRV3;1XqbClfshGM7T=uwR{u5DR0oyjGG^Ngg9r^mStQ4SMW8iA1ijuvS*4N8`1AdfznzZ^Cr-H1qCQW47Nr-_Xg(@zgQ8Maw#5@=P3 zVMP}!Ui!2A?4o{l1s#vg1}gc?I_=G-0KsA!FDecD?zm6v&Og-C5V%truo-Cm_=Gp6 zC3voLr%e}L8+ci(oKRO2@J{_xnc^@yFqK*qFDw=}q<~TUA*`vrSh> zoG+}FL$=S?oNa@$$f_z)`YQOPt+gZvIq}y0FsC3S;LK7GC|z*k<#?ov1=OKv)pB6+ zAa|yQa5%59FR~E zm1z`;*o-}mD!`@y(R5rElW&AXP56Xp!-dQr>e?WdcL3jPYMftwNMw*xo4faYr?mxVwyf+)@0$R6{tqCp$xsHp-V zKkkh`+(C-`YWl$dDJ}OgqoYBQ(Y7oo^e0+0{Lm-ECdDp9a1J>|iw@p{(nV&Wr{5xP zI5=QHsFB=0WN<8S%#PtPM4%JPR(L0PxzMz3RQCfW;>1!5nka~$C zPyv#+O_8gIW_$k}`+-O9&(Jx_JHsTD`aU8rSCC#8H*p~DjD(#TpuT()GKkc}6WSF_ zHwa3NE;v!&me|g8Phm7n?Y^>amP|Du48j;wBpk)sdSO{!E4~Gv^oYqyuZN}c{`Uo>8=H^zC6K&F z>Y)7lwDUgDy@3Gtw(AM6oXm3>_*W1LL5-R-25#1;-pQ6$+%T2`>6e9c)R0rfwZ+zc z2mUEyO%`qP2c#Qi%sA$~Q{tA@3x6`X1w%@VU3=P1oC~q>^uX;YDW5rs6zAtGdNisP z00?fMZbmRhL?}6}%X=fKyUE2Y-Y=2L#0meI*PJeNO1< zLbqGASr!dq3PlT$$bc3-*bepS4lpfVBo#$s0fJ9?P|9|`xM4KAg!~xGqYfy9H@$}! zExGk%ZVvAg$(xS6i9Y@Gy%NQU+Ls=8J1J@eWd1Wo`!mgE!r!)=8Urm283ty2h)gcT z24DI9@Pe<j!{}D zBcL?*)?#WpJ+KKUD}q`(&d$RLcQezKmi!zyh|ZX^{8db(fuYuzu6U|IE0PDNxKs#0 zRj;ZaCa6pnMiCZHYpR3f?TgZc<%z=JnyLULvm8mvH`>WtPa)3rLWcGriEKlje?JA* zL}&}BES4039<2^We_YBqc8*44Du*K)PmXwDcZu02QQFjU+5ES`yDI-PmE|m1d+Y)F zh%XOrGs7o#)qat_HWG8TxSfYeq{kMbxcr?K{F^>J06V<1QdoSXn(OlC(K)&w|8ji# zCyUC@RAb^Wz%KGep)^5vc^X(#qR&O}1D2+k_ijcK&NJ9qd?~d9O8>poOuPN&^HKV| z{rf_lA^wRsX55$EYq{@%>y|bZ$W`;1?;H5|U3yqXkAm=fl5igG1R0lV`6LE{09C zeb16R+AqS1o1(Pvd)Y%kbKWDx9p{8PM%1-u$V+B!m}OC>WY`!#E6?W``I;eSa&h`% zr1;M-=+cDt%M`SNuK)q{qR6bhvC}BRE)Q!BJfvZ_t*J-;0LKzN<~!AwnAOb*+wcb~ zv3g69Pu=~Z*PDyz3Wz4Z6g$*RKW%DwZfBS#q5o9@t`K(NeB9qr&K zB62hH5#fx44mnHP0}hq?%S)sz*_GSIc3z%(mahhhQKqBk{KZ&)OPq)q~)RN z#k|9qQyif2A$`HOUx$oDC24*KLQjufH`>UdV_B;)LM=GqHU&JLogbFxcrHKMHAwny zB6j%Xc9wz1iS;`T=?h2}O`g;Dj0++hazane_rE56LnB7Y_e74*Gfwjiv}iig67H-e zf_&X?9~h>7+efMr+$7Zt=k<(Mqfh3`4g^oU+y~K~>n1nVmbCScnT2-fprg zy4BzcH{X$1HL=^gz!r)nCG73z4sitRSZ<|zmPJMys;Bu$`xW^Z`gb*Wom}Rm(m3)> zz!6?h$(8eB8|j3cLt49c^rn|W9giqn#}-$HbhISrMoZ3b7rb6+Kk|UKtNmYZ6@3@ul29F9N1{p=yl?g&+|JBfMoo(y05}`B&3wz z<)PCY-tv;GT&F^H76wCZkVB*~Z(8mp=sLA@@!)n)3b}R=3$*&hiU4TZY?J@D0W1PY zC^q6BRnNb)sO4Mi!AE1*)C1p_bIy2_RS8PZ7isV(hoOnnb8LWP9r(Pqf5XcY8|F&< z>NjX9eU#v+PYvl4V~Sq#H7_U~4KF$L%jKZP{m?T;jO)c$fT#zBqmJiDZ)j-EEEYdkQ8np?kF9}jD~Asy!Ivh`}HDt-;9bz)n!jRdC4 zfE?d`GOd$Xg_X7SM_r(oIi+e^B}GLmsldUn%B069$`{msQk}amV><#jetvC9wvnLn$Yu9ne|o z*P7V`;IpBl-jLBKdCM3?(0cU1-64-`a}9k zzV9MUgh^z=o?)#6vbjYP>jMm}R_(8#BOsz~GC55K1))WxA~Ap+82kP$Xbf$s3%ti*X~b$kXk%Yd+KzVy0rINFgH|fpkt2^*adSL>2Txh?L>5M zzQ2}{73)k`N`rIp)~lq;Rsb2fmO#z@lWTk|fr<8v(?Kh;fPc&}OM>)H9C+q>7rT2f z@lP`N>KH{FPbgP)W{KwX?(an2-z;cJR|{pE9AHh+GC(x79!54RoU%wn&l=&6YIU79 z*P92=^fyy(=X9H0T%QwtfKZAfM6p!2Wi?hbIR>RUXT?Z>s3bdl;W=QiI`@Il=FKX0 zxInYwdJpQY>2-IeNLwjLos&HmJnx|~R14W>rG}F(knVn1H*fA71HX!ezA|H zB$^!gj1IS33pD#eG-S|Qauq$h+JVHE7>$wF0L zcb~iV(%v^@9~(1$)s)d-JYftQxSf^IAThpQRO-?9tL)AQCLpP-UWhfCVFuBl`n1cB zPZm)68OJl6uaRbtLDWFs?79TGm%fTE3#;Q;W0F0o1fhgrdHyItCQ$SJ zQHpTt7ih`gxndcg<&?7qnProFV=Utze-pd6xF|j*$_o(;)_vE?l%Q$+-j$A$$NR)y z5)aSdKn-;TKVfCzkCNhQv%HaDTxz5gkRqH7k#s!qs99p}Z%|ir#gp|U_5epVbT1*1 zY^8_9RnkU5Odgv7qg_hYv@tR;L7io6|F2Zb;y7+ooI9H$i?Mm5XB*AddpHxK)Duv} z7caU&@>19pcrVE`BIjMq)xGg!XKBoATAXcpR*_kwEtUDMA~~gX5X#y7t^De+ZrAEu zS2Lu>Uj>hX`R7P`bu;Y@)X&j@suhY4?cFXuU4J*Ny^Oj3@k1?$@bq9~PN zdBX8vf4(qohs=uMkCnZ^Jvv3&IrAY*0^+%CrcCu78l&jGqs5gXfMRT|PxOAmppCn? z7m1nNuWv<7W7lD zynWFkdzQLI2F}g^Wfr|mce|=P3xN2G=muVKx)NoQ<(*}71*KnKn?+0PcEBQmG_wjl z_CV$-)?M|BbPeA|J9Zmym%m9?u|5Ge5m+sWG^GUseEhBNWrp&Tuc#zV^QUKNVl!G% z(&B^1Ar}HF@y?PFV;O+Rqizm)1aZouf#Z|Pen`NZQk6MM2+A_6##k{_5lq{l`xNDh~4QQ}sOjS%zd zsxx^q9ii6yBEDyYXJrh^g8$}HQ7RBd%2YlhNXdEdX`L{w`s6NIFMo!2zB2ys`V8Pt z^PZZxoeY%r-9U_7!pPV_O?C8?{|;>x(-_n&ZvQu1#F~1-+ch^gO1fS2M900{hH86r z&^Nm(17p!1{&wt}LxEU^bAr=!9_elo!sT_g!%Q!)3^Z@DazOo<`7YO~teH#gI#E(` zAmX4zAcxW%p(B(t$x6uKk;7ut zs65YSOC!P3-j~&s{MB1!qOQo>lRoC2Q)#7R+(W)7X}5sZTo{d(_smKS#NBn~-z<|k zX+M5{2Ui!cQzU~hAjS3FSz5&teOdU?8@^5-e>E%n3- zIdxO*M&l}*1gqAI!ZpsA40pY%+)nsRqqF9j;=>^7=*J(-th%6W9#*M#t#T@zuoe?B z8<*WIU2#frI-R#A1>WTiRyTSX%Yl=FT4VCa>kivUtA|NM~ih+Ah+q{!?y{d6x2^Z4mSb zm#5<#hm^3KbD!zZ>uZ(KAgRU{tc!I;secR{B^o(#)|uCP?eee{>%4Z(7FJ8aC(GF) zCdAOKGsE0NSo=<|J!h;?qaY#i>)Kf@JyY~o1loB3gCuki zKLFCrWvit!r}x`s$<~SmjY-9Q_3h9e?zTd8heS{xH$Ka2Y+)jx8xLJQeds%P{+CsS z|H;G@eH{i_elq{--}R0qUoZx5z69W|aykNN{L-iG z8t&vN)i|I^+jIVPccR(BUn=lAz8Jw}6Z=Z9$FH%&@B^&v?xLTMe4@_!&o-&Oj*GUa zpf4i3>QH0cyMwW-cCj&Bb+^m=W0nQ_4bW27pX9tpG_3Qwb7eA01OkXvkxb{0Xzk$}NDM}xW+%mt;cA7F^HLtGc z|CV!Bw+Zxh$^zC#=;}fk@BuWycal@9C!n*R0X^%_+cgBzPM5vmwX;3h!SMYI;wDqy z;SAueSm4=2%gufIhT|)iLk(SU&yX{|a>#r6*S3Fz`9w!#GZJzZYMhG1f9eag; z%VOC5F>8q5HpCzG0Vx5UYi8k2$trzeRM;?nbfvp7NwOk7*!XTwdq1iaI@ZGLvUR~8q zlq%mM?RUWFYBt`&$S(AxiwS!@k9M9a`r(PVl`kf$t?wQ^g8hu%%q59m=eQA z4(>auS1q`^%h3o&{BUFle~I#Nr1)Ks@u?vgL1LbbDEf#d_T{XE>_cF|>(T-ycD3p| zt?K9rt5TbZFjaE76Zf0Zu7a7SYI6>K6{VunY0()riSF6kjjla(izBqBdotE<{Np^c zW=Z?)95Imu#lBMAa-Uxo$qmovb82i%>w{#YWpWN z#m>@Yl}SwX>+?b3v5ynwb7EwR(%fDLw#skbN73a5Gj|{(R=1n;9M4qa3d~9wo1K3y z!7%vEdfEl=^jYfyA<(F8J{7C1g{o=1g9Y{&aX2}Ca%0Ryl)rliC>B=djSkK{zWPnn zhOMv}FtceW3TLQvPTm)b0-8(>vqUr?iW#xvE(U8gZe|(yW5qJ(p^IgaNmWH9 zY{VI@wjNfwS*51KENp+S*wxz<^E|=i*^Jdh^~2K-S^#70kA z8IrvZtl+h$b64-8UPs~meNofib*F?dDa|qp zj>AvffpiSr;*}bH3cm)xdA6dQdh~d;O3AXsMkl!p>njKF$?W^-FTANJ2b$7D^d_s2 zElhg=5ydP)&Q@y*N}bj(o;gNeqlq` zhiT$&$vwVC6-DUXAA}mVug8q6yZ(hC&q(gt=g*A_ZX$;teFVpS?!<%^9MkHWisMd| zh7W_7;E&?@(PMC3=)}9Ao)y7sBKg>DN(+OZd;E^-Qs#-wNV5cBPvl5dLz@$d@gHf8sVn41(UogkZmhA+uw?Vo0OD}{9V>#~JMe5$F_F$HL}Y$HqS2(b@6m zo>YM!$k(UozF;;!1O5<#iy51T4+~>UaomzY$@>SblQvceEQiru|Vj(75A?Q^#4 zH1|z$_*!FB{~oHDj;Xf#!{qgd*|EfXrB4!m?tT5m?*}Mw4h#W0`O+cLsN9(`%U;(UKo^i%YRMFBRZ7<<(pUUuYBx>|6J+G=OAvjL)Hggs zXu`K}(p^kFdVlC8CN947^o@)xNnhr#$jCeOv=5jX+iLJImOvDHx9+jmGdgb^t%#mD zEbD7Zu15CtT-zY;d~?N~(KRJ+#h*)ZImSX-_UqH4pizPqPV4lSv@)*?qlJB)o)a>8 zM%_Rg+yQUd3aV++ zQLGZ=1B<&WOJ?%}I`8&*%*^|5ufbDY@dpDZ2eh1>GHT8Hx8N&PtLyJnJ|@^ncT~vs zAck50%^x-afRz{Dw&ps6qa+&rm;g?Ru+Jyv5m*I-}a zDeZisG=*0?iY}*JZdq$7?0IE12E-VFujq){86Xpas90ht3k!?Wbn~3!`);$vg`a?Z zm2;+!JMH@TpXj&eT^fSu(TdY*i!s4unSp{9_6O3d zHn92W_s5=&-Qy_S`v1{(o?%U8>)W@24X~pipku*~N|P=|Wdvy=f>aeDAidWRQ2`YJ zJ0gTCMLN=?1XKo4k=|=WN+6U_5=tP+yY>!&pfhvMxvuyBjSnQ*W$m@sdY<2X-$wo& zmn;pH5VJgk?UcN%!3t9p)e`N{3i2cBrFQKAk0@3klAmT>^iawves5$`IjG1t9&rvv z^*YPi^r68@FZN`8-HG=RS2MUoCmrCyZB~}x2uZ0XseZgEp>#Q_QH*luw6|}dn3aQk z7;-{5r0DxKsc@_B6K1HLs5OE6zuLUB*fJLSMD|!;1Gn(h&7Xr?ir4p**^50brhzD9UXz); zh}0WvGvbe953IJFy3sn3meI1eG|zXCJogkIJJgZ}$qf{SOOp<7@b z-5XwhjC1DxjcsZ69KU2JJaPi)c^Y9a5>-YVFqagsU&+fU4`!ou?VuuhX^sH>WYIg) zL3U1>$Y@oCe~6O8sHvOBRt|o9v(eMfeEj!Pm3UTh$;=-qpnra=zDTOS2SFt^w9_32 z1)}qNuj1RgOIs>RjJn_Z9~bEOU`ZHBmQ0(HO`UDV21%KNM$)qJwZ(@eZBx8KS(j0H z@QmXmvu_@bYahA`L_?M5u=3syC}Lp+6rUs99tr91NHQfw+3uvCoeGT;dw9kN6>6TK zMK})I52)3B#7(ErpOWxvp7GyE##}2*KrE?!Fyb0EyS}NM;&bSBuWk8RcEe&UkuOKv zZRiqh2eu*Ep;OKvG0-Y(?9%YVZRIK*x`m1Z&ZhC`BOGL~mto%>?g;MjeM>&3RdhN| zg^w^L*s7Y_vidS;Cc@Na?{kM}_bGp^uu(354&$@x9?MU(DTm02hz#tHuB?dt25I_bzWtW6BV}c&h45Nr@K>Pgl(xJO6MTay8F0YO4%( zaxr~Xk#Q|Ixhk`=GRg~m0COp$|NEPZ;lV5m*+mLeIu~qJ%fsx8 z^_SYH)56F|`@!s*-1iut(P0OpR?z=wu(Zz<5}wI!H)+EpT4!9###))T-Ij8;Eb3i} zlqKqK-4CqpI%WZVs~0yPJMh_)A|B2F0!EB>+JJx`Qh+a=1~JyO$t-e1_S>&e=$W|%zw_+j4X^sRhgEl-Rrpe6Br3k#RNcX$gojXe=d!wo`@8G zPN#5K%XJyfy^1334-#_D;tp%I={FEQC2eMhazmwJo^dtA=>#c9*Ll9L_`WaieH}Mj z$sudsB+(M^2T>@S-HGsHZ1ihDl791wJw~>5o)x zP7@`0f7$VxD<)=7OG{~$0}*Mv%pd)te|3@k2T3YEcl@M2*^Vb(Cc7`p(bep{^=)?S zRL%Iq(lq^^p~zsW_xDC8|I;~b97I=7!h;qm%Sp4U>7e1=Z(Ibty2h}2bU)d=Y zeqxxXGkUZc>-ru(l&O#AIbM{6a)=OmNbw1Oi`8m(>AkznQv={j>Xd->a!$C_!J;{F z?bjJbbdZz0iyYFxdxljFve3ET}? zjA)A>4BPfZ7UFnP==N6`&R`l4t!A*tCG}oMNWME#nWZ1O?BFXu*< zb&(nf{m4=M;Y;x}|G)s?A0JkRj^EAu2R22(`py!+Ax&$6P5gu-VxgK5Jm6G+ITA$Y zvV2yRk3vHma+h?ymc{ABGopIzlyf~lY>&WSo_DT^=qMvzy*`3xD{S%#4tbA}FNIS? zdQC#tJfZ!i797Ub81Cyt$M}%zs+=U)_XV<+)wB+;-9?D@zc{F)#oKAUQsx=#hPxv! zCmMnkF|mVFl8aFkx2UNeLKbhS?Hk$~cQ3SQq?%|0O99&Ccy41*!#Nt~- zUEoR?LZQHX)Ygl!>EgNbE$JIB6(4E2z+zgP3X#4WB=z~%L1}>rJ@b0hsK@RrZQ})A z`!L|GMF(Z@-H%T7@Amx+5Bvo!5U>v;Zsa4d$9A!pA78&>2LJmWfKEfsX9s~xrmgiS zPV!J2F=xp)L$MLiZBlRDYh$gFufP6qy^I_qgX>^-=ibxx8P-KOp33>M8B`^|*?t?y zYt>)K#`)PRDm()SIMZLmxIJW-$kGqYNAe^=FswRTaM-T?y^7EeFeEhRcTOGuY52mj z+L{9iWId$=``{kJBU?8q=^zc1TxEh& z!!`H}&Wj#_T_)qoIk>_?fqEH37;gj3tSzK`((1WDT!dR~uL*0lk}=ecs|RwdrK3h> zm{d@rC?+I0f)fI`xU2a`zsXkA{{S!fDRm^hIgl z<5MF-rJUq1VGd)(kltgyb)=d4ZdMb%W?T9Cw?GI*f(cNseWG7N3BtadPCsXuxQlTT zG)!ggLQA(!u+0QHdG_CSyg{IfM5UQoHw#7$3<<^>s#x{j1)oNV-re6KJ*~ToFyIWH zaZa+8|*?-f9-wF4RR~~})S&rrb z^IrWsG>NBcgCh-~*&Payy2kDXpU}=R^SHI`XQk}4ygMeS3*J>18l)<(2mtvOP@}`L zuD<(5$cZ6>xaSx?h#{|0f_{l|7sB}UN7LOwu4f;@QwzVQ{cN3e)297HVMJz+k)2z2 z4*yIjS?+7YZ8^&!GjB)%sfPb^QDahR8C_?5{#CG0$LM4?k;KrL;k79bXH|efXrcob zRk>9dd|=4AD5#`wfaWh1|jY%2a$Q$30hT zF4fiCE3JGi3BqZ~i7lN^Q*ky8UsYiZ_}0~xu4q?c(%0wXIj4iDz^92DD28}cSut%8 zPjoXVq#7CmP>F_-k$FHDuZKAvD;J?~gb+QWW#!iNS($bXex>Zd(}!g;e21!eG3h~d zeS=dR<3dr)l^2{+Htd)05U;S&%w^Z2#1O2MUOA=4$Q`+TV77_3^JEdZC>7QPgvFqp z=>;B{w5x8@Cg#KFNXPiGzr5xTaNeCEpPuqi3K~qnFk?PK#J$=I*|=k{5Ysl)Ru{*K znu4&!ayj_z&2Bp*I;HA%o6_$ZTwy>2b2`U3k`m{_BD1m$6%y=I!`Xv5g+)~eDFH6O zvA5#pn0CH~w9X37B}2Q~a8O#whlGoi`+l;X#1+p&Vnl+E#<-t9`9**b{tSNdptWQC zo3fc^GDJZmoG-W+;c8@J3bEC5+~X{_z`ZP(!yN-L!~uBOI$ z-6}*Uh_W0e|7oW!=J8F7a1k?FwBL+ECzEix1E2I88?K@TF+eU;1-$`L-v?=ZWeSbv zeR?6tRNGPv(jT>2c~1lFM)4ALFI1tiGuwh({BqdY7*tzlGusHESYhG5#+o@q0uY`vsDmOiItM9bJ)E1P88)y z2>#0)|9koklVL7}qP0Iq%~(q%zFVV_iMz*yWyKL96~OGT^@t zC3F4aMd2hFfk3UhglsdLmVXzWkl`YU5DLf|-fs17|s7aS7!7LZdJ zb|xrpOFyUQUB{7gI;yeeRU3r-wqR2nyWCn1GsQg6D*zv$uN{LxZHUd#@KZtkk7z8sK56)I#=gIZ` zdGhG?6+5+hMPTMpP}=~yU>bY`uGnFp^$DctMxK8p zG_8ou{*rhxU30T$=Rj@55e|B#abTlG;f-74DI7U^u6+{*iC`w0=rbnr);E}LJMkb{bNhZ_t(3-!tjb-=2#@YUw-cWo&$#4SF1*cIebZQw zfr0SaNZOfJs}H{j|9&$>_Ae+x_RHyFL__=>J5*2@2qXkA3gkYYFzI8 zy^80V6DRYurHxNbz5Qygs-uBEP%cb4d!s5F#9zCOCCY9y){}tcrSD9T#?jABaxF;v z9eJuPjn3p`Bts0m$J->SiKzp};;n9Py4O7$6;vPuazLnhlW*De@tt*@y3 z-u%?jS?W^7 zA0qddPh2~0kEm?fNh;AB!;B6z_6nQ!hgpSU%rKEu6SfYQSgAqNtP&epY-EOsPH};L z-gK@KC~`o8YUaE5Zj8kkO(e}YlzbB!E z)1x8sb|G>>4Tp{=o=5MxPvHG_s&0FKEhR=!ceZx-7Y!wHs(|NhUeQjdQ&b~E6%0AOejk+hE97)`ZW`d zVj3VV-sj2s`}~Bm$gY>ny`p?oN5ro#l1rwnldx3>qoBkBS}QW08UJOpAO3XxiH{qd z@6EZ=cU_i{{sJU5xs9`JTfQXh0$79pb0hSB4O8q_uZ63VFb23JM|nP|iSs#dDfle{ zcUuA%L#v+z;agf@PxnhgCX+DcAyiBXnjvHo{+4HjJ>?b^C2-R1yN&A>lI|B_hTQV9 z;|K;m;1yuV2+{z(ZHiOwwf>Owzi^s3|p8}UyVyjs%cb=}D>L)Jp zB@M}1o2^WXe(=bFN)mKz@WaQjF8J@w?HA){K0cfE8da+jiHYOopRWbN1#xB>^p{cl zZ&^0~!Pb8Mf;R+W`%jpm)nD}w_{_UqEH=Rzd@IPJ`}+*yHQo(Sm;>Z(x@af$Th`4N z1JWjTE;6-o^cVBI#YF7iJoo>@XsBTg2{DKmD;LC~&S!D|4qJ0v zW=UpP6nKDS7O$>|`5$7I3K{tkl0VFl?Q#7mk4}lH*SH3L@I=`$B7y!nxlQO9ldN8h zW^KF49`;s&9+WLd$Vorv_xuPWpq=Qrvg9@6hi#Tlg_=Li%)bxgD8pOOvpDqZUlQc+ z7{z?qOZRBWnE@iJ4xKZqJIr;tD@L6%{D&{omIkD-vj%@aDXOeFn#vdLE0bg1)4t`+ zIg&ALeJOJvgRO;KCy&uZ(zrc2e(^oOaVH|U;Oxvj@2+RteiJuJN%FAdUG>#VtRSNxV5#MnRn zqEt11vIy;D0Q*UYM$a{qqJBdB3_XMrgHnpCZ$;lCNqm(*_e)x$)5B`568R^f9XcocL;1jjNu~5Xvq+4ENw3P+7UUMQr)YC zbP{?42Wj@se2WX%VbAOR!E0(aw#*A0ah2s{T`B)7Thk9qU#N%P+%M7)=$N;vGEQF86+J`nzyBU#6W67f{P6!x;Jedox$q z(Y!ry;GOP(fnC$vi}_j|4&)=@6RLtW(?ELUJY7+_$@08T_}zrepzHtxp%52qJR4q$ z{18DsEush3bMw9^kO=b9DKk{O+!MIDze#GqgHYw&-TQ#HfeUVDmZfzY(h?W0w zTtqEs4E-jPU+DBM$)CL=>lCme>6qtnT6X*Ewho)Z+YJJktPZ)h?N1_QTYWP5S8GO0 zPIdtJ0L0vH-eM6S=&-e6hF;+364=MRTE}1wQ?OdvBzpb;^bnxWP!W? zZE3k^;%pCuynPZpX=qbEjUS zS##NU*If}`!UM9OSnfmVyzTOE7pr5>cCri}?ekzBf92)zp zJGEXPl@qj|++{Qnc(Mx@R3ryQ;+@$gwfw)^Zze9hsWpe$8LR=W+%?S_=vx?Fiaf_p~SW){uR;g@as2-Jg{)v2od z`WE`AwS2Mr9ejkMLMqH=J!4`yxfk9N)x1~!DMhM}3he84P4KzsmN&LfcGfioRZYsi z1Q(`=d12sO9w3~{@vuAN>&83n_kQ+d07uZ81jZ%^@XPP?tk4|fJ&y!Bf-SjpUk7`v z#f*Daiz90&n}yz8sN$Dmn}6$pAmD#VM05CHz|%Zcdwq1bOhi{lQl;q~f#6f5ZcU02&`M*>Dke_$a@%}41J$gH}=FK zD?=@kWM1kxJ`x?-O3}VFd1_~UdZI@=Lu2*vHrr0X{Q;T|jOc|fnF(t!%cFJV?Zx@F zlSq;Nl&s2>lVXNSQbZ~1vYlMVbxrJrcz3k&5K3qPRq1|F&`u}k&}(f3^@E7?F_C#o zCa__?sG!LIJyN!`wo2wi&ef{z#-+!P7bdD&zHPu5`(yg{?~gZXdfL4m(hRapw)cUu zM!pt~W`#Nz`YgHcZyN`{ui+Tw9ni_PcB#_OK7c!E#6fBLb8<77ck*q9bO18EKZ>aR z>93uHvY0MbJ(9BI)$zZ02?#yl#$(_@iCj(Ap}QLDzDessiE!^syJ&pqY}Kj@y+VW z4;oVf(@KA^$3>S7FJpF#8J)9vbBg&1e)#H$Q(Yz5VbDM$#RMxlqa!TohD#QZoo%@s zec#k9J{6KZwBE1=trw+pxU}n|z7&4*Y1*o7iyLppf?IrqM4K`CHRp4(w^iSAwT?B` zhEfQH1rDgP z)mPc1se|SlCugwk<<*P)gfMew0)x29H5i*ZT<>Ey} zx|?g%Gd^<7*uTTs&voC#c^FxC3%82Z*q@cXp}o3CZ|}U&d%ocp!pJjj+MP08WJ!wb zROHI8=A?Hx<%h`<2QlSnw{rGMkHS5gl8UuzLc65aUR^HL#G1PB^X?}w*JO6BhWs*D z05dkp`ao_xx{o%XVg9_YCXTejXs`^pS~xcHD~Z#MLLJL$cb^EnRj1^5r(a@E_=%(y zjwu6-O*PACKKF9)`vfp4B4teuS87Oa<-D=bZ}n!2xc2d~n_)JM((>V{ zKg*2x1;hO%IEF~)#W;vo#V@cZ1ZpL676%V^K~gU;>L;ffB0bNJ9T8|d z;W+yik8C)A7a8KJuqCa&BT8z1eXX+jCdLR8q7=7ACf0H=pmiz;)drEuObfRXBm8(r z$#p9}4t%3kWF#sv%Zc}8YxC642!pEO>{grXVNq4gT=Q-kLh0M5Rlbz|i!Yr#*)`3C zEa%&u)hD6L)qksaN&(VY*r?k@q;irK@BeIa4KN`GZ7_CnvT9edsHk{BHE-W%U3cwu)rD4t3u-Z}tt)TKvB3S?a3{q}1ah!D zN+(LQJ5;K+-J2295O32r$u<@VZQCi^QOK`uthVhMa(@B$i_b-Kas&~05D1}DF* zKRR+H)f1?Gs_$);tY7bt*Cq4^qm8w8hM<;u#|6^S+0Q(_=B|%=mELmWKo!@!ZHb8j z1PiA%sN-BG8*8(rUI3Vt6sm&nk0h0Rj3ll8?2za7v~-uE;7BCN8ar(mIut;l$3-D>b0K4ej+JyMi+zFlFpVgSUc%Uo;JG&?xt@2&;PAB^=$AF>ScP zr@ve7-toJ|l|BBrKW-^^`>mv$jl3_ry(Dng%hUEdQ1a@u_@|=6rta|`mke!A7t>QY z8yg-KCH}}M-At7h4|nkKF-CGxwB)DUXVzc??RI3RsE|cGiyt|PT;|QerWbh~qj^P@ z28L8?lq@rFljM1y+@cidRO=#p^VF=xtNeE3lE9Q6N923_7xR6>(NdP!Z1?(lXMdG% z2Cu_<-JL+0pOeb1^wI!{Qxl+m-}c~c+F8$Q?yv(fFbCoz>;yJ;ns50M8v%TAu;0OSO6F}EF7XpjnUFo{nE|K)WXFr9#G`f?p+KUVj+>o*a7mU5Q?!VOEf z%f0ttdWri9(Gkp}AwyriWTT*kz_v9yfI?lKz(KAlee0N<$U)2jnVlj|p|@dM(v&^8 zLG9H9v3HAaMECoXz7$iV+PuaFpQ-LMT+kvp;w*!ogufl4W3}Gvd*| zV^$Yr-OaSa&ubHePeFDZ8^D6@-i5Wl@OG)p6ctZAW0cow!}Q~Zrk^#3uRvgq+v*vE zvctdAlsZM#t!ja{UF7(^7mF$9y^-gi1y6eq72HRfJHtz zXZWH+!8;`qqMR9qLr+8@)7Nji>mV}xVIE!q-lBqU4meRib-j4jGD2Z9oC6LJZ!qGv z#+XNpID)m9!$)ybuLS314>pkhl|bH=rp)O0z_I2L1ip=+VwY^LZwWub5ZN^k)nZpb z11#khFKeFk%5$Hq>U{@p7pn_w^;vQ!;BiA*#~cTK@l2C>%Re^mAhcPWCLG+&PWc-q z(_lH1Uf;BBak&DRTpO4so=q2ILBpYI3@#6#Y+2Z^Z!UAq*74RET`;0q`*a_(7qW<+ zsxks@*#R2-CoPzgQbdJ0SEljB;y*6%g3I~(*FW>2c$v9;WV&L(Qxk(Djl;3I?PK;M zR!UcMKR{4FiY&04a5rZGPL|^&#m{=q^Cs%0ScC%v4=q;bI_Fjy4 z_go0J9kHC`V8xl4Mp(PeVIovM7KXkZs{$ADiLqR>+{U~l-Qt~XtPK_BGXbpQFM@dL z?a&5>DsL2zt8;N##yA7ZP?fvPc?ZV(P=TzClqs$*BJ|XQ?`54nn1FYf1{CM(SjElo zu1u}{@gtJo>8``npRp_s3ID(xR}*W+cSzMoyWO>L`em|V(CGn;BLN;QAeSB`@+)%; z8asZc;48up7N1Z{1KNv%GrTyBBuHK4X4q&tf<+qRJ}j`rP}u`w!lEC~at}e6B6iu( zUla31XY0D=;JFTNdRkZ*y6MRJtP1l)b{gCP`#B``#2RS4c@@8fZiZi@e1P|;| z4xS#a#QdSlM#F9WvW}aQ{deMbQ!FEdmc86H^%5@f-AU&pZ(882G_B>!%PNO$D{1bp zT2eWidYxqjOY8!1OQJZ?e{(TWu&M^G6VlNAmVuF+YO z8|hbe)jtOEHWeU|S;**Ef9kk}JwT5xFkST3$lD#Jno9K4g;pK!j>#}N z#4(l{y~i^aoxlSZ2H>H3%OfJ0lgz&;v)CLwomo_{q z>XF=!n=lNmz+DeT$#kq&A*nhBgaOVPa(}nQG5RQ9PTxvI$bbbs)0=OqKYc>ZkFMcn zgESe|Cr4WJRunn@EFE`+UX0;~e5P;Y54Il_S2CNBMpj5PHeY-w{t#XaFBVq!46c={ zpIVZ!0dGwRha<@t zxU1S+$yNI=-!(GYLlI4Qt-4W~&YKefLSaU!<7SN0V0fqjB)8jU=)eeA_&LeH?XqQ2 zszCi#Fp(b4(nDSdb(D)!a5l-s9!WJ$G|Zj3&;IIIbl^L1Cs*7UFiZ{$!DsD1Zm-lY zImh$nfaw$Qy1Ba9>q5Qnnx?PrtasN>gr@<37G4i6+!6A6DF_a?r4t_YO5z_CS+-B=%cQwJAs(UJW$v+a|Y4aRt?qLz~3 zUik+))l#9`%;H3S@YBnDe_95}#B9~h_wk`-hUG1nx2`PgQj=H zogQZNC6xwNpGz$sKmSJaV+wJ;(81U`Fl~eEE&@`U2q*NeddWKlEd!a=WrnxcsxSwW zl~m+0869)wNsXXf_Hhe`;ff-Af^f_kFs9|;m;7h1&WhWldmj z9Zfb6;<^Ld+^{@x3IQFUHVPK(OlLwyqBMMp@;$(=faJo9y53mFVVnG}O*EyivClQT zub_-uHVS=GOZ~-IPeD#8j7=Yin>=+ik+l>bA^*WwU=Sb=l{TQ! z%}BkGaTo$@H@JHYrS)R5k-5-6{bTLz8BU`P)#Qvp)4@GD=#kqq2&by*dr)ocq7cv! zzWeJueOAukvOt)}UB{WRMq|NhNBpWh{$p=-XD&L3hYuJJtB<)|+ju1go9PI>9F{gB z70vF+F@bD(&=q=dar}sDA~@zp zxBL25tO#l1uFf*@vUT!`ZjjXQz@t>&5l&$3u$RC)95U8m_Dv3%-ID?HhwthuDMLpX z_Q6ZMf1E#nbhYD@H7Pl{?ys#{dHbg=BY3BL3SL>hzBRNLDVJ@N$Vq*4>da|m5RHtk zv~`+3-97H=YJ#sRbami6U8$`w+dkIViYRb9x@8VDhC%e$?jcT{x>9DKbT4K8cl{kz0>EI@MV)ZiEYw zL^*sr8GAKE%h}1mq}^768d)`1aMLtSbv7N$qz0bLYRs228Xo@){Jl&7NcrG#7Nndt z2V!ZEv(v{9(_{P^b1s1`ghv7swkCsqZH;-y4v6ats(uyo=*GkiMW7x z%aq9&%<7ULd6V_bGbBhYA%l-Y5IO3tPWE~#iM9$vdeG%Mxh^2&p>)qL$91dirzGXQ zp%xGGSx@BKQ4mS97pdn0jXKC(WNAbObLG#%USNRrKpFLoG=y zv%hZ#MVjyYJ&HQb_{Qr%`_?$=sI&S97QE5GdUx?yrTD5NWxYAYJT@#6^H4E{`QO#W z;s*~~@=~YPnh!rGO&`+r*z_b{&=mJPw<7GlEA2GLnW_!E`NvYZtn(pScqZuZw+~~4 zBDd?MnP17*8iR`mbB{Fc#W*U6_&AvRkxeCik#!QNRUI>?PjZCDgp%1NmYb99odK_( z3=w&7(fk*vzXL%1LN#4J#J!82*zJM>uTW4g1WHYX*f5B<*dOv(vOD|f$j-b73*knq z=$z>d*eCpTvdElmhO15kGvHiGc4VHbk3pLK_*;)M@b<+N-cft8na;IeSs*O5;-Jrj zw0MRc(&So*fQq4BWt7I4O{-jajgcgdGj76sdq*kHZ2wqVj>Hazivn~0jTJoq0x@ueKRgiI7E0G`$E^Mca_*D<(7apfzmP~?Zypp&+dbM1vOeL50jFV*jN z4^yAY=Me1ns;8=^VlO#zXG)mz&i6C*?QaG|Y`E&UU4_kE$C_2*jKuGai1^kda>j61 zMs({Bg;*sY^C9ibMCVx!<&<<+Ml*23e`{NHYf9GJpO8sx9c42+ki6x;Al%^2V5_wt z$4d#0hgG%3n?SNV8{Vm=!79h`RpFmD(IOUBIs2lPXHE~xyFY5GzJ4*#visyf$gE{y zd0x`=`ma8hrer{qPP6J;8T(Cr)V^q;vvVdJ@jjD1GySh|1|qj^Yv?D-mRPgdx(+{S zZwSUk+&q8`4xaqkEp06uEA)UTa6q}vyxcJ4&)G?t*t(2S(ySlxPCk#B*+wA)-RTcz znKHp|+z(ndt?SV40XAf{obH3b@{gg)2ga>Xe~B?P?}kY^*}mi??|B{O7}fRgzdQf= z&_F1qUh>#tX=;%N_!shyl<9a+xE|^0UH#4n!7360Y6~^gMpz))7nc8J+c{_i!s@?& zAVqb~v4|wd&A_paN&XNWH$B1b5R?>#&50pyZAlIR%g6FPhM+Ais~zdTn9v3=VnTLk z@+ej53$6d-TZ(wR6aY=y0QG-XRGOf>0Gch-_s(GXu<|U22B0KJ7|Vb$m#i_=za698QG}~zWfm<>ygEl{7<3u6E%*&dBx}J^yI(uzMZE<01wQ<6-GTSW>wF# zc>3OBgt>8jB)<=HocXyNxOQ>16p#(+SKoDQQcL##-wzmE(yO~o7n`~NivQ@#IsqB( zcUfZv>b=4;`gDa2R&UE%kpt8nnRTO&pqd@@MY|6C!(jVc2+%8mn^m&>w_K?7nX;5u zO}Zgo?ytwotS>0k7Ab;XO>S8|ELyM`7EAvR-liZ|kY)P*JE~{7^g=DnDb@a(m^K1i zE*OK2R4hxU`sDb-;)Zy)CHA>2X1@zQ-fTl`4PxNvU^iRHclkg1(rVuIDj&YXLAJW$ ziRf+~&Hn!Zr_bXNey2D!SV#osGHa9O&D_ezoQ+lW`DS~^B0WQa`~CbOLtvg7$D{v? zA$2=aPm4Db*e+|#06!%T>$SfV3-g2WKaHhd>GAWM<0XbILH|MsG8CFf*$8AjL!boj5V%a*emXLoLNLT)LJpRThLvT2wM)18EVEoUwD>;dF#c5I= z*u^^wb9y4;eR7(ID)#_K-YXUQw6wRISgX+g30P(-VIi?9Wc~sAAWL>ywHLltayAp+ z;dF5_PVow&1^y<2TR?LgNcj6?XVR*}sxH4Xbjo%8MkE})dBd((-h1x-bId_#J=JAh!xSGBaZG zy~k4=37Y@&xT89&54qvn<3dGKrEU^?qP3`F<>;5$MI+(If;NI_dZ`uo;TIOeVO}#T z*kd&N3en^FNE$`5>BX3p%L`V_T*RQ4F!J7-KJt}zv$+RyEnXx1hR)qRq}%^_#zgX| z$xK}BM&K`T=QM`NqxUe^U3nawtQ z%gs}{B(i?HdX2_$E-vz{JybZ0t;9?y)*7B$N%I!zFM3w__9AWI9%PWraC^ibw*#iz z%->rY$n<30%VLKO^>LZg{D?A6q-Rn`IvgVx(T84;urnP~0%z zweCJ#a}7uM4|ocvYu!yiaL7GaQqO52zH{=StaPnI5-~5E4q#L*KRiehdh0iFD3Y#u zFopr9Q>L38xBgdD-ABT3XuACfGP8Z;k-VoJ4Wmhv%dZtO2MLwGtvcS{>y;(GM_d(> znq3V{NQdYcilC`PluKyi5&4EsK7o4}_9~!+13lzJQx1aQKy#;`4{|zcv>&--RhdzW z^>M-|Ab-9Xzs8?U$Q198q&f{TT3)}%wCD4bAlCqp3A+lgy=*Y7+NlVxZ(WjbWv5wk zZlcKqv7OSDAwG?l{49@z7KUg&RQlNd?J6z>B{=v_^uYXIJgDp$hBCTvT%(116;rR8w3?E zpf{K#Q)0c&A)_m7LG}ReyCN=r$ytw}dTlN8A7B^KcYpK_iLbGte`^o6kAL>OY);Q} zc|wVP!Iy1sW6ods?H+Dsu5FhVcpkv0ZK;2GxNnYJG}($rg0|Owq_SxQHA4j&{}h_l zC<=(MxK__YK8@~t*Ye^DXOVa@PetR6ApC>=6EBcgrjzlP^@V<`V&3`o2RD@c2F*?r zB$o~3Jy5hEaFpP}TqGa0EpdGlvfp9+lw646a_kq;`Pg5e!(a-+wmXb9$AIWp_$7PT zw}DrrQxSc&?s?+C&w|#x8e+#}8D3UjR@C#OFNJkN&4j}0+ATkHS5?VWT9aieB5CWn zI&b)+l5w|o_%b8`iz`vho&kfM1Vq6|1{Z&DE=A%%c~xX~I088#;lPwPSs0X z78U5kut@Wfj;*%NCLLUZSvC1us5Egj&eK%|k`uptCIM zIQNDdpmh&+h-&%`!1Qq{Mo1Y=>M+I^7PJ%4le`203Xi3JpE%d`IiAYBjItfuC|iRy z;EaDNI3GY}JvU7;yhJp8=xDVTLqXQg7|?o`bd8ppUoGxu=11lEe6pnQ*_E?ZW|nhn zI9if++U=Dicnd_nTX8EsaPmV%_tol=^yg5_5UO(|1-g1+jOT@$f9{ke?G3Iy@Hgp1 zu<5Ba;P}de@>?_7Je_V{6_4vZV0bRy^hb_glJNQgjgxu_hifO(w_JG$w4J}`x>nQO>&9opH>qXw*9s|-e#y(9?<`j6Hb*K zlnyz$DM!x?VhcK+F4*c3ha){kKuQ`GrQEme-}vey!=k6jZx9L3JPs3-dz+n}jUj>re@L|bzw<<^Wz zcA`7^c=FI(%m-eC3tKo{BN_`Nx^Ek3$IkL;T^N z3hEWd=X1p-mT{3*Z?TNW!vS#_7m%S(T0EWtk7X;`!_3)zxA70zslDylftZNfW6k@w zEO^T3My}ld+kpziM-0bVT6wB)p|8$OUji;JKk=R6A)1CcprPYO{HAIuDK>wo4EYJ* zrOp;sQV03ao+Ic9U6d;PW*3O@=X$C8G$87Y{>J(B=vte5z(AsJPIb<-uji{qKpb!B z-S*z~;C}Z%*PJ`wQD^!?E_2-Wh-r88{zZWnI7sE+rK-?drE7I%u8f0a%cW=IWyVSR z;kr4pI9Kt?}FV;6v zso=(=0_Wd6O+~ooIqNx-*JEZM3|+Ms^&y%EwS3)naii@zdfNLYI@C~wwy$Vg5on_y z))sXi}Vd9mA?LPs9s7|4{p6h7taS0+LI>eF6K##E&k0vf!- zAlc!GA_D88@zLEOTJwKD zEvk2yMV3)w2MAlaR|d1yH?j-y+LCM&{U)T#d2_oE0?pmKWMcQ)Z{VO!n2v_`^$tA1 z-}eA7scluF+gW?ujM+-F+|h)agTQOraY;AiaTc#BKDPaha#oE+F~5;`$IR2ZoR>Fa zLNaCQ{TSb(S(UW|?&cbL)KUYbUSY@4v;Ku~67}e=NW<(>eWG~TsT2-8Fac(UC^dM2 zVtRQdJYMnV@k%nvsd!F>N+21c>|o>AF$tz_+S1PYuFs;0sgZW$%9;2>q5g zU+klio|D4(og1xUs#=Zqb@Yd}=?S;^NLPvX70>j6h289-R86ZN20$`7` z^WjM#`m4>OR&ruQ6FgaRaAXOwUe09?$BLYpiUZy4Hk>TwD89p5zLZZtl*6&kjiv@6 z=61rqZ1h~x*KkBWzE(h|L$6i5{Pmo+`OxFi^*ipyY5G=X?Ph6jLtEEnUD*=IoZ33w zBuCwWjI@&NZDP1*y-wzsuqtN`xxCvg@1&^fU&y}gjWm#c*OL*T`4*Fw41p~5QxSq_ za)2@Z_*CF*7z#lxG1POu`U*)O5La@G?vlTIcwv|65DzeY!R@JY%|7qy1ZCvFYVn$o z=kh1I;(o`sX7n4WdG5KcoNH-{whFMK8RIyCGIl`^3xs(A9m7r`bhJBh#cl=7UOG-! z<~h6dxt_?o5i3?4UiVCJ)%`Q0>4cO~-6nl!eO%Im!Eco7RAZyf{C`9xuK0t1#vLEB zZqVGc-1zyW%?6vUtl7Bfs@j<|TUPXl);ZF1Vvi35f0vkQA0b$)PJN#-waZT^qEf>o zH1!=#UVlHG-$~RZR(&IT&fX}ZKFG+$RW{BJwotzJaN#|*r|{Dh87@k%b*gOlV>g%d zQ(k7bEmX%)dUE!W<2`3XqPd~9aQ>&>;@QTK zqjdd>`mkoxaJQSMsHgVFNVJOAm*Y<-#?vMvY9NPcsjELOi5ZndHMMURa}OIvpvD5n zV=vkA`iPf88Wq+fJ`Rp}bxDCxM{fBQ`o)jc5p5ZAiNj&M8Gc274FB|L=Wk3sU@sNY zZau5YR^Wl8w^ugKSPshVvGL5Wo~0V-N(&(h#A|WKHyMZE?AxFc&1J6yae+d#v{BNL zLgijF^i2DYz-wdEJHuxjPQI|liM7Rd;>vnNd|735O z;g|-Wz&ntSIY&Kj%pDkjx%131UdzqvXW6|*O3qNGt3684++0K7#AzTS7T59}{r-B! zQ6XBQd|2@JkrALP>QY@3D>>*i9)57EoV@AnuI|T}5#L&~5~HdsXs=zgfwMHbYGTk& zQCieMM{)<&MXvxqXFnvktuarQ?o7fRdZI=&#?S4xD7I!Jhp+JeWR;duU^5d)JX9nj zQqUHR47F{0v^VXt|4MX zc#d84#kHyWYO$Q;ks;x%WBFDF+5NkzCm$yNB^RhOEV;6$g~6Q*j?9^FL% zgV`yy8MgAnXCSnCWt8=$AMLW{0z*XjH)cfYb zAs@7S$6q%|S_FUBqtX@_CozwG;Dgb{){Jlo}Q*qASC^hvV1VhRzyM5JOvQKT-!#~LhAbUwq@u55~gJrPc%E5O$x%O%3o9GxCK{%kj@3Hc1 z`YTJ*(-*yiE&$w5zMgj{OeJ>Q@klk=7TgDA zNYB?Vh$kP3Ne`R;$zgp2D+bw|252Zl_oen^k2_!DnT`YVfcfS0ZWTN~coKvOH_ShS ztoWSDzX0nm*K5MPPqaXv^b^qj=e2=$0sio@FH@3Nm*T8-m|=Zm$})DE6{Q=+czuB;9A^e*BRHOkv??i0>CH|1)SP=BTyqqbUO0mt(uU z_W{0lBa_J|E@ARNQ8r%P4)#%h8AvWiUqF2VRCdNl*J#?R1{>Cg{sAS5A#HHJPV`xX ztr-nQZ_?$apF+CBb|4MiF^FpI^18ZeJ1;Oeca)qqF;imLC#W%uhif^~rX(OsYR1x# zxubcimJuYqkzeH?_zKj$d%f(3#bVADt2^|b5m1kUO|;Ly1X1Zx2lY7^`hz35VRh6& zcu)05x(WK=2p5;&RwEw@5lc)HyksTjqs-<}90KsiXJXS)im*YrmDeKw&q4mQ4tj94 z&yV|d>!F8(4ZZ!>mNcUe4%(KUr)8WIG_-CYEk@90=Hjg&e=Na%53Sv!_wA`975Ej2_=zm(P+?)}8yghBk@8(^Q=H zsJEj=vT&S_a(l8aJV>5xAAaXNk#OE#C&b!)nO(dflLC!3hZQS9mJVz*6KHv{&{ zMpe5`&XMq{$@>`m;2jc^nd!MmGsqqsWrGICfqAVn^Z-78l--~^w|fWuQ0FRd0fK+N zl=P03*tN9-SEjO+ohB=CYD=%N9jLj9DZqncSMy_38e7K0>mi zv$t>bM{$o;@#5BQl%z#u9kj?!wirw(vX^Cybwc(rh?!y5-+j+wsm}A9 z=llAd*ZH$?Z|~20y{_v$7ma!FVV+Q9>AxD_UYy$3aV1lJ#!>C8Wst9(gI8cs=g9Gj zf_tLFYsQ!ub-=Fyeb;ZNN+ONV-LklfVbPy#d&)&9SMUuLi-h5sUh2XP>nvM0egYbO zf+ofDzE@0*$LT&W+N)T1fjMituQYegp>BN!3I@Ym0PH9X{}vu$Foz12QSNxeveLSJ z%M|Shy5tvRhaR7=uSyXH8$+v0S45S>@|PMftlKRxp9mVVfRRKhSc!w)piHS#M(uc^ zRZhw95d=7JU#F;6FdkV&p5QeVeD(zrCT8nY)fkW=GQ5&Cr+SvMk6_{;Z->hM{@ybv zNP~GWF4k!R&+7zl@6ee#6Yr{NGP%o> z-di>hr_>b8r7^#)Zk6?rg|rnqd&D~(-lZh(Wt*2h_yl-;@wQBcPQbi|_p1;mrEGYN z%~6kcj2;TVU%B!?_8G-uC(bSq@J@jx#0rnQ4;*ML1+3Tsf+LN%#Da_$)ygS-ba5N@ zv9kgiF9yvM_;JL5xq9G2HBh(%5@$LhlzJITI;~ZCU8+i~qNRCQH^+ySa&t1nbf$vU3m;mK*rF7JU+gM#E@GhFmn5;yO0O7=C zYt&HqozL=i_v_c_QzdFPANF(bZqa1%06<8u%2mgDs&9C@@#Gui86H2Tt4xo{nn9~H zlkFj`cVK^UknZ{-6!(Gr$(zS^@)H_9n3h)%0aw5haf|W5;phz=V+M0SyBWFPdB-{! z2ra-W|4|@$OOJyZXNh)U2lG&c3~|v6{z}e zih9l4*4}sWJ$HP~nAT80DPR|$DR0IVlC%SExmAv$?_y>Iun)1J zkTE6H7i#V`Sc|@I2HNe8LoOpSI#KGBM~F*jc#%a!^QvP@Y(2|&rS*_f#=H8i=Kb$| zF!EMUQAs`h++=&~U7$_DvByiw`RF*ySR^4#zs)@F`%h0hqAXE+^vFP{h6 z#RQ$=4Wxcvy)40WyukeRMwhBEu)5(jP%+}t8FsuaA_3b0uuFm-Td&?lBqRv6vnnob zNXsjhJb;w-86Se@8+e}p4{=~*!DRkWgXyi#m7Ye70F+Cy*Q}{i+#4ah=T0l8657Ir zR<5aP5dJ7|Yvdfj+A40%Y}v`}TMmM_<}W2%iBVN+m6gDcjlt!p)+V$XfDc=<%Z^^I z7N_hol@50y*UN?|N=(Dw1|{kF;>@dBK`|LtVg^E^`m){g`@EuO*6Cu;Gq{aA|VZuN* z@BDz0*xudnp$o1`vxc9bR}k#Pi5k{2qdP$tUl}O~DH*&TQJ6!k=(DRQWeeSEi3NBg ztJtG2=RV9_d*9PLpL2);(SmU^3G^C^TiwA}VWobL?jsiK&fW#oKi>vCV>P0}^`|Kl zKjHr09DB&JZ3y=kd8-02URKlljLtlb|;7|c@X)ujZz7a!|-I4K7bqt0TPX9pOs3F=QH)PbE^gOBY)$AhojEA{ky` z1oJsk63*D?*u*9bz6N$t*I={&=M{2kZbKXSCDLL4J zTsHbWOJyrNaRU`DhKsC)&Z-oAhR|dpY#60g)&vRjlHo6X5*=WQ&|g;^piGP`?WQi9 z=ow^CpXNb_CO59}dBffPnE47>2tQLLbJULLsjlju@}s;_TSpBjqp}$@nchYi$FB}9 zn+*%!X96h&KrWhTI$|M59^oscPDIt2myBoYz_Wm~Sj!3pzQyI64|udQX3`_as~$Ad z1{vAt-8B9UKlKpM=hwvnXgRBS16HQTnQOCCw;)|IFRPEqSXrO@+GRAFd4&XZz@hHf zZ&>nxcS^S(@M`sV!>}efV|BfmUrb4t9QIFHuNdG} zOupVn?olxF$^=+iY!FgGQMTutG|=9nO|z~mdw9IYqH8>&!XsV)EIj~4D0WU+V?UtT z4>3idU*h~|Z(-w#66!y{Wq~!p139k|10ue5`ur8!p6f9h^#W^=0ZFR?>PhlDsDCK4 z<;%pKcV4B=KKv|C+>XoNwiKrZv&A^do*HX@eDZjJ`fK(Pjl04{+fv+Z z!XSC&baiEQPIS4^g7Sf9+x@wqbw7gm+^DcfrM>Z(6lHzyUnrzODSxey{kd<0W0XCT zb0yAd?9)|ny0XEnFIv zrbPJa)Po{a#2Af8h)iY7cH~&lYu$h|U-RSpr_T=jbq<4h=)$>%_VZMlf9B+c2i{`g zvMp&VpdsACg83u5AS}jew=VB)K)0yV4(H}I__4`2BA{MZt67Vt%lH7zq&wwRrDa#6 zKIq+7dA#XN;i|0XvdlVc0dNaAcs)a^>J3KVmdQ}(FJprpBAT~;-0R&79Mm;Or(_fr zBM_Epv178n?$mW~4{!VZeV&&~4Rd%fisIK!{SxRp9jZ6rK*mX?x{S!5oBaocBT~U11*xD0`v9S>vymwV}1p7syR(Fg#&H0)>;W31Axsw z^Ouyx2U`Z9^*`pqK(1$W>^O{m|EAKyfHfDz_bztCAc4%CoPfTIg4_HrO3FEJ4>R6`QPiVI0R-N2Xa7 z$VMGUwHyO-`Jva-E-HsJN%i$knpGC)L9!pAw>Nq4Z}SZUW4lwqHk5CsG`l-o5KpVZ zzuy#Wca=VF7t!2g$SA6vi0!o}zRhY^{p5N|Ef-k4@>6?ZS;JcZe!=b!oX9RSAS+Xb zoU7kcHyfp5-Dr_I8k^&Qvi^=+laKO*;!Bc5bR_jMTp7_DqXDfWeJWTn=o|U73H_C& zBKjP}WWBT|t%9_`A?k79^9wPK(Fcbz{V*ocGtvDg|L%VYy}okO=#SvVK;R9W`SrHA zn++P@u@{vo%4iwbSh!OpEtwv3OZ#lf&%l6!@tF%KpMd(V>;{`Elm5qqg2{-$q)r{~ z%m}BW6P_HxEZ3vhPKDV=e)!W7bv>fQQ~OM|j`D84;yTerGh{SmwTrUf0<!B{MRpE8M?wA;l3&Nw=z92G#CwgRE)j`_V z6Jc3`z;ReIFW`7)r*{Rj4@*%;vG_DfB*WdVz5~(VOZ}Td@SE9WvjKSZBX>;&w$@NA zdLg}#ChQZ7-ZY;)PrM~jBIiu`*zO1XGkk1msYgI;F82G}6lo#tbxPAjd=%?Db*~xG z?xa6Ot3ZbNZP@nMnw$`_=jf15m$FRQg)%mxjngm%4oapp9aW93ocOsOGOdPJI6(1n z9`&NnR%FgP8SZ`9^s0`6b87T7b&xIiJn39tOH*g?ICQV4E2;O1@4I4Y*@pP#z%7W{ z$xmW@#uAb}krSZ@UQQviyqdoKG_=V2{?HRUBb3AtRO)BHDPTDf@dZ$40a&0#O%+xQ zTWM_<=Yj6B3qfKbr4TP$CmDCI)16HyJPJa5pLAF6Y?$ldOn}#!Ia=;%*_(up^**-z z$_?T;Yyr2Lb?A&&r~kc2M~nF_L2x@e7XsSNTR*Z}5g;&_+tjYhlS|(=*2MYrnG}A) z4U}2<;m0FEN{N5PN-!fcNRiT5=of+_*kPiep$7qMnh2MYKzg+& z3I^%DNZd32dbWMyUZIBiG#3&TLWT^kW|*sYp#&^)`(frd~i3^-}m(p{W-+XwX&IhrJ ze!zn%^>g2H=qhRG@QhR>wTAe7g%G}vwbDehD}S@0}?M_Xau649I7JS!X~E3%Q() z>=vYFatA{i+AZd!%QC5@Zk?HAe`?KfTYM7&*NrITqDqx;|B#f1P5%g{BDm7zxo4*t z%OJTBm&-4Crb_kUK{{b0lJy{B7z|uzE5*x;e)-xHmZ@0Z^XGhk^rXhm0--`F$!fn1 zMi1r070l1QC_CAJ4$6A=nrSzCtOcyP&vD0eUQLrAnjM^lsNp&pGM5~3uxp8hIx|BP z(%oOE!FY_%7e2hhX#4bOTYd!}==aHZJU5i#q4LpG-v4qJzX_}nV2}WJxE&z6EF`mQ z_JN7%xdb>QKSy_wPC3)!DeLM&6q$)rBjfn~##8i)(17r76<0+nX~fbDnTGetcwr@*;EV zQNSgy1Td?c-d$;D2gV}2xfEx)8mJbUMIgo5+2_en4w!oMy=ELcKafyrS!OgrD^?`p zdimxbV=WuH&E~?ryZ|E7{Z@lrwATD*G^u3`>X+6s=u`c$Vp*6derFH;AS6a3&c@b1 z&XlpH{A*xcB%hypcR}x{wvMy3Me3U<|MnCm4QoW&irh{@Y`Kgo@k}*_Oio3(d}SQEZH=FUbh`Uml+$N2yMpdE^sAjIGcE?~qA3FtsiDf!X)&ndbkXMOO^UA#u6Mu<>?z<-q#z zm;SxoNZUC}3yf&xnQm35hmopeX^c-#M6_dDmdzpMu(=)_K4@g`XE`VLg7fCoADbP# zrVWH(uw`B}dZ8J$YPpcw%D{PdK_iY!!c1DiLW=gin05jfaL*ZNq)Fr&-;X-7yJ~6T22Ss_+3J?_Jtc6e1>#0=+tU!;18oKw zR}M{6vs6Ze3Hpape8_P8eFEy96W$hSB7jPovj8G%>S50@}strhNy`&69rOl)*J5*r52&X zLkA4N#McA%Y3cjpEGu;n3N_mbGNG7bI^b+-9|Odqtk}dEAe@7e!O|Yf3=}S9Jh&LI zDGE?ySyQX+gK^Ye@hl0TwbE<^UbgR;&0Xa)GsR*IKwyWTXD^2lj@5rVp6< zX$v<4JiFhodW>+CC9qUA=R5MK)}pj0EA8jQ$QCUND*8 z_3xfS%^TOml*;9FF;D&-)vUReO&$M}aSa|g3`IxQx)fa_zQb}ShUGFkU3l^_(lH`* zz9)CS=q^*6`rjS}T;2&Zf5C$auJgKA1#aVEN%W~OjT=CCdb2m)_Ii|MPw#e2CK&he zR_QIj_6|kFX(?@WKwWXxKC=RR^T1&FSBssedVvsgj>z~Tivup1A)^a+NI+-Jxg?)u z$!h6&HEUC)`Y7penW(Ajm~+r&(=U7*zoHZLsaEau+IN-UBZJd7u;4TEy2sfd3@Ax4 zZFgB5i{<2hxCA6lfNlY#{fz;7o`9VnU1$peB)ng)s#(uBm_aYhN?7+XkSr1FIXgl1 zxoLwD<->jAWlq*Wjhz9$eJlRg;cL!U&=0ahMV~41_xrWM4+4{zz0ygxb55u-C={Ivj1-1uFMU`Hxo=l+oO{n44M0d*GuO|v>i2M+I4$7K@@S}{G zq~^sp{`(FhHj?L;4$eQB*Yjt#AxOv1P1X`T(RzQ)8d}I*qZ}X(RSR0>_#bavHFv>k z(>r$)7CsO(Q0aM+=Yr>4QVVjHLjRsUfs;yBMWHHFuW>PRU?_-BJAS7Yjc>wl>N))* z)gR+1@Ga-4=0!la*%+E+#w;x=LHbPc=uL~Esh)4P|8pdV*{mnPBUFW00?K8WM{nOwdvN~JdHsH_{O1H$H} zvVQ(MNuGreT5^0jSRGJR9ZW>bN9sm_C_6NJa1-IF!AVu(3$k5x4sJhugVUPmk>dgm z0oIRI&3va;1?<==-S%mpp~PcWjt@?ijC$gCu-4PF>P>|OFxqb>ypRg^QHD=zKN6&s_=Tg7e7Hc;&>liKYwD6PJ`mb(f%j2JpXwiZLmBZc& zM%c5Qw&3-}u+uh3%Ve*j@HIx+od^ z{}Eb&PZd}rOp4t!R8NLmoxgF%Rb-SGx0$jYzNLyjYB6={iNU6GPoaT%C)$2r!**MW zZDwaO#nf0%8XzQ(6frj(%qMefM&hsT(&1f$D_g=3IM1;u=+T~TBx=tp#Yxx+dc>{Y;thgj;7?e zPv%et(Eky@dJXe+qWE;w1%I61J$}u8CwuP~=z;fGM**8C7x$1@PU*kZJuITJ)$WBQ zYay3Z`svt|H#zj3j{7!kAtjV3M0(T<4^ZMEaD@?0GBqzd%3P)bM_AWHNd;bK4xJZUa2}@2f55Gtq@GpP~?+ zfi&NIoV_}Z9p*djxnuH#(k`n`R{=)NWhUPuRCjCUYa@9eXyDSFTPax&b92&s*fRgG z!PJE59+?Dw&^@w+ML3Q4g}}$M@*JS24z#~mvQ695Hf@su`>r>dnkrMMaTiU+#~75X z#|b9vmU`6$2OWdHu9dk1W$SelCdqeEq;p`4!Y*17Vk zz!*Qm>7jc1Y0N9&LzDIV%Ses4K9kdI>0gBlRB$`23?y4r(pekLSeicb#X1uJ!s%%J zDf+S&$NfWrYAEYbSX+k}JrbHQ7D&G9(Bn5O7FpZCA8l<3TrwJ<-mtFGwQFS@(rqejtm18xZ4m%}JmEGv;015r>Sv1)4b+GV%fwyHZPVr z3@gH~+P%2v2Wq~o;tV(*I*^# zR%s@vi$iaKD3tCnw;&boeZ9oF-A7&Zg0?gB_;V1A7=S^YP=x68p@Y22T z3@(lE3~^=(Gmh@)q|Uh-WuJ~)^R8LT#gOk8%H@LReIe44^WS6qyyGx0G*_LTd?N2+ zk~94Bv{mSe#MB_*(=}>dvo@FTb;o!0TN&M3GkId~NkD4!zrHO{@#_BnRvm0J$8}Y9 zwOV8{|67IxIrd>on~#mVxn&sn051ojhH%=JppDmXj05~ z9k0J35y%qIm{${8vcRZOR89G1G;ZeNP<_cxoZ-irPr!96C>BuDxM*dS{(NE=NG@@v zg&bN0!eF;O7WqA(5AZ(~&ogz|(*Z>|v()g0;sZECRX`;T2=WLYOlVG#e*whE&_!tN z@w{}@*%P-%j{#Z5 z(H*4O=g1N}FJ@Q=v9+Ah#^SW3?XegzTW8_*Jh}<*w*g#?J^!)hJdsN6VIY4Nw<83i z^|(h06H32#2#69DBZP?&=M_(bUiS84w9l^-u76k6fRb4(fG$TaC#J?9I`GUmxFWF0 z%GV8yF*I39BBYT4Ko7tq7?dsmV^Yn_x4%qTI0@jA?W(`!Y@E;+a?u}VS&efqx3&=- zZU>&ONM3+a?2dm$f9*1!)&}f_61k=OOOC4>!1?u(!1=oYjp02xybDf>xJR$#x@C3R zsKxb*`>ZNDnq%BXx+e${)i!9%jKMjN4}0e4Q@?T>f6cc*rF1a3&ik6zi^C2}g5sfx ztmtJ`O23u9u#O~nEJke{u(nr-q4b@j0!Z)0@$wJp;G$9OKe)FgmjtIjK%~=7Mwk?O zpr2(WKav-;eJ6W(pq5nJehrUJ%Wkg7$o_Mw$O1zC%kCt*-NI}VajFlcO9P~q^gKKM z{c%3pm^U8F1?}I-zJ$+}$fwn!#<(dZ6&b7kSQj&KyPWF!cRO4U?CG7Cd;mFm(wxo| zt}-RYwee+FvD1K04oU>N*R1?LkZW(gQi}h4pb`EZQWOzrCg%TYV=mdYou4_b`XxXw z>ZWtD$|X7QpL@_iW$c_*qe6P;o~N9l>Qd=s715+UGh=}2{XnDzQQflOovw6Rwy$@P z`Hu}O^|=3-P~I;G=C$CVc_(mb+kBZhrU&o`z%r9N)GXk&n*8&6^qo?_$R|Kr9g3ZP zh_$`f{y?%3B@WFK8Z>)Kw0-byUvcMg&e|zfKEjODzWu9Om;K4BB|dq)Y}tM_-Q!0u z{1Oa)EtA#u#3F4wEE!#!^zAg)5%-vVxlbiVi|vK|c;h*!Pk;3Se&`HO9dgHb{f>7{ zSXW>M%M$!%xAK4ebBpmse;U*N(Pb%|8{zdBl;`r#(Y&#_T^)C!C`|VtfCF-C@0g>1 zq8j~__^QM;opI7HXLZVq*A@3)3dw(4Rs6&EA9RL58=MrB{MtS~i)07`ub|} z?1sd_Tmh|rZc;OjFd9wm&zl2CxQT&}BXg9`0UP{p)eSJ_Nd`x5f38EN zVOb&VQNpC;O?k#bV+I8y{vPiHVtm`XWe*h=mU~@;VYEx7o3P>QZHjaOD`z$NLGVn* zzsbOvIprT*?lVpUc|`1{vdVcsQq698{65m&lE?f6wXE+=erLQI%S$bjB7PQoE1=evF0{E;jan^`A{Qj zIC?rfEA;`%?|7thlPG5r$ZXax`r>*E;G?B=3LrOqHgQQEYGMM5O(ytTT7JtW1&P)C zbu5UydRn$*C@-=Wh3oXV+!4JyaYadi4Zz=Gj`A0yw*P&4#hIFcv)a!JcH&Sa#;2Oy zIgGuyvy$7M6O*v7Z_*-zXx;@S(?+WOns{uyX}NRY7gHYSw}q1Z|I09>s_E8VE&3e% zO97wQTQ1rs9n?9*m%SGBIo{Y2Q~OxTdFye0|KQ>`h7(Tn>V)$}tZox?iu8{LwrD)T z7IEcZTdJCH!Ms)k7RgWR2)1%MhAN<2b|Br#WtfV30 zW5Bs+Gt)A*4Ee>%$VNWU$lCWVdhq6WKj1hVvii z6YQiDJR!gi(%*ZK3;EaJ)CZulekqTC4>XY@x^DI!Gzcttn5d<3x7Ve%T`7HbuZjdo zMspX=Irg{5{XZvtgFxEW70JkpM7|4mnj^p0mg0ffnnpevHWawldn_W|w?`wBhMfgqCvW%T0nRC=RMrH76-w6EXK6QE|y|sZEseC%%s2Vg{xV=q1fL@S*T*##X}(}pR<5+M5P!1Igm0`XKlUUU*c*#2i9 zn5D7XRGBE-t@%X&U02{@tl)0#t#{TEFkI{Xv*ks}o;ifDr(7@{S+_rd7XAQz`J*YZ zzov|^3sIJO_TU#}x)#>N^IKO^IZS(GwQ37V?(=QP^`JBPO7K`$;zoyh{qpnO(1hpP zIkaWAErR=7{@3Y-a`%VX^gd58icLhGc=$T{~M2)Jtz zozH1cV<)`E&uTVH&UX+v?Dc4h$dIlw;^x>1a){WrJ}hWkSGGh5hVfXD6n>8sjV+<9W5!@t&Koo zcW@%G+!Ggr#4`M~oV!Wn_vvl206H}M=Nj#i10L@XyJFm?VjEr0<8&pJt3<{IXUEXe zX?b~*9-=I`#m7|5Mw!T|_N{Qa$Y4kJ}d!xk=H1whq$&E#5FJ<3tcyw+005 zwi8GtHHhWz)EjbbnK`uT$(TtGuEp2%gfn! zhferoIiZ1E2hZcJgTXW?Q%-<0xc;9?Xl)UDq84>0I#RJPkE?P}x-Htw#TYsK#i{qk zo0X3lm>Q!2#p#RKt|a^O`LS=YaSE_u!_2HY)Xd|d$g+;J^bp@L?0$N2ld#`AiRtE2 zr=Yuqdy>pjccv&^!Rh{fTYmudvGDxA0$NU^aRZ(XUH&jyvL}()g+UZKb{ZJTL{V-& z*|SN-x7SJSG&X;nq3WPH8dPoK`ge>wb{z43T!3Z?xsVceCJ|T-yHN)|0K8C5dD@fh z(GpJS8XXo20wkn`O22S$2@p&y`v02u()p5ZIsZb@({r{d+hX5v{Ex(5V;n zHNiaju{$xWv72zU&F=9bv=|^)NucmgCAI0NEBb{;^`fe_Sq$>-0MPJg&S-^Shy(io z=5$ilzjiI>9pypt142Wg#Vn;p6%IEZLKI2WPOF8t+0xH(e`%2G7fdCMW0EoI=zZFC%F|_E|b@kX{DrX6sxIM2xsc>`0KW&6Ud^zS^V`$s>0vTg^=x$B&|; zgvin#m(!EE9##R1%x0gv>m}Phnb?&6e{3#2%QhgRou-~wX`v&79(f9=*ue)bqKNnU zxCjYl7HQ_Hl%tTS_>_w#mPDylXX+fG58$&kZU$@oo}5tcm4JN`Abxgu!4K@|X^Ned zrX@#omAE)}FZUcWzn*h-xKUun4#!Iypa+;w9g}TGHbFYx{N1DXgL0}yJ0pG3#>)ld z#*#r}RQz3lq14#drDQkWk1n*}6TrbP7gTD#6d}b|*K3^*?8=1SqNib3MzQ)M-pJ?yg$Kl zu)MKYR{@HDC?LuPE$xZI^(GYgeQG76GY@6LE}#lZNRbR>FI@4B8USCje#)92ry_&v z;rG)!XfWID376Hh9+=CaOXJQR0ldwrtq&1hIYareq9LutxOi7oq#*}HDRX^Goi|}Mozg6>MF&X8;wcVY{ySL?<5qqwK>3$XcFa) zy9Ler<~hmbpGox)a+6STGrTYVQ)m$7e)lWO#=}$hJ)=t|l2aQH$Q?MtWx(z4Ic-Rl z?Afc;9+u?grbcQV-w1E+DjZD14nTi$FhJ)KnBW$dJ`P^D)Zg8{v3mT>pS9~a*W^p#2ag6 zet&zdUG2KVg=mv+=%{-7XKR>nsC&No+LjBl)QqcNGlW8eP&>?@6uK!o-}6+o2(fU7 zq}UBscMbZa_b{$?w@gP>E1{E|GA2lUI!fmLmBJO`4>#B()DH5e(|0oH#yFSbL4hUK zme}RVE__2&si%2u{8!}M!3j8!zk>2FfR2t>L&MyUQRP|gV5;0~ikrmgfjgStAtL@= z@N!@3==4yRAat+O@gQI3zYf#=)a7mz>*(fQidYf426?$d@vHJpRD-;{7okZ7#iJIc zl)zka4f6WGe=x{US5$@q8{kfiUO1CtB0h}x+}&N^IXYFV=~X9a71XrK?{3=v43 z#0IEeB|IMcSYDZUx|^&D!Gz9L{m`2Rzb7cbaOmhu%7XzvwPuD9x=4V0&?PfV?W;By zE$0UwMS1H)*$Kf200@j=&cAQ!ucLiB9i;XgF|LF3GDIn)9FMD0Q~eqwv1u#e=CThQYV&Ldh~RxB$ZU{>iDz$24glv_ z0qDqmfX@VPeNW9{c~ZYL(ZhH=1g1dAIg2%~SRWhe=MxX#T%h6wEgR(> z+ApBC5lDzwCRTZ;7qJ&XpxyBt6rdef!iL(=dXoCDEyD3?Cm(Ad8>ri8%6z&{QRxN}e-s8$Qf?;*dwC{*vi4|nzi=RN72KkP@vrfVMZf|h3EuR+SiU1Gac)Z5Jyr(HWH zPo*4jS9XjS$Zz-{F`j>;e=L*MHy3w0-@hZnemh zibYjAAqRO2Cu9V-Z3rqKe9gH5$(7TadrEaQuvESC1(_a^8a1jUdpq2ED#SiyZ7O&Z ziyG(FUWM*PW`{||SqGEZ4<5GW^GK4#MN0j43TjV|zbq*_Gqoy?taX5##8Zsk>*NNU4lV>=LFBTM?1d^;vf3fUJ~h?cKG_ z#!XVB%TL|DanI`b3)`>iK>K}R-W>?!Io}}%)vX2ss%Q$hCq8}{ z5#5cER3F$$Z0A;FraT$~^)nsg_Od1t1kt=9d1@~*c|30JVN>wVYWA1we!6TPDj>H*J*OEQYKp z#5uvPZe5G?UeLCCu;JZg*Y^1rQ*gz z7sPpZ4R`A-r8gbqaqJav-&P2cPW)G(%88af05>%VOSlyr)I8eYCV zFD1pE1?tIVp-XSvbZ4{`dzZt;3fab=TlX=^?#iHD3W_({`|sr$z)zppHmS3OqS)12 z>y^TZmxKZ?i`Ai0qU@VKw+4cdCFFe9w#s>R&uSncYuVDZthtXAiD@cuWS^jw`>_NF zjj0h7rt}@>iYS_srkDBEj4Nr?K}Y({kGJa?g;0-*O(wY+OBAfUVP&NFcdv|pT<{)g{($|=3DW|Y&fc`z`RifIAmFA;Byqzx z7XC(F@Z+xhWHjm0P}jq(RL^~UE>DFDoc44rXZA?5?3T$L`aRpwSUhF2+gQSQE+y-g-8UB$ z)5)(a?=skr?IaR1C;KZCtc z`&id4h#XA`*Jl-2kQ;d*QBVH*AMQcNGQ_9X@Dinrb;^tkIJaR4*eih-q8~RJ)42{B z5+K|I01;ic@Mr@x8Gx5?kIP?`Mc!NCP`{q0)tLcEOI4bcXT%+42cGX~00%M&J&@^D zsUZkevizKPD1#^&LeQ@vaM$D0qexEDM;LFtZAeuuX_KS|;q2s%+(rSmt7D=FY*t+&rDX43(wDH?zxbbw}goXb%SEKu4WBKWr|K%Q(jN$u%F`XUo-+)RX8l z1vIUzmJiojnW=8v{Dg@oXQH3xhi7sA<%OpUbCPS<$#KcmC1{t!gt!;Gg(+9kve@57DoaNfQ2Wf0=o97x6v+qHDoYCPS3 zDz4E)i9G1@d6%x;xUE9-FG2W&Wo40iqtNV}XT|K=fR*zE)&)jhq9Rt<)N7PN zyql8|xiw!602HvyUIu7Q`2|_@^bKKT2I9`_Fz`xC97rtU)Ya<}do;WkC(-Wguj)@OM6Yhc-v*A-m;3xaOvzM*}`5slR0 zk8@V9tT`{;Aj^IP2Pbef8(ZagCURW~*0MTk%3ZOZ-RF7N1pTyiIy+Lrj9y@svy=0y zM!B0kY5FuvVsciy`nTkaa>Ku)HnZiDFD*}LSM@5xg&u$#VD7)-9Md@K2H=?X2fcJJ zx83@!H=PoAOl(+(vtZ;Vj*9iP{s}1@=@ZP@+OwQfm-()<8;bF3-UNH%CaWPZMZw}SQt~yQBUA%H+@Xp7X{x2Uzyuy_@ya1 zAcRN%z)qD)!XIU`f#=wf+nqH2^=%{N(~vUlXbTm5PX*5Tmq7n+rpabBd2c zBZqJG#-1l)h(8L_vy%eM#KuD!i)n?Q* z)|Jc3h%%gaM_iXJix6`_9g2>kIXP#*2|*F#LeQtfMyy6nWUeSJyAz5CcS3%H+`3qp zv;)w4zNhz?QnMh&=J1aC3Srs?FK34z9!?tnJX}#oeEM2xz09OwbBUGFSbX5IK--{W z8vuP;3qUWL14n;#5&bekL~WMlW7qRRAEU^_?h-||q?LL%SR1Filu9IsuSG_2t9%ti zr>_mLKJr3zF<_xG#nw48%HN^Pxa|~QXD7#gbQ{6b7FGzJ)oeF|h$D4Sz-O_sjEgp+ zGQt!GfAIOMF*?B>1Fv5Y`wwjVEPu1?k!PX1%cKBeA8A)pSy>j4Q!U%4j9&y!+e4o$ z6H=eh@12rkAC|c)vH%{*0Xr5ud6{r$xI1B5RI1R zbwdauE&#v$PfphNveG9flKSGfRFK}1UtP}$&v26)+Ko(R zkHuE2xt5?^Jyt)A?0&(Y;CD?uhDTh7JIsFUd!^TXx}K%J+LL49xC-fBye0fogaI zE9Bb!y)W~uMm%fwTK57UL(JekcFlTv_z`(VW+rXjPv4dC+V#;4NjFkU3aID|i6K;R zt0BO{XR0w+JXTa3lZC0yS&RA_`+3XJc`ohodXSPs`# zl6^!a*3rdi#jarNBi>u~1~Zf;F;;jH9sVhS`T#?NkmKo#9wACs;u&Afnv^mQc`e$G zSmqpfA{KZHuRPwEL;^-sQf}FXeCh#-nlqHy{ zG}Z2{ef#M;o2918=?Pv`K+A)%qlk*P!m<+B!1iQ#J$+ z=Cj47(B${5$eyx>-|I;r8j^$Y>yt@&PK=7l%Qs#pdw1EaS18%L?)pm)3oeg*tT^WP z00dQIOkJ8ZSgPcVT^~Lexg=Jrp|b3`7}%Sm5W4W>yxlUE#Nw zjv86$YMVRMU#61Bd`g-L&T&^%WtQF`LU!1<|2XU89;6xdwY__b_1QiLMHwylQA+8u zzc=s#%0rydL<#sD>J*B0)HrOytON$Nxq__u>_UCnAV_!Q4c5x%aP$tYETqGowt9-k zSB^Dk2KBMNzTTc05{Q9Q8Y4sX7Swpiuc9{%G5$k>l0BYeP~Pj6zEtd#z|m3n)|zz3 z#FwEVY-x4%@RUCz#6yib$0r^-;_K|}oPN4}-e<$c^LbUy1+6MJ4;TcO9OLBhkLeGI z5f0DWsWBGVDH<_9Z3EFM0dw^tCnsl7nXXZtW$T(e@v(k1_K=(Z(!L92`=WW`0ajW{1|I#!h{<{u^DDMA7j1c$Q87O{=SFWpoNi1d(B>?uqf1WD95ab+EkIv?4U z?qqk_Z+cF}Q_k4aX`(J9_ROaQA*}2Qx=_26c7~qDdJ+^k@n^+FRq8$S7ukU8hv}$u4iLr#?`Ku3_Wt8!3Bc!BUdhkcu66`MYDC4SZ@#&nUEL` zy)G-ey8bOjxY<1C{d!X64Ra$GVhD03$$w4cDQ+I=GTj`$?A7?QnmTS9{ z|ExmhUFWym1NG%de7*lN&y*XbG0>zEbE!-Z1Q&gaz~k-sf<~?k;C6$wT0VD#c_JcD zQtMQO^_$2GiV#sMcTy3Qt$EBuAmtAHP= z5Ikjs+ftkYt4PZv*5@EGG&WYu&E@3Sj(7OgFhKqsf^I*j))r~vPt**1U0UifBk^t?zx0n~BLH z2KjbO4SlLEgFU(Ov~z!M@Zsr8`|k->e&Qlhj5EQuZO*684J&$*hix9c0ruZG)2j03 z@0h1gpO(9oa=(D_@xu7K%NiOERP>f{-5Ypk5YOZ-O%^Mx->27E_mxD7fjw}q99yxU z-c!1)SE+=qlqCqZh$-J-sYjXaP>Ux?_Q!YV{Ui93N15CF_Zr9HC*mZfNG2o?!p-rjFRpkgP|9 z@@y5oB8o-Lk>6h7iVbka)X=LFLGb&*s{MQG!gD@^<%rHu^LMxVpiMU+J{z0<1I zwXh}4XSXS4Nk_O3?@b6${eEeEBlW7){{3;UmdWdbkTtcF=3PTX>W}?nCx>5C1j$02 zVvcsA)RCM?T^GH@A$4W;58C^VQlSC;TOrBdZ1IDyG`_u58Q`joF{G_$ZY6))bJZFs zPfN*<10@bZsFwANyE~0-T#w6J5_yJBQ?z8jqc`q%GxdUoICxm*)F9TdF6`9QEoCI(r@)X|(MZU{_;r6QE~c}RDAzvduYF6HDj zAz)*tF1KqFHWo_mvcqqcE&llNE9w<0T8%xbd)|j?{_%za)72P9a9`h1FSz+61=vqA zOBxBTwaW1s%BVIodi6*?)iz)UTi=_}k-l54WN2s`hO2&~b|LOr*jf;@lj`v{kN{Q% zNilMP+1JC#X+fckl$jERRi5{$6Q55#nHG~5C#(`4wOzND?0Hx6v&dWfTB1^$mSgJ0 zm2?Bb;PClAu{*!A!xSSE!Q|dC4Ui5F4p#B;F|3BFr(P#Wv4~zzuyi^BfnoKL)Zdd) z#lxj0!?t2?2mP`T<05Q=aqeKO=yXLca>g}p?TjYN`y0}e5-ztl=V%biJrn1^5GAoU zm)t#iuMmt)CTxirg(b4DGK>5k%XD(JUHYH5n48Q&X+pRACEq#&pghTDquG1?5 z4!wI0qvr_9nAhj<3By8KvZ7mv?pJLdvygxCLRuj?uk1-6wx`-06vW@t4BE#oV{d zMJ`z!rDrj;x>DaAnFvP|S~67;+=;s(JuTlp48OsdF!K1F-A6_KNsIw7HOOl<_CU0_ zI#K;Wu$ia*0t3spu~U4i5xL;CG%74xZkMvNPrf4Zc+T8*wanK~b7y6n)lti%QH^AW3)$-`~`S4&grGp_ZUy=A+ApeBX2CP?n(VVh1d26^ZA?? zYuJ*bTX-^whTq^w7~#7*OqfWOjZ2dd8nNmxsV@#@ax?1d2|Du60z^z%w)mwlpJ!%N#j;ok8x7&^zSk7F zQ8*ZCNnt6b+OSnw4L0@j z^K%C}QZ1uu&dC*vw+KE<*oh58`Lofves*~!ccZbS=P08D?F%>0GHntbY}M+&6J+&q zX?WV7TOSRcBj$>Yu)Ib%Q;=@P&&C$XjyKWQO*j*7*6l2hG+EcbdOEuYLrgX^tnjAllg)`rG{Fc&m1DdmYzs|Xv(SguVKb+2jjbkQ~N1`K+iN}2>* z?)aFdsXiR9~DO4B2h2i8eH5yZAyIpBh!FD(njN+_8)1(C&J7Q zBU|H8C9U9kWxy(auCdOS4gIy}&zWOa@3@#DA>!T9y^1pic8&R=iCnFer|5q2!wl;lG$hSjyu*bo}D|;L6`BDWQpi>M)vrb zX0uNRMf*he)@FFL3IzbJBw6aBoQseR@W`DKzHj#u7l3H*xyH{o4j0M)~HNcbUAvggv#V z$tvQELKz7%)fOkPmQ-W9d+8w7u<0W)h9pB#4~B7HHfpvhSsmR~rrYjnYme48t^iu< zwK#yO;sQg9jN9J#a1LcL&t@PWjKHNqYTV>eHtcue=lE3qQ3XH0B=Q z`gX^$Z7=s( ze$x;Y{D>)Kw*Z@6*&Z%$yhMRZD^xAr)9ReKq$&LMPC1EAXvf(!5f&-;G%*PYY%6X1 zsr+?ZQgIYM4R|stuEwiUh-`k}7);ZQLM^nUKEq2NGmgivuqmOQuqWKS#gQ5se{s8I z1p!rmZ07Z?UC{~D9G&2pRmd6gY_!{58Iv=8ed}iy%N|tyKF5D2d^+cb)n(i&w@cp)l5N(Zf6Z6HPueL|1wugGPjRo3uUv%6>~Rwc$qnd4p4Vl&fg9Jx=rGk8z?6 z1+~)bp%Yt;A0I|X2RMqQ-|ue+S+7@bstym1yxqG(%CVwR{garv@Xd}aj`Hj(hy1%K z@%)Sj6cm?)#0M2#a34< zTv8xuz4h9vK}t4oZ9?3hG5e0BWBP*;%-YJ**ubqA=sW}S*5;>ApK|Ny)ATQr2=L|N zPHKdZEk6*@e62=6$hiAx@~NMvg{f=F=;3UC^XS&=^@}evd2Zw?9$mz3r6B6AYu`fW zxqe*Go^5*7N|Ij~S1t~h z7**NSaCQ9^QOBp|$Svg;LsGc3ReJea&5emRClA<;+iXYN6;)N$9;~SL>U;~macYm^ zjF{PH9e-LP5z@_T*Lbsa$5}Rs&OU*gb3|FLO>VZebfF>Ztfs8pGcJ2Q%ik4CcW&ag z*1WvDrcLmadHD`iW-VI9RBhM4`B0Rk_C$O;FBV>hHN%jBG;Fi}_ZyM{y$1R;5t0GQ zu6duy&35pqRd`I>a}`q)$W*$X^z&#CASyHUES@svcuI&@>uL3FhgNyQ?CLyX*|a-i zp0b#txK$I|tbj)R?4nKc1|z)*yqF~&Saw8rnBGtQ`SWh)<-0Kta96~dUlbQFYLu3i z9`*A;k4%9cJZC2_GrkjqZkjNC>7HqfCzq&szS|gl>C&a}GEyFJUSX8LX^jOcZSVvxH)zZ zWB$L13wz8-9eEtY>Z8$X_5?3r1Ux3q--4Vf*I5+yC{j# z!!a!$C&x#DlR>j_yDzUp`nB~94Y(?z>T`y171F5m3m!zSxx0-$a@Ve{+&D#8M)vKf zwYBBA5t~46eP6CHMS;mZdyatRg5zV0o7Ry>`OZ|31P?_~k37x-6IZ9co9LBXY>z!v zq_BDM_`ct@BPLUrg9aF-&T_41Q#BGeDszz{?6KEk%j|`iOuSfnuErpQTddvrgHbI%&calPArxfl%F?uu zjFy#^)f6VxIwY7ey3}VS@}bV%6Y`;Z_dl?wwJWfT7?2m7)olBbzDXR}i-uQ^ajs_O zi=Hx*_ede`*O#Dy9<}f9EDN8$muEEsTQzLHoN=loez(yyz|U_KM@H8D6n+f_5>jS| zUQ}+d*6072EIMtPvnLrSdlekzyn8D*60sw%9DXfVipWW4oDx{FDE13M zgH@}sXT#|=*;3*4qv+P_q`NRdxo2D7RYY8OQe7G{^q?;q#a=;RaL&PGKry~ z#{kw4UkqNCGCyffc2cW?2Qy-%3I-Qz8|e91z?2i=^;Y$%8t3U=HFc*&3PpcS1-tua z!bbEuN7pa+JI4M#Yu4F>zd?LA^cq@M7zD)bK)9{PYT{oHr1*mRsp(=0lSgs^7Ln`b z;js!}5+o@|K*|m8{5m7c>aAh?zKoH?3HT8Z@O9rqN)XXMe($sR%ZwAmfg06@>(yiw z2UDj(AS-cI_Vh&J(uzCUuHD2if;Z#Tx334s=RL`jX*gUiKj08{eE${M^sY5u^Q&JnNZ1o}NlJr7?c8I>_>{Nrfmq_-REdWYwZA0#pxaUpF4_t9qV> zkheO2&M)Vz+gxs!d(JddurVT@d>)0Jh~-H5W`D?ah9ou6FTl}?27<5P$HxP!dvluF z_;y73?>jRD8N7BdxJfdw*)X)z`Uq=i!$Td)vgg$_ZKUwsv*H&@KOxAdA zcH4eazK$=mZ@-MhR)hV@3mO)wUbJU~F_G}?Y2p2fr+)i^V(HY87*a@wj{-AI8CPc* zt#@6#^$`!iHhd=-A6-IWW1kQcU#R2Q2y3TT7vB{gDkFt%xA_MIc%o5KZvhcw<2YBr0GR}*jbb+JpS=b)2=xiB%= zkrxChhNiEP85R#k)-yxMCq4FJdi%=WrPRMy{2Gz3t!@oI2RiFe5d8C7)Ujf=Zn?i5 zKnc_>c(xvq(1yNvk?%|@gVGKlyn6H7CaL`Rr0tc zrk@=<5SrNH;-c)0YoV!Dt=2`Md;kFJv==)ZW`gvGYZQOY6k-mnjfuE#0HjdvOC0Lf z8OW*7B`_)Kl^AY^J~qaF`N7`e(5tkyo-G3rJjB!^Ze< zB&5WQkQgREKsZd&0T8esz@Su%YmWtxnf}iKdN*&|E9?27WB2xAB`?4-5=9j}NrXf@ zoTW)^!Taw6TVYloWe}y#6S~SqNE9VMiaS=Zz>->i_jy$|tE~VbCTMbfdiJ!1{oPce zXDSN}()W#y4Q`_$G7)0H1*ozUb}xah@;y!eOzenWJz-t0Kc7eviQ zI4184FM1&WUa0|8)Hq%xU!;d|E5M_-VJ>aQG2OQGkAs})sk2m$ zc(YnYk|UhF@XQTiSPu=SYSid?81o5#^Zdg-WcflP8d&3aA3p)W&{xQw(T4$dq-Hio;z%8Xw?+f~_FdC6 z&U+Ab!L%HuA3oxdER?5P7w;H6 zTlMK)&axEI*{@zejJXY>e_jsYw-(cm!wNwZ;tgv1bnxA2W=3BpfIrqaGei0@057}8 zg9|k&+CdxQ_fXbX`>Mu~ly9|Qi(d8r44}n+R8KOnYz3l-!h$1xZ5fm1$d5;R(~(}L zrlyP@FaXShI+&U=ouvyX3Au%%Ukh4a9eh2ef2EldwO#5-9m^tDn|9u(Zaw`+c`Cdb zFO2JF(~hha3Rt6T-&oV(@g)R?X__E|%ve7tPsnfL|K?WEg22NXXo?K?wAq__ceydmfLQqbvWz<(6%#Kfb z1RDEtfEbB?V+vbzA`x zF!t4G7bE3|7th;$ZRop51Yf1xTb))~>|pV_7$7Nfm1Ka?1CK2Zo*AvM6PsIj5@MWO zW5iT7>D=@|+EE+S3jMA%apI|=IDUY|fQ;>en_UXxm*w|QVR#nW8~h4Tk@yF88HJ=S z`9%aM3+jproTGF~7YQ3e!(RlM<8PWFCwY&Kauz%;F*EPiT`Y=5SPpCI5y?iM)Lg9nQcur#0p=15V$=0b<&|73ikYF&y!}U5n@-f)8QiY9 zlA#a-TbI4qZj~|7Ofun^dy2>e>E`Xo8s>0P<@!3X`IfC>a%@8AkVcow^W(MHSHUqO z%nktQEh%h2Y~Iqt!=7pio-!GCqbRAVy<@V^%l(FQfY=${!I+I(u;Dp~@-=46vBN6X zN=Ust2gi(6)3H7vxlD(rEIBm>o(#NoMuL^{+55yQOb5xHv7_%7R_T{&Vq z);)Qz!UrQCx!&L#Y>11Lr6>Ic3)01%u8t^sNB=zfKo7?yFN$;f<#6QtR>XSDzA#2U zHc5bI_}CGuzoOj>K4yzIHO?aiD)sQ643k;~sPG@{4K-u2^&NRS~%u1aX;v60-fHwas@Mq{}@cr<` zvZn%&q$3>f=@N=)5)DmW7{gDwyTl8n1g=lFL|$McIh~ai$0A)rO-(KI>`k3M{&Ko` zQJZ(7ko|>jnG)_W#O!xv`07{&qEOiXpBX=c*Q?c=UO$h#W?wLdvziQj{w1VEsB({~ zG&e zUQQwBlMh#hifCwj2z0T6};UOFszzvP|Aosc=?&J!M66gSnTlbeVIMdSBnQ~i{WfM2mp$Kpb>8;Sk0;bw9fE>_GDtdH zuIlI}xipAm@!;Z^3~|W|I{cObxXdd!G(&J1wsWgcjaA$tW0mN(N{U5*&2Kgn<{avWIjmQ<1{$^il!YVj>5sf z?*7IPY{c%K0=E=NcjQBw@E0+k_;SdDF?l~!a>Gh#P?*fM&WXnrZ=AT!_HW4A!8no8 zGi2|gJkon{R{zLEVQi%iwXOsZJAf8@GGVMUbqgcEA#V5n67F7?XTO+&?^PODXOnUB0a}3}#zZXz?cQpj8dBS^`2a+%!ik!VS}cPCWQQhV!}Ne_aa-kL zQq)Yg`m%+?VIQb14?6FsQcg~;r>@#~b8ooc2ig8J7GgVf_PEC+15O2*mrPoPqdF|{ zV`Fv0Xij`%uhha8wJJTfF~k? zm#DP7`h_FrL!%&S!8u()uFm!Yb+M8aVlyaWpT1tfK3B zbZz!PFjiD>E-EBShxd6Ys4ge#IY&`6D31%hUpPdG*%=n|FP6yhf{;#C zdpx5&M4M79DoLQsu~%a9D&)ltyClG`>D=3o0#hCc@f1K;no_|25r<(Y9h9@KDUhAB z)=>fSoOIUHG)+?5jbF3?24oeky1OyYpH*wXX7Fux#e0;|ORvaE#awH=*BYVg$Q+_2W_&vInU?KGR&N-%w zT>N6SqMvI&Tmkajz_*n=f6#RRoNmSEY7LtUqfg>{><1@)oPm%@5(U_ZxnJox{bi3z zy{6icHH3NRd^7h)6uOKgLTj07?)PEBzgtMaw2Av7Okup8R4dDu7Po22Ub`qLD8%$` zY;1nsO6mUQn%;1CAgZz}hLs4S@rYm9s%5gP5yXwtM}JKrV+-3T1io&!3htIcGT^1j zek5rMYbn?BxIVJ*g4Qh_m z3JpCVE+gr90B61rDzW+z3A?BLT78+e%qR-jd`#L$LH*Y^GV-J@XW`0~C=*PIKxyh- z_49C=3L@VIk_wNU2YP{Zt0U@%y=oK%xzBRj!AX=+4xO3@*!5l=JtMG@)Cjin{ByO9 z9aNoL-v)tf9$JlUc>czJdAX~X8<9_WZ_D9sVA)~V)daPttGJ}TsuvnWtq)}R4sstl zC~ZGlMT^q%Pe*ocHRje-SKqBt(SR-5bm4xy0C^*MT(HR>q6JCE_1zXmVTuB$ZrW!S z*0WLAF(>L51YPOXA~$Q-Si`Q9It~-rPVI? zxP40{XENX$+MgT(3ScFJbu7t%QWD$1bUnSyJMr(5tDulSi?~hjEeUYf3!hrNxxMen z3m?~WW*=*t+Q$A#v`SMSG)LA@wpYcDIQ8Im-N*b=u;K;WtFw?q0UUpJfHmp!c9BzP zDcjDynSKtt0DG}?UhVicLI$bCr8J0p3#4c5Yl<0MlmpI^0wqB@IXSryZ0_6R)`(mw zIx!3wid;n`za#Kz!^6W1U)lZ?;zXIS_}0+8Mud#H6EDMD!pa2n8&<4bSL2A;lGJ)$ zNVzlHv2L|(7@#%fYXaA&vZbejX1x~^`C?SA?kURVl=}Z!$Q0jl7Teo@wk)J_j0!e= z0y1P9vF|v;?Cf0c^8&4;BgABX0G(|fvX@gl}1%n0wdI5|LzyiZr&dvmi-kWI{r{m^~5iOgPS3h zskpTYWpTiFZE9)?CC?ld&c&6d9Niv4w^EQ8zDNBtE@tN;fWDlpqL^zz_1j)syC-aV z&*Qej4TfPV`$Q|sSCyY@oGcc4bp3O-Yxh4dj^B`Cyvtt}yrRudR*fFM9!%M8TiP0ILRP|KJP=A!yw~ zPywA$bEq2Y0u<%V`*~`+{8z*zweKkxr+&B{Lo#MY&uBgu>~HH{tChJJBEfnfn?W`& z+b=k)7_7UkmAA5E?;g8ol4H6Qo=&S!zMW=UF)HVKJ8%6@$!q^~tM-qzHS0x}qbp$V z=rqrefrAa`ZfMbUUH^cHVH3F7&i1wr+r^7n89F?L2wClWof6|*L%JsPw^wg{FVwot z?~(f1wpI`AEoTCY%XWJvWo6#xnaV@U@uQe%ym;PgBaYCDs z3ZU@SAc)FH?sGiiH+tF2$jpqu>o1eN<4V%e9r^GrxpgbUp{#35p2d0f8yCmdFVW_i z&0I!{PGshxH*5VS5+ij|SEYWXXl`Z;m8V{4vNx;Y^>`F8A5+Ppcf2Zm%&J~WHh=f1 ztP=Kn{hBee%axOQ!yx&!JQ6h)zEx=@cX?bi;ygk>`Q#&q5;fV4%l+jKAI5k6ybXuV z8cgp!+&?&=br54ZkWGj80m{giPPf@mVAa?YE}sS#9}wsSO2vzfU9(?-xKEZ|)3o#6 zPpN;`7%Izv6id7$$>s#^`De|OfkKC2UTo~bSkE!IViv*ZBScKN2BK34u12Q`_%nc& ztIQ7gHvk+Y`4dh<`UI{$`1#*2{2$06FDv%9zGAMI1!zqe030X%vz247rza@Nev^)#q(!G{4aQ&_sAQI+BGddg-mC^2wc ziWaRb`NB*f2FII`5n^s(u?LElQ1Wy~9E(MCbhJ75qnF7eUg+YN&Q#t$7v4D`G02q!*%K5_aF~vl^Sh~yjG9DI7`_~4Fjq}7jvhbsu5OeRP6;JOK zC7`)fnh=5hY|3vpb$RugY_#QfDWZzYfAt*ov@2#;_r*@BxjBeOP7q!bQh*x^j)b;6 zrYw=TP4eo4Pu`ixN{~nWb21E+8|;7nw4%V&cK#x8_H{tLw8&|<>}~!7BC}2_-jAqS z&B&T@5*^0B!ZNXcD5SG8HYgV-dXlYM$QB3+q|7O}g@w>Nzn1jf4ibe-wHj2+2Rw-d zqW-S^{5a?8>EQhTKvesH6H_VOF#*Ysp#gb#l*EWfkpRKlT(STbv4}&jyX`w!M;cqt zueGiu-suK__PhhwWgh(qsE=fcJAJ~?!^=04L*fjUXvD%DvFD4d|N1J|TL!QtReai& zZmH>(*<;WpQ2XkYpx-zVB)Yt~Xl5V%FjZ-J(;{@&w{ntni2m>5{6D0r(i^TP2BeC9 zzdF6Q?gDrZ^B^J9MbYE}WkT<+6egEH3xB=pgqDIyKK;8sVi~?wnYa$D%Y9@x$_RraQ3+<=>|n<;=D(p)VzdAIS^NYRF?EI8Zx@wiUm~Q%_)z zv;hTPcv6;L28V79E_;CUb;$M2>9ykXs1K(`8i78Aiy-J@Pk=etDRJ&-jTx*asLch0 zs$%pz#A*R`;v+yGF&ae3H%`|cK75$kdHmcjV9?rDFyFU07KfG^R3wFm{XKwrmr0XH zR68^IP)?+p^f4U zS->GdYX0j;tU{%C4Vz1q#=T{uf!*%5klcmf1Bd)0Z11{)-;dA7l5QiT2~yDwGx!$Zp{}%#d39(>Bcw?O`3Q5%zp(SP|o}tY+s0K9gC?&4USB(lS81i_9vR7ynT_Ys>J&DN1`!~J%k*)oy8vhv%tH&p&sQH z(>7G;K}Org8)*l`^iZ)8ZTYQ=wq{cXnyVn0H+rd)E-EiCZMQieK0gvkwyWi|^Cxo-PrQ ze=c7x;l;-3tI;NMvF7W@-qG{e)lmC~pm#1lBF@E5Wip<59I!eWQ>zD&B;t$W{_%*ep7m%FR+5DH}0z z$oEte&KfX#=9IEGA5%1s4v)#uhVvv5M#0)Ig; z|NS<>e?pnG+y4hH`~Q1vLvZ@92lfTULIg4Zvgf#xWH;J3p!n4l0ww!%e7v}ZD`-R$ zFCczU$JJ?`UWzP1*PGN(YtVu(KXGodI{qD~UhHP!h_mMU_$Dw|`3*mw9Qv75E!y$w zZ=~>xyL5d1_S9_2Sx_^%xL79DVaX}nc9Th1$OCla*j_T|m?*2B61hk+-3#6 z4|p+T6LKfWp=V|6O7W*pBY>Nr%^76?@kxIIIgEG#<1n9-rcLj^31(`_ryN9*T04t< zJwM>RwenLGO!BVY#HGn)l9C>Wg3d)Y0S{TNERGM(GOGWTkQ8;$Y37y}7CME{k$3@K zTQvYH9F}ZdEGGdU`f*~771LIDC>wF*lt6>}&)o_lz`u0}ul=M}p$?Pwg-h zI!gy^&DZU?f$ynOFlZ@8^dWX6FbXlrKYR)FBGuaw%Ew#O_R;(yNTP62h<^WDLKHiOmhNjVpil)_*k21D zTcQFM@WiDWYHHZ3E`9#|SxmN7NH|-|#I;ywykUQ{LL3qaz{zegIX7L&)?N1=FJVQU z`*X1V$v8@wsR}qNQV%|*i!X!$Zm1wdiTN^y-WYg)-{%?tgyk4pS9;FvmjWwV@Ze{N z*>ey}=kyG{arr-FXhH^L2mr0AdF|Az6!ed^V?{3@G@CTrmU`w-_U0?=WJAtDL!}%P zSxTwl)4Te`9yy}p++m7u{Fg^G>`(ZNc0dUBKQ$tobl?J^6Q<~v&{gy)e5L*}rZUM4 zG-JjtB?DMIFMwKmocpV9!wRleYy2vQpM{Ohbd68s5JHmUKPEPe1QP=#8BpPStdO+C z?{8f+^t*CPR!=Hh*h6_y8Pb>CB~_*EQas=|A5ANW3+1D3U-kXo8*KmK$@vdIIO1ad zV_xS`+uVd2aa~Kxi6zDBT~Y*CsWun(swiR%r_22s_NWKBk`%~iSJM^rPzV{oSXz4_ z<^vg^kiGlC!AS8Rk{5t2z6A}&!8govF9c1=;?t@eeg@U7U_YhY&@O1wVa|O)IU~cl zsx`K*D3HHpz|T5N4{u@*GM1K97#bPb_1hN768KLg003}B;7PVz;2M*dP__XL+MH`P zYHbDd3`@POj3-{wE?+U-bG8fUaf^6JlO<-lRCrPGu$RHNdcM7mGy&}$n!iv7_K3H0#8drIsAIyVVK&ni4VU_ z-EL(>N*Yi~AY|=Uq}?JhjQ#8JJ`@4c`wf+49o&{~>euvvac!iYG`(@PXkpj-r;#m8 zHcwnQw@ARQAs%q=nl|ezQ->6XI*tjKd(j{G%=mX8%sM z{>|OljuaFMrDnbyHGoJZeInX?mr*5mUd+`0sh40w_(ZtUU0kY*3{d=#31}x@& zztLx{(cEV+YaJJH!!`TZ@fcGb)Me}{WHfd>Sv`}L;1sRLuc zvT$yp+W`%m|3l@^qs|GpMa;!L_#!*-9TAjmhkJ{k5fD5y`}lG5jTt?qd)k#a%-B>7 zk4x*;n0O*apC6a0DBBq?6F@X*efdDA;?_ju_K$w2k=JH+#QYnu|GVJ%k^o0dM>b&P zmiFaD=R~CFAXR&D$DR}7QT82dj=+)eiy<8saeECV6DIK+Dr?jhJzG8*Lq_xCquQ|^ zTdRB5KaB3(!nX$9BHg`OpT*HkcQpwsyX9-m_sy4#!K4@nPJ*{T0H4lLa2|? zH$!;>>Phk*Z11|4^3IwGP@mmA%(;4n-}mGC&6OVI`S%CT4(_k_xq} zrg7Jf*BR4An-AqW4yGpB2cGnMU*CQG?I-&MO~J`7lj8$z<^HFo`YO+R)l!RG!*3n8 zXipopwa~<>R<1q*`9=ACu?u)@D~F4nv!}ao?ziw~elyW(M(XTG{7$FU&Azs?0SJKB zD=jodARGT_x2E1%aKDYjSey{=NVM%XXJ)kO75Jqo)?@Nj_QtSxGqEe*V%c(`nH7KtTD~6TT(? z3E`?io`}}rsS?g0f%1H~9(+os!@rCRPBmES6Z^n?Mi`h%nKxCB35bjYAK8(Yb}sNQ zsu~&^HUO4@|0V#V!VEEj4x(u(K4@$ghNe~PFZOZfJ{+%y6w?&INq7AyE`-?r#dUyW~FWw6!2b2q)lX5LR0nG*q=WY-~-b-LoNp$-+&qu!k zG`B8evHyT%D#gAln!zV76YZq1ldtvKi>Z22L6Gp9;H~fP-yI#;uHkB-*q>Ov2;tWSMPSi^a*%C-Jrqx zA1qo8)7ds_5PT-`OOC>hyqCDNIte*+zp%gJh8 zxLDCZ=hAg7QFT*OcD%&@s7wXo5H!|Q%dK)8iTH2$=R-he%%Se$Iyt%? zG&ih2dPxKg3uX3Qb>3_=jWW04$I#@bYHzJb<(dBtD~mYddt#2sK&@DCy2WjMs>$L{ z$A2viq))WVa~%{@E-=|ybFcbW=0-H>5=^uMZn@a6d&Lr|-?<{dP8UJ76Rn@}4#?Q<1Oaf5~`<8^?6?SaOg)u&QK zkZ#li+~AWB-vp~iOp8Rq&?`3O35&A*H}h)#X1C5z(?E@&T}|h6S3v7Jcz2&{9aK^K z;8-Sz*+MFF=RLAv&m!PGAKb1on|D|B{wn9o(7Wvd3Y||oL>g4nMzXEF&?$UKAtZ*`_p1O(&w>rcE zqy}d%MuwmTz!_-ybBwwZlwUX`_G0H$cN(TL(n8>%u4+;h8Lj>|ndJRoz3ZkF?RfB0 zyacsPE5FfdH*uW;&h0^{$r1h?$5Yq>J)opb%-2W-Ro;YwrgOE6qg|ksLK)k0$7OeC zD?tc~Zk*h};`*@n&6B?jhN--;(I0<@>bYr6R%Kx$|yQui~b55KDfhv)Lo zelX8yT)WWoQrtn*_vM36z6H6=3e2t7|EdA1L_&yah}WLC)~F+1u#_$7lso_1{SV)C zy*B5p{xk!r5*ZWdsw=@$i_J6{%`LZ77ShE$+8z1*5OS*KNfMCBz5hCAr(AFPX}vN0 zmjH%#H3Q&V4R5;6n!B4@)w=H~5mI`IOaKrpMBjO<5B}-Pi=8(8Vzo+_d@0AoXXYI> z*6eZq6#A+Jn<94%Dh;UmS{u9({jI<*+kKa@yK7R2)veeuVc*cWb*0sV<7NOK9i{6y z^6k^-MU)cy(M%cbzPpqzXv^JTc_mKA#s*Ld%GD38?wv2p2pi?Ny$c#SI;c@Emtx|jW zy=Timhb9g4*#&3qs$iP)g+O5X7;y>N@!v|u`0%*|i!E)ZZA7m$ea)w7i z>OvY#Rux8}K@UNUG*bDi$whgb11q7H9$vT_*5uZ^w^UZod|^xW4%KYydi-%LL6E4n zi2iZAG97hija@*fk&A}9aHk%5k@Rw+IDw!nsb}LRUe|Vaxn*!ddglh(GNIM8j zFghv8pI-oL9{RspJIk;twy2LE8Wa=}kuCx0k}!w^BHe-rA}Afw-C&@XMnI766p#|7 zl}pEwmIe`!5+nr#-Zh8&et5sX_rrajd(W_EX3w5Id$0BX|CR`Bl@aAMUa_cvJodkb zo2bQcttC8#5WQB$2IFb|7qf+3YgviB3lg%2J+5O1KO9X<{@+QBjG6w=pOgL-{Lw-T zOS9m9%HX<}lye|~`uvL-c0h6l1p5=T-Y?HJ zGggy%MlcgY_{0fWvLGJ(ctc;I3`&7)w_5scV@GC;Ma34lf|4qQik-h2v)|?Gqe7uL zbQ*aH1K3zxv((u(*Vfi*C;pPGj1>F${q&LsWrC~_F%_7K@<4_NDgusu!`{^2-xvQ` zq-Bqi8b^XVkTEZfc08~k$0h2D(r{paUzCbadR<0dC<3QoX~@~ z#Yw8**}a@2H159_s@JlSCN~CUiD=<1K=kISt;eWja(IBeOmT^c@saNw+L2F-J zv$Y!}*3GzZ!x*5`z~~n9t2-YzSs1^6v0`0jZDplahv2iW{0fh`&5O!UfM^QzHWjF@ zHy&e174kTDCw_*J*NzKtGV*J4hMcbXvG;Th9l<6ws*o6i<-CH#S=F)yL{9DgL0b69O9s zTYT50A1_CL!R463&Hv_7KDDPqW%c|!Zbm-e8X%sit zi-WuD+n%9Av?ksv=dB%a2RecJEgPJTx2cvI7oaU95=EiyhuP|laWCVod(-I>@K#kI z&b^^B+m94ASoYXDQgNK)aDVM4X*GdxDx~Kyh<%b*GBW~3Dh0`fYVgt_nsyMsscwFn zXjI;tf)R0(EIX@=NycTSDX0b3U}nF|b-pYMlN5>NkBNQSW=7>Rh#CIUX?+rZ`JLd}m;6bz}r0Q5+{qKQxczB$|(C7PO;?UWjahI&HaYJ#3sZTda<2x}w zd`Suxm1@!M=*12T`)vI5{#Ev>^IgYFi`=A4_fq$w{L&V$L8|U+xcHP6CRj`aM$7NC z0@s5SFhU^uV=zKo?Du0UM7=~GyatdB?^3T&D{r*_KWpY~l_1_P`}@}-mJuH{C(gOn zF=u(pT)F~LL5%}}BDMdDAS<+&y`yIqzQw4Ag9sp%8fp&(=3nd!>ET{DjaU&htf#Gy zrWfvvLd*&>OI;jvMwgXMnFwb_ciW}DYmEv?7%W#!WjveFDlJ&b`0(MwUs?p-w}zMIRK5j5Rt|Y~w4hR*|I(tAo5AdgfR4dAS`3 zS+b2KoOg9~_wR!#625wfU-Vw9?=-gg%UGJ9px}E&D$Lm&zSjjWxJfT}tdBHA4(;-7 z9!TGA9ax(SBJAhEoJf`nR;^-!mD5wD;eDUZZ#*)|OVUgGz^ zJADPSfwkofKod9Q35dl)KYfCKKs@(x-qUmF@i&UGCT^B{=ccqg!*SoGJYWt#5-fb- zcalQ}(Ye2s@vR6!B6=*wK-Qu(dWOqRL-_3~13kU3!BY#(1LZ+c>`;0DLrD^bQmZT{ z2Y{@2F9t`}P`n~n{LN|)Py(fE!1P)1nljYo?Tsc#BP-|QhBXqgRW!=Bd4+dWt2*H) zhuZEH=O+#iWN9~i#h78|eq&&kd z5kInkLN<4lndg@Gt<>dD1|Kx4BAx1swY+x!IO*)tD8vdWWUt?S>?vpKC!*77^vkB2 zDSCQE>+LNQJag*coU+Pin-V`$#6$+GHxE|Mk2(+{k=5wut;y4)qx z-gu=N-8A^5G4e?oZ;;1phER*zo^xjW2ed3Mse{+nzIm0QpI~s?b{Y)nmRF^`?3m zx@4Xq2T{^HL?$ynzJl2Mvx3!7bC4_{Ruv+CT^C93v|$+Oi7d%fnQN(8!*H9P-;$%g zV+h~5{#`-}Sg4`>OnXAVfzHj$(+OGE^*T`yILCY1Qz6&!($fL+^)cXr}HZXdX9l*0KPD`kt>io4D@bEyj%ufiO|d7@kA{%fO9w) zO?w5_k?KeTRZY~xb+5?4vC`b!tnmq1Yih<<4!`rdK!9@r$43_Ov$)pXh%AW5^xP+;FY_-iH1%ag)(RoN z+_37=N3>sqNmobS>0g^^MNFOZpL0k#`&yH+#)+!%7=BJXIC8_}#l_Bw&t%YfHi<$D zm+gt6!weW9=jY^C0_;r=g4B`KU@ONlYV{gscQCjTH%DFOQI;^J!g^$tZ0p;>?n~v)4zR1YDsTZC;BlnA;OOUSdX!ug{(logYKnWS$9E<*Ay0)8#9br+dAi z%lynvL4q_r;h2Mbf@Auf{y7_5wb--%^XE)`Hu!iefK#>*WZJgd;pi>$jL`kvmAJ&h zs)g*cCM`7m&V7lsQJSO-&wXY2@oqmY`#|p=g6?W^^@o-$=8Io*HP(i0v_jCQ^BOL@RhrE4! zq`4;nFXOnw)cF!l1d=bVrCo(f%$3JSJCl>eCAg?`Zt(dP#R>)dQf{Iht9F>a0_It` zD5GTdmWn0Km84NHmhT?sAA!&3 z-{CmK1ff0y`J2R$aP7H4GTm5&d@+#d>jjw0>CL;(n|}nfnGvLsfu3MZ!_J}hy(RQ= zMf<=35rwiIVm>E{>zX$*{j$*}EFld?zA8G_REHsBV`o?8F*-@7+w>||iSwbr*{9Ru z;JXId+$b1J_d0?sD@Yf?*#3$TB4z@JVgBrla7@aPN0{~qct3=uc?ds~{krlDe8-^( ztIhOLXKa90Yu$hvj=(~R&dnnm@NfedOZaSD4PdL{o$bEtRZ|WZ`&1O+pkC?n$JaUo z$L)|L>$<){fzJdvC%htW_gg3CgPS_;n@Ozu0A3+O(>hpTOir6>CO%345PxbYg)0C%`aPmCh2IJn(yDiB)u zI!wg$WNCT%%p@sT`}iGz}l1H#I};jwWi>$;@2 zvpl6~-p(F)kwr^zJD;k!Uk#)u|2T*YIHpmUOfnopg~iM+BqyK@%WvTTO*K~~@Mj!LK!MyuFk8C6>LKqqVg3e&C^&gwfORfzHI{^Z8jV9J$(SBD3iY$it$zh$I`HioQRG+XWCa@j zd>^qXzFR)s(>}P=M+KUfqYThv>g(ZPQ88fp%=p{nQA?43kLZWj0bkZmFyvC~Nb(dW zBv6k?C+0tvI$6rzG7pLDN9%6+p1j`Obw7-LfkuWK(6cc7@Qo$hGwpuB{tA(Z+EkZbiMtt&5owcSiBf+LW82HiEubk5 zZCB>8B5LtW;-v%G(;1=(N)i<7uJ(kAK>ap^&PNo9>*aT299}QUfgF=-MSH2TKAAp& z9HA9~%zyr6LvI|KZzX0|lB8gIz+if~ukZ0XD;bLHcEplp=kdA?jZsmUSLn8jGF>2T zZuoy50Fqb+pw__reZ%?d7|(5iM4aVTMr)6D_4#`qUhBP(=~;eOOS-3q2uUGlakndr z4}G-pZ05@c)rCcX!9<`9aP|%DLtRT>ai^^Vlo8T@3Ebbgi9^b3X&J z8@sIh;@9pL#MUP>pgMaSUdYQXUV>YQLLJzcx786*lBwe^ag$_EgJ~N9Mm<{p*Q2B5 z@;K&-Bwr%VqmH1BK5fOgK<=~u);?wan1+!d5H$La{pPB~6-aCPEYEHcf>GB?8maMJ z=0Ey$4>dgp&Kpbvhas-EnP-|pzg;=o&L_XZ*RXy2@t=z~?*DQb2W$;8%Mi&p769T~ zd1YRn%V)IMZ{70l5=@8|sv1E2nFOjEAR86=<5!}X{HNkj>M~2Jg+hBa#nqiS+cE;A z>x~|Vy9{+#FImxJjpUf!uupPN7w?oCf0WBzBg2bVH1)$vX7%c;gSf@9IADx|8QfpM zFzg_iu3nE%qUu3W=lNTYn`zbPdedn$Z6qc#LO|Z9rt%WHXAESR6B!vSK5w>I?Ydj! zS5(Y!DpYMEGSCts$}0q*5~tC_y9l3Q8TiyloB#fMP7jwe@>xG)^oOj$$|+EQEqG1c zrnq;09B4^(PsGN593C%0=s_0qz$Q%pJ6DxlM9k%m1p*Ly#l9GxjuZ4wDMEyO#p&R_ zP~g5#ED_YIf7EKsoH=ukE9 z`lVVb#aN>*s;}$;B0^6Oi(8Y~EeQY@y zC+)Rq3K@;v%}1y!?;VtWORTF-C$wZN^1XS{`bpTY!Pb3(mkhl_48Wi$I>JnC7$t8o z^T)SqjKjg&ZqitpBA+;X;6x)`((Gu-nIRgjxcbAdDBqIe`XbDNEsv@BciCLIi!s9e zUAB+Q>Nu#nZZ9ZA;%i>~Xn6UOJah3WFO~g?D|_I9AT!aQwm2azt2iUCDbt(8?t})? zTxa(seH*w7`}m9x#|Dp=1}?X|Y@2JRE-CpKeXEQgQvVQ1pvm-udZ#3!w>Rk_iRyI# z8e*qipP8nM!V)l!zcLeM?oL7%^~2Bkp#b- z=DOQ1#n{5a0u{+y1e|zAvh+^wWq_r#VT$^{S=B4jTI9#Z;S5}}NbUFb&mXkjG%WMTPPy6>ta8|<-fM+R-7^B8 zN{5d^-~#FAhOh9OB*D72I21XN&m23Q=32^g6`86*wo2M!6_?Z^yBN*8iMICkzx>9> zr-s{TMmG`UtID@&Y1{S}o&EZqg30Vj%2jLg9+W+wYDDsMLg_2>I;l}68O&jTjCF}I0Un#EyzY9A`C-LYT-QkVm-Tv>U{j2ka&E;v!1Fe+o^bD_mrwip8FJ}oe zzQzMoLMTPyD)0o9@^9KycX@u@s=M7!)URAOJA38MG?Tlz5^FT|hTrsYt@_5n!PB@A zV~0lfZe%v-+Ee>jZszFd_}Ue7!-ex?lEix8A(xk6C6kQs-D9T2AB_Qps;bdzJ)0+@ zw_8c}ap|aI%KZ{09LxWzuI?rCOTTKO3|2@NP8 zg}xI_+w#Job1o~nT5KLpo5Dw)>QetC7(_nR&j!u!cgc;9I> zn%u^9^1?|>JJ0TY#C|rE}dL{I+y+$=%^VIN@=2*fspPvr1CQ!gcxdCme z(f<>8fpEj}=BgSBmX^J`Sc>#}$ip6GxYlB?kj$zvO?B#LE4l~x((mDg3TWrtNfQ3i z{}BF;kS(<7JUDSB0VB9Tu4oH3qJ}sX4;Zerk?(L^%BlVe=;4a~gEk<_Wsp2z`Bei_ zldqbog9a`I{5Fh1mFEnR6}b7!?G<7AQ~Y+DY|akZ>Gw}G6m4)7uyP-)a-^1#+a4^{ zP^7N!fqR2_{mP#7MpGVJ?9_McPc&JBk-KZt)AMj4O8zpESO)dXOuFO)?+-~ZOwoSd z9*{oOLoBur$p$3=HvLw&=-!TZYW(ZjGA#1mt*OCb+xrXWG8tSKC|oA4-gPBVZGXq05n)!JatxSA-6CR@Ivv22Eo?O}7OPQrHUSOxp& z;5OZJtwA0*;iuEZ{^k#+4o7_vJm@~!vRZ0w07ne_@2${4DsyiG7u`uyV!tw=s zuJ4SF9s(Ub96g2xt%u!M!d_>Tcnh3Zhebd8=<&^z;~Jiz8Uhfj9e?0%91ZUSjV_`P#x=3i*>UU3Bvde=QjRvyK`haE|+s zv6qk1kMzrh*;h_eO*_co%c_y{fTP| z34dOsFaif@BU`gAwq{1nPR!SYJ$FDBBGoKF;&yM}*S|`5!PxBjE#$H0)3wD8Gx1P` zrh$qrH{ zEZ{0_dhJQF0^TU+G%VPlgue6Fa?*`DP2VGZs$zciI8XbWTm>8?nvoB_jWk6=MQVc1 zm)Eir$X7;6rJM0TpNJ|y6kx~Pf)iDlWjGh@9!WoOa0qBp!{NO66o*46L-XU8=d;r7 z8=c5NO1JqdBC^n&l9G~SNR|$f*#yT{>U!9S3~8=3zP>v1$(|Mt(su7i{9y`ZD^5Q8 z@C%lK2QUFkcIrvmQzyxPxG5(w4jMg_YV48nipHhT7K}2vf8{3GCyLk} zY}17g2XM?=_W@25JxVXA?B@;9iW3AlP7i8DZZMY@M)z1GfefIO)>MjHLzRCXhN06q zkIZ%`lsYjzEp?(p9z?0z_OR2ZUbxlYuzMeAt|>v1LuNY$slL())mQ#--b@dHA~IEo zUb2h7<|lyvremJ9iz4?jV|G;9e~`AjHonJ%Py*g3;c4E18zO=5Ub!IYw1CDpy6j}i z9++M0(D`AbW^Au=2bLa8(g$*bg-8uzkY~X-W*6%n8M}ym5H|7e&Nootf7S!dySg}0 zdgld2tqK@6o6y)*jqj(pR`{q;wBLMG(RZN22b76RJohLkB?4(76Vem&=%&hx$F0;` zP-?~;xxzuNtidb&e$9JF0k&Xrywro652?h#I9M?oEKL=Kbtp;~i@^77`Ewwz;Z}yW zv3ia+gw@#Nar52axSS;W8f)#Y?WGagVm*KY#tvVb;DEt!i!fHGn){UB`)5@%{TO;^ zFZH5&oOi8iPuK@!hID0puD-l(+=!%cAP|FSoPx`dz;nj&aW%O*gqFG6*q-}O2Ww96 zowc*GdkOb&6W)^M^4V=b$c=a^7n8<$ht^T|x+TFw-XD#$-Y>E2uD;mQGi{HMVF95I z1#}!?Jx4*3H`4z3H!W9boLEsMygC2QCh$tEiy%VGs_Nkk%*mn<>7qZsUx~+fPt&W;&+K}dljYeMw?ulJNtlbI0ydRqftD9MXI~$y3f5wUvUz?d@ zS27 zCjren5==&yOM0H{D2G&dnq?(HtRk6bqlzDOh z(az}J9P;Trqmv*cAK)@s;}X&k@HTJoh5X7{vrXSo*VM{4ATC5vrx{tFSDEorjJS2) zx;Ox&F@EO(i7G%WeK9L9Z?W?I{lD2-%Ma~s%vyb=hDP^g^l;oFq17_173lnVf#{ZJ zc3nRRYISns+dr?$(rAP;5}?rk_(?BbboTwm(iXNxakE;fe}cv3R{v7vnikG(){lRE z=Jz(MwNod^$iw$f*kX_4iUMoonF(w(_4MNRLUL3vq?J+v+jSM@eNMr^ug4#1Dc>ix z&Qq~1j|B1%nNM@l!<^izHKzF8=g%<;IROC4UyGd!qCca_2gCJ@{*#j|Qh{&_^`PMZ z&c?fkRp^IT!1t+0b@gT%MqqJ$|n_ znD#Qi?mzGI&O6tf(z)m1mAWSf%l&~Ih0JA$(zZa9HYvVNVy}hfhDD=-?2=ju;W7o3 z%6sJ8l)QR)EKBk(6!y9#l9&cdw+#G|JHmRjT~Do|*$i)`3WTH1qOO+e;l4P^k2M-M z3$R(&u5GI@#jJ?7u3{yVyHh^v^%}p8ddDoK^ZvFE76kB~U5!+{!Ij8x*{5wT?0J7( zQBcioW&%g;RfeaRdG8Af5I-F)4@_M0nj#&yHMMAGEt>yx-)pM7|9$~YIVy>ZsGnwY zUhHdc?84|e0ZKI8c#LJ_T&L7px>ljauJubDYR1^3DVEVihJJ(i*7E6u(>uFDU3B>`n*AQxtyZPal-Pm#Kl-*DCxQ1X8p^JX0f8@Shrriq0mM);pKYMxz8}J=%C32+rWwzt&ZCE8) zPNtv`N@absu;yi~h!4vkX;8O464IAw98=Tn)QC}2bFi|rn_Ra^&%J;!E&?xn+k0i? z-gn30Y~}G5H*qG$y>Yir9M<;RpJ?;-Pfw)3s`lp~PyNU(YmiCF%U|Syn;4UXtJOSw z9p!6&U)H>aJzHQq$nJcnPZ;!>12j8t^gYo%v;foO67qS1{RAl3ku}rU!4r4unM0=6 zFMgA0M{Hj(8B$p(1xEY3KA^4()@qxowEw#Ge>d2?c zUu?Uj{bZa8D9k_($_M5RT+(0;;L!CB4908c8}4=vWRBKQ*_f8B|6KihUJp+f<`U?o z8dytQzDhwthaTZH<$q;C*ZCfQBLc|yd~irO_K?I6h=VF4BjX^*`6h znz2n(g6xtJ9-nBNzlBx*-ZX!6?DJCF9E~?(Gaseaym(*-_sd08GY;F2*u?|yC44*O z6^m+=MocgLnut>4uKW` zEWr76!hNNr6>5rfsf~&%{fojh1nio=StBmnU@QazN9R1YAGs~CMd%tDRKkTutgH<~ z9*B7yf`AgrhMcRV%|C-}OqH4>wFai#%=h;z#aU}wt&RxwqtwGcWWK9BJ_f+r)CYvq zDUPQ@kG)rOm%pU>XPy?Z`5JNE<;m{hvy)@@tuWtR-9|nqC4}4|*lzpwEz%SMp1KAr zBb~BaWWqb#)-ft{T734)iaAqP8n4XRq?=&xmpTT!NW`QC{3Cf-P-$eJ&1GuDpLE~! z-i>_%zY^F{N$TNVYVJkiEdm9aoZZ5$hTP36?5;)}M?BelF|A~;Y+|*RF|eWsLe+oP zB6S$E{=#o1R0uw|D6gonSAKJU%S(%KKQANMcW?wd3u8k9h-SjbMdOu=)7^BOX)>YV z{~e}JWmB(172IX`=SN9(_?1}AgB1$plL3glvmy?q!Giyw1bJ7hkne;`mC$16wpZs? z@7=zS1>0zmn#XHicA%}925|0U?Cpty9iw;G?}V2o)jDbTfR`j`cXP}od-UrlFPSIT zk$gcl4BA@{$yBkPD0JNG_ctn(3gTb<^KX|9HUDc6W%0$j=azrIb|zyW2gm7W%;HcI z>}Zc5yA^?Sv|tccF9hqwEhrL`(-U9dHI_ioj}aGsbL>h&a5h%RvfVR8oS0LNpV7 z%5-_$O5rR+KfZ2>LESXtUp6zbAgX~4)fxEcBbmLIoe5_rC^d_B4`eoiu}LvPbz0;R zrYj>=^TGs)SLdTFkschI-#?DSM)t^(DNj$M?e4@x>rzab7GV)s2)XXfHJCfvhMJUE zu(win3XdP@cn^8G!eL?a?p)Bj^$azsU`M>pCmn9L#>>GD*OVFD?xL$|AR#V^ROSW2 zcjoB;PxsqdX4-G9yBplxN2*y>BIUmNEx;aS_FL?Nz0L+Q|~RW!0xWNgi!hVZREsr<)csTe%TsU5i~E0v>6e= z46MM5$50~w4Ayked=O$BrD0?|ju2khL0TZHTC6XCSb~&ZR*(}SuSYY$H+c;#Z^fXc zn1lytkqG(gG)&sMjR?q@;eZqfmJ+>uHUp(=F~|W6Jf;nk;O}l9veGmxhlru3<#4HS zKrqSETVdLv$PtXdGoS;dHjZA_X8;|*80f8p8jr#T#yrh=Sv2W34{Y zgZMVt@tPHcji9q`4kM7dR3RFga|+kcZvDztd%L^-qtwlQ_Q-AxxsEE}XKNaiMn8s9 z1<=Se=Z`HWk4v-w5`kZFvb75wsB`=wd@OpX2+7!s;_@ljjud$X-&=y>K>&j4@MR5N zg;&kt6NOvYN(H=0v|+s4Cq^_|Z7?u&)5G_xAQSbjNb4nb=#jNfiR4CM0+fQ+!(niX zW=odVBe9$k`IOTqOqc~vnE8(#jpG8zP)W!0#~x6ovvVl_S~3gVwUs8+K;xSAT47IU z7*fL-T26-*(kN!wO>`N{1xpV?pxm7sU%&DR{~)C-oHWYWLAd<4OXL}5up@{N)C^xHX*MQLh6c&+E63Cf@1$K9K#@A z&;mn9d6WJq4Qe1oYkL2ymLZQFL?~sXBnM4#Y254pyk9Am+NJ6T{*RG$l>He|&{;q; zo)NMcj&DhtdxVoO!Fh@_NuLfu4g*dD^-ZA{H|Te>L|v)f+Z~zVCBOG_{m@vf)iJYJ z9y`Zw;9||5G%?YSh2ZBHwmy%=t$k2o3<5O@T9+ThzP?BHG{MLPz_v*r#Ltlr|DnYW zo~C?wEyRJn2eJ)s>mv^!(E^elq88A_O`%YS!8l6uAReAy97uPyWS4C8vIsX8jG^J= zSWpiEbDYVYU9&j&hu0Vq&6=~(5yGBUJ)}OynkDVzHR&{zQq(P)=G=MXdJ|BOS~(xh zAf}4CddJo-L}p`LxE=ZUsP!q^buVtk*U;*ocFJ}3|ND4tJXncKys-snwal^O=ejvI z;VvQK8cJFk0wZYWY}VikEF>89vO-P`GV1z3QwgHo-5R?gm z!hfSV#?c&PMVPN`aN-Vr20Fcrr`S7u75==x2YG3!U}{jN*;<5J6VmRNxS#JKQy8;5 zoOr|>f`K&7xcEce)Hzc?Ole%TQ9W(DGZSQOaRw{;$jb+%R_)^#3(f9A&;P&uvm;w@ Z!gMIwttjR#!iKb}bVpsTME23s{{aY_cD4Wj literal 0 HcmV?d00001 From 9f3ac159d49c8b8aa9b4922618814b45bd83c903 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 17 Oct 2022 21:41:48 +0100 Subject: [PATCH 372/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 5aba8c785..cffceccd5 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index afcd11531..e3d36263f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 61e52a3ee..35dd126bc 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index a152f7f22..6744fdcd7 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index c95745506..d0ed18395 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index f7eb1d054..a0ccfcb2d 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 854190837..14b757ff8 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index afab60ca0..df76c3dd2 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index efba68e78..1801468bc 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 11526888a..e0c5a0a5a 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 5984f4379..8b0431989 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 4216e832a..6ba6caefc 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 439a0fe5d..5c822c8ba 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 5e037ef9d..60907a8a8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 9f7239f13..6736d343c 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c095f468f..a5c7fc13b 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 259b03f4c..5fd83508b 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4056--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 8de2fcc6f..ae5bf633c 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4056-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4057-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From c94472ec42875ed026da8149dd7c8ce29052d605 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 17 Oct 2022 21:54:12 +0100 Subject: [PATCH 373/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index cffceccd5..c71ef0f58 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index e3d36263f..bbeccc95a 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 35dd126bc..20340b643 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 6744fdcd7..dc8499a3d 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index d0ed18395..a3167d01a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index a0ccfcb2d..dd95cac2a 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 14b757ff8..121fba868 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index df76c3dd2..a1bbde32c 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 1801468bc..29439a243 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e0c5a0a5a..7f26e718a 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 8b0431989..fd6baf7c9 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 6ba6caefc..90f4e1c83 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 5c822c8ba..dd2c718e8 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 60907a8a8..454d880c8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 6736d343c..04f27bc8c 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a5c7fc13b..bfdc93363 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 5fd83508b..a123610c7 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4057--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index ae5bf633c..f0ce27228 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4057-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4058-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 24fa8ffb9f204fb80e30063ba67d21af45f6de8d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 19 Oct 2022 00:33:15 +0300 Subject: [PATCH 374/887] Ability to report coverage on long lines. Sourcecode lines that result in more than 4000 chars after conversion to HTML should be reported successfully. Resolves: #1232 --- .../ut_coverage_report_html_helper.pkb | 15 +++-- .../test_html_coverage_reporter.pkb | 65 +++++++++++++++++++ .../test_html_coverage_reporter.pks | 8 +++ 3 files changed, 84 insertions(+), 4 deletions(-) diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index 2bb9a87d9..f7e0b5ed0 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -134,9 +134,11 @@ create or replace package body ut_coverage_report_html_helper is l_file_part varchar2(32767); l_result ut_varchar2_rows := ut_varchar2_rows(); l_coverage_pct number(5, 2); - l_coverage_block_pct number(5, 2); l_hits varchar2(30); l_blocks varchar2(30); + l_line_text varchar2(32767); + e_buffer_too_small exception; + pragma exception_init ( e_buffer_too_small, -19011 ); begin l_coverage_pct := coverage_pct(a_coverage_unit.covered_lines, a_coverage_unit.uncovered_lines); @@ -148,10 +150,16 @@ create or replace package body ut_coverage_report_html_helper is ut_utils.append_to_list(l_result, l_file_part); for line_no in 1 .. a_source_code.count loop + begin + l_line_text := dbms_xmlgen.convert(a_source_code(line_no)); + exception + when e_buffer_too_small then + l_line_text := dbms_xmlgen.convert(to_clob(a_source_code(line_no))); + end; if not a_coverage_unit.lines.exists(line_no) then l_file_part := '
  • - ' || (dbms_xmlgen.convert(a_source_code(line_no))) || + ' || l_line_text || '
  • '; else l_hits := to_char(a_coverage_unit.lines(line_no).executions); @@ -188,7 +196,7 @@ create or replace package body ut_coverage_report_html_helper is '
    '; end if; l_file_part := l_file_part || ' - ' || (dbms_xmlgen.convert(a_source_code(line_no))) || + ' || l_line_text || ''; end if; ut_utils.append_to_list(l_result, l_file_part); @@ -222,7 +230,6 @@ create or replace package body ut_coverage_report_html_helper is l_file_part varchar2(32767); l_title varchar2(100) := 'All files'; l_coverage_pct number(5, 2); - l_coverage_block_pct number(5, 2); l_result ut_varchar2_rows; l_id varchar2(50) := object_id(a_title); l_unit_coverage ut_coverage.t_unit_coverage; diff --git a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb index d1645acae..ad14adb8c 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb @@ -32,5 +32,70 @@ create or replace package body test_html_coverage_reporter is ut.expect(l_actual).to_be_like(l_expected); end; + procedure setup_long_lines is + pragma autonomous_transaction; + begin + + execute immediate q'[create or replace type string_array is table of varchar2(5 char);]'; + execute immediate q'[ + create or replace function f return integer is + l_string_array string_array; + l_count integer; + begin + -- line is 1912 chars long, 1911 characters seem to be the max. line length that works (@formatter:off) + l_string_array := string_array('aahed', 'aalii', 'aargh', 'aarti', 'abaca', 'abaci', 'abacs', 'abaft', 'abaka', 'abamp', 'aband', 'abash', 'abask', 'abaya', 'abbas', 'abbed', 'abbes', 'abcee', 'abeam', 'abear', 'abele', 'abers', 'abets', 'abies', 'abler', 'ables', 'ablet', 'ablow', 'abmho', 'abohm', 'aboil', 'aboma', 'aboon', 'abord', 'abore', 'abram', 'abray', 'abrim', 'abrin', 'abris', 'absey', 'absit', 'abuna', 'abune', 'abuts', 'abuzz', 'abyes', 'abysm', 'acais', 'acari', 'accas', 'accoy', 'acerb', 'acers', 'aceta', 'achar', 'ached', 'aches', 'achoo', 'acids', 'acidy', 'acing', 'acini', 'ackee', 'acker', 'acmes', 'acmic', 'acned', 'acnes', 'acock', 'acold', 'acred', 'acres', 'acros', 'acted', 'actin', 'acton', 'acyls', 'adaws', 'adays', 'adbot', 'addax', 'added', 'adder', 'addio', 'addle', 'adeem', 'adhan', 'adieu', 'adios', 'adits', 'adman', 'admen', 'admix', 'adobo', 'adown', 'adoze', 'adrad', 'adred', 'adsum', 'aduki', 'adunc', 'adust', 'advew', 'adyta', 'adzed', 'adzes', 'aecia', 'aedes', 'aegis', 'aeons', 'aerie', 'aeros', 'aesir', 'afald', 'afara', 'afars', 'afear', 'aflaj', 'afore', 'afrit', 'afros', 'agama', 'agami', 'agars', 'agast', 'agave', 'agaze', 'agene', 'agers', 'agger', 'aggie', 'aggri', 'aggro', 'aggry', 'aghas', 'agila', 'agios', 'agism', 'agist', 'agita', 'aglee', 'aglet', 'agley', 'agloo', 'aglus', 'agmas', 'agoge', 'agone', 'agons', 'agood', 'agora', 'agria', 'agrin', 'agros', 'agued', 'agues', 'aguna', 'aguti', 'aheap', 'ahent', 'ahigh', 'ahind', 'ahing', 'ahint', 'ahold', 'ahull', 'ahuru', 'aidas', 'aided', 'aides', 'aidoi', 'aidos', 'aiery', 'aigas', 'aight', 'ailed', 'aimed', 'aimer', 'ainee', 'ainga', 'aioli', 'aired', 'airer', 'airns', 'airth', 'airts', 'aitch', 'aitus', 'aiver', 'aiyee', 'aizle', 'ajies', 'ajiva', 'ajuga', 'ajwan', 'akees', 'akela', 'akene', 'aking', 'akita', 'akkas', 'alaap', 'alack', 'alamo', 'aland', 'alane', 'alang', 'a'); + select count(*) into l_count from table(l_string_array); + return l_count; + end;]'; + + execute immediate q'[ + create or replace package test_f is + --%suite + + --%test + procedure crashing_ut_coverage_html_reporter; + end;]'; + + execute immediate q'[ + create or replace package body test_f is + procedure crashing_ut_coverage_html_reporter is + begin + ut3_develop.ut.expect(f()).to_be_greater_or_equal(1); + end; + end; + ]'; + end; + + procedure cleanup_long_lines is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_f'; + execute immediate 'drop function f'; + execute immediate 'drop type string_array force'; + end; + + procedure report_long_lines is + l_expected varchar2(32767); + l_actual clob; + l_name varchar2(250); + begin + --Arrange + l_expected := '%l_string_array := string_array%'; + + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_user.test_f', + a_reporter=> ut3_develop.ut_coverage_html_reporter(), + a_include_objects => ut3_develop.ut_varchar2_list( 'UT3_USER.F' ) + ) + ]' + ); + --Assert + ut.expect(l_actual).to_be_like(l_expected); + end; + + end test_html_coverage_reporter; / diff --git a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pks b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pks index 629d41793..a11f3e912 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pks +++ b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pks @@ -6,5 +6,13 @@ create or replace package test_html_coverage_reporter is --%test(reports on a project file mapped to database object in extended profiler coverage) procedure report_on_file; + procedure setup_long_lines; + procedure cleanup_long_lines; + + --%test(reports on lines exceeding 4000 chars after conversion to XML) + --%beforetest(setup_long_lines) + --%aftertest(cleanup_long_lines) + procedure report_long_lines; + end test_html_coverage_reporter; / From 82707159ee485915c55506d608d0e6143bf99247 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 19 Oct 2022 00:45:25 +0300 Subject: [PATCH 375/887] Fixing name that was too long for the test before 12.2 --- .../reporters/test_coverage/test_html_coverage_reporter.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb index ad14adb8c..2f2200116 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb @@ -53,12 +53,12 @@ create or replace package body test_html_coverage_reporter is --%suite --%test - procedure crashing_ut_coverage_html_reporter; + procedure fail_ut_coverage_html_reporter; end;]'; execute immediate q'[ create or replace package body test_f is - procedure crashing_ut_coverage_html_reporter is + procedure fail_ut_coverage_html_reporter is begin ut3_develop.ut.expect(f()).to_be_greater_or_equal(1); end; From 7925a75de38eaddde5952e92fd8f6ba5ab8500d5 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 19 Oct 2022 21:23:40 +0100 Subject: [PATCH 376/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index c71ef0f58..961ba3060 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index bbeccc95a..2b625c7d0 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 20340b643..a915f2a52 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index dc8499a3d..5d4ed97cf 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index a3167d01a..c391be166 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index dd95cac2a..2acd290c9 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 121fba868..3e95d2852 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index a1bbde32c..b39ab803b 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 29439a243..1a227d9e4 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 7f26e718a..d83142f9f 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index fd6baf7c9..1c1974319 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 90f4e1c83..e9681bb7b 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index dd2c718e8..fca38c92e 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 454d880c8..e7496320c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 04f27bc8c..1f5ead1c5 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) utPLSQL provides the following reporting formats. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index bfdc93363..a87fe9836 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index a123610c7..a219012fd 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4058--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f0ce27228..06b17ccbf 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4058-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4063-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 9e03e76d0c3a193611430113e9b0477712bc8cee Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 27 Oct 2022 00:20:15 +0300 Subject: [PATCH 377/887] Improving documentation --- docs/index.md | 14 +- docs/userguide/advanced_data_comparison.md | 26 +- docs/userguide/annotations.md | 338 +++++++++++---------- docs/userguide/coverage.md | 152 +++++---- docs/userguide/exception-reporting.md | 30 +- docs/userguide/expectations.md | 149 ++++----- docs/userguide/getting-started.md | 16 +- docs/userguide/install.md | 34 +-- docs/userguide/querying_suites.md | 16 +- docs/userguide/reporters.md | 46 +-- docs/userguide/running-unit-tests.md | 52 ++-- mkdocs.yml | 4 +- mkdocs_offline.yml | 4 +- 13 files changed, 475 insertions(+), 406 deletions(-) diff --git a/docs/index.md b/docs/index.md index c391be166..bc7e1e63b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -7,9 +7,15 @@ The framework follows industry standards and best patterns of modern Unit Testin ## Demo project -Have a look at our [demo project](https://github.com/utPLSQL/utPLSQL-demo-project/). +Have a look at [utPLSQL demo project](https://github.com/utPLSQL/utPLSQL-demo-project/) to see: -It uses [Travis CI](https://travis-ci.org/utPLSQL/utPLSQL-demo-project) to build on every commit, runs all tests, publishes test results and code coverage to [SonarCloud](https://sonarcloud.io/project/overview?id=utPLSQL:utPLSQL-demo-project). +- sample code and tests +- demo of deployment automation that leverages: + - Flyway / Liquidbase for scripting and deployment of DB changes + - Docker container with Oracle XE Database + - GitHub Actions and Azure Pipelines to orchestrate the deployment and testing process + - utPLSQL framework for writhing, execution of tests as well as reporting test results and code coverage + - [Sonar]((https://sonarcloud.io/project/overview?id=utPLSQL:utPLSQL-demo-project).) for code quality gate, test results and code coverage reporting ## Three steps @@ -31,6 +37,7 @@ Check out the sections on [annotations](userguide/annotations.md) and [expectati You can use the utPLSQL command line client [utPLSQL-cli](https://github.com/utPLSQL/utPLSQL-cli) to run tests without the need for Oracle Client or any IDE like SQLDeveloper/TOAD etc. Amongst many benefits they provide ability to: + * see the progress of test execution for long-running tests - real-time reporting * use many reporting formats simultaneously and save reports to files (publish) * map your project source files and test files into database objects @@ -40,8 +47,7 @@ See [project readme](https://github.com/utPLSQL/utPLSQL-cli/blob/develop/README. ## Coverage -If you want to have code coverage gathered on your code , it's best to use `ut_run` to execute your tests with multiple reporters and have both test execution report as well as coverage report saved to a file. - +It is best to use utPLSQL-cli or execute tests and gather code coverage from command line. Check out the [coverage documentation](userguide/coverage.md) for options of coverage reporting diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 2acd290c9..2e2d4af9f 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -48,7 +48,7 @@ When specifying column/attribute names, keep in mind that the names are **case s ## Excluding elements from data comparison Consider the following examples -```sql +```sql linenums="1" declare l_expected sys_refcursor; l_actual sys_refcursor; @@ -86,7 +86,7 @@ The actual data is equal/contains expected, when those columns are excluded. ## Selecting columns for data comparison Consider the following example -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; @@ -125,7 +125,7 @@ The actual data is equal/contains expected, when only those columns are included You can chain the advanced options in an expectation and mix the `varchar2` with `ut_varchar2_list` arguments. When doing so, the final list of items to include/exclude will be a concatenation of all items. -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; @@ -163,7 +163,7 @@ SUCCESS Example of `include / exclude` for anydata.convertCollection -```sql +```sql linenums="1" create or replace type person as object( name varchar2(100), age integer @@ -219,7 +219,7 @@ Unordered option allows for quick comparison of two compound data types without Result of such comparison will be limited to only information about row existing or not existing in given set without actual information about exact differences. -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; @@ -267,7 +267,7 @@ The extra or missing rows will be presented to user as well as all non-matching Join by option can be used in conjunction with include or exclude options. However if any of the join keys is part of exclude set, comparison will fail and report to user that sets could not be joined on specific key, as the key was excluded. -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; @@ -305,7 +305,7 @@ FAILURE You can use `join_by` syntax in combination with `contain` matcher. -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; @@ -322,7 +322,7 @@ end; ``` Above test will indicate that in actual data-set -```sql +```sql linenums="1" FAILURE Actual: refcursor [ count = 28 ] was expected to contain: refcursor [ count = 29 ] Diff: @@ -335,7 +335,7 @@ FAILURE You can specify multiple columns in `join_by` -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; @@ -371,7 +371,7 @@ To reference attribute as PK, use slash symbol `/` to separate nested elements. In the below example, cursors are joined using the `NAME` attribute of object in column `SOMEONE` -```sql +```sql linenums="1" create or replace type person as object( name varchar2(100), age integer @@ -414,7 +414,7 @@ FAILURE > `join_by` does not support joining on individual elements of nested table. You can still use data of the nested table as a PK value. > When collection is referenced in `join_by`, test will fail with appropriate message, as it cannot perform a join. -```sql +```sql linenums="1" create or replace type person as object( name varchar2(100), age integer @@ -463,7 +463,7 @@ You may provide items for `include`/`exclude`/`join_by` as a a ut_varchar2_list - nested table and varray items type attributes are nested under `` elements Example of a valid parameter to include columns: `RN`, `A_Column`, `SOME_COL` in data comparison. -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; @@ -494,7 +494,7 @@ Expectations that compare compound data type data with `unordered_columns` optio This option can be useful whn we have no control over the ordering of the column or the column order is not of importance from testing perspective. -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 3e95d2852..2c13fb649 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -5,20 +5,21 @@ No additional configuration files or tables are needed for test cases. The annot The framework runner searches for all the suitable annotated packages, automatically configures suites, forms the suite hierarchy, executes it and reports results in specified formats. Annotation is defined by: + - single line comment `--` (double hyphen) - followed directly by a `%` (percent) - followed by annotation name - followed by optional annotation text placed in single brackets. -All of text between first opening bracket and last closing bracket in annotation line is considered to be annotation text +All text between first opening bracket and last closing bracket in annotation line is considered to be annotation text -Examples: -`--%suite(The name of my test suite)` - represents `suite` annotation with text `The name of my test suite` +For example `--%suite(The name of my test suite)` represents `suite` annotation with `The name of my test suite` as annotation text. -utPLSQL interprets the whole line of annotation and will treat all the text from the first opening bracket in the line to the last closing bracket +utPLSQL interprets the whole line of annotation and will treat text from the first opening bracket in the line to the last closing bracket in that line as annotation text -Example: - `--%suite(Stuff) -- we should name this ( correctly )` - represents `suite` annotation with text `Stuff) -- we should name this ( correctly ` +In below example we have a `suite` annotation with `Stuff) -- we should name this ( correctly ` as the annotation text + +`--%suite(Stuff) -- we should name this ( correctly )` Do not place comments within annotation line to avoid unexpected behaviors. @@ -57,7 +58,7 @@ end; ``` Invalid procedure annotations examples: -```sql +```sql linenums="1" package test_package is --%suite @@ -88,7 +89,7 @@ Those annotations placed at any place in package except directly before procedur We strongly recommend putting package level annotations at the very top of package except for the `--%context` annotations (described below) Valid package annotations example: -```sql +```sql linenums="1" package test_package is --%suite @@ -106,7 +107,7 @@ end; ``` Invalid package annotations examples: -```sql +```sql linenums="1" package test_package is --%suite --This is wrong as suite annotation is not a procedure annotation procedure irrelevant; @@ -120,29 +121,29 @@ end; ## Supported annotations -| Annotation |Level| Description | -| --- | --- | --- | -| `--%suite()` | Package | Mandatory. Marks package as a test suite. Optional suite description can be provided (see `displayname`). | -| `--%suitepath()` | Package | Similar to java package. The annotation allows logical grouping of suites into hierarchies. | -| `--%displayname()` | Package/procedure | Human-readable and meaningful description of a context/suite/test. Overrides the `` provided with `suite`/`test`/`context` annotation. This annotation is redundant and might be removed in future releases. | -| `--%test()` | Procedure | Denotes that the annotated procedure is a unit test procedure. Optional test description can be provided (see `displayname`). | -| `--%throws([,...])`| Procedure | Denotes that the annotated test procedure must throw one of the exceptions provided. Supported forms of exceptions are: numeric literals, numeric constant names, exception constant names, predefined Oracle exception names. | -| `--%beforeall` | Procedure | Denotes that the annotated procedure should be executed once before all elements of the suite. | -| `--%beforeall([[.].][,...])` | Package | Denotes that the mentioned procedure(s) should be executed once before all elements of the suite. | -| `--%afterall` | Procedure | Denotes that the annotated procedure should be executed once after all elements of the suite. | -| `--%afterall([[.].][,...])` | Package | Denotes that the mentioned procedure(s) should be executed once after all elements of the suite. | -| `--%beforeeach` | Procedure | Denotes that the annotated procedure should be executed before each `%test` procedure in the suite. | -| `--%beforeeach([[.].][,...])` | Package | Denotes that the mentioned procedure(s) should be executed before each `%test` procedure in the suite. | -| `--%aftereach` | Procedure | Denotes that the annotated procedure should be executed after each `%test` procedure in the suite. | -| `--%aftereach([[.].][,...])` | Package | Denotes that the mentioned procedure(s) should be executed after each `%test` procedure in the suite. | -| `--%beforetest([[.].][,...])` | Procedure | Denotes that mentioned procedure(s) should be executed before the annotated `%test` procedure. | -| `--%aftertest([[.].][,...])` | Procedure | Denotes that mentioned procedure(s) should be executed after the annotated `%test` procedure. | -| `--%rollback()` | Package/procedure | Defines transaction control. Supported values: `auto`(default) - a savepoint is created before invocation of each "before block" is and a rollback to specific savepoint is issued after each "after" block; `manual` - rollback is never issued automatically. Property can be overridden for child element (test in suite) | -| `--%disabled()` | Package/procedure | Used to disable a suite, whole context or a test. Disabled suites/contexts/tests do not get executed, they are however marked and reported as disabled in a test run. The reason that will be displayed next to disabled tests is decided based on hierarchy suites -> context -> test | -| `--%context()` | Package | Denotes start of a named context (sub-suite) in a suite package an optional description for context can be provided. | -| `--%name()` | Package | Denotes name for a context. Must be placed after the context annotation and before start of nested context. | -| `--%endcontext` | Package | Denotes end of a nested context (sub-suite) in a suite package | -| `--%tags` | Package/procedure | Used to label a test or a suite for purpose of identification | +| Annotation | Level | Description | +|------------------------------------------------------------|-------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| `--%suite( )` | Package | Mandatory. Marks package as a test suite. Optional suite description can be provided (see `displayname`). | +| `--%suitepath( )` | Package | Similar to java package. The annotation allows logical grouping of suites into hierarchies. | +| `--%displayname( )` | Package/procedure | Human-readable and meaningful description of a context/suite/test. Overrides the `` provided with `suite`/`test`/`context` annotation. This annotation is redundant and might be removed in future releases. | +| `--%test( )` | Procedure | Denotes that the annotated procedure is a unit test procedure. Optional test description can be provided (see `displayname`). | +| `--%throws( [,...] )` | Procedure | Denotes that the annotated test procedure must throw one of the exceptions provided. Supported forms of exceptions are: numeric literals, numeric constant names, exception constant names, predefined Oracle exception names. | +| `--%beforeall` | Procedure | Denotes that the annotated procedure should be executed once before all elements of the suite. | +| `--%beforeall( [[.].][,...] )` | Package | Denotes that the mentioned procedure(s) should be executed once before all elements of the suite. | +| `--%afterall` | Procedure | Denotes that the annotated procedure should be executed once after all elements of the suite. | +| `--%afterall( [[.].][,...] )` | Package | Denotes that the mentioned procedure(s) should be executed once after all elements of the suite. | +| `--%beforeeach` | Procedure | Denotes that the annotated procedure should be executed before each `%test` procedure in the suite. | +| `--%beforeeach( [[.].][,...] )` | Package | Denotes that the mentioned procedure(s) should be executed before each `%test` procedure in the suite. | +| `--%aftereach` | Procedure | Denotes that the annotated procedure should be executed after each `%test` procedure in the suite. | +| `--%aftereach( [[.].][,...] )` | Package | Denotes that the mentioned procedure(s) should be executed after each `%test` procedure in the suite. | +| `--%beforetest( [[.].][,...] )` | Procedure | Denotes that mentioned procedure(s) should be executed before the annotated `%test` procedure. | +| `--%aftertest( [[.].][,...] )` | Procedure | Denotes that mentioned procedure(s) should be executed after the annotated `%test` procedure. | +| `--%rollback( )` | Package/procedure | Defines transaction control. Supported values: `auto`(default) - a savepoint is created before invocation of each "before block" is and a rollback to specific savepoint is issued after each "after" block; `manual` - rollback is never issued automatically. Property can be overridden for child element (test in suite) | +| `--%disabled( )` | Package/procedure | Used to disable a suite, whole context or a test. Disabled suites/contexts/tests do not get executed, they are however marked and reported as disabled in a test run. The reason that will be displayed next to disabled tests is decided based on hierarchy suites -> context -> test | +| `--%context( )` | Package | Denotes start of a named context (sub-suite) in a suite package an optional description for context can be provided. | +| `--%name( )` | Package | Denotes name for a context. Must be placed after the context annotation and before start of nested context. | +| `--%endcontext` | Package | Denotes end of a nested context (sub-suite) in a suite package | +| `--%tags` | Package/procedure | Used to label a test or a suite for purpose of identification | ### Suite @@ -162,13 +163,13 @@ If the parameters are placed without brackets or with incomplete brackets, they Suite package without description. -```sql +```sql linenums="1" create or replace package test_package as --%suite end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -179,13 +180,13 @@ Finished in .002415 seconds ``` Suite package with description. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -196,14 +197,14 @@ Finished in .001646 seconds ``` When multiple `--%suite` annotations are specified in package, the first annotation will be used and a warning message will appear indicating duplicate annotation. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) --%suite(Bad annotation) end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -221,14 +222,14 @@ Finished in .003318 seconds ``` When `--%suite` annotation is bound to procedure, it is ignored and results in package not getting recognized as test suite. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) procedure some_proc; end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -255,7 +256,7 @@ If `--%test` raises an unhandled exception the following will happen: - test execution will continue uninterrupted for rest of the suite Test procedure without description. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -268,7 +269,7 @@ create or replace package body test_package as end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -280,7 +281,7 @@ Finished in .004109 seconds ``` Test procedure with description. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -294,7 +295,7 @@ end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -306,7 +307,7 @@ Finished in .006828 seconds ``` When multiple `--%test` annotations are specified for a procedure, the first annotation will be used and a warning message will appear indicating duplicate annotation. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -321,7 +322,7 @@ end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -344,7 +345,7 @@ Marks annotated suite package or test procedure as disabled. You can provide the reason why the test is disabled that will be displayed in output. Disabling suite. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) --%disabled(Reason for disabling suite) @@ -365,7 +366,7 @@ end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -378,7 +379,7 @@ Finished in .001441 seconds ``` Disabling the context(s). -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -408,7 +409,7 @@ end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -423,7 +424,7 @@ Finished in .005079 seconds ``` Disabling individual test(s). -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -444,7 +445,7 @@ end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -461,7 +462,7 @@ Finished in .005868 seconds There are two possible ways to use the `--%beforeall` annotation. As a procedure level annotation: -```sql +```sql linenums="1" --%suite(Some test suite) --%beforeall @@ -473,7 +474,7 @@ procedure some_test; Marks annotated procedure to be executed before all test procedures in a suite. As a package level annotation (not associated with any procedure). -```sql +```sql linenums="1" --%suite(Some test suite) --%beforeall(to_be_executed_before_all, other_package.some_setup) @@ -490,6 +491,7 @@ Indicates that the procedure(s) mentioned as the annotation parameter are to be If `--%beforeall` raises an exception, suite content cannot be safely executed as the setup was not executed successfully for the suite. If `--%beforeall` raises an exception the following will happen: + - the `--%beforeall` procedures that follow the failed one, **will not be executed** - all `--%test` procedures and their `--%beforeeach`, `--%aftereach`, `--%beforetest` and `--%aftertest` procedures within suite package **will not be executed** - all `--%test` procedures **will be marked as failed** @@ -500,7 +502,7 @@ When multiple `--%beforeall` procedures are defined in a suite package, all of t For multiple `--%beforeall` procedures order of execution is defined by annotation position in the package specification. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -528,9 +530,10 @@ end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` + ``` Tests for a package --- SETUP_STUFF invoked --- @@ -544,7 +547,7 @@ Finished in .012292 seconds In the below example a combination pacakge and procedure level `--%beforeall` annotations is used. The order of execution of the beforeall procedures is determined by the annotation position in package. All of the `--%beforeall` procedures get invoked before any test is executed in a suite. - ```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -593,12 +596,13 @@ All of the `--%beforeall` procedures get invoked before any test is executed in procedure other_test is begin null; end; end; / - ``` +``` - ```sql +```sql linenums="1" exec ut.run('test_package'); - ``` - ``` +``` + +``` Tests for a package --- INITIAL_SETUP invoked --- --- ANOTHER_SETUP invoked --- @@ -609,11 +613,11 @@ Tests for a package Finished in .018944 seconds 2 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s) - ``` +``` When multiple `--%beforeall` annotations are specified for a procedure, the first annotation will be used and a warning message will appear indicating duplicate annotation. When procedure is annotated as both `--%beforeall` and `--%test`, the procedure will become a test and a warning message will appear indicating invalid annotation combination. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -644,10 +648,11 @@ When procedure is annotated as both `--%beforeall` and `--%test`, the procedure / ``` - ```sql +```sql linenums="1" exec ut.run('test_package'); - ``` - ``` +``` + +``` Tests for a package --- INITIAL_SETUP invoked --- Description of tested behavior [.003 sec] @@ -665,7 +670,7 @@ Warnings: Finished in .012158 seconds 2 tests, 0 failed, 0 errored, 0 disabled, 2 warning(s) - ``` +``` ### Afterall @@ -673,7 +678,7 @@ Finished in .012158 seconds There are two possible ways to use the `--%afterall` annotation. As a procedure level annotation: -```sql +```sql linenums="1" --%suite(Some test suite) --%afterall @@ -685,7 +690,7 @@ procedure some_test; Marks annotated procedure to be executed after all test procedures in a suite. As a package level annotation (not associated with any procedure). -```sql +```sql linenums="1" --%suite(Some test suite) --%afterall(to_be_executed_after_all, other_package.some_cleanup) @@ -694,11 +699,12 @@ As a package level annotation (not associated with any procedure). procedure some_test; procedure to_be_executed_after_all; - ``` + Indicates that the procedure(s) mentioned as the annotation parameter are to be executed after all test procedures in a suite. If `--%afterall` raises an exception the following will happen: + - a warning will be raised, indicating that `--%afterall` procedure has failed - execution will continue uninterrupted for rest of the suite @@ -711,7 +717,7 @@ For multiple `--%afterall` procedures order of execution is defined by annotatio All rules defined for `--%beforeall` also apply for `--%afterall` annotation. See [beforeall](#Beforeall) for more details. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -739,9 +745,10 @@ end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` + ``` Tests for a package Description of tested behavior [.003 sec] @@ -760,7 +767,7 @@ That means that the procedure will be executed as many times as there are test i There are two possible ways to use the `--%beforeeach` annotation. As a procedure level annotation: -```sql +```sql linenums="1" --%suite(Some test suite) --%beforeeach @@ -772,7 +779,7 @@ procedure some_test; Marks annotated procedure to be executed before each test procedures in a suite. As a package level annotation (not associated with any procedure). -```sql +```sql linenums="1" --%suite(Some test suite) --%beforeeach(to_be_executed_before_each, other_package.some_setup) @@ -781,14 +788,15 @@ As a package level annotation (not associated with any procedure). procedure some_test; procedure to_be_executed_before_each; - ``` + Indicates that the procedure(s) mentioned as the annotation parameter are to be executed before each test procedure in a suite. If a test is marked as disabled the `--%beforeeach` procedure is not invoked for that test. If `--%beforeeach` raises an unhandled exception the following will happen: + - the following `--%beforeeach` as well as all `--%beforetest` for that test **will not be executed** - the test will be marked as errored and exception stack trace will be captured and reported - the `--%aftertest`, `--%aftereach` procedures **will be executed** for the errored test @@ -801,7 +809,7 @@ When multiple `--%beforeeach` procedures are defined in a suite, all of them wil For multiple `--%beforeeach` procedures order of execution is defined by annotation position in the package specification. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -842,9 +850,10 @@ end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` + ``` Tests for a package ---SETUP_STUFF invoked --- @@ -871,7 +880,7 @@ That means that the procedure will be executed as many times as there are test i There are two possible ways to use the `--%aftereach` annotation. As a procedure level annotation: -```sql +```sql linenums="1" --%suite(Some test suite) --%aftereach @@ -883,7 +892,7 @@ procedure some_test; Marks annotated procedure to be executed after each test procedures in a suite. As a package level annotation (not associated with any procedure). -```sql +```sql linenums="1" --%suite(Some test suite) --%aftereach(to_be_executed_after_each, other_package.some_setup) @@ -892,13 +901,14 @@ As a package level annotation (not associated with any procedure). procedure some_test; procedure to_be_executed_after_each; - ``` + Indicates that the procedure(s) mentioned as the annotation parameter are to be executed after each test procedure in a suite. If a test is marked as disabled the `--%aftereach` procedure is not invoked for that test. If `--%aftereach` raises an unhandled exception the following will happen: + - the test will be marked as errored and exception stack trace will be captured and reported - the `--%aftertest`, `--%aftereach` procedures **will be executed** for the errored test - the `--%afterall` procedures **will be executed** @@ -910,7 +920,7 @@ For multiple `--%aftereach` procedures order of execution is defined by the anno As a rule, the `--%aftereach` gets executed even if the associated `--%beforeeach`, `--%beforetest`, `--%test` or other `--%aftereach` procedures have raised unhandled exceptions. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -950,7 +960,7 @@ create or replace package body test_package as end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -972,6 +982,7 @@ See [beforeall](#Beforeall) for more examples. ### Beforetest Indicates specific setup procedure(s) to be executed for a test. The procedure(s) can be located either: + - within current package (package name is optional) - within another package @@ -982,6 +993,7 @@ The `--%beforetest` procedures are executed after invoking all `--%beforeeach` f If a test is marked as disabled the `--%beforetest` procedures are not invoked for that test. If `--%beforetest` raises an unhandled exception the following will happen: + - the following `--%beforetest` for that test **will not be executed** - the test will be marked as errored and exception stack trace will be captured and reported - the `--%aftertest`, `--%aftereach` procedures **will be executed** for the errored test @@ -991,12 +1003,13 @@ If `--%beforetest` raises an unhandled exception the following will happen: When multiple `--%beforetest` procedures are defined for a test, all of them will be executed before invoking the test. The order of execution for `--%beforetest` procedures is defined by: + - position of procedure on the list within single annotation - annotation position As a rule, the `--%beforetest` execution gets aborted if preceding `--%beforeeach` or `--%beforetest` failed. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -1038,7 +1051,7 @@ create or replace package body test_package as end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -1060,6 +1073,7 @@ Finished in .015185 seconds ### Aftertest Indicates specific cleanup procedure(s) to be executed for a test. The procedure(s) can be located either: + - within current package (package name is optional) - within another package @@ -1068,6 +1082,7 @@ The annotation need to be placed alongside `--%test` annotation. If a test is marked as disabled the `--%aftertest` procedures are not invoked for that test. If `--%aftertest` raises an unhandled exception the following will happen: + - the test will be marked as errored and exception stack trace will be captured and reported - the following `--%aftertest` and all `--%aftereach` procedures **will be executed** for the errored test - the `--%afterall` procedures **will be executed** @@ -1076,12 +1091,13 @@ If `--%aftertest` raises an unhandled exception the following will happen: When multiple `--%aftertest` procedures are defined for a test, all of them will be executed after invoking the test. The order of execution for `--%aftertest` procedures is defined by: + - position of procedure on the list within single annotation - annotation position As a rule, the `--%aftertest` gets executed even if the associated `--%beforeeach`, `--%beforetest`, `--%test` or other `--%aftertest` procedures have raised unhandled exceptions. -```sql +```sql linenums="1" create or replace package test_package as --%suite(Tests for a package) @@ -1123,7 +1139,7 @@ create or replace package body test_package as end; / ``` -```sql +```sql linenums="1" exec ut.run('test_package'); ``` ``` @@ -1158,6 +1174,7 @@ Contexts allow for creating sub-suites within a suite package and they allow for In essence, context behaves like a suite within a suite. Context have following characteristics: + - context starts with the `--%context` annotation and ends with `--%endcontext`. Everything placed between those two annotations belongs to that context - can have a description provided as parameter for example `--%context(Some interesting stuff)`. - can have a name provided with `--%name` annotation. This is different than with `suite` and `test` annotations, where name is taken from `package/procedure` name. @@ -1175,7 +1192,7 @@ Context have following characteristics: The below example illustrates usage of `--%context` for separating tests for individual procedures of package. Sample tables and code -```sql +```sql linenums="1" create table rooms ( room_key number primary key, name varchar2(100) not null @@ -1232,11 +1249,12 @@ end; ``` Below test suite defines: + - `--%beforeall` outside of context, that will be executed before all tests - `--%context(remove_rooms_by_name)` to group tests related to `remove_rooms_by_name` functionality - `--%context(add_rooms_content)` to group tests related to `add_rooms_content` functionality -```sql +```sql linenums="1" create or replace package test_rooms_management is gc_null_value_exception constant integer := -1400; @@ -1355,8 +1373,8 @@ end; / ``` -When te tests are executed -```sql +When the tests are executed +```sql linenums="1" exec ut.run('test_rooms_management'); ``` The following report is displayed @@ -1378,7 +1396,7 @@ Finished in .035261 seconds Example of nested contexts test suite specification. *Source - [slide 145](https://www.slideshare.net/Kevlin/structure-and-interpretation-of-test-cases/145?src=clipshare) of Structure and Interpretation of Test Cases by Kevlin Henney* -```sql +```sql linenums="1" create or replace package queue_spec as --%suite(Queue specification) @@ -1468,7 +1486,7 @@ The `--%name` can be useful when you would like to run only a specific context o Consider the below example. -```sql +```sql linenums="1" create or replace package queue_spec as --%suite(Queue specification) @@ -1501,22 +1519,22 @@ end; In the above code, suitepaths, context names and context descriptions will be as follows. -| suitepath | description | name | -|-----------|------------|------| -| queue_spec | Queue specification | queue_spec | -| queue_spec.context_#1 | A new queue | context_#1 | -| queue_spec.context_#2 | An empty queue | context_#2 | -| queue_spec.context_#3 | A non empty queue | context_#3 | -| queue_spec.context_#3.context_#1 | that is not full | context_#1 | -| queue_spec.context_#3.context_#2 | that is full | context_#2 | +| suitepath | description | name | +|----------------------------------|----------------------|------------| +| queue_spec | Queue specification | queue_spec | +| queue_spec.context_#1 | A new queue | context_#1 | +| queue_spec.context_#2 | An empty queue | context_#2 | +| queue_spec.context_#3 | A non empty queue | context_#3 | +| queue_spec.context_#3.context_#1 | that is not full | context_#1 | +| queue_spec.context_#3.context_#2 | that is full | context_#2 | In order to run only the tests for the context `A non empty queue that is not full` you will need to call utPLSQL as below: -```sql +```sql linenums="1" exec ut.run(':queue_spec.context_#3.context_#1'); ``` You can use `--%name` annotation to explicitly name contexts on suitepath. -```sql +```sql linenums="1" create or replace package queue_spec as --%suite(Queue specification) @@ -1554,23 +1572,25 @@ end; In the above code, suitepaths, context names and context descriptions will be as follows. -| suitepath | description | name | -|-----------|------------|------| -| queue_spec | Queue specification | queue_spec | -| queue_spec.a_new_queue | A new queue | a_new_queue | -| queue_spec.an_empty_queue | An empty queue | an_empty_queue | -| queue_spec.a_non_empty_queue | A non empty queue | a_non_empty_queue | -| queue_spec.a_non_empty_queue.that_is_not_full | that is not full | that_is_not_full | -| queue_spec.a_non_empty_queue.that_is_full | that is full | that_is_full | +| suitepath | description | name | +|-----------------------------------------------|-----------------------|-------------------| +| queue_spec | Queue specification | queue_spec | +| queue_spec.a_new_queue | A new queue | a_new_queue | +| queue_spec.an_empty_queue | An empty queue | an_empty_queue | +| queue_spec.a_non_empty_queue | A non empty queue | a_non_empty_queue | +| queue_spec.a_non_empty_queue.that_is_not_full | that is not full | that_is_not_full | +| queue_spec.a_non_empty_queue.that_is_full | that is full | that_is_full | The `--%name` annotation is only relevant for: + - running subsets of tests by given context suitepath - some of test reports, like `ut_junit_reporter` that use suitepath or test-suite element names (not descriptions) for reporting #### Name naming convention The value of `--%name` annotation must follow the following naming rules: + - cannot contain spaces - cannot contain a `.` (full stop/dot) - is case-insensitive @@ -1583,13 +1603,13 @@ It allows for grouping of tests / suites using various categorization and place e.g. -```sql +```sql linenums="1" --%tags(batch,daily,csv) ``` or -```sql +```sql linenums="1" --%tags(online,json) --%tags(api) ``` @@ -1603,7 +1623,7 @@ When a suite/context is tagged, all of its children will automatically inherit t Sample test suite package with tags. -```sql +```sql linenums="1" create or replace package ut_sample_test is --%suite(Sample Test Suite) @@ -1643,17 +1663,17 @@ end ut_sample_test; Execution of the test is done by using the parameter `a_tags` -```sql +```sql linenums="1" select * from table(ut.run(a_path => 'ut_sample_test',a_tags => 'api')); ``` The above call will execute all tests from `ut_sample_test` package as the whole suite is tagged with `api` -```sql +```sql linenums="1" select * from table(ut.run(a_tags => 'complex')); ``` The above call will execute only the `ut_sample_test.ut_refcursors1` test, as only the test `ut_refcursors1` is tagged with `complex` -```sql +```sql linenums="1" select * from table(ut.run(a_tags => 'fast')); ``` The above call will execute both `ut_sample_test.ut_refcursors1` and `ut_sample_test.ut_test` tests, as both tests are tagged with `fast` @@ -1677,7 +1697,7 @@ In order to do so, prefix the tag name to exclude with a `-` (dash) sign when in Examples (based on above sample test suite) -```sql +```sql linenums="1" select * from table(ut.run(a_tags => 'api,fast,-complex')); ``` The above call will execute all suites/contexts/tests that are marked with any of tags `api` or `fast` except those suites/contexts/tests that are marked as `complex`. @@ -1705,7 +1725,7 @@ If you want to create tests for your application it is recommended to structure The `--%suitepath` annotation is used for such grouping. Even though test packages are defined in a flat structure the `--%suitepath` is used by the framework to form them into a hierarchical structure. Your payments recognition test package might look like: -```sql +```sql linenums="1" create or replace package test_payment_recognition as --%suite(Payment recognition tests) @@ -1724,7 +1744,7 @@ end test_payment_recognition; ``` And payments set off test package: -```sql +```sql linenums="1" create or replace package test_payment_set_off as --%suite(Payment set off tests) @@ -1743,7 +1763,7 @@ When you execute tests for your application, the framework constructs a test sui The test report indicates which expectation has failed on the payments module. The payments recognition submodule is causing the failure as `recognize_by_num` has not met the expectations of the test. Grouping tests into modules and submodules using the `--%suitepath` annotation allows you to logically organize your project's flat structure of packages into functional groups. An additional advantage of such grouping is the fact that every element level of the grouping can be an actual unit test package containing a common module level setup for all of the submodules. So in addition to the packages mentioned above you could have the following package. -```sql +```sql linenums="1" create or replace package payments as --%suite(Payments) @@ -1758,6 +1778,7 @@ end payments; ``` When executing tests, `path` for executing tests can be provided in three ways: + * schema - execute all tests in the schema * [schema]:suite1[.suite2][.suite3]...[.procedure] - execute all tests by `suitepath` in all suites on path suite1[.suite2][.suite3]...[.procedure]. If schema is not provided, then the current schema is used. Example: `:all.rooms_tests` * [schema.]package[.procedure] - execute all tests in the specified test package. The whole hierarchy of suites in the schema is built before all before/after hooks or part suites for the provided suite package are executed as well. Example: `tests.test_contact.test_last_name_validator` or simply `test_contact.test_last_name_validator` if `tests` is the current schema. @@ -1798,6 +1819,7 @@ Keep in mind that when your test runs as autonomous transaction it will not see ### Throws The `--%throws` annotation allows you to specify a list of exceptions as one of: + - number literals - example `--%throws(-20134)` - variables of type exception defined in a package specification - example `--%throws(exc_pkg.c_exception_No_variable)` - variables of type number defined in a package specification - example `--%throws(exc_pkg.c_some_exception)` @@ -1814,9 +1836,9 @@ The framework will raise a warning, when `--%throws` annotation has invalid argu Annotation `--%throws(7894562, operaqk, -=1, -20496, pow74d, posdfk3)` will be interpreted as `--%throws(-20496)`. Please note that `NO_DATA_FOUND` exception is a special case in Oracle. To capture it use `NO_DATA_FOUND` named exception or `-1403` exception No. -​ + Example: -```sql +```sql linenums="1" create or replace package exc_pkg is c_e_option1 constant number := -20200; c_e_option2 constant varchar2(10) := '-20201'; @@ -1979,7 +2001,7 @@ Finished in .025784 seconds ## Order of execution -```sql +```sql linenums="1" create or replace package test_employee_pkg is --%suite(Employee management) @@ -2101,46 +2123,50 @@ When processing the test suite `test_employee_pkg` defined in [Example of annota rollback to savepoint 'before-suite' ``` -**Note** ->utPLSQL does not guarantee ordering of tests in suite. On contrary utPLSQL might give random order of tests/contexts in suite. -> ->Order of execution within multiple occurrences of `before`/`after` procedures is determined by the order of annotations in specific block (context/suite) of package specification. +!!! note + utPLSQL does not guarantee ordering of tests in suite. On contrary utPLSQL might give random order of tests/contexts in suite.
    + Order of execution within multiple occurrences of `before`/`after` procedures is determined by the order of annotations in specific block (context/suite) of package specification. ## sys_context It is possible to access information about currently running suite. The information is available by calling `sys_context( 'UT3_INFO', attribute )`. -It can be accessed from any procecure invoked as part of utPLSQL test execution. +It can be accessed from any procedure invoked as part of utPLSQL test execution. -**Note:** -> Context name is derived from schema name where utPLSQL is installed. -> The context name in below examples represents the default install schema -> `UT3` -> If you install utPLSQL into another schema the context name will be different. -> For example if utPLSQL is installed into `HR` schema, the context name will be `HR_INFO` +!!! note + Context name is derived from schema name where utPLSQL is installed.
    + The context name in below examples represents the default install schema -> `UT3`
    + If you install utPLSQL into another schema the context name will be different.
    + For example if utPLSQL is installed into `HR` schema, the context name will be `HR_INFO` Following attributes are populated: -- For entire duration of the test-run: - - `sys_context( 'UT3_INFO', 'COVERAGE_RUN_ID' );` - Value of COVERAGE_RUN_ID used by utPLSQL internally for coverage gathering - - `sys_context( 'UT3_INFO', 'RUN_PATHS' );` - list of suitepaths / suitenames used as input parameters for call to `ut.run(...)` or `ut_runner.run(...)` - - `sys_context( 'UT3_INFO', 'SUITE_DESCRIPTION' );` - the description of test suite that is currently being executed - - `sys_context( 'UT3_INFO', 'SUITE_PACKAGE' );` - the owner and name of test suite package that is currently being executed - - `sys_context( 'UT3_INFO', 'SUITE_PATH' );` - the suitepath for the test suite package that is currently being executed - - `sys_context( 'UT3_INFO', 'SUITE_START_TIME' );` - the execution start timestamp of test suite package that is currently being executed - - `sys_context( 'UT3_INFO', 'CURRENT_EXECUTABLE_NAME' );` - the owner.package.procedure of currently running test suite executable - - `sys_context( 'UT3_INFO', 'CURRENT_EXECUTABLE_TYPE' );` - the type of currently running test suite executable (one of: `beforeall`, `beforeeach`, `beforetest`, `test`, `aftertest`, `aftereach`, `afterall` - -- When running in suite context - - `sys_context( 'UT3_INFO', 'CONTEXT_DESCRIPTION' );` - the description of test suite context that is currently being executed - - `sys_context( 'UT3_INFO', 'CONTEXT_NAME' );` - the name of test suite context that is currently being executed - - `sys_context( 'UT3_INFO', 'CONTEXT_PATH' );` - the suitepath for the currently executed test suite context - - `sys_context( 'UT3_INFO', 'CONTEXT_START_TIME' );` - the execution start timestamp for the currently executed test suite context -- When running a suite executable procedure that is a `test` or `beforeeach`, `aftereach`, `beforetest`, `aftertest` - - `sys_context( 'UT3_INFO', 'TEST_DESCRIPTION' );` - the description of test for which the current executable is being invoked - - `sys_context( 'UT3_INFO', 'TEST_NAME' );` - the name of test for which the current executable is being invoked - - `sys_context( 'UT3_INFO', 'TEST_START_TIME' );` - the execution start timestamp of test that is currently being executed (the time when first `beforeeach`/`beforetest` was called for that test) + +| Name | Scope | Description | +|-------------------------|---------------|-----------------------------------------------------------------------------------------------------------------------------------------------------| +| COVERAGE_RUN_ID | run | Value of COVERAGE_RUN_ID used by utPLSQL internally for coverage gathering | +| RUN_PATHS | run | list of suitepaths / suitenames used as input parameters for call to `ut.run(...)` or `ut_runner.run(...)` | +| SUITE_DESCRIPTION | run | the description of test suite that is currently being executed | +| SUITE_PACKAGE | run | the owner and name of test suite package that is currently being executed | +| SUITE_PATH | run | the suitepath for the test suite package that is currently being executed | +| SUITE_START_TIME | run | the execution start timestamp of test suite package that is currently being executed | +| CURRENT_EXECUTABLE_NAME | run | the owner.package.procedure of currently running test suite executable | +| CURRENT_EXECUTABLE_TYPE | run | the type of currently running test suite executable (one of: `beforeall`, `beforeeach`, `beforetest`, `test`, `aftertest`, `aftereach`, `afterall` | + | CONTEXT_DESCRIPTION | suite context | the description of test suite context that is currently being executed | + | CONTEXT_NAME | suite context | the name of test suite context that is currently being executed | + | CONTEXT_PATH | suite context | the suitepath for the currently executed test suite context | + | CONTEXT_START_TIME | suite context | the execution start timestamp for the currently executed test suite context | +| TEST_DESCRIPTION | test* | the description of test for which the current executable is being invoked | +| TEST_NAME | test* | the name of test for which the current executable is being invoked | +| TEST_START_TIME | test* | the execution start timestamp of test that is currently being executed (the time when first `beforeeach`/`beforetest` was called for that test) | + +!!! note "Scopes" + - run - context information is available in any element of test run
    + - suite context - context information is available in any element nested within a suite context
    + - test* - context information is available when executing following procedure types: test, beforetest, aftertest, beforeeach or aftereach + Example: -```sql +```sql linenums="1" create or replace procedure which_procecure_called_me is begin dbms_output.put_line( @@ -2199,7 +2225,7 @@ end; / ``` -```sql +```sql linenums="1" exec ut.run('test_call'); ``` @@ -2232,14 +2258,14 @@ If you are in a situation where your database is controlled via CI/CD server and To build the annotation cache without actually invoking any tests, call `ut_runner.rebuild_annotation_cache(a_object_owner)` for every unit test owner for which you want to have the annotation cache prebuilt. Example: -```sql +```sql linenums="1" exec ut_runner.rebuild_annotation_cache('HR'); ``` To purge the annotation cache call `ut_runner.purge_cache(a_object_owner, a_object_type)`. Both parameters are optional and if not provided, all owners/object_types will be purged. Example: -```sql +```sql linenums="1" exec ut_runner.purge_cache('HR', 'PACKAGE'); ``` diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 1a227d9e4..20707e917 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -9,9 +9,14 @@ Code coverage is gathered for the following source types: * procedures * functions -**Note** +!!! note -> The package and type specifications are excluded from code coverage analysis. This limitation is introduced to avoid false-negatives. Typically package specifications contain no executable code. The only exception is initialization of global constants and variables in package specification. Since most package specifications are not executable at all, there is no information available on the number of lines covered and those would be reported as 0% covered, which is not desirable. + The package and type specifications are excluded from code coverage analysis. + This limitation is introduced to avoid false-negatives. + Typically package specifications contain no executable code. + The only exception is initialization of global constants and variables in package specification. + Since most package specifications are not executable at all, there is no information available + on the number of lines covered and those would be reported as 0% covered, which is not desirable. To obtain information about code coverage for unit tests, run utPLSQL with one of built-in code coverage reporters. The following code coverage reporters are supplied with utPLSQL: @@ -39,7 +44,7 @@ Using the code coverage functionality is as easy as using any other [reporter](r All you need to do, is pass the constructor of the reporter to the `ut.run` procedure call. Example: -```sql +```sql linenums="1" set serveroutput on begin ut.run(ut_coverage_html_reporter()); @@ -58,7 +63,7 @@ The report allow you to navigate to each source file and inspect line by line co ![Coverage Details page](../images/coverage_html_details.png) -#### Oracle 12.2 extended coverage with profiler and block coverage +### Oracle 12.2 extended coverage with profiler and block coverage Using data collected from profiler and block coverage running parallel we are able to enrich information about coverage. For every line recorded by the profiler if we have a partially covered same line in block coverage we will display that information presenting line as partially covered, displaying number of block and how many blocks have been covered in that line.The feature will be automatically enabled in the Oracle database version 12.2 and higher, for older versions current profiler will be used. @@ -89,8 +94,8 @@ The parameters used to execute tests determine if utPLSQL will be using one appr If parameter `a_source_file_mappings` or `a_source_files` is provided, then coverage is gathered on project files provided, otherwise coverage is gathered on schemas. -**Note** -> Regardless of the options provided, all unit test packages are excluded from the coverage report. Coverage reports provide information only about the **tested** code. +!!! note + Regardless of the options provided, all unit test packages are excluded from the coverage report. Coverage reports provide information only about the **tested** code. The default behavior of coverage reporting can be altered using invocation parameters. @@ -99,17 +104,16 @@ The default behavior of coverage reporting can be altered using invocation param To gather coverage for all objects in the **current schema** execute tests with coverage report as argument. This is the default reporting option and therefore additional coverage options don't need to be provided. -```sql +```sql linenums="1" exec ut.run(ut_coverage_html_reporter()); ``` -**Note** +!!! note -> When no filters are used, the size of the coverage report will depend two factors: -> - the type of report (does the report include source code or not) -> - the amount of source code in the database schema -> ->Keep in mind that for schemas containing a lot of code, it can take quite some time to produce the coverage report. + When no filters are used, the size of the coverage report will depend two factors:
    + - the type of report (does the report include source code or not)
    + - the amount of source code in the database schema
    + Keep in mind that for schemas containing a lot of code, it can take quite some time to produce the coverage report. #### Setting coverage schema(s) @@ -117,7 +121,7 @@ By default, coverage is gathered on the schema(s) derived from suite paths provi This is a valid approach as long as your test packages and tested code share the same schema. So when you run: -```sql +```sql linenums="1" exec ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter()); ``` Coverage will be gathered on both `user_1` and `user_2` objects. @@ -126,13 +130,18 @@ If your tests live in a different schema from the tested code you may override t In the example below, coverage will still be gathered for `user_1` and `user_2` objects, even thought we run the tests located in schema `unit_test_schema` -```sql -exec ut.run('unit_test_schema', ut_coverage_html_reporter(), a_coverage_schemes => ut_varchar2_list('user_1','user_2') ); +```sql linenums="1" +begin + ut.run('unit_test_schema', ut_coverage_html_reporter(), + a_coverage_schemes => ut_varchar2_list('user_1','user_2') + ); +end; ``` #### Filtering objects in coverage reports Multiple parameters can be used to define the scope of coverage report. + - `a_source_file_mappings ( ut_file_mappings )` - map of filenames to database objects. It is used for file-based coverage - see below. - `a_include_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be included in the coverage report. Case-insensitive. - `a_include_object_expr ( varchar(4000) )` - string of regex expression of objects ( without schema name ) to be included in the coverage report. Case-insensitive. @@ -144,22 +153,23 @@ Multiple parameters can be used to define the scope of coverage report. You may specify both _include_ and _exclude_ options to gain more control over what needs to be included / excluded from the coverage report. -**Important notes** -The order of priority is for evaluation of include/exclude filter parameters is as follows. -- if `a_source_file_mappings` is defined then all include/exclude parameters are ignored (see section below for usage of `a_source_file_mappings` parameter ) -- else if `a_include_schema_expr` or `a_include_object_expr` parameter is specified then parameters `a_coverage_schemes` and `a_include_objects` are ignored -- else if `a_include_objects` is specified then the coverage is gathered only on specified database objects. - - if `a_coverage_schemes` is specified then those schemas are used for objects in `a_include_objects` without schema name - - if `a_coverage_schemes` is not specified then schema from paths (`a_paths`) parameter are used for objects in `a_include_objects` without schema name -- else if, only the `a_coverage_schemes` is specified then the coverage is gathered only on specified database schemas -- else if no coverage specific parameters are provided coverage is gathered on all schemas specified in paths passed to run procedure -- else if no paths were specified, the coverage is gathered on current schema of the session running the tests +!!! warning "Important note" + The order of priority is for evaluation of include/exclude filter parameters is as follows.
    + - if `a_source_file_mappings` is defined then all include/exclude parameters are ignored (see section below for usage of `a_source_file_mappings` parameter )
    + - else if `a_include_schema_expr` or `a_include_object_expr` parameter is specified then parameters `a_coverage_schemes` and `a_include_objects` are ignored
    + - else if `a_include_objects` is specified then the coverage is gathered only on specified database objects.
    + - if `a_coverage_schemes` is specified then those schemas are used for objects in `a_include_objects` without schema name
    + - if `a_coverage_schemes` is not specified then schema from paths (`a_paths`) parameter are used for objects in `a_include_objects` without schema name
    + - else if, only the `a_coverage_schemes` is specified then the coverage is gathered only on specified database schemas
    + - else if no coverage specific parameters are provided coverage is gathered on all schemas specified in paths passed to run procedure
    + - else if no paths were specified, the coverage is gathered on current schema of the session running the tests + The exclude parameters are not mutually-exclusive and can be mixed together. All of exclude parameters are always applied. Example: Limiting coverage by schema regex. -```sql +```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_include_schema_expr => '^ut3_develop' @@ -169,7 +179,7 @@ end; Will result in showing coverage for all schemas that match regular expression `^ut3_develop` Example: Limiting coverage by schema regex with parameter `a_include_objects` ignored. -```sql +```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_include_schema_expr => '^ut3_develop', a_include_objects => ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) @@ -179,7 +189,7 @@ end; Will result in showing coverage for all schemas that match regular expression `^ut3_develop`. Example: Limiting coverage by object regex. -```sql +```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_include_object_expr => 'regex123' @@ -189,7 +199,7 @@ end; Will result in showing coverage for all objects that name match regular expression `regex123`. Example: Limiting coverage by object regex with parameter `a_include_objects` ignored. -```sql +```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_include_object_expr => 'utl', a_include_objects => ut_varchar2_list( 'user_2.utils_package' ) @@ -199,7 +209,7 @@ end; Will result in showing coverage for all objects that name match regular expression `utl`. Example: Limiting coverage by excluding schema with regex. -```sql +```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_exclude_schema_expr => 'er_1$' @@ -209,7 +219,7 @@ end; Will result in showing coverage for objects in all schema except schemas that are matching regular expression `er_1$` Example: Limiting coverage by excluding schema with regex and excluding specific object. -```sql +```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_exclude_schema_expr => 'er_1$', a_exclude_objects => ut_varchar2_list( 'user_2.utils_package' ) @@ -220,7 +230,7 @@ Will result in showing coverage for objects in all schemas except schemas that a Will also exclude object `user_2.utils_package` from coverage report Example: Limiting coverage by excluding objects with regex. -```sql +```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_exclude_object_expr => 'utl' @@ -230,7 +240,7 @@ end; Will result in showing coverage for all objects that name is not matching regular expression `utl`. Example: Limiting coverage by excluding objects with regex with parameter `a_exclude_objects` ignored. -```sql +```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_exclude_object_expr => 'utl', a_exclude_objects => ut_varchar2_list( 'user_2.utils_package' ) @@ -242,14 +252,18 @@ Will also exclude object `user_2.utils_package` from coverage report Example: Limiting coverage by object name, for tested code located in the same schema as the unit tests. -```sql -exec ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), a_include_objects=>ut_varchar2_list('award_bonus')); +```sql linenums="1" +begin + ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), + a_include_objects=>ut_varchar2_list('award_bonus') + ); +end; ``` Executes all tests in schemas: `user_1` and `user_2`. Coverage will only be reported on objects `user_1.award_bonus`, `user_2.award_bonus` Example: Limiting coverage by object name, for tested code located in different schemas than the unit tests. -```sql +```sql linenums="1" begin ut.run( 'unit_test_schema', ut_coverage_html_reporter(), @@ -262,7 +276,7 @@ Executes all tests in schema `unit_test_schema`. Coverage will only be reported Objects that do not exist in the database but were specified in `a_include_objects` will be ignored. Example: Limiting coverage by object owner and name. -```sql +```sql linenums="1" begin ut.run( 'unit_test_schema', ut_coverage_html_reporter(), @@ -275,7 +289,7 @@ Executes all tests in schema `unit_test_schema`. Coverage will only be reported The `a_exclude_objects` can be used in the same way as `a_include_objects`. Example: Excluding objects from coverage report by providing a list of object owner/name to be excluded. -```sql +```sql linenums="1" begin ut.run( 'unit_test_schema.test_award_bonus', ut_coverage_html_reporter(), @@ -285,12 +299,12 @@ end; ``` Executes test `test_award_bonus` in schema `unit_test_schema`. Coverage will be reported on all objects in schema `ut3_user` except the `betwnstr` object. -**Note** -> Filtering using `a_include_objects` and `a_exclude_objects` is only applicable when gathering coverage for a schema. Those filters are not applied when reporting coverage on project files. +!!! note + Filtering using `a_include_objects` and `a_exclude_objects` is only applicable when gathering coverage for a schema. Those filters are not applied when reporting coverage on project files. -**Note** -> When running coverage on schema objects, all source code of package bodies, functions, procedures, type bodies and triggers that were not executed will be reported as having 0% code coverage and all source code lines will show as uncovered. -> This is different from the behavior when gathering coverage on project files. +!!! note + When running coverage on schema objects, all source code of package bodies, functions, procedures, type bodies and triggers that were not executed will be reported as having 0% code coverage and all source code lines will show as uncovered. + This is different from the behavior when gathering coverage on project files. ### Project based Coverage @@ -345,16 +359,17 @@ By default, utPLSQL will convert file paths into database objects using the foll - object type is identified by the expression in the sixth set of brackets -**Note** -> utPLSQL will replace any '\\' with '/' for the purpose of mapping files to objects. The paths shown in the results will remain (contain '\' where it was present). -> This is done to simplify the syntax of regular expressions. Regular expression will always use '/' as a directory separator on a file path regardless of whether you're on a Windows or Unix system. +!!! note + utPLSQL will replace any '\\' with '/' for the purpose of mapping files to objects. The paths shown in the results will remain (contain '\' where it was present). + This is done to simplify the syntax of regular expressions. Regular expression will always use '/' as a directory separator on a file path regardless of whether you're on a Windows or Unix system. -**Note** -> Below examples assume that you have downloaded latest version of [utPLSQL-cli](https://github.com/utPLSQL/utPLSQL-cli/releases) and extracted it into your projects root directory (my_project). -> The examples assume that you run the utPLSQL-cli from `my_project` directory. +!!! note + Below examples assume that you have downloaded latest version of [utPLSQL-cli](https://github.com/utPLSQL/utPLSQL-cli/releases) + and extracted it into your projects root directory + and that you run the utPLSQL-cli from that directory. Windows: -``` +```pwsh utPLSQL-cli\bin\utplsql run test_runner/pass@db_host:db_port/db_service_name ^ -p=hr,hotel ^ -source_path=sources ^ @@ -374,6 +389,7 @@ utPLSQL-cli/bin/utplsql run test_runner/pass@db_host:db_port/db_service_name \ ``` The above commands will: + - connect as user `test_runner` - run all utPLSQL v3 tests for users `hr`, `hotel` - map database code to project files in `sources` directory and save code coverage results into `coverage.html` @@ -424,7 +440,7 @@ Note that the owner/name/type subexpressions don't need to be explicitly specifi In the below example, they were specified explicitly only for `source_path`, `test_path` doesn't have subexpressions specified and so they are default (2/3/4). Windows: -``` +```pwsh utPLSQL-cli\bin\utplsql run test_runner/pass@db_url ^ -p=hr,hotel ^ -source_path=sources ^ @@ -487,7 +503,7 @@ For the database objects mapped to `souces` directory user `code_owner` will be For the database objects mapped to `tests` directory user `tests_owner` will be used. Windows: -``` +```pwsh utPLSQL-cli\bin\utplsql run test_runner/pass@db_url ^ -p=tests_owner ^ -source_path=sources -owner=code_owner ^ @@ -506,9 +522,9 @@ utPLSQL-cli/bin/utplsql run test_runner/pass@db_url \ -f=ut_sonar_test_reporter -o=test_results.xml ``` -**Note** -> When the project folder structure does not provide any information about source code owner and test owner, you can specify the owner for tests and owner for code explicitly. -> Such project configuration supports only single-owner for source code and single owner for tests. +!!! note + When the project folder structure does not provide any information about source code owner and test owner, you can specify the owner for tests and owner for code explicitly. + Such project configuration supports only single-owner for source code and single owner for tests. Tested code is mapped to files in `coverage.html` @@ -585,7 +601,7 @@ C: Windows: -``` +```pwsh utPLSQL-cli\bin\utplsql run test_runner/pass@db_url ^ -p=hr,hotel ^ -source_path=sources ^ @@ -636,7 +652,8 @@ Unit test code is mapped to files in `test_results.xml` #### Object-file mapping rules -In order to allow deterministic and accurate mapping of database source-code into project files, the project directory and file structure needs to meet certain criteria. +In order to allow deterministic and accurate mapping of database source-code into project files, the project directory and file structure needs to meet certain criteria. + - Source code is kept separate from test code (separate directories) - Each database (source-code) object is stored in an individual file. Package/type specification is kept separate from its body. - File name (file path) contains the name of database object @@ -650,6 +667,7 @@ In order to allow deterministic and accurate mapping of database source-code int The `ut.run` command provides interface to map project into database objects when executing tests. While it is much easier to perform mapping directly from command line, it is possible to achieve similar functionality from any SQL client. The main differences when using the `ut.run(...)` command, will be: + - you can only use single reporter and therefore will get only one report from test execution - you need to provide fill list of project files rather than point to `sources` and `tests` directories @@ -701,7 +719,7 @@ C: To execute all tests and map database source code into source file names you could use the following command in any SQL client: -```sql +```sql linenums="1" begin ut.run( ut_varchar2_list('hr','hotel'), @@ -733,7 +751,7 @@ end; ``` To execute all tests and map database tests code into test file names you could use the following command in any SQL client: -```sql +```sql linenums="1" begin ut.run( ut_varchar2_list('hr','hotel'), @@ -778,7 +796,7 @@ Following API calls enable the standalone coverage reporting. - `.get_report_cursor( ... )` - coverage reporters function producing coverage report as ref-cursor Example: -```sql +```sql linenums="1" --SESSION 1 -- gather coverage on code using specific coverage_run_id value declare @@ -795,7 +813,7 @@ end; / ``` -```sql +```sql linenums="1" --SESSION 2 -- alternative approach -- gather coverage on code using specific coverage_run_id value @@ -807,7 +825,7 @@ exec ut_runner.coverage_stop(); ``` -```sql +```sql linenums="1" --SESSION 1 or SESSION2 2 or SESSION 3 -- run after calls in SESSION 1 & 2 are finished -- retrieve coverage report in HTML format coverage_run_id value @@ -821,7 +839,7 @@ select * ); ``` -```sql +```sql linenums="1" --SESSION 1 or SESSION2 2 or SESSION 3 -- run after calls in SESSION 1 & 2 are finished declare @@ -839,20 +857,20 @@ end; ``` Specification of parameters for `get_report` and `get_report_cursor` -```sql +```sql linenums="1" function get_report( a_coverage_options ut_coverage_options, a_client_character_set varchar2 := null ) return ut_varchar2_rows pipelined ``` -```sql +```sql linenums="1" function get_report_cursor( a_coverage_options ut_coverage_options, a_client_character_set varchar2 := null ) return sys_refcursor ``` -```sql +```sql linenums="1" ut_coverage_options( coverage_run_id raw, schema_names ut_varchar2_rows := null, diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index d83142f9f..c795c5421 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,23 +1,29 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) -The utPLSQL is responsible for handling exceptions wherever they occur in the test run. utPLSQL is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. -The framework provides a full stacktrace for every exception that was thrown. The stacktrace is clean and does not include any utPLSQL library calls in it. +utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. +The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. To achieve rerunability, the package state invalidation exceptions (ORA-04068, ORA-04061) are not handled and test execution will be interrupted if such exceptions are encountered. This is because of how Oracle behaves on those exceptions. Test execution can fail for different reasons. The failures on different exceptions are handled as follows: -* A test package without body - each `--%test` is reported as failed with exception, nothing is executed -* A test package with _invalid body_ - each `--%test` is reported as failed with exception, nothing is executed -* A test package with _invalid spec_ - package is not considered a valid unit test package and is excluded from execution. When trying to run a test package with invalid spec explicitly, exception is raised. Only valid specifications are parsed for annotations -* A test package that is raising an exception in `--%beforeall` - each `--%test` is reported as failed with exception, `--%test`, `--%beforeeach`, `--%beforetest`, `--%aftertest` and `--%aftereach` are not executed. `--%afterall` is executed to allow cleanup of whatever was done in `--%beforeall` -* A test package that is raising an exception in `--%beforeeach` - each `--%test` is reported as failed with exception, `--%test`, `--%beforetest` and `--%aftertest` is not executed. The `--%aftereach` and `--%afterall` blocks are getting executed to allow cleanup of whatever was done in `--%before...` blocks -* A test package that is raising an exception in `--%beforetest` - the `--%test` is reported as failed with exception, `--%test` is not executed. The `--%aftertest`, `--%aftereach` and `--%afterall` blocks are getting executed to allow cleanup of whatever was done in `--%before...` blocks -* A test package that is raising an exception in `--%test` - the `--%test` is reported as failed with exception. The execution of other blocks continues normally -* A test package that is raising an exception in `--%aftertest` - the `--%test` is reported as failed with exception. The execution of other blocks continues normally -* A test package that is raising an exception in `--%aftereach` - each `--%test` is reported as failed with exception. -* A test package that is raising an exception in `--%afterall` - all blocks of the package are executed, as the `--%afterall` is the last step of package execution. Exception in `--%afterall` is not affecting test results. A warning with exception stacktrace is displayed in the summary +| Problem / error | Framework behavior | +|----------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| A test package **without body** | each `--%test` is reported as failed with exception, nothing is executed | +| A test package with **invalid body** | each `--%test` is reported as failed with exception, nothing is executed | +| A test package with **invalid spec** | package is not considered a valid unit test package and is excluded from execution. When trying to run a test package with invalid spec explicitly, exception is raised. Only valid specifications are parsed for annotations | +| A test package that is raising an exception in `--%beforeall` | each `--%test` is reported as failed with exception, `--%test`, `--%beforeeach`, `--%beforetest`, `--%aftertest` and `--%aftereach` are not executed. `--%afterall` is executed to allow cleanup of whatever was done in `--%beforeall` | +| A test package that is raising an exception in `--%beforeeach` | each `--%test` is reported as failed with exception, `--%test`, `--%beforetest` and `--%aftertest` is not executed. The `--%aftereach` and `--%afterall` blocks are getting executed to allow cleanup of whatever was done in `--%before...` blocks | +| A test package that is raising an exception in `--%beforetest` | the `--%test` is reported as failed with exception, `--%test` is not executed. The `--%aftertest`, `--%aftereach` and `--%afterall` blocks are getting executed to allow cleanup of whatever was done in `--%before...` blocks | +| A test package that is raising an exception in `--%test` | the `--%test` is reported as failed with exception. The execution of other blocks continues normally | +| A test package that is raising an exception in `--%aftertest` | the `--%test` is reported as failed with exception. The execution of other blocks continues normally | +| A test package that is raising an exception in `--%aftereach` | each `--%test` is reported as failed with exception. | +| A test package that is raising an exception in `--%afterall` | all blocks of the package are executed, as the `--%afterall` is the last step of package execution. Exception in `--%afterall` is not affecting test results. A warning with exception stacktrace is displayed in the summary | +!!! warning + If an exception is thrown in an `afterall` procedure then **no failure reported by utPLSQL**.
    + Framework will only report a warning on the suite that the `afterall` belongs to. + Example of reporting with exception thrown in `%beforetest`: ```` Remove rooms by name diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 1c1974319..a972fa2e3 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -7,7 +7,7 @@ Validation of the code under test (the tested logic of procedure/function etc.) utPLSQL uses expectations and matchers to perform the check on the data. Example of an expectation -```sql +```sql linenums="1" begin ut.expect( 'the tested value' ).to_equal('the expected value'); end; @@ -22,6 +22,7 @@ FAILURE ``` Expectation is a combination of: + - the expected value - optional custom message for the expectation - the matcher used to perform comparison @@ -30,7 +31,7 @@ Expectation is a combination of: Matcher defines the comparison operation to be performed on expected (and actual) value. Pseudo-code: -```sql +```sql linenums="1" ut.expect( a_actual {data-type} [, a_message {varchar2}] ).to_( {matcher} ); ut.expect( a_actual {data-type} [, a_message {varchar2}] ).not_to( {matcher} ); ``` @@ -38,7 +39,7 @@ Pseudo-code: Expectations provide two variants of syntax that you can use. Both variants are functionally-equal but give different usage flexibility. Syntax where matcher is passed as parameter to the expectation: -```sql +```sql linenums="1" ut.expect( a_actual ).to_( {matcher} ); ut.expect( a_actual ).not_to( {matcher} ); -- example @@ -46,7 +47,7 @@ Syntax where matcher is passed as parameter to the expectation: ``` Shortcut syntax, where matcher is directly part of expectation: -```sql +```sql linenums="1" ut.expect( a_actual ).to_{matcher}; ut.expect( a_actual ).not_to_{matcher}; @@ -57,7 +58,7 @@ Shortcut syntax, where matcher is directly part of expectation: When using shortcut syntax you don't need to surround matcher with brackets. Shortcut syntax is provided for convenience. If you would like to perform more dynamic checks in your code, you could pass the matcher into a procedure like in the below example: -```sql +```sql linenums="1" declare procedure do_check( p_actual varchar2, p_matcher ut_matcher ) is begin @@ -80,8 +81,8 @@ SUCCESS Actual: 'Alibaba' (varchar2) was expected to match: 'ali' , modifiers 'i' ``` -**Note:** -> The examples in the document will be only using shortcut syntax, to keep the document brief. +!!! note + In order to keep the document brief, the examples in the document are only using the standalone expectations syntax. ## Using expectations @@ -91,17 +92,19 @@ There are two ways to use expectations: ## Running expectations within utPLSQL framework -When expectations are ran as a part of a test suite, the framework tracks: +When expectations are run as a part of a test suite, the framework tracks: + - status of each expectation - outcomes (messages) produced by each expectation - call stack to each expectation In this case: + - expectation results of are not sent directly to `dbms_output` - utPLSQL Reporters used when running suite decide on how the expectation results are formatted and displayed Example of test suite with an expectation: -```sql +```sql linenums="1" create or replace package test_divide as --%suite(Divide two numbers) @@ -159,15 +162,13 @@ Please read about different options for [running test suites](running-unit-tests ## Running expectations outside utPLSQL framework When expectations are invoked outside of utPLSQL framework the outputs from expectations are redirected straight to `dbms_output`. -**Note:** -> The output from expectation contains call stack trace only when expectation fails. -> Source code of the line which called the expectation is only reported when the line is part of in-database code (package) and the user calling expectation has privileges to see that source code. +!!! note + The output from expectation contains call stack trace only when expectation fails.
    + Source code of the line which called the expectation is only reported when the line is part of in-database code (package) and the user calling expectation has privileges to see that source code. -**Important** -> Please do not use expectations as part of your production code. They are not designed to be used as part of your code. Expectations are meant to be used only as part of your day-to-day testing activities. +!!! warning "**Important**" + Please do not use expectations as part of your production code. They are not designed to be used as part of your code. Expectations are meant to be used only as part of your day-to-day testing activities. -**Note:** -> The examples in the document will be only using standalone expectations, to keep the document brief. ## Matchers utPLSQL provides the following matchers to perform checks on the expected and actual values. @@ -193,7 +194,7 @@ You can provide a custom failure message by passing it as the second parameter t `ut.expect( a_actual {data-type}, a_message {varchar2} ).to_{matcher}` Example: -````sql +````sql linenums="1" exec ut.expect( 'supercat', 'checked superhero-animal was not a dog' ).to_equal('superdog'); ```` @@ -208,6 +209,7 @@ If the message is provided, it is being added to the normal failure message retu This is mostly useful when your expectations accept dynamic content, as you can provide additional context to make failing test results more readable. In most cases, there is no need to provide custom message to expectation. This is because utPLSQL identifies: + - The test used to execute the expectation - The line number where the expectation is placed in your test code - The line text of the expectation @@ -215,7 +217,7 @@ In most cases, there is no need to provide custom message to expectation. This i Custom message is useful, if your expectation is placed in a shared procedure to perform a check and your test is using the procedure multiple times. Example: -```sql +```sql linenums="1" create or replace package shared_expectation_test is --%suite @@ -265,6 +267,7 @@ Finished in .066344 seconds ``` In the tests results window you can see the list of failed expectations for a test as well as: + - the additional message for expectation - the reason why the expectation failed - the line number of the expectation @@ -276,7 +279,7 @@ In the tests results window you can see the list of failed expectations for a te Expectations provide a very convenient way to perform a check on a negated matcher. Syntax to check for matcher evaluating to true: -```sql +```sql linenums="1" begin ut.expect( a_actual {data-type} ).to_{matcher}; ut.expect( a_actual {data-type} ).to_( {matcher} ); @@ -284,7 +287,7 @@ end; ``` Syntax to check for matcher evaluating to false: -```sql +```sql linenums="1" begin ut.expect( a_actual {data-type} ).not_to_{matcher}; ut.expect( a_actual {data-type} ).not_to( {matcher} ); @@ -294,7 +297,7 @@ end; If a matcher evaluated to NULL, then both `to_` and `not_to` will cause the expectation to report failure. Example: -```sql +```sql linenums="1" declare l_actual boolean; begin @@ -346,7 +349,7 @@ Testing is not limited to checking for happy-path scenarios. When writing tests, Use the `--%throws` annotation, to test for expected exceptions. Example: -```sql +```sql linenums="1" create or replace function divide(x varchar2, y varchar2) return number is begin return x/y; @@ -397,7 +400,7 @@ You can choose different matchers to validate that your PL/SQL code is working a Validates that the actual value is between the lower and upper bound. Example: -```sql +```sql linenums="1" declare l_timestamp timestamp := current_timestamp; l_timestamp_tz timestamp with time zone := systimestamp; @@ -454,12 +457,12 @@ Unary matcher that validates if the provided dataset is empty. Can be used with `BLOB`,`CLOB`, `refcursor` or `nested table`/`varray` passed as `ANYDATA` -**Note:** -BLOB/CLOB that is initialized is not NULL but it is actually equal to `empty_blob()`/`empty_clob()`. +!!! note + BLOB/CLOB that is initialized is not NULL but it is actually equal to `empty_blob()`/`empty_clob()`. Example: -```sql +```sql linenums="1" declare l_cursor sys_refcursor; begin @@ -502,7 +505,7 @@ FAILURE Unary matcher that validates if the provided value is false. Usage: -```sql +```sql linenums="1" begin ut.expect( ( 1 = 0 ) ).to_be_false(); ut.expect( ( 1 = 1 ) ).to_( be_false() ); @@ -530,7 +533,7 @@ SUCCESS Checks if the actual value is greater or equal than the expected. Usage: -```sql +```sql linenums="1" begin ut.expect( sysdate ).to_be_greater_or_equal( sysdate - 1 ); ut.expect( sysdate ).to_( be_greater_or_equal( sysdate + 1 ) ); @@ -558,7 +561,7 @@ SUCCESS Checks if the actual value is greater than the expected. Usage: -```sql +```sql linenums="1" begin ut.expect( 2 ).to_be_greater_than( 1 ); ut.expect( 0 ).to_( be_greater_than( 1 ) ); @@ -586,7 +589,7 @@ SUCCESS Checks if the actual value is less or equal than the expected. Usage: -```sql +```sql linenums="1" begin ut.expect( 3 ).to_be_less_or_equal( 3 ); ut.expect( 4 ).to_( be_less_or_equal( 3 ) ); @@ -614,7 +617,7 @@ SUCCESS Checks if the actual value is less than the expected. Usage: -```sql +```sql linenums="1" begin ut.expect( 3 ).to_be_less_than( 2 ); ut.expect( 0 ).to_( be_less_than( 2 ) ); @@ -650,7 +653,7 @@ Parameters `a_mask` and `a_escape_char` represent valid parameters of the [Oracl If you use Oracle Database version 11.2.0.4, you may run into Oracle Bug 14402514: WRONG RESULTS WITH LIKE ON CLOB USING ESCAPE CHARACTER. In this case we recommend to use `match` instead of `be_like`. Usage: -```sql +```sql linenums="1" begin ut.expect( 'Lorem_impsum' ).to_be_like( '%rem%'); ut.expect( 'Lorem_impsum' ).to_be_like( '%rem\_i%', '\' ); @@ -680,7 +683,7 @@ SUCCESS Unary matcher that validates if the actual value is not null. Usage: -```sql +```sql linenums="1" begin ut.expect( to_clob('ABC') ).to_be_not_null(); ut.expect( to_clob('') ).to_( be_not_null() ); @@ -708,7 +711,7 @@ SUCCESS Unary matcher that validates if the actual value is null. Usage: -```sql +```sql linenums="1" begin ut.expect( '' ).to_be_null(); ut.expect( 0 ).to_( be_null() ); @@ -736,7 +739,7 @@ SUCCESS Unary matcher that validates if the provided value is true. Usage: -```sql +```sql linenums="1" begin ut.expect( ( 1 = 0 ) ).to_be_true(); ut.expect( ( 1 = 1 ) ).to_( be_true() ); @@ -766,7 +769,7 @@ Unary matcher that validates if the provided dataset count is equal to expected Can be used with `refcursor`, `json` or `table type` Usage: -```sql +```sql linenums="1" declare l_cursor sys_refcursor; l_collection ut_varchar2_list; @@ -806,7 +809,7 @@ Syntax: Parameters `a_pattern` and `a_modifiers` represent a valid regexp pattern accepted by [Oracle REGEXP_LIKE condition](https://docs.oracle.com/database/121/SQLRF/conditions007.htm#SQLRF00501) Usage: -```sql +```sql linenums="1" begin ut.expect( '123-456-ABcd' ).to_match( '\d{3}-\d{3}-[a-z]{4}', 'i' ); ut.expect( 'some value' ).to_( match( '^some.*' ) ) ; @@ -844,7 +847,7 @@ Syntax: `ut.expect( a_actual ).to_equal( a_expected [, a_nulls_are_equal])[.advanced_options]` Example usage -```sql +```sql linenums="1" declare l_actual varchar2(20); l_expected varchar2(20); @@ -911,10 +914,10 @@ FAILURE ``` -**Note:** ->**Comparing NULLs gives success by default ** -The `a_nulls_are_equal` parameter controls the behavior of a `null = null` comparison. -To change the behavior of `NULL = NULL` comparison pass the `a_nulls_are_equal => false` to the `equal` matcher. +!!! note + **by default, comparing NULL to NULL gives success**
    + The `a_nulls_are_equal` parameter controls the behavior of a `null = null` comparison.
    + To change the behavior of `NULL = NULL` comparison pass the `a_nulls_are_equal => false` to the `equal` matcher. ## contain @@ -931,7 +934,7 @@ The matcher will cause a test to fail if actual data set does not contain some o ![included_set](../images/venn21.gif) **Example 1.** -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; @@ -963,7 +966,7 @@ FAILURE When duplicate rows are present in expected data set, actual data set must also include the same amount of duplicates. **Example 2.** -```sql +```sql linenums="1" declare l_actual ut_varchar2_list; l_expected ut_varchar2_list; @@ -991,7 +994,7 @@ The negated version of `contain` ( `not_to_contain` ) is successful only when al ![not_overlapping_set](../images/venn22.gif) **Example 3.** -```sql +```sql linenums="1" declare l_actual ut_varchar2_list; l_expected ut_varchar2_list; @@ -1028,7 +1031,7 @@ FAILURE **Example 4.** -```sql +```sql linenums="1" declare l_actual ut_varchar2_list; l_expected ut_varchar2_list; @@ -1061,7 +1064,7 @@ FAILURE **Example 5.** -```sql +```sql linenums="1" declare l_actual ut_varchar2_list; l_expected ut_varchar2_list; @@ -1134,7 +1137,7 @@ The distance must be expressed as a non-negative number or non-negative interval > The behavior is similar to a call to `months_between()` function with results rounded to full monts ie. round(months_between(date, date)) **Example 1.** -```sql +```sql linenums="1" begin ut.expect(3).to_be_within(1).of_(4); end; @@ -1142,7 +1145,7 @@ end; ``` **Example 2.** -```sql +```sql linenums="1" begin ut.expect(3).to_be_within(1).of_(5); end; @@ -1160,7 +1163,7 @@ Failures: ``` **Example 3.** -```sql +```sql linenums="1" begin ut.expect(sysdate).to_be_within(interval '1' day).of_(sysdate+2); end; @@ -1190,7 +1193,7 @@ The formula used for calcuation of expectation is: ``` **Example 1.** -```sql +```sql linenums="1" begin ut.expect(9).to_be_within_pct(10).of_(10); end; @@ -1206,6 +1209,7 @@ SUCCESS ## Comparing cursors, object types, nested tables and varrays utPLSQL is capable of comparing compound data-types including: + - ref cursors - object types - nested table/varray types @@ -1227,6 +1231,7 @@ utPLSQL is capable of comparing compound data-types including: See [issue #880](https://github.com/utPLSQL/utPLSQL/issues/880) for details. *Note: This behavior might be fixed in future releases, when utPLSQL is no longer depending on XMLType for compound data comparison.* utPLSQL offers advanced data-comparison options, for comparing compound data-types. The options allow you to: + - define columns/attributes to exclude from comparison - define columns/attributes to include in comparison - and more ... @@ -1237,6 +1242,7 @@ For details on available options and how to use them, read the [advanced data co When comparing compound data, utPLSQL will determine the difference between the expected and the actual data. The diff includes: + - differences in column names, column positions and column data-type for cursor data - only data in columns/rows that differ @@ -1246,9 +1252,9 @@ Consider the following expected cursor data | ID (NUMBER)| FIRST_NAME (VARCHAR2) | LAST_NAME (VARCHAR2) | SALARY (NUMBER) | |:----------:|:----------------------:|:----------------------:|:---------------:| -| 1 | JACK | SPARROW | 10000 | -| 2 | LUKE | SKYWALKER | 1000 | -| 3 | TONY | STARK | 1000000 | +| 1 | JACK | SPARROW | 10000 | +| 2 | LUKE | SKYWALKER | 1000 | +| 3 | TONY | STARK | 1000000 | And the actual cursor data: @@ -1261,6 +1267,7 @@ And the actual cursor data: The two data-sets above have the following differences: + - column ID is misplaced (should be first column but is last) - column SALARY has data-type VARCHAR2 but should be NUMBER - column GENDER exists in actual but not in the expected (it is an Extra column) @@ -1272,7 +1279,7 @@ The two data-sets above have the following differences: utPLSQL will report all of the above differences in a readable format to help you identify what is not correct in the compared dataset. Below example illustrates, how utPLSQL will report such differences. -```sql +```sql linenums="1" declare l_actual sys_refcursor; l_expected sys_refcursor; @@ -1320,11 +1327,13 @@ FAILURE ``` utPLSQL identifies and reports on columns: + - column misplacement - column data-type mismatch - extra/missing columns When comparing rows utPLSQL: + - reports only mismatched columns when rows match - reports columns existing in both data-sets when whole row is not matching - reports whole extra (not expected) row from actual when actual has extra rows @@ -1334,6 +1343,7 @@ When comparing rows utPLSQL: ### Object and nested table data-type comparison examples When comparing object type / nested table / varray, utPLSQL will check: + - if data-types match - if data in the compared elements is the same. @@ -1343,7 +1353,7 @@ When diffing, utPLSQL will not check name and data-type of individual attribute Below examples demonstrate how to compare object and nested table data-types. Object type comparison. -```sql +```sql linenums="1" create type department as object(name varchar2(30)) / @@ -1371,7 +1381,7 @@ FAILURE ``` Table type comparison. -```sql +```sql linenums="1" create type department as object(name varchar2(30)) / create type departments as table of department @@ -1409,7 +1419,7 @@ FAILURE ``` Some of the possible combinations of anydata and their results: -```sql +```sql linenums="1" clear screen set serverout on set feedback off @@ -1593,18 +1603,18 @@ FAILURE ### Comparing cursor data containing DATE fields -**Important note** +!!! warning "Important note" -utPLSQL uses XMLType internally to represent rows of the cursor data. This is by far the most flexible method and allows comparison of cursors containing LONG, CLOB, BLOB, user defined types and even nested cursors. -Due to the way Oracle handles DATE data type when converting from cursor data to XML, utPLSQL has no control over the DATE formatting. -The NLS_DATE_FORMAT setting from the moment the cursor was opened determines the formatting of dates used for cursor data comparison. -By default, Oracle NLS_DATE_FORMAT is timeless, so data of DATE datatype, will be compared ignoring the time component. + utPLSQL uses XMLType internally to represent rows of the cursor data. This is by far the most flexible method and allows comparison of cursors containing LONG, CLOB, BLOB, user defined types and even nested cursors.
    + Due to the way Oracle handles DATE data type when converting from cursor data to XML, utPLSQL has no control over the DATE formatting.
    + The NLS_DATE_FORMAT setting from the moment the cursor was opened determines the formatting of dates used for cursor data comparison.
    + By default, Oracle NLS_DATE_FORMAT is timeless, so data of DATE datatype, will be compared ignoring the time component.
    You should surround cursors and expectations with procedures `ut.set_nls`, `ut.reset_nls`. This way, the DATE data in cursors will be properly formatted for comparison using date-time format. The example below makes use of `ut.set_nls`, `ut.reset_nls`, so that the date in `l_expected` and `l_actual` is compared using date-time formatting. -```sql +```sql linenums="1" clear screen alter session set nls_date_format='yyyy-mm-dd'; set serverout on @@ -1649,6 +1659,7 @@ drop table events; ``` In the above example: + - The first expectation is successful, as the `l_expected` cursor contains different date-time then the cursor returned by `get_events` function call - The second expectation fails, as the column `event_date` will get compared as DATE without TIME (using default current session NLS date format) @@ -1687,7 +1698,7 @@ This applies to `timestamp`,`timestamp with timezone`, `timestamp with local tim Example below illustrates usage of `cast` operator to assure appropriate precision is applied on timestamp bind-variables in cursor result-set -```sql +```sql linenums="1" clear screen set serverout on set feedback off @@ -1754,8 +1765,8 @@ FAILURE utPLSQL is capable of comparing json data-types of `json_element_t` **on Oracle 12.2 and above**, and also `json` **on Oracle 21 and above** -**Note:** -> Whenever a database is upgraded to compatible version the utPLSQL needs to be reinstalled to pick up json changes. E.g. upgrade from 18c to 21c to enable `json` type compare. +!!! note + Whenever a database is upgraded to compatible version the utPLSQL needs to be reinstalled to pick up json changes. E.g. upgrade from 18c to 21c to enable `json` type compare. ### Notes on comparison of json data @@ -1769,7 +1780,7 @@ utPLSQL is capable of comparing json data-types of `json_element_t` **on Oracle Compare JSON example using `json_element_t`: -```sql +```sql linenums="1" declare l_expected json_element_t; l_actual json_element_t; @@ -1851,7 +1862,7 @@ FAILURE ``` Comparing parts of JSON example using `json_element_t` subtypes: -```sql +```sql linenums="1" declare l_actual json_object_t; l_actual_extract json_array_t; diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index e9681bb7b..c199d7095 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -24,7 +24,7 @@ This way, we assure we don't jump ahead too much and produce code that is untest ### Create test package -```sql +```sql linenums="1" create or replace package test_betwnstr as --%suite(Between string function) @@ -45,7 +45,7 @@ Finished in .451423 seconds ### Define specification for the test -```sql +```sql linenums="1" create or replace package test_betwnstr as --%suite(Between string function) @@ -78,7 +78,7 @@ Well our test is failing as the package specification requires a body. ### Define body of first test -```sql +```sql linenums="1" create or replace package body test_betwnstr as procedure basic_usage is @@ -114,7 +114,7 @@ Looks like we need to define the function we want to test. ### Define tested function -```sql +```sql linenums="1" create or replace function betwnstr( a_string varchar2, a_start_pos integer, a_end_pos integer ) return varchar2 is begin @@ -147,7 +147,7 @@ Let us fix this and continue from here. The function returned a string one character short, so we need to add 1 to the substr parameter. -```sql +```sql linenums="1" create or replace function betwnstr( a_string varchar2, a_start_pos integer, a_end_pos integer ) return varchar2 is begin @@ -200,7 +200,7 @@ Once defined we can start implementing tests for those behaviors and adjust the A new requirement was added: Start position zero - should be treated as start position one -```sql +```sql linenums="1" create or replace package test_betwnstr as --%suite(Between string function) @@ -254,7 +254,7 @@ Looks like our function does not work as expected for zero start position. Let's fix our function so that the new requirement is met -```sql +```sql linenums="1" create or replace function betwnstr( a_string varchar2, a_start_pos integer, a_end_pos integer ) return varchar2 is begin @@ -288,7 +288,7 @@ When all tests are passing we can proceed with a safe cleanup of our code. The function works well, but we use the `return` twice, which is not the best coding practice. An alternative implementation could be cleaner. -```sql +```sql linenums="1" create or replace function betwnstr( a_string varchar2, a_start_pos integer, a_end_pos integer ) return varchar2 is begin diff --git a/docs/userguide/install.md b/docs/userguide/install.md index fca38c92e..6dfa66140 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -116,26 +116,18 @@ This process can be time-consuming if DB schema is large. The headless scripts accept three optional parameters that define: - username to create as owner of utPLSQL (default `ut3`) - password for owner of utPLSQL (default `XNtxj8eEgA6X6b6f`) -- tablespace to use for storage of profiler data (default `users`) +- tablespace to use for storage of profiler and utPLSQL cache data (default `users`) The scripts need to be executed by `SYSDBA`, in order to grant access to `DBMS_LOCK` and `DBMS_CRYPTO` system packages. -**Note:** -> Grant on `DBMS_LOCK` is required only for installation on Oracle versions below 18c. For versions 18c and above, utPLSQL uses `DBMS_SESSION.SLEEP` so access to `DBMS_LOCK` package is no longer needed. - -**Note:** -> The user performing the installation must have the `ADMINISTER DATABASE TRIGGER` privilege. This is required for installation of trigger that is responsible for parsing annotations at at compile-time of a package. - -**Note:** -> When installing with DDL trigger, utPLSQL will not be registering unit tests for any of oracle-maintained schemas. -For Oracle 11g following users are excluded: -> ANONYMOUS, APPQOSSYS, AUDSYS, DBSFWUSER, DBSNMP, DIP, GGSYS, GSMADMIN_INTERNAL, GSMCATUSER, GSMUSER, ORACLE_OCM, OUTLN, REMOTE_SCHEDULER_AGENT, SYS, SYS$UMF, SYSBACKUP, SYSDG, SYSKM, SYSRAC, SYSTEM, WMSYS, XDB, XS$NULL -> -> For Oracle 12c and above the users returned by below query are excluded by utPLSQL: -> ->```sql -> select username from all_users where oracle_maintained='Y'; ->``` +!!! warning "Important" + - Grant on `DBMS_LOCK` is required only for installation on Oracle versions below 18c. For versions 18c and above, utPLSQL uses `DBMS_SESSION.SLEEP` so access to `DBMS_LOCK` package is no longer needed.
    + - The user performing the installation must have the `ADMINISTER DATABASE TRIGGER` privilege. This is required for installation of trigger that is responsible for parsing annotations at at compile-time of a package.
    + - When installed with DDL trigger, utPLSQL will not be registering unit tests for any of oracle-maintained schemas.
    + - For Oracle 11g following users are excluded:
    + ANONYMOUS, APPQOSSYS, AUDSYS, DBSFWUSER, DBSNMP, DIP, GGSYS, GSMADMIN_INTERNAL, GSMCATUSER, GSMUSER, ORACLE_OCM, OUTLN, REMOTE_SCHEDULER_AGENT, SYS, SYS$UMF, SYSBACKUP, SYSDG, SYSKM, SYSRAC, SYSTEM, WMSYS, XDB, XS$NULL
    + - For Oracle 12c and above the users returned by below query are excluded by utPLSQL:
    + `select username from all_users where oracle_maintained='Y';`
    ### Installation without DDL trigger @@ -232,8 +224,8 @@ cd source sqlplus admin/admins_password@database @install_ddl_trigger.sql ut3 ``` -**Note:** ->Trigger can be installed ant any point in time. +!!! note + Trigger can be installed ant any point in time after the utPLSQL installation. The framework will detect the presence of DDL trigger and act accordingly. ### Allowing other users to access the utPLSQL framework @@ -268,12 +260,12 @@ The following tools that support the SQL*Plus commands can be used to run the in ## Checking environment and utPLSQL version To check the framework version execute the following query: -```sql +```sql linenums="1" select substr(ut.version(),1,60) as ut_version from dual; ``` Additionally you may retrieve more information about your environment by executing the following query: -```sql +```sql linenums="1" select xmlserialize( content xmltype(ut_run_info()) as clob indent size = 2 ) from dual; diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index e7496320c..6ee0b546f 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -22,27 +22,27 @@ Querying the data from function provides the follwing details: - `tags` - tags associated with suites To get list of all test suites in current schema -```sql +```sql linenums="1" select * from table(ut_runner.get_suites_info()) where item_type = 'UT_SUITE'; ``` To get list of all tests for test suite `TEST_STUFF` in current user schema -```sql +```sql linenums="1" select * from table(ut_runner.get_suites_info(USER, 'TEST_STUFF')) where item_type = 'UT_TEST'; ``` To get a full information about suite `TEST_STUFF` including suite description, all contexts and tests in a suite -```sql +```sql linenums="1" select * from table(ut_runner.get_suites_info(USER, 'TEST_STUFF')) where item_type = 'UT_TEST'; ``` To get a full information about suites that have a path like `ut3:tests.test_package_*` including suite description, all contexts and tests in a suite -```sql +```sql linenums="1" select * from table(ut_runner.get_suites_info('ut3:tests.test_package_*') where item_type = 'UT_TEST'; ``` To get a full information about suites that have object name like `test_package_*` including suite description, all contexts and tests in a suite -```sql +```sql linenums="1" select * from table(ut_runner.get_suites_info('test_package_*')); ``` @@ -51,7 +51,7 @@ select * from table(ut_runner.get_suites_info('test_package_*')); Function `ut_runner.has_suites(a_owner)` returns boolean value indicating if given schema contains test suites. Example: -```sql +```sql linenums="1" begin if ut_runner.has_suites(USER) then dbms_output.put_line( 'User '||USER||' owns test suites' ); @@ -66,7 +66,7 @@ end; Function `ut_runner.is_suite(a_owner, a_package_name) ` returns boolean value indicating if given package is a test suites. Example: -```sql +```sql linenums="1" begin if ut_runner.is_suite(USER,'TEST_STUFF') then dbms_output.put_line( 'Package '||USER||'.TEST_STUFF is a test suite' ); @@ -81,7 +81,7 @@ end; Function `ut_runner.is_test(a_owner, a_package_name, a_procedure_name) ` returns boolean value indicating if given package is a test suites. Example: -```sql +```sql linenums="1" begin if ut_runner.is_test(USER,'TEST_STUFF','A_TEST_TO_CHECK_STUFF') then dbms_output.put_line( 'Procedure '||USER||'.TEST_STUFF.A_TEST_TO_CHECK_STUFF is a test' ); diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 1f5ead1c5..467116479 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,6 +1,6 @@ ![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) -utPLSQL provides the following reporting formats. +utPLSQL provides several reporting formats. The sections below describe most of them. ## Documentation reporter @@ -17,7 +17,8 @@ Example outputs from documentation reporter. ![doc_reporter_outputs](../images/documentation_reporter.png) -The documentation report provides the following information. +Documentation reporter provides the following information. + - Test suite name or test package name (nested with suitepath if suitepath is used) - Test description name or test procedure name - Information about test failing `(FAILED - n)` @@ -84,8 +85,11 @@ Example of failure report details ## Sonar test reporter -If you are using [SonarQube](https://www.sonarqube.org/) or [SonarCloud](https://about.sonarcloud.io/) to do static code analysis for you PLSQL projects, your code analysis can benefit from code coverage and test results. + +If you are using [SonarQube](https://www.sonarqube.org/) or [SonarCloud](https://about.sonarcloud.io/) to do static code analysis for you PLSQL projects, +your code analysis can benefit from code coverage and test results. utPLSQL provides two reporters to for SonarQube: + - `ut_sonar_test_reporter` - provides an XML output of each test executed per each project test file (package) - `ut_coverage_sonar_reporter` - provides XML output of code coverage per each project source file @@ -97,15 +101,15 @@ The paths to files can be relative to the project root directory (recommended) o Providing invalid paths or paths to non-existing files will result in failure when publishing test results/coverage results to sonar server. -For details on how to invoke reporter with paths, see the **Coverage reporters** section. +For details on how to invoke reporter with paths, see the [Code coverage](coverage.md) section. ## TFS / VSTS Reporter -If you are using [TFS](https://www.visualstudio.com/tfs/) or [VSTS](https://www.visualstudio.com/team-services/) to do static code analysis for you PLSQL projects and run builds, your code analysis can benefit from code coverage and test results. TFS reporter is designed specifically to [work with Microsoft Team Fundation Server](https://docs.microsoft.com/en-us/vsts/build-release/tasks/test/publish-test-results?view=vsts) report format which is very old version of [JUnit](https://github.com/windyroad/JUnit-Schema/blob/master/JUnit.xsd). -Main diffrence between standard JUnit is that elements cannot be nested and attribute skipped is not present. -utPLSQL provides test reporter to for TFS / VSTS server: -- `ut_tfs_junit_reporter` - provides an XML output of each test executed per each project test file (package) +If you are using [TFS](https://www.visualstudio.com/tfs/) or [VSTS](https://www.visualstudio.com/team-services/) to do static code analysis for you PLSQL projects and run builds, +your code analysis can benefit from code coverage and test results. TFS reporter is designed specifically to [work with Microsoft Team Fundation Server](https://docs.microsoft.com/en-us/vsts/build-release/tasks/test/publish-test-results?view=vsts) report format which is very old version of [JUnit](https://github.com/windyroad/JUnit-Schema/blob/master/JUnit.xsd). +Main difference between standard JUnit is that elements cannot be nested and attribute skipped is not present. +utPLSQL provides a dedicated `ut_tfs_junit_reporter` reporter to for TFS / VSTS servers. The reporter provides an XML output of each test executed per each project test file (package). Example of test report from TFS CI server. Summary: @@ -119,8 +123,8 @@ Details: ## Coverage reporters -utPLSQL comes with a set of build-in coverage reporters. Have a look into the [coverage documentation](coverage.md) to learn more about them. - +utPLSQL comes with a set of build-in coverage reporters. +[Code coverage](coverage.md) section describes in details how to use configure and use code coverage. ## Debug reporter @@ -131,6 +135,7 @@ Use this reporter only when you need to investigate framework issues or raise a Usage of this reporter might have impact on performance of test-suite execution. Amongst others, reporter provides the following information: + - framework version - database version - database OS @@ -152,25 +157,26 @@ Amongst others, reporter provides the following information: - every test - every expectation and it's result -Some of the information in debug log might be redundant. +Some information in debug log might be redundant. -**Note:** ->Some of the information in debug log may be sensitive. In particular: -> - expectation results and messages (logged even for successful runs) -> - test structure -> - db object names -> - etc. +!!! note + Some information in debug log may be sensitive. In particular:
    + - expectation results and messages (logged even for successful runs)
    + - test structure
    + - db object names
    + - etc. ## Custom reporters -It is possible to add your own reporters by creating an appropriate object type. In principle, it has to be a subtype of `ut_reporter_base`. However, if the reporter is expected to produce output consumable by a client oustside of the database (e.g. the data has to be reported to the screen or to a file), then you should base it on `ut_output_reporter_base` (which is a subtype of `ut_reporter_base`). In contrast, if you would like to create a reporter that, for example, saves the data to a database table, then it should be based directly on `ut_reporter_base`. (Currently, all reporters in the utPLSQL framework are based on `ut_output_reporter_base`.) Coverage reporters are based on `ut_coverage_reporter_base` (a subtype of `ut_output_reporter_base`). +It is possible to add your own reporters by creating an appropriate object type. +In principle, it has to be a subtype of `ut_reporter_base`. However, if the reporter is expected to produce output consumable by a client oustside of the database (e.g. the data has to be reported to the screen or to a file), then you should base it on `ut_output_reporter_base` (which is a subtype of `ut_reporter_base`). In contrast, if you would like to create a reporter that, for example, saves the data to a database table, then it should be based directly on `ut_reporter_base`. (Currently, all reporters in the utPLSQL framework are based on `ut_output_reporter_base`.) Coverage reporters are based on `ut_coverage_reporter_base` (a subtype of `ut_output_reporter_base`). If you need to produce a colored text output from the custom reporter, then you can build it basing on `ut_console_reporter_base` (a subtype of `ut_output_reporter_base`). In many cases it may also be more convenient to create the custom reporter type under a more specialized type, like `ut_documentation_reporter` or `ut_junit_reporter`, and override just some of the functionality. It is recommended to create the reporter type in the schema where utPLSQL is installed (by default it is the `UT3` schema). Note that before running the utPLSQL uninstall scripts, all custom reporters should be dropped (cf. [the installation documentation](install.md)). In particular, when upgrading to a newer version of utPLSQL, one has to drop the custom reporters and recreate them after the upgrade. -**Note:** -> It is possible, but cumbersome, to use another schema for storing the custom reporters. This requires to create a synonym for the base reporter type in the schema that is going to own the custom reporter, and to provide appropriate grants both to the owner of the custom reporter and to the user running the reporter. After upgrading or reinstalling utPLSQL, the extra privileges need to be recreated. This approach is not recommended. +!!! note + It is possible, but cumbersome, to use another schema for storing the custom reporters. This requires to create a synonym for the base reporter type in the schema that is going to own the custom reporter, and to provide appropriate grants both to the owner of the custom reporter and to the user running the reporter. After upgrading or reinstalling utPLSQL, the extra privileges need to be recreated. This approach is not recommended. Assuming that the custom reporter type is created in the `UT3` schema, to run the tests using a custom reporter just call: `exec ut.run(ut3.custom_reporter_name());`, optionally providing parameter values to the `custom_reporter_name` constructor. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a87fe9836..18270e707 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -47,7 +47,7 @@ You can use a wildcard character `*` to call tests by part of their name or to c Wildcard character can be placed anywhere on the path and can occur mutliple times. Schema name cannot contain a wildcard character whether is in a suitepath call or call by object name. -```sql +```sql linenums="1" alter session set current_schema=hr; set serveroutput on begin @@ -57,7 +57,7 @@ end; Executes all tests in current schema (_HR_). -```sql +```sql linenums="1" set serveroutput on begin ut.run('HR'); @@ -66,7 +66,7 @@ end; Executes all tests in specified schema (_HR_). -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr:com.my_org.my_project'); @@ -76,7 +76,7 @@ end; Executes all tests from all packages that are on the _com.my_org.my_project_ suitepath. Check the [annotations documentation](annotations.md) to find out about suitepaths and how they can be used to organize test packages for your project. -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr:com*'); @@ -85,7 +85,7 @@ end; Executes all tests in schema `hr` from all packages that are on suitepath starting with `com`. -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr:co*.my_*.my_*'); @@ -94,7 +94,7 @@ end; Executes all tests in schema `hr` from all packages that starting with `my_` and all tests starting with `my_*` that are on suitepath starting with `co` . -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr.test_apply_bonus'); @@ -103,7 +103,7 @@ end; Executes all tests from package _hr.test_apply_bonus_. -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr.test_apply_bonus.bonus_cannot_be_negative'); @@ -112,7 +112,7 @@ end; Executes single test procedure _hr.test_apply_bonus.bonus_cannot_be_negative_. -```sql +```sql linenums="1" set serveroutput on begin ut.run(ut_varchar2_list('hr.test_apply_bonus','cust')); @@ -120,7 +120,7 @@ end; ``` Executes all tests from package _hr.test_apply_bonus_ and all tests from schema _cust_. -```sql +```sql linenums="1" set serveroutput on begin ut.run(ut_varchar2_list('hr.test_apply_bonus,cust)'); @@ -129,7 +129,7 @@ end; Executes all tests from package _hr.test_apply_bonus_ and all tests from schema _cust_. -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr.test_apply_bonus,cust'); @@ -142,7 +142,7 @@ Using a list of items to execute allows you to execute a fine-grained set of tes List can be passed as a comma separated list or a list of *ut_varchar2_list objects* or as a list within ut_varchar2_list. -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr.test*'); @@ -150,7 +150,7 @@ end; ``` Executes all tests in schema `hr` located in packages starting with name `test`. -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr.test_apply_bonus.bonus_*'); @@ -166,7 +166,7 @@ Executes test procedures with names starting with `bonus` in package `hr.test_ap The `ut.run` procedures and functions accept `a_reporter` attribute that defines the reporter to be used in the run. You can execute any set of tests with any of the predefined reporters. -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr.test_apply_bonus', ut_junit_reporter()); @@ -189,7 +189,7 @@ Functions provide output as a pipelined stream and therefore need to be executed At the end of the run, the transaction is automatically rolled-back and all uncommitted changes are reverted. Example. -```sql +```sql linenums="1" select * from table(ut.run('hr.test_apply_bonus', ut_junit_reporter())); ``` @@ -222,7 +222,7 @@ Running with multiple reporters. - each reporter for each test-run must have a unique `reporter_id`. The `reporter_id` is used between two sessions to identify the data stream Example: -```sql +```sql linenums="1" --main test run ( session 1 ) declare l_reporter ut_realtime_reporter := ut_realtime_reporter(); @@ -234,7 +234,7 @@ end; / ``` -```sql +```sql linenums="1" --report consumer ( session 2 ) set arraysize 1 set pagesize 0 @@ -247,7 +247,7 @@ select * ); ``` -```sql +```sql linenums="1" --alternative version of report consumer ( session 2 ) set arraysize 1 set pagesize 0 @@ -279,14 +279,14 @@ When tests are executed with random order, randomization is applied to single le This is needed to maintain visibility and accessibility of common setup/cleanup `beforeall`/`afterall` in tests. Example: -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr.test_apply_bonus', a_random_test_order => true); end; ``` -```sql +```sql linenums="1" select * from table(ut.run('hr.test_apply_bonus', a_random_test_order => 1)); ``` @@ -301,14 +301,14 @@ Tests were executed with random order seed '302980531'. If you want to re-run tests using previously generated seed, you may do so by running them with parameter `a_random_test_order_seed` Example: -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr.test_apply_bonus', a_random_test_order_seed => 302980531); end; ``` -```sql +```sql linenums="1" select * from table(ut.run('hr.test_apply_bonus', a_random_test_order_seed => 302980531)); ``` @@ -321,18 +321,18 @@ In addition to the path, you can filter the tests to be run by specifying tags. Multiple tags are separated by comma. The framework applies `OR` logic to all specified tags so any test / suite that matches at least one tag will be included in the test run. -```sql +```sql linenums="1" begin ut.run('hr.test_apply_bonus', a_tags => 'test1,test2'); end; ``` -```sql +```sql linenums="1" select * from table(ut.run('hr.test_apply_bonus', a_tags => 'suite1')) ``` You can also exclude specific tags by adding a `-` (dash) in front of the tag -```sql +```sql linenums="1" select * from table(ut.run('hr.test_apply_bonus', a_tags => '-suite1')) ``` @@ -347,7 +347,7 @@ Setting this flag to true has following side-effects: - automatic rollback is forced to be disabled in test-run even if it was explicitly enabled by using annotation `--%rollback(manual) Example invocation: -```sql +```sql linenums="1" set serveroutput on begin ut.run('hr.test_apply_bonus', a_force_manual_rollback => true); @@ -366,7 +366,7 @@ If you run your tests using `utPLSQL-cli`, this is done automatically and no act To make sure that the reports will display your national characters properly when running from IDE like SQLDeveloper/TOAD/SQLPlus or sqlcl you need to provide the charaterset manualy to `ut.run`. Example call with characterset provided: -```sql +```sql linenums="1" begin ut.run('hr.test_apply_bonus', ut_junit_reporter(), a_client_character_set => 'Windows-1251'); end; diff --git a/mkdocs.yml b/mkdocs.yml index 487505097..713722620 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -60,11 +60,13 @@ extra: version: # disable for offline docs provider: mike # disable for offline docs markdown_extensions: + - admonition + - pymdownx.details + - pymdownx.superfences - pymdownx.highlight: anchor_linenums: true - pymdownx.inlinehilite - pymdownx.snippets - - pymdownx.superfences - pymdownx.caret - pymdownx.mark - pymdownx.tilde diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index fe2255e59..31c90615e 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -60,11 +60,13 @@ extra: # version: # disable for offline docs # provider: mike # disable for offline docs markdown_extensions: + - admonition + - pymdownx.details + - pymdownx.superfences - pymdownx.highlight: anchor_linenums: true - pymdownx.inlinehilite - pymdownx.snippets - - pymdownx.superfences - pymdownx.caret - pymdownx.mark - pymdownx.tilde From 535f682336801e450c22ae7bc8c7281e15164197 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 26 Oct 2022 22:28:55 +0100 Subject: [PATCH 378/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 961ba3060..0a3d8196f 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 2b625c7d0..928066c17 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index a915f2a52..bae8cc5f9 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 5d4ed97cf..a0752effd 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index bc7e1e63b..6829b6ff6 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 2e2d4af9f..da3ee4b59 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 2c13fb649..112e66dd5 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b39ab803b..dedd8fe14 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 20707e917..d3c0f1881 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index c795c5421..932c34f94 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index a972fa2e3..e3378f69b 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c199d7095..ac684258c 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 6dfa66140..4bf1a7ef6 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 6ee0b546f..4376106c8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 467116479..a7a8a3540 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 18270e707..482aec796 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index a219012fd..32f8b53f6 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4063--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 06b17ccbf..3c80498cb 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4063-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4064-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 05753e533c90b4f82af449728f27b5e5541e4aad Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 21 Nov 2022 23:37:15 +0200 Subject: [PATCH 379/887] Improving expectations documentation --- docs/userguide/expectations.md | 38 +++++++++++++++++----------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index e3378f69b..242922d69 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -388,7 +388,7 @@ Finished in .009229 seconds 1 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s) ``` -For more details see documentation of the [`--%throws` annotation.](annotations.md#throws-annotation) +For more details see documentation of the [`--%throws` annotation.](annotations.md#throws) ## Matchers @@ -396,7 +396,7 @@ For more details see documentation of the [`--%throws` annotation.](annotations. You can choose different matchers to validate that your PL/SQL code is working as expected. -## be_between +### be_between Validates that the actual value is between the lower and upper bound. Example: @@ -452,7 +452,7 @@ SUCCESS Actual: 'Abb' (varchar2) was expected to be between: 'Aba' and 'Abc' ``` -## be_empty +### be_empty Unary matcher that validates if the provided dataset is empty. Can be used with `BLOB`,`CLOB`, `refcursor` or `nested table`/`varray` passed as `ANYDATA` @@ -501,7 +501,7 @@ FAILURE at "anonymous block", line 9 ``` -## be_false +### be_false Unary matcher that validates if the provided value is false. Usage: @@ -529,7 +529,7 @@ SUCCESS Actual: TRUE (boolean) was expected not to be false ``` -## be_greater_or_equal +### be_greater_or_equal Checks if the actual value is greater or equal than the expected. Usage: @@ -557,7 +557,7 @@ SUCCESS Actual: 2019-07-07T22:43:29 (date) was expected not to be greater or equal: 2019-07-08T22:43:29 (date) ``` -## be_greater_than +### be_greater_than Checks if the actual value is greater than the expected. Usage: @@ -585,7 +585,7 @@ SUCCESS Actual: 0 (number) was expected not to be greater than: 1 (number) ``` -## be_less_or_equal +### be_less_or_equal Checks if the actual value is less or equal than the expected. Usage: @@ -613,7 +613,7 @@ SUCCESS Actual: 4 (number) was expected not to be less or equal: 3 (number) ``` -## be_less_than +### be_less_than Checks if the actual value is less than the expected. Usage: @@ -641,7 +641,7 @@ FAILURE at "anonymous block", line 5 ``` -## be_like +### be_like Validates that the actual value is like the expected expression. Syntax: @@ -679,7 +679,7 @@ SUCCESS Actual: 'Lorem_impsum' (varchar2) was expected not to be like: '%reM%' ``` -## be_not_null +### be_not_null Unary matcher that validates if the actual value is not null. Usage: @@ -707,7 +707,7 @@ SUCCESS Actual: NULL (varchar2) was expected not to be not null ``` -## be_null +### be_null Unary matcher that validates if the actual value is null. Usage: @@ -735,7 +735,7 @@ SUCCESS Actual: 0 (number) was expected not to be null ``` -## be_true +### be_true Unary matcher that validates if the provided value is true. Usage: @@ -763,7 +763,7 @@ FAILURE at "anonymous block", line 5 ``` -## have_count +### have_count Unary matcher that validates if the provided dataset count is equal to expected value. Can be used with `refcursor`, `json` or `table type` @@ -799,7 +799,7 @@ FAILURE at "anonymous block", line 11 ``` -## match +### match Validates that the actual value is matching the expected regular expression. Syntax: @@ -833,7 +833,7 @@ FAILURE at "anonymous block", line 5 ``` -## equal +### equal The `equal` matcher is very restrictive. Test using this matcher succeeds only when the compared data-types are exactly the same. If you are comparing a `varchar2` to a `number`, it will fail even if the text contains the same numeric value as the number. The matcher will also fail when comparing a `timestamp` to a `timestamp with timezone` data-type etc. @@ -919,7 +919,7 @@ FAILURE The `a_nulls_are_equal` parameter controls the behavior of a `null = null` comparison.
    To change the behavior of `NULL = NULL` comparison pass the `a_nulls_are_equal => false` to the `equal` matcher. -## contain +### contain This matcher supports only compound data-types comparison. It check if the actual set contains all values of expected subset. @@ -1100,7 +1100,7 @@ SUCCESS DEF ``` -## to_be_within of +### to_be_within of Determines whether expected value is within range (tolerance) from another value. @@ -1181,7 +1181,7 @@ Failures: ``` -## to_be_within_pct of +### to_be_within_pct of Determines whether actual value is within percentage range of expected value. The matcher only works with `number` data-type. @@ -1603,7 +1603,7 @@ FAILURE ### Comparing cursor data containing DATE fields -!!! warning "Important note" +!!! warning "Important" utPLSQL uses XMLType internally to represent rows of the cursor data. This is by far the most flexible method and allows comparison of cursors containing LONG, CLOB, BLOB, user defined types and even nested cursors.
    Due to the way Oracle handles DATE data type when converting from cursor data to XML, utPLSQL has no control over the DATE formatting.
    From ce1a289959ddf284cbf0c03a3ed7ae13fcc07f99 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 21 Nov 2022 23:52:52 +0200 Subject: [PATCH 380/887] Changed to develop version of `mike` for mkdocs - see https://github.com/jimporter/mike/issues/123 --- .github/workflows/build.yml | 4 +++- .github/workflows/release.yml | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 92bf0752e..904c9772a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -255,7 +255,9 @@ jobs: pip install mkdocs pip install mkdocs-git-revision-date-localized-plugin pip install mkdocs-material - pip install mike +# pip install mike +# using develop version of mike - see https://github.com/jimporter/mike/issues/123 + pip install git+https://github.com/jimporter/mike.git mike deploy -p develop dispatch: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index acac5f1aa..8a4423758 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -40,7 +40,9 @@ jobs: pip install mkdocs pip install mkdocs-git-revision-date-localized-plugin pip install mkdocs-material - pip install mike +# pip install mike +# using develop version of mike - see https://github.com/jimporter/mike/issues/123 + pip install git+https://github.com/jimporter/mike.git mike deploy -p -u ${UTPLSQL_VERSION} latest mkdocs build --clean -f mkdocs_offline.yml rm -rf docs/* From a216a3cb0e409db7a4bec13e2ec9616c8dd1c431 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 21 Nov 2022 23:52:52 +0200 Subject: [PATCH 381/887] Changed to develop version of `mike` for mkdocs - see https://github.com/jimporter/mike/issues/123 --- .github/workflows/build.yml | 2 -- .github/workflows/release.yml | 2 -- 2 files changed, 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 904c9772a..441a29d0d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -255,8 +255,6 @@ jobs: pip install mkdocs pip install mkdocs-git-revision-date-localized-plugin pip install mkdocs-material -# pip install mike -# using develop version of mike - see https://github.com/jimporter/mike/issues/123 pip install git+https://github.com/jimporter/mike.git mike deploy -p develop diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 8a4423758..6ec82435f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -40,8 +40,6 @@ jobs: pip install mkdocs pip install mkdocs-git-revision-date-localized-plugin pip install mkdocs-material -# pip install mike -# using develop version of mike - see https://github.com/jimporter/mike/issues/123 pip install git+https://github.com/jimporter/mike.git mike deploy -p -u ${UTPLSQL_VERSION} latest mkdocs build --clean -f mkdocs_offline.yml From 7eaffbde89af288e04cb5ab6384341cd72d8f3f6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 21 Nov 2022 22:06:17 +0000 Subject: [PATCH 382/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 0a3d8196f..83ccdcdf8 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 928066c17..c7336985b 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index bae8cc5f9..2a32da1e1 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index a0752effd..49c005679 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 6829b6ff6..3ce91e6b3 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index da3ee4b59..e90367224 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 112e66dd5..441b2cae4 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index dedd8fe14..bda84931c 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index d3c0f1881..028044c29 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 932c34f94..d39e11abc 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 242922d69..dc38a1dbf 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index ac684258c..8608d1375 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 4bf1a7ef6..6883a123e 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 4376106c8..056459fc7 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index a7a8a3540..ebecc840c 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 482aec796..87e8fdc5a 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 32f8b53f6..07861ae3e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4064--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 3c80498cb..825683207 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4064-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4067-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 5508dff49c92a8691cc5cffa2ff0afc909cb6fb8 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 11 Dec 2022 18:30:51 +0000 Subject: [PATCH 383/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 83ccdcdf8..9428fddd5 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index c7336985b..d4dbf52cb 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 2a32da1e1..181f9ebe0 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 49c005679..beff5f9cd 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 3ce91e6b3..4b1219689 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index e90367224..7f99edbdb 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 441b2cae4..2272eb321 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index bda84931c..2eac7a733 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 028044c29..2e54cfba5 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index d39e11abc..43b362e35 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index dc38a1dbf..bf5d53809 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8608d1375..83f80b145 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 6883a123e..9fd89ea83 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 056459fc7..faef86500 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ebecc840c..3df400c98 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 87e8fdc5a..363ef20b3 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 07861ae3e..633346370 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4067--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 825683207..9dba896a9 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4067-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4068-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 45d20eb5fd6885456b35e9ff2856213671bf9757 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 11 Dec 2022 19:13:58 +0000 Subject: [PATCH 384/887] Updated project version after build [skip ci] --- VERSION | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pks | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/VERSION b/VERSION index d0237db61..ecbc73caf 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.13-develop +v3.1.13 diff --git a/docs/about/authors.md b/docs/about/authors.md index 9428fddd5..bb8b46bb2 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index d4dbf52cb..1381a7d43 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 181f9ebe0..b241fedd7 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index beff5f9cd..06d113450 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 4b1219689..26e95ff2f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7f99edbdb..629ef4237 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 2272eb321..a21fa7292 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 2eac7a733..a5a9c40b6 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 2e54cfba5..2220807ae 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 43b362e35..f585ad14d 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index bf5d53809..128b05b7b 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 83f80b145..60b3f54b7 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 9fd89ea83..3ac993327 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index faef86500..913abf783 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3df400c98..b7a516a87 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 363ef20b3..84a71c0f1 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 633346370..a081a0a1b 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4069-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index 5d6cefe12..77cc387a8 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -3,7 +3,7 @@ sonar.organization=utplsql sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.13-develop +sonar.projectVersion=v3.1.13 # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 9dba896a9..86f25f8fa 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4068-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4069'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From b84535d4532f928f6312777a7b402b36be3fb625 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 11 Dec 2022 21:17:50 +0200 Subject: [PATCH 385/887] Fixed documentation build process for release branch, --- .github/workflows/build.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 441a29d0d..0ec37efe2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -213,8 +213,7 @@ jobs: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} if: | github.repository == 'utPLSQL/utPLSQL' && - github.base_ref == null && - ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' ) + github.base_ref == null && github.ref == 'refs/heads/develop' steps: - name: 🔍 API_TOKEN_GITHUB if: env.API_TOKEN_GITHUB == '' From ebb59383d90e64a1b265fe85a7a0034f18ac9d29 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 11 Dec 2022 19:27:38 +0000 Subject: [PATCH 386/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 9428fddd5..e8d37d574 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index d4dbf52cb..5b94283db 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 181f9ebe0..26c838e8a 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index beff5f9cd..d2580f63b 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 4b1219689..0f87193a4 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7f99edbdb..6bb8163e6 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 2272eb321..9913f9a90 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 2eac7a733..94db22808 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 2e54cfba5..689732e0b 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 43b362e35..81024551e 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index bf5d53809..b6854a8cd 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 83f80b145..aca1963a7 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 9fd89ea83..64d59877d 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index faef86500..7957d106e 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3df400c98..ab3a5b56c 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 363ef20b3..dbcfc2b59 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 633346370..f76e86f23 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4068--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 9dba896a9..f965536cb 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4068-develop'; + gc_version constant varchar2(50) := 'v3.1.13.4070-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 1846c4fc638508f5cf7a86546e8d6dd572624a73 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 11 Dec 2022 22:18:30 +0200 Subject: [PATCH 387/887] Updated releasing.md --- development/releasing.md | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/development/releasing.md b/development/releasing.md index bcc89067a..4b9e2f7f9 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -3,7 +3,7 @@ To create a release follow the below steps ## Release preparation - - Create a **draft** of Release from the `main` branch using [github releases page](https://github.com/utPLSQL/utPLSQL/releases) and populate release description using information found on the issues and pull requests **since previous release**. + - Create a **draft** of a Release with version number `vX.Y.X` sourced from the `main` branch using [github releases page](https://github.com/utPLSQL/utPLSQL/releases) and populate release description using information found on the issues and pull requests **since previous release**. To find issues closed after certain date use [advanced filters](https://help.github.com/articles/searching-issues-and-pull-requests/#search-by-open-or-closed-state). Example: [`is:issue closed:>2018-07-22`](https://github.com/utPLSQL/utPLSQL/issues?utf8=%E2%9C%93&q=is%3Aissue+closed%3A%3E2018-07-22+) @@ -11,11 +11,9 @@ To create a release follow the below steps - create the release branch from `develop` branch and make sure to name the release branch: `release/vX.Y.Z` - update, commit and push at least one file change in the release branch, to kick off a build on [GithubActions](https://github.com/utPLSQL/utPLSQL/actions) or kick-off a build manually for that branch after it was created on github. - wait for the build to complete successfully as it will update the version to be release number (without develop) - - merge the release branch to `main` branch and wait for build on `main` branch to complete successfully (do not use Squash/rebase for merge operation) - - Publish the release on the `main` branch and tag it with version number `vX.Y.Z` - - Wait for the release build to finish successfully on Github Actions as this will upload release artifacts (`zip` and `tar.gz` files along with `md5`) - - After A Release build was completed successfully, merge main branch back into develop branch. - - At this point, main branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. + - merge the release branch to `main` branch and publish [the previously prepared](#release-preparation) release draft. + - Wait for the [Github Actions `Release`](https://github.com/utPLSQL/utPLSQL/actions/workflows/release.yml) process to complete successfully. The process will upload release artifacts (`zip` and `tar.gz` files along with `md5`) + - After Release build was completed successfully, merge the `main` branch back into `develop` branch. At this point, main branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. - After develop branch was built, increase the version number in `VERSION` file to represent next planned release version. - Clone `utplsql.githug.io` project and add a new announcement about next version being released in `_posts`. Use previous announcements as a template. Make sure to set date, time and post title properly. From 90d0e5d53e9673e270053be995885868535d81cd Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 11 Dec 2022 22:22:10 +0200 Subject: [PATCH 388/887] Fixed release.yml --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 6ec82435f..a748d1cbd 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -67,7 +67,7 @@ jobs: slack-workflow-status: if: always() name: Post Workflow Status To Slack - needs: [ publish, upload_artifacts ] + needs: [ upload_artifacts ] runs-on: ubuntu-latest steps: - name: Slack Workflow Notification From 86cd04dcf436eb1545105f70c4c207d5a78b7bbb Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 11 Dec 2022 22:58:00 +0200 Subject: [PATCH 389/887] Updated releasing.md --- development/releasing.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/development/releasing.md b/development/releasing.md index 4b9e2f7f9..2b9be317a 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -15,7 +15,10 @@ To create a release follow the below steps - Wait for the [Github Actions `Release`](https://github.com/utPLSQL/utPLSQL/actions/workflows/release.yml) process to complete successfully. The process will upload release artifacts (`zip` and `tar.gz` files along with `md5`) - After Release build was completed successfully, merge the `main` branch back into `develop` branch. At this point, main branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. - After develop branch was built, increase the version number in `VERSION` file to represent next planned release version. - - Clone `utplsql.githug.io` project and add a new announcement about next version being released in `_posts`. Use previous announcements as a template. Make sure to set date, time and post title properly. + - Clone `utplsql.githug.io` project and: + - Add a new announcement about next version being released in `docs/_posts`. Use previous announcements as a template. Make sure to set date, time and post title properly. + - Add the post to list in `mkdocs.yml` file in root directory of that repository. + - Add the link to the post at the beginning of the `docs/index.md` file. The following will happen: - build executed on branch `release/vX.Y.Z-[something]` updates files `sonar-project.properties`, `VERSION` with project version derived from the release branch name From 315e5c6f07e1b3d299bebea722a022ffb60bbab6 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 21 Jan 2023 00:29:49 +0200 Subject: [PATCH 390/887] Updated version to 3.1.14 --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index ecbc73caf..3b63c19c9 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.13 +v3.1.14 From f72db1e7dacd09ee273e9df3c65d908db7b3e197 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 20 Jan 2023 22:38:37 +0000 Subject: [PATCH 391/887] Updated project version after build [skip ci] --- VERSION | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pks | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/VERSION b/VERSION index 3b63c19c9..5fcdcb942 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.14 +v3.1.14-develop diff --git a/docs/about/authors.md b/docs/about/authors.md index e8d37d574..cd50c02bf 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 5b94283db..52b771abc 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 26c838e8a..c869cfa4f 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index d2580f63b..ec7316027 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 0f87193a4..4a9108f8a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 6bb8163e6..dc7d2f0ad 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 9913f9a90..87ede5b5f 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 94db22808..905a27acb 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 689732e0b..5e9331e6b 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 81024551e..0da0f5178 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b6854a8cd..0655700af 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index aca1963a7..a6948f9d7 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 64d59877d..ad3bfe97e 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 7957d106e..8cb47b973 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ab3a5b56c..3d0bf7d84 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index dbcfc2b59..0ab199c08 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index f76e86f23..1a554dfc9 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.13.4070--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index 77cc387a8..d088e9ccb 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -3,7 +3,7 @@ sonar.organization=utplsql sonar.projectKey=utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.13 +sonar.projectVersion=v3.1.14-develop # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f965536cb..438abddd2 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.13.4070-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4072-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From da6ee7089b4dcdab01b7782562f113b3f34ddab0 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 8 Feb 2023 21:50:46 +0200 Subject: [PATCH 392/887] Refactored output buffers to have better segregation of responsibilities. Changed behavior of output buffer `get_lines` procedure to stop immediately after consuming all produced data if producer has stopped. Changed behavior of output buffer `get_lines` procedure not to timeout after 4 hours, if producer is still running. --- docs/userguide/install.md | 2 +- .../coverage/ut_coverage_reporter_base.tpb | 2 - .../output_buffers/ut_output_buffer_base.tpb | 133 ++++++++++++++++- .../output_buffers/ut_output_buffer_base.tps | 21 ++- .../ut_output_clob_table_buffer.tpb | 134 +++++------------- .../ut_output_clob_table_buffer.tps | 10 +- .../output_buffers/ut_output_table_buffer.tpb | 133 +++++------------ .../output_buffers/ut_output_table_buffer.tps | 10 +- source/core/types/ut_output_reporter_base.tpb | 8 +- source/core/types/ut_output_reporter_base.tps | 3 +- source/create_utplsql_owner.sql | 10 +- test/ut3_tester/core/test_output_buffer.pkb | 25 +++- test/ut3_tester/core/test_output_buffer.pks | 25 +++- test/ut3_tester_helper/coverage_helper.pkb | 19 +-- 14 files changed, 277 insertions(+), 258 deletions(-) diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ad3bfe97e..278bad788 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -121,7 +121,7 @@ The headless scripts accept three optional parameters that define: The scripts need to be executed by `SYSDBA`, in order to grant access to `DBMS_LOCK` and `DBMS_CRYPTO` system packages. !!! warning "Important" - - Grant on `DBMS_LOCK` is required only for installation on Oracle versions below 18c. For versions 18c and above, utPLSQL uses `DBMS_SESSION.SLEEP` so access to `DBMS_LOCK` package is no longer needed.
    + - `DBMS_LOCK` is required for session synchronization between main session and session consuming realtime reports.
    - The user performing the installation must have the `ADMINISTER DATABASE TRIGGER` privilege. This is required for installation of trigger that is responsible for parsing annotations at at compile-time of a package.
    - When installed with DDL trigger, utPLSQL will not be registering unit tests for any of oracle-maintained schemas.
    - For Oracle 11g following users are excluded:
    diff --git a/source/core/coverage/ut_coverage_reporter_base.tpb b/source/core/coverage/ut_coverage_reporter_base.tpb index aff4e6560..da2bd27ad 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tpb +++ b/source/core/coverage/ut_coverage_reporter_base.tpb @@ -92,7 +92,6 @@ create or replace type body ut_coverage_reporter_base is ut_coverage_helper.cleanup_tmp_table(); (l_reporter as ut_output_reporter_base).before_calling_run(null); l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options, a_client_character_set => a_client_character_set ) ); - l_reporter.on_finalize(null); for i in (select /*+ no_parallel */ x.text from table(l_reporter.get_lines(1, 1)) x ) loop pipe row (i.text); end loop; @@ -106,7 +105,6 @@ create or replace type body ut_coverage_reporter_base is ut_coverage_helper.cleanup_tmp_table(); (l_reporter as ut_output_reporter_base).before_calling_run(null); l_reporter.after_calling_run( ut_run( a_coverage_options => a_coverage_options, a_client_character_set => a_client_character_set ) ); - l_reporter.on_finalize(null); open l_result for select /*+ no_parallel */ x.text from table(l_reporter.get_lines(1, 1)) x; return l_result; end; diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index 6d7964150..c3a137b42 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -24,7 +24,7 @@ create or replace type body ut_output_buffer_base is self.self_type := coalesce(a_self_type,self.self_type); self.output_id := coalesce(a_output_id, self.output_id, sys_guid()); self.start_date := coalesce(self.start_date, sysdate); - self.last_message_id := 0; + self.last_write_message_id := 0; select /*+ no_parallel */ count(*) into l_exists from ut_output_buffer_info_tmp where output_id = self.output_id; if ( l_exists > 0 ) then update /*+ no_parallel */ ut_output_buffer_info_tmp set start_date = self.start_date where output_id = self.output_id; @@ -32,10 +32,135 @@ create or replace type body ut_output_buffer_base is insert /*+ no_parallel */ into ut_output_buffer_info_tmp(output_id, start_date) values (self.output_id, self.start_date); end if; commit; + dbms_lock.allocate_unique( self.output_id, self.lock_handle); self.is_closed := 0; end; - member function get_lines_cursor(a_initial_timeout natural := null, a_timeout_sec natural := null) return sys_refcursor is + member procedure lock_buffer(a_timeout_sec number := null) is + l_status integer; + begin + l_status := dbms_lock.request( self.lock_handle, dbms_lock.x_mode, 5, false ); + if l_status != 0 then + raise_application_error(-20000, 'Cannot allocate lock for output buffer of reporter. lock request status = '||l_status||', lock handle = '||self.lock_handle||', self.output_id ='||self.output_id); + end if; + end; + + member procedure close(self in out nocopy ut_output_buffer_base) is + l_status integer; + begin + l_status := dbms_lock.release( self.lock_handle ); + if l_status != 0 then + raise_application_error(-20000, 'Cannot release lock for output buffer of reporter. Lock_handle = '||self.lock_handle||' status = '||l_status); + end if; + self.is_closed := 1; + end; + + + member procedure remove_buffer_info(self in ut_output_buffer_base) is + pragma autonomous_transaction; + begin + delete from ut_output_buffer_info_tmp a + where a.output_id = self.output_id; + commit; + end; + + member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined is + lc_init_wait_sec constant number := coalesce(a_initial_timeout, 10 ); + lc_100_milisec constant number(1,1) := 0.1; --sleep for 100 ms between checks + lc_500_milisec constant number(3,1) := 0.5; --sleep for 1 s when waiting long + lc_1_second constant number(3,1) := 1; + l_buffer_rowids ut_varchar2_rows; + l_buffer_data ut_output_data_rows; + l_finished_flags ut_integer_list; + l_last_read_message_id integer; + l_already_waited_sec number(10,2) := 0; + l_data_finished boolean := false; + l_finished boolean := false; + l_sleep_time number(2,1) := lc_100_milisec; + l_lock_status integer; + l_producer_started boolean := false; + l_producer_finished boolean := false; + function get_lock_status return integer is + l_result integer; + l_release_status integer; + begin + l_result := dbms_lock.request( self.lock_handle, dbms_lock.s_mode, 0, false ); + if l_result = 0 then + l_release_status := dbms_lock.release( self.lock_handle ); + end if; + return l_result; + end; + begin + while not l_finished loop + + --check if the lock is still there on output - if yes, the main session is still running and so don't stop + l_lock_status := get_lock_status(); + get_data_from_buffer_table( l_last_read_message_id, l_buffer_data, l_buffer_rowids, l_finished_flags ); + + --nothing fetched from output, wait and try again + if l_buffer_data.count = 0 then + + dbms_lock.sleep(l_sleep_time); + l_already_waited_sec := l_already_waited_sec + l_sleep_time; + + -- if waited more than lc_1_second seconds then increase wait period to minimize the CPU usage. + if l_already_waited_sec >= lc_1_second then + l_sleep_time := lc_500_milisec; + end if; + + else + + l_already_waited_sec := 0; + l_sleep_time := lc_100_milisec; + + for i in 1 .. l_buffer_data.count loop + if l_buffer_data(i).text is not null then + pipe row( l_buffer_data(i) ); + elsif l_finished_flags(i) = 1 then + l_data_finished := true; + exit; + end if; + end loop; + + remove_read_data(l_buffer_rowids); + + end if; + l_producer_started := (l_lock_status <> 0 or l_buffer_data.count > 0) or l_producer_started; + l_producer_finished := (l_producer_started and l_lock_status = 0 and l_buffer_data.count = 0) or l_producer_finished; + + if not l_producer_started and l_already_waited_sec >= lc_init_wait_sec then + + if lc_init_wait_sec > 0 then + self.remove_buffer_info(); + raise_application_error( + ut_utils.gc_out_buffer_timeout, + 'Timeout occurred while waiting for report data producer to start. Waited for: '||ut_utils.to_string( l_already_waited_sec )||' seconds.' + ); + else + l_finished := true; + end if; + + elsif not l_producer_finished and a_timeout_sec is not null and l_already_waited_sec >= a_timeout_sec then + + if a_timeout_sec > 0 then + self.remove_buffer_info(); + raise_application_error( + ut_utils.gc_out_buffer_timeout, + 'Timeout occurred while waiting for more data from producer. Waited for: '||ut_utils.to_string( l_already_waited_sec )||' seconds.' + ); + else + l_finished := true; + end if; + + elsif (l_data_finished or l_producer_finished) then + l_finished := true; + end if; + end loop; + self.remove_buffer_info(); + return; + end; + + member function get_lines_cursor(a_initial_timeout number := null, a_timeout_sec number := null) return sys_refcursor is l_lines sys_refcursor; begin open l_lines for @@ -44,7 +169,7 @@ create or replace type body ut_output_buffer_base is return l_lines; end; - member procedure lines_to_dbms_output(self in ut_output_buffer_base, a_initial_timeout natural := null, a_timeout_sec natural := null) is + member procedure lines_to_dbms_output(self in ut_output_buffer_base, a_initial_timeout number := null, a_timeout_sec number := null) is l_data sys_refcursor; l_clob clob; l_item_type varchar2(32767); @@ -63,7 +188,7 @@ create or replace type body ut_output_buffer_base is end; member procedure cleanup_buffer(self in ut_output_buffer_base, a_retention_time_sec natural := null) is - gc_buffer_retention_sec constant naturaln := coalesce(a_retention_time_sec, 60 * 60 * 24); -- 24 hours + gc_buffer_retention_sec constant naturaln := coalesce(a_retention_time_sec, 60 * 60 * 24 * 5); -- 5 days l_retention_days number := gc_buffer_retention_sec / (60 * 60 * 24); l_max_retention_date date := sysdate - l_retention_days; pragma autonomous_transaction; diff --git a/source/core/output_buffers/ut_output_buffer_base.tps b/source/core/output_buffers/ut_output_buffer_base.tps index 98a6847cd..8000ea2e7 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tps +++ b/source/core/output_buffers/ut_output_buffer_base.tps @@ -19,16 +19,27 @@ create or replace type ut_output_buffer_base force authid definer as object( output_id raw(32), is_closed number(1,0), start_date date, - last_message_id number(38,0), + last_write_message_id number(38,0), + lock_handle varchar2(30 byte), self_type varchar2(250 byte), member procedure init(self in out nocopy ut_output_buffer_base, a_output_id raw := null, a_self_type varchar2 := null), - member function get_lines_cursor(a_initial_timeout natural := null, a_timeout_sec natural := null) return sys_refcursor, - member procedure lines_to_dbms_output(self in ut_output_buffer_base, a_initial_timeout natural := null, a_timeout_sec natural := null), + member procedure lock_buffer(a_timeout_sec number := null), + member function get_lines_cursor(a_initial_timeout number := null, a_timeout_sec number := null) return sys_refcursor, + member procedure lines_to_dbms_output(self in ut_output_buffer_base, a_initial_timeout number := null, a_timeout_sec number := null), member procedure cleanup_buffer(self in ut_output_buffer_base, a_retention_time_sec natural := null), - not instantiable member procedure close(self in out nocopy ut_output_buffer_base), + member procedure remove_buffer_info(self in ut_output_buffer_base), + not instantiable member procedure get_data_from_buffer_table( + self in ut_output_buffer_base, + a_last_read_message_id in out nocopy integer, + a_buffer_data out nocopy ut_output_data_rows, + a_buffer_rowids out nocopy ut_varchar2_rows, + a_finished_flags out nocopy ut_integer_list + ), + member procedure close(self in out nocopy ut_output_buffer_base), + not instantiable member procedure remove_read_data(self in ut_output_buffer_base, a_buffer_rowids ut_varchar2_rows), not instantiable member procedure send_line(self in out nocopy ut_output_buffer_base, a_text varchar2, a_item_type varchar2 := null), not instantiable member procedure send_lines(self in out nocopy ut_output_buffer_base, a_text_list ut_varchar2_rows, a_item_type varchar2 := null), not instantiable member procedure send_clob(self in out nocopy ut_output_buffer_base, a_text clob, a_item_type varchar2 := null), - not instantiable member function get_lines(a_initial_timeout natural := null, a_timeout_sec natural := null) return ut_output_data_rows pipelined + member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined ) not final not instantiable / diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index 66ff71c62..e47f0bcb0 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -22,23 +22,13 @@ create or replace type body ut_output_clob_table_buffer is return; end; - overriding member procedure close(self in out nocopy ut_output_clob_table_buffer) is - pragma autonomous_transaction; - begin - self.last_message_id := self.last_message_id + 1; - insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, is_finished) - values (self.output_id, self.last_message_id, 1); - commit; - self.is_closed := 1; - end; - overriding member procedure send_line(self in out nocopy ut_output_clob_table_buffer, a_text varchar2, a_item_type varchar2 := null) is pragma autonomous_transaction; begin if a_text is not null or a_item_type is not null then - self.last_message_id := self.last_message_id + 1; + self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_message_id, a_text, a_item_type); + values (self.output_id, self.last_write_message_id, a_text, a_item_type); end if; commit; end; @@ -47,10 +37,10 @@ create or replace type body ut_output_clob_table_buffer is pragma autonomous_transaction; begin insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) - select /*+ no_parallel */ self.output_id, self.last_message_id + rownum, t.column_value, a_item_type + select /*+ no_parallel */ self.output_id, self.last_write_message_id + rownum, t.column_value, a_item_type from table(a_text_list) t where t.column_value is not null or a_item_type is not null; - self.last_message_id := self.last_message_id + SQL%rowcount; + self.last_write_message_id := self.last_write_message_id + SQL%rowcount; commit; end; @@ -58,99 +48,43 @@ create or replace type body ut_output_clob_table_buffer is pragma autonomous_transaction; begin if a_text is not null and a_text != empty_clob() or a_item_type is not null then - self.last_message_id := self.last_message_id + 1; + self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_message_id, a_text, a_item_type); + values (self.output_id, self.last_write_message_id, a_text, a_item_type); end if; commit; end; - overriding member function get_lines(a_initial_timeout natural := null, a_timeout_sec natural := null) return ut_output_data_rows pipelined is - type t_rowid_tab is table of urowid; - l_message_rowids t_rowid_tab; - l_buffer_data ut_output_data_rows; - l_finished_flags ut_integer_list; - l_already_waited_for number(10,2) := 0; - l_finished boolean := false; - lc_init_wait_sec constant naturaln := coalesce(a_initial_timeout, 60 ); -- 1 minute - lc_max_wait_sec constant naturaln := coalesce(a_timeout_sec, 60 * 60 * 4); -- 4 hours - l_wait_for integer := lc_init_wait_sec; - lc_short_sleep_time constant number(1,1) := 0.1; --sleep for 100 ms between checks - lc_long_sleep_time constant number(1) := 1; --sleep for 1 s when waiting long - lc_long_wait_time constant number(1) := 1; --waiting more than 1 sec - l_sleep_time number(2,1) := lc_short_sleep_time; - lc_bulk_limit constant integer := 5000; - l_max_message_id integer := lc_bulk_limit; - - procedure remove_read_data(a_message_rowids t_rowid_tab) is - pragma autonomous_transaction; - begin - forall i in 1 .. a_message_rowids.count - delete from ut_output_clob_buffer_tmp a - where rowid = a_message_rowids(i); - commit; - end; + overriding member procedure get_data_from_buffer_table( + self in ut_output_clob_table_buffer, + a_last_read_message_id in out nocopy integer, + a_buffer_data out nocopy ut_output_data_rows, + a_buffer_rowids out nocopy ut_varchar2_rows, + a_finished_flags out nocopy ut_integer_list + ) is + lc_bulk_limit constant integer := 5000; + begin + a_last_read_message_id := coalesce(a_last_read_message_id, 0); + with ordered_buffer as ( + select /*+ no_parallel index(a) */ ut_output_data_row(a.text, a.item_type), rowidtochar(a.rowid), is_finished + from ut_output_clob_buffer_tmp a + where a.output_id = self.output_id + and a.message_id <= a_last_read_message_id + lc_bulk_limit + order by a.message_id + ) + select /*+ no_parallel */ b.* + bulk collect into a_buffer_data, a_buffer_rowids, a_finished_flags + from ordered_buffer b; + a_last_read_message_id := a_last_read_message_id + a_finished_flags.count; + end; - procedure remove_buffer_info is + overriding member procedure remove_read_data(self in ut_output_clob_table_buffer, a_buffer_rowids ut_varchar2_rows) is pragma autonomous_transaction; - begin - delete from ut_output_buffer_info_tmp a - where a.output_id = self.output_id; - commit; - end; - - begin - while not l_finished loop - with ordered_buffer as ( - select /*+ no_parallel index(a) */ a.rowid, ut_output_data_row(a.text, a.item_type), is_finished - from ut_output_clob_buffer_tmp a - where a.output_id = self.output_id - and a.message_id <= l_max_message_id - order by a.message_id - ) - select /*+ no_parallel */ b.* - bulk collect into l_message_rowids, l_buffer_data, l_finished_flags - from ordered_buffer b; - - --nothing fetched from output, wait and try again - if l_buffer_data.count = 0 then - $if dbms_db_version.version >= 18 $then - dbms_session.sleep(l_sleep_time); - $else - dbms_lock.sleep(l_sleep_time); - $end - l_already_waited_for := l_already_waited_for + l_sleep_time; - if l_already_waited_for > lc_long_wait_time then - l_sleep_time := lc_long_sleep_time; - end if; - else - --reset wait time - -- we wait lc_max_wait_sec for new message - l_wait_for := lc_max_wait_sec; - l_already_waited_for := 0; - l_sleep_time := lc_short_sleep_time; - for i in 1 .. l_buffer_data.count loop - if l_buffer_data(i).text is not null then - pipe row(l_buffer_data(i)); - elsif l_finished_flags(i) = 1 then - l_finished := true; - exit; - end if; - end loop; - remove_read_data(l_message_rowids); - l_max_message_id := l_max_message_id + lc_bulk_limit; - end if; - if l_finished or l_already_waited_for >= l_wait_for then - remove_buffer_info(); - if l_already_waited_for > 0 and l_already_waited_for >= l_wait_for then - raise_application_error( - ut_utils.gc_out_buffer_timeout, - 'Timeout occurred while waiting for output data. Waited for: '||l_already_waited_for||' seconds.' - ); - end if; - end if; - end loop; - return; + begin + forall i in 1 .. a_buffer_rowids.count + delete from ut_output_clob_buffer_tmp a + where rowid = chartorowid(a_buffer_rowids(i)); + commit; end; end; diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tps b/source/core/output_buffers/ut_output_clob_table_buffer.tps index 7b98efaba..ccd710a8f 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tps +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tps @@ -20,7 +20,13 @@ create or replace type ut_output_clob_table_buffer under ut_output_buffer_base ( overriding member procedure send_line(self in out nocopy ut_output_clob_table_buffer, a_text varchar2, a_item_type varchar2 := null), overriding member procedure send_lines(self in out nocopy ut_output_clob_table_buffer, a_text_list ut_varchar2_rows, a_item_type varchar2 := null), overriding member procedure send_clob(self in out nocopy ut_output_clob_table_buffer, a_text clob, a_item_type varchar2 := null), - overriding member procedure close(self in out nocopy ut_output_clob_table_buffer), - overriding member function get_lines(a_initial_timeout natural := null, a_timeout_sec natural := null) return ut_output_data_rows pipelined + overriding member procedure get_data_from_buffer_table( + self in ut_output_clob_table_buffer, + a_last_read_message_id in out nocopy integer, + a_buffer_data out nocopy ut_output_data_rows, + a_buffer_rowids out nocopy ut_varchar2_rows, + a_finished_flags out nocopy ut_integer_list + ), + overriding member procedure remove_read_data(self in ut_output_clob_table_buffer, a_buffer_rowids ut_varchar2_rows) ) not final / diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index 1809a49d5..189baf075 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -22,16 +22,6 @@ create or replace type body ut_output_table_buffer is return; end; - overriding member procedure close(self in out nocopy ut_output_table_buffer) is - pragma autonomous_transaction; - begin - self.last_message_id := self.last_message_id + 1; - insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, is_finished) - values (self.output_id, self.last_message_id, 1); - commit; - self.is_closed := 1; - end; - overriding member procedure send_line(self in out nocopy ut_output_table_buffer, a_text varchar2, a_item_type varchar2 := null) is pragma autonomous_transaction; begin @@ -44,9 +34,9 @@ create or replace type body ut_output_table_buffer is a_item_type ); else - self.last_message_id := self.last_message_id + 1; + self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_message_id, a_text, a_item_type); + values (self.output_id, self.last_write_message_id, a_text, a_item_type); end if; commit; end if; @@ -56,10 +46,10 @@ create or replace type body ut_output_table_buffer is pragma autonomous_transaction; begin insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) - select /*+ no_parallel */ self.output_id, self.last_message_id + rownum, t.column_value, a_item_type + select /*+ no_parallel */ self.output_id, self.last_write_message_id + rownum, t.column_value, a_item_type from table(a_text_list) t where t.column_value is not null or a_item_type is not null; - self.last_message_id := self.last_message_id + SQL%rowcount; + self.last_write_message_id := self.last_write_message_id + SQL%rowcount; commit; end; @@ -75,100 +65,41 @@ create or replace type body ut_output_table_buffer is a_item_type ); else - self.last_message_id := self.last_message_id + 1; + self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_message_id, a_text, a_item_type); + values (self.output_id, self.last_write_message_id, a_text, a_item_type); end if; commit; end if; end; - overriding member function get_lines(a_initial_timeout natural := null, a_timeout_sec natural := null) return ut_output_data_rows pipelined is - l_buffer_data ut_varchar2_rows; - l_item_types ut_varchar2_rows; - l_finished_flags ut_integer_list; - l_already_waited_for number(10,2) := 0; - l_finished boolean := false; - lc_init_wait_sec constant naturaln := coalesce(a_initial_timeout, 60 ); -- 1 minute - lc_max_wait_sec constant naturaln := coalesce(a_timeout_sec, 60 * 60 * 4); -- 4 hours - l_wait_for integer := lc_init_wait_sec; - lc_short_sleep_time constant number(1,1) := 0.1; --sleep for 100 ms between checks - lc_long_sleep_time constant number(1) := 1; --sleep for 1 s when waiting long - lc_long_wait_time constant number(1) := 1; --waiting more than 1 sec - l_sleep_time number(2,1) := lc_short_sleep_time; - lc_bulk_limit constant integer := 5000; - l_max_message_id integer := lc_bulk_limit; - - procedure get_data_from_buffer( - a_max_message_id integer, - a_buffer_data out nocopy ut_varchar2_rows, - a_item_types out nocopy ut_varchar2_rows, - a_finished_flags out nocopy ut_integer_list - ) is - pragma autonomous_transaction; - begin - delete /*+ no_parallel */ from ( - select /*+ no_parallel */ * - from ut_output_buffer_tmp o - where o.output_id = self.output_id - and o.message_id <= a_max_message_id - order by o.message_id - ) d - returning d.text, d.item_type, d.is_finished - bulk collect into a_buffer_data, a_item_types, a_finished_flags; - commit; - - end; - - procedure remove_buffer_info is - pragma autonomous_transaction; - begin - delete from ut_output_buffer_info_tmp a - where a.output_id = self.output_id; - commit; - end; + overriding member procedure get_data_from_buffer_table( + self in ut_output_table_buffer, + a_last_read_message_id in out nocopy integer, + a_buffer_data out nocopy ut_output_data_rows, + a_buffer_rowids out nocopy ut_varchar2_rows, + a_finished_flags out nocopy ut_integer_list + ) is + lc_bulk_limit constant integer := 20000; + pragma autonomous_transaction; + begin + a_last_read_message_id := coalesce(a_last_read_message_id,0); + delete /*+ no_parallel */ from ( + select /*+ no_parallel */ * + from ut_output_buffer_tmp o + where o.output_id = self.output_id + and o.message_id <= a_last_read_message_id + lc_bulk_limit + order by o.message_id + ) d + returning ut_output_data_row(d.text, d.item_type), d.is_finished + bulk collect into a_buffer_data, a_finished_flags; + a_last_read_message_id := a_last_read_message_id + a_finished_flags.count; + commit; + end; - begin - while not l_finished loop - get_data_from_buffer( l_max_message_id, l_buffer_data, l_item_types, l_finished_flags); - --nothing fetched from output, wait and try again - if l_buffer_data.count = 0 then - $if dbms_db_version.version >= 18 $then - dbms_session.sleep(l_sleep_time); - $else - dbms_lock.sleep(l_sleep_time); - $end - l_already_waited_for := l_already_waited_for + l_sleep_time; - if l_already_waited_for > lc_long_wait_time then - l_sleep_time := lc_long_sleep_time; - end if; - else - --reset wait time - -- we wait lc_max_wait_sec for new message - l_wait_for := lc_max_wait_sec; - l_already_waited_for := 0; - l_sleep_time := lc_short_sleep_time; - for i in 1 .. l_buffer_data.count loop - if l_buffer_data(i) is not null then - pipe row(ut_output_data_row(l_buffer_data(i),l_item_types(i))); - elsif l_finished_flags(i) = 1 then - l_finished := true; - exit; - end if; - end loop; - l_max_message_id := l_max_message_id + lc_bulk_limit; - end if; - if l_finished or l_already_waited_for >= l_wait_for then - remove_buffer_info(); - if l_already_waited_for > 0 and l_already_waited_for >= l_wait_for then - raise_application_error( - ut_utils.gc_out_buffer_timeout, - 'Timeout occurred while waiting for output data. Waited for: '||l_already_waited_for||' seconds.' - ); - end if; - end if; - end loop; - return; + overriding member procedure remove_read_data(self in ut_output_table_buffer, a_buffer_rowids ut_varchar2_rows) is + begin + null; end; end; diff --git a/source/core/output_buffers/ut_output_table_buffer.tps b/source/core/output_buffers/ut_output_table_buffer.tps index 726b692f8..721e5eb8a 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tps +++ b/source/core/output_buffers/ut_output_table_buffer.tps @@ -20,7 +20,13 @@ create or replace type ut_output_table_buffer under ut_output_buffer_base ( overriding member procedure send_line(self in out nocopy ut_output_table_buffer, a_text varchar2, a_item_type varchar2 := null), overriding member procedure send_lines(self in out nocopy ut_output_table_buffer, a_text_list ut_varchar2_rows, a_item_type varchar2 := null), overriding member procedure send_clob(self in out nocopy ut_output_table_buffer, a_text clob, a_item_type varchar2 := null), - overriding member procedure close(self in out nocopy ut_output_table_buffer), - overriding member function get_lines(a_initial_timeout natural := null, a_timeout_sec natural := null) return ut_output_data_rows pipelined + overriding member procedure get_data_from_buffer_table( + self in ut_output_table_buffer, + a_last_read_message_id in out nocopy integer, + a_buffer_data out nocopy ut_output_data_rows, + a_buffer_rowids out nocopy ut_varchar2_rows, + a_finished_flags out nocopy ut_integer_list + ), + overriding member procedure remove_read_data(self in ut_output_table_buffer, a_buffer_rowids ut_varchar2_rows) ) not final / diff --git a/source/core/types/ut_output_reporter_base.tpb b/source/core/types/ut_output_reporter_base.tpb index f6bb27b94..48970be5a 100644 --- a/source/core/types/ut_output_reporter_base.tpb +++ b/source/core/types/ut_output_reporter_base.tpb @@ -41,13 +41,6 @@ create or replace type body ut_output_reporter_base is return l_result; end; - overriding member procedure before_calling_run(self in out nocopy ut_output_reporter_base, a_run in ut_run) is - l_output_table_buffer ut_output_table_buffer; - begin - (self as ut_reporter_base).before_calling_run(a_run); - l_output_table_buffer := treat(self.output_buffer as ut_output_table_buffer); - end; - member procedure print_text(self in out nocopy ut_output_reporter_base, a_text varchar2, a_item_type varchar2 := null) is begin self.output_buffer.send_line(a_text, a_item_type); @@ -87,6 +80,7 @@ create or replace type body ut_output_reporter_base is overriding member procedure on_initialize(self in out nocopy ut_output_reporter_base, a_run in ut_run) is begin + self.output_buffer.lock_buffer(); self.output_buffer.send_line(null, 'initialize'); end; diff --git a/source/core/types/ut_output_reporter_base.tps b/source/core/types/ut_output_reporter_base.tps index 22f507f8d..21eed9957 100644 --- a/source/core/types/ut_output_reporter_base.tps +++ b/source/core/types/ut_output_reporter_base.tps @@ -20,8 +20,7 @@ create or replace type ut_output_reporter_base under ut_reporter_base( member procedure init(self in out nocopy ut_output_reporter_base, a_self_type varchar2, a_output_buffer ut_output_buffer_base := null), overriding member procedure set_reporter_id(self in out nocopy ut_output_reporter_base, a_reporter_id raw), member function set_reporter_id(self in ut_output_reporter_base, a_reporter_id raw) return ut_output_reporter_base, - overriding member procedure before_calling_run(self in out nocopy ut_output_reporter_base, a_run in ut_run), - + member procedure print_text(self in out nocopy ut_output_reporter_base, a_text varchar2, a_item_type varchar2 := null), member procedure print_text_lines(self in out nocopy ut_output_reporter_base, a_text_lines ut_varchar2_rows, a_item_type varchar2 := null), member procedure print_clob(self in out nocopy ut_output_reporter_base, a_clob clob, a_item_type varchar2 := null), diff --git a/source/create_utplsql_owner.sql b/source/create_utplsql_owner.sql index 64bcb52ce..d7e4f3040 100644 --- a/source/create_utplsql_owner.sql +++ b/source/create_utplsql_owner.sql @@ -31,15 +31,7 @@ create user &ut3_owner_schema identified by "&ut3_password" default tablespace & grant create session, create sequence, create procedure, create type, create table, create view, create synonym to &ut3_owner_schema; -begin - $if dbms_db_version.version < 18 $then - execute immediate 'grant execute on dbms_lock to &ut3_owner_schema'; - $else - null; - $end -end; -/ - +grant execute on dbms_lock to &ut3_owner_schema; grant execute on dbms_crypto to &ut3_owner_schema; grant execute on dbms_lob to &ut3_owner_schema; grant execute on dbms_xmlgen to &ut3_owner_schema; diff --git a/test/ut3_tester/core/test_output_buffer.pkb b/test/ut3_tester/core/test_output_buffer.pkb index 2e8b3337c..c5a4c07b1 100644 --- a/test/ut3_tester/core/test_output_buffer.pkb +++ b/test/ut3_tester/core/test_output_buffer.pkb @@ -16,12 +16,13 @@ create or replace package body test_output_buffer is || chr(13) || chr(10) || to_clob(lpad('a text', 31000, ',a text')) || to_clob(lpad('a text', 31000, ',a text')); l_expected_item_type := lpad('some item type',1000,'-'); --Act + l_buffer.lock_buffer(); l_buffer.send_clob(l_expected_text, l_expected_item_type); l_buffer.close(); select text, item_type into l_actual_text, l_actual_item_type - from table(l_buffer.get_lines(0,0)); + from table(l_buffer.get_lines(0.1,0.1)); --Assert ut.expect(l_actual_text).to_equal(l_expected_text); @@ -32,7 +33,14 @@ create or replace package body test_output_buffer is ut.expect(l_remaining).to_equal(0); end; - + + procedure test_wait_for_producer is + l_buffer ut3_develop.ut_output_buffer_base; + begin + l_buffer := ut3_develop.ut_output_clob_table_buffer(); + ut.expect( l_buffer.get_lines_cursor(0.1,0) ).to_be_empty(); + end; + procedure test_doesnt_send_on_null_text is l_cur sys_refcursor; l_result integer; @@ -86,11 +94,12 @@ create or replace package body test_output_buffer is begin --Arrange l_expected := 'a text'; + l_buffer.lock_buffer(); l_buffer.send_line(l_expected); l_start := localtimestamp; --Act begin - select text into l_result from table(l_buffer.get_lines(1,1)); + select text into l_result from table(l_buffer.get_lines(0,0.3)); ut.fail('Expected a timeout exception but nothing was raised'); exception when others then @@ -101,7 +110,7 @@ create or replace package body test_output_buffer is --Throws a timeout exception ut.expect(dbms_utility.format_error_stack()).to_match('ORA'||ut3_develop.ut_utils.gc_out_buffer_timeout); --Waited for one second - ut.expect(l_duration).to_be_greater_than(interval '0.99' second); + ut.expect(l_duration).to_be_greater_or_equal(interval '0.3' second); end; select count(1) into l_remaining from table(ut3_tester_helper.run_helper.ut_output_buffer_tmp) where output_id = l_buffer.output_id; @@ -116,13 +125,15 @@ create or replace package body test_output_buffer is l_buffer ut3_develop.ut_output_buffer_base; begin --Arrange - l_stale_buffer.start_date := sysdate - 2; + l_stale_buffer.start_date := sysdate - 10; --initialize with new start date l_stale_buffer.init(); + l_stale_buffer.lock_buffer(); l_stale_buffer.send_line('some text'); l_stale_buffer.close(); l_fresh_buffer := ut3_develop.ut_output_table_buffer(); + l_fresh_buffer.lock_buffer(); l_fresh_buffer.send_line('some text'); l_fresh_buffer.close(); @@ -131,9 +142,9 @@ create or replace package body test_output_buffer is --Assert -- Data in "fresh" buffer remains - ut.expect( l_fresh_buffer.get_lines_cursor(0,0), l_buffer.self_type ).to_have_count(1); + ut.expect( l_fresh_buffer.get_lines_cursor(0,0), l_fresh_buffer.self_type ).to_have_count(1); -- Data in "stale" buffer is purged and so the call to get_lines_cursor throws ORA-20218 - ut.expect( l_stale_buffer.get_lines_cursor(0,0), l_buffer.self_type ).to_be_empty(); + ut.expect( l_stale_buffer.get_lines_cursor(0,0), l_stale_buffer.self_type ).to_be_empty(); end; procedure test_purge_text_buffer is diff --git a/test/ut3_tester/core/test_output_buffer.pks b/test/ut3_tester/core/test_output_buffer.pks index 24c2c01eb..feaa337f8 100644 --- a/test/ut3_tester/core/test_output_buffer.pks +++ b/test/ut3_tester/core/test_output_buffer.pks @@ -2,10 +2,33 @@ create or replace package test_output_buffer is --%suite(output_buffer) --%suitepath(utplsql.ut3_tester.core) + + + --%context(Read and write within the same session) + + + --%endcontext + --%context(Buffer is read in a different session than buffer write) + + --reader will wait for a_initial_timeout seconds for the writer process to start and then it will finish with error + + --reader will wait forever (beyond a_initial_timeout) if the writer process is started and end of data row was not received from the buffer + + --reader stops after reading the end of data signal from the buffer + + --reader stops when writer process ends and all data was read from the buffer + + + --%endcontext + --%test(Receives a line from buffer table and deletes) procedure test_receive; + --%test(Waits specified time for producer to lock the buffer ) + --%throws(-20218) + procedure test_wait_for_producer; + --%test(Does not send line if null text given) procedure test_doesnt_send_on_null_text; @@ -19,11 +42,9 @@ create or replace package test_output_buffer is procedure test_waiting_for_data; --%test(Purges text buffer data older than one day and leaves the rest) - --%throws(-20218) procedure test_purge_text_buffer; --%test(Purges clob buffer data older than one day and leaves the rest) - --%throws(-20218) procedure test_purge_clob_buffer; end test_output_buffer; diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 99f26e9f8..3823d9d0c 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -305,15 +305,6 @@ create or replace package body coverage_helper is return l_status; end; - procedure sleep(a_time number) is - begin - $if dbms_db_version.version >= 18 $then - dbms_session.sleep(a_time); - $else - dbms_lock.sleep(a_time ); - $end - end; - procedure run_job_and_wait_for_finish(a_job_action varchar2) is l_status varchar2(1000); l_job_name varchar2(30); @@ -323,7 +314,7 @@ create or replace package body coverage_helper is begin g_job_no := g_job_no + 1; l_job_name := 'utPLSQL_selftest_job_'||g_job_no; - sleep(0.15); + dbms_lock.sleep(0.15); dbms_scheduler.create_job( job_name => l_job_name, job_type => 'PLSQL_BLOCK', @@ -333,13 +324,13 @@ create or replace package body coverage_helper is auto_drop => TRUE, comments => 'one-time-job' ); - while (l_status is null or l_status not in ('SUCCEEDED','FAILED')) and i < 150 loop + while (l_status is null or l_status not in ('SUCCEEDED','FAILED')) and i < 300 loop l_status := get_job_status( l_job_name, l_timestamp ); - sleep(0.1); + dbms_lock.sleep(0.1); i := i + 1; end loop; commit; - if l_status = 'FAILED' then + if nvl(l_status,'null') <> 'SUCCEEDED' then raise_application_error(-20000, 'Running a scheduler job failed'); end if; end; @@ -378,7 +369,7 @@ create or replace package body coverage_helper is pragma autonomous_transaction; begin run_job_and_wait_for_finish( a_plsql_block ); - + dbms_lock.sleep(0.1); execute immediate q'[ declare l_results ut3_develop.ut_varchar2_list; From a64bd1428499ad207571cd93fcdda78d661d6d92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 9 Feb 2023 16:34:53 +0000 Subject: [PATCH 393/887] Update RunExampleTestSuiteWithCompositeReporter.sql --- .../RunExampleTestSuiteWithCompositeReporter.sql | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/developer_examples/RunExampleTestSuiteWithCompositeReporter.sql b/examples/developer_examples/RunExampleTestSuiteWithCompositeReporter.sql index 468d176ed..e713fa02d 100644 --- a/examples/developer_examples/RunExampleTestSuiteWithCompositeReporter.sql +++ b/examples/developer_examples/RunExampleTestSuiteWithCompositeReporter.sql @@ -20,6 +20,7 @@ begin ut_event_manager.initialize(); ut_event_manager.add_listener(l_doc_reporter); ut_event_manager.add_listener(l_tc_reporter); + ut_event_manager.trigger_event(ut_event_manager.gc_initialize, l_run); l_suite := ut_suite(user, 'ut_exampletest',a_line_no=>1); l_suite.description := 'Test Suite Name'; From c1d5ab6c24cb94af1cc22877d31c4b4c13037822 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 10 Feb 2023 01:31:44 +0200 Subject: [PATCH 394/887] Extended schediler job timeout to 10 minutes to allow for slow execution on older DB versions. We should investigate to see why execution is so slow on 11.2 and 12.1 --- test/ut3_tester_helper/coverage_helper.pkb | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 3823d9d0c..2a508ca6a 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -290,11 +290,11 @@ create or replace package body coverage_helper is ut3_develop.ut_runner.coverage_stop(); end; - function get_job_status(a_job_name varchar2, a_job_started_after timestamp with time zone) return varchar2 is - l_status varchar2(1000); + function get_job_status(a_job_name varchar2, a_job_started_after timestamp with time zone) return user_scheduler_job_run_details%rowtype is + l_result user_scheduler_job_run_details%rowtype; begin begin - select status into l_status + select * into l_result from user_scheduler_job_run_details where job_name = upper(a_job_name) and req_start_date >= a_job_started_after; @@ -302,11 +302,11 @@ create or replace package body coverage_helper is when no_data_found then null; end; - return l_status; + return l_result; end; procedure run_job_and_wait_for_finish(a_job_action varchar2) is - l_status varchar2(1000); + l_job_run_info user_scheduler_job_run_details%rowtype; l_job_name varchar2(30); l_timestamp timestamp with time zone := current_timestamp; i integer := 0; @@ -324,14 +324,14 @@ create or replace package body coverage_helper is auto_drop => TRUE, comments => 'one-time-job' ); - while (l_status is null or l_status not in ('SUCCEEDED','FAILED')) and i < 300 loop - l_status := get_job_status( l_job_name, l_timestamp ); + while (l_job_run_info.status is null or l_job_run_info.status not in ('SUCCEEDED','FAILED')) and i < 6000 loop + l_job_run_info := get_job_status( l_job_name, l_timestamp ); dbms_lock.sleep(0.1); i := i + 1; end loop; commit; - if nvl(l_status,'null') <> 'SUCCEEDED' then - raise_application_error(-20000, 'Running a scheduler job failed'); + if nvl(l_job_run_info.status,'null') <> 'SUCCEEDED' then + raise_application_error(-20000, 'Scheduler job '''||l_job_name||''', status='''||l_job_run_info.status||'''. Additional info: '||l_job_run_info.additional_info); end if; end; From 99447ed877c9deea0f21cda59ca2f326ad2914be Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 10 Feb 2023 12:35:52 +0200 Subject: [PATCH 395/887] Improving performance of output buffer processing. --- .../core/output_buffers/ut_output_buffer_base.tpb | 12 ++++++++---- .../core/output_buffers/ut_output_table_buffer.tpb | 14 ++++++++++++++ .../core/output_buffers/ut_output_table_buffer.tps | 1 + 3 files changed, 23 insertions(+), 4 deletions(-) diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index c3a137b42..c9cffe339 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -179,10 +179,14 @@ create or replace type body ut_output_buffer_base is loop fetch l_data into l_clob, l_item_type; exit when l_data%notfound; - l_lines := ut_utils.clob_to_table(l_clob); - for i in 1 .. l_lines.count loop - dbms_output.put_line(l_lines(i)); - end loop; + if dbms_lob.getlength(l_clob) > 32767 then + l_lines := ut_utils.clob_to_table(l_clob); + for i in 1 .. l_lines.count loop + dbms_output.put_line(l_lines(i)); + end loop; + else + dbms_output.put_line(l_clob); + end if; end loop; close l_data; end; diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index 189baf075..599b56846 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -73,6 +73,20 @@ create or replace type body ut_output_table_buffer is end if; end; + overriding member procedure lines_to_dbms_output(self in ut_output_table_buffer, a_initial_timeout number := null, a_timeout_sec number := null) is + l_data sys_refcursor; + l_text varchar2(32767); + l_item_type varchar2(32767); + begin + l_data := self.get_lines_cursor(a_initial_timeout, a_timeout_sec); + loop + fetch l_data into l_text, l_item_type; + exit when l_data%notfound; + dbms_output.put_line(l_text); + end loop; + close l_data; + end; + overriding member procedure get_data_from_buffer_table( self in ut_output_table_buffer, a_last_read_message_id in out nocopy integer, diff --git a/source/core/output_buffers/ut_output_table_buffer.tps b/source/core/output_buffers/ut_output_table_buffer.tps index 721e5eb8a..b7ef8a3e7 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tps +++ b/source/core/output_buffers/ut_output_table_buffer.tps @@ -20,6 +20,7 @@ create or replace type ut_output_table_buffer under ut_output_buffer_base ( overriding member procedure send_line(self in out nocopy ut_output_table_buffer, a_text varchar2, a_item_type varchar2 := null), overriding member procedure send_lines(self in out nocopy ut_output_table_buffer, a_text_list ut_varchar2_rows, a_item_type varchar2 := null), overriding member procedure send_clob(self in out nocopy ut_output_table_buffer, a_text clob, a_item_type varchar2 := null), + overriding member procedure lines_to_dbms_output(self in ut_output_table_buffer, a_initial_timeout number := null, a_timeout_sec number := null), overriding member procedure get_data_from_buffer_table( self in ut_output_table_buffer, a_last_read_message_id in out nocopy integer, From 07f79e29e65e73e38c9219b3188c66f13acb02b4 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 10 Feb 2023 18:59:22 +0200 Subject: [PATCH 396/887] Fixed performance issues introduced with previous refactoring. --- .../output_buffers/ut_output_buffer_base.tpb | 129 ++++++------------ .../output_buffers/ut_output_buffer_base.tps | 13 +- .../ut_output_clob_table_buffer.tpb | 106 ++++++++++---- .../ut_output_clob_table_buffer.tps | 9 +- .../output_buffers/ut_output_table_buffer.tpb | 69 ++++++++-- .../output_buffers/ut_output_table_buffer.tps | 9 +- 6 files changed, 183 insertions(+), 152 deletions(-) diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index c9cffe339..be4c92bd8 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -64,100 +64,51 @@ create or replace type body ut_output_buffer_base is commit; end; - member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined is - lc_init_wait_sec constant number := coalesce(a_initial_timeout, 10 ); - lc_100_milisec constant number(1,1) := 0.1; --sleep for 100 ms between checks - lc_500_milisec constant number(3,1) := 0.5; --sleep for 1 s when waiting long - lc_1_second constant number(3,1) := 1; - l_buffer_rowids ut_varchar2_rows; - l_buffer_data ut_output_data_rows; - l_finished_flags ut_integer_list; - l_last_read_message_id integer; - l_already_waited_sec number(10,2) := 0; - l_data_finished boolean := false; - l_finished boolean := false; - l_sleep_time number(2,1) := lc_100_milisec; - l_lock_status integer; - l_producer_started boolean := false; - l_producer_finished boolean := false; - function get_lock_status return integer is - l_result integer; - l_release_status integer; - begin - l_result := dbms_lock.request( self.lock_handle, dbms_lock.s_mode, 0, false ); - if l_result = 0 then - l_release_status := dbms_lock.release( self.lock_handle ); - end if; - return l_result; - end; + member function timeout_producer_not_started( a_producer_started boolean, a_already_waited_sec number, a_init_wait_sec number ) return boolean + is + l_result boolean := false; begin - while not l_finished loop - - --check if the lock is still there on output - if yes, the main session is still running and so don't stop - l_lock_status := get_lock_status(); - get_data_from_buffer_table( l_last_read_message_id, l_buffer_data, l_buffer_rowids, l_finished_flags ); - - --nothing fetched from output, wait and try again - if l_buffer_data.count = 0 then - - dbms_lock.sleep(l_sleep_time); - l_already_waited_sec := l_already_waited_sec + l_sleep_time; - - -- if waited more than lc_1_second seconds then increase wait period to minimize the CPU usage. - if l_already_waited_sec >= lc_1_second then - l_sleep_time := lc_500_milisec; - end if; - + if not a_producer_started and a_already_waited_sec >= a_init_wait_sec then + if a_init_wait_sec > 0 then + self.remove_buffer_info(); + raise_application_error( + ut_utils.gc_out_buffer_timeout, + 'Timeout occurred while waiting for report data producer to start. Waited for: '||ut_utils.to_string( a_already_waited_sec )||' seconds.' + ); else - - l_already_waited_sec := 0; - l_sleep_time := lc_100_milisec; - - for i in 1 .. l_buffer_data.count loop - if l_buffer_data(i).text is not null then - pipe row( l_buffer_data(i) ); - elsif l_finished_flags(i) = 1 then - l_data_finished := true; - exit; - end if; - end loop; - - remove_read_data(l_buffer_rowids); - + l_result := true; end if; - l_producer_started := (l_lock_status <> 0 or l_buffer_data.count > 0) or l_producer_started; - l_producer_finished := (l_producer_started and l_lock_status = 0 and l_buffer_data.count = 0) or l_producer_finished; - - if not l_producer_started and l_already_waited_sec >= lc_init_wait_sec then - - if lc_init_wait_sec > 0 then - self.remove_buffer_info(); - raise_application_error( - ut_utils.gc_out_buffer_timeout, - 'Timeout occurred while waiting for report data producer to start. Waited for: '||ut_utils.to_string( l_already_waited_sec )||' seconds.' - ); - else - l_finished := true; - end if; - - elsif not l_producer_finished and a_timeout_sec is not null and l_already_waited_sec >= a_timeout_sec then - - if a_timeout_sec > 0 then - self.remove_buffer_info(); - raise_application_error( - ut_utils.gc_out_buffer_timeout, - 'Timeout occurred while waiting for more data from producer. Waited for: '||ut_utils.to_string( l_already_waited_sec )||' seconds.' - ); - else - l_finished := true; - end if; + end if; + return l_result; + end; - elsif (l_data_finished or l_producer_finished) then - l_finished := true; + member function timeout_producer_not_finished(a_producer_finished boolean, a_already_waited_sec number, a_timeout_sec number) return boolean + is + l_result boolean := false; + begin + if not a_producer_finished and a_timeout_sec is not null and a_already_waited_sec >= a_timeout_sec then + if a_timeout_sec > 0 then + self.remove_buffer_info(); + raise_application_error( + ut_utils.gc_out_buffer_timeout, + 'Timeout occurred while waiting for more data from producer. Waited for: '||ut_utils.to_string( a_already_waited_sec )||' seconds.' + ); + else + l_result := true; end if; - end loop; - self.remove_buffer_info(); - return; + end if; + return l_result; + end; + + member function get_lock_status return integer is + l_result integer; + l_release_status integer; + begin + l_result := dbms_lock.request( self.lock_handle, dbms_lock.s_mode, 0, false ); + if l_result = 0 then + l_release_status := dbms_lock.release( self.lock_handle ); + end if; + return l_result; end; member function get_lines_cursor(a_initial_timeout number := null, a_timeout_sec number := null) return sys_refcursor is diff --git a/source/core/output_buffers/ut_output_buffer_base.tps b/source/core/output_buffers/ut_output_buffer_base.tps index 8000ea2e7..53be365ae 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tps +++ b/source/core/output_buffers/ut_output_buffer_base.tps @@ -24,22 +24,17 @@ create or replace type ut_output_buffer_base force authid definer as object( self_type varchar2(250 byte), member procedure init(self in out nocopy ut_output_buffer_base, a_output_id raw := null, a_self_type varchar2 := null), member procedure lock_buffer(a_timeout_sec number := null), + member function timeout_producer_not_started( a_producer_started boolean, a_already_waited_sec number, a_init_wait_sec number ) return boolean, + member function timeout_producer_not_finished(a_producer_finished boolean, a_already_waited_sec number, a_timeout_sec number) return boolean, + member function get_lock_status return integer, member function get_lines_cursor(a_initial_timeout number := null, a_timeout_sec number := null) return sys_refcursor, member procedure lines_to_dbms_output(self in ut_output_buffer_base, a_initial_timeout number := null, a_timeout_sec number := null), member procedure cleanup_buffer(self in ut_output_buffer_base, a_retention_time_sec natural := null), member procedure remove_buffer_info(self in ut_output_buffer_base), - not instantiable member procedure get_data_from_buffer_table( - self in ut_output_buffer_base, - a_last_read_message_id in out nocopy integer, - a_buffer_data out nocopy ut_output_data_rows, - a_buffer_rowids out nocopy ut_varchar2_rows, - a_finished_flags out nocopy ut_integer_list - ), member procedure close(self in out nocopy ut_output_buffer_base), - not instantiable member procedure remove_read_data(self in ut_output_buffer_base, a_buffer_rowids ut_varchar2_rows), not instantiable member procedure send_line(self in out nocopy ut_output_buffer_base, a_text varchar2, a_item_type varchar2 := null), not instantiable member procedure send_lines(self in out nocopy ut_output_buffer_base, a_text_list ut_varchar2_rows, a_item_type varchar2 := null), not instantiable member procedure send_clob(self in out nocopy ut_output_buffer_base, a_text clob, a_item_type varchar2 := null), - member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined + not instantiable member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined ) not final not instantiable / diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index e47f0bcb0..c4cfdb059 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -55,36 +55,86 @@ create or replace type body ut_output_clob_table_buffer is commit; end; - overriding member procedure get_data_from_buffer_table( - self in ut_output_clob_table_buffer, - a_last_read_message_id in out nocopy integer, - a_buffer_data out nocopy ut_output_data_rows, - a_buffer_rowids out nocopy ut_varchar2_rows, - a_finished_flags out nocopy ut_integer_list - ) is - lc_bulk_limit constant integer := 5000; - begin - a_last_read_message_id := coalesce(a_last_read_message_id, 0); - with ordered_buffer as ( - select /*+ no_parallel index(a) */ ut_output_data_row(a.text, a.item_type), rowidtochar(a.rowid), is_finished - from ut_output_clob_buffer_tmp a - where a.output_id = self.output_id - and a.message_id <= a_last_read_message_id + lc_bulk_limit - order by a.message_id - ) - select /*+ no_parallel */ b.* - bulk collect into a_buffer_data, a_buffer_rowids, a_finished_flags - from ordered_buffer b; - a_last_read_message_id := a_last_read_message_id + a_finished_flags.count; - end; + overriding member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined is + lc_init_wait_sec constant number := coalesce(a_initial_timeout, 10 ); + l_buffer_rowids ut_varchar2_rows; + l_buffer_data ut_output_data_rows; + l_finished_flags ut_integer_list; + l_last_read_message_id integer; + l_already_waited_sec number(10,2) := 0; + l_finished boolean := false; + l_sleep_time number(2,1); + l_lock_status integer; + l_producer_started boolean := false; + l_producer_finished boolean := false; + procedure get_data_from_buffer_table( + a_last_read_message_id in out nocopy integer, + a_buffer_data out nocopy ut_output_data_rows, + a_buffer_rowids out nocopy ut_varchar2_rows, + a_finished_flags out nocopy ut_integer_list + ) is + lc_bulk_limit constant integer := 5000; + begin + a_last_read_message_id := coalesce(a_last_read_message_id, 0); + with ordered_buffer as ( + select /*+ no_parallel index(a) */ ut_output_data_row(a.text, a.item_type), rowidtochar(a.rowid), is_finished + from ut_output_clob_buffer_tmp a + where a.output_id = self.output_id + and a.message_id <= a_last_read_message_id + lc_bulk_limit + order by a.message_id + ) + select /*+ no_parallel */ b.* + bulk collect into a_buffer_data, a_buffer_rowids, a_finished_flags + from ordered_buffer b; + a_last_read_message_id := a_last_read_message_id + a_finished_flags.count; + end; + + procedure remove_read_data(a_buffer_rowids ut_varchar2_rows) is + pragma autonomous_transaction; + begin + forall i in 1 .. a_buffer_rowids.count + delete from ut_output_clob_buffer_tmp a + where rowid = chartorowid(a_buffer_rowids(i)); + commit; + end; - overriding member procedure remove_read_data(self in ut_output_clob_table_buffer, a_buffer_rowids ut_varchar2_rows) is - pragma autonomous_transaction; begin - forall i in 1 .. a_buffer_rowids.count - delete from ut_output_clob_buffer_tmp a - where rowid = chartorowid(a_buffer_rowids(i)); - commit; + while not l_finished loop + + l_sleep_time := case when l_already_waited_sec >= 1 then 0.5 else 0.1 end; + l_lock_status := self.get_lock_status(); + get_data_from_buffer_table( l_last_read_message_id, l_buffer_data, l_buffer_rowids, l_finished_flags ); + + if l_buffer_data.count > 0 then + l_already_waited_sec := 0; + for i in 1 .. l_buffer_data.count loop + if l_buffer_data(i).text is not null then + pipe row( l_buffer_data(i) ); + elsif l_finished_flags(i) = 1 then + l_finished := true; + exit; + end if; + end loop; + remove_read_data(l_buffer_rowids); + else + --nothing fetched from output, wait. + dbms_lock.sleep(l_sleep_time); + l_already_waited_sec := l_already_waited_sec + l_sleep_time; + end if; + + l_producer_started := (l_lock_status <> 0 or l_buffer_data.count > 0) or l_producer_started; + l_producer_finished := (l_producer_started and l_lock_status = 0 and l_buffer_data.count = 0) or l_producer_finished; + + l_finished := + self.timeout_producer_not_finished(l_producer_finished, l_already_waited_sec, a_timeout_sec) + or self.timeout_producer_not_started(l_producer_started, l_already_waited_sec, lc_init_wait_sec) + or l_producer_finished + or l_finished; + + end loop; + + self.remove_buffer_info(); + return; end; end; diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tps b/source/core/output_buffers/ut_output_clob_table_buffer.tps index ccd710a8f..191e64c01 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tps +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tps @@ -20,13 +20,6 @@ create or replace type ut_output_clob_table_buffer under ut_output_buffer_base ( overriding member procedure send_line(self in out nocopy ut_output_clob_table_buffer, a_text varchar2, a_item_type varchar2 := null), overriding member procedure send_lines(self in out nocopy ut_output_clob_table_buffer, a_text_list ut_varchar2_rows, a_item_type varchar2 := null), overriding member procedure send_clob(self in out nocopy ut_output_clob_table_buffer, a_text clob, a_item_type varchar2 := null), - overriding member procedure get_data_from_buffer_table( - self in ut_output_clob_table_buffer, - a_last_read_message_id in out nocopy integer, - a_buffer_data out nocopy ut_output_data_rows, - a_buffer_rowids out nocopy ut_varchar2_rows, - a_finished_flags out nocopy ut_integer_list - ), - overriding member procedure remove_read_data(self in ut_output_clob_table_buffer, a_buffer_rowids ut_varchar2_rows) + overriding member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined ) not final / diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index 599b56846..f38363e49 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -87,12 +87,29 @@ create or replace type body ut_output_table_buffer is close l_data; end; - overriding member procedure get_data_from_buffer_table( - self in ut_output_table_buffer, + /* Important note. + This function code is almost duplicated between two types for performance reasons. + The pipe row clause is much faster on VARCHAR2 then it is on clob. + That is the key reason for two implementations. + */ + overriding member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined is + lc_init_wait_sec constant number := coalesce(a_initial_timeout, 10 ); + l_buffer_texts ut_varchar2_rows; + l_buffer_item_types ut_varchar2_rows; + l_finished_flags ut_integer_list; + l_last_read_message_id integer; + l_already_waited_sec number(10,2) := 0; + l_finished boolean := false; + l_sleep_time number(2,1); + l_lock_status integer; + l_producer_started boolean := false; + l_producer_finished boolean := false; + + procedure get_data_from_buffer_table( a_last_read_message_id in out nocopy integer, - a_buffer_data out nocopy ut_output_data_rows, - a_buffer_rowids out nocopy ut_varchar2_rows, - a_finished_flags out nocopy ut_integer_list + a_buffer_texts out nocopy ut_varchar2_rows, + a_buffer_item_types out nocopy ut_varchar2_rows, + a_finished_flags out nocopy ut_integer_list ) is lc_bulk_limit constant integer := 20000; pragma autonomous_transaction; @@ -105,15 +122,47 @@ create or replace type body ut_output_table_buffer is and o.message_id <= a_last_read_message_id + lc_bulk_limit order by o.message_id ) d - returning ut_output_data_row(d.text, d.item_type), d.is_finished - bulk collect into a_buffer_data, a_finished_flags; + returning d.text, d.item_type, d.is_finished + bulk collect into a_buffer_texts, a_buffer_item_types, a_finished_flags; a_last_read_message_id := a_last_read_message_id + a_finished_flags.count; commit; end; - - overriding member procedure remove_read_data(self in ut_output_table_buffer, a_buffer_rowids ut_varchar2_rows) is begin - null; + while not l_finished loop + + l_sleep_time := case when l_already_waited_sec >= 1 then 0.5 else 0.1 end; + l_lock_status := self.get_lock_status(); + get_data_from_buffer_table( l_last_read_message_id, l_buffer_texts, l_buffer_item_types, l_finished_flags ); + + if l_buffer_texts.count > 0 then + l_already_waited_sec := 0; + for i in 1 .. l_buffer_texts.count loop + if l_buffer_texts(i) is not null then + pipe row( ut_output_data_row(l_buffer_texts(i), l_buffer_item_types(i)) ); + elsif l_finished_flags(i) = 1 then + l_finished := true; + exit; + end if; + end loop; + else + --nothing fetched from output, wait. + dbms_lock.sleep(l_sleep_time); + l_already_waited_sec := l_already_waited_sec + l_sleep_time; + end if; + + l_producer_started := (l_lock_status <> 0 or l_buffer_texts.count > 0) or l_producer_started; + l_producer_finished := (l_producer_started and l_lock_status = 0 and l_buffer_texts.count = 0) or l_producer_finished; + + l_finished := + self.timeout_producer_not_finished(l_producer_finished, l_already_waited_sec, a_timeout_sec) + or self.timeout_producer_not_started(l_producer_started, l_already_waited_sec, lc_init_wait_sec) + or l_producer_finished + or l_finished; + + end loop; + + self.remove_buffer_info(); + return; end; end; diff --git a/source/core/output_buffers/ut_output_table_buffer.tps b/source/core/output_buffers/ut_output_table_buffer.tps index b7ef8a3e7..154ce4de6 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tps +++ b/source/core/output_buffers/ut_output_table_buffer.tps @@ -21,13 +21,6 @@ create or replace type ut_output_table_buffer under ut_output_buffer_base ( overriding member procedure send_lines(self in out nocopy ut_output_table_buffer, a_text_list ut_varchar2_rows, a_item_type varchar2 := null), overriding member procedure send_clob(self in out nocopy ut_output_table_buffer, a_text clob, a_item_type varchar2 := null), overriding member procedure lines_to_dbms_output(self in ut_output_table_buffer, a_initial_timeout number := null, a_timeout_sec number := null), - overriding member procedure get_data_from_buffer_table( - self in ut_output_table_buffer, - a_last_read_message_id in out nocopy integer, - a_buffer_data out nocopy ut_output_data_rows, - a_buffer_rowids out nocopy ut_varchar2_rows, - a_finished_flags out nocopy ut_integer_list - ), - overriding member procedure remove_read_data(self in ut_output_table_buffer, a_buffer_rowids ut_varchar2_rows) + overriding member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined ) not final / From 865785aa49c0258f9b1c1ad8291d07867300daf6 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Fri, 10 Feb 2023 19:18:31 +0200 Subject: [PATCH 397/887] Fixed failing test. --- development/refresh_sources.sh | 2 +- test/ut3_tester/core/test_output_buffer.pkb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/development/refresh_sources.sh b/development/refresh_sources.sh index b6ef51ef9..83518d7cc 100755 --- a/development/refresh_sources.sh +++ b/development/refresh_sources.sh @@ -12,7 +12,7 @@ git clone --depth=1 --branch=${SELFTESTING_BRANCH:-main} https://github.com/utPL rm -rf utPLSQL-cli/* # download latest release version of utPLSQL-cli -curl -Lk -o utPLSQL-cli.zip https://github.com/utPLSQL/utPLSQL-cli/releases/download/v${UTPLSQL_CLI_VERSION}/utPLSQL-cli.zip +curl -Lk -o utPLSQL-cli.zip https://github.com/utPLSQL/utPLSQL-cli/releases/download/${UTPLSQL_CLI_VERSION}/utPLSQL-cli.zip # unzip utPLSQL-cli and remove the zip file unzip utPLSQL-cli.zip && chmod u+x utPLSQL-cli/bin/utplsql && rm utPLSQL-cli.zip diff --git a/test/ut3_tester/core/test_output_buffer.pkb b/test/ut3_tester/core/test_output_buffer.pkb index c5a4c07b1..edb10e3e6 100644 --- a/test/ut3_tester/core/test_output_buffer.pkb +++ b/test/ut3_tester/core/test_output_buffer.pkb @@ -38,7 +38,7 @@ create or replace package body test_output_buffer is l_buffer ut3_develop.ut_output_buffer_base; begin l_buffer := ut3_develop.ut_output_clob_table_buffer(); - ut.expect( l_buffer.get_lines_cursor(0.1,0) ).to_be_empty(); + ut.expect( l_buffer.get_lines_cursor(0.1) ).to_be_empty(); end; procedure test_doesnt_send_on_null_text is From 33f5485645d074f6993402a4f11c8f350534dd43 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 11 Feb 2023 10:57:45 +0000 Subject: [PATCH 398/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index cd50c02bf..9bd1a10c6 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 52b771abc..727b513eb 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index c869cfa4f..5f4b1d57c 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index ec7316027..cd2f76d49 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 4a9108f8a..b029f6206 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index dc7d2f0ad..7a2f511aa 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 87ede5b5f..0e3b6446e 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 905a27acb..d41641303 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 5e9331e6b..5e1c4cbdb 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 0da0f5178..8c986cb87 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0655700af..c116464de 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index a6948f9d7..4427f2f10 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 278bad788..7af30194d 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 8cb47b973..68c689828 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3d0bf7d84..75bd4df3d 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 0ab199c08..07b192ce1 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 1a554dfc9..bb66e6e0e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4072--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 438abddd2..18a3d5952 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4072-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4085-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 28b6eaa53ec15e0fc11c8ff2531388d7e857c645 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sat, 11 Feb 2023 12:54:42 +0200 Subject: [PATCH 399/887] Small performance improvements to output buffer handling and some tests. --- source/api/ut.pkb | 12 +++++++++--- .../core/output_buffers/ut_output_table_buffer.tpb | 10 ++++++---- test/ut3_tester_helper/coverage_helper.pkb | 14 ++++++++++++++ 3 files changed, 29 insertions(+), 7 deletions(-) diff --git a/source/api/ut.pkb b/source/api/ut.pkb index 5c91e54d4..5e612efb4 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -222,10 +222,15 @@ create or replace package body ut is raise_if_packages_invalidated(); raise no_data_found; end if; - g_result_lines := ut_utils.clob_to_table(l_clob, ut_utils.gc_max_storage_varchar2_len); - g_result_line_no := g_result_lines.first; + if l_clob is not null and l_clob != empty_clob() then + if length(l_clob) > ut_utils.gc_max_storage_varchar2_len then + g_result_lines := ut_utils.clob_to_table(l_clob, ut_utils.gc_max_storage_varchar2_len); + else + g_result_lines := ut_varchar2_list(l_clob); + end if; + g_result_line_no := g_result_lines.first; + end if; end if; - if g_result_line_no is not null then l_result := g_result_lines(g_result_line_no); g_result_line_no := g_result_lines.next(g_result_line_no); @@ -274,6 +279,7 @@ create or replace package body ut is if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); loop + g_result_lines := ut_varchar2_list(); pipe row( get_report_outputs( l_results ) ); end loop; end if; diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index f38363e49..480ae9144 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -75,14 +75,16 @@ create or replace type body ut_output_table_buffer is overriding member procedure lines_to_dbms_output(self in ut_output_table_buffer, a_initial_timeout number := null, a_timeout_sec number := null) is l_data sys_refcursor; - l_text varchar2(32767); - l_item_type varchar2(32767); + l_text ut_varchar2_rows; + l_item_type ut_varchar2_rows; begin l_data := self.get_lines_cursor(a_initial_timeout, a_timeout_sec); loop - fetch l_data into l_text, l_item_type; + fetch l_data bulk collect into l_text, l_item_type limit 10000; + for idx in 1 .. l_text.count loop + dbms_output.put_line(l_text(idx)); + end loop; exit when l_data%notfound; - dbms_output.put_line(l_text); end loop; close l_data; end; diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index 2a508ca6a..d234967e4 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -489,16 +489,30 @@ create or replace package body coverage_helper is l_coverage_id raw(32) := sys_guid(); begin l_plsql_block := q'[ + declare + x dbms_output.chararr; + i integer := 100000; begin + execute immediate 'alter session set statistics_level=all'; +/* + dbms_hprof.start_profiling( + location => 'PLSHPROF_DIR' + , filename => 'profiler_utPLSQL_run_]'||rawtohex(l_coverage_id)||q'[.txt' + ); +*/ ut3_develop.ut_runner.coverage_start(']'||rawtohex(l_coverage_id)||q'['); ut3_develop.ut_coverage.set_develop_mode(a_develop_mode => true); --gather coverage on the command executed begin {a_run_command}; end; + dbms_output.get_lines(x,i); ut3_develop.ut_coverage.set_develop_mode(a_develop_mode => false); ut3_develop.ut_runner.coverage_stop(); --get the actual results of the command gathering the coverage insert into test_results select rownum as id, x.* from table( {a_run_command} ) x; commit; +/* + dbms_hprof.stop_profiling; +*/ end;]'; l_plsql_block := replace(l_plsql_block,'{a_run_command}',a_run_command); l_result_clob := run_code_as_job( l_plsql_block ); From 3a837f4ccf5021fbbb8d2a269653226601ca535d Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 14 Mar 2023 23:10:15 -0700 Subject: [PATCH 400/887] Address issue where the not_to(contain) executes a negated matcher without negated flag set causing refcursor compare sql generated inclusion comparision. --- source/expectations/matchers/ut_contain.tpb | 1 + source/expectations/ut_expectation.tpb | 4 +- .../expectations/test_expectations_cursor.pkb | 100 +++++++++++++++++- .../expectations/test_expectations_cursor.pks | 22 +++- 4 files changed, 122 insertions(+), 5 deletions(-) diff --git a/source/expectations/matchers/ut_contain.tpb b/source/expectations/matchers/ut_contain.tpb index 7591925f5..c9691f731 100644 --- a/source/expectations/matchers/ut_contain.tpb +++ b/source/expectations/matchers/ut_contain.tpb @@ -47,6 +47,7 @@ create or replace type body ut_contain as overriding member function run_matcher_negated(self in out nocopy ut_contain, a_actual ut_data_value) return boolean is begin + self.negated(); return run_matcher(a_actual); end; diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index a78c57eb7..309759d48 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -686,7 +686,7 @@ create or replace type body ut_expectation as member procedure not_to_contain(self in ut_expectation, a_expected sys_refcursor) is begin - self.not_to( ut_contain(a_expected).negated() ); + self.not_to( ut_contain(a_expected)); end; member procedure to_contain(self in ut_expectation, a_expected anydata) is @@ -696,7 +696,7 @@ create or replace type body ut_expectation as member procedure not_to_contain(self in ut_expectation, a_expected anydata) is begin - self.not_to( ut_contain(a_expected).negated() ); + self.not_to( ut_contain(a_expected)); end; member function to_be_within(a_dist number) return ut_be_within is diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index 952084fd3..7d0f308a8 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -2329,6 +2329,23 @@ Diff:% ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; + procedure cursor_not_to_contain2 + as + l_actual sys_refcursor; + l_expected sys_refcursor; + begin + open l_expected for select 'TEST' username, -600 user_id from dual; + + open l_actual for select username, user_id from all_users + union all + select 'TEST1' username, -601 user_id from dual; + + --Act + ut3_develop.ut.expect(l_actual).not_to(ut3_develop.contain(l_expected)); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + procedure cursor_not_to_contain_fail is l_actual sys_refcursor; l_expected sys_refcursor; @@ -2359,6 +2376,37 @@ Diff:% ut.expect(l_actual_message).to_be_like(l_expected_message); end; + + procedure cursor_not_to_contain_fail2 is + l_actual sys_refcursor; + l_expected sys_refcursor; + l_expected_message varchar2(32767); + l_actual_message varchar2(32767); + begin + --Arrange + open l_expected for select 'TEST' username, -600 user_id from dual; + + open l_actual for select username, user_id from all_users + union all + select 'TEST' username, -600 user_id from dual; + + --Act + ut3_develop.ut.expect(l_actual).not_to(ut3_develop.contain(l_expected)); + --Assert + l_expected_message := q'[%Actual: (refcursor [ count = % ])% +%Data-types:% +%VARCHAR2NUMBER% +%Data:% +%was expected not to contain:(refcursor [ count = 1 ])% +%Data-types:% +%CHARNUMBER% +%Data:% +%TEST-600%]'; + l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); + --Assert + ut.expect(l_actual_message).to_be_like(l_expected_message); + end; + procedure cursor_not_to_contain_joinby is l_actual sys_refcursor; l_expected sys_refcursor; @@ -2372,7 +2420,21 @@ Diff:% --Assert ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; - + + procedure cursor_not_to_contain_joinby2 is + l_actual sys_refcursor; + l_expected sys_refcursor; + begin + --Arrange + open l_actual for select username,rownum * 10 user_id from all_users where rownum < 5; + open l_expected for select username||to_char(rownum) username ,rownum user_id from all_users where rownum < 5; + + --Act + ut3_develop.ut.expect(l_actual).not_to(ut3_develop.contain(l_expected).join_by('USER_ID')); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + procedure not_cont_join_incl_cols_as_lst is l_actual sys_refcursor; l_expected sys_refcursor; @@ -2386,6 +2448,19 @@ Diff:% ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; + procedure not_cont_join_incl_cols_as_lst2 is + l_actual sys_refcursor; + l_expected sys_refcursor; + begin + --Arrange + open l_actual for select rownum as rn, 'b' as "A_Column", 'c' as A_COLUMN, 'x' SOME_COL, 'd' "Some_Col" from dual a connect by level < 10; + open l_expected for select rownum * 20 rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; + --Act + ut3_develop.ut.expect(l_actual).not_to(ut3_develop.contain(l_expected).include(ut3_develop.ut_varchar2_list('RN','//A_Column','SOME_COL')).join_by('RN')); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + procedure not_cont_join_excl_cols_as_lst is l_actual sys_refcursor; l_expected sys_refcursor; @@ -2399,6 +2474,19 @@ Diff:% ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; + procedure not_cont_join_excl_cols_as_lst2 is + l_actual sys_refcursor; + l_expected sys_refcursor; + begin + --Arrange + open l_actual for select rownum as rn, 'a' as "A_Column", 'c' as A_COLUMN, 'y' SOME_COL, 'd' "Some_Col" from dual a connect by level < 10; + open l_expected for select rownum * 20 as rn, 'a' as "A_Column", 'd' as A_COLUMN, 'x' SOME_COL, 'c' "Some_Col" from dual a connect by level < 4; + --Act + ut3_develop.ut.expect(l_actual).not_to(ut3_develop.contain(l_expected).exclude(ut3_develop.ut_varchar2_list('//Some_Col','A_COLUMN')).join_by('RN')); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + procedure to_contain_duplicates is l_actual sys_refcursor; l_expected sys_refcursor; @@ -2440,6 +2528,16 @@ Diff:% ut.expect(l_actual_message).to_be_like(l_expected_message); end; + procedure to_not_contain_fails_1245 is + c1 sys_refcursor; + c2 sys_refcursor; + begin + open c1 for select 'a' as letter from dual union all select 'b' from dual; + open c2 for select 'c' as letter from dual; + ut3_develop.ut.expect(c1).not_to(ut3_develop.contain(c2)); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + procedure udt_messg_format_eq is l_actual sys_refcursor; l_expected sys_refcursor; diff --git a/test/ut3_user/expectations/test_expectations_cursor.pks b/test/ut3_user/expectations/test_expectations_cursor.pks index 0ed249a49..e7a289247 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pks +++ b/test/ut3_user/expectations/test_expectations_cursor.pks @@ -376,24 +376,42 @@ create or replace package test_expectations_cursor is --%test( Cursor not to contains data from another cursor) procedure cursor_not_to_contain; + --%test( Cursor not_to[contain] data from another cursor) + procedure cursor_not_to_contain2; + --%test( Cursor fail not to contains data from another cursor) procedure cursor_not_to_contain_fail; - + + --%test( Cursor fail not_to[contain] data from another cursor) + procedure cursor_not_to_contain_fail2; + --%test( Cursor not contains data from another cursor with joinby clause) procedure cursor_not_to_contain_joinby; + --%test( Cursor not_to[contain] data from another cursor with joinby clause) + procedure cursor_not_to_contain_joinby2; + --%test(Cursor not contains data with of columns to include and join by value) procedure not_cont_join_incl_cols_as_lst; + --%test(Cursor not_to[contain] data with of columns to include and join by value) + procedure not_cont_join_incl_cols_as_lst2; + --%test(Cursor not contains data with of columns to exclude and join by value) procedure not_cont_join_excl_cols_as_lst; + --%test(Cursor not_to[contain] data with of columns to exclude and join by value) + procedure not_cont_join_excl_cols_as_lst2; + --%test(Cursor to contain duplicates) procedure to_contain_duplicates; --%test(Cursor to contain duplicates fail) procedure to_contain_duplicates_fail; - + + --%test(Cursor using not_to[contain] fails #1245) + procedure to_not_contain_fails_1245; + --%test(Display a message with a uer defined type with only type name not structure on equal) procedure udt_messg_format_eq; From 0707b2d8a8cb44b77abe327c46b596c7899bbb9a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 14 Mar 2023 23:19:56 -0700 Subject: [PATCH 401/887] Fixing when test name is longer than 30 char --- test/ut3_user/expectations/test_expectations_cursor.pkb | 4 ++-- test/ut3_user/expectations/test_expectations_cursor.pks | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index 7d0f308a8..847cce9a0 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -2448,7 +2448,7 @@ Diff:% ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; - procedure not_cont_join_incl_cols_as_lst2 is + procedure not_con_join_incl_cols_as_lst2 is l_actual sys_refcursor; l_expected sys_refcursor; begin @@ -2474,7 +2474,7 @@ Diff:% ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; - procedure not_cont_join_excl_cols_as_lst2 is + procedure not_con_join_excl_cols_as_lst2 is l_actual sys_refcursor; l_expected sys_refcursor; begin diff --git a/test/ut3_user/expectations/test_expectations_cursor.pks b/test/ut3_user/expectations/test_expectations_cursor.pks index e7a289247..0f34486a9 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pks +++ b/test/ut3_user/expectations/test_expectations_cursor.pks @@ -395,13 +395,13 @@ create or replace package test_expectations_cursor is procedure not_cont_join_incl_cols_as_lst; --%test(Cursor not_to[contain] data with of columns to include and join by value) - procedure not_cont_join_incl_cols_as_lst2; + procedure not_con_join_incl_cols_as_lst2; --%test(Cursor not contains data with of columns to exclude and join by value) procedure not_cont_join_excl_cols_as_lst; --%test(Cursor not_to[contain] data with of columns to exclude and join by value) - procedure not_cont_join_excl_cols_as_lst2; + procedure not_con_join_excl_cols_as_lst2; --%test(Cursor to contain duplicates) procedure to_contain_duplicates; From 8460a3092ac4f6781bf8f07f5a0d26d31ab6fa71 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 15 Mar 2023 00:24:05 -0700 Subject: [PATCH 402/887] Update test --- .../expectations/test_expectation_anydata.pkb | 19 ++++++++++++++++++- .../expectations/test_expectation_anydata.pks | 3 +++ 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index c56c31930..c70d41f9e 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -957,6 +957,23 @@ Rows: [ 60 differences, showing first 20 ] ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; + procedure collection_not_to_contain is + l_actual ut3_tester_helper.test_dummy_object_list; + l_expected ut3_tester_helper.test_dummy_object_list; + begin + --Arrange + select ut3_tester_helper.test_dummy_object( rownum, 'Something2 '||rownum, rownum+100) + bulk collect into l_actual + from dual connect by level <=4; + select ut3_tester_helper.test_dummy_object( rownum, 'Something '||rownum, rownum) + bulk collect into l_expected + from dual connect by level <=2 + order by rownum desc; + --Act + ut3_develop.ut.expect(anydata.convertCollection(l_actual)).not_to_contain(anydata.convertCollection(l_expected)); + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + end; + procedure object_to_contain is begin --Arrange @@ -967,7 +984,7 @@ Rows: [ 60 differences, showing first 20 ] ut3_develop.ut.expect(g_test_actual).to_contain(g_test_expected); ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; - + procedure arr_empty_eq_arr_empty_unord is begin --Arrange diff --git a/test/ut3_user/expectations/test_expectation_anydata.pks b/test/ut3_user/expectations/test_expectation_anydata.pks index 81dea74eb..54c246bd3 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pks +++ b/test/ut3_user/expectations/test_expectation_anydata.pks @@ -195,6 +195,9 @@ create or replace package test_expectation_anydata is --%test( Success when anydata collection contains data from another anydata collection) procedure collection_to_contain; + --%test( Success when anydata collection not contains data from another anydata collection) + procedure collection_not_to_contain; + --%test( Success when anydata object contains data from another anydata) procedure object_to_contain; From 7597905bfe41bc1b3580919e670d00e76bd62f3d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 19 Mar 2023 17:05:14 +0000 Subject: [PATCH 403/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 9bd1a10c6..d132d2085 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 727b513eb..21b82ee41 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 5f4b1d57c..9b423d5a8 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index cd2f76d49..d534857fa 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b029f6206..d6884ba2d 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7a2f511aa..2c31a9a89 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 0e3b6446e..d193e2c20 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index d41641303..63c0e36e9 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 5e1c4cbdb..f77717798 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 8c986cb87..e237bf4ef 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c116464de..8fa525a69 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 4427f2f10..d97d49464 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 7af30194d..934d07d72 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 68c689828..9e16fd3e8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 75bd4df3d..b3b0e338a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 07b192ce1..e8e431980 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index bb66e6e0e..47772937e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4085--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 18a3d5952..f92fbc2b0 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4085-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4094-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 521fe472bb634095a3a3081f5175933eec61d2aa Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 20 Mar 2023 00:20:15 +0200 Subject: [PATCH 404/887] Performance improvements in output buffer for reporters that only produce data after the whole run is finished. --- source/api/ut.pkb | 7 +- .../output_buffers/ut_output_bulk_buffer.tpb | 160 ++++++++++++++++++ .../output_buffers/ut_output_bulk_buffer.tps | 27 +++ source/core/ut_utils.pkb | 1 + source/install.sql | 2 + .../ut_coverage_cobertura_reporter.tpb | 2 +- .../reporters/ut_coverage_html_reporter.tpb | 2 +- .../reporters/ut_coverage_sonar_reporter.tpb | 9 +- source/reporters/ut_coveralls_reporter.tpb | 2 +- source/reporters/ut_junit_reporter.tpb | 2 +- source/reporters/ut_sonar_test_reporter.tpb | 2 +- source/reporters/ut_tfs_junit_reporter.tpb | 2 +- source/reporters/ut_xunit_reporter.tpb | 2 +- source/uninstall_objects.sql | 2 + test/ut3_tester_helper/coverage_helper.pkb | 2 +- 15 files changed, 214 insertions(+), 10 deletions(-) create mode 100644 source/core/output_buffers/ut_output_bulk_buffer.tpb create mode 100644 source/core/output_buffers/ut_output_bulk_buffer.tps diff --git a/source/api/ut.pkb b/source/api/ut.pkb index 5e612efb4..cff35b771 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -278,8 +278,8 @@ create or replace package body ut is ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); + g_result_lines := ut_varchar2_list(); loop - g_result_lines := ut_varchar2_list(); pipe row( get_report_outputs( l_results ) ); end loop; end if; @@ -326,6 +326,7 @@ create or replace package body ut is ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); + g_result_lines := ut_varchar2_list(); loop pipe row( get_report_outputs( l_results ) ); end loop; @@ -374,6 +375,7 @@ create or replace package body ut is ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); + g_result_lines := ut_varchar2_list(); loop pipe row( get_report_outputs( l_results ) ); end loop; @@ -422,6 +424,7 @@ create or replace package body ut is ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); + g_result_lines := ut_varchar2_list(); loop pipe row( get_report_outputs( l_results ) ); end loop; @@ -470,6 +473,7 @@ create or replace package body ut is ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); + g_result_lines := ut_varchar2_list(); loop pipe row( get_report_outputs( l_results ) ); end loop; @@ -518,6 +522,7 @@ create or replace package body ut is ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); + g_result_lines := ut_varchar2_list(); loop pipe row( get_report_outputs( l_results ) ); end loop; diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tpb b/source/core/output_buffers/ut_output_bulk_buffer.tpb new file mode 100644 index 000000000..49aa1e913 --- /dev/null +++ b/source/core/output_buffers/ut_output_bulk_buffer.tpb @@ -0,0 +1,160 @@ +create or replace type body ut_output_bulk_buffer is + /* + utPLSQL - Version 3 + Copyright 2016 - 2023 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + constructor function ut_output_bulk_buffer(self in out nocopy ut_output_bulk_buffer, a_output_id raw := null) return self as result is + begin + self.init(a_output_id, $$plsql_unit); + return; + end; + + overriding member procedure send_line(self in out nocopy ut_output_bulk_buffer, a_text varchar2, a_item_type varchar2 := null) is + pragma autonomous_transaction; + begin + if a_text is not null or a_item_type is not null then + if length(a_text) > ut_utils.gc_max_storage_varchar2_len then + self.send_lines( + ut_utils.convert_collection( + ut_utils.clob_to_table(a_text, ut_utils.gc_max_storage_varchar2_len) + ), + a_item_type + ); + else + self.last_write_message_id := self.last_write_message_id + 1; + insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) + values (self.output_id, self.last_write_message_id, a_text, a_item_type); + end if; + commit; + end if; + end; + + overriding member procedure send_lines(self in out nocopy ut_output_bulk_buffer, a_text_list ut_varchar2_rows, a_item_type varchar2 := null) is + pragma autonomous_transaction; + begin + insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) + select /*+ no_parallel */ self.output_id, self.last_write_message_id + rownum, t.column_value, a_item_type + from table(a_text_list) t + where t.column_value is not null or a_item_type is not null; + self.last_write_message_id := self.last_write_message_id + SQL%rowcount; + commit; + end; + + overriding member procedure send_clob(self in out nocopy ut_output_bulk_buffer, a_text clob, a_item_type varchar2 := null) is + pragma autonomous_transaction; + begin + if a_text is not null and a_text != empty_clob() or a_item_type is not null then + if length(a_text) > ut_utils.gc_max_storage_varchar2_len then + self.send_lines( + ut_utils.convert_collection( + ut_utils.clob_to_table(a_text, ut_utils.gc_max_storage_varchar2_len) + ), + a_item_type + ); + else + self.last_write_message_id := self.last_write_message_id + 1; + insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) + values (self.output_id, self.last_write_message_id, a_text, a_item_type); + end if; + commit; + end if; + end; + + overriding member procedure lines_to_dbms_output(self in ut_output_bulk_buffer, a_initial_timeout number := null, a_timeout_sec number := null) is + l_data sys_refcursor; + l_text ut_varchar2_rows; + l_item_type ut_varchar2_rows; + begin + l_data := self.get_lines_cursor(a_initial_timeout, a_timeout_sec); + loop + fetch l_data bulk collect into l_text, l_item_type limit 10000; + for idx in 1 .. l_text.count loop + dbms_output.put_line(l_text(idx)); + end loop; + exit when l_data%notfound; + end loop; + close l_data; + end; + + overriding member function get_lines_cursor(a_initial_timeout number := null, a_timeout_sec number := null) return sys_refcursor is + lc_init_wait_sec constant number := coalesce(a_initial_timeout, 30 ); + l_already_waited_sec number(10,2) := 0; + l_sleep_time number(2,1); + l_exists integer; + l_finished boolean := false; + l_data_produced boolean; + l_producer_active boolean := false; + l_producer_started boolean := false; + l_producer_finished boolean := false; + l_results sys_refcursor; + begin + + while not l_finished loop + + if not l_data_produced then + select /*+ no_parallel */ count(1) into l_exists + from ut_output_buffer_tmp o + where o.output_id = self.output_id and rownum = 1; + l_data_produced := (l_exists = 1); + end if; + + l_sleep_time := case when l_already_waited_sec >= 1 then 0.5 else 0.1 end; + l_producer_active := (self.get_lock_status() <> 0); + l_producer_started := (l_producer_active or l_data_produced ) or l_producer_started; + l_producer_finished := (l_producer_started and not l_producer_active) or l_producer_finished; + + l_finished := + self.timeout_producer_not_finished(l_producer_finished, l_already_waited_sec, a_timeout_sec) + or self.timeout_producer_not_started(l_producer_started, l_already_waited_sec, lc_init_wait_sec) + or l_producer_finished; + end loop; + + open l_results for + select /*+ no_parallel */ o.text, o.item_type + from ut_output_buffer_tmp o + where o.output_id = self.output_id + and o.text is not null + order by o.output_id, o.message_id; + + return l_results; + + end; + + /* Important note. + This function code is almost duplicated between two types for performance reasons. + The pipe row clause is much faster on VARCHAR2 then it is on clob. + That is the key reason for two implementations. + */ + overriding member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined is + l_data sys_refcursor; + l_text ut_varchar2_rows; + l_item_type ut_varchar2_rows; + begin + l_data := self.get_lines_cursor(a_initial_timeout, a_timeout_sec); + loop + fetch l_data bulk collect into l_text, l_item_type limit 10000; + for idx in 1 .. l_text.count loop + pipe row( ut_output_data_row(l_text(idx), l_item_type(idx)) ); + end loop; + exit when l_data%notfound; + end loop; + close l_data; + return; + self.remove_buffer_info(); + end; + +end; +/ diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tps b/source/core/output_buffers/ut_output_bulk_buffer.tps new file mode 100644 index 000000000..d74d4ee14 --- /dev/null +++ b/source/core/output_buffers/ut_output_bulk_buffer.tps @@ -0,0 +1,27 @@ +create or replace type ut_output_bulk_buffer under ut_output_buffer_base ( + /* + utPLSQL - Version 3 + Copyright 2016 - 2023 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + constructor function ut_output_bulk_buffer(self in out nocopy ut_output_bulk_buffer, a_output_id raw := null) return self as result, + overriding member procedure send_line(self in out nocopy ut_output_bulk_buffer, a_text varchar2, a_item_type varchar2 := null), + overriding member procedure send_lines(self in out nocopy ut_output_bulk_buffer, a_text_list ut_varchar2_rows, a_item_type varchar2 := null), + overriding member procedure send_clob(self in out nocopy ut_output_bulk_buffer, a_text clob, a_item_type varchar2 := null), + overriding member procedure lines_to_dbms_output(self in ut_output_bulk_buffer, a_initial_timeout number := null, a_timeout_sec number := null), + overriding member function get_lines_cursor(a_initial_timeout number := null, a_timeout_sec number := null) return sys_refcursor, + overriding member function get_lines(a_initial_timeout number := null, a_timeout_sec number := null) return ut_output_data_rows pipelined +) not final +/ diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 162e50f8f..5114cecad 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -570,6 +570,7 @@ create or replace package body ut_utils is end loop; exit when l_lines_data%notfound; end loop; + close l_lines_data; execute immediate 'truncate table ut_dbms_output_cache'; commit; end; diff --git a/source/install.sql b/source/install.sql index 6f3c16801..0873d6a1e 100644 --- a/source/install.sql +++ b/source/install.sql @@ -120,6 +120,8 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/output_buffers/ut_output_table_buffer.tpb' @@install_component.sql 'core/output_buffers/ut_output_clob_table_buffer.tps' @@install_component.sql 'core/output_buffers/ut_output_clob_table_buffer.tpb' +@@install_component.sql 'core/output_buffers/ut_output_bulk_buffer.tps' +@@install_component.sql 'core/output_buffers/ut_output_bulk_buffer.tpb' @@install_component.sql 'core/types/ut_output_reporter_base.tps' diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index 48082a6d4..50eb34631 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -20,7 +20,7 @@ create or replace type body ut_coverage_cobertura_reporter is self in out nocopy ut_coverage_cobertura_reporter ) return self as result is begin - self.init($$plsql_unit); + self.init($$plsql_unit,ut_output_bulk_buffer()); return; end; diff --git a/source/reporters/ut_coverage_html_reporter.tpb b/source/reporters/ut_coverage_html_reporter.tpb index c88c91a80..b1f9f6651 100644 --- a/source/reporters/ut_coverage_html_reporter.tpb +++ b/source/reporters/ut_coverage_html_reporter.tpb @@ -22,7 +22,7 @@ create or replace type body ut_coverage_html_reporter is a_html_report_assets_path varchar2 := null ) return self as result is begin - self.init($$plsql_unit); + self.init($$plsql_unit,ut_output_bulk_buffer()); self.project_name := a_project_name; assets_path := nvl(a_html_report_assets_path, ut_coverage_report_html_helper.get_default_html_assets_path()); return; diff --git a/source/reporters/ut_coverage_sonar_reporter.tpb b/source/reporters/ut_coverage_sonar_reporter.tpb index 8ee78dc24..1861a9be3 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tpb +++ b/source/reporters/ut_coverage_sonar_reporter.tpb @@ -20,7 +20,7 @@ create or replace type body ut_coverage_sonar_reporter is self in out nocopy ut_coverage_sonar_reporter ) return self as result is begin - self.init($$plsql_unit); + self.init($$plsql_unit,ut_output_bulk_buffer()); return; end; @@ -84,6 +84,12 @@ create or replace type body ut_coverage_sonar_reporter is end; begin +-- execute immediate 'alter session set statistics_level=all'; +-- dbms_hprof.start_profiling( +-- location => 'PLSHPROF_DIR' +-- , filename => 'profiler_utPLSQL_run_on_'||$$plsql_unit||'_'||rawtohex(self.id)||'.txt' +-- ); +-- ut_coverage.coverage_stop(); self.print_text_lines( @@ -92,6 +98,7 @@ create or replace type body ut_coverage_sonar_reporter is a_run ) ); +-- dbms_hprof.stop_profiling; end; overriding member function get_description return varchar2 as diff --git a/source/reporters/ut_coveralls_reporter.tpb b/source/reporters/ut_coveralls_reporter.tpb index 3a54aa7f7..14672303e 100644 --- a/source/reporters/ut_coveralls_reporter.tpb +++ b/source/reporters/ut_coveralls_reporter.tpb @@ -20,7 +20,7 @@ create or replace type body ut_coveralls_reporter is self in out nocopy ut_coveralls_reporter ) return self as result is begin - self.init($$plsql_unit); + self.init($$plsql_unit,ut_output_bulk_buffer()); return; end; diff --git a/source/reporters/ut_junit_reporter.tpb b/source/reporters/ut_junit_reporter.tpb index 44affa030..3bceb52a4 100644 --- a/source/reporters/ut_junit_reporter.tpb +++ b/source/reporters/ut_junit_reporter.tpb @@ -18,7 +18,7 @@ create or replace type body ut_junit_reporter is constructor function ut_junit_reporter(self in out nocopy ut_junit_reporter) return self as result is begin - self.init($$plsql_unit); + self.init($$plsql_unit,ut_output_bulk_buffer()); return; end; diff --git a/source/reporters/ut_sonar_test_reporter.tpb b/source/reporters/ut_sonar_test_reporter.tpb index a3ec72241..7c46879d2 100644 --- a/source/reporters/ut_sonar_test_reporter.tpb +++ b/source/reporters/ut_sonar_test_reporter.tpb @@ -20,7 +20,7 @@ create or replace type body ut_sonar_test_reporter is self in out nocopy ut_sonar_test_reporter ) return self as result is begin - self.init($$plsql_unit); + self.init($$plsql_unit,ut_output_bulk_buffer()); return; end; diff --git a/source/reporters/ut_tfs_junit_reporter.tpb b/source/reporters/ut_tfs_junit_reporter.tpb index 710c3bc7f..e2d45a369 100644 --- a/source/reporters/ut_tfs_junit_reporter.tpb +++ b/source/reporters/ut_tfs_junit_reporter.tpb @@ -18,7 +18,7 @@ create or replace type body ut_tfs_junit_reporter is constructor function ut_tfs_junit_reporter(self in out nocopy ut_tfs_junit_reporter) return self as result is begin - self.init($$plsql_unit); + self.init($$plsql_unit,ut_output_bulk_buffer()); return; end; diff --git a/source/reporters/ut_xunit_reporter.tpb b/source/reporters/ut_xunit_reporter.tpb index eab0c8a3c..4612fb640 100644 --- a/source/reporters/ut_xunit_reporter.tpb +++ b/source/reporters/ut_xunit_reporter.tpb @@ -18,7 +18,7 @@ create or replace type body ut_xunit_reporter is constructor function ut_xunit_reporter(self in out nocopy ut_xunit_reporter) return self as result is begin - self.init($$plsql_unit); + self.init($$plsql_unit,ut_output_bulk_buffer()); return; end; diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 571d187a2..9531736b9 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -323,6 +323,8 @@ drop type ut_output_table_buffer force; drop type ut_output_clob_table_buffer force; +drop type ut_output_bulk_buffer force; + drop type ut_output_buffer_base force; drop table ut_output_buffer_tmp purge; diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index d234967e4..ef14c586f 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -493,8 +493,8 @@ create or replace package body coverage_helper is x dbms_output.chararr; i integer := 100000; begin - execute immediate 'alter session set statistics_level=all'; /* + execute immediate 'alter session set statistics_level=all'; dbms_hprof.start_profiling( location => 'PLSHPROF_DIR' , filename => 'profiler_utPLSQL_run_]'||rawtohex(l_coverage_id)||q'[.txt' From 6c0b6e681954c389ca2763edcc6c56a7d142b586 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 20 Mar 2023 12:35:05 +0200 Subject: [PATCH 405/887] Fixes to new data-buffer implementation. --- .../core/output_buffers/ut_output_bulk_buffer.tpb | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tpb b/source/core/output_buffers/ut_output_bulk_buffer.tpb index 49aa1e913..ceae07862 100644 --- a/source/core/output_buffers/ut_output_bulk_buffer.tpb +++ b/source/core/output_buffers/ut_output_bulk_buffer.tpb @@ -49,7 +49,7 @@ create or replace type body ut_output_bulk_buffer is select /*+ no_parallel */ self.output_id, self.last_write_message_id + rownum, t.column_value, a_item_type from table(a_text_list) t where t.column_value is not null or a_item_type is not null; - self.last_write_message_id := self.last_write_message_id + SQL%rowcount; + self.last_write_message_id := self.last_write_message_id + sql%rowcount; commit; end; @@ -87,15 +87,16 @@ create or replace type body ut_output_bulk_buffer is exit when l_data%notfound; end loop; close l_data; + self.remove_buffer_info(); end; overriding member function get_lines_cursor(a_initial_timeout number := null, a_timeout_sec number := null) return sys_refcursor is - lc_init_wait_sec constant number := coalesce(a_initial_timeout, 30 ); + lc_init_wait_sec constant number := coalesce(a_initial_timeout, 10 ); l_already_waited_sec number(10,2) := 0; l_sleep_time number(2,1); l_exists integer; l_finished boolean := false; - l_data_produced boolean; + l_data_produced boolean := false; l_producer_active boolean := false; l_producer_started boolean := false; l_producer_finished boolean := false; @@ -115,11 +116,13 @@ create or replace type body ut_output_bulk_buffer is l_producer_active := (self.get_lock_status() <> 0); l_producer_started := (l_producer_active or l_data_produced ) or l_producer_started; l_producer_finished := (l_producer_started and not l_producer_active) or l_producer_finished; - l_finished := self.timeout_producer_not_finished(l_producer_finished, l_already_waited_sec, a_timeout_sec) or self.timeout_producer_not_started(l_producer_started, l_already_waited_sec, lc_init_wait_sec) or l_producer_finished; + + dbms_lock.sleep(l_sleep_time); + l_already_waited_sec := l_already_waited_sec + l_sleep_time; end loop; open l_results for @@ -152,8 +155,8 @@ create or replace type body ut_output_bulk_buffer is exit when l_data%notfound; end loop; close l_data; - return; self.remove_buffer_info(); + return; end; end; From 0daab3389dbf3fd0a0ec28e800479cfff486d45c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 27 Mar 2023 20:37:09 -0700 Subject: [PATCH 406/887] Checkpoint --- docs/userguide/annotations.md | 71 ++++++++++-- source/api/ut_runner.pkb | 14 +-- source/core/types/ut_run.tpb | 2 +- source/core/types/ut_run.tps | 6 +- source/core/ut_suite_builder.pkb | 2 +- source/core/ut_suite_cache_manager.pkb | 150 ++++++++++++++++++------- source/core/ut_suite_cache_manager.pks | 5 +- source/core/ut_suite_manager.pkb | 6 +- source/core/ut_suite_manager.pks | 2 +- source/core/ut_utils.pks | 4 + test/ut3_user/api/test_ut_run.pkb | 74 +++++++++++- test/ut3_user/api/test_ut_run.pks | 15 +++ 12 files changed, 280 insertions(+), 71 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 0e3b6446e..7fd2c09fa 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1616,11 +1616,8 @@ or Tags are defined as a comma separated list within the `--%tags` annotation. -When executing a test run with tag filter applied, the framework will find all tests associated with the given tags and execute them. -The framework applies `OR` logic to all specified tags so any test / suite that matches at least one tag will be included in the test run. - -When a suite/context is tagged, all of its children will automatically inherit the tag and get executed along with the parent. Parent suite tests are not executed, but a suitepath hierarchy is kept. - +When a suite/context is tagged, all of its children will automatically inherit the tag and get executed along with the parent, unless they are excluded by tag expression. +Parent suite tests are not executed, but a suitepath hierarchy is kept. Sample test suite package with tags. ```sql linenums="1" @@ -1661,7 +1658,37 @@ end ut_sample_test; / ``` -Execution of the test is done by using the parameter `a_tags` +#### Tag Expressions + +Tag expressions are boolean expressions with the operators !, & and |. In addition, ( and ) can be used to adjust for operator precedence. + +Two special expressions are supported, any() and none(), which select all tests with any tags at all, and all tests without any tags, respectively. These special expressions may be combined with other expressions just like normal tags. + +| Operator | Meaning | +| -------- | --------| +| ! | not | +| & | and | +| \| | or | + +If you are tagging your tests across multiple dimensions, tag expressions help you to select which tests to execute. When tagging by test type (e.g., micro, integration, end-to-end) and feature (e.g., product, catalog, shipping), the following tag expressions can be useful. + + +| Tag Expression | Selection | +| -------- | --------| +| product | all tests for product | +| catalog \| shipping | all tests for catalog plus all tests for shipping | +| catalog & shipping | all tests for the intersection between catalog and shipping | +| product & !end-to-end | all tests for product, but not the end-to-end tests | +| (micro \| integration) & (product \| shipping) | all micro or integration tests for product or shipping | + + +Execution of the test is done by using the parameter `a_tags` with tag expressions + + +```sql linenums="1" +select * from table(ut.run(a_tags => 'fast||!complex')); +``` +The above call will execute all tests from `ut_sample_test` package as the whole suite is tagged with `api` because a suite meet expression condition. ```sql linenums="1" select * from table(ut.run(a_path => 'ut_sample_test',a_tags => 'api')); @@ -1683,8 +1710,14 @@ The above call will execute both `ut_sample_test.ut_refcursors1` and `ut_sample_ Tags must follow the below naming convention: - tag is case sensitive -- tag can contain special characters like `$#/\?-!` etc. -- tag cannot be an empty string +- tag must not contain any of the following reserved characters: + - comma (,) + - left or right parenthesis ((, )) + - ampersand (&) + - vertical bar (|) + - exclamation point (!) +- tag cannot be null or blank +- tag cannot contain whitespace - tag cannot start with a dash, e.g. `-some-stuff` is **not** a valid tag - tag cannot contain spaces, e.g. `test of batch`. To create a multi-word tag use underscores or dashes, e.g. `test_of_batch`, `test-of-batch` - leading and trailing spaces are ignored in tag name, e.g. `--%tags( tag1 , tag2 )` becomes `tag1` and `tag2` tag names @@ -1693,13 +1726,31 @@ Tags must follow the below naming convention: #### Excluding tests/suites by tags It is possible to exclude parts of test suites with tags. -In order to do so, prefix the tag name to exclude with a `-` (dash) sign when invoking the test run. - +In order to do so, prefix the tag name to exclude with a `!` (exclamation) sign when invoking the test run which is equivalent of `-` (dash) in legacy notation. Examples (based on above sample test suite) +```sql linenums="1" +select * from table(ut.run(a_tags => '(api|fast)&!complex')); +``` + +which is equivalent of legacy calling: + ```sql linenums="1" select * from table(ut.run(a_tags => 'api,fast,-complex')); ``` + +or + +```sql linenums="1" +select * from table(ut.run(a_tags => '(api|fast)&(!complex&!test1)')); +``` + +which is equivalent of legacy calling: + +```sql linenums="1" +select * from table(ut.run(a_tags => 'api,fast,-complex,-test1')); +``` + The above call will execute all suites/contexts/tests that are marked with any of tags `api` or `fast` except those suites/contexts/tests that are marked as `complex`. Given the above example package `ut_sample_test`, only `ut_sample_test.ut_test` will be executed. diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index b69a51a04..2760868e0 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -79,7 +79,8 @@ create or replace package body ut_runner is l_coverage_schema_names ut_varchar2_rows; l_paths ut_varchar2_list; l_random_test_order_seed positive; - l_tags ut_varchar2_rows := ut_varchar2_rows(); + l_tags varchar2(4000) := a_tags; + begin ut_event_manager.initialize(); if a_reporters is not empty then @@ -94,6 +95,11 @@ create or replace package body ut_runner is ut_event_manager.trigger_event(ut_event_manager.gc_initialize); ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_run_info()); + --Verify tag tag expression is valid + if regexp_like(l_tags,'[&|]{2,}|[!-]{2,}|[!-][&|]|[^-&|!]+[-!]|[-!|&][)]') + or (regexp_count(l_tags,'\(') <> regexp_count(l_tags,'\)')) then + raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + end if; if a_random_test_order_seed is not null then l_random_test_order_seed := a_random_test_order_seed; elsif a_random_test_order then @@ -118,12 +124,6 @@ create or replace package body ut_runner is l_coverage_schema_names := ut_suite_manager.get_schema_names(l_paths); end if; - - if a_tags is not null then - l_tags := l_tags multiset union distinct ut_utils.convert_collection( - ut_utils.trim_list_elements(ut_utils.filter_list(ut_utils.string_to_table(a_tags,','),ut_utils.gc_word_no_space)) - ); - end if; l_run := ut_run( a_run_paths => l_paths, a_coverage_options => ut_coverage_options( diff --git a/source/core/types/ut_run.tpb b/source/core/types/ut_run.tpb index cdafb30fc..660c88791 100644 --- a/source/core/types/ut_run.tpb +++ b/source/core/types/ut_run.tpb @@ -24,7 +24,7 @@ create or replace type body ut_run as a_test_file_mappings ut_file_mappings := null, a_client_character_set varchar2 := null, a_random_test_order_seed positive := null, - a_run_tags ut_varchar2_rows := null + a_run_tags varchar2 := null ) return self as result is begin self.run_paths := a_run_paths; diff --git a/source/core/types/ut_run.tps b/source/core/types/ut_run.tps index debf847cd..8ce80d2a1 100644 --- a/source/core/types/ut_run.tps +++ b/source/core/types/ut_run.tps @@ -1,4 +1,4 @@ -create or replace type ut_run under ut_suite_item ( +create or replace type ut_run force under ut_suite_item ( /* utPLSQL - Version 3 Copyright 2016 - 2021 utPLSQL Project @@ -21,7 +21,7 @@ create or replace type ut_run under ut_suite_item ( project_name varchar2(4000), items ut_suite_items, run_paths ut_varchar2_list, - run_tags ut_varchar2_rows, + run_tags varchar2(4000), coverage_options ut_coverage_options, test_file_mappings ut_file_mappings, client_character_set varchar2(100), @@ -34,7 +34,7 @@ create or replace type ut_run under ut_suite_item ( a_test_file_mappings ut_file_mappings := null, a_client_character_set varchar2 := null, a_random_test_order_seed positive := null, - a_run_tags ut_varchar2_rows := null + a_run_tags varchar2 := null ) return self as result, overriding member procedure mark_as_skipped(self in out nocopy ut_run,a_skip_reason in varchar2), overriding member function do_execute(self in out nocopy ut_run) return boolean, diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index ebb113370..4aa2ff915 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -205,7 +205,7 @@ create or replace package body ut_suite_builder is l_tag_items := ut_utils.trim_list_elements(ut_utils.string_to_table(a_tags_ann_text(l_annotation_pos),',')); if l_tag_items is not empty then for i in 1 .. l_tag_items.count loop - if regexp_like(l_tag_items(i),'^[^-](\S)+$') then + if regexp_like(l_tag_items(i),'^[^-!&|](\S)+$') then l_tags_list.extend(); l_tags_list(l_tags_list.last) := l_tag_items(i); else diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index d3e832a9b..276f9427d 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -221,52 +221,118 @@ create or replace package body ut_suite_cache_manager is return l_suite_items; end; + /* + To support a legact tag notation + , = OR + - = NOT + we will perform a replace of that characters into + new notation. + || = OR + && = AND + ^ = NOT + */ + --TODO: How do we prevent when old notation reach 4k an new will be longer? + function replace_legacy_tag_notation(a_tags varchar2 + ) return varchar2 is + l_tags ut_varchar2_list := ut_utils.string_to_table(a_tags,','); + l_tags_include varchar2(2000); + l_tags_exclude varchar2(2000); + l_return_tag varchar2(4000); + begin + select listagg( t.column_value,' | ') + within group( order by column_value) + into l_tags_include + from table(l_tags) t + where t.column_value not like '-%'; + + select listagg( replace(t.column_value,'-','!'),' & ') + within group( order by column_value) + into l_tags_exclude + from table(l_tags) t + where t.column_value like '-%'; + + l_return_tag:= + case when l_tags_include is not null then + '('||l_tags_include||')' else null end || + case when l_tags_include is not null and l_tags_exclude is not null then + ' & ' else null end || + case when l_tags_exclude is not null then + '('||l_tags_exclude||')' else null end; + + return l_return_tag; + end; + + function create_where_filter(a_tags varchar2 + ) return varchar2 is + l_tags varchar2(4000):= replace(a_tags,' '); + begin + if instr(l_tags,',') > 0 or instr(l_tags,'-') > 0 then + l_tags := replace(replace_legacy_tag_notation(l_tags),' '); + end if; + l_tags := REGEXP_REPLACE(l_tags, + '(\(|\)|\||\!|\&)?([^|&!-]+)(\(|\)|\||\!|\&)?', + q'[\1q'<\2>' member of tags\3]'); + --replace operands to XPath + l_tags := REGEXP_REPLACE(l_tags, '\|',' or '); + l_tags := REGEXP_REPLACE(l_tags , '\&',' and '); + l_tags := REGEXP_REPLACE(l_tags,q'[(\!)(q'<[^|&!-]+>')( member of tags)]','\2 not \3'); + l_tags := '('||l_tags||')'; + return l_tags; + end; + /* Having a base set of suites we will do a further filter down if there are any tags defined. - */ + */ function get_tags_suites ( a_suite_items ut_suite_cache_rows, - a_tags ut_varchar2_rows + a_tags varchar2 ) return ut_suite_cache_rows is - l_suite_tags ut_suite_cache_rows := ut_suite_cache_rows(); - l_include_tags ut_varchar2_rows; - l_exclude_tags ut_varchar2_rows; + l_suite_tags ut_suite_cache_rows := ut_suite_cache_rows(); + l_sql varchar2(32000); + l_tags varchar2(4000):= create_where_filter(a_tags); begin - - select /*+ no_parallel */ column_value - bulk collect into l_include_tags - from table(a_tags) - where column_value not like '-%'; - - select /*+ no_parallel */ ltrim(column_value,'-') - bulk collect into l_exclude_tags - from table(a_tags) - where column_value like '-%'; - - with included_tags as ( - select c.path as path - from table(a_suite_items) c - where c.tags multiset intersect l_include_tags is not empty or l_include_tags is empty - ), - excluded_tags as ( - select c.path as path - from table(a_suite_items) c - where c.tags multiset intersect l_exclude_tags is not empty - ) - select value(c) as obj - bulk collect into l_suite_tags - from table(a_suite_items) c - where exists ( - select 1 from included_tags t - where t.path||'.' like c.path || '.%' /*all ancestors and self*/ - or c.path||'.' like t.path || '.%' /*all descendants and self*/ - ) - and not exists ( - select 1 from excluded_tags t - where c.path||'.' like t.path || '.%' /*all descendants and self*/ - ); - return l_suite_tags; + l_sql := + q'[ +with + suites_mv as ( + select c.id,value(c) as obj,c.path as path,c.self_type,c.object_owner,c.tags + from table(:suite_items) c + ), + suites_matching_expr as ( + select c.id,c.path as path,c.self_type,c.object_owner,c.tags + from suites_mv c + where c.self_type in ('UT_SUITE','UT_CONTEXT') + and ]'||l_tags||q'[ + ), + tests_matching_expr as ( + select c.id,c.path as path,c.self_type,c.object_owner,c.tags + from suites_mv c where c.self_type in ('UT_TEST') + and ]'||l_tags||q'[ + ), + tests_with_tags_inherited_from_suite as ( + select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner + from suites_mv c join suites_matching_expr t + on (c.path||'.' like t.path || '.%' /*all descendants and self*/ and c.object_owner = t.object_owner) + ), + tests_with_tags_promoted_to_suites as ( + select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner + from suites_mv c join tests_matching_expr t + on (t.path||'.' like c.path || '.%' /*all ancestors and self*/ and c.object_owner = t.object_owner) + ) + select obj from suites_mv c, + (select id,row_number() over (partition by id order by id) r_num from + (select id + from tests_with_tags_promoted_to_suites tst + where ]'||l_tags||q'[ + union all + select id from tests_with_tags_inherited_from_suite tst + where ]'||l_tags||q'[ + ) + ) t where c.id = t.id and r_num = 1 ]'; + + execute immediate l_sql bulk collect into l_suite_tags using a_suite_items; + return l_suite_tags; end; /* @@ -323,17 +389,17 @@ create or replace package body ut_suite_cache_manager is function get_cached_suite_rows( a_schema_paths ut_path_items, a_random_seed positive := null, - a_tags ut_varchar2_rows := null + a_tags varchar2 := null ) return ut_suite_cache_rows is l_results ut_suite_cache_rows := ut_suite_cache_rows(); l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); l_schema_paths ut_path_items; - l_tags ut_varchar2_rows := coalesce(a_tags,ut_varchar2_rows()); + l_tags varchar2(4000) := a_tags; begin l_schema_paths := a_schema_paths; l_suite_items := get_suite_items(a_schema_paths); - if l_tags.count > 0 then + if length(l_tags) > 0 then l_suite_items := get_tags_suites(l_suite_items,l_tags); end if; diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 974babca5..72dd08800 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -57,7 +57,7 @@ create or replace package ut_suite_cache_manager authid definer is function get_cached_suite_rows( a_schema_paths ut_path_items, a_random_seed positive := null, - a_tags ut_varchar2_rows := null + a_tags varchar2 := null ) return ut_suite_cache_rows; function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items; @@ -95,5 +95,8 @@ create or replace package ut_suite_cache_manager authid definer is a_procedure_name varchar2 ) return boolean; + +function create_where_filter(a_tags varchar2 + ) return varchar2; end ut_suite_cache_manager; / diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 86f68c076..0f8629ded 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -352,7 +352,7 @@ create or replace package body ut_suite_manager is function get_cached_suite_data( a_schema_paths ut_path_items, a_random_seed positive, - a_tags ut_varchar2_rows := null, + a_tags varchar2 := null, a_skip_all_objects boolean := false ) return t_cached_suites_cursor is l_unfiltered_rows ut_suite_cache_rows; @@ -451,7 +451,7 @@ create or replace package body ut_suite_manager is a_schema_paths ut_path_items, a_suites in out nocopy ut_suite_items, a_random_seed positive, - a_tags ut_varchar2_rows := null + a_tags varchar2 := null ) is begin reconstruct_from_cache( @@ -528,7 +528,7 @@ create or replace package body ut_suite_manager is a_paths ut_varchar2_list, a_suites out nocopy ut_suite_items, a_random_seed positive := null, - a_tags ut_varchar2_rows := ut_varchar2_rows() + a_tags varchar2 := null ) is l_paths ut_varchar2_list := a_paths; l_schema_names ut_varchar2_rows; diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 65b3c0654..07539139a 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -53,7 +53,7 @@ create or replace package ut_suite_manager authid current_user is a_paths in ut_varchar2_list, a_suites out nocopy ut_suite_items, a_random_seed in positive := null, - a_tags ut_varchar2_rows := ut_varchar2_rows() + a_tags in varchar2 := null ); /** diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 18a3d5952..f7f7b4f00 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -121,6 +121,10 @@ create or replace package ut_utils authid definer is ex_failed_open_cur exception; gc_failed_open_cur constant pls_integer := -20218; pragma exception_init (ex_failed_open_cur, -20218); + + ex_invalid_tag_expression exception; + gc_invalid_tag_expression constant pls_integer := -20219; + pragma exception_init (ex_invalid_tag_expression, -20219); gc_max_storage_varchar2_len constant integer := 4000; gc_max_output_string_length constant integer := 4000; diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 41b969359..6f6e229c8 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -948,7 +948,7 @@ Failures:% procedure two_test_run_by_two_tags is l_results clob; begin - ut3_tester_helper.run_helper.run(a_tags => 'subtest1,subtest2'); + ut3_tester_helper.run_helper.run(a_tags => 'subtest1|subtest2'); l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); --Assert ut.expect( l_results ).to_be_like( '%test_package_1%' ); @@ -958,7 +958,21 @@ Failures:% ut.expect( l_results ).not_to_be_like( '%test_package_3%' ); ut.expect( l_results ).not_to_be_like( '%test_package_3%' ); end; - + + procedure two_test_run_by_two_tags_leg is + l_results clob; + begin + ut3_tester_helper.run_helper.run(a_tags => 'subtest1,subtest2'); + l_results := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); + --Assert + ut.expect( l_results ).to_be_like( '%test_package_1%' ); + ut.expect( l_results ).to_be_like( '%test_package_2%' ); + ut.expect( l_results ).not_to_be_like( '%test_package_1.test2%' ); + ut.expect( l_results ).not_to_be_like( '%test_package_2.test2%' ); + ut.expect( l_results ).not_to_be_like( '%test_package_3%' ); + ut.expect( l_results ).not_to_be_like( '%test_package_3%' ); + end; + procedure suite_with_children_tag is l_results clob; begin @@ -1078,6 +1092,20 @@ Failures:% procedure tag_run_func_path_list is l_results ut3_develop.ut_varchar2_list; + begin + l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests'),a_tags => 'suite1test1|suite2test1'); + --Assert + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_3%' ); + end; + + procedure tag_run_func_path_list_leg is + l_results ut3_develop.ut_varchar2_list; begin l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests'),a_tags => 'suite1test1,suite2test1'); --Assert @@ -1092,6 +1120,18 @@ Failures:% procedure tag_inc_exc_run_func_path_list is l_results ut3_develop.ut_varchar2_list; + begin + l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests'),a_tags => '(suite1test1|suite2test1)&!suite2'); + --Assert + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_3%' ); + end; + + procedure tag_inc_exc_run_fun_pth_lst_lg is + l_results ut3_develop.ut_varchar2_list; begin l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests.test_package_1',':tests'),a_tags => 'suite1test1,suite2test1,-suite2'); --Assert @@ -1104,6 +1144,22 @@ Failures:% procedure tag_exclude_run_func_path_list is l_results ut3_develop.ut_varchar2_list; + begin + l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests,:tests2'),a_tags => '!suite1test2&!suite2test1&!test1suite3'); + --Assert + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_3%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_3.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_3.test2%executed%' ); + end; + +procedure tag_exclude_run_fun_pth_lst_lg is + l_results ut3_develop.ut_varchar2_list; begin l_results := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests,:tests2'),a_tags => '-suite1test2,-suite2test1,-test1suite3'); --Assert @@ -1120,6 +1176,20 @@ Failures:% procedure tag_include_exclude_run_func is l_results ut3_develop.ut_varchar2_list; + begin + l_results := ut3_tester_helper.run_helper.run(a_tags => '(suite1)&(!suite1test2&!suite2test1&!test1suite3)'); + --Assert + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_3%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_1.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2.test2%executed%' ); + end; + + procedure tag_include_exclude_run_fun_lg is + l_results ut3_develop.ut_varchar2_list; begin l_results := ut3_tester_helper.run_helper.run(a_tags => 'suite1,-suite1test2,-suite2test1,-test1suite3'); --Assert diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index b3be8700d..db02ee8f8 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -202,6 +202,9 @@ create or replace package test_ut_run is --%test(Execute tests by passing two tags) procedure two_test_run_by_two_tags; + --%test(Execute tests by passing two tags - Legacy notation) + procedure two_test_run_by_two_tags_leg; + --%test(Execute suite and all of its children) procedure suite_with_children_tag; @@ -235,15 +238,27 @@ create or replace package test_ut_run is --%test(Runs tests from given paths with paths list and a tag) procedure tag_run_func_path_list; + --%test(Runs tests from given paths with paths list and a tag - Legacy Notation) + procedure tag_run_func_path_list_leg; + --%test(Runs tests from given paths with paths list and include/exclude tags) procedure tag_inc_exc_run_func_path_list; + --%test(Runs tests from given paths with paths list and include/exclude tags - Legacy Notation) + procedure tag_inc_exc_run_fun_pth_lst_lg; + --%test(Runs tests from given path and excludes specific tags) procedure tag_exclude_run_func_path_list; + --%test(Runs tests from given path and excludes specific tags - Legacy Notation) + procedure tag_exclude_run_fun_pth_lst_lg; + --%test(Runs tests from given tags and exclude tags) procedure tag_include_exclude_run_func; + --%test(Runs tests from given tags and exclude tags - Legacy Notation) + procedure tag_include_exclude_run_fun_lg; + --%endcontext --%context(ut3_info context) From adbc76eb027f8425975b8277d4a10e2ec9ce7f7c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 27 Mar 2023 23:04:34 -0700 Subject: [PATCH 407/887] Address too long identified in 11g. Address flaky expression checker to be reworked. --- source/api/ut_runner.pkb | 6 ++++-- source/core/ut_suite_cache_manager.pkb | 10 +++++----- source/core/ut_suite_cache_manager.pks | 5 +---- 3 files changed, 10 insertions(+), 11 deletions(-) diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 2760868e0..94538eb69 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -95,11 +95,13 @@ create or replace package body ut_runner is ut_event_manager.trigger_event(ut_event_manager.gc_initialize); ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_run_info()); - --Verify tag tag expression is valid - if regexp_like(l_tags,'[&|]{2,}|[!-]{2,}|[!-][&|]|[^-&|!]+[-!]|[-!|&][)]') + --TODO:Verify tag tag expression is valid + /* + if regexp_like(l_tags,'[&|]{2,}|[!-]{2,}|[!-][&|]|[^-&|!,]+[-!]|[-!|&][)]') or (regexp_count(l_tags,'\(') <> regexp_count(l_tags,'\)')) then raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); end if; + */ if a_random_test_order_seed is not null then l_random_test_order_seed := a_random_test_order_seed; elsif a_random_test_order then diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 276f9427d..ff18deabf 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -270,7 +270,7 @@ create or replace package body ut_suite_cache_manager is l_tags := replace(replace_legacy_tag_notation(l_tags),' '); end if; l_tags := REGEXP_REPLACE(l_tags, - '(\(|\)|\||\!|\&)?([^|&!-]+)(\(|\)|\||\!|\&)?', + '(\(|\)|\||\!|\&)?([^|&!-()]+)(\(|\)|\||\!|\&)?', q'[\1q'<\2>' member of tags\3]'); --replace operands to XPath l_tags := REGEXP_REPLACE(l_tags, '\|',' or '); @@ -310,12 +310,12 @@ with from suites_mv c where c.self_type in ('UT_TEST') and ]'||l_tags||q'[ ), - tests_with_tags_inherited_from_suite as ( + tests_with_tags_inh_from_suite as ( select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner from suites_mv c join suites_matching_expr t on (c.path||'.' like t.path || '.%' /*all descendants and self*/ and c.object_owner = t.object_owner) ), - tests_with_tags_promoted_to_suites as ( + tests_with_tags_prom_to_suite as ( select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner from suites_mv c join tests_matching_expr t on (t.path||'.' like c.path || '.%' /*all ancestors and self*/ and c.object_owner = t.object_owner) @@ -323,10 +323,10 @@ with select obj from suites_mv c, (select id,row_number() over (partition by id order by id) r_num from (select id - from tests_with_tags_promoted_to_suites tst + from tests_with_tags_prom_to_suite tst where ]'||l_tags||q'[ union all - select id from tests_with_tags_inherited_from_suite tst + select id from tests_with_tags_inh_from_suite tst where ]'||l_tags||q'[ ) ) t where c.id = t.id and r_num = 1 ]'; diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 72dd08800..7f06e95eb 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -94,9 +94,6 @@ create or replace package ut_suite_cache_manager authid definer is a_package_name varchar2, a_procedure_name varchar2 ) return boolean; - - -function create_where_filter(a_tags varchar2 - ) return varchar2; + end ut_suite_cache_manager; / From 1478b0d21035398f3b6eccf82b37fa91adeb0e6b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 29 Mar 2023 12:41:32 -0700 Subject: [PATCH 408/887] Adding validation for tag expression --- source/api/ut_runner.pkb | 7 +-- source/core/ut_utils.pkb | 63 +++++++++++++++++++++++++- source/core/ut_utils.pks | 2 + test/ut3_tester/core/test_ut_utils.pkb | 27 +++++++++++ test/ut3_tester/core/test_ut_utils.pks | 2 + 5 files changed, 95 insertions(+), 6 deletions(-) diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 94538eb69..1ecaf1a42 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -95,13 +95,10 @@ create or replace package body ut_runner is ut_event_manager.trigger_event(ut_event_manager.gc_initialize); ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_run_info()); - --TODO:Verify tag tag expression is valid - /* - if regexp_like(l_tags,'[&|]{2,}|[!-]{2,}|[!-][&|]|[^-&|!,]+[-!]|[-!|&][)]') - or (regexp_count(l_tags,'\(') <> regexp_count(l_tags,'\)')) then + if ut_utils.valid_tag_expression(l_tags) = 0 then raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); end if; - */ + if a_random_test_order_seed is not null then l_random_test_order_seed := a_random_test_order_seed; elsif a_random_test_order then diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 162e50f8f..03ce1ad55 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -988,7 +988,68 @@ create or replace package body ut_utils is return l_result; end; - + + function valid_tag_expression(a_tags in varchar2) return number is + t_left_side ut_varchar2_list := ut_varchar2_list('|','&',','); + t_right_side ut_varchar2_list := ut_varchar2_list('!','-'); + l_left_side_expression varchar2(100) := '[|&,]'; + l_left_side_regex varchar(400) := '([^|&,]*)[|&,](.*)'; + l_left_side varchar2(4000); + + l_rigth_side_expression varchar2(100) := '[!-]'; + l_right_side_regex varchar(400) := '([!-])([^!-].*)'; + l_right_side varchar2(4000); + + l_tags varchar2(4000) := a_tags; + l_result number :=1; + begin + --Validate that we have closed up all brackets + if regexp_count(l_tags,'\(') <> regexp_count(l_tags,'\)') then + l_result := 0; + end if; + + --Remove brackets as we dont evaluate expression only validate. + l_tags := replace(replace(l_tags,'('),')'); + + --Check if there are any left side operators for first in order from left to right + if regexp_count(l_tags,l_left_side_expression) > 0 then + --Extract left part of operator and remaining of string to right + l_left_side := regexp_replace(l_tags,l_left_side_regex,'\1'); + l_right_side := regexp_replace(l_tags,l_left_side_regex,'\2'); + + --If left side is null that means that we used left side operator without + -- left and right e.g. &test + if l_left_side is null then + l_result := 0; + else + --Extract right side from left side expression if there is any !- + --Remove first negation tag to see if there is double negation + l_left_side := regexp_replace(l_left_side,l_right_side_regex,'\2'); + end if; + + + --check that on right side there is no extra negation + if regexp_count(l_left_side,l_rigth_side_expression) > 0 then + l_result := 0; + end if; + + --Now process right side of string + if l_right_side is not null then + l_result := least(l_result,valid_tag_expression(l_right_side)); + else + l_result := 0; + end if; + else + --We just process single tag. + l_left_side := l_tags; + l_left_side := regexp_replace(l_left_side,l_right_side_regex,'\2'); + if regexp_count(l_left_side,l_rigth_side_expression) > 0 then + l_result := 0; + end if; + end if; + + return l_result; + end; end ut_utils; / diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f7f7b4f00..2975c3846 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -477,5 +477,7 @@ create or replace package ut_utils authid definer is */ function interval_to_text(a_interval yminterval_unconstrained) return varchar2; + function valid_tag_expression(a_tags in varchar2) return number; + end ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 4ed718777..52c9cdff8 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -489,5 +489,32 @@ end; ut.expect(l_expected).to_equal(l_actual); end; + procedure valid_tag_expressions is + begin + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1&tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|!tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1&!tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1|!tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1&!tag2')); + + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1,tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('-tag1')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1,-tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('-tag1,-tag2')); + + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('(!tag1|!tag2)|tag3')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('(!tag1&!tag2)|(tag3&tag4)')); + + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|')); + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('&!tag2')); + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('!!tag1|!tag2')); + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1&!tag2|')); + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('((!tag1|!tag2)|tag3')); + + end; + end test_ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index 4d83b5042..b87d3b2c6 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -154,6 +154,8 @@ create or replace package test_ut_utils is --%test(returns text representation of interval year to month for custom interval) procedure int_conv_ym_date; + --%test(Test to validate different type of expressions passed as tags) + procedure valid_tag_expressions; --%endcontext From b5ad7475b53f5b4b14d9805f9c56b8e36dde0883 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 29 Mar 2023 14:53:24 -0700 Subject: [PATCH 409/887] Comment out to see why its failing. --- source/api/ut_runner.pkb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 1ecaf1a42..5f4912a24 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -94,10 +94,12 @@ create or replace package body ut_runner is ut_event_manager.trigger_event(ut_event_manager.gc_initialize); ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_run_info()); - + + /* if ut_utils.valid_tag_expression(l_tags) = 0 then raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); end if; + */ if a_random_test_order_seed is not null then l_random_test_order_seed := a_random_test_order_seed; From 06cb054aa72b8aca8115f277e673485321efc0ad Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 29 Mar 2023 15:10:34 -0700 Subject: [PATCH 410/887] Revert "Comment out to see why its failing." This reverts commit b5ad7475b53f5b4b14d9805f9c56b8e36dde0883. Revert "Adding validation for tag expression" This reverts commit 1478b0d21035398f3b6eccf82b37fa91adeb0e6b. --- source/api/ut_runner.pkb | 7 +-- source/core/ut_utils.pkb | 63 +------------------------- source/core/ut_utils.pks | 2 - test/ut3_tester/core/test_ut_utils.pkb | 27 ----------- test/ut3_tester/core/test_ut_utils.pks | 2 - 5 files changed, 5 insertions(+), 96 deletions(-) diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 5f4912a24..94538eb69 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -94,13 +94,14 @@ create or replace package body ut_runner is ut_event_manager.trigger_event(ut_event_manager.gc_initialize); ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_run_info()); - + + --TODO:Verify tag tag expression is valid /* - if ut_utils.valid_tag_expression(l_tags) = 0 then + if regexp_like(l_tags,'[&|]{2,}|[!-]{2,}|[!-][&|]|[^-&|!,]+[-!]|[-!|&][)]') + or (regexp_count(l_tags,'\(') <> regexp_count(l_tags,'\)')) then raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); end if; */ - if a_random_test_order_seed is not null then l_random_test_order_seed := a_random_test_order_seed; elsif a_random_test_order then diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 03ce1ad55..162e50f8f 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -988,68 +988,7 @@ create or replace package body ut_utils is return l_result; end; - - function valid_tag_expression(a_tags in varchar2) return number is - t_left_side ut_varchar2_list := ut_varchar2_list('|','&',','); - t_right_side ut_varchar2_list := ut_varchar2_list('!','-'); - l_left_side_expression varchar2(100) := '[|&,]'; - l_left_side_regex varchar(400) := '([^|&,]*)[|&,](.*)'; - l_left_side varchar2(4000); - - l_rigth_side_expression varchar2(100) := '[!-]'; - l_right_side_regex varchar(400) := '([!-])([^!-].*)'; - l_right_side varchar2(4000); - - l_tags varchar2(4000) := a_tags; - l_result number :=1; - begin - --Validate that we have closed up all brackets - if regexp_count(l_tags,'\(') <> regexp_count(l_tags,'\)') then - l_result := 0; - end if; - - --Remove brackets as we dont evaluate expression only validate. - l_tags := replace(replace(l_tags,'('),')'); - - --Check if there are any left side operators for first in order from left to right - if regexp_count(l_tags,l_left_side_expression) > 0 then - --Extract left part of operator and remaining of string to right - l_left_side := regexp_replace(l_tags,l_left_side_regex,'\1'); - l_right_side := regexp_replace(l_tags,l_left_side_regex,'\2'); - - --If left side is null that means that we used left side operator without - -- left and right e.g. &test - if l_left_side is null then - l_result := 0; - else - --Extract right side from left side expression if there is any !- - --Remove first negation tag to see if there is double negation - l_left_side := regexp_replace(l_left_side,l_right_side_regex,'\2'); - end if; - - - --check that on right side there is no extra negation - if regexp_count(l_left_side,l_rigth_side_expression) > 0 then - l_result := 0; - end if; - - --Now process right side of string - if l_right_side is not null then - l_result := least(l_result,valid_tag_expression(l_right_side)); - else - l_result := 0; - end if; - else - --We just process single tag. - l_left_side := l_tags; - l_left_side := regexp_replace(l_left_side,l_right_side_regex,'\2'); - if regexp_count(l_left_side,l_rigth_side_expression) > 0 then - l_result := 0; - end if; - end if; - - return l_result; - end; + end ut_utils; / diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 2975c3846..f7f7b4f00 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -477,7 +477,5 @@ create or replace package ut_utils authid definer is */ function interval_to_text(a_interval yminterval_unconstrained) return varchar2; - function valid_tag_expression(a_tags in varchar2) return number; - end ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 52c9cdff8..4ed718777 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -489,32 +489,5 @@ end; ut.expect(l_expected).to_equal(l_actual); end; - procedure valid_tag_expressions is - begin - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1&tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|!tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1&!tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1|!tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1&!tag2')); - - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1,tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('-tag1')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1,-tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('-tag1,-tag2')); - - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('(!tag1|!tag2)|tag3')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('(!tag1&!tag2)|(tag3&tag4)')); - - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|')); - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('&!tag2')); - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('!!tag1|!tag2')); - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1&!tag2|')); - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('((!tag1|!tag2)|tag3')); - - end; - end test_ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index b87d3b2c6..4d83b5042 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -154,8 +154,6 @@ create or replace package test_ut_utils is --%test(returns text representation of interval year to month for custom interval) procedure int_conv_ym_date; - --%test(Test to validate different type of expressions passed as tags) - procedure valid_tag_expressions; --%endcontext From e87d39f992da9ff7fdb0cb2b653f6fc0380c6def Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 29 Mar 2023 15:17:46 -0700 Subject: [PATCH 411/887] Adding validate function, with no calls --- source/core/ut_utils.pkb | 61 ++++++++++++++++++++++++++++++++++++++++ source/core/ut_utils.pks | 7 ++++- 2 files changed, 67 insertions(+), 1 deletion(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 162e50f8f..14d0bc148 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -989,6 +989,67 @@ create or replace package body ut_utils is return l_result; end; + function valid_tag_expression(a_tags in varchar2) return number is + t_left_side ut_varchar2_list := ut_varchar2_list('|','&',','); + t_right_side ut_varchar2_list := ut_varchar2_list('!','-'); + l_left_side_expression varchar2(100) := '[|&,]'; + l_left_side_regex varchar(400) := '([^|&,]*)[|&,](.*)'; + l_left_side varchar2(4000); + + l_rigth_side_expression varchar2(100) := '[!-]'; + l_right_side_regex varchar(400) := '([!-])([^!-].*)'; + l_right_side varchar2(4000); + + l_tags varchar2(4000) := a_tags; + l_result number :=1; + begin + --Validate that we have closed up all brackets + if regexp_count(l_tags,'\(') <> regexp_count(l_tags,'\)') then + l_result := 0; + end if; + + --Remove brackets as we dont evaluate expression only validate. + l_tags := replace(replace(l_tags,'('),')'); + + --Check if there are any left side operators for first in order from left to right + if regexp_count(l_tags,l_left_side_expression) > 0 then + --Extract left part of operator and remaining of string to right + l_left_side := regexp_replace(l_tags,l_left_side_regex,'\1'); + l_right_side := regexp_replace(l_tags,l_left_side_regex,'\2'); + + --If left side is null that means that we used left side operator without + -- left and right e.g. &test + if l_left_side is null then + l_result := 0; + else + --Extract right side from left side expression if there is any !- + --Remove first negation tag to see if there is double negation + l_left_side := regexp_replace(l_left_side,l_right_side_regex,'\2'); + end if; + + + --check that on right side there is no extra negation + if regexp_count(l_left_side,l_rigth_side_expression) > 0 then + l_result := 0; + end if; + + --Now process right side of string + if l_right_side is not null then + l_result := least(l_result,valid_tag_expression(l_right_side)); + else + l_result := 0; + end if; + else + --We just process single tag. + l_left_side := l_tags; + l_left_side := regexp_replace(l_left_side,l_right_side_regex,'\2'); + if regexp_count(l_left_side,l_rigth_side_expression) > 0 then + l_result := 0; + end if; + end if; + + return l_result; + end; end ut_utils; / diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f7f7b4f00..06c6956b4 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -476,6 +476,11 @@ create or replace package ut_utils authid definer is * Return value of interval in plain english */ function interval_to_text(a_interval yminterval_unconstrained) return varchar2; - + + /* + * Return number 1 or 0 if the list of tags is valid expression + */ + function valid_tag_expression(a_tags in varchar2) return number; + end ut_utils; / From 97537de9629c19313ccc6157ac95f323a2de6656 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 29 Mar 2023 15:29:07 -0700 Subject: [PATCH 412/887] Remove a & from text --- source/api/ut_runner.pkb | 7 ++----- source/core/ut_utils.pkb | 2 +- test/ut3_tester/core/test_ut_utils.pkb | 27 ++++++++++++++++++++++++++ test/ut3_tester/core/test_ut_utils.pks | 3 +++ 4 files changed, 33 insertions(+), 6 deletions(-) diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 94538eb69..a2a69f464 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -95,13 +95,10 @@ create or replace package body ut_runner is ut_event_manager.trigger_event(ut_event_manager.gc_initialize); ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_run_info()); - --TODO:Verify tag tag expression is valid - /* - if regexp_like(l_tags,'[&|]{2,}|[!-]{2,}|[!-][&|]|[^-&|!,]+[-!]|[-!|&][)]') - or (regexp_count(l_tags,'\(') <> regexp_count(l_tags,'\)')) then + if ut_utils.valid_tag_expression(l_tags) = 0 then raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); end if; - */ + if a_random_test_order_seed is not null then l_random_test_order_seed := a_random_test_order_seed; elsif a_random_test_order then diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 14d0bc148..2a47d4d4b 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -1018,7 +1018,7 @@ create or replace package body ut_utils is l_right_side := regexp_replace(l_tags,l_left_side_regex,'\2'); --If left side is null that means that we used left side operator without - -- left and right e.g. &test + -- left and right e.g. |test if l_left_side is null then l_result := 0; else diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 4ed718777..8a497b9f1 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -488,6 +488,33 @@ end; begin ut.expect(l_expected).to_equal(l_actual); end; + + procedure valid_tag_expressions is + begin + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1&tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|!tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1&!tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1|!tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1&!tag2')); + + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1,tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('-tag1')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1,-tag2')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('-tag1,-tag2')); + + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('(!tag1|!tag2)|tag3')); + ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('(!tag1&!tag2)|(tag3&tag4)')); + + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|')); + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('&!tag2')); + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('!!tag1|!tag2')); + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1&!tag2|')); + ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('((!tag1|!tag2)|tag3')); + + end; end test_ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index 4d83b5042..0f8545a45 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -157,5 +157,8 @@ create or replace package test_ut_utils is --%endcontext + --%test(Test to validate different type of expressions passed as tags) + procedure valid_tag_expressions; + end test_ut_utils; / From 69092f249427dccd39ff0df26848cbd873701ef9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 30 Mar 2023 20:07:27 +0100 Subject: [PATCH 413/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index d132d2085..a47004a3c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 21b82ee41..8b6437299 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 9b423d5a8..02eabab07 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index d534857fa..aacb289f2 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index d6884ba2d..5e30a9fc6 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 2c31a9a89..8db920ee7 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index d193e2c20..31b2fd442 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 63c0e36e9..b83fb78c3 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index f77717798..04b3db380 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e237bf4ef..a7b0ae0a5 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 8fa525a69..2b436250e 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index d97d49464..37c22c882 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 934d07d72..00a74b288 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 9e16fd3e8..164c0cbc0 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index b3b0e338a..e92558e3d 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index e8e431980..978803b9a 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 47772937e..794e75070 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4094--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f92fbc2b0..e79ce1fa6 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4094-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4105-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 2a0f99affc9b6b43dfa9e6f00c053c0eada27b14 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 31 Mar 2023 08:29:14 -0700 Subject: [PATCH 414/887] Extra changes and added tests --- source/core/ut_suite_cache_manager.pkb | 6 +- test/ut3_tester_helper/run_helper.pkb | 94 ++++++++++++++++++++++++++ test/ut3_user/api/test_ut_run.pkb | 33 +++++++++ test/ut3_user/api/test_ut_run.pks | 3 + 4 files changed, 133 insertions(+), 3 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index ff18deabf..ca7945c74 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -273,9 +273,9 @@ create or replace package body ut_suite_cache_manager is '(\(|\)|\||\!|\&)?([^|&!-()]+)(\(|\)|\||\!|\&)?', q'[\1q'<\2>' member of tags\3]'); --replace operands to XPath - l_tags := REGEXP_REPLACE(l_tags, '\|',' or '); - l_tags := REGEXP_REPLACE(l_tags , '\&',' and '); - l_tags := REGEXP_REPLACE(l_tags,q'[(\!)(q'<[^|&!-]+>')( member of tags)]','\2 not \3'); + l_tags := REPLACE(l_tags, '|',' or '); + l_tags := REPLACE(l_tags , '&',' and '); + l_tags := REGEXP_REPLACE(l_tags,q'[(\!)(q'<[^|&!]+?>')( member of tags)]','\2 not \3'); l_tags := '('||l_tags||')'; return l_tags; end; diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index a132f4943..c73564798 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -343,9 +343,100 @@ create or replace package body run_helper is end; end test_package_3; ]'; + + execute immediate q'[create or replace package test_tag_pkg_1 is + --%suite + --%tags(suite1,release_3_1_13,development,complex,end_to_end) + --%suitepath(suite1) + --%rollback(manual) + + --%test(Test1 from test_tag_pkg_1) + --%tags(test1,development,fast) + procedure test1; + + --%test(Test2 from test_tag_pkg_1) + --%tags(test2,production,slow,patch_3_1_13) + procedure test2; + + end test_tag_pkg_1; + ]'; + + execute immediate q'[create or replace package body test_tag_pkg_1 is + procedure test1 is + begin + dbms_output.put_line('test_tag_pkg_1.test1 executed'); + end; + procedure test2 is + begin + dbms_output.put_line('test_tag_pkg_1.test2 executed'); + end; + end test_tag_pkg_1; + ]'; + + execute immediate q'[create or replace package test_tag_pkg_2 is + --%suite + --%tags(suite2,release_3_1_12,development,simple) + --%suitepath(suite1.suite2) + --%rollback(manual) + + --%test(Test3 from test_tag_pkg_2) + --%tags(test3,development,fast) + procedure test3; + + --%test(Test4 from test_tag_pkg_1) + --%tags(test4,production,slow) + procedure test4; + + end test_tag_pkg_2; + ]'; + + execute immediate q'[create or replace package body test_tag_pkg_2 is + procedure test3 is + begin + dbms_output.put_line('test_tag_pkg_2.test3 executed'); + end; + procedure test4 is + begin + dbms_output.put_line('test_tag_pkg_2.test4 executed'); + end; + end test_tag_pkg_2; + ]'; + + execute immediate q'[create or replace package test_tag_pkg_3 is + --%suite + --%tags(suite3,release_3_1_13,production,simple,end_to_end) + --%suitepath(suite3) + --%rollback(manual) + + --%test(Test5 from test_tag_pkg_3) + --%tags(test5,release_3_1_13,production,patch_3_1_13) + procedure test5; + + --%test(Test6 from test_tag_pkg_3) + --%tags(test6,development,patch_3_1_14) + procedure test6; + + end test_tag_pkg_3; + ]'; + + execute immediate q'[create or replace package body test_tag_pkg_3 is + procedure test5 is + begin + dbms_output.put_line('test_tag_pkg_3.test5 executed'); + end; + procedure test6 is + begin + dbms_output.put_line('test_tag_pkg_3.test6 executed'); + end; + end test_tag_pkg_3; + ]'; + execute immediate q'[grant execute on test_package_1 to public]'; execute immediate q'[grant execute on test_package_2 to public]'; execute immediate q'[grant execute on test_package_3 to public]'; + execute immediate q'[grant execute on test_tag_pkg_1 to public]'; + execute immediate q'[grant execute on test_tag_pkg_2 to public]'; + execute immediate q'[grant execute on test_tag_pkg_3 to public]'; end; procedure drop_ut3_user_tests is @@ -354,6 +445,9 @@ create or replace package body run_helper is execute immediate q'[drop package test_package_1]'; execute immediate q'[drop package test_package_2]'; execute immediate q'[drop package test_package_3]'; + execute immediate q'[drop package test_tag_pkg_1]'; + execute immediate q'[drop package test_tag_pkg_2]'; + execute immediate q'[drop package test_tag_pkg_3]'; end; procedure create_test_suite is diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 6f6e229c8..ee420f310 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1202,6 +1202,39 @@ procedure tag_exclude_run_fun_pth_lst_lg is ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_package_2.test2%executed%' ); end; + procedure tag_complex_expressions is + l_results ut3_develop.ut_varchar2_list; + begin + l_results := ut3_tester_helper.run_helper.run(a_tags => 'release_3_1_13&(fast|simple)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test5 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test6 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test3%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test4%executed%' ); + + l_results := ut3_tester_helper.run_helper.run(a_tags => 'release_3_1_13&(!patch_3_1_13&!patch_3_1_14)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_1.test1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test3%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test4%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_3.test5%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_3.test6%executed%' ); + + l_results := ut3_tester_helper.run_helper.run(a_tags => 'release_3_1_13&(patch_3_1_13&!slow)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test5 executed%' ); + + l_results := ut3_tester_helper.run_helper.run(a_tags => '(simple&end_to_end)|(development&fast)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_1.test1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_2.test3 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test5 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test6 executed%' ); + + l_results := ut3_tester_helper.run_helper.run(a_tags => '(!development&end_to_end)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test5 executed%' ); + + end; + procedure set_application_info is begin dbms_application_info.set_module( gc_module, gc_action ); diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index db02ee8f8..40e870fe4 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -259,6 +259,9 @@ create or replace package test_ut_run is --%test(Runs tests from given tags and exclude tags - Legacy Notation) procedure tag_include_exclude_run_fun_lg; + --%test(Runs tests suing complex expressions) + procedure tag_complex_expressions; + --%endcontext --%context(ut3_info context) From b30688cae39ea3917c92427528a5649022e76a4b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 1 Apr 2023 08:31:13 -0700 Subject: [PATCH 415/887] Address sonar coverage issues. --- source/core/ut_suite_cache_manager.pkb | 14 ++++++++------ source/core/ut_utils.pkb | 14 ++++++++++---- 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index ca7945c74..2ccf20721 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -227,11 +227,10 @@ create or replace package body ut_suite_cache_manager is - = NOT we will perform a replace of that characters into new notation. - || = OR - && = AND - ^ = NOT + | = OR + & = AND + ! = NOT */ - --TODO: How do we prevent when old notation reach 4k an new will be longer? function replace_legacy_tag_notation(a_tags varchar2 ) return varchar2 is l_tags ut_varchar2_list := ut_utils.string_to_table(a_tags,','); @@ -331,8 +330,11 @@ with ) ) t where c.id = t.id and r_num = 1 ]'; - execute immediate l_sql bulk collect into l_suite_tags using a_suite_items; - return l_suite_tags; + execute immediate l_sql bulk collect into l_suite_tags using a_suite_items; + return l_suite_tags; + exception when others then + --If the dynamic SQL fails we will fall gracefully with meaningfull message + raise_application_error(ut_utils.gc_invalid_tag_expression, 'Tag expression, causing error. If expression is correct please report error.'); end; /* diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 751971202..3747b029a 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -990,15 +990,21 @@ create or replace package body ut_utils is return l_result; end; + /* + Purpose of this function is to break down the tag expressions + We can separate operators on left and rigth side. + Left ones are AND and OR as they require an operator on left side to + be valid. Right side is NOT. + In each iteration we breakdown string into parts + + */ function valid_tag_expression(a_tags in varchar2) return number is - t_left_side ut_varchar2_list := ut_varchar2_list('|','&',','); - t_right_side ut_varchar2_list := ut_varchar2_list('!','-'); l_left_side_expression varchar2(100) := '[|&,]'; - l_left_side_regex varchar(400) := '([^|&,]*)[|&,](.*)'; + l_left_side_regex varchar2(400) := '([^|&,]*)[|&,](.*)'; l_left_side varchar2(4000); l_rigth_side_expression varchar2(100) := '[!-]'; - l_right_side_regex varchar(400) := '([!-])([^!-].*)'; + l_right_side_regex varchar2(400) := '([!-])([^!-].*)'; l_right_side varchar2(4000); l_tags varchar2(4000) := a_tags; From 0c41a0f22816b901e0b2adca5441e462feedb88a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 1 Apr 2023 09:19:43 -0700 Subject: [PATCH 416/887] Adding tests covering exception of invalid tags --- source/core/ut_suite_cache_manager.pkb | 5 +---- test/ut3_user/api/test_ut_run.pkb | 30 +++++++++++++++++++++++++- test/ut3_user/api/test_ut_run.pks | 4 ++++ 3 files changed, 34 insertions(+), 5 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 2ccf20721..152b5c0f9 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -331,10 +331,7 @@ with ) t where c.id = t.id and r_num = 1 ]'; execute immediate l_sql bulk collect into l_suite_tags using a_suite_items; - return l_suite_tags; - exception when others then - --If the dynamic SQL fails we will fall gracefully with meaningfull message - raise_application_error(ut_utils.gc_invalid_tag_expression, 'Tag expression, causing error. If expression is correct please report error.'); + return l_suite_tags; end; /* diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index ee420f310..84dd11f9c 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1223,16 +1223,44 @@ procedure tag_exclude_run_fun_pth_lst_lg is l_results := ut3_tester_helper.run_helper.run(a_tags => 'release_3_1_13&(patch_3_1_13&!slow)'); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test5 executed%' ); - + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test3%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test4%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_3.test6%executed%' ); + l_results := ut3_tester_helper.run_helper.run(a_tags => '(simple&end_to_end)|(development&fast)'); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_1.test1 executed%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_2.test3 executed%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test5 executed%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test6 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test4%executed%' ); l_results := ut3_tester_helper.run_helper.run(a_tags => '(!development&end_to_end)'); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%test_tag_pkg_3.test5 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test1%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_1.test2%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test3%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test4%executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_3.test6%executed%' ); + + end; + + procedure invalid_tag_expression is + l_results ut3_develop.ut_varchar2_list; + begin + l_results := ut3_tester_helper.run_helper.run(a_tags => '(!!development&end_to_end)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); + + l_results := ut3_tester_helper.run_helper.run(a_tags => '(!development&&end_to_end)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); + l_results := ut3_tester_helper.run_helper.run(a_tags => '(!development&end_to_end|)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); end; procedure set_application_info is diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index 40e870fe4..c57788bff 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -262,6 +262,10 @@ create or replace package test_ut_run is --%test(Runs tests suing complex expressions) procedure tag_complex_expressions; + --%test(Testing invalid tag expression) + --%throws(-20219) + procedure invalid_tag_expression; + --%endcontext --%context(ut3_info context) From 543685dc94676110099af0b8af1a155918725cd5 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 1 Apr 2023 11:26:17 -0700 Subject: [PATCH 417/887] Removing that , we will not implement that, there is no benefit at the moment. --- docs/userguide/annotations.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index f3cf73d4d..4017521b5 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1662,8 +1662,6 @@ end ut_sample_test; Tag expressions are boolean expressions with the operators !, & and |. In addition, ( and ) can be used to adjust for operator precedence. -Two special expressions are supported, any() and none(), which select all tests with any tags at all, and all tests without any tags, respectively. These special expressions may be combined with other expressions just like normal tags. - | Operator | Meaning | | -------- | --------| | ! | not | From 0d3cfa166beccb14b19debffa99bb392f85d8bbb Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 1 Apr 2023 11:30:00 -0700 Subject: [PATCH 418/887] Removing force --- source/core/types/ut_run.tps | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/types/ut_run.tps b/source/core/types/ut_run.tps index 8ce80d2a1..1878a2d46 100644 --- a/source/core/types/ut_run.tps +++ b/source/core/types/ut_run.tps @@ -1,4 +1,4 @@ -create or replace type ut_run force under ut_suite_item ( +create or replace type ut_run under ut_suite_item ( /* utPLSQL - Version 3 Copyright 2016 - 2021 utPLSQL Project From 20e317742e00f5299b2abd2675160d4b2cc38b86 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 9 Apr 2023 18:47:21 -0700 Subject: [PATCH 419/887] Changing to use Dijkstra algorithm to parse infix notation into postfix ( Reverse Polish Notation). This allows us to more flexibility of using boolean expressions and not limited to flaky regex. --- source/api/ut_runner.pkb | 4 - source/core/types/ut_stack.tpb | 58 ++++++ source/core/types/ut_stack.tps | 26 +++ source/core/ut_suite_cache_manager.pkb | 21 +-- source/core/ut_utils.pkb | 245 ++++++++++++++++++++++++- source/core/ut_utils.pks | 25 +++ source/install.sql | 2 + test/ut3_user/api/test_ut_run.pkb | 2 +- 8 files changed, 363 insertions(+), 20 deletions(-) create mode 100644 source/core/types/ut_stack.tpb create mode 100644 source/core/types/ut_stack.tps diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index a2a69f464..3d4550cf9 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -95,10 +95,6 @@ create or replace package body ut_runner is ut_event_manager.trigger_event(ut_event_manager.gc_initialize); ut_event_manager.trigger_event(ut_event_manager.gc_debug, ut_run_info()); - if ut_utils.valid_tag_expression(l_tags) = 0 then - raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); - end if; - if a_random_test_order_seed is not null then l_random_test_order_seed := a_random_test_order_seed; elsif a_random_test_order then diff --git a/source/core/types/ut_stack.tpb b/source/core/types/ut_stack.tpb new file mode 100644 index 000000000..a7f7ab0c2 --- /dev/null +++ b/source/core/types/ut_stack.tpb @@ -0,0 +1,58 @@ +create or replace type body ut_stack as + /* + utPLSQL - Version 3 + Copyright 2016 - 2021 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + constructor function ut_stack( self in out nocopy ut_stack) return self as result is + begin + self.tokens := ut_varchar2_list(); + self.top := 0; + return; + end ut_stack; + + member function peek(self in out nocopy ut_stack) return varchar2 is + l_token varchar2(32767); + begin + if self.tokens.count =0 or self.tokens is null then + l_token := null; + else + l_token := self.tokens(self.tokens.last); + end if; + return l_token; + end; + + member procedure push(self in out nocopy ut_stack, a_token varchar2) is + begin + self.tokens.extend; + self.tokens(self.tokens.last) := a_token; + self.top := self.tokens.count; + end push; + + member procedure pop(self in out nocopy ut_stack,a_cnt in integer default 1) is + begin + self.tokens.trim(a_cnt); + self.top := self.tokens.count; + end pop; + + member function pop(self in out nocopy ut_stack) return varchar2 is + l_token varchar2(32767) := self.tokens(self.tokens.last); + begin + self.pop(); + return l_token; + end; +end; +/ + diff --git a/source/core/types/ut_stack.tps b/source/core/types/ut_stack.tps new file mode 100644 index 000000000..9851b9cc5 --- /dev/null +++ b/source/core/types/ut_stack.tps @@ -0,0 +1,26 @@ +create or replace type ut_stack as object ( + top integer, + tokens ut_varchar2_list, + /* + utPLSQL - Version 3 + Copyright 2016 - 2021 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + constructor function ut_stack( self in out nocopy ut_stack) return self as result, + member function peek(self in out nocopy ut_stack) return varchar2, + member procedure push(self in out nocopy ut_stack, a_token varchar2), + member procedure pop(self in out nocopy ut_stack,a_cnt in integer default 1), + member function pop(self in out nocopy ut_stack) return varchar2 +) + diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 152b5c0f9..ae5460ef6 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -234,11 +234,11 @@ create or replace package body ut_suite_cache_manager is function replace_legacy_tag_notation(a_tags varchar2 ) return varchar2 is l_tags ut_varchar2_list := ut_utils.string_to_table(a_tags,','); - l_tags_include varchar2(2000); - l_tags_exclude varchar2(2000); + l_tags_include varchar2(4000); + l_tags_exclude varchar2(4000); l_return_tag varchar2(4000); begin - select listagg( t.column_value,' | ') + select listagg( t.column_value,'|') within group( order by column_value) into l_tags_include from table(l_tags) t @@ -268,15 +268,14 @@ create or replace package body ut_suite_cache_manager is if instr(l_tags,',') > 0 or instr(l_tags,'-') > 0 then l_tags := replace(replace_legacy_tag_notation(l_tags),' '); end if; - l_tags := REGEXP_REPLACE(l_tags, - '(\(|\)|\||\!|\&)?([^|&!-()]+)(\(|\)|\||\!|\&)?', - q'[\1q'<\2>' member of tags\3]'); - --replace operands to XPath + l_tags := ut_utils.convert_postfix_to_infix_where_sql(ut_utils.shunt_logical_expression(l_tags)); l_tags := REPLACE(l_tags, '|',' or '); - l_tags := REPLACE(l_tags , '&',' and '); - l_tags := REGEXP_REPLACE(l_tags,q'[(\!)(q'<[^|&!]+?>')( member of tags)]','\2 not \3'); - l_tags := '('||l_tags||')'; - return l_tags; + l_tags := REPLACE(l_tags ,'&',' and '); + l_tags := REPLACE(l_tags ,'!','not'); + return l_tags; + exception + when ut_utils.ex_invalid_tag_expression then + raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); end; /* diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 3747b029a..c09c15221 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -24,6 +24,16 @@ create or replace package body ut_utils is gc_full_valid_xml_name constant varchar2(50) := '^([_a-zA-Z])([_a-zA-Z0-9\.-])*$'; gc_owner_hash constant integer(11) := dbms_utility.get_hash_value( ut_owner(), 0, power(2,31)-1); + /** + * Constants use in postfix and infix transformations + */ + gc_operators constant ut_varchar2_list := ut_varchar2_list('|','&','!'); + gc_unary_operator constant ut_varchar2_list := ut_varchar2_list('!'); -- right side associative operator + gc_binary_operator constant ut_varchar2_list := ut_varchar2_list('|','&'); -- left side associative operator + + type t_precedence_table is table of number index by varchar2(1); + g_precedence t_precedence_table; + function surround_with(a_value varchar2, a_quote_char varchar2) return varchar2 is begin return case when a_quote_char is not null then a_quote_char||a_value||a_quote_char else a_value end; @@ -999,12 +1009,12 @@ create or replace package body ut_utils is */ function valid_tag_expression(a_tags in varchar2) return number is - l_left_side_expression varchar2(100) := '[|&,]'; - l_left_side_regex varchar2(400) := '([^|&,]*)[|&,](.*)'; + l_left_side_expression varchar2(10) := '[|&,]'; + l_left_side_regex varchar2(50) := '([^|&,]*)[|&,](.*)'; l_left_side varchar2(4000); - l_rigth_side_expression varchar2(100) := '[!-]'; - l_right_side_regex varchar2(400) := '([!-])([^!-].*)'; + l_rigth_side_expression varchar2(10) := '[!-]'; + l_right_side_regex varchar2(50) := '([!-])([^!-].*)'; l_right_side varchar2(4000); l_tags varchar2(4000) := a_tags; @@ -1058,5 +1068,232 @@ create or replace package body ut_utils is return l_result; end; + procedure build_tag_expression_filter(a_tags in varchar2,a_expression_tab in out t_expression_tab,a_parent_id varchar2 default null) is + l_left_side_expression varchar2(10) := '[|&,]'; + l_left_side_regex varchar2(50) := '([^|&,]*)([|&,])(.*)'; + l_left_side varchar2(4000); + + l_rigth_side_expression varchar2(10) := '[!-]'; + l_right_side_regex varchar2(50) := '([!-])([^!-].*)'; + l_right_side varchar2(4000); + + l_tags varchar2(4000) := a_tags; + l_result number :=1; + l_expression_rec t_expression_rec; + + begin + if a_expression_tab is null then + a_expression_tab := t_expression_tab(); + end if; + + l_expression_rec.id := sys_guid(); + l_expression_rec.parent_id := a_parent_id; + + if instr(substr(l_tags,1,1),'(',1,1) + instr(substr(l_tags,-1,1),')',-1,1) = 2 then + + if regexp_count(l_tags,l_right_side_regex) = 1 then + l_expression_rec.negated :=1; + l_tags := trim (leading '!' from l_tags); + end if; + + l_expression_rec.left_bracket := 1; + l_tags := trim(leading '(' from l_tags); + l_expression_rec.right_bracket := 1; + l_tags := trim(trailing ')' from l_tags); + end if; + + + --Check if there are any left side operators for first in order from left to right + if regexp_count(l_tags,l_left_side_expression) > 0 then + --Extract left part of operator and remaining of string to right + + --if there are bracketc extract it and record it + + l_left_side := regexp_replace(l_tags,l_left_side_regex,'\1'); + l_expression_rec.log_operator := regexp_replace(l_tags,l_left_side_regex,'\2'); + l_right_side := regexp_replace(l_tags,l_left_side_regex,'\3'); + a_expression_tab.extend; + a_expression_tab(a_expression_tab.last) := l_expression_rec; + + build_tag_expression_filter(l_left_side,a_expression_tab,l_expression_rec.id); + build_tag_expression_filter(l_right_side,a_expression_tab,l_expression_rec.id); + + else + if instr(substr(l_tags,1,1),'(',1,1) + instr(substr(l_tags,-1,1),')',-1,1) = 2 then + + if regexp_count(l_tags,l_right_side_regex) = 1 then + l_expression_rec.negated :=1; + l_tags := trim (leading '!' from l_tags); + end if; + + l_expression_rec.left_bracket := 1; + l_tags := trim(leading '(' from l_tags); + l_expression_rec.right_bracket := 1; + l_tags := trim(trailing ')' from l_tags); + end if; + l_expression_rec.expression := l_tags; + a_expression_tab.extend; + a_expression_tab(a_expression_tab.last) := l_expression_rec; + end if; + + end; + + /* + https://stackoverflow.com/questions/29634992/shunting-yard-validate-expression + */ + function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list is + l_tags varchar2(32767) := a_tags; + l_operator_stack ut_stack := ut_stack(); + l_input_tokens ut_varchar2_list := ut_varchar2_list(); + l_rnp_tokens ut_varchar2_list := ut_varchar2_list(); + l_token varchar2(32767); + l_expect_operand boolean := true; + l_expect_operator boolean := false; + begin + --Tokenize a string into operators and tags + select regexp_substr(l_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts + bulk collect into l_input_tokens + from dual connect by regexp_substr (l_tags, '([^!()|&]+)|([!()|&])', 1, level) is not null; + + --Exuecute modified shunting algorithm + for token in 1..l_input_tokens.count loop + l_token := l_input_tokens(token); + if (l_token member of gc_operators and l_token member of gc_binary_operator) then + if not(l_expect_operator) then + raise ex_invalid_tag_expression; + end if; + while l_operator_stack.top > 0 and (g_precedence(l_operator_stack.peek) > g_precedence(l_token)) loop + l_rnp_tokens.extend; + l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; + end loop; + l_operator_stack.push(l_input_tokens(token)); + l_expect_operand := true; + l_expect_operator:= false; + elsif (l_token member of gc_operators and l_token member of gc_unary_operator) then + if not(l_expect_operand) then + raise ex_invalid_tag_expression; + end if; + l_operator_stack.push(l_input_tokens(token)); + l_expect_operand := true; + l_expect_operator:= false; + elsif l_token = '(' then + if not(l_expect_operand) then + raise ex_invalid_tag_expression; + end if; + l_operator_stack.push(l_input_tokens(token)); + l_expect_operand := true; + l_expect_operator:= false; + elsif l_token = ')' then + if not(l_expect_operator) then + raise ex_invalid_tag_expression; + end if; + while l_operator_stack.peek <> '(' loop + l_rnp_tokens.extend; + l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; + end loop; + l_operator_stack.pop; --Pop the open bracket and discard it + l_expect_operand := false; + l_expect_operator:= true; + else + if not(l_expect_operand) then + raise ex_invalid_tag_expression; + end if; + l_rnp_tokens.extend; + l_rnp_tokens(l_rnp_tokens.last) :=l_token; + l_expect_operator := true; + l_expect_operand := false; + end if; + + end loop; + + while l_operator_stack.top > 0 loop + if l_operator_stack.peek in ('(',')') then + raise ex_invalid_tag_expression; + end if; + l_rnp_tokens.extend; + l_rnp_tokens(l_rnp_tokens.last):=l_operator_stack.pop; + end loop; + + return l_rnp_tokens; + end shunt_logical_expression; + + procedure shunt_logical_expression(a_tags in varchar2) is + a_postfix ut_varchar2_list; + begin + a_postfix := ut_utils.shunt_logical_expression(a_tags); + end shunt_logical_expression; + + function convert_postfix_to_infix(a_postfix_exp in ut_varchar2_list) + return varchar2 is + l_infix_stack ut_stack := ut_stack(); + l_right_side varchar2(32767); + l_left_side varchar2(32767); + l_infix_exp varchar2(32767); + begin + for i in 1..a_postfix_exp.count loop + --If token is operand but also single tag + if a_postfix_exp(i) not member of gc_operators then --its operand + l_infix_stack.push(a_postfix_exp(i)); + --If token is unary operator not + elsif a_postfix_exp(i) member of gc_unary_operator then + l_right_side := l_infix_stack.pop; + l_infix_exp := '('||a_postfix_exp(i)||l_right_side||')'; + l_infix_stack.push(l_infix_exp); + --If token is binary operator + elsif a_postfix_exp(i) member of gc_binary_operator then + l_right_side := l_infix_stack.pop; + l_left_side := l_infix_stack.pop; + l_infix_exp := '('||l_left_side||a_postfix_exp(i)||l_right_side||')'; + l_infix_stack.push(l_infix_exp); + else + null; + end if; + end loop; + + return l_infix_stack.pop; + end; + + function convert_postfix_to_infix_where_sql(a_postfix_exp in ut_varchar2_list) + return varchar2 is + l_infix_stack ut_stack := ut_stack(); + l_right_side varchar2(32767); + l_left_side varchar2(32767); + l_infix_exp varchar2(32767); + l_member_token varchar2(20) := ' member of tags'; + begin + for i in 1..a_postfix_exp.count loop + --If token is operand but also single tag + if regexp_count(a_postfix_exp(i),'[!()|&]') = 0 then + l_infix_stack.push(q'[']'||a_postfix_exp(i)||q'[']'||l_member_token); + --If token is operand but containing other expressions + elsif a_postfix_exp(i) not member of gc_operators then + l_infix_stack.push(a_postfix_exp(i)); + --If token is unary operator not + elsif a_postfix_exp(i) member of gc_unary_operator then + l_right_side := l_infix_stack.pop; + l_infix_exp := a_postfix_exp(i)||'('||l_right_side||')'; + l_infix_stack.push(l_infix_exp); + --If token is binary operator + elsif a_postfix_exp(i) member of gc_binary_operator then + l_right_side := l_infix_stack.pop; + l_left_side := l_infix_stack.pop; + l_infix_exp := '('||l_left_side||a_postfix_exp(i)||l_right_side||')'; + l_infix_stack.push(l_infix_exp); + else + null; + end if; + end loop; + + return l_infix_stack.pop; + end; + +begin + --Define operator precedence + g_precedence('!'):=4; + g_precedence('&'):=3; + g_precedence('|'):=2; + g_precedence(')'):=1; + g_precedence('('):=1; + end ut_utils; / diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index e84818cba..2212454f4 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -482,5 +482,30 @@ create or replace package ut_utils authid definer is */ function valid_tag_expression(a_tags in varchar2) return number; + /* + * Return number 1 or 0 if the list of tags is valid expression + */ + procedure build_tag_expression_filter(a_tags in varchar2,a_expression_tab in out t_expression_tab,a_parent_id varchar2 default null); + + /* + * Function that uses Dijkstra algorithm to parse mathematical and logical expression + * and return a list of elements in Reverse Polish Notation ( postfix ) + * As part of execution it will validate expression. + */ + function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list; + + procedure shunt_logical_expression(a_tags in varchar2); + + /* + * Function that converts postfix notation into infix + */ + function convert_postfix_to_infix(a_postfix_exp in ut_varchar2_list) return varchar2; + + /* + * Function that converts postfix notation into infix and creating a string of sql filter + * that checking a tags collections for tags according to posted logic. + */ + function convert_postfix_to_infix_where_sql(a_postfix_exp in ut_varchar2_list) return varchar2; + end ut_utils; / diff --git a/source/install.sql b/source/install.sql index 0873d6a1e..a54977f94 100644 --- a/source/install.sql +++ b/source/install.sql @@ -50,6 +50,8 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/types/ut_key_value_pairs.tps' @@install_component.sql 'core/types/ut_reporter_info.tps' @@install_component.sql 'core/types/ut_reporters_info.tps' +@@install_component.sql 'core/types/ut_stack.tps' +@@install_component.sql 'core/types/ut_stack.tpb' @@install_component.sql 'core/ut_utils.pks' @@install_component.sql 'core/ut_metadata.pks' @@install_component.sql 'core/ut_savepoint_seq.sql' diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 84dd11f9c..7eb377f4b 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1250,7 +1250,7 @@ procedure tag_exclude_run_fun_pth_lst_lg is procedure invalid_tag_expression is l_results ut3_develop.ut_varchar2_list; begin - l_results := ut3_tester_helper.run_helper.run(a_tags => '(!!development&end_to_end)'); + l_results := ut3_tester_helper.run_helper.run(a_tags => '(!development!&end_to_end)'); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); From f51cc993be376e456758b73a21680591fa9130d9 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 9 Apr 2023 18:52:21 -0700 Subject: [PATCH 420/887] Missing slash at end of type --- source/core/types/ut_stack.tps | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/types/ut_stack.tps b/source/core/types/ut_stack.tps index 9851b9cc5..7b8c145c2 100644 --- a/source/core/types/ut_stack.tps +++ b/source/core/types/ut_stack.tps @@ -23,4 +23,4 @@ create or replace type ut_stack as object ( member procedure pop(self in out nocopy ut_stack,a_cnt in integer default 1), member function pop(self in out nocopy ut_stack) return varchar2 ) - +/ \ No newline at end of file From 4b8e2ab124d7819b2a8a442b9fcd31d6d5d5666e Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 9 Apr 2023 21:26:13 -0700 Subject: [PATCH 421/887] Cleanup. Fix object name length. --- source/core/ut_suite_cache_manager.pkb | 2 +- source/core/ut_utils.pkb | 144 +------------------------ source/core/ut_utils.pks | 12 +-- 3 files changed, 5 insertions(+), 153 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index ae5460ef6..aea8c667e 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -268,7 +268,7 @@ create or replace package body ut_suite_cache_manager is if instr(l_tags,',') > 0 or instr(l_tags,'-') > 0 then l_tags := replace(replace_legacy_tag_notation(l_tags),' '); end if; - l_tags := ut_utils.convert_postfix_to_infix_where_sql(ut_utils.shunt_logical_expression(l_tags)); + l_tags := ut_utils.convert_postfix_to_infix(ut_utils.shunt_logical_expression(l_tags)); l_tags := REPLACE(l_tags, '|',' or '); l_tags := REPLACE(l_tags ,'&',' and '); l_tags := REPLACE(l_tags ,'!','not'); diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index c09c15221..028a0c756 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -1000,144 +1000,6 @@ create or replace package body ut_utils is return l_result; end; - /* - Purpose of this function is to break down the tag expressions - We can separate operators on left and rigth side. - Left ones are AND and OR as they require an operator on left side to - be valid. Right side is NOT. - In each iteration we breakdown string into parts - - */ - function valid_tag_expression(a_tags in varchar2) return number is - l_left_side_expression varchar2(10) := '[|&,]'; - l_left_side_regex varchar2(50) := '([^|&,]*)[|&,](.*)'; - l_left_side varchar2(4000); - - l_rigth_side_expression varchar2(10) := '[!-]'; - l_right_side_regex varchar2(50) := '([!-])([^!-].*)'; - l_right_side varchar2(4000); - - l_tags varchar2(4000) := a_tags; - l_result number :=1; - begin - --Validate that we have closed up all brackets - if regexp_count(l_tags,'\(') <> regexp_count(l_tags,'\)') then - l_result := 0; - end if; - - --Remove brackets as we dont evaluate expression only validate. - l_tags := replace(replace(l_tags,'('),')'); - - --Check if there are any left side operators for first in order from left to right - if regexp_count(l_tags,l_left_side_expression) > 0 then - --Extract left part of operator and remaining of string to right - l_left_side := regexp_replace(l_tags,l_left_side_regex,'\1'); - l_right_side := regexp_replace(l_tags,l_left_side_regex,'\2'); - - --If left side is null that means that we used left side operator without - -- left and right e.g. |test - if l_left_side is null then - l_result := 0; - else - --Extract right side from left side expression if there is any !- - --Remove first negation tag to see if there is double negation - l_left_side := regexp_replace(l_left_side,l_right_side_regex,'\2'); - end if; - - - --check that on right side there is no extra negation - if regexp_count(l_left_side,l_rigth_side_expression) > 0 then - l_result := 0; - end if; - - --Now process right side of string - if l_right_side is not null then - l_result := least(l_result,valid_tag_expression(l_right_side)); - else - l_result := 0; - end if; - else - --We just process single tag. - l_left_side := l_tags; - l_left_side := regexp_replace(l_left_side,l_right_side_regex,'\2'); - if regexp_count(l_left_side,l_rigth_side_expression) > 0 then - l_result := 0; - end if; - end if; - - return l_result; - end; - - procedure build_tag_expression_filter(a_tags in varchar2,a_expression_tab in out t_expression_tab,a_parent_id varchar2 default null) is - l_left_side_expression varchar2(10) := '[|&,]'; - l_left_side_regex varchar2(50) := '([^|&,]*)([|&,])(.*)'; - l_left_side varchar2(4000); - - l_rigth_side_expression varchar2(10) := '[!-]'; - l_right_side_regex varchar2(50) := '([!-])([^!-].*)'; - l_right_side varchar2(4000); - - l_tags varchar2(4000) := a_tags; - l_result number :=1; - l_expression_rec t_expression_rec; - - begin - if a_expression_tab is null then - a_expression_tab := t_expression_tab(); - end if; - - l_expression_rec.id := sys_guid(); - l_expression_rec.parent_id := a_parent_id; - - if instr(substr(l_tags,1,1),'(',1,1) + instr(substr(l_tags,-1,1),')',-1,1) = 2 then - - if regexp_count(l_tags,l_right_side_regex) = 1 then - l_expression_rec.negated :=1; - l_tags := trim (leading '!' from l_tags); - end if; - - l_expression_rec.left_bracket := 1; - l_tags := trim(leading '(' from l_tags); - l_expression_rec.right_bracket := 1; - l_tags := trim(trailing ')' from l_tags); - end if; - - - --Check if there are any left side operators for first in order from left to right - if regexp_count(l_tags,l_left_side_expression) > 0 then - --Extract left part of operator and remaining of string to right - - --if there are bracketc extract it and record it - - l_left_side := regexp_replace(l_tags,l_left_side_regex,'\1'); - l_expression_rec.log_operator := regexp_replace(l_tags,l_left_side_regex,'\2'); - l_right_side := regexp_replace(l_tags,l_left_side_regex,'\3'); - a_expression_tab.extend; - a_expression_tab(a_expression_tab.last) := l_expression_rec; - - build_tag_expression_filter(l_left_side,a_expression_tab,l_expression_rec.id); - build_tag_expression_filter(l_right_side,a_expression_tab,l_expression_rec.id); - - else - if instr(substr(l_tags,1,1),'(',1,1) + instr(substr(l_tags,-1,1),')',-1,1) = 2 then - - if regexp_count(l_tags,l_right_side_regex) = 1 then - l_expression_rec.negated :=1; - l_tags := trim (leading '!' from l_tags); - end if; - - l_expression_rec.left_bracket := 1; - l_tags := trim(leading '(' from l_tags); - l_expression_rec.right_bracket := 1; - l_tags := trim(trailing ')' from l_tags); - end if; - l_expression_rec.expression := l_tags; - a_expression_tab.extend; - a_expression_tab(a_expression_tab.last) := l_expression_rec; - end if; - - end; - /* https://stackoverflow.com/questions/29634992/shunting-yard-validate-expression */ @@ -1251,9 +1113,9 @@ create or replace package body ut_utils is end loop; return l_infix_stack.pop; - end; + end convert_postfix_to_infix; - function convert_postfix_to_infix_where_sql(a_postfix_exp in ut_varchar2_list) + function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list) return varchar2 is l_infix_stack ut_stack := ut_stack(); l_right_side varchar2(32767); @@ -1285,7 +1147,7 @@ create or replace package body ut_utils is end loop; return l_infix_stack.pop; - end; + end conv_postfix_to_infix_sql; begin --Define operator precedence diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 2212454f4..4bc35466d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -477,16 +477,6 @@ create or replace package ut_utils authid definer is */ function interval_to_text(a_interval yminterval_unconstrained) return varchar2; - /* - * Return number 1 or 0 if the list of tags is valid expression - */ - function valid_tag_expression(a_tags in varchar2) return number; - - /* - * Return number 1 or 0 if the list of tags is valid expression - */ - procedure build_tag_expression_filter(a_tags in varchar2,a_expression_tab in out t_expression_tab,a_parent_id varchar2 default null); - /* * Function that uses Dijkstra algorithm to parse mathematical and logical expression * and return a list of elements in Reverse Polish Notation ( postfix ) @@ -505,7 +495,7 @@ create or replace package ut_utils authid definer is * Function that converts postfix notation into infix and creating a string of sql filter * that checking a tags collections for tags according to posted logic. */ - function convert_postfix_to_infix_where_sql(a_postfix_exp in ut_varchar2_list) return varchar2; + function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list) return varchar2; end ut_utils; / From 84e8684004ddbcc95318e24903fae9fd046bf12a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 10 Apr 2023 13:29:07 -0700 Subject: [PATCH 422/887] Update tests after removed function --- test/ut3_tester/core/test_ut_utils.pkb | 27 -------------------------- test/ut3_tester/core/test_ut_utils.pks | 3 --- 2 files changed, 30 deletions(-) diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 8a497b9f1..ec7e4f403 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -489,32 +489,5 @@ end; ut.expect(l_expected).to_equal(l_actual); end; - procedure valid_tag_expressions is - begin - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1&tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|!tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1&!tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1|!tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1&!tag2')); - - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1,tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('-tag1')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1,-tag2')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('-tag1,-tag2')); - - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('(!tag1|!tag2)|tag3')); - ut.expect(1).to_equal(ut3_develop.ut_utils.valid_tag_expression('(!tag1&!tag2)|(tag3&tag4)')); - - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('tag1|')); - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('&!tag2')); - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('!!tag1|!tag2')); - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('!tag1&!tag2|')); - ut.expect(0).to_equal(ut3_develop.ut_utils.valid_tag_expression('((!tag1|!tag2)|tag3')); - - end; - end test_ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index 0f8545a45..4d83b5042 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -157,8 +157,5 @@ create or replace package test_ut_utils is --%endcontext - --%test(Test to validate different type of expressions passed as tags) - procedure valid_tag_expressions; - end test_ut_utils; / From 2e7a766f6169d0ad104448166ff3d0c84280b3e3 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 10 Apr 2023 13:57:54 -0700 Subject: [PATCH 423/887] Tidy up tests --- source/core/ut_suite_cache_manager.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index aea8c667e..a9153c7bd 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -268,7 +268,7 @@ create or replace package body ut_suite_cache_manager is if instr(l_tags,',') > 0 or instr(l_tags,'-') > 0 then l_tags := replace(replace_legacy_tag_notation(l_tags),' '); end if; - l_tags := ut_utils.convert_postfix_to_infix(ut_utils.shunt_logical_expression(l_tags)); + l_tags := ut_utils.conv_postfix_to_infix_sql(ut_utils.shunt_logical_expression(l_tags)); l_tags := REPLACE(l_tags, '|',' or '); l_tags := REPLACE(l_tags ,'&',' and '); l_tags := REPLACE(l_tags ,'!','not'); From cbdf83aee9491bd39e4bc06f74f72745fd5a6ef3 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 10 Apr 2023 14:02:57 -0700 Subject: [PATCH 424/887] Added ut_stack to uninstall --- source/uninstall_objects.sql | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 9531736b9..1e21f0f95 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -267,6 +267,8 @@ end; drop package ut_utils; +drop type ut_stack force; + drop sequence ut_savepoint_seq; drop type ut_documentation_reporter force; From 436eb5bed919df6b512688511a6d121a71c3a320 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 10 Apr 2023 18:00:07 -0700 Subject: [PATCH 425/887] Addressing test failures and sonar smells --- source/core/ut_utils.pkb | 51 +++++++++++++++----------- test/ut3_tester/core/test_ut_utils.pkb | 35 ++++++++++++++++++ test/ut3_tester/core/test_ut_utils.pks | 6 +++ 3 files changed, 71 insertions(+), 21 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 028a0c756..ac5f25645 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -1011,15 +1011,17 @@ create or replace package body ut_utils is l_token varchar2(32767); l_expect_operand boolean := true; l_expect_operator boolean := false; + l_idx pls_integer; begin --Tokenize a string into operators and tags select regexp_substr(l_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts bulk collect into l_input_tokens from dual connect by regexp_substr (l_tags, '([^!()|&]+)|([!()|&])', 1, level) is not null; + l_idx := l_input_tokens.first; --Exuecute modified shunting algorithm - for token in 1..l_input_tokens.count loop - l_token := l_input_tokens(token); + WHILE (l_idx is not null) loop + l_token := l_input_tokens(l_idx); if (l_token member of gc_operators and l_token member of gc_binary_operator) then if not(l_expect_operator) then raise ex_invalid_tag_expression; @@ -1028,21 +1030,21 @@ create or replace package body ut_utils is l_rnp_tokens.extend; l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; end loop; - l_operator_stack.push(l_input_tokens(token)); + l_operator_stack.push(l_input_tokens(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif (l_token member of gc_operators and l_token member of gc_unary_operator) then if not(l_expect_operand) then raise ex_invalid_tag_expression; end if; - l_operator_stack.push(l_input_tokens(token)); + l_operator_stack.push(l_input_tokens(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif l_token = '(' then if not(l_expect_operand) then raise ex_invalid_tag_expression; end if; - l_operator_stack.push(l_input_tokens(token)); + l_operator_stack.push(l_input_tokens(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif l_token = ')' then @@ -1066,6 +1068,7 @@ create or replace package body ut_utils is l_expect_operand := false; end if; + l_idx := l_input_tokens.next(l_idx); end loop; while l_operator_stack.top > 0 loop @@ -1091,25 +1094,28 @@ create or replace package body ut_utils is l_right_side varchar2(32767); l_left_side varchar2(32767); l_infix_exp varchar2(32767); + l_idx pls_integer; begin - for i in 1..a_postfix_exp.count loop + l_idx := a_postfix_exp.first; + while (l_idx is not null) loop --If token is operand but also single tag - if a_postfix_exp(i) not member of gc_operators then --its operand - l_infix_stack.push(a_postfix_exp(i)); + if a_postfix_exp(l_idx) not member of gc_operators then --its operand + l_infix_stack.push(a_postfix_exp(l_idx)); --If token is unary operator not - elsif a_postfix_exp(i) member of gc_unary_operator then + elsif a_postfix_exp(l_idx) member of gc_unary_operator then l_right_side := l_infix_stack.pop; - l_infix_exp := '('||a_postfix_exp(i)||l_right_side||')'; + l_infix_exp := '('||a_postfix_exp(l_idx)||l_right_side||')'; l_infix_stack.push(l_infix_exp); --If token is binary operator - elsif a_postfix_exp(i) member of gc_binary_operator then + elsif a_postfix_exp(l_idx) member of gc_binary_operator then l_right_side := l_infix_stack.pop; l_left_side := l_infix_stack.pop; - l_infix_exp := '('||l_left_side||a_postfix_exp(i)||l_right_side||')'; + l_infix_exp := '('||l_left_side||a_postfix_exp(l_idx)||l_right_side||')'; l_infix_stack.push(l_infix_exp); else null; end if; + l_idx := a_postfix_exp.next(l_idx); end loop; return l_infix_stack.pop; @@ -1122,28 +1128,31 @@ create or replace package body ut_utils is l_left_side varchar2(32767); l_infix_exp varchar2(32767); l_member_token varchar2(20) := ' member of tags'; + l_idx pls_integer; begin - for i in 1..a_postfix_exp.count loop + l_idx := a_postfix_exp.first; + while ( l_idx is not null) loop --If token is operand but also single tag - if regexp_count(a_postfix_exp(i),'[!()|&]') = 0 then - l_infix_stack.push(q'[']'||a_postfix_exp(i)||q'[']'||l_member_token); + if regexp_count(a_postfix_exp(l_idx),'[!()|&]') = 0 then + l_infix_stack.push(q'[']'||a_postfix_exp(l_idx)||q'[']'||l_member_token); --If token is operand but containing other expressions - elsif a_postfix_exp(i) not member of gc_operators then - l_infix_stack.push(a_postfix_exp(i)); + elsif a_postfix_exp(l_idx) not member of gc_operators then + l_infix_stack.push(a_postfix_exp(l_idx)); --If token is unary operator not - elsif a_postfix_exp(i) member of gc_unary_operator then + elsif a_postfix_exp(l_idx) member of gc_unary_operator then l_right_side := l_infix_stack.pop; - l_infix_exp := a_postfix_exp(i)||'('||l_right_side||')'; + l_infix_exp := a_postfix_exp(l_idx)||'('||l_right_side||')'; l_infix_stack.push(l_infix_exp); --If token is binary operator - elsif a_postfix_exp(i) member of gc_binary_operator then + elsif a_postfix_exp(l_idx) member of gc_binary_operator then l_right_side := l_infix_stack.pop; l_left_side := l_infix_stack.pop; - l_infix_exp := '('||l_left_side||a_postfix_exp(i)||l_right_side||')'; + l_infix_exp := '('||l_left_side||a_postfix_exp(l_idx)||l_right_side||')'; l_infix_stack.push(l_infix_exp); else null; end if; + l_idx := a_postfix_exp.next(l_idx); end loop; return l_infix_stack.pop; diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index ec7e4f403..1f64c621e 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -489,5 +489,40 @@ end; ut.expect(l_expected).to_equal(l_actual); end; + + procedure test_conversion_to_rpn is + l_postfix ut3_develop.ut_varchar2_list; + l_postfix_string varchar2(4000); + begin + l_postfix := ut3_develop.ut_utils.shunt_logical_expression('A'); + l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); + ut.expect(l_postfix_string).to_equal('A'); + + l_postfix := ut3_develop.ut_utils.shunt_logical_expression('A|B'); + l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); + ut.expect(l_postfix_string).to_equal('AB|'); + + l_postfix := ut3_develop.ut_utils.shunt_logical_expression('(a|b)|c&d'); + l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); + ut.expect(l_postfix_string).to_equal('ab|cd&|'); + end; + + procedure test_conversion_from_rpn_to_infix is + l_postfix_rpn ut3_develop.ut_varchar2_list; + l_infix_string varchar2(4000); + begin + l_postfix_rpn := ut3_develop.ut_varchar2_list('A'); + l_infix_string := ut3_develop.ut_utils.convert_postfix_to_infix(l_postfix_rpn); + ut.expect(l_infix_string).to_equal('A'); + + l_postfix_rpn := ut3_develop.ut_varchar2_list('A','B','|'); + l_infix_string := ut3_develop.ut_utils.convert_postfix_to_infix(l_postfix_rpn); + ut.expect(l_infix_string).to_equal('(A|B)'); + + l_postfix_rpn := ut3_develop.ut_varchar2_list('a','b','|','c','d','&','|'); + l_infix_string := ut3_develop.ut_utils.convert_postfix_to_infix(l_postfix_rpn); + ut.expect(l_infix_string).to_equal('((a|b)|(c&d))'); + end; + end test_ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index 4d83b5042..7bfd9b36e 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -156,6 +156,12 @@ create or replace package test_ut_utils is --%endcontext + + --%test( Test conversion of expression into Reverse Polish Notation) + procedure test_conversion_to_rpn; + + --%test( Test conversion of expression from Reverse Polish Notation into infix) + procedure test_conversion_from_rpn_to_infix; end test_ut_utils; / From 3d77514448e9720ad11589343d171723ad8f1c72 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 10 Apr 2023 18:08:42 -0700 Subject: [PATCH 426/887] Update name --- test/ut3_tester/core/test_ut_utils.pkb | 2 +- test/ut3_tester/core/test_ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 1f64c621e..126ada89c 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -507,7 +507,7 @@ end; ut.expect(l_postfix_string).to_equal('ab|cd&|'); end; - procedure test_conversion_from_rpn_to_infix is + procedure test_conv_from_rpn_to_infix is l_postfix_rpn ut3_develop.ut_varchar2_list; l_infix_string varchar2(4000); begin diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index 7bfd9b36e..6d11f65d1 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -161,7 +161,7 @@ create or replace package test_ut_utils is procedure test_conversion_to_rpn; --%test( Test conversion of expression from Reverse Polish Notation into infix) - procedure test_conversion_from_rpn_to_infix; + procedure test_conv_from_rpn_to_infix; end test_ut_utils; / From bf6959fc63c4c36ff24f62d28e8a5b1d6b323ce4 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 10 Apr 2023 20:39:25 -0700 Subject: [PATCH 427/887] Update tests and code --- source/core/ut_utils.pkb | 30 +++++++++++--------------- source/core/ut_utils.pks | 7 ++++-- test/ut3_tester/core/test_ut_utils.pkb | 29 +++++++++++++++++++++++-- test/ut3_tester/core/test_ut_utils.pks | 3 +++ test/ut3_user/api/test_ut_run.pkb | 15 ++++++++++++- 5 files changed, 62 insertions(+), 22 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index ac5f25645..1c99a3a42 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -1000,24 +1000,30 @@ create or replace package body ut_utils is return l_result; end; + function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list is + l_tags_tokens ut_varchar2_list := ut_varchar2_list(); + begin + --Tokenize a string into operators and tags + select regexp_substr(a_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts + bulk collect into l_tags_tokens + from dual connect by regexp_substr (a_tags, '([^!()|&]+)|([!()|&])', 1, level) is not null; + + return l_tags_tokens; + end; + /* https://stackoverflow.com/questions/29634992/shunting-yard-validate-expression */ function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list is l_tags varchar2(32767) := a_tags; l_operator_stack ut_stack := ut_stack(); - l_input_tokens ut_varchar2_list := ut_varchar2_list(); + l_input_tokens ut_varchar2_list := tokenize_tags_string(a_tags); l_rnp_tokens ut_varchar2_list := ut_varchar2_list(); l_token varchar2(32767); l_expect_operand boolean := true; l_expect_operator boolean := false; l_idx pls_integer; begin - --Tokenize a string into operators and tags - select regexp_substr(l_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts - bulk collect into l_input_tokens - from dual connect by regexp_substr (l_tags, '([^!()|&]+)|([!()|&])', 1, level) is not null; - l_idx := l_input_tokens.first; --Exuecute modified shunting algorithm WHILE (l_idx is not null) loop @@ -1071,7 +1077,7 @@ create or replace package body ut_utils is l_idx := l_input_tokens.next(l_idx); end loop; - while l_operator_stack.top > 0 loop + while l_operator_stack.peek is not null loop if l_operator_stack.peek in ('(',')') then raise ex_invalid_tag_expression; end if; @@ -1082,12 +1088,6 @@ create or replace package body ut_utils is return l_rnp_tokens; end shunt_logical_expression; - procedure shunt_logical_expression(a_tags in varchar2) is - a_postfix ut_varchar2_list; - begin - a_postfix := ut_utils.shunt_logical_expression(a_tags); - end shunt_logical_expression; - function convert_postfix_to_infix(a_postfix_exp in ut_varchar2_list) return varchar2 is l_infix_stack ut_stack := ut_stack(); @@ -1112,8 +1112,6 @@ create or replace package body ut_utils is l_left_side := l_infix_stack.pop; l_infix_exp := '('||l_left_side||a_postfix_exp(l_idx)||l_right_side||')'; l_infix_stack.push(l_infix_exp); - else - null; end if; l_idx := a_postfix_exp.next(l_idx); end loop; @@ -1149,8 +1147,6 @@ create or replace package body ut_utils is l_left_side := l_infix_stack.pop; l_infix_exp := '('||l_left_side||a_postfix_exp(l_idx)||l_right_side||')'; l_infix_stack.push(l_infix_exp); - else - null; end if; l_idx := a_postfix_exp.next(l_idx); end loop; diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4bc35466d..67b09b2f9 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -476,6 +476,11 @@ create or replace package ut_utils authid definer is * Return value of interval in plain english */ function interval_to_text(a_interval yminterval_unconstrained) return varchar2; + + /* + * Return table of tokens character by character + */ + function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list; /* * Function that uses Dijkstra algorithm to parse mathematical and logical expression @@ -484,8 +489,6 @@ create or replace package ut_utils authid definer is */ function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list; - procedure shunt_logical_expression(a_tags in varchar2); - /* * Function that converts postfix notation into infix */ diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 126ada89c..22733c4ce 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -504,7 +504,11 @@ end; l_postfix := ut3_develop.ut_utils.shunt_logical_expression('(a|b)|c&d'); l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); - ut.expect(l_postfix_string).to_equal('ab|cd&|'); + ut.expect(l_postfix_string).to_equal('ab|cd&|'); + + l_postfix := ut3_develop.ut_utils.shunt_logical_expression('!a|b'); + l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); + ut.expect(l_postfix_string).to_equal('a!b|'); end; procedure test_conv_from_rpn_to_infix is @@ -521,7 +525,28 @@ end; l_postfix_rpn := ut3_develop.ut_varchar2_list('a','b','|','c','d','&','|'); l_infix_string := ut3_develop.ut_utils.convert_postfix_to_infix(l_postfix_rpn); - ut.expect(l_infix_string).to_equal('((a|b)|(c&d))'); + ut.expect(l_infix_string).to_equal('((a|b)|(c&d))'); + + l_postfix_rpn := ut3_develop.ut_varchar2_list('a','b','!','|'); + l_infix_string := ut3_develop.ut_utils.convert_postfix_to_infix(l_postfix_rpn); + ut.expect(l_infix_string).to_equal('(a|(!b))'); + end; + + procedure conv_from_rpn_to_sql_filter is + l_postfix_rpn ut3_develop.ut_varchar2_list; + l_infix_string varchar2(4000); + begin + l_postfix_rpn := ut3_develop.ut_varchar2_list('A'); + l_infix_string := ut3_develop.ut_utils.conv_postfix_to_infix_sql(l_postfix_rpn); + ut.expect(l_infix_string).to_equal(q'['A' member of tags]'); + + l_postfix_rpn := ut3_develop.ut_varchar2_list('A','B','|'); + l_infix_string := ut3_develop.ut_utils.conv_postfix_to_infix_sql(l_postfix_rpn); + ut.expect(l_infix_string).to_equal(q'[('A' member of tags|'B' member of tags)]'); + + l_postfix_rpn := ut3_develop.ut_varchar2_list('a','b','!','|'); + l_infix_string := ut3_develop.ut_utils.conv_postfix_to_infix_sql(l_postfix_rpn); + ut.expect(l_infix_string).to_equal(q'[('a' member of tags|!('b' member of tags))]'); end; end test_ut_utils; diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index 6d11f65d1..1561e1136 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -163,5 +163,8 @@ create or replace package test_ut_utils is --%test( Test conversion of expression from Reverse Polish Notation into infix) procedure test_conv_from_rpn_to_infix; + --%test( Test conversion of expression from Reverse Polish Notation into custom where filter for SQL) + procedure conv_from_rpn_to_sql_filter; + end test_ut_utils; / diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 7eb377f4b..25b50343e 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1260,7 +1260,20 @@ procedure tag_exclude_run_fun_pth_lst_lg is l_results := ut3_tester_helper.run_helper.run(a_tags => '(!development&end_to_end|)'); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); - ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); + + l_results := ut3_tester_helper.run_helper.run(a_tags => '(!development&!!end_to_end)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); + + l_results := ut3_tester_helper.run_helper.run(a_tags => '(&development&end_to_end)'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); + + l_results := ut3_tester_helper.run_helper.run(a_tags => '(development|end_to_end))'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); + end; procedure set_application_info is From d8233ff6587f81c0a0a6430a4f33747bc2723983 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 11 Apr 2023 20:33:04 -0700 Subject: [PATCH 428/887] fixing typo in docs --- docs/userguide/annotations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 4017521b5..8e5a5d1ca 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1684,7 +1684,7 @@ Execution of the test is done by using the parameter `a_tags` with tag expressio ```sql linenums="1" -select * from table(ut.run(a_tags => 'fast||!complex')); +select * from table(ut.run(a_tags => 'fast|!complex')); ``` The above call will execute all tests from `ut_sample_test` package as the whole suite is tagged with `api` because a suite meet expression condition. From bd860f602d458575d00010834e5ca28058ec09cb Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 11 Apr 2023 20:55:34 -0700 Subject: [PATCH 429/887] Removed unused variable --- source/core/ut_utils.pkb | 1 - 1 file changed, 1 deletion(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 1c99a3a42..a8528fa86 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -1015,7 +1015,6 @@ create or replace package body ut_utils is https://stackoverflow.com/questions/29634992/shunting-yard-validate-expression */ function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list is - l_tags varchar2(32767) := a_tags; l_operator_stack ut_stack := ut_stack(); l_input_tokens ut_varchar2_list := tokenize_tags_string(a_tags); l_rnp_tokens ut_varchar2_list := ut_varchar2_list(); From e6a6a4cbf108b44932fb114c07e2d18f62ee687f Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 12 Apr 2023 19:54:56 +0300 Subject: [PATCH 430/887] Improvements to teamcity reporter (used by DataGrip and IntelliJ - JetBrains IDEs) The reporter will now report all errors and all failed expectations. The test description will be used instead of test name. --- source/reporters/ut_teamcity_reporter.tpb | 33 +++++++++------- .../reporters/ut_teamcity_reporter_helper.pkb | 2 - .../reporters/test_teamcity_reporter.pkb | 39 +++++++++++++++++-- .../reporters/test_teamcity_reporter.pks | 3 ++ 4 files changed, 58 insertions(+), 19 deletions(-) diff --git a/source/reporters/ut_teamcity_reporter.tpb b/source/reporters/ut_teamcity_reporter.tpb index 95bea32b8..e05dc994f 100644 --- a/source/reporters/ut_teamcity_reporter.tpb +++ b/source/reporters/ut_teamcity_reporter.tpb @@ -108,23 +108,28 @@ create or replace type body ut_teamcity_reporter is ut_teamcity_reporter_helper.test_failed( a_test_name => l_test_full_name, a_msg => 'Error occured', - a_details => - trim(l_std_err_msg) - || case when a_test.failed_expectations is not null - and a_test.failed_expectations.count>0 - then a_test.failed_expectations(1).message end + a_details => trim(l_std_err_msg) ) ); + for i in 1 .. a_test.failed_expectations.count loop + ut_utils.append_to_list( + l_results, + ut_teamcity_reporter_helper.test_failed( + a_test_name => l_test_full_name, + a_msg => a_test.failed_expectations(i).description, + a_details => a_test.failed_expectations(i).message ) + ); + end loop; elsif a_test.failed_expectations is not null and a_test.failed_expectations.count > 0 then - -- Teamcity supports only a single failure message - - ut_utils.append_to_list( - l_results, - ut_teamcity_reporter_helper.test_failed( - a_test_name => l_test_full_name, - a_msg => a_test.failed_expectations(a_test.failed_expectations.first).description, - a_details => a_test.failed_expectations(a_test.failed_expectations.first).message ) - ); + for i in 1 .. a_test.failed_expectations.count loop + ut_utils.append_to_list( + l_results, + ut_teamcity_reporter_helper.test_failed( + a_test_name => l_test_full_name, + a_msg => a_test.failed_expectations(i).description, + a_details => a_test.failed_expectations(i).message ) + ); + end loop; elsif a_test.result = ut_utils.gc_failure then ut_utils.append_to_list( l_results, diff --git a/source/reporters/ut_teamcity_reporter_helper.pkb b/source/reporters/ut_teamcity_reporter_helper.pkb index 84a9d19e8..1633d10aa 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pkb +++ b/source/reporters/ut_teamcity_reporter_helper.pkb @@ -73,8 +73,6 @@ create or replace package body ut_teamcity_reporter_helper is 'true' when false then 'false' - else - null end; l_props('flowId') := a_flow_id; return message('testStarted', l_props); diff --git a/test/ut3_user/reporters/test_teamcity_reporter.pkb b/test/ut3_user/reporters/test_teamcity_reporter.pkb index ff550e488..cf7a925a1 100644 --- a/test/ut3_user/reporters/test_teamcity_reporter.pkb +++ b/test/ut3_user/reporters/test_teamcity_reporter.pkb @@ -31,12 +31,26 @@ create or replace package body test_teamcity_reporter as end; end;]'; + execute immediate q'[create or replace package check_multiple_failures is + --%suite + + --%test + procedure multi_failure; + end;]'; + execute immediate q'[create or replace package body check_multiple_failures is + procedure multi_failure is + begin + ut3_develop.ut.expect(1).to_be_null; + ut3_develop.ut.expect(2).to_equal(1); + ut3_develop.ut.expect('Bad').to_equal('Good'); + end; + end;]'; + end; procedure report_produces_expected_out is l_output_data ut3_develop.ut_varchar2_list; - l_output clob; l_expected varchar2(32767); begin l_expected := q'{%##teamcity[testSuiteStarted timestamp='%' name='org'] @@ -84,7 +98,6 @@ create or replace package body test_teamcity_reporter as procedure escape_special_chars is l_output_data ut3_develop.ut_varchar2_list; - l_output clob; l_expected varchar2(32767); begin l_expected := q'{%##teamcity[testSuiteStarted timestamp='%' name='A suite with |'quote|''] @@ -103,7 +116,6 @@ create or replace package body test_teamcity_reporter as procedure trims_long_output is l_output_data ut3_develop.ut_varchar2_list; - l_output clob; l_expected varchar2(32767); begin l_expected := q'{%##teamcity[testSuiteStarted timestamp='%' name='check_trims_long_output'] @@ -120,11 +132,32 @@ create or replace package body test_teamcity_reporter as ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); end; + procedure report_mutiple_expectations is + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'{%##teamcity[testSuiteStarted timestamp='%' name='check_multiple_failures'] +%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3_user.check_multiple_failures.multi_failure'] +%##teamcity[testFailed timestamp='%' details='Actual: 1 (number) was expected to be null' name='ut3_user.check_multiple_failures.multi_failure'] +%##teamcity[testFailed timestamp='%' details='Actual: 2 (number) was expected to equal: 1 (number)' name='ut3_user.check_multiple_failures.multi_failure'] +%##teamcity[testFailed timestamp='%' details='Actual: |'Bad|' (varchar2) was expected to equal: |'Good|' (varchar2)' name='ut3_user.check_multiple_failures.multi_failure'] +%##teamcity[testFinished timestamp='%' duration='%' name='ut3_user.check_multiple_failures.multi_failure'] +%##teamcity[testSuiteFinished timestamp='%' name='check_multiple_failures']}'; + --act + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('check_multiple_failures',ut3_develop.ut_teamcity_reporter())); + + --assert + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); + end; + procedure remove_test_package is pragma autonomous_transaction; begin execute immediate 'drop package check_escape_special_chars'; execute immediate 'drop package check_trims_long_output'; + execute immediate 'drop package check_multiple_failures'; end; end; diff --git a/test/ut3_user/reporters/test_teamcity_reporter.pks b/test/ut3_user/reporters/test_teamcity_reporter.pks index f849751f1..30ae7e26b 100644 --- a/test/ut3_user/reporters/test_teamcity_reporter.pks +++ b/test/ut3_user/reporters/test_teamcity_reporter.pks @@ -15,6 +15,9 @@ create or replace package test_teamcity_reporter as --%test(Trims output so it fits into 4000 chars) procedure trims_long_output; + --%test(Reports failures on multiple expectations) + procedure report_mutiple_expectations; + --%afterall procedure remove_test_package; From 0497dcfadcac637d186fdbc0aa36338d178f597d Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 12 Apr 2023 20:02:14 +0300 Subject: [PATCH 431/887] Adding Oracle 23-free-developer-edition --- .github/workflows/build.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0ec37efe2..c2fe3971e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -58,6 +58,11 @@ jobs: oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:21-slim" oracle-base: '/opt/oracle' + - id: 7 + db_version_name: '23free' + oracle-sid: 'FREEPDB1' + oracle-version: "gvenzl/oracle-free:23-slim" + oracle-base: '/opt/oracle' services: html_checker: From 55a2ecfcb73ff6389058423f41adf9e20279fc1c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Wed, 12 Apr 2023 21:00:57 +0300 Subject: [PATCH 432/887] Adjusted tests for ORacle 23c (change of error message for ORA-06502) --- test/ut3_user/reporters/test_documentation_reporter.pkb | 2 +- test/ut3_user/reporters/test_teamcity_reporter.pkb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/test/ut3_user/reporters/test_documentation_reporter.pkb b/test/ut3_user/reporters/test_documentation_reporter.pkb index 6ace70c49..2a05679ff 100644 --- a/test/ut3_user/reporters/test_documentation_reporter.pkb +++ b/test/ut3_user/reporters/test_documentation_reporter.pkb @@ -37,7 +37,7 @@ Failures: % % 2) erroring_test - ORA-06502: PL/SQL: numeric or value error: character to number conversion error + ORA-06502: PL/SQL: %: character to number conversion error ORA-06512: at "UT3_USER.TEST_REPORTERS", line 44% ORA-06512: at line 6 Finished in % seconds diff --git a/test/ut3_user/reporters/test_teamcity_reporter.pkb b/test/ut3_user/reporters/test_teamcity_reporter.pkb index cf7a925a1..7c4c1e513 100644 --- a/test/ut3_user/reporters/test_teamcity_reporter.pkb +++ b/test/ut3_user/reporters/test_teamcity_reporter.pkb @@ -77,8 +77,8 @@ create or replace package body test_teamcity_reporter as -%##teamcity[testStdErr timestamp='%' name='ut3_user.test_reporters.erroring_test' out='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3_USER.TEST_REPORTERS", line %|nORA-06512: at %|n'] -%##teamcity[testFailed timestamp='%' details='Test exception:|nORA-06502: PL/SQL: numeric or value error: character to number conversion error|nORA-06512: at "UT3_USER.TEST_REPORTERS", line %|nORA-06512: at %|n' message='Error occured' name='ut3_user.test_reporters.erroring_test'] +%##teamcity[testStdErr timestamp='%' name='ut3_user.test_reporters.erroring_test' out='Test exception:|nORA-06502: PL/SQL: %: character to number conversion error|nORA-06512: at "UT3_USER.TEST_REPORTERS", line %|nORA-06512: at %|n'] +%##teamcity[testFailed timestamp='%' details='Test exception:|nORA-06502: PL/SQL: %: character to number conversion error|nORA-06512: at "UT3_USER.TEST_REPORTERS", line %|nORA-06512: at %|n' message='Error occured' name='ut3_user.test_reporters.erroring_test'] %##teamcity[testFinished timestamp='%' duration='%' name='ut3_user.test_reporters.erroring_test'] %##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3_user.test_reporters.disabled_test'] %##teamcity[testIgnored timestamp='%' name='ut3_user.test_reporters.disabled_test'] From 313d5e9019f1253cc222821c802a11c8cdd7ed1a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 12 Apr 2023 18:40:28 -0700 Subject: [PATCH 433/887] Stage 1 Resolving PR comments --- source/api/ut_runner.pkb | 8 ++-- source/core/types/ut_stack.tpb | 2 +- source/core/types/ut_stack.tps | 2 +- source/core/ut_suite_builder.pkb | 2 +- source/core/ut_suite_cache_manager.pkb | 62 +++++++++++++------------- source/core/ut_utils.pkb | 55 +++++------------------ source/core/ut_utils.pks | 5 --- test/ut3_tester/core/test_ut_utils.pkb | 21 --------- test/ut3_tester/core/test_ut_utils.pks | 3 -- 9 files changed, 50 insertions(+), 110 deletions(-) diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 3d4550cf9..3ec2a5393 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -78,9 +78,7 @@ create or replace package body ut_runner is l_run ut_run; l_coverage_schema_names ut_varchar2_rows; l_paths ut_varchar2_list; - l_random_test_order_seed positive; - l_tags varchar2(4000) := a_tags; - + l_random_test_order_seed positive; begin ut_event_manager.initialize(); if a_reporters is not empty then @@ -135,10 +133,10 @@ create or replace package body ut_runner is a_test_file_mappings => set(a_test_file_mappings), a_client_character_set => a_client_character_set, a_random_test_order_seed => l_random_test_order_seed, - a_run_tags => l_tags + a_run_tags => a_tags ); - ut_suite_manager.configure_execution_by_path(l_paths, l_run.items, l_random_test_order_seed, l_tags); + ut_suite_manager.configure_execution_by_path(l_paths, l_run.items, l_random_test_order_seed, a_tags); if a_force_manual_rollback then l_run.set_rollback_type( a_rollback_type => ut_utils.gc_rollback_manual, a_force => true ); end if; diff --git a/source/core/types/ut_stack.tpb b/source/core/types/ut_stack.tpb index a7f7ab0c2..b5f4e8747 100644 --- a/source/core/types/ut_stack.tpb +++ b/source/core/types/ut_stack.tpb @@ -1,7 +1,7 @@ create or replace type body ut_stack as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2023 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_stack.tps b/source/core/types/ut_stack.tps index 7b8c145c2..23112fdde 100644 --- a/source/core/types/ut_stack.tps +++ b/source/core/types/ut_stack.tps @@ -3,7 +3,7 @@ create or replace type ut_stack as object ( tokens ut_varchar2_list, /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2023 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 4aa2ff915..ebb113370 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -205,7 +205,7 @@ create or replace package body ut_suite_builder is l_tag_items := ut_utils.trim_list_elements(ut_utils.string_to_table(a_tags_ann_text(l_annotation_pos),',')); if l_tag_items is not empty then for i in 1 .. l_tag_items.count loop - if regexp_like(l_tag_items(i),'^[^-!&|](\S)+$') then + if regexp_like(l_tag_items(i),'^[^-](\S)+$') then l_tags_list.extend(); l_tags_list(l_tags_list.last) := l_tag_items(i); else diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index a9153c7bd..858069c8f 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -238,44 +238,46 @@ create or replace package body ut_suite_cache_manager is l_tags_exclude varchar2(4000); l_return_tag varchar2(4000); begin - select listagg( t.column_value,'|') - within group( order by column_value) - into l_tags_include - from table(l_tags) t - where t.column_value not like '-%'; - - select listagg( replace(t.column_value,'-','!'),' & ') - within group( order by column_value) - into l_tags_exclude - from table(l_tags) t - where t.column_value like '-%'; - - l_return_tag:= - case when l_tags_include is not null then - '('||l_tags_include||')' else null end || - case when l_tags_include is not null and l_tags_exclude is not null then - ' & ' else null end || - case when l_tags_exclude is not null then - '('||l_tags_exclude||')' else null end; + if instr(a_tags,',') > 0 or instr(a_tags,'-') > 0 then + + select '('||listagg( t.column_value,'|') + within group( order by column_value)||')' + into l_tags_include + from table(l_tags) t + where t.column_value not like '-%'; + select '('||listagg( replace(t.column_value,'-','!'),' & ') + within group( order by column_value)||')' + into l_tags_exclude + from table(l_tags) t + where t.column_value like '-%'; + + + l_return_tag:= + case + when l_tags_include <> '()' and l_tags_exclude <> '()' + then l_tags_include || ' & ' || l_tags_exclude + when l_tags_include <> '()' + then l_tags_include + when l_tags_exclude <> '()' + then l_tags_exclude + end; + else + l_return_tag := a_tags; + end if; return l_return_tag; end; function create_where_filter(a_tags varchar2 ) return varchar2 is - l_tags varchar2(4000):= replace(a_tags,' '); + l_tags varchar2(4000); begin - if instr(l_tags,',') > 0 or instr(l_tags,'-') > 0 then - l_tags := replace(replace_legacy_tag_notation(l_tags),' '); - end if; + l_tags := replace(replace_legacy_tag_notation(a_tags),' '); l_tags := ut_utils.conv_postfix_to_infix_sql(ut_utils.shunt_logical_expression(l_tags)); - l_tags := REPLACE(l_tags, '|',' or '); - l_tags := REPLACE(l_tags ,'&',' and '); - l_tags := REPLACE(l_tags ,'!','not'); - return l_tags; - exception - when ut_utils.ex_invalid_tag_expression then - raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + l_tags := replace(l_tags, '|',' or '); + l_tags := replace(l_tags ,'&',' and '); + l_tags := replace(l_tags ,'!','not'); + return l_tags; end; /* diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index a8528fa86..6bcfbfeff 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -28,8 +28,8 @@ create or replace package body ut_utils is * Constants use in postfix and infix transformations */ gc_operators constant ut_varchar2_list := ut_varchar2_list('|','&','!'); - gc_unary_operator constant ut_varchar2_list := ut_varchar2_list('!'); -- right side associative operator - gc_binary_operator constant ut_varchar2_list := ut_varchar2_list('|','&'); -- left side associative operator + gc_unary_operators constant ut_varchar2_list := ut_varchar2_list('!'); -- right side associative operator + gc_binary_operators constant ut_varchar2_list := ut_varchar2_list('|','&'); -- left side associative operator type t_precedence_table is table of number index by varchar2(1); g_precedence t_precedence_table; @@ -1027,9 +1027,9 @@ create or replace package body ut_utils is --Exuecute modified shunting algorithm WHILE (l_idx is not null) loop l_token := l_input_tokens(l_idx); - if (l_token member of gc_operators and l_token member of gc_binary_operator) then + if (l_token member of gc_operators and l_token member of gc_binary_operators) then if not(l_expect_operator) then - raise ex_invalid_tag_expression; + raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); end if; while l_operator_stack.top > 0 and (g_precedence(l_operator_stack.peek) > g_precedence(l_token)) loop l_rnp_tokens.extend; @@ -1038,23 +1038,23 @@ create or replace package body ut_utils is l_operator_stack.push(l_input_tokens(l_idx)); l_expect_operand := true; l_expect_operator:= false; - elsif (l_token member of gc_operators and l_token member of gc_unary_operator) then + elsif (l_token member of gc_operators and l_token member of gc_unary_operators) then if not(l_expect_operand) then - raise ex_invalid_tag_expression; + raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); end if; l_operator_stack.push(l_input_tokens(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif l_token = '(' then if not(l_expect_operand) then - raise ex_invalid_tag_expression; + raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); end if; l_operator_stack.push(l_input_tokens(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif l_token = ')' then if not(l_expect_operator) then - raise ex_invalid_tag_expression; + raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); end if; while l_operator_stack.peek <> '(' loop l_rnp_tokens.extend; @@ -1065,7 +1065,7 @@ create or replace package body ut_utils is l_expect_operator:= true; else if not(l_expect_operand) then - raise ex_invalid_tag_expression; + raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); end if; l_rnp_tokens.extend; l_rnp_tokens(l_rnp_tokens.last) :=l_token; @@ -1078,7 +1078,7 @@ create or replace package body ut_utils is while l_operator_stack.peek is not null loop if l_operator_stack.peek in ('(',')') then - raise ex_invalid_tag_expression; + raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); end if; l_rnp_tokens.extend; l_rnp_tokens(l_rnp_tokens.last):=l_operator_stack.pop; @@ -1087,37 +1087,6 @@ create or replace package body ut_utils is return l_rnp_tokens; end shunt_logical_expression; - function convert_postfix_to_infix(a_postfix_exp in ut_varchar2_list) - return varchar2 is - l_infix_stack ut_stack := ut_stack(); - l_right_side varchar2(32767); - l_left_side varchar2(32767); - l_infix_exp varchar2(32767); - l_idx pls_integer; - begin - l_idx := a_postfix_exp.first; - while (l_idx is not null) loop - --If token is operand but also single tag - if a_postfix_exp(l_idx) not member of gc_operators then --its operand - l_infix_stack.push(a_postfix_exp(l_idx)); - --If token is unary operator not - elsif a_postfix_exp(l_idx) member of gc_unary_operator then - l_right_side := l_infix_stack.pop; - l_infix_exp := '('||a_postfix_exp(l_idx)||l_right_side||')'; - l_infix_stack.push(l_infix_exp); - --If token is binary operator - elsif a_postfix_exp(l_idx) member of gc_binary_operator then - l_right_side := l_infix_stack.pop; - l_left_side := l_infix_stack.pop; - l_infix_exp := '('||l_left_side||a_postfix_exp(l_idx)||l_right_side||')'; - l_infix_stack.push(l_infix_exp); - end if; - l_idx := a_postfix_exp.next(l_idx); - end loop; - - return l_infix_stack.pop; - end convert_postfix_to_infix; - function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list) return varchar2 is l_infix_stack ut_stack := ut_stack(); @@ -1136,12 +1105,12 @@ create or replace package body ut_utils is elsif a_postfix_exp(l_idx) not member of gc_operators then l_infix_stack.push(a_postfix_exp(l_idx)); --If token is unary operator not - elsif a_postfix_exp(l_idx) member of gc_unary_operator then + elsif a_postfix_exp(l_idx) member of gc_unary_operators then l_right_side := l_infix_stack.pop; l_infix_exp := a_postfix_exp(l_idx)||'('||l_right_side||')'; l_infix_stack.push(l_infix_exp); --If token is binary operator - elsif a_postfix_exp(l_idx) member of gc_binary_operator then + elsif a_postfix_exp(l_idx) member of gc_binary_operators then l_right_side := l_infix_stack.pop; l_left_side := l_infix_stack.pop; l_infix_exp := '('||l_left_side||a_postfix_exp(l_idx)||l_right_side||')'; diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 67b09b2f9..a7f7752fb 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -489,11 +489,6 @@ create or replace package ut_utils authid definer is */ function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list; - /* - * Function that converts postfix notation into infix - */ - function convert_postfix_to_infix(a_postfix_exp in ut_varchar2_list) return varchar2; - /* * Function that converts postfix notation into infix and creating a string of sql filter * that checking a tags collections for tags according to posted logic. diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 22733c4ce..8f3b57fd0 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -511,27 +511,6 @@ end; ut.expect(l_postfix_string).to_equal('a!b|'); end; - procedure test_conv_from_rpn_to_infix is - l_postfix_rpn ut3_develop.ut_varchar2_list; - l_infix_string varchar2(4000); - begin - l_postfix_rpn := ut3_develop.ut_varchar2_list('A'); - l_infix_string := ut3_develop.ut_utils.convert_postfix_to_infix(l_postfix_rpn); - ut.expect(l_infix_string).to_equal('A'); - - l_postfix_rpn := ut3_develop.ut_varchar2_list('A','B','|'); - l_infix_string := ut3_develop.ut_utils.convert_postfix_to_infix(l_postfix_rpn); - ut.expect(l_infix_string).to_equal('(A|B)'); - - l_postfix_rpn := ut3_develop.ut_varchar2_list('a','b','|','c','d','&','|'); - l_infix_string := ut3_develop.ut_utils.convert_postfix_to_infix(l_postfix_rpn); - ut.expect(l_infix_string).to_equal('((a|b)|(c&d))'); - - l_postfix_rpn := ut3_develop.ut_varchar2_list('a','b','!','|'); - l_infix_string := ut3_develop.ut_utils.convert_postfix_to_infix(l_postfix_rpn); - ut.expect(l_infix_string).to_equal('(a|(!b))'); - end; - procedure conv_from_rpn_to_sql_filter is l_postfix_rpn ut3_develop.ut_varchar2_list; l_infix_string varchar2(4000); diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index 1561e1136..a58082be0 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -160,9 +160,6 @@ create or replace package test_ut_utils is --%test( Test conversion of expression into Reverse Polish Notation) procedure test_conversion_to_rpn; - --%test( Test conversion of expression from Reverse Polish Notation into infix) - procedure test_conv_from_rpn_to_infix; - --%test( Test conversion of expression from Reverse Polish Notation into custom where filter for SQL) procedure conv_from_rpn_to_sql_filter; From 02a071cb43799b8b68aa12cddb8cba757e6654a2 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 13 Apr 2023 16:47:00 -0700 Subject: [PATCH 434/887] Separate tag logic. --- source/core/ut_suite_cache_manager.pkb | 143 +-------- source/core/ut_suite_cache_manager.pks | 9 +- source/core/ut_suite_manager.pkb | 15 +- source/core/ut_suite_tag_filter.pkb | 288 ++++++++++++++++++ source/core/ut_suite_tag_filter.pks | 48 +++ source/core/ut_utils.pkb | 140 --------- source/core/ut_utils.pks | 18 -- source/install.sql | 2 + test/install_ut3_tester_tests.sql | 2 + .../core/test_ut_suite_tag_filter.pkb | 42 +++ .../core/test_ut_suite_tag_filter.pks | 13 + test/ut3_tester/core/test_ut_utils.pkb | 39 --- test/ut3_tester/core/test_ut_utils.pks | 6 - 13 files changed, 423 insertions(+), 342 deletions(-) create mode 100644 source/core/ut_suite_tag_filter.pkb create mode 100644 source/core/ut_suite_tag_filter.pks create mode 100644 test/ut3_tester/core/test_ut_suite_tag_filter.pkb create mode 100644 test/ut3_tester/core/test_ut_suite_tag_filter.pks diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 858069c8f..3bb679517 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -220,121 +220,7 @@ create or replace package body ut_suite_cache_manager is and c.name = nvl(upper(sp.procedure_name),c.name)))) where r_num =1; return l_suite_items; end; - - /* - To support a legact tag notation - , = OR - - = NOT - we will perform a replace of that characters into - new notation. - | = OR - & = AND - ! = NOT - */ - function replace_legacy_tag_notation(a_tags varchar2 - ) return varchar2 is - l_tags ut_varchar2_list := ut_utils.string_to_table(a_tags,','); - l_tags_include varchar2(4000); - l_tags_exclude varchar2(4000); - l_return_tag varchar2(4000); - begin - if instr(a_tags,',') > 0 or instr(a_tags,'-') > 0 then - - select '('||listagg( t.column_value,'|') - within group( order by column_value)||')' - into l_tags_include - from table(l_tags) t - where t.column_value not like '-%'; - select '('||listagg( replace(t.column_value,'-','!'),' & ') - within group( order by column_value)||')' - into l_tags_exclude - from table(l_tags) t - where t.column_value like '-%'; - - - l_return_tag:= - case - when l_tags_include <> '()' and l_tags_exclude <> '()' - then l_tags_include || ' & ' || l_tags_exclude - when l_tags_include <> '()' - then l_tags_include - when l_tags_exclude <> '()' - then l_tags_exclude - end; - else - l_return_tag := a_tags; - end if; - return l_return_tag; - end; - - function create_where_filter(a_tags varchar2 - ) return varchar2 is - l_tags varchar2(4000); - begin - l_tags := replace(replace_legacy_tag_notation(a_tags),' '); - l_tags := ut_utils.conv_postfix_to_infix_sql(ut_utils.shunt_logical_expression(l_tags)); - l_tags := replace(l_tags, '|',' or '); - l_tags := replace(l_tags ,'&',' and '); - l_tags := replace(l_tags ,'!','not'); - return l_tags; - end; - - /* - Having a base set of suites we will do a further filter down if there are - any tags defined. - */ - function get_tags_suites ( - a_suite_items ut_suite_cache_rows, - a_tags varchar2 - ) return ut_suite_cache_rows is - l_suite_tags ut_suite_cache_rows := ut_suite_cache_rows(); - l_sql varchar2(32000); - l_tags varchar2(4000):= create_where_filter(a_tags); - begin - l_sql := - q'[ -with - suites_mv as ( - select c.id,value(c) as obj,c.path as path,c.self_type,c.object_owner,c.tags - from table(:suite_items) c - ), - suites_matching_expr as ( - select c.id,c.path as path,c.self_type,c.object_owner,c.tags - from suites_mv c - where c.self_type in ('UT_SUITE','UT_CONTEXT') - and ]'||l_tags||q'[ - ), - tests_matching_expr as ( - select c.id,c.path as path,c.self_type,c.object_owner,c.tags - from suites_mv c where c.self_type in ('UT_TEST') - and ]'||l_tags||q'[ - ), - tests_with_tags_inh_from_suite as ( - select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner - from suites_mv c join suites_matching_expr t - on (c.path||'.' like t.path || '.%' /*all descendants and self*/ and c.object_owner = t.object_owner) - ), - tests_with_tags_prom_to_suite as ( - select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner - from suites_mv c join tests_matching_expr t - on (t.path||'.' like c.path || '.%' /*all ancestors and self*/ and c.object_owner = t.object_owner) - ) - select obj from suites_mv c, - (select id,row_number() over (partition by id order by id) r_num from - (select id - from tests_with_tags_prom_to_suite tst - where ]'||l_tags||q'[ - union all - select id from tests_with_tags_inh_from_suite tst - where ]'||l_tags||q'[ - ) - ) t where c.id = t.id and r_num = 1 ]'; - - execute immediate l_sql bulk collect into l_suite_tags using a_suite_items; - return l_suite_tags; - end; - /* We will sort a suites in hierarchical structure. Sorting from bottom to top so when we consolidate @@ -387,30 +273,29 @@ with end; function get_cached_suite_rows( - a_schema_paths ut_path_items, - a_random_seed positive := null, - a_tags varchar2 := null + a_suites_filtered ut_suite_cache_rows ) return ut_suite_cache_rows is l_results ut_suite_cache_rows := ut_suite_cache_rows(); - l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); - l_schema_paths ut_path_items; - l_tags varchar2(4000) := a_tags; begin - l_schema_paths := a_schema_paths; - l_suite_items := get_suite_items(a_schema_paths); - if length(l_tags) > 0 then - l_suite_items := get_tags_suites(l_suite_items,l_tags); - end if; - - open c_get_bulk_cache_suite(l_suite_items); + open c_get_bulk_cache_suite(a_suites_filtered); fetch c_get_bulk_cache_suite bulk collect into l_results; close c_get_bulk_cache_suite; return l_results; end; - + function get_cached_suites( + a_schema_paths ut_path_items, + a_random_seed positive := null + ) return ut_suite_cache_rows is + l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); + l_schema_paths ut_path_items; + begin + l_schema_paths := a_schema_paths; + l_suite_items := get_suite_items(a_schema_paths); + return l_suite_items; + end; function get_schema_parse_time(a_schema_name varchar2) return timestamp result_cache is l_cache_parse_time timestamp; @@ -558,7 +443,7 @@ with a_schema_paths ut_path_items ) return ut_suite_cache_rows is begin - return get_cached_suite_rows( a_schema_paths ); + return get_cached_suite_rows(get_cached_suites( a_schema_paths )); end; function get_suite_items_info( diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 7f06e95eb..c217abeed 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -55,11 +55,14 @@ create or replace package ut_suite_cache_manager authid definer is * Not to be used publicly. Used internally for building suites at runtime. */ function get_cached_suite_rows( + a_suites_filtered ut_suite_cache_rows + ) return ut_suite_cache_rows; + + function get_cached_suites( a_schema_paths ut_path_items, - a_random_seed positive := null, - a_tags varchar2 := null + a_random_seed positive := null ) return ut_suite_cache_rows; - + function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items; /* diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 0f8629ded..f8a2e002c 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -355,17 +355,18 @@ create or replace package body ut_suite_manager is a_tags varchar2 := null, a_skip_all_objects boolean := false ) return t_cached_suites_cursor is - l_unfiltered_rows ut_suite_cache_rows; - l_filtered_rows ut_suite_cache_rows; - l_result t_cached_suites_cursor; + l_unfiltered_rows ut_suite_cache_rows; + l_tag_filter_applied ut_suite_cache_rows; + l_filtered_rows ut_suite_cache_rows; + l_result t_cached_suites_cursor; begin - l_unfiltered_rows := ut_suite_cache_manager.get_cached_suite_rows( + l_unfiltered_rows := ut_suite_cache_manager.get_cached_suites( a_schema_paths, - a_random_seed, - a_tags + a_random_seed ); - l_filtered_rows := get_filtered_cursor(l_unfiltered_rows,a_skip_all_objects); + l_tag_filter_applied := ut_suite_tag_filter.apply(l_unfiltered_rows,a_tags); + l_filtered_rows := get_filtered_cursor(ut_suite_cache_manager.get_cached_suite_rows(l_tag_filter_applied),a_skip_all_objects); reconcile_paths_and_suites(a_schema_paths,l_filtered_rows); ut_suite_cache_manager.sort_and_randomize_tests(l_filtered_rows,a_random_seed); diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb new file mode 100644 index 000000000..f1e055a27 --- /dev/null +++ b/source/core/ut_suite_tag_filter.pkb @@ -0,0 +1,288 @@ +create or replace package body ut_suite_tag_filter is + /* + utPLSQL - Version 3 + Copyright 2016 - 2023 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + /** + * Constants use in postfix and infix transformations + */ + gc_operators constant ut_varchar2_list := ut_varchar2_list('|','&','!'); + gc_unary_operators constant ut_varchar2_list := ut_varchar2_list('!'); -- right side associative operator + gc_binary_operators constant ut_varchar2_list := ut_varchar2_list('|','&'); -- left side associative operator + + type t_precedence_table is table of number index by varchar2(1); + g_precedence t_precedence_table; + + function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list is + l_tags_tokens ut_varchar2_list := ut_varchar2_list(); + begin + --Tokenize a string into operators and tags + select regexp_substr(a_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts + bulk collect into l_tags_tokens + from dual connect by regexp_substr (a_tags, '([^!()|&]+)|([!()|&])', 1, level) is not null; + + return l_tags_tokens; + end; + + /* + To support a legact tag notation + , = OR + - = NOT + we will perform a replace of that characters into + new notation. + | = OR + & = AND + ! = NOT + */ + function replace_legacy_tag_notation(a_tags varchar2 + ) return varchar2 is + l_tags ut_varchar2_list := ut_utils.string_to_table(a_tags,','); + l_tags_include varchar2(4000); + l_tags_exclude varchar2(4000); + l_return_tag varchar2(4000); + begin + if instr(a_tags,',') > 0 or instr(a_tags,'-') > 0 then + + select '('||listagg( t.column_value,'|') + within group( order by column_value)||')' + into l_tags_include + from table(l_tags) t + where t.column_value not like '-%'; + + select '('||listagg( replace(t.column_value,'-','!'),' & ') + within group( order by column_value)||')' + into l_tags_exclude + from table(l_tags) t + where t.column_value like '-%'; + + + l_return_tag:= + case + when l_tags_include <> '()' and l_tags_exclude <> '()' + then l_tags_include || ' & ' || l_tags_exclude + when l_tags_include <> '()' + then l_tags_include + when l_tags_exclude <> '()' + then l_tags_exclude + end; + else + l_return_tag := a_tags; + end if; + return l_return_tag; + end; + + /* + https://stackoverflow.com/questions/29634992/shunting-yard-validate-expression + */ + function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list is + l_operator_stack ut_stack := ut_stack(); + l_input_tokens ut_varchar2_list := tokenize_tags_string(a_tags); + l_rnp_tokens ut_varchar2_list := ut_varchar2_list(); + l_token varchar2(32767); + l_expect_operand boolean := true; + l_expect_operator boolean := false; + l_idx pls_integer; + begin + l_idx := l_input_tokens.first; + --Exuecute modified shunting algorithm + WHILE (l_idx is not null) loop + l_token := l_input_tokens(l_idx); + if (l_token member of gc_operators and l_token member of gc_binary_operators) then + if not(l_expect_operator) then + raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + end if; + while l_operator_stack.top > 0 and (g_precedence(l_operator_stack.peek) > g_precedence(l_token)) loop + l_rnp_tokens.extend; + l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; + end loop; + l_operator_stack.push(l_input_tokens(l_idx)); + l_expect_operand := true; + l_expect_operator:= false; + elsif (l_token member of gc_operators and l_token member of gc_unary_operators) then + if not(l_expect_operand) then + raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + end if; + l_operator_stack.push(l_input_tokens(l_idx)); + l_expect_operand := true; + l_expect_operator:= false; + elsif l_token = '(' then + if not(l_expect_operand) then + raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + end if; + l_operator_stack.push(l_input_tokens(l_idx)); + l_expect_operand := true; + l_expect_operator:= false; + elsif l_token = ')' then + if not(l_expect_operator) then + raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + end if; + while l_operator_stack.peek <> '(' loop + l_rnp_tokens.extend; + l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; + end loop; + l_operator_stack.pop; --Pop the open bracket and discard it + l_expect_operand := false; + l_expect_operator:= true; + else + if not(l_expect_operand) then + raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + end if; + l_rnp_tokens.extend; + l_rnp_tokens(l_rnp_tokens.last) :=l_token; + l_expect_operator := true; + l_expect_operand := false; + end if; + + l_idx := l_input_tokens.next(l_idx); + end loop; + + while l_operator_stack.peek is not null loop + if l_operator_stack.peek in ('(',')') then + raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + end if; + l_rnp_tokens.extend; + l_rnp_tokens(l_rnp_tokens.last):=l_operator_stack.pop; + end loop; + + return l_rnp_tokens; + end shunt_logical_expression; + + function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list) + return varchar2 is + l_infix_stack ut_stack := ut_stack(); + l_right_side varchar2(32767); + l_left_side varchar2(32767); + l_infix_exp varchar2(32767); + l_member_token varchar2(20) := ' member of tags'; + l_idx pls_integer; + begin + l_idx := a_postfix_exp.first; + while ( l_idx is not null) loop + --If token is operand but also single tag + if regexp_count(a_postfix_exp(l_idx),'[!()|&]') = 0 then + l_infix_stack.push(q'[']'||a_postfix_exp(l_idx)||q'[']'||l_member_token); + --If token is operand but containing other expressions + elsif a_postfix_exp(l_idx) not member of gc_operators then + l_infix_stack.push(a_postfix_exp(l_idx)); + --If token is unary operator not + elsif a_postfix_exp(l_idx) member of gc_unary_operators then + l_right_side := l_infix_stack.pop; + l_infix_exp := a_postfix_exp(l_idx)||'('||l_right_side||')'; + l_infix_stack.push(l_infix_exp); + --If token is binary operator + elsif a_postfix_exp(l_idx) member of gc_binary_operators then + l_right_side := l_infix_stack.pop; + l_left_side := l_infix_stack.pop; + l_infix_exp := '('||l_left_side||a_postfix_exp(l_idx)||l_right_side||')'; + l_infix_stack.push(l_infix_exp); + end if; + l_idx := a_postfix_exp.next(l_idx); + end loop; + + return l_infix_stack.pop; + end conv_postfix_to_infix_sql; + + function create_where_filter(a_tags varchar2 + ) return varchar2 is + l_tags varchar2(4000); + begin + l_tags := replace(replace_legacy_tag_notation(a_tags),' '); + l_tags := conv_postfix_to_infix_sql(shunt_logical_expression(l_tags)); + l_tags := replace(l_tags, '|',' or '); + l_tags := replace(l_tags ,'&',' and '); + l_tags := replace(l_tags ,'!','not'); + return l_tags; + end; + + + /* + Having a base set of suites we will do a further filter down if there are + any tags defined. + */ + function get_tags_suites ( + a_suite_items ut_suite_cache_rows, + a_tags varchar2 + ) return ut_suite_cache_rows is + l_suite_tags ut_suite_cache_rows := ut_suite_cache_rows(); + l_sql varchar2(32000); + l_tags varchar2(4000):= create_where_filter(a_tags); + begin + l_sql := + q'[ +with + suites_mv as ( + select c.id,value(c) as obj,c.path as path,c.self_type,c.object_owner,c.tags + from table(:suite_items) c + ), + suites_matching_expr as ( + select c.id,c.path as path,c.self_type,c.object_owner,c.tags + from suites_mv c + where c.self_type in ('UT_SUITE','UT_CONTEXT') + and ]'||l_tags||q'[ + ), + tests_matching_expr as ( + select c.id,c.path as path,c.self_type,c.object_owner,c.tags + from suites_mv c where c.self_type in ('UT_TEST') + and ]'||l_tags||q'[ + ), + tests_with_tags_inh_from_suite as ( + select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner + from suites_mv c join suites_matching_expr t + on (c.path||'.' like t.path || '.%' /*all descendants and self*/ and c.object_owner = t.object_owner) + ), + tests_with_tags_prom_to_suite as ( + select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner + from suites_mv c join tests_matching_expr t + on (t.path||'.' like c.path || '.%' /*all ancestors and self*/ and c.object_owner = t.object_owner) + ) + select obj from suites_mv c, + (select id,row_number() over (partition by id order by id) r_num from + (select id + from tests_with_tags_prom_to_suite tst + where ]'||l_tags||q'[ + union all + select id from tests_with_tags_inh_from_suite tst + where ]'||l_tags||q'[ + ) + ) t where c.id = t.id and r_num = 1 ]'; + + execute immediate l_sql bulk collect into l_suite_tags using a_suite_items; + return l_suite_tags; + end; + + function apply( + a_unfiltered_rows ut_suite_cache_rows, + a_tags varchar2 := null + ) return ut_suite_cache_rows is + l_suite_items ut_suite_cache_rows := a_unfiltered_rows; + begin + if length(a_tags) > 0 then + l_suite_items := get_tags_suites(l_suite_items,a_tags); + end if; + + return l_suite_items; + end; + +begin + --Define operators precedence + g_precedence('!'):=4; + g_precedence('&'):=3; + g_precedence('|'):=2; + g_precedence(')'):=1; + g_precedence('('):=1; + +end ut_suite_tag_filter; +/ diff --git a/source/core/ut_suite_tag_filter.pks b/source/core/ut_suite_tag_filter.pks new file mode 100644 index 000000000..787c72603 --- /dev/null +++ b/source/core/ut_suite_tag_filter.pks @@ -0,0 +1,48 @@ +create or replace package ut_suite_tag_filter authid definer is + /* + utPLSQL - Version 3 + Copyright 2016 - 2023 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + /** + * Package that will filter suites by tags + * + */ + + /* + * Return table of tokens character by character + */ + function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list; + + /* + * Function that uses Dijkstra algorithm to parse mathematical and logical expression + * and return a list of elements in Reverse Polish Notation ( postfix ) + * As part of execution it will validate expression. + */ + function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list; + + /* + * Function that converts postfix notation into infix and creating a string of sql filter + * that checking a tags collections for tags according to posted logic. + */ + function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list) return varchar2; + + function apply( + a_unfiltered_rows ut_suite_cache_rows, + a_tags varchar2 := null + ) return ut_suite_cache_rows; + +end ut_suite_tag_filter; +/ diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 6bcfbfeff..6f972e11c 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -24,15 +24,6 @@ create or replace package body ut_utils is gc_full_valid_xml_name constant varchar2(50) := '^([_a-zA-Z])([_a-zA-Z0-9\.-])*$'; gc_owner_hash constant integer(11) := dbms_utility.get_hash_value( ut_owner(), 0, power(2,31)-1); - /** - * Constants use in postfix and infix transformations - */ - gc_operators constant ut_varchar2_list := ut_varchar2_list('|','&','!'); - gc_unary_operators constant ut_varchar2_list := ut_varchar2_list('!'); -- right side associative operator - gc_binary_operators constant ut_varchar2_list := ut_varchar2_list('|','&'); -- left side associative operator - - type t_precedence_table is table of number index by varchar2(1); - g_precedence t_precedence_table; function surround_with(a_value varchar2, a_quote_char varchar2) return varchar2 is begin @@ -999,136 +990,5 @@ create or replace package body ut_utils is return l_result; end; - - function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list is - l_tags_tokens ut_varchar2_list := ut_varchar2_list(); - begin - --Tokenize a string into operators and tags - select regexp_substr(a_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts - bulk collect into l_tags_tokens - from dual connect by regexp_substr (a_tags, '([^!()|&]+)|([!()|&])', 1, level) is not null; - - return l_tags_tokens; - end; - - /* - https://stackoverflow.com/questions/29634992/shunting-yard-validate-expression - */ - function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list is - l_operator_stack ut_stack := ut_stack(); - l_input_tokens ut_varchar2_list := tokenize_tags_string(a_tags); - l_rnp_tokens ut_varchar2_list := ut_varchar2_list(); - l_token varchar2(32767); - l_expect_operand boolean := true; - l_expect_operator boolean := false; - l_idx pls_integer; - begin - l_idx := l_input_tokens.first; - --Exuecute modified shunting algorithm - WHILE (l_idx is not null) loop - l_token := l_input_tokens(l_idx); - if (l_token member of gc_operators and l_token member of gc_binary_operators) then - if not(l_expect_operator) then - raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); - end if; - while l_operator_stack.top > 0 and (g_precedence(l_operator_stack.peek) > g_precedence(l_token)) loop - l_rnp_tokens.extend; - l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; - end loop; - l_operator_stack.push(l_input_tokens(l_idx)); - l_expect_operand := true; - l_expect_operator:= false; - elsif (l_token member of gc_operators and l_token member of gc_unary_operators) then - if not(l_expect_operand) then - raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); - end if; - l_operator_stack.push(l_input_tokens(l_idx)); - l_expect_operand := true; - l_expect_operator:= false; - elsif l_token = '(' then - if not(l_expect_operand) then - raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); - end if; - l_operator_stack.push(l_input_tokens(l_idx)); - l_expect_operand := true; - l_expect_operator:= false; - elsif l_token = ')' then - if not(l_expect_operator) then - raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); - end if; - while l_operator_stack.peek <> '(' loop - l_rnp_tokens.extend; - l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; - end loop; - l_operator_stack.pop; --Pop the open bracket and discard it - l_expect_operand := false; - l_expect_operator:= true; - else - if not(l_expect_operand) then - raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); - end if; - l_rnp_tokens.extend; - l_rnp_tokens(l_rnp_tokens.last) :=l_token; - l_expect_operator := true; - l_expect_operand := false; - end if; - - l_idx := l_input_tokens.next(l_idx); - end loop; - - while l_operator_stack.peek is not null loop - if l_operator_stack.peek in ('(',')') then - raise_application_error(gc_invalid_tag_expression, 'Invalid Tag expression'); - end if; - l_rnp_tokens.extend; - l_rnp_tokens(l_rnp_tokens.last):=l_operator_stack.pop; - end loop; - - return l_rnp_tokens; - end shunt_logical_expression; - - function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list) - return varchar2 is - l_infix_stack ut_stack := ut_stack(); - l_right_side varchar2(32767); - l_left_side varchar2(32767); - l_infix_exp varchar2(32767); - l_member_token varchar2(20) := ' member of tags'; - l_idx pls_integer; - begin - l_idx := a_postfix_exp.first; - while ( l_idx is not null) loop - --If token is operand but also single tag - if regexp_count(a_postfix_exp(l_idx),'[!()|&]') = 0 then - l_infix_stack.push(q'[']'||a_postfix_exp(l_idx)||q'[']'||l_member_token); - --If token is operand but containing other expressions - elsif a_postfix_exp(l_idx) not member of gc_operators then - l_infix_stack.push(a_postfix_exp(l_idx)); - --If token is unary operator not - elsif a_postfix_exp(l_idx) member of gc_unary_operators then - l_right_side := l_infix_stack.pop; - l_infix_exp := a_postfix_exp(l_idx)||'('||l_right_side||')'; - l_infix_stack.push(l_infix_exp); - --If token is binary operator - elsif a_postfix_exp(l_idx) member of gc_binary_operators then - l_right_side := l_infix_stack.pop; - l_left_side := l_infix_stack.pop; - l_infix_exp := '('||l_left_side||a_postfix_exp(l_idx)||l_right_side||')'; - l_infix_stack.push(l_infix_exp); - end if; - l_idx := a_postfix_exp.next(l_idx); - end loop; - - return l_infix_stack.pop; - end conv_postfix_to_infix_sql; - -begin - --Define operator precedence - g_precedence('!'):=4; - g_precedence('&'):=3; - g_precedence('|'):=2; - g_precedence(')'):=1; - g_precedence('('):=1; - end ut_utils; / diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index a7f7752fb..b60fc4cdf 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -477,23 +477,5 @@ create or replace package ut_utils authid definer is */ function interval_to_text(a_interval yminterval_unconstrained) return varchar2; - /* - * Return table of tokens character by character - */ - function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list; - - /* - * Function that uses Dijkstra algorithm to parse mathematical and logical expression - * and return a list of elements in Reverse Polish Notation ( postfix ) - * As part of execution it will validate expression. - */ - function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list; - - /* - * Function that converts postfix notation into infix and creating a string of sql filter - * that checking a tags collections for tags according to posted logic. - */ - function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list) return varchar2; - end ut_utils; / diff --git a/source/install.sql b/source/install.sql index a54977f94..827213e6c 100644 --- a/source/install.sql +++ b/source/install.sql @@ -155,6 +155,8 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/ut_suite_cache_seq.sql' @@install_component.sql 'core/ut_suite_cache.sql' +@@install_component.sql 'core/ut_suite_tag_filter.pks' +@@install_component.sql 'core/ut_suite_tag_filter.pkb' @@install_component.sql 'core/ut_suite_cache_manager.pks' @@install_component.sql 'core/ut_suite_cache_manager.pkb' @@install_component.sql 'core/ut_suite_builder.pks' diff --git a/test/install_ut3_tester_tests.sql b/test/install_ut3_tester_tests.sql index 8163a39f2..cc96b2b64 100644 --- a/test/install_ut3_tester_tests.sql +++ b/test/install_ut3_tester_tests.sql @@ -17,6 +17,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core/annotations/test_annot_disabled_reason.pks @@ut3_tester/core/expectations/test_expectation_processor.pks @@ut3_tester/core/test_ut_utils.pks +@@ut3_tester/core/test_ut_suite_tag_filter.pks @@ut3_tester/core/test_ut_test.pks @@ut3_tester/core/test_ut_suite.pks @@ut3_tester/core/test_ut_executable.pks @@ -35,6 +36,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core/annotations/test_annot_disabled_reason.pkb @@ut3_tester/core/expectations/test_expectation_processor.pkb @@ut3_tester/core/test_ut_utils.pkb +@@ut3_tester/core/test_ut_suite_tag_filter.pkb @@ut3_tester/core/test_ut_test.pkb @@ut3_tester/core/test_ut_suite.pkb @@ut3_tester/core/test_ut_executable.pkb diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb new file mode 100644 index 000000000..a1d0be1f7 --- /dev/null +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -0,0 +1,42 @@ +create or replace package body test_ut_suite_tag_filter is + + procedure test_conversion_to_rpn is + l_postfix ut3_develop.ut_varchar2_list; + l_postfix_string varchar2(4000); + begin + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression('A'); + l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); + ut.expect(l_postfix_string).to_equal('A'); + + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression('A|B'); + l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); + ut.expect(l_postfix_string).to_equal('AB|'); + + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression('(a|b)|c&d'); + l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); + ut.expect(l_postfix_string).to_equal('ab|cd&|'); + + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression('!a|b'); + l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); + ut.expect(l_postfix_string).to_equal('a!b|'); + end; + + procedure conv_from_rpn_to_sql_filter is + l_postfix_rpn ut3_develop.ut_varchar2_list; + l_infix_string varchar2(4000); + begin + l_postfix_rpn := ut3_develop.ut_varchar2_list('A'); + l_infix_string := ut3_develop.ut_suite_tag_filter.conv_postfix_to_infix_sql(l_postfix_rpn); + ut.expect(l_infix_string).to_equal(q'['A' member of tags]'); + + l_postfix_rpn := ut3_develop.ut_varchar2_list('A','B','|'); + l_infix_string := ut3_develop.ut_suite_tag_filter.conv_postfix_to_infix_sql(l_postfix_rpn); + ut.expect(l_infix_string).to_equal(q'[('A' member of tags|'B' member of tags)]'); + + l_postfix_rpn := ut3_develop.ut_varchar2_list('a','b','!','|'); + l_infix_string := ut3_develop.ut_suite_tag_filter.conv_postfix_to_infix_sql(l_postfix_rpn); + ut.expect(l_infix_string).to_equal(q'[('a' member of tags|!('b' member of tags))]'); + end; + +end test_ut_suite_tag_filter; +/ diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pks b/test/ut3_tester/core/test_ut_suite_tag_filter.pks new file mode 100644 index 000000000..093fab856 --- /dev/null +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pks @@ -0,0 +1,13 @@ +create or replace package test_ut_suite_tag_filter is + + --%suite(ut_suite_tag_filter) + --%suitepath(utplsql.ut3_tester.core) + + --%test( Test conversion of expression into Reverse Polish Notation) + procedure test_conversion_to_rpn; + + --%test( Test conversion of expression from Reverse Polish Notation into custom where filter for SQL) + procedure conv_from_rpn_to_sql_filter; + +end test_ut_suite_tag_filter; +/ diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 8f3b57fd0..ec7e4f403 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -489,44 +489,5 @@ end; ut.expect(l_expected).to_equal(l_actual); end; - - procedure test_conversion_to_rpn is - l_postfix ut3_develop.ut_varchar2_list; - l_postfix_string varchar2(4000); - begin - l_postfix := ut3_develop.ut_utils.shunt_logical_expression('A'); - l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); - ut.expect(l_postfix_string).to_equal('A'); - - l_postfix := ut3_develop.ut_utils.shunt_logical_expression('A|B'); - l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); - ut.expect(l_postfix_string).to_equal('AB|'); - - l_postfix := ut3_develop.ut_utils.shunt_logical_expression('(a|b)|c&d'); - l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); - ut.expect(l_postfix_string).to_equal('ab|cd&|'); - - l_postfix := ut3_develop.ut_utils.shunt_logical_expression('!a|b'); - l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); - ut.expect(l_postfix_string).to_equal('a!b|'); - end; - - procedure conv_from_rpn_to_sql_filter is - l_postfix_rpn ut3_develop.ut_varchar2_list; - l_infix_string varchar2(4000); - begin - l_postfix_rpn := ut3_develop.ut_varchar2_list('A'); - l_infix_string := ut3_develop.ut_utils.conv_postfix_to_infix_sql(l_postfix_rpn); - ut.expect(l_infix_string).to_equal(q'['A' member of tags]'); - - l_postfix_rpn := ut3_develop.ut_varchar2_list('A','B','|'); - l_infix_string := ut3_develop.ut_utils.conv_postfix_to_infix_sql(l_postfix_rpn); - ut.expect(l_infix_string).to_equal(q'[('A' member of tags|'B' member of tags)]'); - - l_postfix_rpn := ut3_develop.ut_varchar2_list('a','b','!','|'); - l_infix_string := ut3_develop.ut_utils.conv_postfix_to_infix_sql(l_postfix_rpn); - ut.expect(l_infix_string).to_equal(q'[('a' member of tags|!('b' member of tags))]'); - end; - end test_ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index a58082be0..114b35e86 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -157,11 +157,5 @@ create or replace package test_ut_utils is --%endcontext - --%test( Test conversion of expression into Reverse Polish Notation) - procedure test_conversion_to_rpn; - - --%test( Test conversion of expression from Reverse Polish Notation into custom where filter for SQL) - procedure conv_from_rpn_to_sql_filter; - end test_ut_utils; / From b8b66ee715c6765d5fef1ad92d8c25513bf757c5 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 13 Apr 2023 17:00:41 -0700 Subject: [PATCH 435/887] Fix uninstall --- source/uninstall_objects.sql | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 1e21f0f95..f488b8b8d 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -95,6 +95,8 @@ drop package ut_suite_manager; drop package ut_suite_builder; +drop package ut_suite_tag_filter; + drop package ut_suite_cache_manager; drop table ut_suite_cache purge; From 077fdb11316cda8b99b9ccc909a1c9cb3de57267 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 14 Apr 2023 15:48:56 -0700 Subject: [PATCH 436/887] Various PR fixe --- docs/userguide/annotations.md | 82 +------------------ docs/userguide/running-unit-tests.md | 76 +++++++++++++++-- source/core/ut_suite_tag_filter.pkb | 18 ++-- source/core/ut_suite_tag_filter.pks | 2 +- .../core/test_ut_suite_tag_filter.pkb | 49 ++++++++++- .../core/test_ut_suite_tag_filter.pks | 20 +++++ 6 files changed, 145 insertions(+), 102 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8e5a5d1ca..552b02b52 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1616,7 +1616,7 @@ or Tags are defined as a comma separated list within the `--%tags` annotation. -When a suite/context is tagged, all of its children will automatically inherit the tag and get executed along with the parent, unless they are excluded by tag expression. +When a suite/context is tagged, all of its children will automatically inherit the tag and get executed along with the parent, unless they are excluded explicitly at runtime with a negated tag expression. Parent suite tests are not executed, but a suitepath hierarchy is kept. Sample test suite package with tags. @@ -1657,52 +1657,6 @@ create or replace package body ut_sample_test is end ut_sample_test; / ``` - -#### Tag Expressions - -Tag expressions are boolean expressions with the operators !, & and |. In addition, ( and ) can be used to adjust for operator precedence. - -| Operator | Meaning | -| -------- | --------| -| ! | not | -| & | and | -| \| | or | - -If you are tagging your tests across multiple dimensions, tag expressions help you to select which tests to execute. When tagging by test type (e.g., micro, integration, end-to-end) and feature (e.g., product, catalog, shipping), the following tag expressions can be useful. - - -| Tag Expression | Selection | -| -------- | --------| -| product | all tests for product | -| catalog \| shipping | all tests for catalog plus all tests for shipping | -| catalog & shipping | all tests for the intersection between catalog and shipping | -| product & !end-to-end | all tests for product, but not the end-to-end tests | -| (micro \| integration) & (product \| shipping) | all micro or integration tests for product or shipping | - - -Execution of the test is done by using the parameter `a_tags` with tag expressions - - -```sql linenums="1" -select * from table(ut.run(a_tags => 'fast|!complex')); -``` -The above call will execute all tests from `ut_sample_test` package as the whole suite is tagged with `api` because a suite meet expression condition. - -```sql linenums="1" -select * from table(ut.run(a_path => 'ut_sample_test',a_tags => 'api')); -``` -The above call will execute all tests from `ut_sample_test` package as the whole suite is tagged with `api` - -```sql linenums="1" -select * from table(ut.run(a_tags => 'complex')); -``` -The above call will execute only the `ut_sample_test.ut_refcursors1` test, as only the test `ut_refcursors1` is tagged with `complex` - -```sql linenums="1" -select * from table(ut.run(a_tags => 'fast')); -``` -The above call will execute both `ut_sample_test.ut_refcursors1` and `ut_sample_test.ut_test` tests, as both tests are tagged with `fast` - #### Tag naming convention Tags must follow the below naming convention: @@ -1715,45 +1669,11 @@ Tags must follow the below naming convention: - vertical bar (|) - exclamation point (!) - tag cannot be null or blank -- tag cannot contain whitespace - tag cannot start with a dash, e.g. `-some-stuff` is **not** a valid tag - tag cannot contain spaces, e.g. `test of batch`. To create a multi-word tag use underscores or dashes, e.g. `test_of_batch`, `test-of-batch` - leading and trailing spaces are ignored in tag name, e.g. `--%tags( tag1 , tag2 )` becomes `tag1` and `tag2` tag names -#### Excluding tests/suites by tags - -It is possible to exclude parts of test suites with tags. -In order to do so, prefix the tag name to exclude with a `!` (exclamation) sign when invoking the test run which is equivalent of `-` (dash) in legacy notation. -Examples (based on above sample test suite) - -```sql linenums="1" -select * from table(ut.run(a_tags => '(api|fast)&!complex')); -``` - -which is equivalent of legacy calling: - -```sql linenums="1" -select * from table(ut.run(a_tags => 'api,fast,-complex')); -``` - -or - -```sql linenums="1" -select * from table(ut.run(a_tags => '(api|fast)&(!complex&!test1)')); -``` - -which is equivalent of legacy calling: - -```sql linenums="1" -select * from table(ut.run(a_tags => 'api,fast,-complex,-test1')); -``` - -The above call will execute all suites/contexts/tests that are marked with any of tags `api` or `fast` except those suites/contexts/tests that are marked as `complex`. -Given the above example package `ut_sample_test`, only `ut_sample_test.ut_test` will be executed. - - - ### Suitepath It is very likely that the application for which you are going to introduce tests consists of many different packages, procedures and functions. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 978803b9a..9abc7c964 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -319,23 +319,85 @@ select * from table(ut.run('hr.test_apply_bonus', a_random_test_order_seed => 30 In addition to the path, you can filter the tests to be run by specifying tags. Tags are defined in the test / context / suite with the `--%tags`-annotation ([Read more](annotations.md#tags)). Multiple tags are separated by comma. -The framework applies `OR` logic to all specified tags so any test / suite that matches at least one tag will be included in the test run. + + +### Tag Expressions + +Tag expressions are boolean expressions with the operators !, & and |. In addition, ( and ) can be used to adjust for operator precedence. + +| Operator | Meaning | +| -------- | --------| +| ! | not | +| & | and | +| \| | or | + +If you are tagging your tests across multiple dimensions, tag expressions help you to select which tests to execute. When tagging by test type (e.g., micro, integration, end-to-end) and feature (e.g., product, catalog, shipping), the following tag expressions can be useful. + + +| Tag Expression | Selection | +| -------- | --------| +| product | all tests for product | +| catalog \| shipping | all tests for catalog plus all tests for shipping | +| catalog & shipping | all tests for the intersection between catalog and shipping | +| product & !end-to-end | all tests for product, but not the end-to-end tests | +| (micro \| integration) & (product \| shipping) | all micro or integration tests for product or shipping | + + +Execution of the test is done by using the parameter `a_tags` with tag expressions + ```sql linenums="1" -begin - ut.run('hr.test_apply_bonus', a_tags => 'test1,test2'); -end; +select * from table(ut.run(a_tags => 'fast|!complex')); +``` +The above call will execute all tests from `ut_sample_test` package as the whole suite is tagged with `api` because a suite meet expression condition. + +```sql linenums="1" +select * from table(ut.run(a_path => 'ut_sample_test',a_tags => 'api')); +``` +The above call will execute all tests from `ut_sample_test` package as the whole suite is tagged with `api` + +```sql linenums="1" +select * from table(ut.run(a_tags => 'complex')); ``` +The above call will execute only the `ut_sample_test.ut_refcursors1` test, as only the test `ut_refcursors1` is tagged with `complex` + ```sql linenums="1" -select * from table(ut.run('hr.test_apply_bonus', a_tags => 'suite1')) +select * from table(ut.run(a_tags => 'fast')); ``` +The above call will execute both `ut_sample_test.ut_refcursors1` and `ut_sample_test.ut_test` tests, as both tests are tagged with `fast` + +### Excluding tests/suites by tags -You can also exclude specific tags by adding a `-` (dash) in front of the tag +It is possible to exclude parts of test suites with tags. +In order to do so, prefix the tag name to exclude with a `!` (exclamation) sign when invoking the test run which is equivalent of `-` (dash) in legacy notation. +Examples (based on above sample test suite) ```sql linenums="1" -select * from table(ut.run('hr.test_apply_bonus', a_tags => '-suite1')) +select * from table(ut.run(a_tags => '(api|fast)&!complex')); ``` +which is equivalent of legacy calling: + +```sql linenums="1" +select * from table(ut.run(a_tags => 'api,fast,-complex')); +``` + +or + +```sql linenums="1" +select * from table(ut.run(a_tags => '(api|fast)&(!complex&!test1)')); +``` + +which is equivalent of legacy calling: + +```sql linenums="1" +select * from table(ut.run(a_tags => 'api,fast,-complex,-test1')); +``` + +The above call will execute all suites/contexts/tests that are marked with any of tags `api` or `fast` except those suites/contexts/tests that are marked as `complex`. +Given the above example package `ut_sample_test`, only `ut_sample_test.ut_test` will be executed. + + ## Keeping uncommitted data after test-run utPLSQL by default runs tests in autonomous transaction and performs automatic rollback to assure that tests do not impact one-another and do not have impact on the current session in your IDE. diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index f1e055a27..d5df54212 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -87,19 +87,18 @@ create or replace package body ut_suite_tag_filter is /* https://stackoverflow.com/questions/29634992/shunting-yard-validate-expression */ - function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list is + function shunt_logical_expression(a_tags in ut_varchar2_list) return ut_varchar2_list is l_operator_stack ut_stack := ut_stack(); - l_input_tokens ut_varchar2_list := tokenize_tags_string(a_tags); l_rnp_tokens ut_varchar2_list := ut_varchar2_list(); l_token varchar2(32767); l_expect_operand boolean := true; l_expect_operator boolean := false; l_idx pls_integer; begin - l_idx := l_input_tokens.first; + l_idx := a_tags.first; --Exuecute modified shunting algorithm WHILE (l_idx is not null) loop - l_token := l_input_tokens(l_idx); + l_token := a_tags(l_idx); if (l_token member of gc_operators and l_token member of gc_binary_operators) then if not(l_expect_operator) then raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); @@ -108,21 +107,21 @@ create or replace package body ut_suite_tag_filter is l_rnp_tokens.extend; l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; end loop; - l_operator_stack.push(l_input_tokens(l_idx)); + l_operator_stack.push(a_tags(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif (l_token member of gc_operators and l_token member of gc_unary_operators) then if not(l_expect_operand) then raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); end if; - l_operator_stack.push(l_input_tokens(l_idx)); + l_operator_stack.push(a_tags(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif l_token = '(' then if not(l_expect_operand) then raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); end if; - l_operator_stack.push(l_input_tokens(l_idx)); + l_operator_stack.push(a_tags(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif l_token = ')' then @@ -146,7 +145,7 @@ create or replace package body ut_suite_tag_filter is l_expect_operand := false; end if; - l_idx := l_input_tokens.next(l_idx); + l_idx := a_tags.next(l_idx); end loop; while l_operator_stack.peek is not null loop @@ -198,9 +197,10 @@ create or replace package body ut_suite_tag_filter is function create_where_filter(a_tags varchar2 ) return varchar2 is l_tags varchar2(4000); + l_tokenized_tags ut_varchar2_list; begin l_tags := replace(replace_legacy_tag_notation(a_tags),' '); - l_tags := conv_postfix_to_infix_sql(shunt_logical_expression(l_tags)); + l_tags := conv_postfix_to_infix_sql(shunt_logical_expression(tokenize_tags_string(l_tags))); l_tags := replace(l_tags, '|',' or '); l_tags := replace(l_tags ,'&',' and '); l_tags := replace(l_tags ,'!','not'); diff --git a/source/core/ut_suite_tag_filter.pks b/source/core/ut_suite_tag_filter.pks index 787c72603..37ba19111 100644 --- a/source/core/ut_suite_tag_filter.pks +++ b/source/core/ut_suite_tag_filter.pks @@ -31,7 +31,7 @@ create or replace package ut_suite_tag_filter authid definer is * and return a list of elements in Reverse Polish Notation ( postfix ) * As part of execution it will validate expression. */ - function shunt_logical_expression(a_tags in varchar2) return ut_varchar2_list; + function shunt_logical_expression(a_tags in ut_varchar2_list) return ut_varchar2_list; /* * Function that converts postfix notation into infix and creating a string of sql filter diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index a1d0be1f7..a396c6d25 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -3,24 +3,65 @@ create or replace package body test_ut_suite_tag_filter is procedure test_conversion_to_rpn is l_postfix ut3_develop.ut_varchar2_list; l_postfix_string varchar2(4000); + l_input_token ut3_develop.ut_varchar2_list; begin - l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression('A'); + l_input_token := ut3_develop.ut_suite_tag_filter.tokenize_tags_string('A'); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); ut.expect(l_postfix_string).to_equal('A'); - l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression('A|B'); + l_input_token := ut3_develop.ut_suite_tag_filter.tokenize_tags_string('A|B'); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); ut.expect(l_postfix_string).to_equal('AB|'); - l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression('(a|b)|c&d'); + l_input_token := ut3_develop.ut_suite_tag_filter.tokenize_tags_string('(a|b)|c&d'); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); ut.expect(l_postfix_string).to_equal('ab|cd&|'); - l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression('!a|b'); + l_input_token := ut3_develop.ut_suite_tag_filter.tokenize_tags_string('!a|b'); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); l_postfix_string := ut3_develop.ut_utils.table_to_clob(l_postfix,''); ut.expect(l_postfix_string).to_equal('a!b|'); end; + procedure test_conversion_opr_by_opr is + l_postfix ut3_develop.ut_varchar2_list; + l_input_token ut3_develop.ut_varchar2_list; + begin + l_input_token := ut3_develop.ut_varchar2_list('A','B'); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); + ut.fail('Expected exception but nothing was raised'); + end; + + procedure test_conversion_oprd_by_opd is + l_postfix ut3_develop.ut_varchar2_list; + l_input_token ut3_develop.ut_varchar2_list; + begin + l_input_token := ut3_develop.ut_varchar2_list('|','|'); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); + ut.fail('Expected exception but nothing was raised'); + end; + + procedure test_conversion_lb_by_oper is + l_postfix ut3_develop.ut_varchar2_list; + l_input_token ut3_develop.ut_varchar2_list; + begin + l_input_token := ut3_develop.ut_varchar2_list('(','A','|','B',')','('); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); + ut.fail('Expected exception but nothing was raised'); + end; + + procedure test_conversion_rb_by_oprd is + l_postfix ut3_develop.ut_varchar2_list; + l_input_token ut3_develop.ut_varchar2_list; + begin + l_input_token := ut3_develop.ut_varchar2_list(')','A'); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); + ut.fail('Expected exception but nothing was raised'); + end; + procedure conv_from_rpn_to_sql_filter is l_postfix_rpn ut3_develop.ut_varchar2_list; l_infix_string varchar2(4000); diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pks b/test/ut3_tester/core/test_ut_suite_tag_filter.pks index 093fab856..6d0b9ff69 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pks +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pks @@ -3,9 +3,29 @@ create or replace package test_ut_suite_tag_filter is --%suite(ut_suite_tag_filter) --%suitepath(utplsql.ut3_tester.core) + --%context( Conversion to Reverse Polish Notation) + --%test( Test conversion of expression into Reverse Polish Notation) procedure test_conversion_to_rpn; + --%test( Operator is followed by operator) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure test_conversion_opr_by_opr; + + --%test( Operand is followed by operand) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure test_conversion_oprd_by_opd; + + --%test( Left Bracket is followed by operator) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure test_conversion_lb_by_oper; + + --%test( Right Bracket is followed by operand) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure test_conversion_rb_by_oprd; + + --%endcontext + --%test( Test conversion of expression from Reverse Polish Notation into custom where filter for SQL) procedure conv_from_rpn_to_sql_filter; From 01e53646ba0e37b02ca476832061053e5aa5e786 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 14 Apr 2023 23:21:35 -0700 Subject: [PATCH 437/887] Update tests and code --- source/core/ut_suite_tag_filter.pkb | 36 +++++++++---------- source/core/ut_suite_tag_filter.pks | 9 ++++- .../core/test_ut_suite_tag_filter.pkb | 23 ++++++------ .../core/test_ut_suite_tag_filter.pks | 4 +-- 4 files changed, 38 insertions(+), 34 deletions(-) diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index d5df54212..df125091d 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -22,7 +22,9 @@ create or replace package body ut_suite_tag_filter is gc_operators constant ut_varchar2_list := ut_varchar2_list('|','&','!'); gc_unary_operators constant ut_varchar2_list := ut_varchar2_list('!'); -- right side associative operator gc_binary_operators constant ut_varchar2_list := ut_varchar2_list('|','&'); -- left side associative operator - + gc_tags_column_name constant varchar2(250) := 'tags'; + gc_exception_msg constant varchar2(200) := 'Invalid tag expression'; + type t_precedence_table is table of number index by varchar2(1); g_precedence t_precedence_table; @@ -101,7 +103,7 @@ create or replace package body ut_suite_tag_filter is l_token := a_tags(l_idx); if (l_token member of gc_operators and l_token member of gc_binary_operators) then if not(l_expect_operator) then - raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); end if; while l_operator_stack.top > 0 and (g_precedence(l_operator_stack.peek) > g_precedence(l_token)) loop l_rnp_tokens.extend; @@ -112,21 +114,21 @@ create or replace package body ut_suite_tag_filter is l_expect_operator:= false; elsif (l_token member of gc_operators and l_token member of gc_unary_operators) then if not(l_expect_operand) then - raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); end if; l_operator_stack.push(a_tags(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif l_token = '(' then if not(l_expect_operand) then - raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); end if; l_operator_stack.push(a_tags(l_idx)); l_expect_operand := true; l_expect_operator:= false; elsif l_token = ')' then if not(l_expect_operator) then - raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); end if; while l_operator_stack.peek <> '(' loop l_rnp_tokens.extend; @@ -137,7 +139,7 @@ create or replace package body ut_suite_tag_filter is l_expect_operator:= true; else if not(l_expect_operand) then - raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); end if; l_rnp_tokens.extend; l_rnp_tokens(l_rnp_tokens.last) :=l_token; @@ -150,7 +152,7 @@ create or replace package body ut_suite_tag_filter is while l_operator_stack.peek is not null loop if l_operator_stack.peek in ('(',')') then - raise_application_error(ut_utils.gc_invalid_tag_expression, 'Invalid Tag expression'); + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); end if; l_rnp_tokens.extend; l_rnp_tokens(l_rnp_tokens.last):=l_operator_stack.pop; @@ -159,13 +161,13 @@ create or replace package body ut_suite_tag_filter is return l_rnp_tokens; end shunt_logical_expression; - function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list) + function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list,a_tags_column_name in varchar2) return varchar2 is l_infix_stack ut_stack := ut_stack(); l_right_side varchar2(32767); l_left_side varchar2(32767); l_infix_exp varchar2(32767); - l_member_token varchar2(20) := ' member of tags'; + l_member_token varchar2(20) := ' member of '||a_tags_column_name; l_idx pls_integer; begin l_idx := a_postfix_exp.first; @@ -173,9 +175,6 @@ create or replace package body ut_suite_tag_filter is --If token is operand but also single tag if regexp_count(a_postfix_exp(l_idx),'[!()|&]') = 0 then l_infix_stack.push(q'[']'||a_postfix_exp(l_idx)||q'[']'||l_member_token); - --If token is operand but containing other expressions - elsif a_postfix_exp(l_idx) not member of gc_operators then - l_infix_stack.push(a_postfix_exp(l_idx)); --If token is unary operator not elsif a_postfix_exp(l_idx) member of gc_unary_operators then l_right_side := l_infix_stack.pop; @@ -197,10 +196,9 @@ create or replace package body ut_suite_tag_filter is function create_where_filter(a_tags varchar2 ) return varchar2 is l_tags varchar2(4000); - l_tokenized_tags ut_varchar2_list; begin l_tags := replace(replace_legacy_tag_notation(a_tags),' '); - l_tags := conv_postfix_to_infix_sql(shunt_logical_expression(tokenize_tags_string(l_tags))); + l_tags := conv_postfix_to_infix_sql(shunt_logical_expression(tokenize_tags_string(l_tags)),gc_tags_column_name); l_tags := replace(l_tags, '|',' or '); l_tags := replace(l_tags ,'&',' and '); l_tags := replace(l_tags ,'!','not'); @@ -224,7 +222,7 @@ create or replace package body ut_suite_tag_filter is q'[ with suites_mv as ( - select c.id,value(c) as obj,c.path as path,c.self_type,c.object_owner,c.tags + select c.id,value(c) as obj,c.path as path,c.self_type,c.object_owner,c.tags as ]'||gc_tags_column_name||q'[ from table(:suite_items) c ), suites_matching_expr as ( @@ -234,17 +232,17 @@ with and ]'||l_tags||q'[ ), tests_matching_expr as ( - select c.id,c.path as path,c.self_type,c.object_owner,c.tags - from suites_mv c where c.self_type in ('UT_TEST') + select c.id,c.path as path,c.self_type,c.object_owner,c.tags as ]'||gc_tags_column_name||q'[ + from suites_mv c where c.self_type in ('UT_TEST') and ]'||l_tags||q'[ ), tests_with_tags_inh_from_suite as ( - select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner + select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags as ]'||gc_tags_column_name||q'[ ,c.object_owner from suites_mv c join suites_matching_expr t on (c.path||'.' like t.path || '.%' /*all descendants and self*/ and c.object_owner = t.object_owner) ), tests_with_tags_prom_to_suite as ( - select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags tags,c.object_owner + select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags as ]'||gc_tags_column_name||q'[ ,c.object_owner from suites_mv c join tests_matching_expr t on (t.path||'.' like c.path || '.%' /*all ancestors and self*/ and c.object_owner = t.object_owner) ) diff --git a/source/core/ut_suite_tag_filter.pks b/source/core/ut_suite_tag_filter.pks index 37ba19111..e824ae275 100644 --- a/source/core/ut_suite_tag_filter.pks +++ b/source/core/ut_suite_tag_filter.pks @@ -37,8 +37,15 @@ create or replace package ut_suite_tag_filter authid definer is * Function that converts postfix notation into infix and creating a string of sql filter * that checking a tags collections for tags according to posted logic. */ - function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list) return varchar2; + function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list,a_tags_column_name in varchar2) + return varchar2; + /* + * Generates a part where clause sql + */ + function create_where_filter(a_tags varchar2) + return varchar2; + function apply( a_unfiltered_rows ut_suite_cache_rows, a_tags varchar2 := null diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index a396c6d25..edfb27cfc 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -62,21 +62,20 @@ create or replace package body test_ut_suite_tag_filter is ut.fail('Expected exception but nothing was raised'); end; - procedure conv_from_rpn_to_sql_filter is - l_postfix_rpn ut3_develop.ut_varchar2_list; - l_infix_string varchar2(4000); + procedure conv_from_tag_to_sql_filter is + l_sql_filter varchar2(4000); begin - l_postfix_rpn := ut3_develop.ut_varchar2_list('A'); - l_infix_string := ut3_develop.ut_suite_tag_filter.conv_postfix_to_infix_sql(l_postfix_rpn); - ut.expect(l_infix_string).to_equal(q'['A' member of tags]'); + l_sql_filter := ut3_develop.ut_suite_tag_filter.create_where_filter('test1'); + ut.expect(l_sql_filter).to_equal(q'['test1' member of tags]'); - l_postfix_rpn := ut3_develop.ut_varchar2_list('A','B','|'); - l_infix_string := ut3_develop.ut_suite_tag_filter.conv_postfix_to_infix_sql(l_postfix_rpn); - ut.expect(l_infix_string).to_equal(q'[('A' member of tags|'B' member of tags)]'); + l_sql_filter := ut3_develop.ut_suite_tag_filter.create_where_filter('test1|test2'); + ut.expect(l_sql_filter).to_equal(q'[('test1' member of tags or 'test2' member of tags)]'); - l_postfix_rpn := ut3_develop.ut_varchar2_list('a','b','!','|'); - l_infix_string := ut3_develop.ut_suite_tag_filter.conv_postfix_to_infix_sql(l_postfix_rpn); - ut.expect(l_infix_string).to_equal(q'[('a' member of tags|!('b' member of tags))]'); + l_sql_filter := ut3_develop.ut_suite_tag_filter.create_where_filter('test1|!test2'); + ut.expect(l_sql_filter).to_equal(q'[('test1' member of tags or not('test2' member of tags))]'); + + l_sql_filter := ut3_develop.ut_suite_tag_filter.create_where_filter('test1&!test2'); + ut.expect(l_sql_filter).to_equal(q'[('test1' member of tags and not('test2' member of tags))]'); end; end test_ut_suite_tag_filter; diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pks b/test/ut3_tester/core/test_ut_suite_tag_filter.pks index 6d0b9ff69..0f84b751b 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pks +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pks @@ -26,8 +26,8 @@ create or replace package test_ut_suite_tag_filter is --%endcontext - --%test( Test conversion of expression from Reverse Polish Notation into custom where filter for SQL) - procedure conv_from_rpn_to_sql_filter; + --%test( Test conversion of expression from tag into custom where filter for SQL) + procedure conv_from_tag_to_sql_filter; end test_ut_suite_tag_filter; / From dc0b4a60dfa799b360245bc7c39480e11861f564 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 17 Apr 2023 19:37:03 -0700 Subject: [PATCH 438/887] Addressing changes via PR review. --- docs/userguide/annotations.md | 40 +----------- docs/userguide/running-unit-tests.md | 90 +++++++++++++++++++------- source/core/ut_suite_cache_manager.pkb | 14 +--- source/core/ut_suite_cache_manager.pks | 9 ++- source/core/ut_suite_manager.pkb | 5 +- 5 files changed, 75 insertions(+), 83 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 552b02b52..17fb7d1f2 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1617,46 +1617,8 @@ or Tags are defined as a comma separated list within the `--%tags` annotation. When a suite/context is tagged, all of its children will automatically inherit the tag and get executed along with the parent, unless they are excluded explicitly at runtime with a negated tag expression. -Parent suite tests are not executed, but a suitepath hierarchy is kept. +See [running unit tests](running-unit-tests.md) for more information on using tags to filter test suites that are to be executed. -Sample test suite package with tags. -```sql linenums="1" -create or replace package ut_sample_test is - - --%suite(Sample Test Suite) - --%tags(api) - - --%test(Compare Ref Cursors) - --%tags(complex,fast) - procedure ut_refcursors1; - - --%test(Run equality test) - --%tags(simple,fast) - procedure ut_test; - -end ut_sample_test; -/ - -create or replace package body ut_sample_test is - - procedure ut_refcursors1 is - v_actual sys_refcursor; - v_expected sys_refcursor; - begin - open v_expected for select 1 as test from dual; - open v_actual for select 2 as test from dual; - - ut.expect(v_actual).to_equal(v_expected); - end; - - procedure ut_test is - begin - ut.expect(1).to_equal(0); - end; - -end ut_sample_test; -/ -``` #### Tag naming convention Tags must follow the below naming convention: diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 9abc7c964..7597ae72a 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -323,7 +323,7 @@ Multiple tags are separated by comma. ### Tag Expressions -Tag expressions are boolean expressions with the operators !, & and |. In addition, ( and ) can be used to adjust for operator precedence. +Tag expressions are boolean expressions created by combining tags with the `!`, `&`, `|` operators. Tag expressions can be grouped using `(` and `)` braces. Grouping tag expressions affects operator precedence. | Operator | Meaning | | -------- | --------| @@ -338,18 +338,76 @@ If you are tagging your tests across multiple dimensions, tag expressions help y | -------- | --------| | product | all tests for product | | catalog \| shipping | all tests for catalog plus all tests for shipping | -| catalog & shipping | all tests for the intersection between catalog and shipping | -| product & !end-to-end | all tests for product, but not the end-to-end tests | +| catalog & shipping | all tests that are tagged with both `catalog` and `shipping` tags | +| product & !end-to-end | all tests tagged `product`, except the tests tagged `end-to-end` | | (micro \| integration) & (product \| shipping) | all micro or integration tests for product or shipping | -Execution of the test is done by using the parameter `a_tags` with tag expressions +Taking the last expression above `(micro | integration) & (product | shipping)` +| --%tags |included in run | +| -------- | --------| +| micro | no | +| integration | no | +| micro | no | +| product | no | +| shipping | no | +| micro | no | +| micro, integration | no | +| product, shipping | no | +| micro, product | yes | +| micro, shipping | yes | +| integration, product | yes | +| integration, shipping | yes | +| integration, micro, shipping | yes | +| integration, micro, product | yes | +| integration, shipping ,product | yes | +| micro, shipping ,product | yes | +| integration, micro, shipping ,product | yes | + + +### Sample execution of test with tags. + +Execution of the test with tag expressions is done using the parameter `a_tags`. +Given a test package `ut_sample_test` defined below ```sql linenums="1" -select * from table(ut.run(a_tags => 'fast|!complex')); +create or replace package ut_sample_test is + + --%suite(Sample Test Suite) + --%tags(api) + + --%test(Compare Ref Cursors) + --%tags(complex,fast) + procedure ut_refcursors1; + + --%test(Run equality test) + --%tags(simple,fast) + procedure ut_test; + +end ut_sample_test; +/ + +create or replace package body ut_sample_test is + + procedure ut_refcursors1 is + v_actual sys_refcursor; + v_expected sys_refcursor; + begin + open v_expected for select 1 as test from dual; + open v_actual for select 2 as test from dual; + + ut.expect(v_actual).to_equal(v_expected); + end; + + procedure ut_test is + begin + ut.expect(1).to_equal(0); + end; + +end ut_sample_test; +/ ``` -The above call will execute all tests from `ut_sample_test` package as the whole suite is tagged with `api` because a suite meet expression condition. ```sql linenums="1" select * from table(ut.run(a_path => 'ut_sample_test',a_tags => 'api')); @@ -357,9 +415,9 @@ select * from table(ut.run(a_path => 'ut_sample_test',a_tags => 'api')); The above call will execute all tests from `ut_sample_test` package as the whole suite is tagged with `api` ```sql linenums="1" -select * from table(ut.run(a_tags => 'complex')); +select * from table(ut.run(a_tags => 'fast&complex')); ``` -The above call will execute only the `ut_sample_test.ut_refcursors1` test, as only the test `ut_refcursors1` is tagged with `complex` +The above call will execute only the `ut_sample_test.ut_refcursors1` test, as only the test `ut_refcursors1` is tagged with `complex` and `fast` ```sql linenums="1" select * from table(ut.run(a_tags => 'fast')); @@ -376,25 +434,13 @@ Examples (based on above sample test suite) select * from table(ut.run(a_tags => '(api|fast)&!complex')); ``` -which is equivalent of legacy calling: - -```sql linenums="1" -select * from table(ut.run(a_tags => 'api,fast,-complex')); -``` - or ```sql linenums="1" -select * from table(ut.run(a_tags => '(api|fast)&(!complex&!test1)')); -``` - -which is equivalent of legacy calling: - -```sql linenums="1" -select * from table(ut.run(a_tags => 'api,fast,-complex,-test1')); +select * from table(ut.run(a_tags => '(api|fast)&!complex&!test1')); ``` -The above call will execute all suites/contexts/tests that are marked with any of tags `api` or `fast` except those suites/contexts/tests that are marked as `complex`. +The above call will execute all suites/contexts/tests that are marked with any of tags `api` or `fast` except those suites/contexts/tests that are marked as `complex` and except those suites/contexts/tests that are marked as `test1`. Given the above example package `ut_sample_test`, only `ut_sample_test.ut_test` will be executed. diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 3bb679517..680624f02 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -285,18 +285,6 @@ create or replace package body ut_suite_cache_manager is return l_results; end; - function get_cached_suites( - a_schema_paths ut_path_items, - a_random_seed positive := null - ) return ut_suite_cache_rows is - l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); - l_schema_paths ut_path_items; - begin - l_schema_paths := a_schema_paths; - l_suite_items := get_suite_items(a_schema_paths); - return l_suite_items; - end; - function get_schema_parse_time(a_schema_name varchar2) return timestamp result_cache is l_cache_parse_time timestamp; begin @@ -443,7 +431,7 @@ create or replace package body ut_suite_cache_manager is a_schema_paths ut_path_items ) return ut_suite_cache_rows is begin - return get_cached_suite_rows(get_cached_suites( a_schema_paths )); + return get_cached_suite_rows(get_suite_items(a_schema_paths)); end; function get_suite_items_info( diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index c217abeed..81b1e0136 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -58,11 +58,6 @@ create or replace package ut_suite_cache_manager authid definer is a_suites_filtered ut_suite_cache_rows ) return ut_suite_cache_rows; - function get_cached_suites( - a_schema_paths ut_path_items, - a_random_seed positive := null - ) return ut_suite_cache_rows; - function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items; /* @@ -77,6 +72,10 @@ create or replace package ut_suite_cache_manager authid definer is function get_suite_items_info( a_suite_cache_items ut_suite_cache_rows ) return ut_suite_items_info; + + function get_suite_items ( + a_schema_paths ut_path_items + ) return ut_suite_cache_rows; /* * Retrieves list of cached suite packages. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index f8a2e002c..c46ba66b8 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -360,10 +360,7 @@ create or replace package body ut_suite_manager is l_filtered_rows ut_suite_cache_rows; l_result t_cached_suites_cursor; begin - l_unfiltered_rows := ut_suite_cache_manager.get_cached_suites( - a_schema_paths, - a_random_seed - ); + l_unfiltered_rows := ut_suite_cache_manager.get_suite_items(a_schema_paths); l_tag_filter_applied := ut_suite_tag_filter.apply(l_unfiltered_rows,a_tags); l_filtered_rows := get_filtered_cursor(ut_suite_cache_manager.get_cached_suite_rows(l_tag_filter_applied),a_skip_all_objects); From ef1c02b3eee5b3a5a71076f1db24a58765cddbda Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 18 Apr 2023 15:36:11 -0700 Subject: [PATCH 439/887] Update docs --- docs/userguide/running-unit-tests.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 7597ae72a..fb9a9f602 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -440,7 +440,13 @@ or select * from table(ut.run(a_tags => '(api|fast)&!complex&!test1')); ``` -The above call will execute all suites/contexts/tests that are marked with any of tags `api` or `fast` except those suites/contexts/tests that are marked as `complex` and except those suites/contexts/tests that are marked as `test1`. +which is equivalent of exclusion on whole expression + +```sql linenums="1" +select * from table(ut.run(a_tags => '(api|fast)&!(complex|test1)')); +``` + +The above calls will execute all suites/contexts/tests that are marked with any of tags `api` or `fast` except those suites/contexts/tests that are marked as `complex` and except those suites/contexts/tests that are marked as `test1`. Given the above example package `ut_sample_test`, only `ut_sample_test.ut_test` will be executed. From 1551ea5583152a0d0b726005906aa6e51f42c38a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 25 Apr 2023 09:30:40 -0700 Subject: [PATCH 440/887] Adding any and none --- docs/userguide/annotations.md | 1 + docs/userguide/running-unit-tests.md | 75 ++++++++++++ source/core/ut_suite_tag_filter.pkb | 15 ++- test/ut3_tester_helper/run_helper.pkb | 160 +++++++++++++++++++++++++- test/ut3_user/api/test_ut_run.pkb | 25 ++++ 5 files changed, 271 insertions(+), 5 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 17fb7d1f2..4ec6de59d 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1634,6 +1634,7 @@ Tags must follow the below naming convention: - tag cannot start with a dash, e.g. `-some-stuff` is **not** a valid tag - tag cannot contain spaces, e.g. `test of batch`. To create a multi-word tag use underscores or dashes, e.g. `test_of_batch`, `test-of-batch` - leading and trailing spaces are ignored in tag name, e.g. `--%tags( tag1 , tag2 )` becomes `tag1` and `tag2` tag names +- tag cannot be one of two reserved words : `none` and `any`, any tags with that will not be considered. ### Suitepath diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index fb9a9f602..b3a974d53 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -325,6 +325,8 @@ Multiple tags are separated by comma. Tag expressions are boolean expressions created by combining tags with the `!`, `&`, `|` operators. Tag expressions can be grouped using `(` and `)` braces. Grouping tag expressions affects operator precedence. +Two special expressions are supported, `any` and `none`, which select all tests with any tags at all, and all tests without any tags, respectively. These special expressions may be combined with other expressions just like normal tags. When using `none` be aware that if the suite is tagged it will exclude any tests and children belonging to that suite. + | Operator | Meaning | | -------- | --------| | ! | not | @@ -450,6 +452,79 @@ The above calls will execute all suites/contexts/tests that are marked with any Given the above example package `ut_sample_test`, only `ut_sample_test.ut_test` will be executed. +### Sample execution with `any` and `none` + +Given a sample test package: + +```sql linenums="1" +create or replace package ut_sample_test is + + --%suite(Sample Test Suite) + + --%test(Compare Ref Cursors) + --%tags(complex,fast) + procedure ut_refcursors1; + + --%test(Run equality test) + --%tags(simple,fast) + procedure ut_test; + + --%test(Run equality test no tag) + procedure ut_test_no_tag; + +end ut_sample_test; +/ + +create or replace package body ut_sample_test is + + procedure ut_refcursors1 is + v_actual sys_refcursor; + v_expected sys_refcursor; + begin + open v_expected for select 1 as test from dual; + open v_actual for select 2 as test from dual; + + ut.expect(v_actual).to_equal(v_expected); + end; + + procedure ut_test is + begin + ut.expect(1).to_equal(0); + end; + + procedure ut_test_no_tag is + begin + ut.expect(1).to_equal(0); + end; + +end ut_sample_test; +/ +``` + +```sql linenums="1" +select * from table(ut.run(a_path => 'ut_sample_test',a_tags => 'none')); +``` + +The above call will execute tests `ut_test_no_tag` + +```sql linenums="1" +select * from table(ut.run(a_path => 'ut_sample_test',a_tags => 'any')); +``` + +The above call will execute tests `ut_test` and `ut_refcursors1` + +```sql linenums="1" +select * from table(ut.run(a_path => 'ut_sample_test',a_tags => 'none|simple')); +``` + +The above call will execute tests `ut_test_no_tag` and `ut_test` + +```sql linenums="1" +select * from table(ut.run(a_tags => 'none|!simple')); +``` + +The above call will execute tests `ut_test_no_tag` and `ut_refcursors1` + ## Keeping uncommitted data after test-run utPLSQL by default runs tests in autonomous transaction and performs automatic rollback to assure that tests do not impact one-another and do not have impact on the current session in your IDE. diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index df125091d..2d9436301 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -22,9 +22,10 @@ create or replace package body ut_suite_tag_filter is gc_operators constant ut_varchar2_list := ut_varchar2_list('|','&','!'); gc_unary_operators constant ut_varchar2_list := ut_varchar2_list('!'); -- right side associative operator gc_binary_operators constant ut_varchar2_list := ut_varchar2_list('|','&'); -- left side associative operator + gc_reserved_tag_words constant ut_varchar2_list := ut_varchar2_list('none','any'); gc_tags_column_name constant varchar2(250) := 'tags'; gc_exception_msg constant varchar2(200) := 'Invalid tag expression'; - + type t_precedence_table is table of number index by varchar2(1); g_precedence t_precedence_table; @@ -172,8 +173,17 @@ create or replace package body ut_suite_tag_filter is begin l_idx := a_postfix_exp.first; while ( l_idx is not null) loop + --If the token we got is a none or any keyword + if a_postfix_exp(l_idx) member of gc_reserved_tag_words then + + l_infix_stack.push( + case + when a_postfix_exp(l_idx) = 'none' then '('||a_tags_column_name||' is empty or '||a_tags_column_name||' is null)' + else a_tags_column_name||' is not empty' + end + ); --If token is operand but also single tag - if regexp_count(a_postfix_exp(l_idx),'[!()|&]') = 0 then + elsif regexp_count(a_postfix_exp(l_idx),'[!()|&]') = 0 then l_infix_stack.push(q'[']'||a_postfix_exp(l_idx)||q'[']'||l_member_token); --If token is unary operator not elsif a_postfix_exp(l_idx) member of gc_unary_operators then @@ -256,7 +266,6 @@ with where ]'||l_tags||q'[ ) ) t where c.id = t.id and r_num = 1 ]'; - execute immediate l_sql bulk collect into l_suite_tags using a_suite_items; return l_suite_tags; end; diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index c73564798..6289b1642 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -431,12 +431,162 @@ create or replace package body run_helper is end test_tag_pkg_3; ]'; + execute immediate q'[create or replace package suite1_level1_pkg is + + --%suite(suite1_level1) + --%suitepath(any_none) + --%rollback(manual) + + --%test(Test 1 from Suite1 on level 1) + --%tags(suite1,level1,test1,test1_level1) + procedure test1_level1; + + --%test(Test 2 from Suite1 on level 1) + procedure test2_level1; + + end suite1_level1_pkg; + ]'; + + execute immediate q'[create or replace package body suite1_level1_pkg is + procedure test1_level1 is + begin + dbms_output.put_line('suite1_level1_pkg.test1_level1 executed'); + end; + procedure test2_level1 is + begin + dbms_output.put_line('suite1_level1_pkg.test2_level1 executed'); + end; + end suite1_level1_pkg; + ]'; + + execute immediate q'[create or replace package suite1_1_level2_pkg is + + --%suite(suite1_1_level2) + --%suitepath(any_none.suite1_level1) + --%rollback(manual) + + --%test(Test 1 from Suite1_2 on level 2) + --%tags(level2,test1,test1_level2) + procedure suite1_1_test1_level2; + + --%test(Test 2 from Suite1_2 on level 2) + procedure suite1_1_test2_level2; + + end suite1_1_level2_pkg; + ]'; + + execute immediate q'[create or replace package body suite1_1_level2_pkg is + procedure suite1_1_test1_level2 is + begin + dbms_output.put_line('suite1_1_level2_pkg.suite1_1_test1_level2 executed'); + end; + procedure suite1_1_test2_level2 is + begin + dbms_output.put_line('suite1_1_level2_pkg.suite1_1_test2_level2 executed'); + end; + end suite1_1_level2_pkg; + ]'; + + execute immediate q'[create or replace package suite1_2_level2_pkg is + + --%suite(suite1_2_level2) + --%tags(level2,suite1_2,suites) + --%suitepath(any_none.suite1_level1) + --%rollback(manual) + + --%test(Test 1 from Suite1_2 on level 2) + procedure suite1_2_test1_level2; + + --%test(Test 2 from Suite1_2 on level 2) + --%tags(level2,test2,test2_level2) + procedure suite1_2_test2_level1; + + end suite1_2_level2_pkg; + ]'; + + execute immediate q'[create or replace package body suite1_2_level2_pkg is + procedure suite1_2_test1_level2 is + begin + dbms_output.put_line('suite1_2_level2_pkg.suite1_2_test1_level2 executed'); + end; + procedure suite1_2_test2_level1 is + begin + dbms_output.put_line('suite1_2_level2_pkg.suite1_2_test2_level1 executed'); + end; + end suite1_2_level2_pkg; + ]'; + + execute immediate q'[create or replace package suite2_level1_pkg is + + --%suite(suite2_level1) + --%tags(level1,suite2,suites) + --%suitepath(any_none) + --%rollback(manual) + + --%test(Test 1 from Suite1 on level 1) + --%tags(suite2,level1,test1,test1_level1) + procedure test1_level1; + + --%test(Test 2 from Suite1 on level 1) + procedure test2_level1; + + end suite2_level1_pkg; + ]'; + + execute immediate q'[create or replace package body suite2_level1_pkg is + procedure test1_level1 is + begin + dbms_output.put_line('suite2_level1_pkg.test1_level1 executed'); + end; + procedure test2_level1 is + begin + dbms_output.put_line('suite2_level1_pkg.test2_level1 executed'); + end; + end suite2_level1_pkg; + ]'; + + execute immediate q'[create or replace package suite2_2_level2_pkg is + + --%suite(suite2_2_level2) + --%tags(level2,suite2_2,suites) + --%suitepath(any_none.suite2_level1) + --%rollback(manual) + + --%test(Test 1 from Suite2_2 on level 2) + procedure suite2_2_test1_level2; + + --%test(Test 2 from Suite2_2 on level 2) + --%tags(level2,test2,test2_level2) + procedure suite2_2_test2_level2; + + end suite2_2_level2_pkg; + ]'; + + execute immediate q'[create or replace package body suite2_2_level2_pkg is + procedure suite2_2_test1_level2 is + begin + dbms_output.put_line('suite2_2_level2_pkg.suite2_2_test1_level2 executed'); + end; + procedure suite2_2_test2_level2 is + begin + dbms_output.put_line('suite2_2_level2_pkg.suite2_2_test2_level2 executed'); + end; + end suite2_2_level2_pkg; + ]'; + + execute immediate q'[grant execute on test_package_1 to public]'; execute immediate q'[grant execute on test_package_2 to public]'; execute immediate q'[grant execute on test_package_3 to public]'; execute immediate q'[grant execute on test_tag_pkg_1 to public]'; execute immediate q'[grant execute on test_tag_pkg_2 to public]'; - execute immediate q'[grant execute on test_tag_pkg_3 to public]'; + execute immediate q'[grant execute on test_tag_pkg_3 to public]'; + + execute immediate q'[grant execute on suite1_level1_pkg to public]'; + execute immediate q'[grant execute on suite1_1_level2_pkg to public]'; + execute immediate q'[grant execute on suite1_2_level2_pkg to public]'; + execute immediate q'[grant execute on suite2_level1_pkg to public]'; + execute immediate q'[grant execute on suite2_2_level2_pkg to public]'; end; procedure drop_ut3_user_tests is @@ -447,7 +597,13 @@ create or replace package body run_helper is execute immediate q'[drop package test_package_3]'; execute immediate q'[drop package test_tag_pkg_1]'; execute immediate q'[drop package test_tag_pkg_2]'; - execute immediate q'[drop package test_tag_pkg_3]'; + execute immediate q'[drop package test_tag_pkg_3]'; + + execute immediate q'[drop package suite2_2_level2_pkg]'; + execute immediate q'[drop package suite2_level1_pkg]'; + execute immediate q'[drop package suite1_2_level2_pkg]'; + execute immediate q'[drop package suite1_level1_pkg]'; + execute immediate q'[drop package suite1_1_level2_pkg]'; end; procedure create_test_suite is diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 25b50343e..e80235744 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1244,6 +1244,31 @@ procedure tag_exclude_run_fun_pth_lst_lg is ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test3%executed%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_2.test4%executed%' ); ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%test_package_3.test6%executed%' ); + + l_results := ut3_tester_helper.run_helper.run(a_tags => 'any'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite2_level1_pkg.test1_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite2_level1_pkg.test2_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite1_level1_pkg.test1_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite2_2_level2_pkg.suite2_2_test1_level2 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite2_2_level2_pkg.suite2_2_test2_level2 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite1_2_level2_pkg.suite1_2_test1_level2 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite1_2_level2_pkg.suite1_2_test2_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite1_1_level2_pkg.suite1_1_test1_level2 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite1_level1_pkg.test2_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite1_1_level2_pkg.suite1_1_test2_level2 executed%' ); + + l_results := ut3_tester_helper.run_helper.run(a_tags => 'none'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite1_level1_pkg.test2_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%suite1_1_level2_pkg.suite1_1_test2_level2 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite2_level1_pkg.test1_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite2_level1_pkg.test2_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite1_level1_pkg.test1_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite2_2_level2_pkg.suite2_2_test1_level2 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite2_2_level2_pkg.suite2_2_test2_level2 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite1_2_level2_pkg.suite1_2_test1_level2 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite1_2_level2_pkg.suite1_2_test2_level1 executed%' ); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%suite1_1_level2_pkg.suite1_1_test1_level2 executed%' ); + end; From 9dee7e0ffd4bfee0af948befd4f6b739506c11d1 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 25 Apr 2023 17:08:42 -0700 Subject: [PATCH 441/887] Update docs --- docs/userguide/running-unit-tests.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index b3a974d53..044ffdb35 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -325,7 +325,7 @@ Multiple tags are separated by comma. Tag expressions are boolean expressions created by combining tags with the `!`, `&`, `|` operators. Tag expressions can be grouped using `(` and `)` braces. Grouping tag expressions affects operator precedence. -Two special expressions are supported, `any` and `none`, which select all tests with any tags at all, and all tests without any tags, respectively. These special expressions may be combined with other expressions just like normal tags. When using `none` be aware that if the suite is tagged it will exclude any tests and children belonging to that suite. +Two special expressions are supported, `any` and `none`, which select all tests with any tags at all, and all tests without any tags, respectively. These special expressions may be combined with other expressions just like normal tags. When using `none` be aware that if the suite is tagged it will exclude any tests and suites below. | Operator | Meaning | | -------- | --------| From beb9a3a3207e208b7e5e2687b6d4751b4ee705b9 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 26 Apr 2023 17:30:32 -0700 Subject: [PATCH 442/887] Resolving PR --- docs/userguide/annotations.md | 2 +- docs/userguide/running-unit-tests.md | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 4ec6de59d..7c7015872 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1634,7 +1634,7 @@ Tags must follow the below naming convention: - tag cannot start with a dash, e.g. `-some-stuff` is **not** a valid tag - tag cannot contain spaces, e.g. `test of batch`. To create a multi-word tag use underscores or dashes, e.g. `test_of_batch`, `test-of-batch` - leading and trailing spaces are ignored in tag name, e.g. `--%tags( tag1 , tag2 )` becomes `tag1` and `tag2` tag names -- tag cannot be one of two reserved words : `none` and `any`, any tags with that will not be considered. +- tag cannot be one of two reserved words: `none` and `any`. `none` and `any` as a tag will be treated as no tag ### Suitepath diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 044ffdb35..e12fd6b32 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -325,7 +325,13 @@ Multiple tags are separated by comma. Tag expressions are boolean expressions created by combining tags with the `!`, `&`, `|` operators. Tag expressions can be grouped using `(` and `)` braces. Grouping tag expressions affects operator precedence. -Two special expressions are supported, `any` and `none`, which select all tests with any tags at all, and all tests without any tags, respectively. These special expressions may be combined with other expressions just like normal tags. When using `none` be aware that if the suite is tagged it will exclude any tests and suites below. +Two reserved keywords, `any` and `none`, can be used when creating a tag expression to run tests. +- `any` keyword represents tests and suites with any tags +- `none` keyword represents tests and suites without tags + +These keywords may be combined with other expressions just like normal tags. + +**Note:** When specifying `none`, be aware that it will exclude any tests/suites/contexts contained within a tagged suite. | Operator | Meaning | | -------- | --------| From 46ffe739386b92dc831a46227c17326bb85f459e Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 27 Apr 2023 11:48:26 -0700 Subject: [PATCH 443/887] Update note --- docs/userguide/running-unit-tests.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index e12fd6b32..2b18a3d3b 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -331,7 +331,8 @@ Two reserved keywords, `any` and `none`, can be used when creating a tag express These keywords may be combined with other expressions just like normal tags. -**Note:** When specifying `none`, be aware that it will exclude any tests/suites/contexts contained within a tagged suite. +!!! note + When specifying `none`, be aware that it will exclude any tests/suites/contexts contained within a tagged suite. | Operator | Meaning | | -------- | --------| From 73e9cf32bce4f0b8dbd38f7da63ad253b0ae42b6 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Thu, 27 Apr 2023 22:09:18 +0300 Subject: [PATCH 444/887] Added missing test for multiple expectation failures with exception thrown. --- test/ut3_user/reporters.pkb | 5 +-- .../reporters/test_teamcity_reporter.pkb | 37 ++++++++++++++++++- .../reporters/test_teamcity_reporter.pks | 5 ++- 3 files changed, 41 insertions(+), 6 deletions(-) diff --git a/test/ut3_user/reporters.pkb b/test/ut3_user/reporters.pkb index b6d43b144..031683615 100644 --- a/test/ut3_user/reporters.pkb +++ b/test/ut3_user/reporters.pkb @@ -90,11 +90,10 @@ as procedure erroring_test is - l_variable integer; + l_integer_variable integer; begin dbms_output.put_line(''); - l_variable := 'a string'; - ut3_develop.ut.expect(l_variable).to_equal(1); + l_integer_variable := 'a string'; end; procedure disabled_test diff --git a/test/ut3_user/reporters/test_teamcity_reporter.pkb b/test/ut3_user/reporters/test_teamcity_reporter.pkb index 7c4c1e513..517ddc037 100644 --- a/test/ut3_user/reporters/test_teamcity_reporter.pkb +++ b/test/ut3_user/reporters/test_teamcity_reporter.pkb @@ -36,6 +36,9 @@ create or replace package body test_teamcity_reporter as --%test procedure multi_failure; + + --%test + procedure multi_failure_on_error; end;]'; execute immediate q'[create or replace package body check_multiple_failures is procedure multi_failure is @@ -44,6 +47,14 @@ create or replace package body test_teamcity_reporter as ut3_develop.ut.expect(2).to_equal(1); ut3_develop.ut.expect('Bad').to_equal('Good'); end; + procedure multi_failure_on_error is + l_integer_variable integer; + begin + ut3_develop.ut.expect(1).to_be_null; + ut3_develop.ut.expect(2).to_equal(1); + ut3_develop.ut.expect('Bad').to_equal('Good'); + l_integer_variable := 'a string'; + end; end;]'; end; @@ -132,7 +143,7 @@ create or replace package body test_teamcity_reporter as ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); end; - procedure report_mutiple_expectations is + procedure report_multiple_expectations is l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin @@ -146,7 +157,29 @@ create or replace package body test_teamcity_reporter as --act select * bulk collect into l_output_data - from table(ut3_develop.ut.run('check_multiple_failures',ut3_develop.ut_teamcity_reporter())); + from table(ut3_develop.ut.run('check_multiple_failures.multi_failure',ut3_develop.ut_teamcity_reporter())); + + --assert + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); + end; + + procedure report_multiple_expect_on_err is + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'{%##teamcity[testSuiteStarted timestamp='%' name='check_multiple_failures'] +%##teamcity[testStarted timestamp='%' captureStandardOutput='true' name='ut3_user.check_multiple_failures.multi_failure_on_error'] +%##teamcity[testStdErr timestamp='%' name='ut3_user.check_multiple_failures.multi_failure_on_error' out='Test exception:|nORA-06502: PL/SQL: %: character to number conversion error|nORA-06512: at "UT3_USER.CHECK_MULTIPLE_FAILURES", line %|nORA-06512: at %|n'] +%##teamcity[testFailed timestamp='%' details='Test exception:|nORA-06502: PL/SQL: %: character to number conversion error|nORA-06512: at "UT3_USER.CHECK_MULTIPLE_FAILURES", line %|nORA-06512: at %|n' message='Error occured' name='ut3_user.check_multiple_failures.multi_failure_on_error'] +%##teamcity[testFailed timestamp='%' details='Actual: 1 (number) was expected to be null' name='ut3_user.check_multiple_failures.multi_failure_on_error'] +%##teamcity[testFailed timestamp='%' details='Actual: 2 (number) was expected to equal: 1 (number)' name='ut3_user.check_multiple_failures.multi_failure_on_error'] +%##teamcity[testFailed timestamp='%' details='Actual: |'Bad|' (varchar2) was expected to equal: |'Good|' (varchar2)' name='ut3_user.check_multiple_failures.multi_failure_on_error'] +%##teamcity[testFinished timestamp='%' duration='%' name='ut3_user.check_multiple_failures.multi_failure_on_error'] +%##teamcity[testSuiteFinished timestamp='%' name='check_multiple_failures']}'; + --act + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('check_multiple_failures.multi_failure_on_error',ut3_develop.ut_teamcity_reporter())); --assert ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); diff --git a/test/ut3_user/reporters/test_teamcity_reporter.pks b/test/ut3_user/reporters/test_teamcity_reporter.pks index 30ae7e26b..1b9277e7a 100644 --- a/test/ut3_user/reporters/test_teamcity_reporter.pks +++ b/test/ut3_user/reporters/test_teamcity_reporter.pks @@ -16,7 +16,10 @@ create or replace package test_teamcity_reporter as procedure trims_long_output; --%test(Reports failures on multiple expectations) - procedure report_mutiple_expectations; + procedure report_multiple_expectations; + + --%test(Reports failures on multiple expectations) + procedure report_multiple_expect_on_err; --%afterall procedure remove_test_package; From 6a32cbd572dd9cbbcb8858a32693cd6f41376267 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 28 Apr 2023 10:29:06 +0100 Subject: [PATCH 445/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index a47004a3c..afdf64bdd 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 8b6437299..37bc28342 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 02eabab07..c4a36c2fc 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index aacb289f2..450bde3ad 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 5e30a9fc6..926b89912 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 8db920ee7..2efea8de6 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 7c7015872..0ef65a9e8 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b83fb78c3..3582c1968 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 04b3db380..35cdd3a3f 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a7b0ae0a5..bbda24125 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 2b436250e..af07865b1 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 37c22c882..afd4ad124 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 00a74b288..7e6af19cd 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 164c0cbc0..0a5584ba9 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index e92558e3d..ca62b674e 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 2b18a3d3b..a24145f82 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 794e75070..160c51fd4 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4105--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index b60fc4cdf..954d4f8be 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4105-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4167-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 962f6fd4446d8369af56360dcc591e2a7cc919f7 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 21 May 2023 12:54:53 +0300 Subject: [PATCH 446/887] Resolves #1252 Replaced all regexp ranges with posix representations to avoid NLS_SORT impact on regex behavior. --- .../core/annotations/ut_annotation_manager.pkb | 2 +- .../core/annotations/ut_annotation_parser.pkb | 2 +- source/core/types/ut_executable_test.tpb | 2 +- source/core/ut_expectation_processor.pkb | 12 ++++++------ source/core/ut_metadata.pkb | 2 +- source/core/ut_suite_cache_manager.pkb | 4 ++-- source/core/ut_suite_manager.pkb | 8 ++++---- source/core/ut_utils.pkb | 6 +++--- test/ut3_tester/core/test_suite_manager.pkb | 17 +++++++++++++++++ test/ut3_tester/core/test_suite_manager.pks | 10 ++++++++++ 10 files changed, 46 insertions(+), 19 deletions(-) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 16923bc23..65f7b3e40 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -246,7 +246,7 @@ create or replace package body ut_annotation_manager as l_sql_clob := regexp_replace(l_sql_clob, '^(.*?\s*create(\s+or\s+replace)?(\s+(editionable|noneditionable))?\s+?)((package|type).*)', '\5', 1, 1, 'ni'); -- remove "OWNER." from create or replace statement. -- Owner is not supported along with AUTHID - see issue https://github.com/utPLSQL/utPLSQL/issues/1088 - l_sql_clob := regexp_replace(l_sql_clob, '^(package|type)\s+("?[a-zA-Z][a-zA-Z0-9#_$]*"?\.)(.*)', '\1 \3', 1, 1, 'ni'); + l_sql_clob := regexp_replace(l_sql_clob, '^(package|type)\s+("?[[:alpha:]][[:alnum:]$#_]*"?\.)(.*)', '\1 \3', 1, 1, 'ni'); l_sql_lines := ut_utils.convert_collection( ut_utils.clob_to_table(l_sql_clob) ); end if; open l_result for diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index f0271c957..10bb76b3c 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -25,7 +25,7 @@ create or replace package body ut_annotation_parser as gc_annot_comment_pattern constant varchar2(30) := '^( |'||chr(09)||')*-- *('||gc_annotation_qualifier||'.*?)$'; -- chr(09) is a tab character gc_comment_replacer_patter constant varchar2(50) := '{COMMENT#%N%}'; gc_comment_replacer_regex_ptrn constant varchar2(25) := '{COMMENT#(\d+)}'; - gc_regexp_identifier constant varchar2(50) := '[a-zA-Z][a-zA-Z0-9#_$]*'; + gc_regexp_identifier constant varchar2(50) := '[[:alpha:]][[:alnum:]$#_]*'; gc_annotation_block_pattern constant varchar2(200) := '(({COMMENT#.+}'||chr(10)||')+)( |'||chr(09)||')*(procedure|function)\s+(' || gc_regexp_identifier || ')'; gc_annotation_pattern constant varchar2(50) := gc_annotation_qualifier || gc_regexp_identifier || '[ '||chr(9)||']*(\(.*?\)\s*?$)?'; diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index c5a7f29a1..fa5872e04 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -159,7 +159,7 @@ create or replace type body ut_executable_test as if self.error_stack is null then l_fail_message := 'Expected one of exceptions ('||l_expected_error_codes||') but nothing was raised.'; else - l_actual_error_no := regexp_substr(self.error_stack, '^[a-zA-Z]{3}(-[0-9]+)', subexpression=>1); + l_actual_error_no := regexp_substr(self.error_stack, '^[[:alpha:]]{3}(-[0-9]+)', subexpression=>1); if not l_actual_error_no member of a_expected_error_codes or l_actual_error_no is null then l_fail_message := 'Actual: '||l_actual_error_no||' was expected to '; if cardinality(a_expected_error_codes) > 1 then diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index 77b734b30..c165a9ee5 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -159,17 +159,17 @@ create or replace package body ut_expectation_processor as -- when 11g and 12c reports only package name function cut_header_and_expectations( a_stack varchar2 ) return varchar2 is begin - return regexp_substr( a_stack, '(.*\.(UT_EQUAL|UT_BE_WITHIN[A-Z0-9#_$]*|UT_EXPECTATION[A-Z0-9#_$]*|UT|UTASSERT2?)(\.[A-Z0-9#_$]+)?\s+)+((.|\s)*)', 1, 1, 'm', 4); + return regexp_substr( a_stack, '(.*\.(UT_EQUAL|UT_BE_WITHIN[[:alnum:]$#_]*|UT_EXPECTATION[[:alnum:]$#_]*|UT|UTASSERT2?)(\.[[:alnum:]$#_]+)?\s+)+((.|\s)*)', 1, 1, 'm', 4); end; function cut_address_columns( a_stack varchar2 ) return varchar2 is begin - return regexp_replace( a_stack, '^(0x)?[0-9a-f]+\s+', '', 1, 0, 'mi' ); + return regexp_replace( a_stack, '^(0x)?[[:digit:]abcdef]+\s+', '', 1, 0, 'mi' ); end; function cut_framework_stack( a_stack varchar2 ) return varchar2 is begin return regexp_replace( a_stack, - '[0-9]+\s+anonymous\s+block\s+[0-9]+\s+package\s+body\s+sys\.dbms_sql(\.execute)?\s+[0-9]+\s+[0-9_$#a-z ]+\.ut_executable.*', + '[0-9]+\s+anonymous\s+block\s+[0-9]+\s+package\s+body\s+sys\.dbms_sql(\.execute)?\s+[0-9]+\s+[[:alnum:]_$# ]+\.ut_executable.*', '', 1, 1, 'mni' ); @@ -178,7 +178,7 @@ create or replace package body ut_expectation_processor as begin return regexp_replace( a_stack, - '([0-9]+)\s+(.* )?((anonymous block)|(([0-9_$#a-z]+\.[0-9_$#a-z]+(\.([0-9_$#a-z])+)?)))', + '([0-9]+)\s+(.* )?((anonymous block)|(([[:alnum:]$#_]+\.[[:alnum:]$#_]+(\.([[:alnum:]$#_])+)?)))', 'at "\3", line \1', 1, 0, 'i' ); end; @@ -190,8 +190,8 @@ create or replace package body ut_expectation_processor as l_caller_stack_line := regexp_substr(l_call_stack,'^(.*)'); if l_caller_stack_line like '%.%' then l_line_no := to_number( regexp_substr( l_caller_stack_line, ', line (\d+)', subexpression => 1 ) ); - l_owner := regexp_substr( l_caller_stack_line, 'at "([A-Za-z0-9$#_]+)\.(([A-Za-z0-9$#_]+)(\.([A-Za-z0-9$#_]+))?)", line (\d+)', subexpression => 1 ); - l_object_name := regexp_substr( l_caller_stack_line, 'at "([A-Za-z0-9$#_]+)\.(([A-Za-z0-9$#_]+)(\.([A-Za-z0-9$#_]+))?)", line (\d+)', subexpression => 3 ); + l_owner := regexp_substr( l_caller_stack_line, 'at "([[:alnum:]$#_]+)\.(([[:alnum:]$#_]+)(\.([[:alnum:]$#_]+))?)", line (\d+)', subexpression => 1 ); + l_object_name := regexp_substr( l_caller_stack_line, 'at "([[:alnum:]$#_]+)\.(([[:alnum:]$#_]+)(\.([[:alnum:]$#_]+))?)", line (\d+)', subexpression => 3 ); l_result := l_caller_stack_line || ' ' || rtrim(ut_metadata.get_source_definition_line(l_owner, l_object_name, l_line_no),chr(10)) || replace( l_call_stack, l_caller_stack_line ); diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index 700c0efb0..360b7b97d 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -304,7 +304,7 @@ create or replace package body ut_metadata as begin l_result := regexp_substr( a_full_object_name, - '^([A-Za-z0-9$#_]+|".*?")\.([A-Za-z0-9$#_]+|".*?")', subexpression => 2 + '^([[:alnum:]$#_]+|".*?")\.([[:alnum:]$#_]+|".*?")', subexpression => 2 ); if not l_result like '"%"' then l_result := upper(l_result); diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 680624f02..6d621c339 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -88,7 +88,7 @@ create or replace package body ut_suite_cache_manager is end; function group_paths_by_schema(a_paths ut_varchar2_list) return ut_path_items is - c_package_path_regex constant varchar2(100) := '^([A-Za-z0-9$#_]+)(\.([A-Za-z0-9$#_\*]+))?(\.([A-Za-z0-9$#_\*]+))?$'; + c_package_path_regex constant varchar2(100) := '^([[:alnum:]$#_]+)(\.([[:alnum:]$#_\*]+))?(\.([[:alnum:]$#_\*]+))?$'; l_results ut_path_items := ut_path_items(); l_path_item ut_path_item; i pls_integer; @@ -157,7 +157,7 @@ create or replace package body ut_suite_cache_manager is from schema_paths sp left outer join ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) --and c.path like replace(sp.suite_path,'*','%')) - and regexp_like(c.path,'^'||replace(sp.suite_path,'*','[A-Za-z0-9$#_]*'))) + and regexp_like(c.path,'^'||replace(sp.suite_path,'*','[[:alnum:]$#_]*'))) where sp.suite_path is not null and instr(sp.suite_path,'*') > 0 ), straigth_suite_paths as ( diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index c46ba66b8..c418de638 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -32,7 +32,7 @@ create or replace package body ut_suite_manager is for i in 1 .. a_paths.count loop l_path := a_paths(i); if l_path is null or not ( - regexp_like(l_path, '^[A-Za-z0-9$#_\*]+(\.[A-Za-z0-9$#_\*]+){0,2}$') or regexp_like(l_path, '^([A-Za-z0-9$#_]+)?:[A-Za-z0-9$#_\*]+(\.[A-Za-z0-9$#_\*]+)*$')) then + regexp_like(l_path, '^[[:alnum:]$#_\*]+(\.[[:alnum:]$#_\*]+){0,2}$') or regexp_like(l_path, '^([[:alnum:]$#_]+)?:[[:alnum:]$#_\*]+(\.[[:alnum:]$#_\*]+)*$')) then raise_application_error(ut_utils.gc_invalid_path_format, 'Invalid path format: ' || nvl(l_path, 'NULL')); end if; end loop; @@ -61,9 +61,9 @@ create or replace package body ut_suite_manager is for i in 1 .. a_paths.count loop --if path is suite-path - if regexp_like(a_paths(i), '^([A-Za-z0-9$#_]+)?:') then + if regexp_like(a_paths(i), '^([[:alnum:]$#_]+)?:') then --get schema name / path - l_schema := regexp_substr(a_paths(i), '^([A-Za-z0-9$#_]+)?:',subexpression => 1); + l_schema := regexp_substr(a_paths(i), '^([[:alnum:]$#_]+)?:',subexpression => 1); -- transform ":path1[.path2]" to "schema:path1[.path2]" if l_schema is not null then l_schema := sys.dbms_assert.schema_name(upper(l_schema)); @@ -78,7 +78,7 @@ create or replace package body ut_suite_manager is -- Object name or procedure is allowed to have filter char -- However this is not allowed on schema begin - l_object := regexp_substr(a_paths(i), '^[A-Za-z0-9$#_\*]+'); + l_object := regexp_substr(a_paths(i), '^[[:alnum:]$#_\*]+'); l_schema := sys.dbms_assert.schema_name(upper(l_object)); exception when sys.dbms_assert.invalid_schema_name then diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 6f972e11c..f29e3b188 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -19,9 +19,9 @@ create or replace package body ut_utils is /** * Constants regex used to validate XML name */ - gc_invalid_first_xml_char constant varchar2(50) := '[^_a-zA-Z]'; - gc_invalid_xml_char constant varchar2(50) := '[^_a-zA-Z0-9\.-]'; - gc_full_valid_xml_name constant varchar2(50) := '^([_a-zA-Z])([_a-zA-Z0-9\.-])*$'; + gc_invalid_first_xml_char constant varchar2(50) := '[^_[:alpha:]]'; + gc_invalid_xml_char constant varchar2(50) := '[^_[:alnum:]\.-]'; + gc_full_valid_xml_name constant varchar2(50) := '^([[:alpha:]])([_[:alnum:]\.-])*$'; gc_owner_hash constant integer(11) := dbms_utility.get_hash_value( ut_owner(), 0, power(2,31)-1); diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index fbac0f3f5..c818ad212 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -2217,5 +2217,22 @@ end;]'; end loop; end; + --%test(Path validation does not fail on Estonian NLS_SORT - fix #1252) + procedure path_validate_nls_sort is + l_schema_names ut3_develop.ut_varchar2_rows; + begin + --Arrange + execute immediate q'[alter session set nls_sort='estonian']'; + --Act + l_schema_names := ut3_develop.ut_suite_manager.get_schema_names(ut3_develop.ut_varchar2_list('ut3')); + --Asseert + ut.expect(sqlcode).to_equal(0); + end; + + + procedure reset_nls_sort is + begin + execute immediate q'[alter session set nls_sort='binary']'; + end; end test_suite_manager; / diff --git a/test/ut3_tester/core/test_suite_manager.pks b/test/ut3_tester/core/test_suite_manager.pks index d9d4efc09..ac7818f4f 100644 --- a/test/ut3_tester/core/test_suite_manager.pks +++ b/test/ut3_tester/core/test_suite_manager.pks @@ -237,5 +237,15 @@ create or replace package test_suite_manager is --%endcontext + --%context(paths validation) + + --%test(Path validation does not fail on Estonian NLS_SORT - fix #1252) + --%aftertest(reset_nls_sort) + procedure path_validate_nls_sort; + + procedure reset_nls_sort; + + --%endcontext + end test_suite_manager; / From 6589b8468ecaaf85258873e6484c0183b770dc17 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 27 May 2023 12:42:57 +0100 Subject: [PATCH 447/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index afdf64bdd..9d18766ae 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 37bc28342..a9cd17bc9 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index c4a36c2fc..0b1b005c6 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 450bde3ad..639dc2970 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 926b89912..bd908d60c 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 2efea8de6..eb3b311a5 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 0ef65a9e8..4f1c6b420 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 3582c1968..f5f889ca6 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 35cdd3a3f..dbd584a7c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index bbda24125..cad56f1b8 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index af07865b1..67f851f36 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index afd4ad124..b2c67054e 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 7e6af19cd..4e1b3e903 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 0a5584ba9..d68240a5d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ca62b674e..ca3878f9f 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a24145f82..4fdb74073 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 160c51fd4..bd401f5d9 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4167--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 954d4f8be..90c165bbb 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4167-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4171-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 8b45b0d670d7212f4e1ffbc9635a4a1b2a621cf1 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 28 May 2023 16:00:15 +0300 Subject: [PATCH 448/887] Fix output length error and output buffer. When dealing with multibyte strings, the substring limit of 4000 **chars** is not correct. We need to apply a limit of 4000 **bytes** to both VARCHAR2 and to CLOB data types. This means we need to have a function to calculate lenght of CLOB in bytes. This is now added and all the conversions/trimming/string-splitting is done using the string length in **bytes** Additionally, a different approach (with sequences) was introduced into output buffers to avoid the sometime occurring PK violation on the output buffer tables. The new approach may add a but overhead on reading from / saving into buffer, but will definitely address the threat of PK errors. Resolves #1254 Resolves #1128 Replaced all regexp ranges with posix representations to avoid NLS_SORT impact on regex behavior. --- .../output_buffers/ut_output_buffer_base.tpb | 1 - .../output_buffers/ut_output_buffer_base.tps | 1 - .../output_buffers/ut_output_buffer_tmp.sql | 1 + .../output_buffers/ut_output_bulk_buffer.tpb | 9 ++-- .../ut_output_clob_buffer_tmp.sql | 2 + .../ut_output_clob_table_buffer.tpb | 17 ++----- .../output_buffers/ut_output_table_buffer.tpb | 27 ++++------ source/core/ut_utils.pkb | 48 ++++++++++++++--- source/core/ut_utils.pks | 5 ++ source/uninstall_objects.sql | 4 ++ test/ut3_tester/core/test_output_buffer.pkb | 51 ++++++++++++++++--- test/ut3_tester/core/test_output_buffer.pks | 6 +++ test/ut3_tester/core/test_ut_utils.pkb | 18 +++++++ test/ut3_tester/core/test_ut_utils.pks | 13 +++-- 14 files changed, 149 insertions(+), 54 deletions(-) diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index be4c92bd8..20cec335e 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -24,7 +24,6 @@ create or replace type body ut_output_buffer_base is self.self_type := coalesce(a_self_type,self.self_type); self.output_id := coalesce(a_output_id, self.output_id, sys_guid()); self.start_date := coalesce(self.start_date, sysdate); - self.last_write_message_id := 0; select /*+ no_parallel */ count(*) into l_exists from ut_output_buffer_info_tmp where output_id = self.output_id; if ( l_exists > 0 ) then update /*+ no_parallel */ ut_output_buffer_info_tmp set start_date = self.start_date where output_id = self.output_id; diff --git a/source/core/output_buffers/ut_output_buffer_base.tps b/source/core/output_buffers/ut_output_buffer_base.tps index 53be365ae..f2d9ec686 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tps +++ b/source/core/output_buffers/ut_output_buffer_base.tps @@ -19,7 +19,6 @@ create or replace type ut_output_buffer_base force authid definer as object( output_id raw(32), is_closed number(1,0), start_date date, - last_write_message_id number(38,0), lock_handle varchar2(30 byte), self_type varchar2(250 byte), member procedure init(self in out nocopy ut_output_buffer_base, a_output_id raw := null, a_self_type varchar2 := null), diff --git a/source/core/output_buffers/ut_output_buffer_tmp.sql b/source/core/output_buffers/ut_output_buffer_tmp.sql index 57027817e..1ab19e534 100644 --- a/source/core/output_buffers/ut_output_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_buffer_tmp.sql @@ -30,3 +30,4 @@ create table ut_output_buffer_tmp( ) organization index nologging initrans 100 overflow nologging initrans 100; +create sequence ut_output_buffer_tmp_seq cache 20; diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tpb b/source/core/output_buffers/ut_output_bulk_buffer.tpb index ceae07862..cfc173e95 100644 --- a/source/core/output_buffers/ut_output_bulk_buffer.tpb +++ b/source/core/output_buffers/ut_output_bulk_buffer.tpb @@ -34,9 +34,8 @@ create or replace type body ut_output_bulk_buffer is a_item_type ); else - self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_write_message_id, a_text, a_item_type); + values (self.output_id, ut_output_buffer_tmp_seq.nextval, a_text, a_item_type); end if; commit; end if; @@ -46,10 +45,9 @@ create or replace type body ut_output_bulk_buffer is pragma autonomous_transaction; begin insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) - select /*+ no_parallel */ self.output_id, self.last_write_message_id + rownum, t.column_value, a_item_type + select /*+ no_parallel */ self.output_id, ut_output_buffer_tmp_seq.nextval, t.column_value, a_item_type from table(a_text_list) t where t.column_value is not null or a_item_type is not null; - self.last_write_message_id := self.last_write_message_id + sql%rowcount; commit; end; @@ -65,9 +63,8 @@ create or replace type body ut_output_bulk_buffer is a_item_type ); else - self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_write_message_id, a_text, a_item_type); + values (self.output_id, ut_output_buffer_tmp_seq.nextval, a_text, a_item_type); end if; commit; end if; diff --git a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql index 40dda121f..9ff9f7413 100644 --- a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql @@ -45,3 +45,5 @@ begin end; end; / + +create sequence ut_output_clob_buffer_tmp_seq cache 20; diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index c4cfdb059..3d49ab08d 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -26,9 +26,8 @@ create or replace type body ut_output_clob_table_buffer is pragma autonomous_transaction; begin if a_text is not null or a_item_type is not null then - self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_write_message_id, a_text, a_item_type); + values (self.output_id, ut_output_clob_buffer_tmp_seq.nextval, a_text, a_item_type); end if; commit; end; @@ -37,10 +36,9 @@ create or replace type body ut_output_clob_table_buffer is pragma autonomous_transaction; begin insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) - select /*+ no_parallel */ self.output_id, self.last_write_message_id + rownum, t.column_value, a_item_type + select /*+ no_parallel */ self.output_id, ut_output_clob_buffer_tmp_seq.nextval, t.column_value, a_item_type from table(a_text_list) t where t.column_value is not null or a_item_type is not null; - self.last_write_message_id := self.last_write_message_id + SQL%rowcount; commit; end; @@ -48,9 +46,8 @@ create or replace type body ut_output_clob_table_buffer is pragma autonomous_transaction; begin if a_text is not null and a_text != empty_clob() or a_item_type is not null then - self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_clob_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_write_message_id, a_text, a_item_type); + values (self.output_id, ut_output_clob_buffer_tmp_seq.nextval, a_text, a_item_type); end if; commit; end; @@ -60,7 +57,6 @@ create or replace type body ut_output_clob_table_buffer is l_buffer_rowids ut_varchar2_rows; l_buffer_data ut_output_data_rows; l_finished_flags ut_integer_list; - l_last_read_message_id integer; l_already_waited_sec number(10,2) := 0; l_finished boolean := false; l_sleep_time number(2,1); @@ -68,25 +64,22 @@ create or replace type body ut_output_clob_table_buffer is l_producer_started boolean := false; l_producer_finished boolean := false; procedure get_data_from_buffer_table( - a_last_read_message_id in out nocopy integer, a_buffer_data out nocopy ut_output_data_rows, a_buffer_rowids out nocopy ut_varchar2_rows, a_finished_flags out nocopy ut_integer_list ) is lc_bulk_limit constant integer := 5000; begin - a_last_read_message_id := coalesce(a_last_read_message_id, 0); with ordered_buffer as ( select /*+ no_parallel index(a) */ ut_output_data_row(a.text, a.item_type), rowidtochar(a.rowid), is_finished from ut_output_clob_buffer_tmp a where a.output_id = self.output_id - and a.message_id <= a_last_read_message_id + lc_bulk_limit + and a.message_id <= (select min(message_id) from ut_output_clob_buffer_tmp o where o.output_id = self.output_id) + lc_bulk_limit order by a.message_id ) select /*+ no_parallel */ b.* bulk collect into a_buffer_data, a_buffer_rowids, a_finished_flags from ordered_buffer b; - a_last_read_message_id := a_last_read_message_id + a_finished_flags.count; end; procedure remove_read_data(a_buffer_rowids ut_varchar2_rows) is @@ -103,7 +96,7 @@ create or replace type body ut_output_clob_table_buffer is l_sleep_time := case when l_already_waited_sec >= 1 then 0.5 else 0.1 end; l_lock_status := self.get_lock_status(); - get_data_from_buffer_table( l_last_read_message_id, l_buffer_data, l_buffer_rowids, l_finished_flags ); + get_data_from_buffer_table( l_buffer_data, l_buffer_rowids, l_finished_flags ); if l_buffer_data.count > 0 then l_already_waited_sec := 0; diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index 480ae9144..e8e2442a7 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -26,7 +26,7 @@ create or replace type body ut_output_table_buffer is pragma autonomous_transaction; begin if a_text is not null or a_item_type is not null then - if length(a_text) > ut_utils.gc_max_storage_varchar2_len then + if lengthb(a_text) > ut_utils.gc_max_storage_varchar2_len then self.send_lines( ut_utils.convert_collection( ut_utils.clob_to_table(a_text, ut_utils.gc_max_storage_varchar2_len) @@ -34,9 +34,8 @@ create or replace type body ut_output_table_buffer is a_item_type ); else - self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_write_message_id, a_text, a_item_type); + values (self.output_id, ut_output_buffer_tmp_seq.nextval, a_text, a_item_type); end if; commit; end if; @@ -46,10 +45,9 @@ create or replace type body ut_output_table_buffer is pragma autonomous_transaction; begin insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) - select /*+ no_parallel */ self.output_id, self.last_write_message_id + rownum, t.column_value, a_item_type + select /*+ no_parallel */ self.output_id, ut_output_buffer_tmp_seq.nextval, t.column_value, a_item_type from table(a_text_list) t where t.column_value is not null or a_item_type is not null; - self.last_write_message_id := self.last_write_message_id + SQL%rowcount; commit; end; @@ -57,7 +55,7 @@ create or replace type body ut_output_table_buffer is pragma autonomous_transaction; begin if a_text is not null and a_text != empty_clob() or a_item_type is not null then - if length(a_text) > ut_utils.gc_max_storage_varchar2_len then + if ut_utils.lengthb_clob(a_text) > ut_utils.gc_max_storage_varchar2_len then self.send_lines( ut_utils.convert_collection( ut_utils.clob_to_table(a_text, ut_utils.gc_max_storage_varchar2_len) @@ -65,9 +63,8 @@ create or replace type body ut_output_table_buffer is a_item_type ); else - self.last_write_message_id := self.last_write_message_id + 1; insert /*+ no_parallel */ into ut_output_buffer_tmp(output_id, message_id, text, item_type) - values (self.output_id, self.last_write_message_id, a_text, a_item_type); + values (self.output_id, ut_output_buffer_tmp_seq.nextval, a_text, a_item_type); end if; commit; end if; @@ -99,7 +96,6 @@ create or replace type body ut_output_table_buffer is l_buffer_texts ut_varchar2_rows; l_buffer_item_types ut_varchar2_rows; l_finished_flags ut_integer_list; - l_last_read_message_id integer; l_already_waited_sec number(10,2) := 0; l_finished boolean := false; l_sleep_time number(2,1); @@ -108,7 +104,6 @@ create or replace type body ut_output_table_buffer is l_producer_finished boolean := false; procedure get_data_from_buffer_table( - a_last_read_message_id in out nocopy integer, a_buffer_texts out nocopy ut_varchar2_rows, a_buffer_item_types out nocopy ut_varchar2_rows, a_finished_flags out nocopy ut_integer_list @@ -116,17 +111,15 @@ create or replace type body ut_output_table_buffer is lc_bulk_limit constant integer := 20000; pragma autonomous_transaction; begin - a_last_read_message_id := coalesce(a_last_read_message_id,0); delete /*+ no_parallel */ from ( select /*+ no_parallel */ * - from ut_output_buffer_tmp o - where o.output_id = self.output_id - and o.message_id <= a_last_read_message_id + lc_bulk_limit - order by o.message_id + from ut_output_buffer_tmp a + where a.output_id = self.output_id + and a.message_id <= (select min(message_id) from ut_output_buffer_tmp o where o.output_id = self.output_id) + lc_bulk_limit + order by a.message_id ) d returning d.text, d.item_type, d.is_finished bulk collect into a_buffer_texts, a_buffer_item_types, a_finished_flags; - a_last_read_message_id := a_last_read_message_id + a_finished_flags.count; commit; end; begin @@ -134,7 +127,7 @@ create or replace type body ut_output_table_buffer is l_sleep_time := case when l_already_waited_sec >= 1 then 0.5 else 0.1 end; l_lock_status := self.get_lock_status(); - get_data_from_buffer_table( l_last_read_message_id, l_buffer_texts, l_buffer_item_types, l_finished_flags ); + get_data_from_buffer_table( l_buffer_texts, l_buffer_item_types, l_finished_flags ); if l_buffer_texts.count > 0 then l_already_waited_sec := 0; diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index f29e3b188..81d47221b 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -92,8 +92,8 @@ create or replace package body ut_utils is a_max_output_len in number := gc_max_output_string_length ) return varchar2 is l_result varchar2(32767); - c_length constant integer := coalesce( length( a_value ), 0 ); - c_max_input_string_length constant integer := a_max_output_len - coalesce( length( a_quote_char ) * 2, 0 ); + c_length constant integer := coalesce( lengthb( a_value ), 0 ); + c_max_input_string_length constant integer := a_max_output_len - coalesce( lengthb( a_quote_char ) * 2, 0 ); c_overflow_substr_len constant integer := c_max_input_string_length - gc_more_data_string_len; begin if c_length = 0 then @@ -112,8 +112,8 @@ create or replace package body ut_utils is a_max_output_len in number := gc_max_output_string_length ) return varchar2 is l_result varchar2(32767); - c_length constant integer := coalesce(dbms_lob.getlength(a_value), 0); - c_max_input_string_length constant integer := a_max_output_len - coalesce( length( a_quote_char ) * 2, 0 ); + c_length constant integer := coalesce(ut_utils.lengthb_clob(a_value), 0); + c_max_input_string_length constant integer := a_max_output_len - coalesce( lengthb( a_quote_char ) * 2, 0 ); c_overflow_substr_len constant integer := c_max_input_string_length - gc_more_data_string_len; begin if a_value is null then @@ -135,7 +135,7 @@ create or replace package body ut_utils is ) return varchar2 is l_result varchar2(32767); c_length constant integer := coalesce(dbms_lob.getlength(a_value), 0); - c_max_input_string_length constant integer := a_max_output_len - coalesce( length( a_quote_char ) * 2, 0 ); + c_max_input_string_length constant integer := a_max_output_len - coalesce( lengthb( a_quote_char ) * 2, 0 ); c_overflow_substr_len constant integer := c_max_input_string_length - gc_more_data_string_len; begin if a_value is null then @@ -412,7 +412,7 @@ create or replace package body ut_utils is if a_list is null then a_list := ut_varchar2_rows(); end if; - if length(a_item) > gc_max_storage_varchar2_len then + if lengthb(a_item) > gc_max_storage_varchar2_len then append_to_list( a_list, ut_utils.convert_collection( @@ -468,7 +468,7 @@ create or replace package body ut_utils is l_result := ut_varchar2_rows(); for i in 1 .. a_collection.count loop l_result.extend(); - l_result(i) := substr(a_collection(i),1,gc_max_storage_varchar2_len); + l_result(i) := substrb(a_collection(i),1,gc_max_storage_varchar2_len); end loop; end if; return l_result; @@ -990,5 +990,39 @@ create or replace package body ut_utils is return l_result; end; + + + /* + * Inspired by + * https://stackoverflow.com/a/48782891 + */ + function lengthb_clob( a_clob clob) return integer is + l_blob blob; + l_desc_offset PLS_INTEGER := 1; + l_src_offset PLS_INTEGER := 1; + l_lang PLS_INTEGER := 0; + l_warning PLS_INTEGER := 0; + l_result integer; + begin + if a_clob = empty_clob() then + l_result := 0; + elsif a_clob is not null then + dbms_lob.createtemporary(l_blob,true); + dbms_lob.converttoblob + ( l_blob + , a_clob + , dbms_lob.getlength(a_clob) + , l_desc_offset + , l_src_offset + , dbms_lob.default_csid + , l_lang + , l_warning + ); + l_result := length(l_blob); + dbms_lob.freetemporary(l_blob); + end if; + return l_result; + end; + end ut_utils; / diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 90c165bbb..ee5ed7876 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -476,6 +476,11 @@ create or replace package ut_utils authid definer is * Return value of interval in plain english */ function interval_to_text(a_interval yminterval_unconstrained) return varchar2; + + /* + * Return length of CLOB in bytes. Null for NULL + */ + function lengthb_clob( a_clob clob) return integer; end ut_utils; / diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index f488b8b8d..a0b53ba21 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -333,8 +333,12 @@ drop type ut_output_buffer_base force; drop table ut_output_buffer_tmp purge; +drop table ut_output_buffer_tmp_seq purge; + drop table ut_output_clob_buffer_tmp purge; +drop table ut_output_clob_buffer_tmp_seq purge; + drop table ut_output_buffer_info_tmp purge; drop package ut_session_context; diff --git a/test/ut3_tester/core/test_output_buffer.pkb b/test/ut3_tester/core/test_output_buffer.pkb index edb10e3e6..317e7e3d5 100644 --- a/test/ut3_tester/core/test_output_buffer.pkb +++ b/test/ut3_tester/core/test_output_buffer.pkb @@ -56,8 +56,8 @@ create or replace package body test_output_buffer is procedure test_doesnt_send_on_null_elem is - l_cur sys_refcursor; - l_result integer; + l_actual sys_refcursor; + l_expected sys_refcursor; l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); l_message_id varchar2(255); l_text varchar2(4000); @@ -67,9 +67,12 @@ create or replace package body test_output_buffer is l_buffer.send_lines(ut3_develop.ut_varchar2_rows(null)); l_buffer.send_lines(ut3_develop.ut_varchar2_rows('test')); - select message_id, text into l_message_id, l_text from table(ut3_tester_helper.run_helper.ut_output_buffer_tmp); - ut.expect(l_message_id).to_equal('1'); - ut.expect(l_text).to_equal('test'); + open l_actual for + select text from table(ut3_tester_helper.run_helper.ut_output_buffer_tmp); + open l_expected for + select 'test' as text from dual; + + ut.expect(l_actual).to_equal(l_expected); end; procedure test_send_line is @@ -157,5 +160,41 @@ create or replace package body test_output_buffer is test_purge(ut3_develop.ut_output_clob_table_buffer()); end; -end test_output_buffer; + procedure text_buffer_send_multibyte is + l_input varchar2(32767); + l_max_len integer := ut3_develop.ut_utils.gc_max_storage_varchar2_len; + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); + l_text varchar2(4000); + begin + --Arrange + ut3_tester_helper.run_helper.delete_buffer(); + l_input := rpad( '❤', l_max_len, 'a' ); + ut.expect( lengthb( l_input ) ).to_be_greater_than(l_max_len); + + --Act + l_buffer.send_line(l_input); + --Assert + select text into l_text from table(ut3_tester_helper.run_helper.ut_output_buffer_tmp); + ut.expect(lengthb(l_text)).to_be_less_or_equal(l_max_len); + end; + + procedure text_buffer_send_clob_multib is + l_input clob; + l_max_len integer := ut3_develop.ut_utils.gc_max_storage_varchar2_len; + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); + l_text varchar2(4000); + begin + --Arrange + ut3_tester_helper.run_helper.delete_buffer(); + l_input := rpad( '❤', l_max_len, 'a' ); + ut.expect( ut3_develop.ut_utils.lengthb_clob( l_input ) ).to_be_greater_than(l_max_len); + + --Act + l_buffer.send_clob(l_input); + --Assert + select text into l_text from table(ut3_tester_helper.run_helper.ut_output_buffer_tmp); + ut.expect(lengthb(l_text)).to_be_less_or_equal(l_max_len); + end; + + end test_output_buffer; / diff --git a/test/ut3_tester/core/test_output_buffer.pks b/test/ut3_tester/core/test_output_buffer.pks index feaa337f8..5b6cd678b 100644 --- a/test/ut3_tester/core/test_output_buffer.pks +++ b/test/ut3_tester/core/test_output_buffer.pks @@ -47,5 +47,11 @@ create or replace package test_output_buffer is --%test(Purges clob buffer data older than one day and leaves the rest) procedure test_purge_clob_buffer; + --%test(Successfully sends multibyte long line into text buffer) + procedure text_buffer_send_multibyte; + + --%test(Successfully sends multibyte long clob line into text buffer) + procedure text_buffer_send_clob_multib; + end test_output_buffer; / diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index ec7e4f403..27c164e4e 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -489,5 +489,23 @@ end; ut.expect(l_expected).to_equal(l_actual); end; + procedure convert_collection_multibyte is + l_input ut3_develop.ut_varchar2_list; + l_max_len integer := ut3_develop.ut_utils.gc_max_storage_varchar2_len; + begin + --Arrange + l_input := ut3_develop.ut_varchar2_list( rpad( '❤', l_max_len, 'a' ) ); + ut.expect( lengthb( l_input( 1 ) ) ).to_be_greater_than(l_max_len); + + --Act + ut.expect( lengthb( ut3_develop.ut_utils.convert_collection(l_input)(1) ) ).to_be_less_or_equal(l_max_len); + end; + + procedure lengthb_gives_length_in_bytes is + l_clob clob; + begin + l_clob := '❤'; + ut.expect(ut3_develop.ut_utils.lengthb_clob(l_clob)).to_equal(3); + end; end test_ut_utils; / diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index 114b35e86..ca2e7b304 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -152,10 +152,15 @@ create or replace package test_ut_utils is procedure int_conv_ym_month; --%test(returns text representation of interval year to month for custom interval) - procedure int_conv_ym_date; - - + procedure int_conv_ym_date; + --%endcontext - + + --%test(convert_collection does not fail on multibyte strings - Issue #1245 ) + procedure convert_collection_multibyte; + + --%test(lengthb returns length of a CLOB in bytes ) + procedure lengthb_gives_length_in_bytes; + end test_ut_utils; / From b70ee1e742652da3c4a13231e1edcc26ecff5998 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 28 May 2023 17:03:28 +0300 Subject: [PATCH 449/887] Fixed failing unit test and the uninstall script --- source/uninstall_objects.sql | 4 ++-- test/ut3_tester/core/test_ut_utils.pkb | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index a0b53ba21..dde9a824f 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -333,11 +333,11 @@ drop type ut_output_buffer_base force; drop table ut_output_buffer_tmp purge; -drop table ut_output_buffer_tmp_seq purge; +drop sequence ut_output_buffer_tmp_seq; drop table ut_output_clob_buffer_tmp purge; -drop table ut_output_clob_buffer_tmp_seq purge; +drop sequence ut_output_clob_buffer_tmp_seq; drop table ut_output_buffer_info_tmp purge; diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 27c164e4e..433987c01 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -505,7 +505,7 @@ end; l_clob clob; begin l_clob := '❤'; - ut.expect(ut3_develop.ut_utils.lengthb_clob(l_clob)).to_equal(3); + ut.expect(ut3_develop.ut_utils.lengthb_clob(l_clob)).to_be_greater_than(1); end; end test_ut_utils; / From 21462fcfa53b2d466fd7719f9f854facb06c2cdc Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 28 May 2023 15:44:45 +0100 Subject: [PATCH 450/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 9d18766ae..d4bebf085 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index a9cd17bc9..adf03ba11 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 0b1b005c6..aca73a1d6 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 639dc2970..c83158ec0 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index bd908d60c..f60d80aa9 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index eb3b311a5..5fc69e002 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 4f1c6b420..4b3af7c2a 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index f5f889ca6..6c1920c6b 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index dbd584a7c..0466e237a 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index cad56f1b8..5b242a0cd 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 67f851f36..d188c0aa2 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index b2c67054e..1a0aceeb9 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 4e1b3e903..e12ed3588 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d68240a5d..d7f2a2838 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ca3878f9f..a804d98e7 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 4fdb74073..282e07d09 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index bd401f5d9..bbca978ba 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4171--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index ee5ed7876..552f31143 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4171-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4176-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From cd3e2b940208c6f9f68d6ae74b10d86019761c3f Mon Sep 17 00:00:00 2001 From: Jonas Gassenmeyer Date: Fri, 7 Jul 2023 14:17:00 +0200 Subject: [PATCH 451/887] fix(doc): Update running-unit-tests.md - remove example --- docs/userguide/running-unit-tests.md | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 282e07d09..447b5eb54 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -120,14 +120,6 @@ end; ``` Executes all tests from package _hr.test_apply_bonus_ and all tests from schema _cust_. -```sql linenums="1" -set serveroutput on -begin - ut.run(ut_varchar2_list('hr.test_apply_bonus,cust)'); -end; -``` - -Executes all tests from package _hr.test_apply_bonus_ and all tests from schema _cust_. ```sql linenums="1" set serveroutput on @@ -566,4 +558,4 @@ Example call with characterset provided: begin ut.run('hr.test_apply_bonus', ut_junit_reporter(), a_client_character_set => 'Windows-1251'); end; -``` \ No newline at end of file +``` From e4d8528822254212a28e676a11ba9d578cfeee04 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Sun, 9 Jul 2023 19:11:21 +0300 Subject: [PATCH 452/887] Added missing grant for `ut_output_bulk_buffer`. --- source/create_grants.sql | 1 + 1 file changed, 1 insertion(+) diff --git a/source/create_grants.sql b/source/create_grants.sql index 8a44ab371..0e9f46cc5 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -123,6 +123,7 @@ grant execute on &&ut3_owner..ut_console_reporter_base to &ut3_user; grant execute on &&ut3_owner..ut_output_buffer_base to &ut3_user; grant execute on &&ut3_owner..ut_output_table_buffer to &ut3_user; grant execute on &&ut3_owner..ut_output_clob_table_buffer to &ut3_user; +grant execute on &&ut3_owner..ut_output_bulk_buffer to &ut3_user; --needed internally for selecting from annotation objects within packages that use invoker rights grant execute on &&ut3_owner..ut_annotation_objs_cache_info to &ut3_user; From 550ea328e74cc211408292b1f481b4feabe5ce46 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 9 Jul 2023 17:20:41 +0100 Subject: [PATCH 453/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index d4bebf085..cd5f1191e 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index adf03ba11..f81d13395 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index aca73a1d6..e315c921f 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index c83158ec0..968d9acc4 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index f60d80aa9..49f5d42a7 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 5fc69e002..325b831c5 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 4b3af7c2a..95b34accc 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 6c1920c6b..94ab25215 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0466e237a..e30c87d00 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 5b242a0cd..7fdac2189 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index d188c0aa2..ceca41af8 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 1a0aceeb9..e5b636f53 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index e12ed3588..ce21e475f 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d7f2a2838..7c4891aea 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index a804d98e7..f46d7dba4 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 282e07d09..618e61f1c 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index bbca978ba..2eecf9c85 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4176--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 552f31143..7c49dad67 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4176-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4178-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From fc8c520bfb569cee737193c7db81c7efec07a20b Mon Sep 17 00:00:00 2001 From: Jonas Gassenmeyer Date: Mon, 10 Jul 2023 08:12:46 +0200 Subject: [PATCH 454/887] fix(doc): Update running-unit-tests.md add comments --- docs/userguide/running-unit-tests.md | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index e35001a52..fde0330c9 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -118,7 +118,16 @@ begin ut.run(ut_varchar2_list('hr.test_apply_bonus','cust')); end; ``` -Executes all tests from package _hr.test_apply_bonus_ and all tests from schema _cust_. +Executes all tests from package _hr.test_apply_bonus_ and all tests from schema _cust_ (passing individual items to be executed as elements of the ut_varchar2_list table type). + + +```sql linenums="1" +set serveroutput on +begin + ut.run(ut_varchar2_list('hr.test_apply_bonus,cust')); +end; +``` +Executes all tests from package _hr.test_apply_bonus_ and all tests from schema _cust_ (passing all items as a comma-separated-list of values into a single element of the ut_varchar2_list table type). ```sql linenums="1" @@ -128,7 +137,7 @@ begin end; ``` -Executes all tests from package _hr.test_apply_bonus_ and all tests from schema _cust_. +Executes all tests from package _hr.test_apply_bonus_ and all tests from schema _cust_ (no explicit ut_varchar2_list table type). Using a list of items to execute allows you to execute a fine-grained set of tests. From 242695255a9751d642563bfe75ad02582032561b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 29 Aug 2023 21:51:17 +0100 Subject: [PATCH 455/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index cd5f1191e..43b94f7ab 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index f81d13395..cf10e3bd6 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index e315c921f..6889d9edb 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 968d9acc4..c2af14837 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 49f5d42a7..f22ea814e 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 325b831c5..f676ae4db 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 95b34accc..a21f66424 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 94ab25215..f563fb819 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index e30c87d00..4c1e1dcb8 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 7fdac2189..467651334 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index ceca41af8..ce9e519d5 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index e5b636f53..47f2cb92e 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ce21e475f..69183c577 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 7c4891aea..3bf028596 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index f46d7dba4..3c36676e8 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index fde0330c9..662b5b004 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 2eecf9c85..ae4499f98 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4178--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 7c49dad67..29ce06991 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4178-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4182-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 03106637532a424c413cd34e7614ef10b0359ad0 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 22 Sep 2023 21:07:16 +0100 Subject: [PATCH 456/887] Issue #1268 The line-rate is not recorded for packages and classes. --- .../ut_coverage_cobertura_reporter.tpb | 37 +++++++++++++++---- .../test_cov_cobertura_reporter.pkb | 4 +- .../test_coverage_standalone.pkb | 4 +- 3 files changed, 33 insertions(+), 12 deletions(-) diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index 50eb34631..d833ac0aa 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -29,11 +29,19 @@ create or replace type body ut_coverage_cobertura_reporter is l_report_lines ut_varchar2_list; l_coverage_data ut_coverage.t_coverage; - function get_lines_xml(a_unit_coverage ut_coverage.t_unit_coverage) return clob is + function get_line_rate(a_lines_covered in integer, a_lines_hit in integer) return varchar2 is + begin + return to_char(round((case a_lines_covered when 0 then 0 else a_lines_covered/a_lines_hit end), 17), rpad('FM0.0',20,'9') , 'NLS_NUMERIC_CHARACTERS=''. '''); + end; + + procedure get_lines_xml(a_unit_coverage ut_coverage.t_unit_coverage, + a_lines_result in out nocopy clob, a_lines_hits out number, a_lines_total out number) is l_file_part varchar2(32767); l_result clob; l_line_no binary_integer; l_pct integer; + l_lines_hits integer := 0; + l_lines_total integer := 0; begin dbms_lob.createtemporary(l_result, true); l_line_no := a_unit_coverage.lines.first; @@ -41,11 +49,14 @@ create or replace type body ut_coverage_cobertura_reporter is for i in 1 .. a_unit_coverage.total_lines loop ut_utils.append_to_clob(l_result, ''||chr(10)); end loop; + l_lines_hits:=0; + l_lines_total:= a_unit_coverage.total_lines; else while l_line_no is not null loop if a_unit_coverage.lines(l_line_no).executions = 0 then l_file_part := ''||chr(10); else + l_lines_hits:= l_lines_hits+1; l_file_part := '' + '' ); ut_utils.append_to_list( @@ -129,13 +150,13 @@ create or replace type body ut_coverage_cobertura_reporter is ut_utils.append_to_list( l_result, '' + ||dbms_xmlgen.convert(l_unit)||'" line-rate="'||get_line_rate(l_line_hits,l_line_total)||'" branch-rate="0.0" complexity="0.0">' ); ut_utils.append_to_list(l_result, ''); - - ut_utils.append_to_list( l_result, get_lines_xml(a_coverage_data.objects(l_unit)) ); - + ut_utils.append_to_list( l_result,l_lines_xml); + dbms_lob.freetemporary(l_lines_xml); + ut_utils.append_to_list(l_result, c_lines_footer); ut_utils.append_to_list(l_result, c_class_footer); ut_utils.append_to_list(l_result, c_classes_footer); diff --git a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb index 2c36f37ba..ad6c9dbb4 100644 --- a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ -25,9 +25,9 @@ create or replace package body test_cov_cobertura_reporter is ]'||l_file_path||q'[ - + - + ]'||l_block_cov||q'[ diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index e5706f885..90cfb484e 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -20,9 +20,9 @@ create or replace package body test_coverage_standalone is ]'||l_file_path||q'[ - + - + ]'||l_block_cov||q'[ From e0a9fa16a973d3a47784f58485238309fb44bb69 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 23 Sep 2023 19:28:21 +0100 Subject: [PATCH 457/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index 43b94f7ab..c4c40bfad 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index cf10e3bd6..702ea3f9c 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 6889d9edb..60aa6a657 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index c2af14837..fc412205d 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index f22ea814e..8325ec636 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index f676ae4db..1f7f2d191 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index a21f66424..d1ff5da07 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index f563fb819..5148273e6 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4c1e1dcb8..5d071335e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 467651334..ca52ac951 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index ce9e519d5..b6f3d7e29 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 47f2cb92e..9620878ad 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 69183c577..8f32c5a10 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 3bf028596..e3ec1f53d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3c36676e8..e37ac6627 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 662b5b004..3b23f5f98 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index ae4499f98..e5537f520 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4182--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 29ce06991..522da1480 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4182-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4187-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 0474d7a8f2944b864e8b221e9a7c79f11d23c245 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 24 Sep 2023 23:52:15 +0100 Subject: [PATCH 458/887] First checking. Still some more tests to go for complex nesting. --- source/reporters/ut_tfs_junit_reporter.tpb | 92 ++++++---- .../reporters/test_tfs_junit_reporter.pkb | 161 +++++++++++++++++- .../reporters/test_tfs_junit_reporter.pks | 9 + 3 files changed, 218 insertions(+), 44 deletions(-) diff --git a/source/reporters/ut_tfs_junit_reporter.tpb b/source/reporters/ut_tfs_junit_reporter.tpb index e2d45a369..5b8702808 100644 --- a/source/reporters/ut_tfs_junit_reporter.tpb +++ b/source/reporters/ut_tfs_junit_reporter.tpb @@ -51,11 +51,12 @@ create or replace type body ut_tfs_junit_reporter is return regexp_substr(a_path_with_name, '(.*)\.' ||a_name||'$',subexpression=>1); end; - procedure print_test_results(a_test ut_test) is + function add_test_results(a_test ut_test) return ut_varchar2_rows is l_results ut_varchar2_rows := ut_varchar2_rows(); begin - self.print_text(''); + /* According to specs : - A failure is a test which the code has explicitly failed by using the mechanisms for that purpose. @@ -83,64 +84,83 @@ create or replace type body ut_tfs_junit_reporter is ut_utils.append_to_list( l_results, ''); - self.print_text_lines(l_results); + return l_results; end; - procedure print_suite_results(a_suite ut_logical_suite, a_suite_id in out nocopy integer) is + procedure print_suite_results(a_suite ut_logical_suite, a_suite_id in out nocopy integer, a_nested_tests in out nocopy ut_varchar2_rows) is l_tests_count integer := a_suite.results_count.disabled_count + a_suite.results_count.success_count + a_suite.results_count.failure_count + a_suite.results_count.errored_count; l_results ut_varchar2_rows := ut_varchar2_rows(); l_suite ut_suite; l_outputs clob; l_errors ut_varchar2_list; - begin - + l_tests ut_varchar2_list; + begin for i in 1 .. a_suite.items.count loop if a_suite.items(i) is of(ut_logical_suite) then - print_suite_results(treat(a_suite.items(i) as ut_logical_suite), a_suite_id); + print_suite_results(treat(a_suite.items(i) as ut_logical_suite), a_suite_id, a_nested_tests); end if; end loop; - - if a_suite is of(ut_suite) then - a_suite_id := a_suite_id + 1; - self.print_text(''); - self.print_text(''); + --Due to fact tha TFS and junit5 accepts only flat structure we have to report in suite level only. + if a_suite.self_type ='UT_SUITE_CONTEXT' then for i in 1 .. a_suite.items.count loop if a_suite.items(i) is of(ut_test) then - print_test_results(treat(a_suite.items(i) as ut_test)); + ut_utils.append_to_list( a_nested_tests,(add_test_results(treat(a_suite.items(i) as ut_test)))); end if; end loop; - l_suite := treat(a_suite as ut_suite); - l_outputs := l_suite.get_serveroutputs(); - if l_outputs is not null and l_outputs != empty_clob() then - ut_utils.append_to_list( l_results, ''); - ut_utils.append_to_list( l_results, ut_utils.to_cdata( l_suite.get_serveroutputs() ) ); - ut_utils.append_to_list( l_results, ''); - else - ut_utils.append_to_list( l_results, ''); - end if; - - l_errors := l_suite.get_error_stack_traces(); - if l_errors is not empty then - ut_utils.append_to_list( l_results, ''); - ut_utils.append_to_list( l_results, ut_utils.to_cdata( ut_utils.convert_collection( l_errors ) ) ); - ut_utils.append_to_list( l_results, ''); - else - ut_utils.append_to_list( l_results, ''); - end if; - ut_utils.append_to_list( l_results, ''); - - self.print_text_lines(l_results); + elsif a_suite.self_type ='UT_SUITE' then + for i in 1 .. a_suite.items.count loop + if a_suite.items(i) is of(ut_test) then + ut_utils.append_to_list( a_nested_tests,(add_test_results(treat(a_suite.items(i) as ut_test)))); + end if; + end loop; + --TFS doesnt report on empty test suites, however all we want to make sure is that we dont pring parents suites + -- showing test count but not tests. + if (a_nested_tests.count > 0 and l_tests_count > 0) or (a_nested_tests.count = 0 and l_tests_count = 0) then + a_suite_id := a_suite_id + 1; + ut_utils.append_to_list( l_results,''); + ut_utils.append_to_list( l_results,''); + ut_utils.append_to_list(l_results,a_nested_tests); + l_suite := treat(a_suite as ut_suite); + l_outputs := l_suite.get_serveroutputs(); + if l_outputs is not null and l_outputs != empty_clob() then + ut_utils.append_to_list( l_results, ''); + ut_utils.append_to_list( l_results, ut_utils.to_cdata( l_suite.get_serveroutputs() ) ); + ut_utils.append_to_list( l_results, ''); + else + ut_utils.append_to_list( l_results, ''); + end if; + + l_errors := l_suite.get_error_stack_traces(); + if l_errors is not empty then + ut_utils.append_to_list( l_results, ''); + ut_utils.append_to_list( l_results, ut_utils.to_cdata( ut_utils.convert_collection( l_errors ) ) ); + ut_utils.append_to_list( l_results, ''); + else + ut_utils.append_to_list( l_results, ''); + end if; + ut_utils.append_to_list( l_results, ''); + + self.print_text_lines(l_results); + --We have resolved a context and we now reset value. + a_nested_tests := ut_varchar2_rows(); + end if; end if; end; + + procedure get_suite_results(a_suite ut_logical_suite, a_suite_id in out nocopy integer) is + l_nested_tests ut_varchar2_rows:= ut_varchar2_rows(); + begin + print_suite_results(a_suite, l_suite_id,l_nested_tests); + end; begin l_suite_id := 0; self.print_text(ut_utils.get_xml_header(a_run.client_character_set)); self.print_text(''); for i in 1 .. a_run.items.count loop - print_suite_results(treat(a_run.items(i) as ut_logical_suite), l_suite_id); + get_suite_results(treat(a_run.items(i) as ut_logical_suite), l_suite_id); end loop; self.print_text(''); end; diff --git a/test/ut3_user/reporters/test_tfs_junit_reporter.pkb b/test/ut3_user/reporters/test_tfs_junit_reporter.pkb index 7eb4f8ab6..1036be2ba 100644 --- a/test/ut3_user/reporters/test_tfs_junit_reporter.pkb +++ b/test/ut3_user/reporters/test_tfs_junit_reporter.pkb @@ -8,7 +8,7 @@ create or replace package body test_tfs_junit_reporter as --%test(A test with ) procedure test_do_stuff; - + end;]'; execute immediate q'[create or replace package body check_junit_reporting is procedure test_do_stuff is @@ -18,12 +18,12 @@ create or replace package body test_tfs_junit_reporter as end; end;]'; - + execute immediate q'[create or replace package check_junit_rep_suitepath is --%suitepath(core) --%suite(check_junit_rep_suitepath) --%displayname(Check JUNIT Get path for suitepath) - + --%test(check_junit_rep_suitepath) --%displayname(Check JUNIT Get path for suitepath) procedure check_junit_rep_suitepath; @@ -38,7 +38,7 @@ create or replace package body test_tfs_junit_reporter as execute immediate q'[create or replace package check_junit_flat_suitepath is --%suitepath(core.check_junit_rep_suitepath) --%suite(flatsuitepath) - + --%beforeall procedure donuffin; end;]'; @@ -49,8 +49,85 @@ create or replace package body test_tfs_junit_reporter as end; end;]'; - end; + execute immediate q'[create or replace package check_junit_in_context is + --%suitepath(core.check_junit_rep_suitepath) + --%suite(inctxsuite) + --%displayname(JUNIT test are inside context) + + -- %context(incontext) + -- %name(incontext) + + --%test(incontext) + --%displayname(Check JUNIT Get path incontext) + procedure check_junit_rep_incontext; + + -- %endcontext + end;]'; + execute immediate q'[create or replace package body check_junit_in_context is + procedure check_junit_rep_incontext is + begin + ut3_develop.ut.expect(1).to_equal(1); + end; + end;]'; + + execute immediate q'[create or replace package check_junit_out_context is + --%suitepath(core) + --%suite(outctxsuite) + --%displayname(JUNIT test are outside context) + + -- %context(outcontext) + -- %name(outcontext) + + -- %endcontext + + + --%test(outctx) + --%displayname(outctx) + procedure outctx; + + + end;]'; + execute immediate q'[create or replace package body check_junit_out_context is + procedure outctx is + begin + ut3_develop.ut.expect(1).to_equal(1); + end; + end;]'; + + execute immediate q'[create or replace package check_junit_inout_context is + --%suitepath(core) + --%suite(inoutcontext) + --%displayname(Test in and out of context) + -- %context(incontext) + -- %name(ProductincontextFeatures) + + --%test(inctx) + --%displayname(inctx) + procedure inctx; + + -- %endcontext + + + --%test(outctx) + --%displayname(outctx) + procedure outctx; + + + end;]'; + execute immediate q'[create or replace package body check_junit_inout_context is + procedure inctx is + begin + ut3_develop.ut.expect(1).to_equal(1); + end; + + procedure outctx is + begin + ut3_develop.ut.expect(1).to_equal(1); + end; + end;]'; + + end; procedure escapes_special_chars is l_results ut3_develop.ut_varchar2_list; @@ -92,7 +169,7 @@ create or replace package body test_tfs_junit_reporter as --Assert ut.expect(l_actual).to_be_like('%testcase classname="check_junit_reporting"%'); end; - + procedure check_flatten_nested_suites is l_results ut3_develop.ut_varchar2_list; l_actual clob; @@ -111,7 +188,7 @@ create or replace package body test_tfs_junit_reporter as
    %'); end; - + procedure check_nls_number_formatting is l_results ut3_develop.ut_varchar2_list; l_actual clob; @@ -163,5 +240,73 @@ create or replace package body test_tfs_junit_reporter as reporters.check_xml_encoding_included(ut3_develop.ut_tfs_junit_reporter(), 'UTF-8'); end; + procedure reports_only_test_in_ctx is + l_results ut3_develop.ut_varchar2_list; + l_actual clob; + begin + --Act + select * + bulk collect into l_results + from table(ut3_develop.ut.run('check_junit_in_context',ut3_develop.ut_tfs_junit_reporter())); + l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + --Assert + ut.expect(l_actual).to_be_like(' + + + + + + + + +%'); + end; + + procedure reports_only_test_out_ctx is + l_results ut3_develop.ut_varchar2_list; + l_actual clob; + begin + --Act + select * + bulk collect into l_results + from table(ut3_develop.ut.run('check_junit_out_context',ut3_develop.ut_tfs_junit_reporter())); + l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + --Assert + ut.expect(l_actual).to_be_like(' + + + + + + + + +%'); + end; + + procedure reports_only_test_inout_ctx is + l_results ut3_develop.ut_varchar2_list; + l_actual clob; + begin + --Act + select * + bulk collect into l_results + from table(ut3_develop.ut.run('check_junit_inout_context',ut3_develop.ut_tfs_junit_reporter())); + l_actual := ut3_tester_helper.main_helper.table_to_clob(l_results); + --Assert + ut.expect(l_actual).to_be_like(' + + + + + + + + + + +%'); + end; + end; -/ +/ \ No newline at end of file diff --git a/test/ut3_user/reporters/test_tfs_junit_reporter.pks b/test/ut3_user/reporters/test_tfs_junit_reporter.pks index 07acb4d21..70f78e334 100644 --- a/test/ut3_user/reporters/test_tfs_junit_reporter.pks +++ b/test/ut3_user/reporters/test_tfs_junit_reporter.pks @@ -30,6 +30,15 @@ create or replace package test_tfs_junit_reporter as --%test(Includes XML header with encoding when encoding provided) procedure check_encoding_included; + --%test(Reports only testsuites where there are any testcases, all tests are in context) + procedure reports_only_test_in_ctx; + + --%test(Reports only testsuites where there are any testcases, all tests are outside context) + procedure reports_only_test_out_ctx; + + --%test(Reports only testsuites where there are any testcases, one test in ctx one test outside) + procedure reports_only_test_inout_ctx; + --%afterall procedure remove_test_package; end; From d974ce31394118fbb6c1ca9d6aac5a290e16853d Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Fri, 29 Sep 2023 19:42:46 +0100 Subject: [PATCH 459/887] Update code --- source/reporters/ut_tfs_junit_reporter.tpb | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/source/reporters/ut_tfs_junit_reporter.tpb b/source/reporters/ut_tfs_junit_reporter.tpb index 5b8702808..5e36aad17 100644 --- a/source/reporters/ut_tfs_junit_reporter.tpb +++ b/source/reporters/ut_tfs_junit_reporter.tpb @@ -97,18 +97,22 @@ create or replace type body ut_tfs_junit_reporter is l_tests ut_varchar2_list; begin for i in 1 .. a_suite.items.count loop - if a_suite.items(i) is of(ut_logical_suite) then - print_suite_results(treat(a_suite.items(i) as ut_logical_suite), a_suite_id, a_nested_tests); + if a_suite.items(i) is of(ut_suite_context) then + print_suite_results(treat(a_suite.items(i) as ut_suite_context), a_suite_id, a_nested_tests); + elsif a_suite.items(i) is of(ut_suite) then + print_suite_results(treat(a_suite.items(i) as ut_suite), a_suite_id, a_nested_tests); + elsif a_suite.items(i) is of(ut_logical_suite) then + print_suite_results(treat(a_suite.items(i) as ut_logical_suite), a_suite_id, a_nested_tests); end if; end loop; --Due to fact tha TFS and junit5 accepts only flat structure we have to report in suite level only. - if a_suite.self_type ='UT_SUITE_CONTEXT' then + if a_suite is of(ut_suite_context) then for i in 1 .. a_suite.items.count loop if a_suite.items(i) is of(ut_test) then ut_utils.append_to_list( a_nested_tests,(add_test_results(treat(a_suite.items(i) as ut_test)))); end if; end loop; - elsif a_suite.self_type ='UT_SUITE' then + elsif a_suite is of(ut_suite) then for i in 1 .. a_suite.items.count loop if a_suite.items(i) is of(ut_test) then ut_utils.append_to_list( a_nested_tests,(add_test_results(treat(a_suite.items(i) as ut_test)))); From 03b0566bda57947df59eb0dd3bfbdb203a6a79c4 Mon Sep 17 00:00:00 2001 From: Rachid EL AISSAOUI Date: Tue, 5 Dec 2023 23:46:45 +0100 Subject: [PATCH 460/887] Fix indentation --- docs/userguide/best-practices.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 5148273e6..57a108fdd 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -15,9 +15,9 @@ The following are best practices we at utPLSQL have learned about PL/SQL and Uni - Tests should not mimic / duplicate the logic of tested code - Tests should contain zero logic (or as close to zero as possible) - The 3A rule: - - Arrange (setup inputs/data/environment for the tested code) - - Act (execute code under test) - - Assert (validate the outcomes of the execution) + - Arrange (setup inputs/data/environment for the tested code) + - Act (execute code under test) + - Assert (validate the outcomes of the execution) - Each tested procedure/function/trigger (code block) should have more than one test - Each test should check only one behavior (one requirement) of the code block under test - Tests should be maintained as thoroughly as production code From 03c231cd44b60f218dd61c2f8a1abf8713d3503d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 18 Feb 2024 15:58:08 +0000 Subject: [PATCH 461/887] Updated project version after build [skip ci] --- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 18 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/about/authors.md b/docs/about/authors.md index c4c40bfad..228cb8451 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 702ea3f9c..fc4dbea8b 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 60aa6a657..cb30adf37 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index fc412205d..452c69dab 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 8325ec636..01a850083 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 1f7f2d191..df8c9d47d 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index d1ff5da07..72c70de2e 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 57a108fdd..d1448fa23 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 5d071335e..d3e7ef42e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index ca52ac951..43d67eb68 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b6f3d7e29..c4ddb4757 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 9620878ad..964ccbdcf 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 8f32c5a10..08bd036b0 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index e3ec1f53d..77307bf7c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index e37ac6627..cd49d7c38 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 3b23f5f98..941a00e36 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e5537f520..623bef999 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4187--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 522da1480..9bdf0c7a5 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4187-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4194-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 688aad2f0a9d4b39b69d44de5e7d0b5834966702 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 19 Feb 2024 23:14:30 +0200 Subject: [PATCH 462/887] Simplification of the release process. --- .github/scripts/get_project_build_version.sh | 2 -- .github/scripts/get_project_version.sh | 13 +++-------- .../set_release_version_numbers_env.sh | 9 ++++++++ .github/scripts/set_version_numbers_env.sh | 12 ++++------ .github/scripts/update_project_version.sh | 1 + .github/workflows/build.yml | 2 +- .github/workflows/release.yml | 2 +- BUILD_NO | 1 + development/releasing.md | 23 ++++++++----------- 9 files changed, 31 insertions(+), 34 deletions(-) delete mode 100755 .github/scripts/get_project_build_version.sh create mode 100755 .github/scripts/set_release_version_numbers_env.sh create mode 100644 BUILD_NO diff --git a/.github/scripts/get_project_build_version.sh b/.github/scripts/get_project_build_version.sh deleted file mode 100755 index 838523b05..000000000 --- a/.github/scripts/get_project_build_version.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/usr/bin/env bash -echo `sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/" <<< "${UTPLSQL_VERSION}"` diff --git a/.github/scripts/get_project_version.sh b/.github/scripts/get_project_version.sh index 60fc0a796..54a30a562 100755 --- a/.github/scripts/get_project_version.sh +++ b/.github/scripts/get_project_version.sh @@ -1,14 +1,7 @@ #!/usr/bin/env bash - -#When building a new version from a release branch, the version is taken from release branch name -if [[ "${CI_ACTION_REF_NAME}" =~ ^release/v[0-9]+\.[0-9]+\.[0-9]+.*$ ]]; then - version=${CI_ACTION_REF_NAME#release\/} -else - #Otherwise, version is taken from the VERSION file - version=`cat VERSION` - #When on develop branch, add "-develop" to the version text - if [[ "${CI_ACTION_REF_NAME}" == "develop" ]]; then +version=`cat VERSION` +#When on develop branch, add "-develop" to the version text +if [[ "${CI_ACTION_REF_NAME}" == "develop" ]]; then version=`sed -E "s/(v?[0-9]+\.[0-9]+\.[0-9]+).*/\1-develop/" <<< "${version}"` - fi fi echo ${version} diff --git a/.github/scripts/set_release_version_numbers_env.sh b/.github/scripts/set_release_version_numbers_env.sh new file mode 100755 index 000000000..a43843508 --- /dev/null +++ b/.github/scripts/set_release_version_numbers_env.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +build_no=$(cat BUILD_NO) +version=${CI_ACTION_REF_NAME} + +echo "UTPLSQL_BUILD_NO=${build_no}" >> $GITHUB_ENV +echo "UTPLSQL_VERSION=${version}" >> $GITHUB_ENV +echo UTPLSQL_BUILD_VERSION=$(echo ${version} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${build_no}\4/") >> $GITHUB_ENV + diff --git a/.github/scripts/set_version_numbers_env.sh b/.github/scripts/set_version_numbers_env.sh index 10529a1bf..c61639bf9 100755 --- a/.github/scripts/set_version_numbers_env.sh +++ b/.github/scripts/set_version_numbers_env.sh @@ -1,10 +1,8 @@ #!/bin/bash -UTPLSQL_BUILD_NO=$( expr ${GITHUB_RUN_NUMBER} + ${UTPLSQL_BUILD_NO_OFFSET} ) -UTPLSQL_VERSION=$(.github/scripts/get_project_version.sh) +build_no=$( expr ${GITHUB_RUN_NUMBER} + ${UTPLSQL_BUILD_NO_OFFSET} ) +version=$(.github/scripts/get_project_version.sh) -echo "UTPLSQL_BUILD_NO=${UTPLSQL_BUILD_NO}" >> $GITHUB_ENV -echo "UTPLSQL_VERSION=${UTPLSQL_VERSION}" >> $GITHUB_ENV -echo UTPLSQL_BUILD_VERSION=$(echo ${UTPLSQL_VERSION} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${UTPLSQL_BUILD_NO}\4/") >> $GITHUB_ENV - -echo "CURRENT_BRANCH=${CI_ACTION_REF_NAME}" >> $GITHUB_ENV +echo "UTPLSQL_BUILD_NO=${build_no}" >> $GITHUB_ENV +echo "UTPLSQL_VERSION=${version}" >> $GITHUB_ENV +echo UTPLSQL_BUILD_VERSION=$(echo ${version} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${build_no}\4/") >> $GITHUB_ENV diff --git a/.github/scripts/update_project_version.sh b/.github/scripts/update_project_version.sh index 586cb5b64..66e45125a 100755 --- a/.github/scripts/update_project_version.sh +++ b/.github/scripts/update_project_version.sh @@ -16,4 +16,5 @@ sed -i -r "s/(sonar\.projectVersion=).*?/\1${UTPLSQL_VERSION}/" sonar-project.pr echo Update VERSION file echo ${UTPLSQL_VERSION} > VERSION +echo ${UTPLSQL_BUILD_NO} > BUILD_NO diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c2fe3971e..668f1e5a4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -245,7 +245,7 @@ jobs: - name: Push version update to repository id: push-version-number-update run: | - git add sonar-project.properties VERSION source/* docs/* + git add sonar-project.properties VERSION BUILD_NO source/* docs/* git commit -m 'Updated project version after build [skip ci]' git push --quiet origin HEAD:${CI_ACTION_REF_NAME} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a748d1cbd..0e29bd5c1 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -25,7 +25,7 @@ jobs: - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action - name: Set build version number env variables - run: .github/scripts/set_version_numbers_env.sh + run: .github/scripts/set_release_version_numbers_env.sh - name: Update project version & build number in source code and documentation run: .github/scripts/update_project_version.sh diff --git a/BUILD_NO b/BUILD_NO new file mode 100644 index 000000000..9ae5f9c77 --- /dev/null +++ b/BUILD_NO @@ -0,0 +1 @@ +4194 \ No newline at end of file diff --git a/development/releasing.md b/development/releasing.md index 2b9be317a..c1e49184d 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -3,28 +3,25 @@ To create a release follow the below steps ## Release preparation - - Create a **draft** of a Release with version number `vX.Y.X` sourced from the `main` branch using [github releases page](https://github.com/utPLSQL/utPLSQL/releases) and populate release description using information found on the issues and pull requests **since previous release**. - To find issues closed after certain date use [advanced filters](https://help.github.com/articles/searching-issues-and-pull-requests/#search-by-open-or-closed-state). - Example: [`is:issue closed:>2018-07-22`](https://github.com/utPLSQL/utPLSQL/issues?utf8=%E2%9C%93&q=is%3Aissue+closed%3A%3E2018-07-22+) + - Create a **draft** of a Release with a new tag number `vX.Y.X` sourced from the `develop` branch on [github releases page](https://github.com/utPLSQL/utPLSQL/releases) + - Populate release description using the `Generate release notes` button + - Review the auto-generated release notes and update tem if needed + - Split the default `## What's Changed` list into `## New features`, `## Enhancements`, `## Bug fixes`. See previous release notes for details ## Performing a release - - create the release branch from `develop` branch and make sure to name the release branch: `release/vX.Y.Z` - - update, commit and push at least one file change in the release branch, to kick off a build on [GithubActions](https://github.com/utPLSQL/utPLSQL/actions) or kick-off a build manually for that branch after it was created on github. - - wait for the build to complete successfully as it will update the version to be release number (without develop) - - merge the release branch to `main` branch and publish [the previously prepared](#release-preparation) release draft. + - Publish [the previously prepared](#release-preparation) release draft. - Wait for the [Github Actions `Release`](https://github.com/utPLSQL/utPLSQL/actions/workflows/release.yml) process to complete successfully. The process will upload release artifacts (`zip` and `tar.gz` files along with `md5`) - - After Release build was completed successfully, merge the `main` branch back into `develop` branch. At this point, main branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. - - After develop branch was built, increase the version number in `VERSION` file to represent next planned release version. + - After Release build was completed successfully, merge the `develop` branch into `main` branch. At this point, main branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. + - Increase the version number in the `VERSION` file on `develop` branch to open start next release version. - Clone `utplsql.githug.io` project and: - Add a new announcement about next version being released in `docs/_posts`. Use previous announcements as a template. Make sure to set date, time and post title properly. - Add the post to list in `mkdocs.yml` file in root directory of that repository. - Add the link to the post at the beginning of the `docs/index.md` file. + - Send the announcement on Twitter(X) accoiunt abut utPLSQL release. The following will happen: - - build executed on branch `release/vX.Y.Z-[something]` updates files `sonar-project.properties`, `VERSION` with project version derived from the release branch name - - changes to those two files are committed and pushed back to release branch - - when a Github release is published, a new tag is added in on the repository and a release build is executed - - With Release build, the documentation for new release is published on `utplsql.github.io` and installation archives are added to the release. + - When a Github release is published, a new tag is added in on the repository and a release build is executed + - With Release action, the documentation for new release is published on `utplsql.github.io` and installation archives are added to the release. # Note: The utPLSQL installation files are uploaded by the release build process as release artifacts (separate `zip` and `tar.gz` files). From fc9382e27515762ca5a4cbfa747d54de47e2675c Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 19 Feb 2024 23:24:21 +0200 Subject: [PATCH 463/887] Fixed a flaky test when test runs in 0 seconds. --- test/ut3_user/api/test_ut_run.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index e80235744..f0cfd8373 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -742,7 +742,7 @@ Failures:% procedure remove_time_from_results(a_results in out nocopy ut3_develop.ut_varchar2_list) is begin for i in 1 .. a_results.count loop - a_results(i) := regexp_replace(a_results(i),'\[[0-9]*[\.,][0-9]+ sec\]',''); + a_results(i) := regexp_replace(a_results(i),'\[[0-9]*[\.,]?[0-9]+ sec\]',''); a_results(i) := regexp_replace(a_results(i),'Finished in [0-9]*[\.,][0-9]+ seconds',''); end loop; end; From 072dfbc1d0ed37f8da9c0ff87823906483ea3887 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 19 Feb 2024 21:41:43 +0000 Subject: [PATCH 464/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 9ae5f9c77..26de2ed80 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4194 \ No newline at end of file +4197 diff --git a/docs/about/authors.md b/docs/about/authors.md index 228cb8451..203d450d1 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index fc4dbea8b..28aea5fed 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index cb30adf37..8e6730847 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 452c69dab..0748fd479 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 01a850083..320784892 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index df8c9d47d..34b4eddcc 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 72c70de2e..b3602ef10 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index d1448fa23..379024e73 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index d3e7ef42e..24855cbb5 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 43d67eb68..e2a8bc7da 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c4ddb4757..472c9654e 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 964ccbdcf..9c4d8813a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 08bd036b0..c322639df 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 77307bf7c..463bcef97 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index cd49d7c38..41468a3a5 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 941a00e36..502bd49bd 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 623bef999..cb49a0424 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4194--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 9bdf0c7a5..463aa1604 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4194-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4197-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 614a0e00bd0285c3a938de5cdf83a9c3aa547202 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Mon, 19 Feb 2024 23:47:32 +0200 Subject: [PATCH 465/887] Remove deprecated github actions and update releasing documentation. --- .github/workflows/build.yml | 4 ++-- .github/workflows/release.yml | 2 +- development/releasing.md | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 668f1e5a4..3d2f9a0a0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -88,7 +88,7 @@ jobs: --health-cmd healthcheck.sh steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: fetch-depth: 0 - uses: c-py/action-dotenv-to-setenv@v2 @@ -183,7 +183,7 @@ jobs: run: bash .github/scripts/validate_report_files.sh - name: Codecov - uses: codecov/codecov-action@v2 + uses: codecov/codecov-action@v4 with: token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos files: ./cobertura.xml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0e29bd5c1..1c4db5d59 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: fetch-depth: 0 - uses: c-py/action-dotenv-to-setenv@v2 diff --git a/development/releasing.md b/development/releasing.md index c1e49184d..ac2091632 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -6,7 +6,7 @@ To create a release follow the below steps - Create a **draft** of a Release with a new tag number `vX.Y.X` sourced from the `develop` branch on [github releases page](https://github.com/utPLSQL/utPLSQL/releases) - Populate release description using the `Generate release notes` button - Review the auto-generated release notes and update tem if needed - - Split the default `## What's Changed` list into `## New features`, `## Enhancements`, `## Bug fixes`. See previous release notes for details + - Optionally, split the default `## What's Changed` list into `## New features`, `## Enhancements`, `## Bug fixes`. See previous release notes for details ## Performing a release - Publish [the previously prepared](#release-preparation) release draft. From 5a42ce5ea71045b4cafa063ccc57781fa7ce09ae Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 19 Feb 2024 21:56:00 +0000 Subject: [PATCH 466/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 26de2ed80..8c8049510 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4197 +4198 diff --git a/docs/about/authors.md b/docs/about/authors.md index 203d450d1..541662a36 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 28aea5fed..f07bdd4b4 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 8e6730847..0cd02e09e 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 0748fd479..195b194e3 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 320784892..8f1cc584e 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 34b4eddcc..4068e2d09 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index b3602ef10..57cb29685 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 379024e73..b016fdac0 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 24855cbb5..f48051ba5 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e2a8bc7da..b580b7077 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 472c9654e..19e77835a 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 9c4d8813a..1cf1f9d2f 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index c322639df..4fdd04af6 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 463bcef97..2c6ae2d95 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 41468a3a5..8042fcd55 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 502bd49bd..7f8f6d620 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index cb49a0424..11410dd2b 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4197--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 463aa1604..36264fafc 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4197-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4198-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 42b923be7f4c46768c4f62eeb347b45590f11ad3 Mon Sep 17 00:00:00 2001 From: Jacek Gebal Date: Tue, 20 Feb 2024 00:39:24 +0200 Subject: [PATCH 467/887] Removed unneeded files from the release archives. --- .gitattributes | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitattributes b/.gitattributes index 5e0c801de..2cda5ad55 100644 --- a/.gitattributes +++ b/.gitattributes @@ -6,6 +6,8 @@ test export-ignore .gitignore export-ignore .gitmodules export-ignore mkdocs.yml export-ignore +BUILD_NO export-ignore +mkdocs_offline.yml export-ignore sonar-project.properties export-ignore ^docs/** linguist-documentation *.pkb linguist-language=PLSQL From 629e6116887b1921f956ff6dd449ed9b9b1e29da Mon Sep 17 00:00:00 2001 From: bozo030 Date: Tue, 21 May 2024 11:59:34 +0200 Subject: [PATCH 468/887] Matcher shortcut syntax example fixed --- docs/userguide/expectations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 19e77835a..ec24b570c 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -52,7 +52,7 @@ Shortcut syntax, where matcher is directly part of expectation: ut.expect( a_actual ).not_to_{matcher}; --example - ut.expect( 1 ).to_( be_null() ); + ut.expect( 1 ).to_be_null(); ``` When using shortcut syntax you don't need to surround matcher with brackets. Shortcut syntax is provided for convenience. From 3f4dc81ccaa2625b8da111e446105d6d51ef32de Mon Sep 17 00:00:00 2001 From: Samuel Nitsche Date: Tue, 17 Sep 2024 22:58:03 +0200 Subject: [PATCH 469/887] Update build.yml to use actions/upload-artifact@v4 as described in https://github.blog/news-insights/product-news/get-started-with-v4-of-github-actions-artifacts/ --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3d2f9a0a0..af2e4875d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -172,7 +172,7 @@ jobs: - name: Upload ORACLE_BASE/diag data Artifact id: upload if: ${{ always() && steps.run-tests.outcome == 'failure' }} - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: name: my-artifact$-${{matrix.db_version_name}} path: ${{github.workspace}}/database-diag From ca88e498e8e374776f76a5f63d136f2609c6c60c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 23 Oct 2024 00:30:02 +0300 Subject: [PATCH 470/887] Update test_realtime_reporter.pkb Fixing failing test for 23ai --- test/ut3_user/reporters/test_realtime_reporter.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_user/reporters/test_realtime_reporter.pkb b/test/ut3_user/reporters/test_realtime_reporter.pkb index 2dafa71d0..84053c3c9 100644 --- a/test/ut3_user/reporters/test_realtime_reporter.pkb +++ b/test/ut3_user/reporters/test_realtime_reporter.pkb @@ -408,7 +408,7 @@ create or replace package body test_realtime_reporter as from table(g_events) t where t.event_doc.extract('/event[@type="post-test"]/test/@id').getstringval() = 'realtime_reporting.check_realtime_reporting3.test_6_with_runtime_error'; - ut3_tester_helper.main_helper.append_to_list(l_expected_list, ''); l_expected := ut3_tester_helper.main_helper.table_to_clob(l_expected_list); From 5241c43e2b25d718a8ecc3e5c26820af852310ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 23 Oct 2024 00:38:54 +0300 Subject: [PATCH 471/887] Update test_documentation_reporter.pkb Fixed failing unit test --- test/ut3_user/reporters/test_documentation_reporter.pkb | 1 - 1 file changed, 1 deletion(-) diff --git a/test/ut3_user/reporters/test_documentation_reporter.pkb b/test/ut3_user/reporters/test_documentation_reporter.pkb index 2a05679ff..016cec256 100644 --- a/test/ut3_user/reporters/test_documentation_reporter.pkb +++ b/test/ut3_user/reporters/test_documentation_reporter.pkb @@ -34,7 +34,6 @@ Failures: "Fails as values are different" Actual: 'number [1] ' (varchar2) was expected to equal: 'number [2] ' (varchar2)% at "UT3_USER.TEST_REPORTERS%", line 36 ut3_develop.ut.expect('number [1] ','Fails as values are different').to_equal('number [2] '); -% % 2) erroring_test ORA-06502: PL/SQL: %: character to number conversion error From 1819ca766160a4b6c82090b7304512b68d08b063 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 22 Oct 2024 22:47:42 +0100 Subject: [PATCH 472/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 8c8049510..fab85b21d 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4198 +4206 diff --git a/docs/about/authors.md b/docs/about/authors.md index 541662a36..499398993 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index f07bdd4b4..03cc286eb 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 0cd02e09e..5579a943b 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 195b194e3..6d68864bd 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 8f1cc584e..b277c9d16 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 4068e2d09..45fca1871 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 57cb29685..31a91cac2 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b016fdac0..6becefc5c 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index f48051ba5..c9015b438 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index b580b7077..824aaecd5 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index ec24b570c..54c204d58 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 1cf1f9d2f..1ff54a7d6 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 4fdd04af6..9d8167739 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 2c6ae2d95..24159fede 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 8042fcd55..9b1a7e75b 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 7f8f6d620..375a05125 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 11410dd2b..6fdaa6a48 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4198--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 36264fafc..0e1e0a851 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4198-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4206-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 808fcdfc31c17dac2fedc41a440f55d7f7bd9bbe Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 29 Mar 2025 16:43:12 +0000 Subject: [PATCH 473/887] Update documentation for customer reporter --- docs/userguide/reporters.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 9b1a7e75b..24d1065fe 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -175,6 +175,16 @@ If you need to produce a colored text output from the custom reporter, then you It is recommended to create the reporter type in the schema where utPLSQL is installed (by default it is the `UT3` schema). Note that before running the utPLSQL uninstall scripts, all custom reporters should be dropped (cf. [the installation documentation](install.md)). In particular, when upgrading to a newer version of utPLSQL, one has to drop the custom reporters and recreate them after the upgrade. +!!! note + Please make sure that grants have been added and synonyms created for the custom reporter in order for reporter to be accessible the same way as other reporters. + Assuming that reporter with name `customer_reporter` was created in schema `UT3` +```sql + grant execute on ut3.custom_reporter to public; + create or replace public synonym custom_reporter for ut3.custom_reporter; +``` + + + !!! note It is possible, but cumbersome, to use another schema for storing the custom reporters. This requires to create a synonym for the base reporter type in the schema that is going to own the custom reporter, and to provide appropriate grants both to the owner of the custom reporter and to the user running the reporter. After upgrading or reinstalling utPLSQL, the extra privileges need to be recreated. This approach is not recommended. From 39ff2ed0090a22fe680f5de38a2aa87f31b95226 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 2 Apr 2025 20:41:46 +0100 Subject: [PATCH 474/887] Adding tests for issue 1293 --- .../expectations/test_expectations_cursor.pkb | 42 +++++++++++++++++++ .../expectations/test_expectations_cursor.pks | 6 +++ 2 files changed, 48 insertions(+) diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index 847cce9a0..867a5f3db 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -2950,5 +2950,47 @@ Rows: [ 2 differences ] ); end; + procedure cursor_joinby_compare_issue_1293 is + l_actual sys_refcursor; + l_expected sys_refcursor; + begin + --Arrange + open l_expected for + select 'FOO' username, 12 from dual union all + select 'TEST' username, -600 user_id from dual + order by 1 desc; + open l_actual for + select 'FOO' username, 12 from dual union all + select 'TEST' username, -600 user_id from dual union all + -- DUPLICATE!!! + select 'TEST' username, -600 user_id from dual + order by 1 asc; + --Act + ut3_develop.ut.expect(l_actual).to_equal(l_expected).join_by('USERNAME'); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); + end; + + procedure cursor_not_joinby_compare_issue_1293 is + l_actual sys_refcursor; + l_expected sys_refcursor; + begin + --Arrange + open l_expected for + select 'FOO' username, 12 from dual union all + select 'TEST' username, -600 user_id from dual + order by 1 desc; + open l_actual for + select 'FOO' username, 12 from dual union all + select 'TEST' username, -600 user_id from dual union all + -- DUPLICATE!!! + select 'TEST' username, -600 user_id from dual + order by 1 asc; + --Act + ut3_develop.ut.expect(l_actual).to_equal(l_expected); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); + end; + end; / diff --git a/test/ut3_user/expectations/test_expectations_cursor.pks b/test/ut3_user/expectations/test_expectations_cursor.pks index 0f34486a9..53f754322 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pks +++ b/test/ut3_user/expectations/test_expectations_cursor.pks @@ -485,5 +485,11 @@ create or replace package test_expectations_cursor is --%test( Multiple failures reported correctly - Issue #998 ) procedure multiple_cursor_expectations; + --%test( Compares cursors with duplicate rows using join by - Issue #1293 ) + procedure cursor_joinby_compare_issue_1293; + + --%test( Compares cursors with duplicate rows - Issue #1293 ) + procedure cursor_not_joinby_compare_issue_1293; + end; / From 85734ffec7f57efff073d833ee2d43de1a9ad0f2 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 3 Apr 2025 18:38:33 +0100 Subject: [PATCH 475/887] For a join by key we need to also compare by duplicate numbers to make sure that we have same amount of rows when rows are identical but row counts is different. --- source/expectations/data_values/ut_compound_data_helper.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 4517cd43c..875ec760a 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -300,8 +300,8 @@ create or replace package body ut_compound_data_helper is ut_utils.append_to_clob(a_partition_stmt,' row_number() over (partition by '||l_partition_tmp||' order by '||l_partition_tmp||' ) '); if a_pk_table.count > 0 then - -- If key defined do the join or these and where on diffrences - a_join_by_stmt := ut_utils.table_to_clob(l_join_by_list, ' and '); + -- If key defined do the join or these and where on diffrences as well as on duplicate number when rows are same. + a_join_by_stmt := ' e."UT3$_Dup#No" = a."UT3$_Dup#No" and '||ut_utils.table_to_clob(l_join_by_list, ' and '); elsif a_unordered then -- If no key defined do the join on all columns a_join_by_stmt := ' e."UT3$_Dup#No" = a."UT3$_Dup#No" and '||ut_utils.table_to_clob(l_equal_list, ' and '); From 6f273df2752c7a0665debbc9532886ea01f8ff5a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Thu, 3 Apr 2025 19:49:58 +0100 Subject: [PATCH 476/887] Change procedure nameto be less 30 to work for 11 and 12 --- test/ut3_user/expectations/test_expectations_cursor.pkb | 4 ++-- test/ut3_user/expectations/test_expectations_cursor.pks | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index 867a5f3db..a4ef4e8f2 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -2950,7 +2950,7 @@ Rows: [ 2 differences ] ); end; - procedure cursor_joinby_compare_issue_1293 is + procedure cr_joinby_compare_issue_1293 is l_actual sys_refcursor; l_expected sys_refcursor; begin @@ -2971,7 +2971,7 @@ Rows: [ 2 differences ] ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_be_greater_than(0); end; - procedure cursor_not_joinby_compare_issue_1293 is + procedure cr_not_joinby_comp_issue_1293 is l_actual sys_refcursor; l_expected sys_refcursor; begin diff --git a/test/ut3_user/expectations/test_expectations_cursor.pks b/test/ut3_user/expectations/test_expectations_cursor.pks index 53f754322..8cceb5e01 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pks +++ b/test/ut3_user/expectations/test_expectations_cursor.pks @@ -486,10 +486,10 @@ create or replace package test_expectations_cursor is procedure multiple_cursor_expectations; --%test( Compares cursors with duplicate rows using join by - Issue #1293 ) - procedure cursor_joinby_compare_issue_1293; + procedure cr_joinby_compare_issue_1293; --%test( Compares cursors with duplicate rows - Issue #1293 ) - procedure cursor_not_joinby_compare_issue_1293; + procedure cr_not_joinby_comp_issue_1293; end; / From 933f41a70510a04c2eef89846301458009a312e8 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Thu, 10 Jul 2025 13:16:55 +0200 Subject: [PATCH 477/887] Added TAP reporter and synonyms --- source/create_grants.sql | 1 + source/create_synonyms.sql | 1 + source/reporters/ut_tap_reporter.tpb | 104 +++++++++++++++++++++++++++ source/reporters/ut_tap_reporter.tps | 13 ++++ 4 files changed, 119 insertions(+) create mode 100644 source/reporters/ut_tap_reporter.tpb create mode 100644 source/reporters/ut_tap_reporter.tps diff --git a/source/create_grants.sql b/source/create_grants.sql index 0e9f46cc5..2cdea9970 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -104,6 +104,7 @@ grant execute on &&ut3_owner..ut_tfs_junit_reporter to &ut3_user; grant execute on &&ut3_owner..ut_documentation_reporter to &ut3_user; grant execute on &&ut3_owner..ut_sonar_test_reporter to &ut3_user; grant execute on &&ut3_owner..ut_realtime_reporter to &ut3_user; +grant execute on &&ut3_owner..ut_tap_reporter to &ut3_user; --reporters - coverage grant execute on &&ut3_owner..ut_coverage_html_reporter to &ut3_user; grant execute on &&ut3_owner..ut_coverage_sonar_reporter to &ut3_user; diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index fa1c1dc45..d839e11b7 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -119,6 +119,7 @@ create &action_type. synonym &ut3_user.ut_tfs_junit_reporter for &&ut3_owner..ut create &action_type. synonym &ut3_user.ut_documentation_reporter for &&ut3_owner..ut_documentation_reporter; create &action_type. synonym &ut3_user.ut_sonar_test_reporter for &&ut3_owner..ut_sonar_test_reporter; create &action_type. synonym &ut3_user.ut_realtime_reporter for &&ut3_owner..ut_realtime_reporter; +create &action_type. synonym &ut3_user.ut_tap_reporter for &&ut3_owner..ut_tap_reporter; --reporters - coverage create &action_type. synonym &ut3_user.ut_coverage_html_reporter for &&ut3_owner..ut_coverage_html_reporter; create &action_type. synonym &ut3_user.ut_coverage_sonar_reporter for &&ut3_owner..ut_coverage_sonar_reporter; diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb new file mode 100644 index 000000000..f3f511d05 --- /dev/null +++ b/source/reporters/ut_tap_reporter.tpb @@ -0,0 +1,104 @@ +create or replace type body ut_tap_reporter is + + + constructor function ut_tap_reporter(self in out nocopy ut_tap_reporter) return self as result is + begin + self.init($$plsql_unit); + self.lvl := 0; + return; + end ut_tap_reporter; + + overriding member procedure before_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite) as + begin + self.print_text('# Subtest: ' || coalesce(a_suite.description, a_suite.name)); + lvl := lvl + 2; + self.print_text('1..' || a_suite.items.count); + end before_calling_suite; + + overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test) as + l_message varchar2(4000); + l_test_name varchar2(300) := coalesce(a_test.description, a_test.name); + + procedure print_failed_expectation(a_test ut_test) is + l_lines ut_varchar2_list; + l_failed boolean; + begin + if a_test.get_error_stack_traces().count = 0 then + -- If no error occurred, print failed expectation + l_lines := a_test.all_expectations(a_test.all_expectations.last).get_result_lines(); + l_failed := a_test.all_expectations(a_test.all_expectations.last).status >= ut_utils.gc_success; + if l_failed then + self.print_text('message: ''' || l_lines(1) || ''''); + self.print_text('severity: fail'); + end if; + else + -- Print multi-line YAML-String with implicit newline characters + self.print_text('message: |'); + self.lvl := self.lvl + 1; + self.print_text(ut_utils.table_to_clob(a_test.get_error_stack_traces())); + self.lvl := self.lvl - 1; + self.print_text('severity: error'); + end if; + end print_failed_expectation; + + begin + + if a_test.result = ut_utils.gc_disabled then + self.print_text('ok - ' || l_test_name || ' # SKIP'|| + case when a_test.disabled_reason is not null + then ': '||a_test.disabled_reason + else null + end ); + elsif a_test.result = ut_utils.gc_success then + self.print_text('ok - ' || l_test_name); + elsif a_test.result > ut_utils.gc_success then + if self.lvl = 0 then + self.print_text(ut_ansiconsole_helper.red('not ok') || ' - ' || l_test_name); + else + self.print_text('not ok - ' || l_test_name); + end if; + self.lvl := self.lvl + 1; + self.print_text('---'); + print_failed_expectation(a_test); + self.print_text('...'); + self.lvl := self.lvl - 1; + end if; + + end after_calling_test; + + overriding member procedure after_calling_before_all(self in out nocopy ut_tap_reporter, a_executable in ut_executable) is + begin + if a_executable.serveroutput is not null and a_executable.serveroutput != empty_clob() then + self.print_clob(a_executable.serveroutput); + end if; + end after_calling_before_all; + + overriding member procedure after_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite) as + l_suite_name varchar2(300) := coalesce(a_suite.description, a_suite.name); + begin + lvl := lvl - 2; + if lvl = 0 then + if a_suite.result = ut_utils.gc_success then + self.print_text('ok - ' || l_suite_name); + elsif a_suite.result > ut_utils.gc_success then + self.print_text(ut_ansiconsole_helper.red('not ok') || ' - ' || l_suite_name); + end if; + + self.print_text(' '); + end if; + + end after_calling_suite; + + overriding member procedure before_calling_run(self in out nocopy ut_tap_reporter, a_run in ut_run) as + begin + self.print_text('TAP version 14'); + self.print_text('1..' || a_run.items.count); + self.print_text(' '); + end before_calling_run; + + overriding member procedure after_calling_run(self in out nocopy ut_tap_reporter, a_run in ut_run) as + begin + self.lvl := 0; + end; +end; +/ \ No newline at end of file diff --git a/source/reporters/ut_tap_reporter.tps b/source/reporters/ut_tap_reporter.tps new file mode 100644 index 000000000..3e792b1f7 --- /dev/null +++ b/source/reporters/ut_tap_reporter.tps @@ -0,0 +1,13 @@ +create or replace type ut_tap_reporter under ut_documentation_reporter( + + constructor function ut_tap_reporter(self in out nocopy ut_tap_reporter) return self as result, + overriding member procedure before_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite), + overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test), + overriding member procedure after_calling_before_all (self in out nocopy ut_tap_reporter, a_executable in ut_executable), + overriding member procedure before_calling_run(self in out nocopy ut_tap_reporter, a_run in ut_run), + overriding member procedure after_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite), + overriding member procedure after_calling_run(self in out nocopy ut_tap_reporter, a_run in ut_run) + +) +not final +/ \ No newline at end of file From c5f07a76885105d2044a655925e94f9dcbf9de9e Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Thu, 10 Jul 2025 13:21:28 +0200 Subject: [PATCH 478/887] Larger variables to prevent failure during reporting --- source/reporters/ut_tap_reporter.tpb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index f3f511d05..6ae764399 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -17,7 +17,7 @@ create or replace type body ut_tap_reporter is overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test) as l_message varchar2(4000); - l_test_name varchar2(300) := coalesce(a_test.description, a_test.name); + l_test_name varchar2(4000) := coalesce(a_test.description, a_test.name); procedure print_failed_expectation(a_test ut_test) is l_lines ut_varchar2_list; @@ -74,7 +74,7 @@ create or replace type body ut_tap_reporter is end after_calling_before_all; overriding member procedure after_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite) as - l_suite_name varchar2(300) := coalesce(a_suite.description, a_suite.name); + l_suite_name varchar2(4000) := coalesce(a_suite.description, a_suite.name); begin lvl := lvl - 2; if lvl = 0 then From 4ed6837276570eac30c7fd674d47ff927077695b Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Fri, 11 Jul 2025 21:29:06 +0200 Subject: [PATCH 479/887] Added TAP Reporter to install script --- source/install.sql | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/install.sql b/source/install.sql index 827213e6c..22ce75365 100644 --- a/source/install.sql +++ b/source/install.sql @@ -346,6 +346,8 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'reporters/ut_xunit_reporter.tpb' @@install_component.sql 'reporters/ut_sonar_test_reporter.tps' @@install_component.sql 'reporters/ut_sonar_test_reporter.tpb' +@@install_component.sql 'reporters/ut_tap_reporter.tps' +@@install_component.sql 'reporters/ut_tap_reporter.tpb' @@install_component.sql 'reporters/ut_coverage_html_reporter.tps' @@install_component.sql 'reporters/ut_coverage_report_html_helper.pks' From 5e656fe4a953f207fcf0618232886d32764d158e Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Fri, 11 Jul 2025 21:40:41 +0200 Subject: [PATCH 480/887] Add TAP to expected reporters --- test/ut3_user/api/test_ut_runner.pkb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/ut3_user/api/test_ut_runner.pkb b/test/ut3_user/api/test_ut_runner.pkb index b6b7c67e7..d665718e1 100644 --- a/test/ut3_user/api/test_ut_runner.pkb +++ b/test/ut3_user/api/test_ut_runner.pkb @@ -393,7 +393,8 @@ end;'; select 'UT3_DEVELOP.UT_SONAR_TEST_REPORTER', 'Y' from dual union all select 'UT3_DEVELOP.UT_TEAMCITY_REPORTER', 'Y' from dual union all select 'UT3_DEVELOP.UT_TFS_JUNIT_REPORTER', 'Y' from dual union all - select 'UT3_DEVELOP.UT_XUNIT_REPORTER', 'Y' from dual + select 'UT3_DEVELOP.UT_XUNIT_REPORTER', 'Y' from dual union all + select 'UT3_DEVELOP.UT_TAP_REPORTER', 'Y' from dual order by 1; --Act open l_actual for select * from table(ut3_develop.ut_runner.GET_REPORTERS_LIST()) order by 1; From 6f47bb9999e3a07713416372bc42d2a41a47b692 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Mon, 14 Jul 2025 21:06:20 +0200 Subject: [PATCH 481/887] Added simple test for TAP reporter --- source/reporters/ut_tap_reporter.tpb | 9 ++++++++- source/reporters/ut_tap_reporter.tps | 1 + test/install_ut3_user_tests.sql | 2 ++ test/ut3_user/reporters/test_tap_reporter.pkb | 17 +++++++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 10 ++++++++++ 5 files changed, 38 insertions(+), 1 deletion(-) create mode 100644 test/ut3_user/reporters/test_tap_reporter.pkb create mode 100644 test/ut3_user/reporters/test_tap_reporter.pks diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 6ae764399..05779cfcf 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -69,10 +69,17 @@ create or replace type body ut_tap_reporter is overriding member procedure after_calling_before_all(self in out nocopy ut_tap_reporter, a_executable in ut_executable) is begin if a_executable.serveroutput is not null and a_executable.serveroutput != empty_clob() then - self.print_clob(a_executable.serveroutput); + self.print_clob('# ' || a_executable.serveroutput); end if; end after_calling_before_all; + overriding member procedure after_calling_after_all(self in out nocopy ut_tap_reporter, a_executable in ut_executable) is + begin + if a_executable.serveroutput is not null and a_executable.serveroutput != empty_clob() then + self.print_clob('# ' || a_executable.serveroutput); + end if; + end after_calling_after_all; + overriding member procedure after_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite) as l_suite_name varchar2(4000) := coalesce(a_suite.description, a_suite.name); begin diff --git a/source/reporters/ut_tap_reporter.tps b/source/reporters/ut_tap_reporter.tps index 3e792b1f7..cec7afebc 100644 --- a/source/reporters/ut_tap_reporter.tps +++ b/source/reporters/ut_tap_reporter.tps @@ -4,6 +4,7 @@ create or replace type ut_tap_reporter under ut_documentation_reporter( overriding member procedure before_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite), overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test), overriding member procedure after_calling_before_all (self in out nocopy ut_tap_reporter, a_executable in ut_executable), + overriding member procedure after_calling_after_all (self in out nocopy ut_tap_reporter, a_executable in ut_executable), overriding member procedure before_calling_run(self in out nocopy ut_tap_reporter, a_run in ut_run), overriding member procedure after_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite), overriding member procedure after_calling_run(self in out nocopy ut_tap_reporter, a_run in ut_run) diff --git a/test/install_ut3_user_tests.sql b/test/install_ut3_user_tests.sql index ad7f014bc..518e07841 100644 --- a/test/install_ut3_user_tests.sql +++ b/test/install_ut3_user_tests.sql @@ -43,6 +43,7 @@ set define off @@ut3_user/reporters/test_documentation_reporter.pks @@ut3_user/reporters/test_debug_reporter.pks @@ut3_user/reporters/test_realtime_reporter.pks +@@ut3_user/reporters/test_tap_reporter.pks @@ut3_user/reporters/test_coverage.pks @@ut3_user/reporters/test_coverage/test_coverage_standalone.pks set define on @@ -86,6 +87,7 @@ set define off @@ut3_user/reporters/test_documentation_reporter.pkb @@ut3_user/reporters/test_debug_reporter.pkb @@ut3_user/reporters/test_realtime_reporter.pkb +@@ut3_user/reporters/test_tap_reporter.pkb @@ut3_user/reporters/test_coverage/test_coverage_standalone.pkb set define on @@ut3_user/reporters/test_coverage/test_extended_coverage.pkb diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb new file mode 100644 index 000000000..6eaf2e4bb --- /dev/null +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -0,0 +1,17 @@ +create or replace package body test_tap_reporter as + + procedure simple_succeeding_test as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := 'TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters\s*1..1\s*# \s*# Subtest: A description of some context\s*1..1\s*ok - passing_test\s*# \s*ok - org\s*'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_reporters.passing_test',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); + end simple_succeeding_test; + +end test_tap_reporter; +/ \ No newline at end of file diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks new file mode 100644 index 000000000..9dca659e6 --- /dev/null +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -0,0 +1,10 @@ +create or replace package test_tap_reporter as + + --%suite(ut_tap_reporter) + --%suitepath(utplsql.test_user.reporters) + + --%test(Simple succeeding test) + procedure simple_succeeding_test; + +end test_tap_reporter; +/ \ No newline at end of file From 641ef7d2434334c7cfd5c8e184d5c110042eb08c Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Tue, 15 Jul 2025 16:36:52 +0200 Subject: [PATCH 482/887] Added failing test for TAP --- test/ut3_user/reporters/test_tap_reporter.pkb | 13 +++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 3 +++ 2 files changed, 16 insertions(+) diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 6eaf2e4bb..82a02af8a 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -13,5 +13,18 @@ create or replace package body test_tap_reporter as ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); end simple_succeeding_test; + procedure simple_failing_test as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters\s*1..1\s*# \s*not ok - a test with failing assertion\s*---\s*message: '"Fails as values are different"'\s*severity: fail\s*...\s*# \s*not ok - org\s*]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_reporters.failing_test',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); + end simple_failing_test; + end test_tap_reporter; / \ No newline at end of file diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index 9dca659e6..2bc35a8db 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -6,5 +6,8 @@ create or replace package test_tap_reporter as --%test(Simple succeeding test) procedure simple_succeeding_test; + --%test(Simple failing test) + procedure simple_failing_test; + end test_tap_reporter; / \ No newline at end of file From 2500604651a2e97d8b52f9b7fc5e298f2d6a0a1e Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Tue, 15 Jul 2025 17:12:44 +0200 Subject: [PATCH 483/887] Added erroring Test for TAP reporter --- test/ut3_user/reporters/test_tap_reporter.pkb | 14 ++++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 3 +++ 2 files changed, 17 insertions(+) diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 82a02af8a..1aadeb5f7 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -26,5 +26,19 @@ create or replace package body test_tap_reporter as ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); end simple_failing_test; + + procedure simple_erroring_test as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters\s*1..1\s*# \s*not ok - a test raising unhandled exception\s*---\s*message: |\s*ORA-06502: .*\s*ORA-06512: .*\s*ORA-06512: .*\s*ORA-06512: at line [[:digit:]]+\s*severity: error\s*...\s*# \s*not ok - org\s*]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_reporters.erroring_test',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); + end simple_erroring_test; + end test_tap_reporter; / \ No newline at end of file diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index 2bc35a8db..72b72ab4c 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -9,5 +9,8 @@ create or replace package test_tap_reporter as --%test(Simple failing test) procedure simple_failing_test; + --%test(Simple erroring test) + procedure simple_erroring_test; + end test_tap_reporter; / \ No newline at end of file From 9d765a42fa329f1710938d8db505dae5b7917048 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Wed, 16 Jul 2025 21:32:33 +0200 Subject: [PATCH 484/887] Added test for disabled TAP test --- source/reporters/ut_tap_reporter.tpb | 2 +- test/ut3_user/reporters/test_tap_reporter.pkb | 14 ++++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 3 +++ 3 files changed, 18 insertions(+), 1 deletion(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 05779cfcf..3eb783287 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -85,7 +85,7 @@ create or replace type body ut_tap_reporter is begin lvl := lvl - 2; if lvl = 0 then - if a_suite.result = ut_utils.gc_success then + if a_suite.result = ut_utils.gc_success or a_suite.result = ut_utils.gc_disabled then self.print_text('ok - ' || l_suite_name); elsif a_suite.result > ut_utils.gc_success then self.print_text(ut_ansiconsole_helper.red('not ok') || ' - ' || l_suite_name); diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 1aadeb5f7..6772dcd3f 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -40,5 +40,19 @@ create or replace package body test_tap_reporter as ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); end simple_erroring_test; + + procedure disabled_test as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters\s*1..1\s*# \s*ok - a disabled test # SKIP: Disabled for testing purpose\s*# \s*ok - org\s*]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_reporters.disabled_test',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); + end disabled_test; + end test_tap_reporter; / \ No newline at end of file diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index 72b72ab4c..a3c6475ab 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -12,5 +12,8 @@ create or replace package test_tap_reporter as --%test(Simple erroring test) procedure simple_erroring_test; + --%test(Skipped test) + procedure disabled_test; + end test_tap_reporter; / \ No newline at end of file From ef7f8114e4123c675a93f6b57a7b36ac94ff3a02 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Wed, 16 Jul 2025 21:43:17 +0200 Subject: [PATCH 485/887] Added boilerplate expression for shorter tests --- test/ut3_user/reporters/test_tap_reporter.pkb | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 6772dcd3f..40b66318b 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -1,10 +1,12 @@ create or replace package body test_tap_reporter as + gc_boilerplate_suitepath_expression constant varchar2(300) := 'TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters'; + procedure simple_succeeding_test as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := 'TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters\s*1..1\s*# \s*# Subtest: A description of some context\s*1..1\s*ok - passing_test\s*# \s*ok - org\s*'; + l_expected := gc_boilerplate_suitepath_expression || '\s*1..1\s*# \s*# Subtest: A description of some context\s*1..1\s*ok - passing_test\s*# \s*ok - org\s*'; select * bulk collect into l_output_data @@ -17,7 +19,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters\s*1..1\s*# \s*not ok - a test with failing assertion\s*---\s*message: '"Fails as values are different"'\s*severity: fail\s*...\s*# \s*not ok - org\s*]'; + l_expected := gc_boilerplate_suitepath_expression || q'[\s*1..1\s*# \s*not ok - a test with failing assertion\s*---\s*message: '"Fails as values are different"'\s*severity: fail\s*...\s*# \s*not ok - org\s*]'; select * bulk collect into l_output_data @@ -31,7 +33,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters\s*1..1\s*# \s*not ok - a test raising unhandled exception\s*---\s*message: |\s*ORA-06502: .*\s*ORA-06512: .*\s*ORA-06512: .*\s*ORA-06512: at line [[:digit:]]+\s*severity: error\s*...\s*# \s*not ok - org\s*]'; + l_expected := gc_boilerplate_suitepath_expression || q'[\s*1..1\s*# \s*not ok - a test raising unhandled exception\s*---\s*message: |\s*ORA-06502: .*\s*ORA-06512: .*\s*ORA-06512: .*\s*ORA-06512: at line [[:digit:]]+\s*severity: error\s*...\s*# \s*not ok - org\s*]'; select * bulk collect into l_output_data @@ -45,7 +47,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters\s*1..1\s*# \s*ok - a disabled test # SKIP: Disabled for testing purpose\s*# \s*ok - org\s*]'; + l_expected := gc_boilerplate_suitepath_expression || q'[\s*1..1\s*# \s*ok - a disabled test # SKIP: Disabled for testing purpose\s*# \s*ok - org\s*]'; select * bulk collect into l_output_data From 78cc7721c0ccd05d8b048d4bc53cb365652f9ff1 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Fri, 18 Jul 2025 12:16:27 +0200 Subject: [PATCH 486/887] Added skipped test with no reason --- test/ut3_user/reporters/test_tap_reporter.pkb | 14 ++++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 3 +++ 2 files changed, 17 insertions(+) diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 40b66318b..51678c8a2 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -56,5 +56,19 @@ create or replace package body test_tap_reporter as ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); end disabled_test; + + procedure disabled_test_no_description as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := gc_boilerplate_suitepath_expression || q'[\s*1..1\s*# \s*ok - a disabled test with no reason # SKIP\s*# \s*ok - org\s*]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_reporters.disabled_test_no_reason',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); + end disabled_test_no_description; + end test_tap_reporter; / \ No newline at end of file diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index a3c6475ab..7f3c7843a 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -15,5 +15,8 @@ create or replace package test_tap_reporter as --%test(Skipped test) procedure disabled_test; + --%test(Skipped test without description) + procedure disabled_test_no_description; + end test_tap_reporter; / \ No newline at end of file From 1e78987ace0e5a7199f170eddb0f67edf0c6e832 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Fri, 18 Jul 2025 12:32:40 +0200 Subject: [PATCH 487/887] Add explicit spaces for correct indentation --- test/ut3_user/reporters/test_tap_reporter.pkb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 51678c8a2..1c24407cf 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -6,7 +6,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := gc_boilerplate_suitepath_expression || '\s*1..1\s*# \s*# Subtest: A description of some context\s*1..1\s*ok - passing_test\s*# \s*ok - org\s*'; + l_expected := gc_boilerplate_suitepath_expression || '\s{21}1..1\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}ok - passing_test\s{21}# \sok - org\s*'; select * bulk collect into l_output_data @@ -19,7 +19,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := gc_boilerplate_suitepath_expression || q'[\s*1..1\s*# \s*not ok - a test with failing assertion\s*---\s*message: '"Fails as values are different"'\s*severity: fail\s*...\s*# \s*not ok - org\s*]'; + l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}not ok - a test with failing assertion\s{23}---\s{23}message: '"Fails as values are different"'\s{23}severity: fail\s{23}...\s{21}# \snot ok - org\s*]'; select * bulk collect into l_output_data @@ -33,7 +33,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := gc_boilerplate_suitepath_expression || q'[\s*1..1\s*# \s*not ok - a test raising unhandled exception\s*---\s*message: |\s*ORA-06502: .*\s*ORA-06512: .*\s*ORA-06512: .*\s*ORA-06512: at line [[:digit:]]+\s*severity: error\s*...\s*# \s*not ok - org\s*]'; + l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}not ok - a test raising unhandled exception\s{23}---\s{23}message: |\s{25ORA-06502: .*\s{25}ORA-06512: .*\s{25}ORA-06512: .*\s{25}ORA-06512: at line [[:digit:]]+\s{23}severity: error\s{23}...\s{21}# \snot ok - org\s*]'; select * bulk collect into l_output_data @@ -47,7 +47,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := gc_boilerplate_suitepath_expression || q'[\s*1..1\s*# \s*ok - a disabled test # SKIP: Disabled for testing purpose\s*# \s*ok - org\s*]'; + l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}ok - a disabled test # SKIP: Disabled for testing purpose\s{21}# \sok - org\s*]'; select * bulk collect into l_output_data @@ -61,7 +61,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := gc_boilerplate_suitepath_expression || q'[\s*1..1\s*# \s*ok - a disabled test with no reason # SKIP\s*# \s*ok - org\s*]'; + l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}ok - a disabled test with no reason # SKIP\s{21}# \sok - org\s*]'; select * bulk collect into l_output_data From ee226695879800a408ed39b4aba8685ed91fa215 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Fri, 18 Jul 2025 21:50:18 +0200 Subject: [PATCH 488/887] Added test for multiple test outcomes in one go --- test/ut3_user/reporters/test_tap_reporter.pkb | 13 +++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 3 +++ 2 files changed, 16 insertions(+) diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 1c24407cf..9803f5779 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -70,5 +70,18 @@ create or replace package body test_tap_reporter as ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); end disabled_test_no_description; + + procedure multiple_tests_different_outcome as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org.*# Subtest: A suite for testing different outcomes from reporters\s{21}1..5\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}ok - passing_test\s{21}not ok - a test with failing assertion\s{23}---\s{23}message:.*not ok - a test raising unhandled exception\s{23}---\s{23}message: |.*ok - a disabled test # SKIP: Disabled for testing purpose.*ok - a disabled test with no reason # SKIP\s{21}# \snot ok - org\s*]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_reporters',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected, 'n'); + end multiple_tests_different_outcome; end test_tap_reporter; / \ No newline at end of file diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index 7f3c7843a..9183bd558 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -18,5 +18,8 @@ create or replace package test_tap_reporter as --%test(Skipped test without description) procedure disabled_test_no_description; + --%test(Multiple tests with different outcome) + procedure multiple_tests_different_outcome; + end test_tap_reporter; / \ No newline at end of file From 55d5b612d77f97a442038a61f9b773cc8b413929 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Fri, 18 Jul 2025 22:23:35 +0200 Subject: [PATCH 489/887] Added serverout for beforetest procedures --- source/reporters/ut_tap_reporter.tpb | 9 +++++++++ source/reporters/ut_tap_reporter.tps | 3 +++ test/ut3_user/reporters/test_tap_reporter.pkb | 4 ++-- 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 3eb783287..6782bda32 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -15,6 +15,15 @@ create or replace type body ut_tap_reporter is self.print_text('1..' || a_suite.items.count); end before_calling_suite; + + overriding member procedure after_calling_before_test (self in out nocopy ut_tap_reporter, a_executable in ut_executable) as + begin + if a_executable.serveroutput is not null and a_executable.serveroutput != empty_clob() then + self.print_clob('# ' || a_executable.serveroutput); + end if; + end after_calling_before_test; + + overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test) as l_message varchar2(4000); l_test_name varchar2(4000) := coalesce(a_test.description, a_test.name); diff --git a/source/reporters/ut_tap_reporter.tps b/source/reporters/ut_tap_reporter.tps index cec7afebc..17f3784d9 100644 --- a/source/reporters/ut_tap_reporter.tps +++ b/source/reporters/ut_tap_reporter.tps @@ -2,6 +2,9 @@ create or replace type ut_tap_reporter under ut_documentation_reporter( constructor function ut_tap_reporter(self in out nocopy ut_tap_reporter) return self as result, overriding member procedure before_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite), + + overriding member procedure after_calling_before_test (self in out nocopy ut_tap_reporter, a_executable in ut_executable), + overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test), overriding member procedure after_calling_before_all (self in out nocopy ut_tap_reporter, a_executable in ut_executable), overriding member procedure after_calling_after_all (self in out nocopy ut_tap_reporter, a_executable in ut_executable), diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 9803f5779..3c8320d4f 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -6,7 +6,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := gc_boilerplate_suitepath_expression || '\s{21}1..1\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}ok - passing_test\s{21}# \sok - org\s*'; + l_expected := gc_boilerplate_suitepath_expression || '\s{21}1..1\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}# \s{25}ok - passing_test\s{21}# \sok - org\s*'; select * bulk collect into l_output_data @@ -75,7 +75,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org.*# Subtest: A suite for testing different outcomes from reporters\s{21}1..5\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}ok - passing_test\s{21}not ok - a test with failing assertion\s{23}---\s{23}message:.*not ok - a test raising unhandled exception\s{23}---\s{23}message: |.*ok - a disabled test # SKIP: Disabled for testing purpose.*ok - a disabled test with no reason # SKIP\s{21}# \snot ok - org\s*]'; + l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org.*# Subtest: A suite for testing different outcomes from reporters\s{21}1..5\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}# \s{25}ok - passing_test\s{21}not ok - a test with failing assertion\s{23}---\s{23}message:.*not ok - a test raising unhandled exception\s{23}---\s{23}message: |.*ok - a disabled test # SKIP: Disabled for testing purpose.*ok - a disabled test with no reason # SKIP\s{21}# \snot ok - org\s*]'; select * bulk collect into l_output_data From e451e4b7bfc856daae7e17657ffc1cc483ee62b2 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Mon, 21 Jul 2025 13:03:11 +0200 Subject: [PATCH 490/887] Included print of serverout as comment --- source/reporters/ut_tap_reporter.tpb | 15 +++++++-------- source/reporters/ut_tap_reporter.tps | 4 ++-- test/ut3_user/reporters/test_tap_reporter.pkb | 8 ++++---- 3 files changed, 13 insertions(+), 14 deletions(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 6782bda32..a6ae51b3c 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -8,6 +8,11 @@ create or replace type body ut_tap_reporter is return; end ut_tap_reporter; + member procedure print_comment(self in out nocopy ut_tap_reporter, a_comment clob) as + begin + self.print_clob(regexp_replace(a_comment, '^', '# ', 1, 0, 'm')); + end print_comment; + overriding member procedure before_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite) as begin self.print_text('# Subtest: ' || coalesce(a_suite.description, a_suite.name)); @@ -16,14 +21,6 @@ create or replace type body ut_tap_reporter is end before_calling_suite; - overriding member procedure after_calling_before_test (self in out nocopy ut_tap_reporter, a_executable in ut_executable) as - begin - if a_executable.serveroutput is not null and a_executable.serveroutput != empty_clob() then - self.print_clob('# ' || a_executable.serveroutput); - end if; - end after_calling_before_test; - - overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test) as l_message varchar2(4000); l_test_name varchar2(4000) := coalesce(a_test.description, a_test.name); @@ -72,6 +69,8 @@ create or replace type body ut_tap_reporter is self.print_text('...'); self.lvl := self.lvl - 1; end if; + + self.print_comment(a_test.get_serveroutputs); end after_calling_test; diff --git a/source/reporters/ut_tap_reporter.tps b/source/reporters/ut_tap_reporter.tps index 17f3784d9..c706fecd2 100644 --- a/source/reporters/ut_tap_reporter.tps +++ b/source/reporters/ut_tap_reporter.tps @@ -1,11 +1,11 @@ create or replace type ut_tap_reporter under ut_documentation_reporter( constructor function ut_tap_reporter(self in out nocopy ut_tap_reporter) return self as result, + member procedure print_comment(self in out nocopy ut_tap_reporter, a_comment clob), overriding member procedure before_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite), - overriding member procedure after_calling_before_test (self in out nocopy ut_tap_reporter, a_executable in ut_executable), - overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test), + overriding member procedure after_calling_before_all (self in out nocopy ut_tap_reporter, a_executable in ut_executable), overriding member procedure after_calling_after_all (self in out nocopy ut_tap_reporter, a_executable in ut_executable), overriding member procedure before_calling_run(self in out nocopy ut_tap_reporter, a_run in ut_run), diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 3c8320d4f..bda706809 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -6,7 +6,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := gc_boilerplate_suitepath_expression || '\s{21}1..1\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}# \s{25}ok - passing_test\s{21}# \sok - org\s*'; + l_expected := gc_boilerplate_suitepath_expression || '\s{21}1..1\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}ok - passing_test\s{25}# \s{25}# \s{25}# \s{25}# \s{25}# \s{21}# \sok - org\s*'; select * bulk collect into l_output_data @@ -19,7 +19,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}not ok - a test with failing assertion\s{23}---\s{23}message: '"Fails as values are different"'\s{23}severity: fail\s{23}...\s{21}# \snot ok - org\s*]'; + l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}not ok - a test with failing assertion\s{23}---\s{23}message: '"Fails as values are different"'\s{23}severity: fail\s{23}...\s{21}# \s{21}# \s{21}# \s{21}# \snot ok - org\s*]'; select * bulk collect into l_output_data @@ -33,7 +33,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}not ok - a test raising unhandled exception\s{23}---\s{23}message: |\s{25ORA-06502: .*\s{25}ORA-06512: .*\s{25}ORA-06512: .*\s{25}ORA-06512: at line [[:digit:]]+\s{23}severity: error\s{23}...\s{21}# \snot ok - org\s*]'; + l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}not ok - a test raising unhandled exception\s{23}---\s{23}message: |\s{25ORA-06502: .*\s{25}ORA-06512: at line [[:digit:]]+\s{23}severity: error\s{23}...\s{21}# \s{21}# \s{21}# \s{21}# \snot ok - org\s*]'; select * bulk collect into l_output_data @@ -75,7 +75,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org.*# Subtest: A suite for testing different outcomes from reporters\s{21}1..5\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}# \s{25}ok - passing_test\s{21}not ok - a test with failing assertion\s{23}---\s{23}message:.*not ok - a test raising unhandled exception\s{23}---\s{23}message: |.*ok - a disabled test # SKIP: Disabled for testing purpose.*ok - a disabled test with no reason # SKIP\s{21}# \snot ok - org\s*]'; + l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org.*# Subtest: A suite.*\s{21}1..5\s{21}# \s{21}# Subtest: A desc.*\s{25}1..1\s{25}ok - passing_test\s{25}# \s{25}# \s{21}not ok - a test w.*\s{23}---\s{23}message:.*\s{21}# .*\s{21}# not ok - a test rai.*\s{23}---\s{23}message: |.*ok - a disabled test # SKIP: Disabled for testing purpose.*ok - a dis.* # SKIP\s{21}# \snot ok - org\s*]'; select * bulk collect into l_output_data From fb9ef0badc83c3d90eb37d393add96d693b8f729 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Mon, 21 Jul 2025 14:10:50 +0200 Subject: [PATCH 491/887] Added suite name escaping --- source/reporters/ut_tap_reporter.tpb | 11 ++- source/reporters/ut_tap_reporter.tps | 1 + test/ut3_user/reporters/test_tap_reporter.pkb | 71 +++++++++++++++++-- test/ut3_user/reporters/test_tap_reporter.pks | 10 +++ 4 files changed, 84 insertions(+), 9 deletions(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index a6ae51b3c..8ad880cee 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -13,9 +13,14 @@ create or replace type body ut_tap_reporter is self.print_clob(regexp_replace(a_comment, '^', '# ', 1, 0, 'm')); end print_comment; + member function escape_special_chars(self in out nocopy ut_tap_reporter, a_string_to_escape clob) return clob as + begin + return regexp_replace(a_string_to_escape, '([\\#])', '\\\1'); + end escape_special_chars; + overriding member procedure before_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite) as begin - self.print_text('# Subtest: ' || coalesce(a_suite.description, a_suite.name)); + self.print_text('# Subtest: ' || self.escape_special_chars(coalesce(a_suite.description, a_suite.name))); lvl := lvl + 2; self.print_text('1..' || a_suite.items.count); end before_calling_suite; @@ -94,9 +99,9 @@ create or replace type body ut_tap_reporter is lvl := lvl - 2; if lvl = 0 then if a_suite.result = ut_utils.gc_success or a_suite.result = ut_utils.gc_disabled then - self.print_text('ok - ' || l_suite_name); + self.print_text('ok - ' || self.escape_special_chars(l_suite_name)); elsif a_suite.result > ut_utils.gc_success then - self.print_text(ut_ansiconsole_helper.red('not ok') || ' - ' || l_suite_name); + self.print_text(ut_ansiconsole_helper.red('not ok') || ' - ' || self.escape_special_chars(l_suite_name)); end if; self.print_text(' '); diff --git a/source/reporters/ut_tap_reporter.tps b/source/reporters/ut_tap_reporter.tps index c706fecd2..e38d809f9 100644 --- a/source/reporters/ut_tap_reporter.tps +++ b/source/reporters/ut_tap_reporter.tps @@ -2,6 +2,7 @@ create or replace type ut_tap_reporter under ut_documentation_reporter( constructor function ut_tap_reporter(self in out nocopy ut_tap_reporter) return self as result, member procedure print_comment(self in out nocopy ut_tap_reporter, a_comment clob), + member function escape_special_chars(self in out nocopy ut_tap_reporter, a_string_to_escape clob) return clob, overriding member procedure before_calling_suite(self in out nocopy ut_tap_reporter, a_suite ut_logical_suite), overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test), diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index bda706809..9c45a431b 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -2,6 +2,44 @@ create or replace package body test_tap_reporter as gc_boilerplate_suitepath_expression constant varchar2(300) := 'TAP version 14\s*1..1\s*# Subtest: org\s{5}1..1\s{5}# Subtest: utplsql\s{9}1..1\s{9}# Subtest: tests\s{13}1..1\s{13}# Subtest: helpers\s{17}1..1\s{17}# Subtest: A suite for testing different outcomes from reporters'; + + procedure compile_tests as + pragma autonomous_transaction; + begin + + execute immediate q'[ + create or replace package test_tap_escaping as + --%suite(Some \ and # to be escaped) + + --%test(Even more \\ and multiple ###) + procedure more_escaping; + + --%test(Disabled test) + --%disabled(With \ and # in skip reason) + procedure not_skipping_escapes; + end test_tap_escaping; + ]'; + + execute immediate q'[ + create or replace package body test_tap_escaping as + + procedure more_escaping as + begin + ut.expect(1).to_equal(1); + end more_escaping; + + + procedure not_skipping_escapes as + begin + ut.expect(10).to_equal(1); + end not_skipping_escapes; + + end test_tap_escaping; + ]'; + + end compile_tests; + + procedure simple_succeeding_test as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); @@ -9,7 +47,7 @@ create or replace package body test_tap_reporter as l_expected := gc_boilerplate_suitepath_expression || '\s{21}1..1\s{21}# \s{21}# Subtest: A description of some context\s{25}1..1\s{25}ok - passing_test\s{25}# \s{25}# \s{25}# \s{25}# \s{25}# \s{21}# \sok - org\s*'; select * - bulk collect into l_output_data + bulk collect into l_output_data from table(ut3_develop.ut.run('test_reporters.passing_test',ut3_develop.ut_tap_reporter())); ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); @@ -22,7 +60,7 @@ create or replace package body test_tap_reporter as l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}not ok - a test with failing assertion\s{23}---\s{23}message: '"Fails as values are different"'\s{23}severity: fail\s{23}...\s{21}# \s{21}# \s{21}# \s{21}# \snot ok - org\s*]'; select * - bulk collect into l_output_data + bulk collect into l_output_data from table(ut3_develop.ut.run('test_reporters.failing_test',ut3_develop.ut_tap_reporter())); ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); @@ -36,7 +74,7 @@ create or replace package body test_tap_reporter as l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}not ok - a test raising unhandled exception\s{23}---\s{23}message: |\s{25ORA-06502: .*\s{25}ORA-06512: at line [[:digit:]]+\s{23}severity: error\s{23}...\s{21}# \s{21}# \s{21}# \s{21}# \snot ok - org\s*]'; select * - bulk collect into l_output_data + bulk collect into l_output_data from table(ut3_develop.ut.run('test_reporters.erroring_test',ut3_develop.ut_tap_reporter())); ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); @@ -50,7 +88,7 @@ create or replace package body test_tap_reporter as l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}ok - a disabled test # SKIP: Disabled for testing purpose\s{21}# \sok - org\s*]'; select * - bulk collect into l_output_data + bulk collect into l_output_data from table(ut3_develop.ut.run('test_reporters.disabled_test',ut3_develop.ut_tap_reporter())); ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); @@ -64,7 +102,7 @@ create or replace package body test_tap_reporter as l_expected := gc_boilerplate_suitepath_expression || q'[\s{21}1..1\s{21}# \s{21}ok - a disabled test with no reason # SKIP\s{21}# \sok - org\s*]'; select * - bulk collect into l_output_data + bulk collect into l_output_data from table(ut3_develop.ut.run('test_reporters.disabled_test_no_reason',ut3_develop.ut_tap_reporter())); ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected); @@ -78,10 +116,31 @@ create or replace package body test_tap_reporter as l_expected := q'[TAP version 14\s*1..1\s*# Subtest: org.*# Subtest: A suite.*\s{21}1..5\s{21}# \s{21}# Subtest: A desc.*\s{25}1..1\s{25}ok - passing_test\s{25}# \s{25}# \s{21}not ok - a test w.*\s{23}---\s{23}message:.*\s{21}# .*\s{21}# not ok - a test rai.*\s{23}---\s{23}message: |.*ok - a disabled test # SKIP: Disabled for testing purpose.*ok - a dis.* # SKIP\s{21}# \snot ok - org\s*]'; select * - bulk collect into l_output_data + bulk collect into l_output_data from table(ut3_develop.ut.run('test_reporters',ut3_develop.ut_tap_reporter())); ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected, 'n'); end multiple_tests_different_outcome; + + + procedure escape_suite_name as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[%# Subtest: Some \\ and \# to be escaped%ok - Some \\ and \# to be escaped%]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_tap_escaping.more_escaping',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); + end escape_suite_name; + + + procedure drop_help_tests as + pragma autonomous_transaction; + begin + execute immediate 'drop package test_tap_escaping'; + end drop_help_tests; end test_tap_reporter; / \ No newline at end of file diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index 9183bd558..44247dbfa 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -3,6 +3,9 @@ create or replace package test_tap_reporter as --%suite(ut_tap_reporter) --%suitepath(utplsql.test_user.reporters) + --%beforeall + procedure compile_tests; + --%test(Simple succeeding test) procedure simple_succeeding_test; @@ -21,5 +24,12 @@ create or replace package test_tap_reporter as --%test(Multiple tests with different outcome) procedure multiple_tests_different_outcome; + --%test(Escape special characters in suite name) + procedure escape_suite_name; + + + --%afterall + procedure drop_help_tests; + end test_tap_reporter; / \ No newline at end of file From f18981d278e92d9f69ddfa8c243b840a4f2687f7 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Sat, 26 Jul 2025 21:28:49 +0200 Subject: [PATCH 492/887] Included escaped test name --- source/reporters/ut_tap_reporter.tpb | 2 +- test/ut3_user/reporters/test_tap_reporter.pkb | 14 ++++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 3 +++ 3 files changed, 18 insertions(+), 1 deletion(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 8ad880cee..d348f61e1 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -28,7 +28,7 @@ create or replace type body ut_tap_reporter is overriding member procedure after_calling_test(self in out nocopy ut_tap_reporter, a_test ut_test) as l_message varchar2(4000); - l_test_name varchar2(4000) := coalesce(a_test.description, a_test.name); + l_test_name varchar2(4000) := self.escape_special_chars(coalesce(a_test.description, a_test.name)); procedure print_failed_expectation(a_test ut_test) is l_lines ut_varchar2_list; diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 9c45a431b..5135cffde 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -137,6 +137,20 @@ create or replace package body test_tap_reporter as end escape_suite_name; + procedure escape_multiple_characters_test_name as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[%ok - Even more \\\\ and multiple \#\#\#%]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_tap_escaping.more_escaping',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); + end escape_multiple_characters_test_name; + + procedure drop_help_tests as pragma autonomous_transaction; begin diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index 44247dbfa..e77ab8515 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -27,6 +27,9 @@ create or replace package test_tap_reporter as --%test(Escape special characters in suite name) procedure escape_suite_name; + --%test(Escape multiple special characters in test name) + procedure escape_multiple_characters_test_name; + --%afterall procedure drop_help_tests; From f1c0f860f84efe389dc6b3db79a950ff4c266259 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Sat, 26 Jul 2025 21:49:52 +0200 Subject: [PATCH 493/887] Included escaped skip reason --- source/reporters/ut_tap_reporter.tpb | 2 +- test/ut3_user/reporters/test_tap_reporter.pkb | 14 ++++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 3 +++ 3 files changed, 18 insertions(+), 1 deletion(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index d348f61e1..4472c2f2f 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -57,7 +57,7 @@ create or replace type body ut_tap_reporter is if a_test.result = ut_utils.gc_disabled then self.print_text('ok - ' || l_test_name || ' # SKIP'|| case when a_test.disabled_reason is not null - then ': '||a_test.disabled_reason + then ': '|| self.escape_special_chars(a_test.disabled_reason) else null end ); elsif a_test.result = ut_utils.gc_success then diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 5135cffde..a4c3a1b6a 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -151,6 +151,20 @@ create or replace package body test_tap_reporter as end escape_multiple_characters_test_name; + procedure special_characters_in_deisabled_reason as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[%ok - Disabled test # SKIP: With \\ and \# in skip reason%]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_tap_escaping.not_skipping_escapes',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); + end special_characters_in_deisabled_reason; + + procedure drop_help_tests as pragma autonomous_transaction; begin diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index e77ab8515..7385b91bb 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -30,6 +30,9 @@ create or replace package test_tap_reporter as --%test(Escape multiple special characters in test name) procedure escape_multiple_characters_test_name; + --%test(Disabled Test with special characters in disable reason) + procedure special_characters_in_deisabled_reason; + --%afterall procedure drop_help_tests; From 33865dd88a80729a6db01b9c511e79e1f9d3a542 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Sun, 27 Jul 2025 13:47:27 +0200 Subject: [PATCH 494/887] Added escaped comment test --- source/reporters/ut_tap_reporter.tpb | 2 +- test/ut3_user/reporters/test_tap_reporter.pkb | 22 +++++++++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 3 +++ 3 files changed, 26 insertions(+), 1 deletion(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 4472c2f2f..3738a0f7a 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -10,7 +10,7 @@ create or replace type body ut_tap_reporter is member procedure print_comment(self in out nocopy ut_tap_reporter, a_comment clob) as begin - self.print_clob(regexp_replace(a_comment, '^', '# ', 1, 0, 'm')); + self.print_clob(regexp_replace(self.escape_special_chars(a_comment), '^', '# ', 1, 0, 'm')); end print_comment; member function escape_special_chars(self in out nocopy ut_tap_reporter, a_string_to_escape clob) return clob as diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index a4c3a1b6a..a037e50e5 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -17,6 +17,9 @@ create or replace package body test_tap_reporter as --%test(Disabled test) --%disabled(With \ and # in skip reason) procedure not_skipping_escapes; + + --%test(Escaped Comments) + procedure escaped_comments; end test_tap_escaping; ]'; @@ -34,6 +37,11 @@ create or replace package body test_tap_reporter as ut.expect(10).to_equal(1); end not_skipping_escapes; + procedure escaped_comments as + begin + dbms_output.put_line('This \ and # should be escaped, but this not!!!'); + ut.expect(1).to_equal(1); + end escaped_comments; end test_tap_escaping; ]'; @@ -165,6 +173,20 @@ create or replace package body test_tap_reporter as end special_characters_in_deisabled_reason; + procedure special_characters_in_comment as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[%ok - Escaped Comments%# This \\ and \# should be escaped, but this not!!!%]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_tap_escaping.escaped_comments',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); + end special_characters_in_comment; + + procedure drop_help_tests as pragma autonomous_transaction; begin diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index 7385b91bb..b5ac6c31e 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -33,6 +33,9 @@ create or replace package test_tap_reporter as --%test(Disabled Test with special characters in disable reason) procedure special_characters_in_deisabled_reason; + --%test(Escape special characters in comment) + procedure special_characters_in_comment; + --%afterall procedure drop_help_tests; From a477d688bc278ebc60c2aa400370af75f58a4520 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Sun, 27 Jul 2025 14:05:57 +0200 Subject: [PATCH 495/887] Central use of comment procedure --- source/reporters/ut_tap_reporter.tpb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 3738a0f7a..a2540ef97 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -82,14 +82,14 @@ create or replace type body ut_tap_reporter is overriding member procedure after_calling_before_all(self in out nocopy ut_tap_reporter, a_executable in ut_executable) is begin if a_executable.serveroutput is not null and a_executable.serveroutput != empty_clob() then - self.print_clob('# ' || a_executable.serveroutput); + self.print_comment(a_executable.serveroutput); end if; end after_calling_before_all; overriding member procedure after_calling_after_all(self in out nocopy ut_tap_reporter, a_executable in ut_executable) is begin if a_executable.serveroutput is not null and a_executable.serveroutput != empty_clob() then - self.print_clob('# ' || a_executable.serveroutput); + self.print_comment(a_executable.serveroutput); end if; end after_calling_after_all; From 2e399fdc33d6b1ce8dfdbb3f3b27281c2a0350ab Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Tue, 29 Jul 2025 13:53:32 +0200 Subject: [PATCH 496/887] Comments shouldn't escape special characters --- source/reporters/ut_tap_reporter.tpb | 2 +- test/ut3_user/reporters/test_tap_reporter.pkb | 4 ++-- test/ut3_user/reporters/test_tap_reporter.pks | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index a2540ef97..5a75fcac8 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -10,7 +10,7 @@ create or replace type body ut_tap_reporter is member procedure print_comment(self in out nocopy ut_tap_reporter, a_comment clob) as begin - self.print_clob(regexp_replace(self.escape_special_chars(a_comment), '^', '# ', 1, 0, 'm')); + self.print_clob(regexp_replace(a_comment, '^', '# ', 1, 0, 'm')); end print_comment; member function escape_special_chars(self in out nocopy ut_tap_reporter, a_string_to_escape clob) return clob as diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index a037e50e5..87ec1dd9d 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -39,7 +39,7 @@ create or replace package body test_tap_reporter as procedure escaped_comments as begin - dbms_output.put_line('This \ and # should be escaped, but this not!!!'); + dbms_output.put_line('This \ and # should not be escaped, and this not as well!!!'); ut.expect(1).to_equal(1); end escaped_comments; end test_tap_escaping; @@ -177,7 +177,7 @@ create or replace package body test_tap_reporter as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin - l_expected := q'[%ok - Escaped Comments%# This \\ and \# should be escaped, but this not!!!%]'; + l_expected := q'[%ok - Escaped Comments%# This \ and # should not be escaped, and this not as well!!!%]'; select * bulk collect into l_output_data diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index b5ac6c31e..aef27fa0a 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -33,7 +33,7 @@ create or replace package test_tap_reporter as --%test(Disabled Test with special characters in disable reason) procedure special_characters_in_deisabled_reason; - --%test(Escape special characters in comment) + --%test(Don't escape special characters in comment) procedure special_characters_in_comment; From 3193f5bdd221250433c434a1110fb0efc733eee1 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Sat, 2 Aug 2025 12:41:09 +0200 Subject: [PATCH 497/887] Added TAP reporter to documentation --- docs/images/tap_reporter_colored.png | Bin 0 -> 36097 bytes docs/images/tap_reporter_no_color.png | Bin 0 -> 44916 bytes docs/userguide/reporters.md | 10 ++++++++++ 3 files changed, 10 insertions(+) create mode 100644 docs/images/tap_reporter_colored.png create mode 100644 docs/images/tap_reporter_no_color.png diff --git a/docs/images/tap_reporter_colored.png b/docs/images/tap_reporter_colored.png new file mode 100644 index 0000000000000000000000000000000000000000..d4a5e932670135bb14350020592eeb9d821131c5 GIT binary patch literal 36097 zcmce;c|6zOzAygK92JszDiwtcl_5kK3n>yZ50xoVA<0Kd8M5f817`2*7`{Ix6Wo9<@K^c){%4Ns8qed%Kf6 z&Rd*2dGgG8D|^S0r6scXNBra;DV#fL=4fqyW}~*X-AT$(vyCD$`VA&=F?oBh8GB1vw zy2dV%p3|_AhbN9HPB>B1!9iqhetzs{UrfB`;=-zR>#F8{jyF+%9vBEZ+fx;L>Bq2D zXYt;kpdg2V#_e19_-yZ9y5i>McI4PG-z>{I@tPTf&Eev+Z{NLJUsY8lvTIk$(?e=g z-KE}3=~-C=J3SXU&-cEzo^rvX7aY*;ZppMzF)Z=mq;!4y#N(E+?vA?ON?NXsd-kw~ za_zl*^(u|vjvY;PdJnp~Og|J}%u)&p4-ZPHl@$~aC?D-EXFuJrzWvMaa7bRBq~xAG z-BUyDwM_m20Rf6k9zsGwFJ8Q$L^FD~wzk?VU%hITmm<&eiLVX#6l-gDy7zu=PDheYb<7DpftW#?@P%kfDn6Wj}kCAn!M9EUbKl=V;gdRJ~03>C_?F)9TjN+jY|Pms3PU zMCgh*u$huGI?C$W+Smr0)0R>q?%p+DnERQOp6-{Nyd5vc|KZ`7PgiJV=@=Dbk93Xo zR8LR$gl@X=^6t%1cKbr_!a^BAlVXnE-d+|t4;k|BS$CbfpPjuyKsS9EMLkBA6AK_8 zcI=tyx%20*sPmQ=yU$*~dzbqB`SU*h{ubS3z5&6(jBT}%613H!+$!hJ?VOmH*mz6z z?BarZ*YW2(ygF--9zFX0{rl4Tdd>KuW*zRt2iOnKuUtQ{B|^&S(JME*ADi$YiX;bi z%&DrXVsD=~kf3#qQ<^EpeTucfc_@fhZjKI{Q%B%{rY1ep4t*c2gZb>#(1F8;tE+<9 z#WV`0Y8Pp_Wfk4rWFBa3$8(_b)XE zR8{3OjEk<{y0u(FLV|^jjc4y(BbK&w*5UL`ygI@7RY!`gP+!n4@Lg*<75t&Ci@kPjYg(c=7p*7ptzUSgUoX@7uR)si}gW`}#KX@vY1{ zRV$BIxsF5fzD~4LeRh9JY?^H23Q_k1IC;Y1t~4cBrP8`O+L@UdEVc5!eUypG#fZrSIAU5Pvea%1xeVpBJhp8Sa&d7fZE4YUNxLe=t8p(t z)_tb5xtXcCxw*gLA#K$))+?PJvuhU@ew27yW=OB5rY^g(lJCVM@6B)N@y8Zk2DcQy)W#?(D*B?XPM6i$`N9PiY_L}~HL>{KGan1O z+j49vUY9Q~S;Hx{!NbENDJjVdpV`gbot~XtV9gio2A(ZjmYq6v3a4vyY;6CLBXl7g zdoG)J&L4A3Wz$ODVB4JP9TrCK@$<`Vok0c4` zT`1s^4qX)S)9*KCA3S)_J1uR8@--GJ1qFo@Cr@sYmE}s&&Ct=;RaK=n;(S#%&c96{Qsw%buS3 zsO5SfE-#NIO3Fzd+y3?I*GIIpmgF0T47EQ^VN9tiy7c3Sv2n^#yzV*0Ns@4{tUn9V#IEP)QEM5&vh; zr1A7!pFjJwKed0V_W><~g_Si&PX@a&uJ>(X`t+?^w>C*gFq4h);)PXML~d^Gs5hELH+mfDh;P;PuhaZ)*o0gWg zaH`Grecsv4DBb$foaEQ=nsv8$h04yXI+xF(q@Bp# z)CUCgrkgBYM~F@jKO6C>;~3bA@6Sy?wD&{3mW+&ysl9z@L<9@gZ(Hq+nlIODzD&;y zW*F>{!>{2vRM_YngAM4hIDa9h-LSxM_1Uv$RU78!=0qI(kGw`xIeGGA?O(#bK9fzB zLJ<=a)8ogFlP(l%^DD{AFOi)aRS0hT{Q2`X_m71ak4C)l-%FNnhs}B2x!lvOO9B;n z+`?V&@&5@A!ILb3$j^ z>i(eLXoF5t1FqNAg@wt`tSKBIfdlYJLTjHcq}X|u*kYe8X6ip{1`TxL(e~;p>f9H&X0~uwDtA%0imJQ`RDue z1$6}k1O$x>S)84n0Vwvhq#Mz*0mQ$ksVV>b@`i6NYKBGCHSdQH`5rxb1gsKRQK5($ zyxOj?s0iTB-Uu)D%-w)BBZNo5&+KCQ_Gp z%+HujeQSMRbV=f`zy9j#?+?JT0Qs4HeV5=Q)YH>*1)Iuja-eC4{zUh2s+@CQR4Jvv zd|^>h!Fw-FfeP^R`#7IDbLRTX6YrnebE8F=ojDUSI_e;3m`9hHnJNG5;&^ZO^jHr* zt6y|97tp|PXGw;RAl~jfBfCeV?0e2_3E|osgbzXSl8-G#Sr)l4YJaLL z==omtZ|^g4N;#}<-4iyJ+cIea8pt)}X#GUzVdDu3_7K;AAvT1%B-Hn3&Le_c&hP6{C6i@@1ON3sS4vn@&-e z++E3J(>bma9~ZX-hoY=l46Tj4wkpE;eXfAkP}UdMJ>A5rrxbh9l@GQXe+lGdt{ND#|{Bt+I^Xk|U zvcn6qlUwqEapLVei*d~7=j)5zFWr;#G`60JQ@VOYPcL9{uw^sg+VJqOO*MKm+Xiai zcefL<&CTrWjQV7J<-JkmQgVuoo;i1as=NwRb3}j%&-_(r@A>oNbq3O_Gg0>lY9}2D zaJT>CGYQ$5{>^wH$}X3iK7QoH(KvAMAQk0vZ*Sa%kq#CS(|sxHt`^{+0a1VX^5tzy ziwgRT!%&+TW#9h&RDSC?spaJ4v;mlavWtt03F19BH94tt;J_;MpN(M$y0CZe-`~iw z=iIWAg_)Foy#d$3w5KS2b(>D&W8dCKxZyyvhCKP@ETZPi$hibU#y2Rsykf3f(6u)- zy!Woi1r2w4ASL7Rg%RV^?;pqB+PPA8e&XoFw^jzM>NX)EWp(vyB6au>WX*mIe>5{U zzijaIOm|<5r?QsT`q6KXtAqrM&p^y;+&+Rcyg>KklW%T^{^U)tas_}tC zuoE^*O0tai)#=)Drl+Ul2XYi#7zqImiBC#e^-v>x@7VE@^b#cg|81|9-nUAN!fSe#1;ZuC;-+~^Rqv~Zrr#M%r3zr zCub5rlo1-Cw|e#JX#jgF3M!6%@Z!$Q>}(%E7wiOmX-1wnW;U7hrlhU^f(s zN+_2v*zS_0OU3x-uzS&NsAL3|WMySF>C0~1NI~5JTdu~7QryA7%_K}AI+dG2$7e!fKFRtubCY{|OLPHub_ zf9MCp9Yt5UJ?Au8hEwV;jTHI!_ghs|SND9#Kffb9<<>1m5RNs{($Xv}EcbzHfPt1% zK7aXQ_Wkoqd4pu_AW@5|(uM{G?5Y>9Un`oM$2sJzr2Ol~wN?4hS?$@ZhYuer&%cGV z5o?M@uz6~vGo$&tpPwJaD=3Isb7*mKo#C^u` zgrz0Ta`_>is@mGMJMXLkl~zFce_dNk&&3tuOT*0nu|>?jLxw}ng9A+mHT{Y>OJ1wtFj8yh#^P?uvDj6Gk;9iV?3{S_N@Y^<7F zf%k^k`>7^flV7Ab!*gEEwxrSS^l4Kos{mB5?S~}9#C(H;*8*4OtbZ7*x0e3dBGz={ z)~(Ag41e&(R|uy9icI*F5$moVrDwjIY4D;GXU+EQ+a+B_H{wMlYDDReJOPcHM&$q- zx(c>w`s(KP2suw#pzTDRH;RgOMv?q;${`$q@hYJ_qN4OJI&?BFqm=V~Zz^-`+K(JL za=)>osflry<(rBSPH6|gGo6<|%Y11{vu3mY9VLN3jaBv-UpOz&Z`YSETV*Jlln)+U z&3ia{4fbTFMfInwI#~rEt+8%@ZgT)4n@VAR{xUQ`5nzwgoyDAAzkUTAk5`qpu&{9Z z{*o{6Y|jcjQKHVZHZVXwH{n~VqGvux-V6_aw5G^7|J?E$yobt~QgkEt>L^rvlcS7I zwwMU)u*Alpm7U(VZLZ>*g}H^8vU+M8n^d^1-v~FPjFIo?eT-9g&?B~N+0u1YxY!FI z@7%d_ieJ5Tt*xxbj~@qrRngE`cdGWTFTgpIz=^HvS3`uLLi<+mUzeP78hQ#! zN$inrN3^wlyu2vgmz++XI%QrFK+gi6vVxZD+S5)Cc2vviI=Mx`Y}VaYbc7=idW?PF zkT;!`nW^a-`~n|((2Xtcl=0Cdh7?)zDQ?Otux;p--Jd@%1D5I^9PEKqC~qJ-8}VK* zSkuz8xhm7`%PYo&I%Z*GMJFdQ)H1;KFb(TnzA>n!qu;(3^$~3ZJa^jg`0>E)M-%t) zgq5OJ_C#Q3DDK(;o{M`3^^G-?@GJHlG_eDj$lpqKb+|W0K~9 zLx+@HT??AWlZWg*XW1X6q=*7+=7dLzTC4!YA%eibfX%XH%l4TpE;>tidU`%cNHA;9 zwX^BVvToo#4FP9tY%Bu*x~#n1_abWc^hCqqF*GXk4|!+Vm_4w9m2wMXwA#mx#X?|= zm(SU15!mYKw}$mHkoD<~LRKtcId*&3&`{d9ugE$5MEA%R zSMOM#iA@e104@nG@l<38FwZI1&Wih}r3qtv=KOJk>T^aJ3!;#0(MKW+*W&0OjGU?C z{Q2`|fBVyncf0Ybv+X;%`s!kI?-pCt^K4*ZGRM9OxOUCw*|TSDW9dfER`|-tP9!8_ z-SrF%TJ{`{J#rt4x=orr4sM>y7!MA2W6;)S%NTb*)Wj|v>4u~OAXDXNfu`2hK>8Y8 zM5uc5qzp&?uHi&?Yx!oEsUtPxP&tXH_V(=&NlD4wdvp};MMXtA&6}fDK$ITqdcHKl z8ZdFK(9ssz#FxeV$_let;vrx9S_TIPX((mf_&5b|wT5F$y>=MnnsyXk%sbz=P9sWc zIUgS%c3uzoPab6Is2X&Kl^G=qQcx2{U-HFdySx#@`4(~L+P8*Fh6PK2${H-P;pfoP zPV<+4ZPm*?&FVbT5&Zr8xxBo*jgpdjFIrn#n2n8%U%YvveEc{oj!IW|xA#c#tVWui zxq77dTKCy0C4GH1sSCr`z;S5C(~XPt?M>t|AeEK9E%f*IuR7eSaZi%o#W_X?B@iE! zv={)k9$+*lp)9D~%T}(mDDzpZmu(d$^0A}Cc-smncejj%(u7bf83lAqt3x=kudXN$ z(v?4dPDQv*(-~+MH*elt)h={u@#UL0RRC94po)=VZeKLX^x?yYo1X$&t1BwjD@4ub zE4x=effNNV0%#eMz!Gp)l+I7UmGY5~9`O@IF*{PC;=hhl1Xa~A&w&c~d41F_s9yIE zF?!&5SI8~?JWPb$O`A65c`nMLxona7Vi0pnK=)HhMzOr3qhr>>RlA?}MlAFN)rN3k zlXWt)dq!Y6G%jSBm9J38Y8`#3QAs*?!(lnI${)?`v%`(;x~Z*`?jnF8~e*SBqXFMEovFGD4>}{Gql0a8%zG6HiVkX4`O9pI=!C2|Kk(CNLnt*jdVGdilzg#8HwuKArP9S3*oj zTYCd4_4VlJ5U`JUV9e>RE3~5%UynX`@W5)X3E_6PG?+a=+wx$>**>i2*FV=D$z}`a zMLPKC&;I&&2S-Prj11vlOiC;}x$H3Sjc%wKaFmpx&jP!^vB<=MHGJlL$f|E-Boxwk zd1d8tQr$!47PhUS(La9NZ0u9z@zmz0;ovU(O6sg=%3&*+oUgV zW2^Ijfq{8my?W&%-qFzkdgm1x$sR3p@iKbd>DDL9@7%egKhoFt6+II#=8*nM7?
    taID(0kCn^@n4t z0$ZJNQr*TXnTgm#3fyngNx{T~8`P_;z4)b zOd%AkYU|dm{U7poLF>BJc2Dx`5|A0}DSuVb<_!ZCPv9KD-@&mXUU1r%w;a%ROi!Hf z*?(n4^6T@?&dNGEOy9@H35P`+-n3^=ek)BY?9tbEcCAE*?{7|HKUEhU3>7DNLJkL~ zDWjIr14Y6~1AUJ3+t84=ex<1$P7PGoxB6TI6_22W-Q0c@ng?|HgtPcLmOL9b?z7gf zrF$aI`X5E6Hs1?|h8z&|={PxqHRF{xiHR`+*y`6k^plUJL>nD1y!1l|9kQB83kTNP zrH`hhr!R(AK>Md8WtHwir3B~53HO)Eymsvxkx*Ur$(CuJp z+nM(Ur@#t{j*d>69fbh~N!`z^+|Nw4?TEnNvH<8Y@Uv~h%u^pfrdzRMMSo*512qjz zqkx!HU1DRF^Mb zKBB4Vjr~j0aN5pJ)avcVZy%pACnO|*h3VN@nvuww+FB(ja-ycCUZ*&j?9>(7jgK7hidFD0 zgI`EiGB?)`<;dK^!uOs#oTK&Ym!JV1*s^|ldV1rwZL3s5IGzJF@JofWz~Zi2oU2=e zQMiKWD>5!3uzNu3<+`x&`opZG{^>@t57@nip*>dTxxlbl`Px3nVvt=!f%I1&?r4TI zAw`THLBTb@HLNOvhqmh2!Dp?|HF5U^sfX6JKYr-+Bfs3e!osw>PQ5OL^GL_QuoU9s zhXN-Wxy8Ax$8KlOib^>R5V{a?=T7W{2g_hipe*YOgtL%`M%fr^Hn5KcDA@)+g)*Lb zzE5MvBsxOa8LOkedkar(k>ihF84S&j|0LJ{n^}ziJKsIutZ_f*^}Rg|5JFTN@OJMe zpnuZWU%ej{A8+Ag%U924Xk@f0?7+>$?Hhtl{kAQ5-nRbM<61_!{ zbO0(|AfamGAXJ&A&oArLCa00!4su#N_q_&gknwu-6}`u%ROkQ>kQJIW`h2U$^%{y^ z_lX*h#q+}daT%|b7>w$KCHvybxog~V#RtzKe*&7^^uTF1@1{*uuzyQ^Rx`kyZ%WOy zS;HYo2NV0UI&Z_P8JGs6Z=^@8P8!*HCnRhwo*kB+0Eo*u8p|Z5(KHtKrD47PjLZ}S z01JpE2h`NcXC?iNBiqH(p;?Nj=I#cj%BrGL(A$dekea0n1&?crR_Fi<^iWN468qw8k zvZ22oMCw9l3do?uq{*?zU9ZS)nq9E6^`&Df2Z;bumP03#; zce27iT?1y&%D1lGqGJclq;Bs7YI;Ep6^}LoNkno z%`KjrA!Lxd1|5pxMVKM@1TB&StJvAue|zJ`*6aXBS0y^#7=ZPUrgZkczHG)O4$H#}l^MhNo`WcJ)Odpy`DJY)r$qx4)MsCyH{zM%Ji;1Cy>kSq_9udMU zd5lX_g3YPNuRsH=&$QV+Dapt#uzU9gm|uR-P{Ce(h$z!^Vc>Jm|AIaPK7T%u^C|FS zI)EQDv3-F192Vv-rh;nV(=)!&v>TIIL4iliA7dM0>w(VK z?A^N;iJ%W9o+jI)BgE0V;odxlA7^S|aRmzRMqXZJ$q1}6k<)l~>{x60=H7k~xY1V2 znC)o_r{7RaZEUFVq9vuI#Pj8D3!8)>$X4{`A_5fPCBNVi#B4Y`P40oQv$ULy37)q}?}&Mo*JB+l zqVrj9KhKfZ4pa?Bgkae|uo!4B*c!sA0(e4v{Jm)Z_4t&;G6Ws3&bDq)tiBu`a#S>P z;rs0pQ|L>ORwM}M28Vzxo807SKK`{OgPXub1c)|o-@Y0YFCZxBGTufl$>KEW;`*jhc$7SpK%Hf|8g;PY+O&FTIRuh;u8l3OI8M!CQ91YhD>N%)i$3@f-a$HAGKl5M1 z3YFk8T$Cjg*!NygHY}hd=i#+R4dx;8Lb?Cs$$ALW^s=^bf7=2dK7Ks=<<%|MK3!d1 zfxWT0KpwAS+@UDzWezk=FE&jfd!0nswd?$J93_ zOwar~>u;z0(T2f)P#~SYenq2-)4Enx+hC&e8yJ|82d|SIO^PEg?cQ+OCV}b^` z>hWJLa@o$wG`}4&6m`rUP01HD)YROh{f4AML4qiyH8nI~A1u4AuD^Qn=FOWIuU^S} zc*qiQ%C=b$u~b3<`RyvRsl4E-5)6R+gUHUEm$69i=9lB_SN-Vp%*cM-nq_&5T26FN zOY{2WYN(&SW_R)Ox&TlR#0q^&i+YPru3S{2o}Gr3YPqU4LFMJ^t8`_4dhTW1scrH+ zVM$J9r@y_Y+PGn_7%A@*hqGt*Bc0baJAk7;xYyaHagDoU|J(gTzcQATQS@h4>^Ru| zx38<2nZ>@%&74>HhJ%+mKMt3RINN#!j@#AM)o=PG+sG`cO`s3KO7w%BMb!1*?>!t+ zGof_7CoL^)wKs|-qG0o9LMroyVgYwh!Lgg~)H9N|g3-Obw&vBVcUI4g8^B8X`&q;eAF?ODE*wNLHLnlPRhi|5rnbjG## z!U&145WYj)Dx~^6XBuLVC=gyV`6z2KU=QDJ#i)fqWHgaptS|BO1QJmB!taacf3rS!DP2Y3(OG2$DeIZ$~)0Ly_7DWtN;qI5YpIoUb7V=>FFe;5b;1yFmq zI}PwuHKuYRtKjZ4+9pjct#=P}bp!B{&|lLh@(;(zQoNvD>?`j{5ryLB^8NGbGavF| zr=Cch`QQ~A8Y=Sn7Lr18^Is2x=`;AbinV%H++!Hv$@N4&$`o`Ob)g56PT5lSoW0!b z(6*0^TgImKXsf3JdQvM4iA67_hWLGd3HPeA*!@=G&)L~{>>o+bg~EOo^V~r|XP3z) z-CK!G9!ab0re&r8F;>%Z*qobdsv3{z?Gw#J6s`v!(HFQ1*=|43C4_v<08UA&!$+Ki zM*;))V}H0#4)_vC#l^){rm-pakh8OR$HhKQlEfp4B9i(*PJH{9EC?Nd^(3>^-#7NeA?N0BTIMQMC)kuZfcS%O^3_tOXh-3#Rl?c50#_DoCt%GZ^ z6#@KA&CIAEy}xg3dz6iQdUJ(M5Y)D0BhyCSMB2(nI9ITIx{-3n9=9M7YBWp0%VkNK z83hFeWgQ({NT}k$Cl{7fXDxX+)sQ+sQt$#9g*chCDhfRJtq3V<509t7kA(7N>^^yn$b4+`WXA^uPL6mkvU_`bL+IOwejsXI zv8tOnotN#EWli`F44#z2903WV1%x-l14??#5;e%K0gWj z!m4MgvjCD)z=p{5T=Z}p{=f=Zin+LAE_PHVx_Y-lc<_M4l_Ax5ffbE10dQ6zTQC)t-(~kUc>#B4jS^MBX3_0~1qqOZ25QDl2Awlq{0@ z0^(=kqa4|`K`+lC)`8%Ak_!7o*G=Y{WfXo_&FY}2+SQ@BjKS=rKCChj1i91<+gEUA;O%>cU`1iJ=<2&a zWU692#LYid1QO>WLGAYFXt#pnVDnmRRsP#y2cK@=KuxSwKqaZ8%OE*#5)e=u+O(C& zRh0ZXz3Ci!_?^|Le?;=bOZ!ml&W_IcSy);t_N&^J_D5I{u9b?ytoUWLe|KW4NkZ&@ z9Q<+%HDS+&6is?I#0dK#ZN)*9t+@F3?%rNMz}udZ#rcd;IhrQT&fL1+vR7Fjkd_5P zSo$xc0s{I^q8|tUBU3eCM}nb$d>p0owlC1S&mx*9sGq$GyPo7tnv7Kx+M{75+n3BU zQRvv&Q*PZOhK{)4Tw4URlQrD3h0n!d7{jCKr8zq7^!43xPASJyD1>7W0c;AR{c?-` zLntcP0&(D?*Dj%*YA=wo%{h9+{PgKHlst5Q+lTT{aT^?`f@09%Al4)I=?BJlAEGh> zcKd-B-YO&DMUKeCgyOMdjL_!8A|e9t7!Wizf;D+A&UTKWI0&Rk18AUJS3((LGoqyc zIsZ2T0m*e^CFsmKWL%DX<=XS#=620&ZLcCpX@N-~AiR58ZxAXdhviBHQM0?q)P)Nk zzl^{*eR9Q?vP zd-jlO3-FFV$fkBf@Q!OwyZ;zczV!e zF$kyW6V55ci}36rNI%#A`s*^z1`)myf8LMO<&inD+#zJcw}fagdEom*cJEenb(MOO zl|@AX@K&|s`Ip`gVYM(~le6z(J_p|blql%BmqMa1;AKST0&^s-NVNlHj%e3_d;=fS z@0vgQO*A$6(`~+WmT<>-%p||dZZW>JmRZPhyWMwe%E+|igH~Vl^+fmW|CA`kyoQ%5J7^op2fw|)pMM_GaoX zll#E`62h^aXe1$iF?Bu~IT?22wKOyej*h#PgV}r=8?_OdrWp^ucI~m#pw2y+i&`gJ zq0>?JAu!-EKdD=|Ff$0djLuKp)+CJ~E4qzK#^ruxT53D=uK>`)IrtH1M;L_3c_m`6 z#=7&wD#*`|QH1VEUsy*dCr&DSrWXF6zm7EsX?d2v2y7ye)9*!4si}aDu}POle`H4V zPuKFSPCFn11|C<-u=m!!dbOUb?TF=GG5t@fE$C08_$Fl5pF=tZS+>pLJ9Fjl+`z02 z;Kg7oGqFWDP5PFY{v#{mV-0`>;9&3AifJlL>BYf+CqY)2y|;R=8ik5uaIvhdt)Sy4 zzNs9behgz0<@hbIHj3t>*=wirluYN(K|PI<7( za_%6yk%iv$*9dHwUsT2U8w)Ds?Secmv8U=4RP`(bsH#J=8% zjP&eiJDAM`VG&AvDRQH55o+6heL3gr1Y-$0O>AKynLDcO`2Dy4c{mII=9lYbRQB(s z(*LFFWqWGriZxz_LiR(u@r(hE&ql|`#=LLe*8LOc$l2kI-4~G$zzHb> zk`l4qrGo%3wrutjA#x<+8%U7Q-S**I8)QLp7;6Bvflc3I>R6|lc)+$ur%*XT`o4!@ zP=d{=sV^(?Ky(s`nRWeaysfLBA`NeME$RphpX`}uEuLQ%G< zTwhaOzBHp~ij64es4Nnhd}O7LMheU!cRBXu_LtfhWq->8m{7++z7702-d7Ip0#-&+ zBL8|W=s#<|DQd{kqDcP7K_PizD~;E=D*w~zATq1vESO2gQs9DaU}Ur|Tt~J}OD}Z^ z>Q+MC|3A@><20=pK!pur4ynDC=?ZW?b9R1N1~MaWz5+`#aPcI$bL$7gcGA<+v)V!H zWR9j}4(%J`q}Y4!BwY^OZP=BkA?v4uy{v2iJ=BR z6CoE2hx233-4{YHx3u%OBhtMH;b1PNgZETN9-a`3pKNH9riS?8e{SXcy89!sO_xF; zB3cWe+dG+j!*v+GK&nCCmP}e2pF-NiRvnV_%+%1;%_~}QahSV@fXA}ebvGK;C|U>n zZFX+=33>#ZHp?8-FaPJJo2YYkD=+b=Q86&zvV`*DKcqicnHW=I?S!{&D}`j+-Ph+& z7S_O^9KshFmU{y=3d)K%x+X$sz}s{iHu&IWbb$gea;jYe{@v!jM^dsB!rkBk_oWM5 zOqF-iLl?u9bgY+WhP~if&9eFaGOAD-(J-rPU99n+w>fh#b38p;^)bSXXHUfQ`ul+z zpA`M`HcfAi6V07ne}S_{{8#O|fqhZk z(LWMci2<{dM$vTWxP_h1L}xSI7(>gJ*?(|=|7Jud3{CqWYZ z=dusJKM|4D|1Z8=mK4v>zYS?Juac6Iq#Yt6j}Oh@-OQBJk zfARBuG*$TCc0dyG$MphT75sP=}Hf^Pv;^oNPZA?ucRsKXX7a>l9t8M>pf>({L$ zYhdCwwwyFP1hR<{8{_tUH3*15oXm2}M}&oiNuK?*tayIP0BHjrOt4{@h;Aj)9J4UN zN2Z`jQh4`npOh2<;91472NTG$E1y0sh`D`c+@)dKmTiq;gpeb1!N@BTaDjj%q;M)` zW@gNE23B3ayNePL8CeeciossH(RB=n6lH`NGkH)PkWV~u>XdowlatW3Wl%duiDruG zvx2g112y4HsOXH%2Qj<=iiTTE&dyHRNlHtT^ebVq=Qi~ds=324+hb|PMkQAJsPzI8}N<1JxvJ; zD`g+@<-fQz>R*3bj=(RE5ceeDCY5Vd1teeVJ}Zv&UC8y^8sNO zs(Uc{emMfszeg9=hfCv98C1SFCxlnF^3Of^Z1_81IUo1b*Te`ZM>aeBhJdSA%aP;W z9gg3;8Y9|{+X;lg{Til_X33!6+0QTNH5Yqlh-Qq&`98;%nW(jhke8t{LJ$S|fnp3; zzW?mmOsfww8411WKuj}%z9yRy4>Ee8RR;ttglzvi|G3D~p;7-R8egaSGG7N1Mo_ykO46=8vXRumw!hWE0}?P@;DRV(Jl(&SY*awi{Rvu5R$O@0 z#@)sPLlwrChQxyTE%(9D+gtQ>a96tp3>r zdlYF27ByAw?V0*F^wX*!@fx@rqR=oe$5bx-0kQ}AV%&JLp%#+M2*@ZubsT^Z5-&?B z#N7ljyT-LwKYnz4a# zJquwNYz(v=o(&eT5fD|{k6070dISZvIap6?=0IT6T>|}Jap-X0#v4?E-n|@0PRVlW z$kF$;QPO1M26Or+t_+?$al-V)^-Xc&z^`CbMBPWga&&UCsbF;J#trUHCO-yS4&NLH zk@0Q83nAAYAku&D-aRl3Zv@s!c%DMBu;^LQbKvXdtvVlvOrDS<36f-ol5 zU4&%IPC}`GRG*_`ka-fgZCfX)NNV^KLJj^^LL(M@T>)So{{wBtuVq0pJ1KQ|%jgupk6D3KY8>(}3Yk})zgB(_EOq?&NimJK&S z{m7m`{+^zZ5wjO7HAS1X+A4NRNcdyu^V_#?jv+13W_fQ58x?Fo+IOVr2NxL*Tu#HZ z5l$CO4$zXnK3HOWc^WbxDWaHwDu;;;TR;UV=uD4!*OxuOK{*mk9#V+QFC$rdD?x$n z+xJ5n^l8ai9*9e=-~xn@z&I3`I43A+zBSL0r%?e)$82?@P0pJ=1^M~Uky^ost$ZXJ z`1Nrh$Fu!!H{oc+BZ&->DphS0AfD;5@Y50@xBE)I5Ag|b6^QBisnwX#9n<3O&; zz{fzqau0mb2cjD1-4oUCT>h2rQo!COcXh>w%9f##`I_sh;@*niFB*I(SO|058;a5m zu4{vn;Xx&xzeOa4`uneZ6TO$Fal?N68>qF<5!P^gg%J}oOn@Ir)-KC)TE1dM8OGQq z=mNd>x4$0VET*GYC;q6(Ce`SfPGj>Cvyi);Cg(@&EZnhgMllN()J8;Pdu)ds$HR7XXZk-L2i6L1SX+*Rh0&(N*{_?MbtbMuHCm3u>vf0_ zuoiGF8})4`&7)mkdV9?=lp`OB{?_3(eyAR9&Tu7k-pJY=JUk?8rI&v$q3Q|DS5sVS zhI#P~Tygy!Mbbps{Pykij!xgi97{nvF{i5BWYVto9Xe|gbLYQl)|^YkX944R^L+HI)}nbhNf|%Om>2HZ&X&gw(ej1@x-BvxYSgX~_9 zh}dR*Y4AHtGo+5LBgX;LA;1G#|HcX2%tYcOa3;t|8WjcBkCKI0%ftKkDG2&ek;k6< zd7i|?N@hQfkUPQZwRdZoH+^&lodev@dOl>ECJPMJ>5}}EY!1`|GK!3{sgR~a!iA1< z1`6OM-pFhGxpau|Xqb7*B?v#$gA|iVg{|AU;gnEH9~``~JG>GJJ8^L)>;zJIaA{5u zjNec))rXrrM4q2dgBQFHE^&q}x5gb=_W}{dL+9NeRLR#?v{Y7BmL+H#q0!Vc6z15B zTuEK5updg8L@_32#$U4}oJg|K1ULiP#G$~zEnwW6yyN7(nRa8(byd0jxW8y7?P^q% zk&_A^F7v>MYv}K}hOhtE=w^|F^H7^FCVZS7*%TXnsunbKQ}wXs+vie^iwYFJZ+6vW zb#h!1^$}@3a-A0;3DEJ$y&F(n9vj9UF~v;`6fbz6G9Gg*Bp3@4CRR1jSt8e*VG@eQ zjw-JI&<){91bNqx@5h>|Camvt{}H8Jg4H1R0OIC0Z)6KF?X~^$mfJP#*A{Uxi0R_O zd|WQcS;JRB&I<|qTUAm-bccwr9AZyg91pod3g^b4WsfunS`3P8>~X!o0y!91()hp_h~+ zhJwn+7z~!-k4fL@pFh89PvauZ%>Z!xx2Pen`T@hpD=27U_#K2|^*l+UqfqwzzWAsV z9A)hDO9r!iwSFxrWK{U`|NnZ4^ z;lRRCEv?HJIxenUoUWE*tL4LWL1+|8AcQCk#Hj{DwdGW!&e0DBRDz4EPH*hW-OJa@;48V=xGED<{gPy#og>T%eTV6tV>$ z!|S?va|5|}6XR@1s@C^2aB`xb1Oi)7O0hdkVf@42%01rQVobt5w5`beB{kX9pF?g7 zcg3#5Fija^M?O;^ZZwPG1&fBb#tJ5xP4?*ck01WPLQhWCV7?`O#q5FLt)!V^rkg+C z(;c0OZSY}YqPXO#^O<+sf4{WIc3Oj@L!xWMEGe9voSA@7;#XU^9&p4z;Lr_}V(92; zS%L_zq|?C7q#>|IqG`ZYi6_7ocPZ&N^4_lL#x-DA;x7201lVqm!TzGjz~lhATN1?m zR}P%KLICvm`Z!uK-%en=$ZN;oY6=%mFTqSdY`HVpCPP#?!-Mz+>j{h*z0W_-M?BvX zAF41k5im@nU+9vl9P{GE0dn~d$&+Ey;tKAn1PEfn;nlBBxs;eN>~Eijq618KHK=&z z!LS_8KAFZtNonemL=tzo&6%xM)~RolU*#^gWuJOeJLGS75_F7Qeu+4*(hz71DC0gP z(>{Ir^cX>^`a71}Js)a`F{?f5#iqKK1})}z+_>CRTX2 zU(661=?9y-@`G0#4!3j}YaTQX9KrqBA20-rI%MnUZa4Kyb-=|SE`3oK*f`V@w7Stw zq0F7RYH_eWL5(?W=BXmtC{rPCqxVQW<<4D>2}N9Ow(8QbjB?nbm*QW89?s% zg)zXZ5B)+n@8&tA<;i#s?+t6GuT@y?7nUerl8*g!BzJ+JJrDtf+?h!(ltBnYQCS&L zE+XrY5v^Y)6>2Am4$?C-uf$v=Qu?T;3=r62){QhS_Q09~27q8-Ejar}&8m0zX?ykZ z<$gpeQGnQojv5&SABq%Toq^*Uib0<`Ok6U3?AxaFkv4tihtzQc1Br`2wIk=N-@c_I z6#>K@x0O7|JdCzsit&>_Rxy#C$VAFRJuOIn&_jaSP~_>Em=c>L)96$3?M7A&MV&u7 zYi0miOCqXOosS>`;8s79qln!B5{=L((Q6R&p$fz%Ja>J)n!#GmKZg^12*$FF<8jRK z_B(x~y$r-pF2ck35yRvdSQ+Y>_gx-b0zwU%#&)~!0p?D95ZUdgqF;JtQ99oiiCPF8 zSA$~U%ahAWkct5VRmSE=(EU0t@jxp?EQIJ4q#g#Gc)%qEUDdWKsF9~OxT72I>;W37xA!Y2r~ zTj*MFF#U!N56*Z0fYVE~KUh9t8iP;6tA@R8hH7r3_8#i6e^9${bP$#K7u2~aY!e0BK~R(%>SE!3`8HgD*qMuE4{^rs>J_|&eL=jEWZ!|ENQPoAAl)!O zE;Dt(Gf)4~4s$W*Yk#>KZXFOrkYF3aQ(%&$x8&W1b*1)C(#z_2E$5D8dOTQvm_zBjZQ>aN|f-0R-AZ(X2Qu zSCW&hca5l)LqbF65-?O9K7hgeq4j)w_ON2mIasLW)ME0jh=^6_<(m}zcC&i|_JQSk zLm5ZRAv>h$PE+U9oBO*y%V4GfcKL3p5i=;sh{+ffy|4|{JM_2R9{uo)H@O!L93(Cm zf+0vWNqntMCwGwi9z`{_8pm8AHYNb52Q(5hjE!L~BGv>vAnEXY7Ils&q!FR)U|5?r zIr@_OARgOnxCs>Ng8_&e+>&_WvXh#2P~iV?xL^%2ts2~EGC1a$hQ(e94F?wtJgJv0 z_$EhAex!YI>$k0KZ4axUA326Ju}OWppzql(eP!y!MOaplwclQJ2T?)8lW^sZRZS=h zpx>;2J=QUeH6`ET=FMNbb(hDE$4DlklHpDo4%}+wgL~SD;FO@%+F$V)Njq{SmMBQJ z8wTeIv4f@oD@AAkDzQIig#ZBq->ef?g7Aj%Z=4EmAZ1Ke(BTd{^t{#Xco(?tl}MOf zFTyq>A4B@*7i>$uR&wJrnw5;(^pS|+o?wZNQpDcbuG!+;sLvR-;6`(D{T!L`Lo78e znHB+IMNF)F>>_#Feo9I(vb1r)qX_Kda&d-Jt@btfwQT2so(v0J=yAXnF^cKRNAP&*PSwA$*b?}Z5 zbu-MigIgePmW}sJL^!BGxOVLRXd^j}N}aqsUq-ZrZeI-%Kn289LZFpr`2W}4naAav zw|o3YBW93&s~K6QF}5-zAxoCBC)*?;OGq`@Q??jHF|s5}Nfat=qJRg_PTL@2{7^fRO^jch+d#f}eg}gtcWldb zdg^@-*z3RD%f-dX?k^5^;tL+2;fen}r(4%WYpvh-V~cA2ejglSxF&w|7?*Da0Q}uP z&Gel+<~+DJf(=Yf5B{q-LoIjC35(h@_%%exH`8c`Jc?{NpA?NcMwFWYHn_TLeH z^`d{u4-`e%O~EGe-KkTjxX2fuYaj3+R2IRPd_5scst7yJD#VC0Kw5Sx(iGG{5_5%{ z7iq9c%MU*E;M@-#g}oJ6=T}QQwwf}3gM5D z)C=K5FV$5`>tteaXskh2yY}sWd>M~O%lh5rD$rxI=q27y&5Z40Gt9jESp`~<&RLw+4$Q}H86$O8BfMv>^zuGue+PF&;wXAh)>@to)8YucBVoU0injU%E zB*fH`9#_sMpjOPUO<8{8{ntH;z5_1?x(ffP`Bq3C$srDy)Xr+loS7r^pl2t%wGbpA}aj z#|@N}B?{l96@ir|NNdGy#Box)SXa8D!5cocX2sF$IMY^$-^#vMcj_K0^WaQpx!g-N(})z=E>Apk*=8?RvtL38MTe>bl3bNYeF)qtCseeH(sfe(QCnPQ>_p6?Q zC)`@slrM{_p*ay`u&|esla2gLpt$*NsaN@R+OsxEWWC$B4;DGkS=U`#yY0{gJ9q9p zZW?5CW60pa5)LM1Znud?nrEXy?Nv4NRn5vj-z`MzbUM8*wiFAE=tx=S>aV-@JAksQ zjf|0aT2tPpZCjgQA5YKh$A?mrZI*og%9boK_|-V_YM+cF^+*uALKu8@FN<~mIL91! z&uL7~!V@_{qsU@OqUMAf+7)^bzdCUblf7nXZ%5N1517j;i4Mqr{Vg8@oj5gCAJMm9 z*Q#g`luLYtc(`|s+Br0%wG&{8-Or}bd>1R8H0FrDeEF0AD6ff&t;k(@Yy zx4nCOdgUHd%f|OZ(gfdVx}`vb5djxGj-3qG*XW*8V|&-Lt}XOHypfN!9tC!r$k><| zO2PVocEZZjCm2~BJz3>FE^}6|K+i#68p2*xtIAk;mjQF2mwZ=qo6>-gH9RWIuJBy| z+Y)hzM0O$ELO^X&bVPI+`Mr+gt4E_Hxd0+J#%!-_67Y}0btIL9;J=((^U>n_s+|PoJ$uqsMzyFutpo~hX$-^uGf9U z6eW$U9!n~f-1jTcRKrw+rI$xO*eJqh!9Bbka;=y3g8RXoV@c`K+fB=eyENieUdy_L zGHArQ=MNt`-ES)(se}YcR9gw>JiC_Yh3yNh&cjJ7iiAF)H|ZRD9P6hg-$~IK#;T;SN#X7zC8e!oN&k;2Z^B zDO4h+V2Xa#?`yorT^l|Q{%6&fB7u; zJC4DRR8&+fo^{l{OP@Z?Ir4oQ8a8QC^X6%&tLxXqB4D7ZvSfgCz2$vX(ORH8WbrOMC<^O4PZF2U>5KLUH73k(Fzx?S3snyUKIQ?AamV zni(fkYwiNVkRS0F6HGTr2)UA+Y#qFk$ZHYMi4XcM^BSJ8{1Q2LB45PJ2}NV(k(Q?HS>0q!`54e&P`)o2>)`b?dcof2H+6jeLGUleyYv42?RK} z|I@fv%RK_l&CU1sgUBO|mHyADz(RZG%$ey;FY{rf{3lEsOdO!D$J!CM0E4-?eAk>s z@glCj9VwJ2I!KVS7f)=~aquN7d3=uD2M@_6DM?IzP#nWjM|RND(^D@}@6e&&nni4u zrW9nUaXp*v#5NHU60)rOg|5F$pB_E_2r?BE9sOfwc~$$Hl4ZwDjPu8?orz!Ns;d>S$bV4>Ywcbjh=>wtLegyXy-Hh9Q^kMR}WV8XyyTRJdU)>;{(C z#lyGViCh%?4=^^ZBJvVzh?C5f0#3S46mybdyMNq5zgCx@L*)>AaZT{c{~v=(DW*gtBk?yj(eZ{DEF#13t4fZzvqA>#3pQgL<^z zqB2#1qxDq@))UN@cQ4&Bo!y~@3B6zF+1{jj5+#dlFyQwJG09T3vVrFuIx_uWwdl5R z%s8VMxlMsL_}KH@+mLgY@Mm+6ktXX_y2({99DYjoRA9im8?bN7w^)5wl-758<)CU# z4bLO%W4iy1eb|!~T0_LDO zCULAFy>Pi0kNT@Kr?V871Z;|n8Qn0%#)he80a0Lf|- zZxWfO&mGs(dS=m1!h=b?EzKs09Ry5OAyU&wclnBSGh$cw7D*v{Cm)0arQ_jc&9uzV z)Jmtj>Yg5-6FqZ#zB;)uvFGt@T)$atH(y3~L}d1EyWr;;#B1EEy&jdFXFXn9tAD%k z*Q27N=UCnn0giD0FYjo1-*Z^KTGi%axqoQPoCioLwt>)CB4I=*swOW?K6Q-0*>!fv z(11VN9*@~@;>x}e*MAy!oujMo%lTGTSws5|VYah;Qu2GO;g zafXZ-YIK9`EabTxN1?je@nh zd31;d2i%C^(~$pZ^k1SV+7@w*C^Vs=ZCg9xTfi+lK;|kS8KVfc_Ao)J1yJU^9u1S= zmISmPFV*(7LdD&JwftpSv{Ts%6+0Kpnb6bs&_*@3uT* z0_WfQG-VTquwS*!&WkZ&mE}eLbzK^-DwQsDgxBwn5ZE<`>ueOp&xI@>s0Y1fP*c$r zV+4*Jg)fiZT#iThz6||EA^)ZA5|XBncrU8h<(%aZLB<2Nbknj5^xUcC{N>XQeR$mO z;2ft8!1wri+C>Is+R#3Z)IQihX35BdqpK15fhc2dm6@QVtC_zjyE9(r>tx@5x$#19 z72C({U+%qhXIw!v=tpfP?45`?P}S)=F7=%T6pvbN*+7Z4mvgU^%xzK0V!l-uX5Oeo3o5e!SiA?B5k71l1F8>D5# zdhA+gP+QfvZ7;K9???6y80d8fJ{$?ys7e?zNhFab0m_jxNp=Cgo}$)MKX)>|m72CW zY2JgjqZ@fbeRdvwr{K1LOGyl93OaJ~X(uhyl_y?nfRJ8zOM^%wqdwbo#*FT3?LPNP zy$~2`kW28xs{(W*Kza5184`jGFJ7e*U z$F&9K23Mp-l|i;-ivE@&(%I44Ip}8flhrIkY-Jlxe%qCeAw-N-I&vO@{tu za^4vK@|ojl6}A*dS}ly^!dUj<^$Zf~hglw`@uM7BhIxP2!t$MI2W(Q!rhI6MiahRb z1Y9C$gy9V&#zxKh(UwR(M5YUZ0MLqn!oW#%?2;k32v?w=P* z!3yy)Okg57lKLzQQ&ZKEBQKlkyvzRiKxo}<)iLgB*uU2n&@1S!wz~;K-PjHl%4YMB zwmUY%%kSE}g7GW#A%+-W{BmBEl!Rus@{Qy!rAygNzW%Ph-sPy4Y==0Fo(%nsJ;!h5 z$G~Yl2(h{UE-!qif~t-V5wS13d3Z0Xi0$ z)0g0tZ7*5}KD{qF8dHvNS;(9-l*ZeTK_GnC!eS;4$n?jr&YeBmhdvHIkZB@KKzU@l z(uu+htsLmL=(GmCm`rGe_vHMSA!A#wMV?Htar=BfL~GMIg{&+dZ_<=F96 za;~sOAGDXZ#6aQM5f%Xdk~)emP##xe*e6en!IF>>zGSL+zNp*F$hSl%$!ZQrnSLVv z)2kqvgJQAfS)0Fzu0I>8)UV&XefvhdD;XBVjVrmHg%=H!`<$&?OgeHA%E%9bETaow zK93>t(&!EJN8Ri&Toc~U-+r#yM{l{ou*l5<&vR)aIqkx@LG019Z=Ly<$Yfjel=zgHJ2o&d%c#?XQIP| z46%upNs)zFyRE7$h7r2;s<5^Ed3wMXL1}u6|JgfNSnxkN?l@;9e+u_pt=QOIQ*!Y< zu^mME|9XHT(Ue3z)Kf%WPHk=pKOq}{%^$wD+=kkv6Ru*H<=lN_6;F12L{3*#dDup0 zKzS4rMt^cQ0Ywq)`Uyg&9k`iz>~EtflZI2KdT`e3$ESsa7f<=5 zhzIs9M7RtQ;gXP$SVXFOc4jQ+lUqz%JF}vggca6w5(O)ktwscSiYEjKn4&-fi|R^j zd&uFwL6L{rLI7ya*spB9afOs~`KFKP&7Ga+LD`@l_Rv+c*%2&me44>gyspIH(<8~a zVzdAwG^xnAghX=Kx}72vnj$@^1SB6f((Q-VZ>9T!NgGUCfsfV@Ckl(MiL`c4(+TnUo>} zMLMybQS0Ydz1%k{7YJ9X5=!|kIUWe`Wf1dKdekm)p+%^i%+TNk6erXaC7{m#zQ-r! z@fQdfw@P~9x(EC3<$gHzNg`>XVlJWTV&bRAH|*l%(V82?AKe97c7>QC+Ie7Q1pKea zN~m$hyeHAv$d2z67W^HX93nZ5JfpcnqYZXEGiku5ii)|YyUce@osP_9%byVkT)He* zlqS8$8V;X!0Nh^WZz3vMhBZprgsq#eAZzZ%**k|uq(}9?cNOaq!<|C{WRSQh{5RE8 z*_veHB_0VK_4r;@ij2KDq-)($hHhiVc!Du887zA1Gmg!_yoUEe;(z_bxA&0Z0e0~+ zwWMJCSf*TVbs5{iKa}G+>WQh|Yf4JNI%q0oz$n!u09ANqK}2#?{|x^R^A2QJsupqV zlkMg)Q7p<9x-8`5&pZFlK{XGJ=%FF&^e8sBo*VTA);lvSu!tiaRApG|!d%RCJHKfj zSdbw~uynn#(k@FP4&U`QcoeZY24uc6-F>%hPVOY1?C}{*+cr5WBh>2}vsvK~S33*P~h!p~{)>9_Ek z=!fza&*3EZe!n=)j-gUl!MzOaB%2LDMl-upmoBI0Ew;Aqkefa>qCb@nvUuTWA>3qp z5va&3?5>OKrOyB7x7fk0li%wWOFj)8FYHPB&w&N>W@6$bpCoBo&vMNtLgG+b=97bs z91abpsIky~_&UkSkNO4qMH6_DI4&egz3^28R;kmrH2$pxvk2EcI4}%BRPbORGEFdAv0Dgnr+5o5<_BWViS?U6P+Cmj0W@_2VDwLR@0YN#g19 zYRoq9wEXY94M#7xw@;=8{`!lt#JEx{_V&8*Lkk#XzZC|aUMFHrowwfYUh=J5p)r2$ ztX)Pn`ey-^@n0G8U;d)Yzxf8=Cbe;@w|ez}HqCFRTSo+<)0)S#{H|{Nk^Rr3iaXrQ zN>TO5%sl`0>DYDKikJOUg97;&>1%`kYXu#EF#eH3Y%-~V22 zM>a@VXekxc6@bwexFKkh@JSv+&81(bR2O0YwV@QADO~nB5v4^r(K-Z$@4(!K-Z>%l z3E$o1BI~TAv|Be@^J>|B7i|B#27R^b1GW}5%Xwo8#WnTU?KK&JB;=9&9`P`*wkEljAG@aQrZ#u)ptgovi}~C8j5}Y>?(t@YL_u z*Apr`D03f0_S9?A@pp?Kekiozw(r>?*I`9{Ik#I_16tHFF4t)%TyWi)BEecD3>(i*XE}kJv!!(n^*GO zr{2!F+2q{p*>CqZm9`R;O)@7#DTHtm)h0 z2d!4lnjQW&H-5FwCj~C-i>_N6^54E=Hw-b-Iv~qH`Ko&WhVd~W8x8Bi3#le9Q-u7s z*2o`JRr2tjT={xEaOoMw6v2kDcm(bAt{Y-LCt*=z5@2k8J?~)RSZy~-wZ`Fgr~9jl zcg#6zaJ8XM?Bic2szrT|_Q|P7FT-maYqpgBrqaUwz_y!KY0LbdPq_2`bdRSV2OEb) zYH69yb|WKbrNhiELJre8GLvyM)iIv4q4 z0Z*}oMb=5W^OA=HndSJ);>y~bSf4$5Zw9y(_)IgtskbZL%r0PGX!#U>qcagric<|* zEo^6}qBgkAa>pY{+U^!V49Lb1^hCc!?dvX$8t9btdH%fDNV6v=qKxaijp$bsxU0xz z_A70@X?=_L-47{#?=)O3?S0j|%ApB4+pB7>ym)UtckVDa+;@(HzXlCf9INAXEB+jD zd`MPNPR_pXXPSH7i;8}>_T!LUC0;h(YN~D4e3)=@^|}e|$B!Bu`P$n0)7jt&3Be&R zZGCG0$nD&Mb7@8FBO7aLPzY}uTU&dM^+y-K%hUZh8ARMYdH!T$W8<5B{qK$~#XQja z!=1+;D>l6}bH8>Xu58uVJ1KYle@d(U-EjZjwX4>ReiGQm&9LmjgL7vOr=EQi8b02T zlx7;Yh!+-6wn^1Z)zoa3Et|y9^jC$2lcr9+` z*i%or6jUB|YHhQ#aj~m!erUF{GH=}0A-pW?ZItKi#W8!mg{jnf}v>ygNJWpQX*nRbX+jK80>)9&(%#4f^^s0r4S1rP( zLk^mb9JyuvP#>s`U!WQ99=x0n*>xb;H0W17R6hsdfg>Q0{U1Gf!Wfp*zz_bzIvr!x z8=IJn-v^(Xardqt`WH0%BaTlRLr+UOvnln}2usR`Y1D8d@){^gt@nv7dAk#jg{~R= z>FNIQnm&UAL&g~94O!p*(V9x%+(8ZthOC}2eU|ov)J46wUtZoI!Ot_eh@^smNr>kQZ>UlkT>zI+5 zc@n$pVy}{tCG-b|VI+?F<)5L*Uc2hX`y!CzetLS>mqd$vSiP#sDM4RfKjY!UV9<#f zA*KzsByQF7Y|^aRjYa2-!pP&(8k>HuAxo<$dB2a(#?mfB6-9~bx6h)Wp`vW+uaekI zQ7(0AL^h?OI-KRM^l7wNlYbfByo$eSviULp+uY_~8SsZKov4(Q_Fw&LKeACJabD(; UycK2V`B7!8(L}@05py^H2gM*Zo&W#< literal 0 HcmV?d00001 diff --git a/docs/images/tap_reporter_no_color.png b/docs/images/tap_reporter_no_color.png new file mode 100644 index 0000000000000000000000000000000000000000..e7379a889f3f66af1a50e90b5b0c3e1a6f316343 GIT binary patch literal 44916 zcmdqIbyQr>x-Ciq!GZ+W0Kwf|L$DAmSb*Rj+@OauPld&PKu6zfPg9gR$2`K;b{{5 zPYM+oex~Y)2K)yClFJ);4OIBygK8EI|4rg5qwT8hVBzXv>}-x;Y42cX&gNq3Y;JDv z^2x#V5V2hxei8HIMN-b@#;#Tl_EZ{HcIF7`##Ef#RFZC%RNS20d{kWA!aQ8UoV-+0 zGU^&aGh0On2vi92(vljU8G8!=9|E_mLzq@38yW4ZSHYUqm0^6ZRO5YPQPEez8|&(Y z>vLfI2F`wef*&t~ql5VQ_0uP~Z>I374>u?8 zX^aV$$r*8j4mVeqSAT$n&#$L0HGTs&Z_A2JX=!Ow!XFPkI$dvp*V6E#92-4}8h)6d zJyXDeA63DD`Hxp1TF8wQC6&cTg5lWDYc;)OWcdZ{1skLn(XiLE-^mjel_7 zz6#L<9cSsxbjF3K9DjPpi5#$<-*kWvy7cP{qx6%vUvN8mo`6O4nVsmfq_QpYub6Z* zBoOCz8zrZWqaYOMaO@E2F>%H=)O<6tZs^aO(d}>-YM$!053z+m>~??;R#JgC(P29v z@HJvoxb#8FMDnWtZGgTxeabn03pnDHEO8YV&g6$FTnaL&MyHJG=W1Urdn}UjUglvT zY9&93$^knC<@tM zAd$GWc!O1Dv@aR*4*mqk*@vCgZQ*-S)CjgfFP;f9rQ>Cci*-X<;ienhxst4)xfgG@P7+Tt%w`)7{(6sECt%fkwB65pmxno&kA&)dBbZU}a zP3V%L-nSHT;ILwLeYH1Li+#i2+8A^avv?1GS>ssnem_)R#^hGy27v1+>CQHadd}-> zZYwu&4>^lQBqT`$aB=K|sukGgx==|*u>IWx%G>XW{O@vd_L6M9EU!kNrzJ4KL=JNG_K-w3}$7 zgT9q94dKYFWVF0h`a;J&6H{1_vR783om8Lg?4YoJRHbrsczSD!(xI?z$#J^37~}LX z)wm_@#eZ7BfJ?TWGv=F^x%;8oOYT)PTL^LW5fcUa;_zU?v0{r*(&z{s`E2Xg_VN*H z%$2sI73eiT$IHR*wL$@T3g_lauPuhj6&LEKXEYqI+lb(Apee=1@iZp7yo$?}eQ4d& zn7zsTRZovQ(Ds#_r(kCEM{8?e1!W66LJ}c*-!Kf?o=?7Gs3sk8+WiAd?{~fQ?(J8r zyycAd3`Tb=?ji`h?PwP-Q5*W2Mh$-e1-e(~eeOV;o)_39{gG*1z75zk{Ro`lpmMo2KFT9p!mr)8?+YrEeNhWplETX?s1Pue7 znvpT3(jYfQj3s`l3**9Hf$A2y=F4!D>C8&#FNw-?J}ptH8;DR+ynG$n60NvU#8HMD zt4{i8{Hokr!>=o(6Y6}jGVKX>Cy$Sz>XQeG65Dy_zq6AlMjnc zn{dZ+hV6xaRiJ>uJ*D`Fm1xZu`b$;ri+xi=Swa~i%zovS1X-N4gg#vs{wkY8cK$NY z$l44}TsctYG)0YQCT4oEh40#|t}!rt%89@OshFe_f-qz3$OSju&AeevcPpt)Wiaz` z?dq^^4&@Aso2l9fgTolkhbf(Loy;$j|%!g2zhqR6UbiP)AYT>B)5y3e)N4 z0Xa>;ulGcl_LmSQyBhR{796da>;2;oT3I!Un7@D1KY79~AA&Ccl02Y+6k5?Y^5KH)yGTWCUob(R>#sjuLzxQR&D)sK&EMdC)BFrG7?s6sSQtI{FCDd2l0&RWB zKJgu=1vvTT@nIk;I*826*dw@`*xxdN=iLu>mGT+@y6|l&FSkZeyLpRjnvCXB-M}y& z%3WrI#A6H1jf&ijv{7j46$tZW5~|GpNTyh|7-YN~qD zL*}vWZ@hcQMm|W%H&wWipDAaJa)Rxr4wyT3t-h~F3vbIE(sGGnFkBI`jvzC$kfDW# ze@~DcIu(vqmX>b(B&sPdrOTjj$Tih|j8Z=b28_U?I9ADOH55K-{pTICMplP1dWH-# zBJM7X0_}WDkWZtmCeH83fqUC)+IPHU4$FQQ$x6molhVzNmsPDt^G*ZwF?%yIBc?S? z{sqw^LcftN6wP*qjVDVV*eVD$Za+TD3FSFYdO&IxH}|)qi3xwDDDS9R-SqvOOVYi$ z2P4PBl8pF=G|HT#OfQeCwq>g)lZ0PD>tND_hG^E{eM7qKX!)x=n4m?UR^@IT&Eid@ zpjIDME%?Pv=o|ur?;E?BR$pS_(o~C@(1b8&M}gmJK4+Z0n{6XFZ|aC_D%Ro1A^z~0 z0z8JPlTs?Jow10rc=q@5ua0n-3;SM>8PgQ@41QsgU}*C9f2L0Fk-JxOpV7Ls(h<6+ zdACSMe`*2klu}2uDi@U8U~o9;B+B_c zQXbAj0WcoVlljq~E@3|b8-EbJN8#U<--1s-lUFpaUP*4hc| z<}Jl`o9S}?GP=i7EpTj+BTA6P{J>H%=G}I_L{0ZTFm%Lv=ucgfXYf@A*yzzVq7cT- zXop3${jt7S$tD6Gf#C%3+g{)Dl$-0$79~BN(3bQFiG2L$pFrPZ6aVO858v~o(XDvJ zY_ZJvvGS6SvXA2=j4W}0E`Ykv6Wq4U-yxsH zty^$HfxSHz`>g!Ez?4Uk`CZYU4lF+NLsAgoN}yQ#Ax+emI{nXYB{{vULO?aeC8}6* zfl1W)YhPsfq1w=uy24|_ZO@~EgOTWX;aee2lXWvd?(yV*0muF?UHb3C;QwD#f6_7K zf-doJUUTPj@cQX&3m3dsi~8~U_IDL}GP?4q03YZyH}Yr62jY(9T?ZjO7xP~1 zbz7P?H6K5mEenyeKhSy88i11+zO)XdDtEMA7r-Db! zY{X*cIO_hpylEw?I<%RHDD>Rcyx~|JRuQgT*>O6Dmkw;V882JfHWECb#N^cCdk&-Lg*M5u?-tzr zdPTyzKSL&6-4iF$!G#r~BZM{eZlu$lM<`j#e$&o==Y8%w2&mN8@r8{g$950Ve4TWt=|Hn>v63V0{E&JqEuL*HyD&`NAY<{QB5Sq8^T1=5>3CeY zOf(X}BZo)1o!54SIyc=0PCNTrW9KRzFSyCBmS7TrQNLQmMDM-JoRq&`IKQjHh9Ckg z6z^P}$YHu!<1@HF3tpUc{Rgub$NZS+x;_n9Bi-wX@4m)L7{MaRNeYdYs&yw z9Ny*li*@hHT5KaIn1YIlH_j+5%-_q4o1R}!@<|Fd3`Nz7<8-z_jq+(ha%;B`@1j_Q zNMFWUcSWq~nAy0ty5uT>Z2)jHdfwCexs^Xe)@WYaKJ$Uf<$3mU=GjNlCNjY02yn(u zjKt;Awd;b_Qpp07-e`*O{TS)l$AWKiD-W(h6_y_+td4jOS`Tq-H93xqm1&G#2w6ON zuBK-TbL47?Ohet`O4Dgr1P7{vk8hIK#iy;8X^TBn-aLJ}4Jlz!zQauVaQ;JHX#>P+ zFp1WUYCf~q)T3V+?B=^Q=e~XjKC*cZ51X}??n|R>p}{mQgSGxre>1Q17S>t4KoYLd zFv`8I&}6LyP5t%NpZW5?N3pf14pj+IH@>9+2RxA2 zYYU3<6hm&8w}!Ucsh-8kjz)`UmD4<*vWP$fL3?vrev%@YJq!#uSqXiI(*^3rPn+^x zzueLlF&+CPCdl*f=Xgn*lEYH?3}1d~Qf1r}e0JRu@zViKsX(PpxrE^!sHIaY5Oq?D zIC6@b1tDRq&LzW;5z~!d2yZw&+!oZ>aND{Mvy#c~zFW{uuHrSp z!jo0DI7oc|)b^J~b%J?C`&^7bs`g}<)=0AWBc$2Q1b0^NUQr&el5ioRh#cLmS<$B% zxje%$67NyJZ#bQDVHr3v5C63#oo$SW$}|i9krSHqev65Yh9+AGFE^rAvMDSn_!IGF zFfL+uW53uE@+JxqBImtAfq`PNJM5c8`H+|cDFlvuH_nRFzCg}9$@Xp#Dp6icnKCwr zH^$A;+nHW^L$ogT`dQ4~;G;r$`yL*F9H_CIas=I-o!4XjVZ*XuU3H?N5ZPtBc# z=3pnfey4+^F*j+YQOX!;ZE@c8eaph9ISJ(p)ST8OAEm z89c36uMLsIwHIkQs2t@d-Q8(-Qp!dnu8)k$O#Oq4UA>AJ*>isW4A03?+adoEj4brg zMrbS3hovY&?4$7T#OvM&*YQ~X7q}FCAu2IM(0hdy&WSJS~g<4YD#Vq$X2S&SA~IP^SuwlvLkOUb+#hOj+J#Wm+(~ii9_&+Xd$hMt0xgf=B|{yLJn2dp3k0G@DL`QJ;~fKdfS6Ff=c+DUuM$ znf5W*iu>5VZ_y~5cuE2|Q~?N{%i_|YUsD5rwWsT{?n;U1n}q&qSMkWn^~M!&MI9?3 z^KfBkmXX7GZ}@IKHCw&;M!Z!t=$AMe#@1Zs*49A}28CqQE`CTIdrq@km&*>mn^!HI zuIu+m0(au-oslKK>#3^S6C4W%s-W}SeycH8ug{*=PMh4Ipek%*2~z9hwpYYOq~0Ac zXiv;1Q^~m2dFvp974}7H%VQOZ9{TldR7sp23)EccgPTpb9a<7iTDzJ4@oP0pl~+v_ z(W}`U=GR2ei0)d=UWPo2K2szI=T$M$($RBMmj5?}hH_H($*A5~ zv<()WxoCiM#CZcroGv9!JI=;vW8Qt&3Xcxh`W*F6k=AL_F)+qo)@y8=)}zjM>p2SI z;S~`@);C3y6;zWhyP4)5Zf>sl9-R0@`vv84Si>(kczsL8g^P>JtNw?~)Y?a9Kf-(5 zhp*}XuW8T!65iW7f@6pn;}cVrldedP<2$Kb$9hR6t#&vK5dvE}=#(V3d#?hYvw1X* zwH}D&p)A57EfiVcw;x1XM@~Q>{QhsFGk$zph^0lRG@;t zMcCXNGT%R#z|vXCCbdTzx1Z#tXU}+~_vT!yD`U|32Ey0b?>RVvaU?t_>J9sR`~;rx z-|*|+g2sLXnLj*4@t1CXpU#8Ows33T3>cHnR#rcj%KiFW*fp2**VK!MBmX1MRuvbR z&k^+^v_QGga6P&7CWqKz*9OjEY(eGq8R28~29$;FAXQIBEKD2RiaEzrje>)ZB>1!v z(avco?oT7%jkfU+EAd?BQ~(?GE`|=&z%0zj(JTdpw<8Q}}bN-Mkf~ z4eO(vv6rwk_Li^^=U<-{(0d%4pskM1@qd$>W*YGSMb;5vKK$`ZEJeZ9eDBLw8s1|Z zhww)Vuib&)>u-7Cn45BA`f!j0l4zLD@fqce&j#9t68;8xuJwBl^w^BGmDO);tbfwN z#lE+1-~KuTJ>H;SbE3u>{#1W>^8Zr6{A-&1-&S|ZM1ki@E`9^2Fz)EB!||k9Y7%ZI zVI~126W6$pvW^%Dl-^&7416LsDM>>ny6FGx>dP(o4Q&!psJQe>G}oaWSgJ#CLc1$l zRMPrPz8YOLiT^P&%PG;5oJsz3ut70#A9H#}Id6fboqs{yE?yAQ#7TPGC(5C`T#4RH zj@PlQ*Rgqtc6l;MGk}zxm5>FaH;`4SWcN#!-XBGkn<-B6@DxdO35 z^&|YN#ybw2S2#zZPfgQCc=^113}SWM0ugVO1AtkQr>%m@6lRNUC(ogWe-@|ez{JGZqeu$A(_lbRCRA6` zd+m21Ip~U(_c*^2V#rvzDoFwW55yT(X+|@n-nB764`$d+x<*Id_7Zn}#;2RUS@t3C z!01RrOC`&OkxB?xjj}^>#J?ae-GZVY+ls^@XH{yY zH_Cvy%64;hoMj2D@3P$ldL-Ew+IO&0qzETf`MMuDm1i%Hmx40A@f-M}+cjRbrfBRx zu=wjG4>jS8{Xt@(d;~SSK>{=9PmHjsNMO(0G?gllY5D&c?|7m&o-8H9YTHpMWf6X63vDzuM1nN0knu zt#`VAm>cbWXqj#U!yKGr?o%+ABKleoYijgf4D$kY1vE_Wme+aEUPhlgj5vczDHxO3 z@6&e297gJZ31FZyp5;a6KQIMVrMWk!_EK4IX@B*C6qUP-=j-ySb}A))n>Jm^uYQ%W zmb$uaS@C0(LNdL3#tKgBa zl2J&x!tax^vLC*<#J?Iu#>N&RNJImPrE^48J|scIN{4tI{NcdCVCr{cAC+L_4q^LzO#Yj$vudS0hxsJPnrK77-^k~ z*G?#&H`S2AS}s7tBaxsFQN5QcdTTf`UaQC~);8TN`fmY+{XO3fJ$x!}zkj5e#6JHa zyUIU;fPH@i(>C@0sf_;HCHwy@tp0D+^*n6F3XfI|C5FJ8ShU}PWHi(#Vk@5xk@a-l zO*ZZ_{I}Yp7u&ATWS|%JDlEFRQhf|#OqO_aF1uXqr*(Q~Z&SPHt#ZTnSMoYDyGPv) zPsc{7N$>4dJPKf^xvn=yBp)a)Uhv-F_zBq(sjxw1g1{_JxO~jt06c2paPdzoqgRU( z2yR9+_e5~yG+R~|#cxh4G=P0&#_NzhOQbyYr_Wqj*nAj1utuf4MS_X9OI(~z?Z3JO z76RN9ge-QwD3s9p5IBLn)0rz*Q1I1JH^)F(%}GLw9vc~a^BRq1@UXkL`IYB1ZSsfP zsIMeg)c2zp`k(r*-dvEPw6t=|XwbSxB93HNo|UW3L)w1R`Qq_MG6qFNl{h%RLyE`M((bfF{w(Yc+-`HzRkr$U z`k~4eJ5mxop6hhtqxVUC&#+8RuAqs2O@YAQY)rZIr>2A)JHf!+PaDvwS$x0Mf<3>z@z4)!2K}Na_8=rN39FC=8NFrEFnH<{MBT4aQyvb>9 zEEQEqI>JycZ}_aOg5BxHcP%{X&;-Nb)Rbt+aO@Mhzf)5cY`5eMXnR5tr-d+SH4}%a z4GO!Lb)w19Khq1i22%&B*%(IeV2@hdywR=;Vvz-JZ`frO$6-2GkFI{l55!wtIq}N` z{lySN*2dI$efR3B;aM}lz{e1sJr*QX>Lc0S{2?we3QUbJ;k8v*6s-ELlw#?C3A~7C z*Rd_}!BICB9boR!Tz3pk|MwQZ!Q3FMU zvu+o>-nG^$pO2bAhsPd?L=N$;i@L)adf?h#e-_P`9wCqTG<*fK%9koiTo7HYDpos* zbpwBEeS_^bw^HWOoC{a2)OGx1-ertk#keQYey%^*sJ|Sk_cj6p*fPrXNtxWHuL%&y zu~013Cm?M{8>ibWDmA^Oz_&kqq=Tc5uzL_;Uk8(i(i6mu zqb;%ApYzR0bUMFXNjYOkE=2=Xk40IkIsAIFYQSb2v@J93ywO2+#LQ3riuxL=Ez!|^ zEwfAXX-MP$8nu{za5390Bp15m)5QmRH~$nfnB@-KetwIvaliNE>l;Kgch9TBLIzWl zZUX#(>m&ac-!8Z-?3mAA8F>weWJsMZBs7{1%ZuOL5ECfTNAnRZ-kEkCbgZN2-Hxcs zqYL(YQ3A0wQHm6;j)cK9oYgz26 z2}8}&!ELJdi4Ih`VvMm6j?5qP1bLrv#y2kGp60!TgGxq*SkNuQIAP%!>>8eS5^7u3 zs8pWM{i~EUo*wzxhE&Mz$#`ML8Gv5ibSvvK-{z50;m*>^mG?*IdG2JC7F_0qK+|x{yESisP;0}j#iQX9z@wc|7mF_T8&RM9{ogyZkdnZ0S^&jpRB3OI*ZgUqr zUBg#+(z?4%e!qEq2otL?Uvto)#Wr-}s{0?)^Bkmpa>xX1_ycxT}w^Dr2ud zzz2M?`G}23B1y#%8o>6&UVYdBGs)tbV#+`3w=>?aqF4y8a4JOV#zaBFXn+!lntD;| zpHL=P*)UbJaUr^~s|%I)`_0*IC}vora?as{x}KiG>*i{aIK)+CzXJj`)Zq z%HM!6lZeY=afD#$L%d3yw#1vQ7KfRG?GN+>oL0h(QEUu%%{L_>mq=tp?OhZgA)2HS z0(@*A**~3l!{UpZB*0>m{!?AMtUbP%HADmTX={K9Z z0h3%_!qOq?c-O4Akx64V9lD$Jms`fx#qCQQ@e?H3jiEuh_mp+#8+J=&?fZpOXXAQW z%Epo;=hKWGhQ4f+7nC%?#-|h}QX=zr}b*p<_Ndc(c?!<*RPl%(SRTH(tb zv(YcNyVW~SS&Yt3EKvzSS_J)!o+MHV_OS+Rzx90nUA2!+;aG%tH}VU$+H5HqOg1=6 zkr)-_v!NJ8KaRXk6hoV2YwEIrPZ-mZnq^pcEq>#1bI(UdF6PsyWWU#V^HF?H;-U@X zCAlKBIrfTrZecu3mQhoQ2p_m7zOmZ2^PKY1QX$41A?P&dQ0Cz+Je7pG%^O0w$bOdE z(o#_eDi^lDiu&U&C@sxf&NxJ^smi!p1@+&piA`;|o3CWzZJWdD2^ui*IBkhYUOm?P z)Ukc`XlGDW#gUQ8pA>q7hUr|3Y=HtyaG>L>k{d$V`VTV$87dlf_qGk2A%t4q;Od3C z@cueS?!MZWD;#?0~Z@Am|#z%e*C~m+DD&Sbl zig0QiZQaVVX+VvdEshK$sYwH-d#F+P;;o_}-$2|KA#c36JbR41LiBdK2P3DEy6s^b zPxdArOij{|-NWu}8=Yk*YId7YLg4d7rOs#h_QCddm2KqKyPoY)9$`EvMAlS);d0IR zl$v^48HJ+CcBMZ?|1aGOME;Wz4dEj!;>ME_N~X|8;N9|R&IQ1;x*_VT8gZszJQ)j? z`sy=>-)LAAA|ZutE!Gt2BlkRZwxdP#m6p`%mRPwK=MI3n@1#d>CLIf)te zdT_Xcnb6qZ@e^hEdz{hPTz7S1@=$D)8zYB}W0^oX6O9XDTIx(fVdy@jsVDrCM!~Wx zVpW;*>g%3Q;ffmz?WrRP!2^aJAQEzV&Q&n)CxHFC+|)*y@3XIiNuN?Dxo%z9io^Bm z^cY)Xn}-oavh24XH%=9DjLF4xbzJN!MJ zfzx=HaYZECWE#ca*iBZ(=2JC}xFb1J{I$=uCKexkiY8!9B$Uh7S(MM)J$||`mfTuZ z&RCL03=hO(Ws5E!5fO#TVl-6llZK!IF~(}@Cg!&1P5|X|3eI*{MGtA$GgY|JPUSIQ z5^KgwHClB^_r=N^Yrx(!k89QNvL(EWJ*;Er2zY|$V5;HDxquu+#l>|zEJ3phB%jZS zZ~&uvj5+8rWov__MZAbtj>R%+?q0U0;t81G1i8oA^#!b=&v@70p* zMaOPx;`nnyl}t2V6Owss)FI*3Bz-LqkILjEc7bV`X}$S0{>IOFQ3Dsnjo}yJ+e^vZ zw~FMFW&J8YDY`)3O;8J6wfUGrWjo89$P6HIpW0INdDbA zT;vGPli`+P*?)M2|F@JD&dmHbtj2$<{zy8CbQAuQm!N#)P;WLO_0;9z2aMnEc7*{S zP$7>4s~f1-)g1bxo02Kl?um!{8zUjK@`bVGaNf|z?3eO*Rfc=PJjaWk)P3>T7mV5RZB7m#s5AfbJzPH+kHKfn58^5so&&duA_R5JXk-x+ z_IF+y7>`tKT-ay8Y2VAV__(-Vk|+Rj44o@{><|Zw^#RX<1#*SW4O}ccg8{>73spCZ z61~4lo8n|U;vG3u#J(z49*>~^L$n7B-i+6=3lrEQac`AppKN`XYCXQ==H8t>SUvKc z%ls>k?!O~Wf8Wn{LCxd@l!k{~14o2aBRhPc> zs^+>=ADgpb=@C44!n38}o zN=qSLy`_*1w=UEMF2pa(%{1wiMgAw+b?LOe=otyt44kZ;H3FB||W(Mk=5HqNtt=+B{DY zw`)nbTBGf98Na%pb!AqhYDiReYNzF+%Zhd8w(67Bi2W1=&n7lX5ZQ8jg+NUGi%QbI zxs-Kx%XX=_4qJ+QwUlw5tAvEWJ8={n0(Q8+epVq2I|;foSTg~&_?ug_%mah$Ke$@3 zPQf2PsW$OvWDVVKQg=n>|B0+^FZ^5ua=8U(8~G&Hs6?IoovWpYtdB_AM}Lm_y}t3v z_IAYjOQa3jmX}vcYa%|r34OGsUvUB=LnIRuJC(#GmHG6}sK+V(w!e3zYX{VgHTGd> zf4I>JFN{BN2blsc1GtYb2d(F;2Y((x7(ON9R>H#|BWjvIWWF*Of{J|ezgJ>58h3Rh z(N*U4HML7#7whcnt*8V!jfR`MJbRXeBJ@uZ{G7$3AGNSys0ZjqqCm63X}o5(p^Qe? zfviL)qH}T6vgc?xx5*5c-`*4R6RGi*H7z_#r|E{z<#Bppzsgoxyb3hpO}V#^1n)=D z>UD26hcTko8dniFM2q8&$*QRRnxI&hdyHfYv4i>C#xkqBeDvksJnKut>(yqx(dcjs zsb_qJ0;NSM`joAm<=6<`2*zTe&bvX+o9xE<-P@C+&4Yf*3LfX8;G{G}-iJh&ad>^Y z2pF+%D1Q7bLhtkLZL-Jk-%Xzr+pU(a)YM%vrsnGc2h{vey4^!oQ~V~m$%Y0b{Gx_c zpr&^ATJ%t%c!T|nh&H#mN4qGgqcBhdp9s$U!l4}6LF8qhA(Dq{y7EeUW7Sds z(w~Cy$~R-kZ@Ri2Z$1tY$ub}-r-EC#1TysDis4o{vL?ZUK_N4IP(Cz|%CV*kR+|zL z#1=Zk_UY4WY*4o)Vp5L@_Pq8{H=}X9h8USb#v<^Vs#ZAp430izE-h85i^tSotL`d} zQ1e$@1*^h%qXDZICt={oPsx<4O>6ZHwp#znYKmwOPC7cNdxN)ilX#yWEl3^8N!KYe zu%;)t)N4Mg?RxZNagpA7y9WK?ulRu&%bJq{Q43(aB>Xmlg@ zKX0L-L<~S&hWI7O(9Ky=+y;}#n-4mc$P1#M(M)A=7O(MJ#IK&0@G!HZzH-AS4nUh)YcA53hV$zc<+K$=Dh`H2r@B7EarCmx(Vo;zXiet@o z(?2q_o$TK?%KzgxHjg#`VYmE$*_*fwCy;#vh-dVb$wQqs2qtU`ipGMhuDKuEoMw2Y zfbfq@TqIyutS&+eW_u|g{z9J3AO%kl?7Zh`U!M@;@aT`)aqfFV?AI%9;Kv1O*yC>Lxeu{yx8!8HqrYVExvIopZx<1hG{u4zJk0rOu1_r$ci;iGW{^U|qVBNN;`}XO~db`V9RzX+q$1IC9CG0E*ksxB@o<8aKx;hG;wiwG= z!X?Jiahz790|H0}GNv583dhq!+O3~(A_;*bee*W{%q}v8l}8LJaiqRqO9NSio@Eay zR}7pIQ@RIV8v3Uz34QaSY?J+wI+&Xd*gVG;#O2QdBzPG+9Mbz{>z}Spsw~!B=(*VW zQt+UX2xqsqdm~*8^RWVMD}204@tB@du3kuLjc*Fa>R*VuHyzHqe>Y-E;!aOLPN5K8 zbboL@r>oZzL%Af+`C&=!i#Xf(S)8YcZP;Y7&3A9kBLMH)^iA-d(XS{G61}?562LP{ z_r{9qEV0nUv9Uz^`xLu;JJ{vDK;6FKICR`D&&~}mGviIv*LAne7B2P)oZ4f+FskuZ zN_-~f{ z^6l|BiN42N-qiG5zHynkHiV~B1@J7!5tq-J@YEuPUVL2M_ZX+X!Z(|5o30E->G-eg znIP_ZPGse#AYBIv=?YE;B?5q%&%>)j2XWc`?fcoS;ec%qm(8os(!_;=t$>$uriT`- z-Z-%1>7X)oEb&^B|LpDTAyCrkfV5|&rE~Zp%zA^yrd2yE=VEcaPBm7%<{-XT^VV3+ zSlI(Fc@nl4*^p|4vk`SaoOa&WGXKMM>f@E?@{rIf*j{(`cWwVAhW`@Dfd|{BmV<2} zRshvkO2C&E(#4I%ht`Jm3IoF%h^5wCn8Ccr;zqs{Ng_W=+?vDnbK+&+t%;^DdqE5w z<5=)$7w?r?PS*i&XITk=#+#agrP8%drt5SxQrU*|%CW`7DMb)EdsMuGQ}K{r3@}ym z13_QiAR5`*n?r{sF~*mtyC{L$4YhHdHTJLSU3d<<4J)1HNl{oh?m9%*D2H>b-%#EJ zlaV{!-h3u?%{;?<;Cp!fa2mbOdzKBZ@Z*j0_4oO5S#5{W0+XlD_KZ&!NHn>rhFv+g z-mY=qo9+(IfM6j)Pj&&v>ncn~2p0#6*M_iks}aiMt`ah)Z&`6crWvnn0FZ za~0joy6F6c%-%bt2~E;635`TN8O5UK{rNfi!`-NyS!hAr`01U575n1GM27VFf&AOo zsAAr3z+#cH;Tv^0UGcqjIp?L)^bE0Z^15>?XYzdY3lo!;tOmU16^r97#MN-Yrie@E z!*l=J<}YLxcX23vb*!6zk`Z>3u@zo!8?lT#XC?>sk3Bi?kMHgpT$z0ysxR`h@15Wd zGPpkjIsb!xDB*bO3uZ=GU&Icpcg1o~=DStwcE7Y_t@R1hS;XO&6f2AMw~l)VGv3ht zX#MK9w?lKS4RsmN2}-krqa~g?AE?$okc47$V^u;NRO7ELV=#$-(BexhNn};4qoe%n zl`Gb_U%l#h(YWFE-B+R0p~0YwV?%5?0bA)Ki6efZG|iz4Gwk(t2Dz}!3)XYuHx0n z`pPizD1tL%qlvUaEP7IMQmyg#m(gm4}kHU;R%u31(F`AgBRy@v;- zva4$SSKXT@9km9DzEv48fHz;N@c^yIrHALeh&u&OiBR>qdObyvxJbQaWR8alQC)ui zC#x1vT}RYet3y3tQ>)@IJu@F8DWtzfPvr{zDn@zj4qvOyVk6Pf$y}i0A@!isUA)5-IipOy9swZaz#joV=Q7YQk%UX?gRM))Azz1v( zUcSL?nM^WGr!8PUs|fjMYNB*;+vpEh|6X1HyPcJG-oS{M?Kk>UA5Lse`-jU--zcig z5?^CxUy+}Y3w`ZxwQIcs+pXzz{K(C~x@A(qdik~`Q-qOyi2C>~p!lZogryoMC7+ z)YaFse6)YI!^FJi>WMO&O5dqJ8}G{LLm$a4ASZQbaca^GE`8eLCB=6p~ z+G!a+o!~ziEdZX+)#m66JP2C65VuA4aA!9=+`$vCh@BL4Uw4AP-6PvN>*68tHa5dun=%k?5m&xPhT^qcIe@Amm0PywM z>AyMib;t6Kxy{~|N#EfB*x76Vh73mi7fODL+N`2uoh;WKP25hFR6j+WsHgv^6lzrljR426M;jzeUoGmySu25*PmD}*Vm%hy@U6ZeUG!=E@*iuWm~Fc zlx^VBeW7DD1xGy5K};x&oniW9^Snr-Zi8<^aO%csPgt$;>`QcrlFl8o0pu%Sl&5xY z=j(<_M%}ZXGVh>9w*Z>Bqw=7X`yP`GAX9<`-^-3kXqYTIF%mAkZg)FG3z3RJT`5 z!cd{ev6kej&0&Ds&1^+TJG2m5H&owL*`>9f;M8rq3t;Nw#HeJWya8hG3peCN*6z~3 z1U=17ty(h<)$kcCaqyM*V>v|rEqKA#SGD_A;Lx+Xyr4FZv~VIPk1G4_&gbMbQjqM0 zthVE8DHP1_w_A{5(y_XS?_R}B1HwH&&aB_eh6u0*URaQk&G9=T38slu*6=I{*Xm8` z%ei~eyH~WNOmRF-rU@VIrsuAX+&0ZjPkp6&Mmd}PGp^(}ot`wv9n?QRXyfl0k!;`< zk^FFkuFFlu%-_7sg-MMD?s7v=pg23C$nem`N()Bp1!iXd-v5QRSl5Q|Xmy?IEDOT^)jj%_ z>kXQNjhah+vEN91tnY6TWV>cJhA!ruU(-X8?tC&K>$Qh-$^9#$U#ue;84o)4@2MGC zKDD+?q{D;tcA@3Q)6FM}Gju^9xy@31b;10wYE{v2V_qPm@>Dnga>BKUKLV){ zZzc5e%J$Oy@KV##hEu8=)owln5)u5EY9BS)}bL zvM~IdLoFC3SL_WX(n-_B(*EUys(#p-Nj3c;hVb``7hC~Mi2C>k!*-q;Aw+Z9skHeS z=4Zjr6g?bh@^jdL2jnW*F3?r}UhktjmBJ#}! zg*{UxXb;S;5Zr>LtB|Yq$chXsQmQyxxOW!{B{Z8}D^lPoB(A=&qQGWYT@e&>M~@ZL z7^N#MnEm;ho1fNsv?o$i(HJL+)Ct=oF;C6-vu2Xa_`rncQ5*@S%9y^#=@MeT z&)4_wu9mjvU+Q#}H>#i4NE^J|+%Qc|Ru2bEXAZY^Qv=7JT00feB}|-go$XRc1yxcY zhTB^{RrU%_P5FS0j9H#LT293vgn4-#xz1jABN)M8OF`^`l6m3((LXm-rQ8R@mt-rN zUn-^UdkP13Ha+KseL;^#d@E1x56Y`?EufjZ$?(-&mHOg(BiKXXW8?ELXp{>68BB^|}FRf4_cXszQVaFDVN1*~B5S7_4y#q3}kpry;m*V2IKx}uO6Nq=J2xICu zIp#EF+t3;bbt1x=O-HWJRd}QZk&2WC&;5ZaKr$^J+=L=8A7<>)QWMLM1p8t0196cH z;=8{Uyw`6MMMWY(2Q?5tYhc{mp@l^S?uvn!Q|HIu6_;K*X5B{o%U{2E6>!0w=tx?Ff-94NN_q5gFe)9y#-W7 z>vwkYIgD+0K2y}bV^uFcmA^ZqX>*m~0h)(cyUf(>Y3(^of99;oSeZ~h@U%CHG}>0m zOm~-6b*K1-D6AT{dSQ%ko<)Kq1wL{fSJU;A`5_~@gZ8fQf|kCEw(M8VMvq+ULsIWu zY69Ss8LGPu7O0-pbY%3jt$D=#^mj96k2rUb%wkqRH|I~0`mZoAUu**YNpqj!>IOt@ zL2ts?h2@-P&Tk9;{@EkZ&->wf6z2Ibq%93opVDL}$AO2bqoYz`rtXZW)uZ*86g({! zishy36-Y<(kzF`@7;o{3Xi+O{sJ-&^P9ZJXG#Ljrz)tV$fE;OQd2%CHByRYnX@%?T zGlK`^?GOsr^jl0U&U`ZDGPWoDmMmR;7ySBnQTjEfJ>z1VKfhDa zVY~+Hg@h>J7GgM_-4uInb#Aj3%sJck7HK{=ykb*)l+T%f=EJ zHJI9r{>J~@0xl-C=uhGox)`mK*&ZF29%!~;m8~D@Q*QhZ>fSOcu5Q~FO(0mX;0__U zyIT?nu7L!1hr$YXcXx;2?(Xgu+}%BeTfr;7@9ewJzW46)UVHcH58A3$P^(yT%{k`i zee}_nH$teh*_P>d!IvOtXK>P#o)FhM_g=285|u`N>=#>NWBHLOInVJa?K0BY#E~uh zf%blG2QV%)97=0&FpXEMQN;wj8I zFC0}o(FK3Nvff6TErE-{H_Fl-qI~q(ByYV`hA6CdO0ImE7@kjZPiiR>B&T~$!>GL`s%e4rJs{<#b_TSVOs2Gff-3nkeIhY zt=c(rz^(sgVaka>!np6NKmRzn0@SZ68eAF(zJ5bq<(>L@*ZwX+Px$L^Af|CnhOr8!>yPRJ8$1% z*oo1hmq0#I8{$Lp`LmelN=uL`nSKypyHio26SR7)+IC27oB|Avjp*60)Y+qU`NmsB z%iYyJW`2JsPg>`N#u{?|bn-=mrruEisd!QUx4pcv4YW(MaOu)fEXk z9`IefkR=B1uSiHQ^R5(WR~qe7#zB#AFFQXHEXOVwF!5!fprM(^KBnb+Z(5@f5{AK5p7NR%n;jbyjafg) zHf1huKcHcq<<{?DB4oOEE~QfyRSd_!-uF-Qfj$(l(c2_jSuBh!77Xm{%*0%ZhF^X)G4z{Iz@5unq;A0Or+Xp zc`LACIuA%e-nFRWmhdLZOL7=ujsd;IyS~aEVy5ESMgq-2V&@}U^HwB#r51`d0J4!p ze?44Xqztaig-f;Fp_Q&>E8>1#2mL4CX#}A=MiP>ePS}%S4N3Y+x=5RkRVf33sHDJs zhYXI-MFQ4r2N#+lL1K3}u|!L)%#-sasU+ZIP0;U!OjdJgCP7I)(R9uJD!*9z zG(N9o-y3vKZ0l>i&sK0$T*M`)DQhPMRca0_a1G~_WrIH5ZGbg_h%CpO{8Z;84B|rj zg4hk%(FnT~J?#$=Ssp!lq=9!%hzBA)6flMxxHIaU7+xYS7}dFWj%2JdKm-_TVE+2R z!aXN^F-%T-YTF=iwe~%M2xVVd@>6^HTrJ{lCGgM&Dx5ih!O2h8pX6e0fAP8|F5^3p z{!Qu>wAE$m9jzpt+0k)IoJ{Jokgi(CSrWo^;&{c3!)u%o#H6pH9v$l;=JAFz;*l7o z`BnKb@nn=dgn-GHz}qhn=DVu=?++i|wxs#^NJ8=XVHkXFvQTuP_a1#TX8x5Jdgq6q z#sWUv=Ixu)&$}iaDgm?qEJ>@r=zqVU)Mz_M2YS(5mlR?ZDgNC@zmZgpJHJvix zZNTBLhgytn^ha#SjU({&q2N4QEpevW(xOC39etwFeU~Dy?&LLF0geS*A~G{0`&NP` zE*`7KCdZkH7HEtVH>%{QVxj~hU157Sq{VmZAsoi|n#9&&e+S4?2&Y89uj@yv(;r&) z4$g4sz;R}W1?FbUWr=yxwnC`~Dw_FiSRk2S7h(eQe!bEhgLWUpkl`0{5Ag#rMuo8b zYmJQSeZrf6hX4maI{Lbb*c~Ct^#&Q2DkLqiDQz}d-SwWer$u0Y)C1oncEKN2v#s>ntE{7(Vwg8`Tb-Ug& zFv_W8QWEDemoh=aUgyY(ycNShOoh&!e*`f>;E>crpxPo_5M7YL!isBS8)vldKnYWG zIv)DBmn?Ab`zE#3{{DJo!nYB7i|WS4&Gy!{Ku_!hbM`8gBz1qn<=7%Vqn60)hAN>C&5bQco##@! z?;Y4>c0aRFI$0g;vo-u5aEGc4U2JY#O;|>y*WsB(u2OB@eERmGtt{l{|FIm z-SYz>#cxZ~_X#ThCaYy{F|Dt9xN~`Ko-*nheN<)T2x^X@k8r=BJZ`7vbp{pWC zbtW6AHkgr)BFc6;wAQD$rdqyDg0>sWZqkC}^7ix$zf1kMq}bABFJF5Ri%{bdJDpgg z)30xWHIFy5S59b4N|}9HecFK@SYKfzJRg|Ue6TG2o|*Xs-GKoNb51m`$OO5*r!ib^ z>tFen?I3Ah+2^-H8A&|^9cnTcKP19mE6F9(Q*3W*$bqgeS*)T zDRobCe6%$)_()^xb;Vk}(|rHha*WpTJM1sB$~*tRO)LLDbTmX9AMZ&LwBqgIZ7F}? zgj~y~h7_-3O>Y9RkG@7sMsxC1b?GbQ41Awwe=NVYknPOn;Ehn$?c}BBmNtjQQUME_ zikBfdNYIK)m^U=s(tHd0>q&r@)BlfMvmqH<%-dUO<57z*xXNW8-~`UWG)zy{_~}-; zWS%lh9`?h)>x>CGtp_IJ6B4)U`#mXCv1%texS&WqxO=CBfp>ST%xC zI*BVHYA13r%?^8+_5^^PXWqPp zCfUT13(p_>R-W^Z{OI>Zy=)>=$@BNSOSkhIf!4bLxxt1vWI-OG9;1$r6qo&oB|Hu{ zOKpT}4XY9Zo3<*4SL%`lQ>ud202mqv0w<-+cIWT zBY^!Ew>Ge3g(RUKPnr*e?(sNlLbCSes6LRJcPG<%UEVpr8-)M$Wb*cIq++!ek2%tc z$tCT+sblv%khaphQ}Fg;H84=I*_Dk>aTwv$mWz$p<9*H!%$kr^IF&7&RfjWf;9@uk zRhH^$qs7gw^x5hZlH0h!^C{CF>!k@$+Mb)>h^;S*OmQH^d(B%oUT2IcPbEvEQY?FjU3JoL?T-}|uan9*tB?K(l}5Kc6_;~~I|O0n4`Q4!sPAhp~( za(-Uiq2WS~TyiOw#6g>Y8bOj%P9NG!rn*s>y$%)Xl|~*x$TJ;s?V=TD|D2gbgy(rK z@`;VJn!kN!fEAgLk?O7JCFU=Sc?I=tkc&{gvW4T6`IY!mp2gNgDyo7Wbn-X9{^vMV zeHW0z63Y?u;X)moXuqi7Gi{YeJvW2z%8ApbVly}Dk&y(km9ACp*;z2wbWj_Us>#NzJ@jc&4WimoTZyfZwPY4b8-HeSGluc*WTq&E2U*8qU%rwyP z(?<>a`0PFWN2wvJN)y|^$$5c{>Q5&CiYHDda_7W#c8vi`&V3cbKW+oj-3f@ zOdXD=QYiqvXkh{p#IHg_j?2BW^(ijV+w{#%6TxCVa=_vKz_gQgLe3-obH@u8Vr7wx z+E{t%65@@+x1ZR22_2(dUf662_7po0e1p0=_^`U$nY*|8smn%5C?|3K4vUSB6?^GH zuF2d0*2@AvG?T9un{R)1+{oRufK_NNIbo6EH)n3#cldk|P+*~;Y~FZSHNVc_ojufq zL__^WFB?lgb|h%P$V6lTsGXkf1#!*8n8f&TbQ4tMXrmkn28>>@Xe|9`WSh2mEVxLd zgGWrQzWdQyO>vp_$4EI*esZC532JMu?aK;pCz`m^{FhM=Jr-N4Q_|;<*}@J4 zv$M$iv6Td&iruL7;SZ1iG1pk=rSe`8P|wz zpT(Veq?||CpkfD;B5(Fd%mhgwT@e~BXFWi~bb?^8^GT>*YEmp-Ga7eMm^PCcmDGyI-GG%{TLjFIxjlhDBK&_|xPSkfQ> z(nTKrp5UZf(Etv~=wU}oi7;$?hQnh=zHOvoRWVJnnlJ6Gqny#js{X84TZ`id(yRh$(w}y2gi~hQbfjWfualX#;HcQHo z3nDn9^!WTbCxceRuiPM+0K{Jz@o)c@|JRS9f9>tQ-aWhIoy;j7ddv1Rb551u_E+nH z!7_<1^v=o9#|+O1gws?i>wks}X9CDYM61WKSZ{om$;bO5a&sW*^f@%SzZo4U*Hlyu zZvE>74F92`d-}@tmoZ7u{{oxymwosD%ICF{6>9E4h(bm`Pm7BN! zmV2Qmsb}dqZJZ4?HT2d@qn(IMrpr~J*7`< z;Nyz-Qb&sr*SkGX9A-dG2MJQL@&JkoDbQ^P#2Xp9D$@g4L&@H~?e<6}q<2kg?j z-(x-3)A%}IkZfmFoie*EQ0hIA@$>M+q!FE0KZWnMwj8rJjJe0$L;I%IBjB-S4j5nM z0?r>>uW!T%5ea&dEF)}F?00#&fKycvSt6A10ru?M{aL{^$QT2q9{ML#pmY+y%R42c zRBNpKG`@ImR>+?^lI$hu2S*@J^tob^%rvn+Sjb9HBpBHM8x8+a(J1_|Pt0_nuqRi4 zejFE%;Qp>eWEk-AAKNDW`wJt2{{-x21H*gU%StiX4R2LhbldmT^n(<9Y{6UoQY%h1$WEi;qV#DKejb|e z_9?iqxcR+xjfcztouv zSbFSq3X+g@C;Ho5InG5^MtXH)lZ7b4K4X|6qER(YwJ2P3AL21)URBbdc^zE+g#s5-lDkFSMQMsdd0>M115$O&uI$%#XCU zGzt)z^fd9z{yIYe0U^2e?D~iCYO*JhIa`O${G8JU#%erYRz;cZ_jG7ETL-6BfSo=O z!bvXsr|+8TfwhGJUO{iA@eZ=BjTx^S_MEE1<0ZZitBT60blTl=ey3fUIvxjI@lc&F zVxFsx1iEK#wHJ8y3(P3QJmDdz5(hje?Tdav(!6pfCczf@@$}xKee0Ly24p1AG9kCK z=-&Zevm|iM;Mxu6c_5R)u)7>9>0oa$E#>xxYb)5)p(oFTslJMiyK#?!SD?`gAvDua z(q1q))1x=B+$6uDRNexmB>@})KIQ#jl%VLgG(4_w(7 z*nYM1=;iD0^oFimI{T^fFV%$O8!uZnGi;%U#4f`7Oq|6y3uh3{>-sGD9kweo@-bIk zTaPSVha2JCoyyU%Y~w(T=V6ZUb)GV^>pM>af4gpaUaYL1G6O=FrU2;m9TTp6YHp`F zue$|D?%#57k1XSn*TD3DU9f+rasGZqEzOQlFwmb(Y`VlZG$kA3}6NGz@fM8RPM>a9d<4+q>UU$b6{oU z$+Rcf^gMSdz2BR`{QlsxAO}PJA*&f9Vt(XDO4cYdM_wECxk_D6tx$_jlj&HANRLz= z@UkwER+lGzq?Ji5)3THD+`RFW#UASYZ{0KVFfzbP;UmneFLTZ3K9!m5~C1f?YCG=e=NUa>HIe8 zgvxMs`fxVERr#qY?RWbv^X;aw^^f+>;$BHW=d3eQXoj1Y?%Sf=o%+1nZ;~w+oNMvB zatVA9sDeR4`;Ck7O>xu^Ym6WbtoI2X+aFze;Xhpp?)Lpy9;)#YR(&S|4g!&7FFLW- z(XgxSHjz^i=Z(TfP}=05Uh=a&qgXxyhz`REnzDm~i$9razX$jCq7yaxZqbqy>-#aA zJTYq^od4Nd;-&>`Si_3$dm29^3A#nuCE-IIayf8+2|mAQK)qG8gdUB03Fk7rPt=T;lk7$VVv$2acR2!#REN!PPJYZ~ zO%WUYsHzYe+Ij?wd2BfL3DJz4gfzwb1^rJZ=f7xFc$){%iK0dd9;XlpxZ)SiP_`7A z+5@F%c&q)dVQ7>%#}^ijsi{l*@YWJ^pv~YZ_(yl_fR>>av_oS&;fq{p^3cTq#9Qx< zOQ9hI%vl)Li);!=;dWC-b!?#eac1AiLCyF=$T>bwy@t`|q&?%ms+UwW6m|3pRcxX| zj8YtV;l^8f&sRMltJl)9*?GVUX*3{bkq`s_d4idR@zQbgw41q@t`Hz8M@gjTGF8tV z8`dh#8Y+B%H{I2MGs3vvdscQLsIaC%QbV@d(o{%KTb$X&jwB5YcwEuZUv_X$M}8A} zk^}jlHOrZq>OsY&qW@7xfPbwcT;;9q#~ng^F36cHH-!>Iy)IF+bNGbyRsn9ij!!pC z$2_w(?<3c^l5~0=EubD(MjT0qz1a-e=#)zhY(rwBQHA_liA{KUcJx)X+eMZWR*Ed?Ac=9t(1N0aGjjBVm$LUNH#}O~6QRk2>=jEhpeO$Y zrJH)yzWM&qWoxXlC3RKK{B_p4-t<7fAtnVI)%f)7Mx)HZRr4oS;F|hyb1#Kh+$) z`;EJ*J^fP|RmckFf>bn*KW^N>Jnf(3%)Io}QwuePV;#q)Kr8*vC3Bo>&^!MPVk=tD z9Zsk|lyGRAgfy`o5fi)Xe2j0=(l_6`R}AI+X~@##+=QvD=Ft(H&ta&#TOc09cU>oW zf$7mV?0BFSa8aqtuG|?rj5N5d5j>>vg+5F%m|4j z`uZGH^-$1-1E#}MA`I*dXS3l;*{4PVxAIek|A?C+!lv>?q&Jra&)(j z{y4?VY1OL90b&P#C(Cty7amw0^FAy{Jf&PV^)xt)xsaNsBw~^gR^jXep;{pYQZ6T)ItX$vBW3>N^E=|nlwW+VtkRLl1&&Wet9Gs`NlF8L>>xDKyD@3 z-EQ&0m%#Ifx`-N(5z7Hf!WHE^c*mWeWx&7{$OHKn7Aqa(z?Zqky=jOg+?(v>WUp9a zUCR7f-!Hz$g*9}860$v-$77spakJDxS)uI{+dV#oA=+IN%7lPfWPVY3;|C;s>A*|k zs0?8CVC4GMU-gWCqpWGb&{X|b4%s@o{_in(fyfDSmaf9-9}9f_*^K}EQNiKpJ3P^D ziU~hVjKFc&RS;a?-hitF7V}WCZks*DcAYh-A|TR z%)Z-@7mt14Mvc)B&^|Pfe{q1XrOgp}KYg}8Bq3WIIu)#ajZc71i_f^td%$yukPv2F z*VrqROw|tU^xgR-(NlLH&#E4jUz$%Q@y{Bb@nh1?i}V?ux@R}axI}?Iwdy*H%B>s+DCu8p#92*-zB~xWd>*nd5jiaaSE&5 zNePKBpSb>Sqyd`pl2`Np_-el-?C;-F{Bcnh6=9S-SBzE{d!=^E`u+m1+_vm(yp4r4 zyj|^)>-#x(U(McH|32@^yc}(mN9wE>n2Fo5J_)@pT}=2|Gz-+G6xe&#ezrFgTUmbY zwVF59(JWq&0!|vvXkbf|e33TzID2NdRbQ&x^UQBHzCIJQbGGj>s=@i^CE={sf@?l! zd6eWLCs|?N<9(HR@XPXLDYw#mYbd8c^3_2@@^lB$+$Pr3z{OpF1J``PaguAYkOeo( zX}VI&GN?sn{) z2bQFG+)!Ixl2{StmzxUJs4(jzL74P32Jy|3$hm5YDqPgH1Q^j&7Ps5|TSZVqCMYt; zUgH4W9r}+!>As`ql4urA`dnB_U!(`OuO-f7lKF1seI6vm4o@`HY(HI#x8IdqkFvih zCV3DR79!m2=5An3TWpHcZqHoG&U9`W32l=jx@x_3_F!%j?g7;l1*@-RXKEv_g((Pz zm3&(N42h&WCp@tQ#7(|S(CRAJHh30~vIY-ia+^HhPsehcV)S(8RCHVvHrQ~a5HC;t zenoy$aCBnBE+^`sC^w4$Ss{H{t|mmmkB5i(h#7*kgrovVCQ-Y=_pm?76ET)KF@4XB`hxmr)E8{y31Xp>Q$pv|L1)7jlKI?+*qW-eE4AHfWN5kN@44=?399{+ z;(w9r4T|4OK!pX6}v=-jyV0@`~<2ar5O zTEIrlqaMKt?fVr@c9A5yc>BD1SLL}e zwSBr<;g>(wz{mG%VOG(0nv>ER?7#6PjvwJDk>Ia7aBaA zbt~B+e7y&5xu2txtpy<#r!_Zp&SeLiyEKWQIIr8R;OR2)#1G;Vff;82{fKXP_<+85 zL3tm-YVPu%XgdaQOvjTu+oApECl=aI&#_{n*Hl-X%5jTpHzcXmX@n<&!i@rd;1O_I zHBekoNJJkM)t&6Gjju`2QT8^TKpo6L5l2qr{B2NHg-cKQFcrlnd{de9nZpmk0gQ{| zNF^mlBeirIahZ)l9=5;$97E?xhl=55)nm6jj{_#oyn+bej*=}OpLCLVWb?b9?#c5< zsMa{`au&3g-??MpK1ly2Qa;Zib>b7fXD$zM6Q)sl2=}eu%vw166hbf{RFagfm-^em z!lsh~_D&5byQ?1={Hx73U+3_ESjz4*W9FF@6<|e4uZ1s2?s^kb*AJc82*}IRaR0qT zQ^IoGbhLfb4`1F;@dd$cgPrnQCdKnu1$Fbxf(34(YLxk=;2+0lDjx6b=Fg&9dL`Lp z>MGh%Q`v(52|uKa)1oxXxknfm*i*j5Dyuegj10u)d}(RP*cKvbBoY$_hX{hTJsvlQ zupbe0I=8edb5~{OcCPf68gZBAuwq(mkxMuWW&%B|7K!=oIqk#QzS$E)?oxp%39Q9( zfL;rtHP_G1@=u1xLMnKBmTHun7B4nCls4Q>NWv~n;^M7;U=ZQqJIl)~v;uStYp!>- zt4GQK3u5MvN8#tg79F6wvT@~;K;^(mqc_u(>!QyQLcl+1T(V$bC=8p}B;Az6k1m88 z3$2lXK>S2?r%S=>x%lCWajXIARwBrZZ?e0LSjSC57OQdAFufD%;kRO#YVyQcV?@en z_8HEfoXHi21RQMRnCL_aBO7=DecrnpJv`X_xApF8gkBc&^95C3jd0FV1k*Sd`R>_4 zCltmvNMawqbbWaT!&&Oh8~E*J@?8jH!=Isl;+ufQ=(AM~C2XwO2^4ml|HL&GFrAh& zg@x!7sI~*}M%LUC+Y(g|_FqewhcZvQ^Bp^$^TyNmOWUI)=)mOpV?8tKp$XE0J9sf6!n({cIibbX~eX?86 zAQnHqW1P}ir8s%D#afr@c=u~`BsfOpkKW$MFA!a!Mp^W3wW0I$&GAOc?7bxTkD2xF z(=*kuO4LeI<1?O``0K>GK>gm15p$-F@y9?JQK1LS8hrxSvfJ}%x+b8i)*qv=3kMCX zd)Vo)-RlkbLZQixkGTWfd#khl)qdA$0Hg#_=1CUK!jUCO4-4YtMSJO>LkR-1jy`-b z=)e()&!N$y^~Z%}JTJf)?~(~9k6ME_!6VuR6V4sxY$op=9l44|33_8*GDO5J-qN&i zRi91UT2TU5I73OmM%X&rMf4jB`{pWbJjqi(J$bp{NjQD^_;9KnuY)hKx0V0dG1mK2 zQ?2+_(^W3S0?~9~xCWn|umvu(U%s|3JYRr7B`_BA3jOk3*72lrtW9d${YY{F6@2F`4BExLrKRmFlx=|H1kZ>iO~( z@#sZYJuY*lKjd0s>@DpEr(TW>P;e+aL9Ln<$Xw6|RPQ84C!k^>Y->Ef-%tA8?rb*5 z3+9pXtP8NMNLp5j@7vki{jOn}PQV*pk3`Iu^gD(B2GTX%GDQa;+!X43nX%Op@v;>&5mr5wS@_YzNxysU0T_f>r>XmDo*BRbDaQYA#%}bD^JEn12ymm&x&V6zcKbb)~%XZx&trDsP=#F?x;Pt z3SK{yOEgPNz&lvri^U)j6RyN6EpK&`pJaWy#dQTnRv9lFuYgB8SgelV1qGgAjGtEb zQl<^^3hEyAh+Y!yk(bZHQ>(_cm_H4$ngf`{lszT;VU$mirF%XCo@$;v0JhLb)86S* zA-mX#6~XHx7e-;tJB_p#$OSrwT%13*S?lsMIi51zTMOH)U$*oRpyZX#X;x6eZi z_fuv9yo~;LpzqMp%=`ei)nueD?%1`>J2cFVtd9-9`V6&EVVeA%e0tz*p@^w;)A`U< z6h7-Z_Y^p^_)Hs{u?YLxWY|uJ|IRFkc>9OT-bKr5g?%A9}EGhMTPJ ze2U5hnv#P2kZ9>j!HV>WYVR0@OI6ZQ)6|))*CBR=w{ZF#PSpwgG^N49mRJ1jQ6+Jk zbjDyAWiur}`ChCjbxW-iFmTZK(tm4oYsRRF*naq;o`B6j4}MLgasg1czM8MxEdC+_D$98@T=n9N>+>FQ5&@OkT3 zef(~6fYA1>T;T%vu;J=}SODEaF$p&xs{TXkA=2?l4>DH!pW;)lB*<*?${AT5#kaKC z*w)mroArfA1td6R3%*Hw5xl>@-`U5p;rtj@x#9Km9dn7`ZyrLNjM^vFx%hr+tNtI+ zR@`HdEGICm(J5p=&Ir_v??9f2w&eIJwgtP!Sf-yscJ9Aq3<|9Nb3c(*`hAJ`l5Nxx z)%kWX59M;~2*N2}urstd_ftc_b=ptt79lC!mF@xOsY?XyJmnAQYzd~0{y<<)A~F|7 zlLWU@$YBi*NaYawCZjk@^Tjo3u_T6U1RtlC!0#IOvmGCX^%U7?Z>YG#3EI@H7 zNh~vz&a+hk*V<(VLbFAL5(qjoK{`k8@k41hHr8ULo6f%^C|T+{LW)F_`pGQy$W-$r zxt$kv^l+!yaI6ae=l;^Z^aN?yZ{UuwU*lJJ>`5s50&nACjN85k3Llx?@A+}0o9*KajYY2$f~U9n)>XwP3Rm`?b&|Jnai zup5($XvJHcN6i;G{5G9>(B|=qkoQg4$A?js?jEqZ-Fd{N3Txx8vcg02bj3jIHG)++ zyiV5%g4=QMhtg{Lh;r@z6nEnkBPF+Up;Hb!ByZW{Bcc@37=Q zyu*VL$@hzj3XXE7q%z^QY>uT4jjJA&(bA32TRI#2VeEa?7dm&)iI{q z+mr>Ss=T*G0mV5F-`%Pzmm4~p98|~azz>+1=~I16{Kzu18u&0RJoXOZ`n(bw;2t`06C6zv1q?A>9@h{`@n9zlSDA{+>sTif&4ZQ{k{hV`p zN^{BN)Mn55?qrR~_voJ5M3 z1t4%{xlUAjERK3R_3BW8jDN;-$Ha)#kNWlplmXiFoqBjuODiqU_RUAZ0T?lu5&y%k0 zMCSKl-AmdZk<{X5JHp>FJ0=ON|rrvaCGpL$>0DAlB9y>BM_SIDD`J@1;wkjuJ#aZ=lawB%9_eeN1r(# z&>CFTPWcd_J$kW#+YLQ7qgoxb+!CK&5L$HJScE=UyYJbn=WyX^9;svM{JS6m;>;3? zgY&N81v{JL!^^W2K)SNwEL#k>hS)RYThEgM#882XU@LWLRV~v4Be5E=rqb<-UsPiN zG&<)LcwCI$9Cik2|^+>$sSaJTT zV>dFtVE>Ow0#izF)Gy+~A28%ZYvc7yHC1&phc4iO&O$1Wv7;*FUJIvq&$JSY`^D|2 z*vuy|;Y|XV-r)WzSOgZo>3hofJR}3R0`j1wF(AefV>s{Opz6B67(X4irkB`Ha=j57 zNAb9v^I+teG_~(SbOwE4lYaV#7NBEqx}&C|$&A!>&CPcehFf*6Zuv|@b-v=tLe;q7 zA&Zawx(63S@^M(+#(<&1BW*H2lc!~5e67HxJE6T7vBs5yNGSZF5!vG5K73=8XW0L; z_`~f-gak_iB=yee$W^hPfK#<=@*JI#8GU zLSy*Xx2%OOnqtFEIh;__hqlBr z`wU#u$A;=1@J7hY7;DG?Y4^uNoLSZJId|M7XOj8(yBzT$X>*aNioZpEmOCf01Rza? zy5Y`9xVMT5j@CewtiTgnPR-g)J~!-3Wp`BHYkNWIGW$FmSw&mN%ZJF@Y;M9;_`UIJ z{RVUHlkkC_P3vDggr|ZU*Il+MmoxOEG>?n*FX#^&!K3OANRetUk=F%ulNtv?DSHw# zgQCw>ZFc~B<mS4!$wZ|G z$~`F97<~=0h$*Lu!=p3aRMkJ7b8Hx2FQCn%YN#X~K}y19x5A2Do%Uknwv7Ouw$k>t ziTmU&A0UJWlUClnu>uH+SG_0S(TDelreVoC8MXvtSIl8XC%9#pA#-O+`cFvl^X&@4 z5--XAycErs@Afs95QvwZ>4pC~7D(eraU}Bqk6-I%m^XEaO@BWG_ZUoD2xltK^B!EqT^(>F$SA*VeS2 zt9RwM6a8xZaXqg{!a@;r}Oj;BTSBvc1wS??&!i!rk$@l8&Yv!-;kSeLF?n|~TJ-u5V+>3STWT~of zJ24_3EmxF+?7M(VP~rg0Y}-wL{%wc#l%v@iZqqoCx3w<<5xid8sk z@&qfWM_lu@;zP%?`EWC@Bi%3u_D-?N_>-?tE`@>-7h8E~*)aNTbq;%*j5{rL+l<%b z1e_eqk-FfIE5A|qjQu?rg^NCIl@_M;K2$N7m!gTw=|H#~t77d%Z=s8&f<=oPeVw~v zWtCG;zcT;m(Nw~SNHDsoSbep#oQwW}W5Qmi?tCRzB<3PfVKKDWh#;n$Tk9l!o=OTG zBui>P*9KhF)zZgW*S{Que&^ZeiB^cFjESju_QgYjtqlm6GlVyL`?%&2pOaE%O0s%d z($I0-0KVC-=hbc?S;Li#+#F36h>Gdy*ax(5$!-HfcM+uRayr0Jbmv_I9zy zTjkR2+p5!SS8XxJGa#F$<4_-;WzH{i-juTa`1}_|JEFNybuR)!p4xG|boB`}MG;z? zx_5E=F^XwYmQ6Uin{678`ZVu(Vc5%haJ}+5<_em=Hn&TM6G=t-kP(WvPwft7WOHqA z9(o5hnIbFk(ZcMB*SmHLv+yap}_0nG+J3=;k_#d$x{hU7?=& zPsTfNVFz#+;t90PZ@;Hb4dpv9?h-j>hWqMxIdafvZ?r@f?1jNmAJZq&F6;$U& zbzjh#m}t;2{i@6@9)mB13V~94Y}cjZmeY{5k?M3Tf1y5zheB68K_U`>pZ;O5Ff=mQ zOUx1)nD4i34A7|jX;qdxJXh^fo$6kP7(yI76t=i>l{w_MDVnZYuA0DR(E($rmR>QB zYV}S4T);ps%GYy7_U%-Zj-cRfAiLLdu*IrlU|`=)+Ud!ZILPFzZoEUTV*kOArz_bu zu4exS>6tF8o-^G6aySY50SKQtnL_dLdwQ+!$(~M;6FUAHj_b3aB!0*cLnWI4e;Bc( zL@GzbdzV-=;Z(Nd{6*8kbMEw99sKGv9A#80=N^KzgFkAK(Y8t0**!n`V`hai{gs7j z4hI~oz@HyOgRh`*F19Lgpzu-DX=t=94M#HAi<`lx8eLYSZfB^?y+aH*eDwVl6q`A9 zrF{Eh-&}wV`3d;+s^qHpLbwm3lR*c1d}W`!eZ?5{6uN+VTw+w=Mh-J?>=25^BU4N` z(pE2A$2q}lRxd42?F9A?30nIfA2r@D=}(HJFxr(O%^KI&82)B+d)&mqt*MP^t$im; zyfgtCEheZQS6UZJczKcmq|&PJfYv4!;botZI78Y8N3Xag_Qpi9iP%h>rv&qOd4V{dV_$v$L} zhJ_Ii6;@%WfZQ;@oP)hB4mBes9TT^w<^d1C#=dE%_!e&wU~HGG&&gOmuBsXD<051V zWa@GZ++Pk|pzLF_d9)h=^76{G1M2W4r7V(M?>Do4?@3*7+4&AP-|!sazfMgXbb70| zV&fj1ZorIy-#q;HUR-cor+Z&hn{+hgxpgysJpOzn;NHicHXpioo!yvgSqVS&ThD2|vM#x}j1s6qwThza0S;I5=sdUs*yLJ1y z+EQ;h-G*vz5kYc;99#Bc=P3btM}xz>;+G<(TLJ%o6;&PQ=gGs#sg|mhttAc{SJm;f zoM!%t_coESI)|M2W|ypW37H(=%(-WRGKapemOm+HoA9X$p1f!j$+)XIa%g_h+y(eg zOW}N8CutqOO3<#xAU+C>QJ!pMD#Mnt#7&Yhhrl5A5bKBXo@vFA5cC5C- zcPd+oo8KM80fj=={-upYU8+fG`l?K`2H2GSHobwW-vMWpyNhu6X*QB|*u|^k2}~zx zIZsEsA_*;Hu3@%#!RAlg)f0SC7nPJ*}6Cscd&kAOej(F1NkK34I*b8(vS!(g)IY&yUr0 zfWB0(4AB#1K)Ju9=0}X5WkwOVJkNEOT&nZ9#WT(@Y=A3fpSH6A#$p9cO<(lishtUX zNqGGGEX3((Yj!7^=R(&w6VYb4<59mjD`?k5`pUN^lhG_5LZY?Yq2vLxG9=Zj2PKv| zNch4hF)ID$?aZ=BeT+2t_pyzfcU6NV|QzHbMRO)v0=*K%U@y)PLWx!XEw$ZNvJRR$sg`)gKe6GeNrPx8F6%KTmU12}H!hJAEy z=$H8}v2B+n`Jut|Z0Qf zdO*};l8_pig{|cDLxts4W-}7{G;&xZs8?%ALy5*%&WLTlOH9RLc?2|y&;ON*#q&FA zwPRYIl6@V$z;hN^&|Dq37tk4#ESgmZ(hd>(AS^06UDAWxIn9(%r%I`7v;$qD!o4Ie zOoCW+JZ^WKU22}N3t0f|%T?ncF9z+8B#6vJY9rbx@r_OpWx8%n!E^_2x?+Eqh*(2= z_Rsy;6n8v0WDS0zz-w2jyKyKYF;??G2P8c!Fq0~d?OjXR_*Cl!V{m2OTisFz`D+tC zk4n`5vs8}*Y1MJ-J;L4I*EBZmofMbZ;8I_+=do&)j$ouL1f6H}9m=FG#Lr$^2(vFc zxAW_6`qNC~xj3!%4K5(PGZz*#@Jnd z6GM)}!h}4BA#mzzsMKv1^kh}fS)1SNqy@>h!z0-aJh5k-(sdJ^d+2G% z1Ff_QXYbS2t0Kw@Xw^iOG|q+WHMkRp<84?hMALpS5; z0Uj^DOJxF^>H9`E7G{wwAKA)ca?G_ia}dKh=3)9P0W#8$H(J-?1F#`%kaYA&3e?wa zxem3zWXLmrbF3(DCy8Tz$9vr5VTGZLFDbOmj7071eE!?UDPE+hmyJW*5WB$*sj+ zxm$=TEKFV=32(V}f?^tv7>}(M*4A2n7%t1#HN>y*lOmwZ{#(yxpDz!xT7dg(JE}}h zEEm}qK_;djiw{S9ge9%9%b)xjR|kXgK76gs`Y{0NN=;7UBdDG^DzrYVl5QX)YV&>g zd{1+6cJ~(}^-2h3GX%z0@4@6clJy1t`b9jmzi;QU8UEp`8#F5x<6rF3%9dqgV(4G= zQX}&J1^m)KnJPyP%@>~5KPB@{ri=2U4b7~w%^1h@kT3lRA)2`Ue@`^6Jik$d&dIpr zDAAXuKJ_U7{x@9%X&lpZ_-QPlE2X{Vzu1=YjDmk{LvS~=KB3#O_S{~?_!s~g?8yws zg8tu1yUMUAx3w)IAX17TU7|D$-7Q^1cO%^}z#UGr#7#rr!0g=UMB%@8_OpaYNWwc6#@qt3#&zfu>QTV`N?8$Gp*l zu9fu7e3r#$^0T!fiL5tR|Lqwv+a~J#)zXsL6uC5!L?`@irOw;|0Rh~sKX)OY0QC0- z8@1rzf7fgJUOq_c8{i}0>4}l@izNsaF8(mn7vg&yYoQ+J7Vv!=VE&O)08L#O3|@EhF?wK@-o0beb)Jbbb#t@XSSeTjxz zGKPn~FuoOk7GiP0&)tOIq+mM{gJFtPX>5Y>=fAXtHBdVlA5FnR{;oBH!-T$Q9O}SE zAW#6av({<1^(rJWK5sUQQhsm`6p%tGLcPCWLa9=L0J)}>rPOwHadeiwEjnW*)eVR_ z;iv98F{&`7Vj~8~sgVUU@1TEijex_@wmj5>UaRbO(fP;u?Lndp9q>bbW3d>WsOc>E z5+c*C%f=kfaWQA(XD@Wz>*2f8USBGS3*+^1SHgM&1Q;01y2ILTbXndTB9hx+RQboC;=!Mk>nWD*|55<0xaj3vp zmQK&UH)QC(D-+7K;}3rTfKq%9slWS)Jc>S@ev^y!=)q4!dqHVQOCHmVeoTp_5R%|3 zCP^lBaj1c#jzxK4FnZ#M|5tI&ktVvF1dS+hk*lJnpY*2qs3$Ur>1+*9x|qDb2C5Fa zp4vLwfd`KZOjqoFrt$qTxy%2Xi_?Fawe(n`^Gm0~rYe4K@9VHydZW1(##XK)pWq2A zL8J}A$Bl!1p|38CQG?Ht0HnZ|IkEE-5gGF}QKOI3k`)EDY;8>{*b0r-jhAm0m^6h- z5CujizWP^=b;olF*%^yVli$loAh=9`Y-JLPEx0Fx%JkXh^woTdEtncY%W5J^ej=}WlnSX7P*VaXm0RXPU!5$kykcbw25xXNa&no&^&+G|Grl!DN<`BLJ;8$ZQLgZV_P)Zmn1`MZ z#)l)!b5`&54|}GbD^UCI_!gWvW#;Gt0{iF9T=Fj?8zBy?g+&da9_jPqAQo{MV0ce+ zTZ&e%_?BG~am7I~o53OP==OD=(W}EMsD}3;`WGAC#Zx(322KZt2&?Ru)^o10dcu>!yrl4VMUo0g2cj3b-SDYRE zsPjWn?g67f_H}7-NKCSUuqf`j{S2T<<3bKu#uu@j-WnzGqtDI|;TzFV?DX7?5Qov% z-|SqqvG`^jA_#WWI9zCfOYRg{(}}tXZzK(E3cbXzan&nzb$zbL zoJKdd$DRCpM$KzoJ@4>7B7YPV*ZjdJ@Pxs&?To?oYLDu8Q_@X_iNUr6YEWFNxieP* z$Qo|e72Ww-!RVkvtV>)3$p2_8uK>Q^lVrwANJt&oHX!Ybo`baQgwY&cVm&n))NR4u zw(ok~y=ho9g~4qx?XU^XUN=K{$9qNPDrM?%!sQ6)XA#HydFO4D`hvROhPLD>TzRHr zb>(%espOza*7n%XpFdAXNO137iKr;dr3fx?SWm`mz4|Ut**xG;;CfROq(ULYuY!GH z5rzH(PP%19TW*GYD1OJ;Y$n85w+Z5EfNH${&KZWxGVl4=mN94a4o1N6bV{Lr2Rz|{ zlO~q|n$=QD5#tIn54fAE7DY52=eNe@mnD-z)|4tB5Q5dgOT2h4*?sJD_oTaid;Pn8wlVi-HJBf+xQ0v~MtN;fl(NIz zt4D^hivEp_v5dWW&J!hF!h;fH|CQnsQRLO$ReQ^Rx@;+<(0G-pWLtN?Nd|9gFR>Qr z+z9d;HV!}~bz}^lu872A9IAi}MXntKP5K)YrWZIn(LpawJvQTv@xGpwwbc7!4{nNe zr5VV5AE*vpzTgmvPjk(OTAZElw?Nr#c1p3pPLQzkLrTK>_Q4UW;d*{eW}ypl1nN{o zQELof_xB?9!Kbg0uXgQx{XS$>8UVe)rK?U^7aS{nE9-jKL$MF&r8)vQcOoN=kM21q z`=u>x`XMEddTfc{>A1KLS6a#0HXX7ksmO&KUhy2L&2i* z-{3u5AlS%o@?a4W^+M;!Yg7~1fx;APb@f`M=<A3x}zgr$Z#4kihgpj=cMGj!62tU)+le@{E6JG2j zAK_qZf_Q8KAiZ#Y{EXLI+-$PJuD8^nsL2|T`E01WIG>19a| z$_hFO7(J-@#$se@&}(1fy?A+tG_M_Ak#+ELAFCVJ2qdv8?#)KlJKJP0P^?3qvm)`! z_x1UK`O%%C1gcZ|ih#5zs4opY^?G6<;}|sl%=Mo|>jBZ8!;Qg`gE=I{6=-%s({{Ok z^zd-PPaN!p?q0XKm&^Ea4=E}D2#o_=bTo5Mp_B^Dv%Ug=; zPHi=s^KDA;BN-sPnH1zv!1>YHSy_2kS^h&oFTBy=BU<;~kX=EyppTXSx#17iZo~E? z8+>Xs>6l`DIF3CY-%38r9nQIPz=BhLk6nVzL>1?)v1T1PWmRl7D>S2fNq8Y7`B?N@ zVtsuudZ$a_Y(Lv$^z9%y9!3UAfa6mUiTR$ZnkVNfrbD}JvXnr!4t&8<>kaD+#;aY~ zU6h@TO{{;sHasa-x$Kx*)_^%fm8rwi?jBxY-NEY8nN;ky^XyeL(B|kec)LQRR~Cy`zgnUC zPSes+D)iBKu8yIXcz@VgPQ`PF#_(Lu#ICMze67t-A2Su#27G$C3r;MK6N{KkHDu%k z6}~2ft2(wjcgi~&_>6oAKYD3wR<_etXBJ37AG_YOmfo0NFCnh<9`l(^9_A$hPOtny zKL*L*Z2)L(z}&Psh>4-^fm^HZc^X`YIG>)Md`?SOlB+7?3T3vr@E@L4Qcl17G-q1f z&;h=?9};pmM>j=lZ5lj1v zygNBMR#j70hpl|Q2B;`)An6NzPM)-GbV_T^%+oVuGe>DQBy86Jg0SyjrB6N~Rv%-2 z(598OULS8rACfl-%|{rztV2!I7>doYc|t<0R0hmf4wyu7qGS9U&wMhz0&Tr&vlfRa zY+WUh6x>4b>Kz}sthVc~?_bKvS^_Txc3j%uT*%e6!ui7|z=-E%0isj9cnLV)-KK1_-IL; zBAS6#z=})p{l(AXmjgzJQSrYUizzoUgd)COaYaV6LHB8~n6H)gd$dn}EezE;78zQ7 zc2d?L8q+3=x^Wn}JWPGiE7|uBOP_SI;-|Ub_o5*nEnNvdAW$Omjv3C3uLRX*z~__(|;LqbU{o09|2T9b{`t z=wvluhG2>~p;x)(lRrSF9k>)?k>(XHp!D=P@3LqZ%x?${4J;sF^pk=1vrK>vu~*!U z|0$G0T8>R4_k?M4NrIGMQhX$N+Uh>(NX8=u4k~7cCO%bk5@4^z;c2yPuebqUtF!VP+25M~YXFhvnhZ_yEXM8W9olFc zz%6A#$&nvz%v@ScVhpAIjp?c)uq?$IBSt*)v7mZaZy0;P>J;s|M9^+=#3WK zJe_z8F&_GelU4oCZomI*fGzNy^U>A!X01KSgAmKM>BL8<3+@sdb{kasg2C;7F4)4; zjzTx=^LWfMz}bo9)2o%oEkAz)m^54!=s371UhPUJjb8 zTn14U22s(dZK8(nl1mBe3ko}rdP;k{>1G4!`k_?N>B=HzVbwdv;|idtr(6RqD7Kw$NeDS%TNAc+}~g%6UUBHW{z*Z$od7lLPo35iI}6{fhqTf)z&$0$43h1Xh-A^IgT7%c2jxNID#X zS``bog{bbJyn(4b7xLM1#r~Ne08^`dsKx*@*)J*(qY3hsKSh4iWf$^ZmD{l9O}y_Y zM6=;Xu{4$9#1kkCLH}QVaj`=-RZMujGMu2Nk!jSAf4KTk6D}C zHNqZSdtDHlxE8QwN|}#v@OSAo>K6npz3j?iVwV`_6~X(3PjU>^2(S?`!W4to)4YDm zrOeu|th}<3dr3K3>R~V3+z}@mmtUnCuxY1 zP~&F#EZf@K1NSyzn^rt3wH;xGg{^$7e0=0KHP{%Ee?XQRRlX<6Vhj=zqC`dRGqky^ z*381VnDl7SWKKYBBs}n9;Qh`q!@txslO&kwRotic1tkb;vS-O(dP4MEwspShX$+m7 zrBx*+)lsvSK_)aQHcefwUfqzgweqcVoz)p!a-~Uj*Ll~E_T)^$2^@hHA{hW>n(CPA zlRzA_D998$x_&sBbxEhZ+2gj- zS=AFelP)J!$aJda8@;UNz^;GerdYf@xlPx_k>PrZ33Wb6dm2R|Su|BIq+JHmy7+nT z=@wRD1NX~Ez@f~6DYQb9_D>&lBc2Q33>S4OUHBd` zo;qlelEgEYt*k95D8os!?KD)Zu{EX9lA&Xv=goXZ8ojniCs=h=UgFNP%8=lI(IUKRR6P{nXRQx*~T|`s4tS#FuQNZ2{DWZ zOp9`Wn->hHDl{}^VOjw@8Q3;+?E{#E8=_v!@$>S+Do(j=zGy?vrY)u~$hZ+woA}l4 zYw= z7QXZW4Z8WWtoI3Lrp%*m<#Lm)I-cpQ0eo3|UTMUF0 z{Uyyo$Etr?O^#uzqG2&f@LoEqXSdaT9%9e6^+2SrpXxg3(?sz2hYLnvS2Ux|?){)v zP)aa_o1X!aQUyI25|Wf2M6y-{WKex0`)F`MD(=i*Q>gk`N=BtH_fu=(1%cj8I_w$Ts3k9Zv~E^7X@9Fj1^JsN gf8Y22H;}+JjT}#~Ys^?K@(${uD61w@E^Qw4f7?jyE&u=k literal 0 HcmV?d00001 diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 24d1065fe..47fb226fa 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -126,6 +126,16 @@ Details: utPLSQL comes with a set of build-in coverage reporters. [Code coverage](coverage.md) section describes in details how to use configure and use code coverage. +## TAP Reporter + +The `ut_tap_reporter` produces output compatible with the [Test Anything Protocol](https://testanything.org) (Version 14). TAP output can be consumed by a TAP consumer that can aggregate results from testsuites across different programming languages while maintaining good readability for humans. + +![tap_output_no_color](../images/tap_reporter_no_color.png) + +If you use a compatible terminal, you can also have a colored result. Only top level `not ok`-results will be colored: + +![tap_colored_output](../images/tap_reporter_colored.png) + ## Debug reporter The `ut_debug_reporter` provides a highly verbose output containing thorough details about framework and test execution. From 8de19cc8c29b8bf1653a69c11386b48b39b0a406 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 14:40:03 +0200 Subject: [PATCH 498/887] Small refresh of project setup scripts and documentation. --- CONTRIBUTING.md | 27 +++++++++++++-------------- development/template.env.sh | 10 +++++----- readme.md | 4 ++-- test/install_and_run_tests.sh | 6 ++++-- 4 files changed, 24 insertions(+), 23 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 41a86ecdd..926f0df80 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -57,7 +57,7 @@ To get started with development, follow the below steps. _If you're using Windows, run the shell scripts using `GIT bash` - Windows-based bash command line._ -**Caution**: If you are using jetBrains DataGrip, don't use the ingegrated console to run the shell scripts (not even with GIT bash configured). It might disconnect from oracle randomly during script-run. +**Caution**: If you are using jetBrains DataGrip, don't use the integrated console to run the shell scripts (not even with GIT bash configured). It might disconnect from oracle randomly during script-run. ### Clone your fork of utPLSQL git repository @@ -94,13 +94,13 @@ export ORACLE_PWD=oracle # Adjust your local SYS password The below script is fetching latest release version from utPLSQL repository. Latest release version is used for self-testing. ```bash -development/refresh_sources.sh +./development/refresh_sources.sh ``` ### Setup local database for utPLSQL development ```bash -development/install.sh +./development/install.sh ``` ### That's it @@ -135,9 +135,9 @@ Whenever a new version of utPLSQL or a new version of utPLSQL-cli is available, utPLSQL v3 unit tests are located in the `test` directory -Before you push any changes and create a pull request to the utPLSQL project repository, make sure that all of the tests are executing successfully in your local environment. +Before you push any changes and create a pull request to the utPLSQL project repository, make sure that all the tests are executing successfully in your local environment. -Every new functionality needs to be documented by unit tests that cover both happy-path scenarios as well as edge-cases and exception paths. +Every new functionality needs to be documented by unit tests that cover happy-path scenarios as well as edge-cases and exception paths. > **Important notice:** > We do our best to keep utPLSQL covered with unit tests. @@ -145,8 +145,8 @@ Every new functionality needs to be documented by unit tests that cover both hap To run a full suite of unit tests execute: ```bash -development/env.sh -test/install_and_run_tests.sh +. ./development/env.sh +./test/install_and_run_tests.sh ``` You can review the results of tests as well as see information about code coverage in `./coverage.html` file. @@ -189,18 +189,17 @@ docker build --force-rm --no-cache --squash -t oracle/db-prebuilt . Travis will use your Docker Hub credentials to pull the private images, and the following secure environment variables must be defined. -Variable | Description ----------|------------ -**DOCKER_USER**
    **DOCKER_PASSWORD** | _Your Docker Hub website credentials. They will be used to pull the private database images._ +| Variable | Description | +|------------------------------------------|-----------------------------------------------------------------------------------------------| +| **DOCKER_USER**
    **DOCKER_PASSWORD** | _Your Docker Hub website credentials. They will be used to pull the private database images._ | ### SQLCL Our build configuration uses SQLCL to run the scripts, and you need to configure a few additional secure environment variables. After the first build, the downloaded file will be cached. -Variable | Description ----------|------------ -**ORACLE_OTN_USER
    ORACLE_OTN_PASSWORD** | _Your Oracle website credentials. They will be used to download SQLCL._ - +| Variable | Description | +|----------------------------------------------|-------------------------------------------------------------------------| +| **ORACLE_OTN_USER
    ORACLE_OTN_PASSWORD** | _Your Oracle website credentials. They will be used to download SQLCL._ | ## New to GIT diff --git a/development/template.env.sh b/development/template.env.sh index 7761a70c4..fdbed4b6b 100755 --- a/development/template.env.sh +++ b/development/template.env.sh @@ -1,10 +1,10 @@ #!/bin/bash -export SQLCLI=sql # For sqlcl client -#export SQLCLI=sqlplus # For sqlplus client -export CONNECTION_STR=127.0.0.1:1521/xe ORACLE_VERSION=11g-r2-xe# Adjust the connect string -export ORACLE_PWD=oracle # Adjust your local SYS password -export UTPLSQL_CLI_VERSION="3.1.6" +export SQLCLI=sql # For sqlcl client +#export SQLCLI=sqlplus # For sqlplus client +export CONNECTION_STR=127.0.0.1:1521/xe # Adjust the connect string +export ORACLE_PWD=oracle # Adjust your local SYS password +export UTPLSQL_CLI_VERSION="v3.1.8" export SELFTESTING_BRANCH=develop export UTPLSQL_DIR="utPLSQL_latest_release" diff --git a/readme.md b/readme.md index 141c68ffe..3c2d7fb3a 100644 --- a/readme.md +++ b/readme.md @@ -9,8 +9,8 @@ [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) [![build](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml/badge.svg)](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml) -[![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=sqale_rating)](https://sonarcloud.io/summary/new_code?id=utPLSQL) -[![Coverage](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL&metric=coverage)](https://sonarcloud.io/summary/new_code?id=utPLSQL) +[![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL_utPLSQL&metric=sqale_rating)](https://sonarcloud.io/summary/new_code?id=utPLSQL) +[![Coverage](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL_utPLSQL&metric=coverage)](https://sonarcloud.io/summary/new_code?id=utPLSQL_utPLSQL) ---------- utPLSQL version 3 is a complete rewrite of utPLSQL v2 from scratch. diff --git a/test/install_and_run_tests.sh b/test/install_and_run_tests.sh index 04f51fb3c..1719f137a 100755 --- a/test/install_and_run_tests.sh +++ b/test/install_and_run_tests.sh @@ -1,9 +1,11 @@ #!/bin/bash set -ev +. ./development/env.sh + #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" cd test -time . ./${DIR}/install_tests.sh -time . ./${DIR}/run_tests.sh +time . ./install_tests.sh +time . ./run_tests.sh From 5d2faaf80bd352bbabe2bd7ca6fd4b829004c1bc Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 12:47:04 +0000 Subject: [PATCH 499/887] Removing old builds from build workflow --- .github/workflows/build.yml | 36 ++++++++---------------------------- 1 file changed, 8 insertions(+), 28 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c2fe3971e..8ddfbd584 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -28,41 +28,21 @@ jobs: matrix: include: - id: 1 - db_version_name: '11XE' - oracle-sid: 'XE' - oracle-version: "gvenzl/oracle-xe:11-full" - oracle-base: '/u01/app/oracle' - - id: 2 - db_version_name: '12.1EE' + db_version_name: '19se' oracle-sid: 'ORCLCDB' - oracle-version: "utplsqlv3/oracledb:12c-r1-ee-small" - oracle-base: '/opt/oracle' -# - id: 3 -# db_version_name: '12.2se' -# oracle-sid: 'ORCLCDB' -# oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" -# oracle-base: '/opt/oracle' - - id: 4 - db_version_name: '18XE' - oracle-sid: 'XE' - oracle-version: "gvenzl/oracle-xe:18-slim" + oracle-version: "utplsqlv3/oracledb:19c-se2-small" oracle-base: '/opt/oracle' -# TODO - need to add healthcheck.sh into our containers -# - id: 5 -# db_version_name: '19se' -# oracle-sid: 'ORCLCDB' -# oracle-version: "utplsqlv3/oracledb:19c-se2-small" -# oracle-base: '/opt/oracle' - - id: 6 + - id: 2 db_version_name: '21XE' oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:21-slim" oracle-base: '/opt/oracle' - - id: 7 + - id: 3 db_version_name: '23free' oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23-slim" oracle-base: '/opt/oracle' +# TODO - need to add healthcheck.sh into our containers services: html_checker: @@ -124,17 +104,17 @@ jobs: run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh - name: Check code style - if: ${{ matrix.id == 1 }} + if: ${{ matrix.db_version_name == '21XE' }} id: check-coding-style run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint "$SQLCLI" ${DOCKER_ENV} ${ORACLE_VERSION} $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @development/utplsql_style_check.sql - name: Validate utPLSQL uninstall - if: ${{ matrix.id == 1 }} + if: ${{ matrix.db_version_name == '21XE' }} id: validate-uninstall run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/uninstall_validate_utplsql.sh - name: Reinstall utPLSQL - if: ${{ matrix.id == 1 }} + if: ${{ matrix.db_version_name == '21XE' }} id: reinstall-utplsql run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh From 098aca2ad405f34e1f8da4908543e6b1d97c4e4f Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 13:06:20 +0000 Subject: [PATCH 500/887] Improvments --- .github/workflows/build.yml | 50 ++++++++++++++++++++++++++--------- .github/workflows/release.yml | 16 ++++++++--- 2 files changed, 50 insertions(+), 16 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8ddfbd584..270249b7a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -17,6 +17,7 @@ jobs: build: name: Build and test on ${{matrix.db_version_name}} DB runs-on: ubuntu-latest + timeout-minutes: 90 env: ORACLE_VERSION: ${{matrix.oracle-version}} ORACLE_SID: ${{matrix.oracle-sid}} @@ -68,13 +69,13 @@ jobs: --health-cmd healthcheck.sh steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: fetch-depth: 0 - - uses: c-py/action-dotenv-to-setenv@v2 + - uses: c-py/action-dotenv-to-setenv@v5 with: env-file: .github/variables/.env - - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action + - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action - name: Set build version number env variables id: set-build-version-number-vars @@ -91,11 +92,27 @@ jobs: - name: Update privileges on sources run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} + - name: Cache OJDBC jars + id: cache-ojdbc + uses: actions/cache@v4 + with: + path: ${{ env.OJDBC_HOME }} + key: ${{ runner.os }}-ojdbc-${{ env.OJDBC_URL }}-v1 + - name: Add OJDBC home + if: steps.cache-ojdbc.outputs.cache-hit != 'true' id: get-ojdbc run: mkdir -p ${OJDBC_HOME} && curl -Lk -o ${OJDBC_HOME}/ojdbc8.jar ${OJDBC_URL}/ojdbc8.jar && curl -Lk -o ${OJDBC_HOME}/orai18n.jar ${OJDBC_URL}/orai18n.jar + - name: Cache utPLSQL-cli + id: cache-utplsql-cli + uses: actions/cache@v4 + with: + path: utPLSQL-cli + key: ${{ runner.os }}-utplsql-cli-v3.1.8 + - name: Install utPLSQL-cli + if: steps.cache-utplsql-cli.outputs.cache-hit != 'true' id: install-utplsql-cli run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli @@ -152,7 +169,7 @@ jobs: - name: Upload ORACLE_BASE/diag data Artifact id: upload if: ${{ always() && steps.run-tests.outcome == 'failure' }} - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: name: my-artifact$-${{matrix.db_version_name}} path: ${{github.workspace}}/database-diag @@ -163,7 +180,7 @@ jobs: run: bash .github/scripts/validate_report_files.sh - name: Codecov - uses: codecov/codecov-action@v2 + uses: codecov/codecov-action@v5 with: token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos files: ./cobertura.xml @@ -171,7 +188,7 @@ jobs: fail_ci_if_error: true # optional (default = false) - name: Publish unit test results - uses: EnricoMi/publish-unit-test-result-action@v1.24 + uses: EnricoMi/publish-unit-test-result-action@v2 if: always() with: files: junit_test_results.xml @@ -179,7 +196,7 @@ jobs: - name: SonarCloud Scan id: sonar if: ${{ always() && matrix.db_version_name == '21XE' }} - uses: SonarSource/sonarcloud-github-action@master + uses: SonarSource/sonarcloud-github-action@v5.0.0 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} @@ -194,6 +211,7 @@ jobs: needs: [ build ] concurrency: publish runs-on: ubuntu-latest + timeout-minutes: 30 env: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} if: | @@ -205,14 +223,14 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: echo "API_TOKEN_GITHUB=${GITHUB_TOKEN}" >> $GITHUB_ENV - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: fetch-depth: 0 token: ${{ env.API_TOKEN_GITHUB }} - - uses: c-py/action-dotenv-to-setenv@v2 + - uses: c-py/action-dotenv-to-setenv@v5 with: env-file: .github/variables/.env - - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action + - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action - name: Set buid version number env variables id: set-build-version-number-vars @@ -234,6 +252,12 @@ jobs: git config --global user.email "github-actions[bot]@users.noreply.github.com" git config --global user.name "github-actions[bot]" + - name: Setup Python for docs + uses: actions/setup-python@v5 + with: + python-version: '3.11' + cache: 'pip' + - name: Build and publish documentation run: | pip install mkdocs @@ -247,6 +271,7 @@ jobs: concurrency: trigger needs: [ build, publish ] runs-on: ubuntu-latest + timeout-minutes: 15 if: | github.repository == 'utPLSQL/utPLSQL' && github.base_ref == null && ( startsWith( github.ref, 'refs/heads/release/v' ) || github.ref == 'refs/heads/develop' ) @@ -256,7 +281,7 @@ jobs: # repo: [ 'utPLSQL/utPLSQL-v2-v3-migration' ] steps: - name: Repository Dispatch - uses: peter-evans/repository-dispatch@v1 + uses: peter-evans/repository-dispatch@v4 with: token: ${{ secrets.API_TOKEN_GITHUB }} repository: ${{ matrix.repo }} @@ -267,9 +292,10 @@ jobs: name: Post Workflow Status To Slack needs: [ build, publish, dispatch ] runs-on: ubuntu-latest + timeout-minutes: 10 steps: - name: Slack Workflow Notification - uses: Gamesight/slack-workflow-status@master + uses: Gamesight/slack-workflow-status@v1.3.0 with: repo_token: ${{secrets.GITHUB_TOKEN}} slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a748d1cbd..19bf5007f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,15 +14,16 @@ jobs: name: Upload archives concurrency: upload runs-on: ubuntu-latest + timeout-minutes: 60 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: fetch-depth: 0 - - uses: c-py/action-dotenv-to-setenv@v2 + - uses: c-py/action-dotenv-to-setenv@v5 with: env-file: .github/variables/.env - - uses: FranzDiebold/github-env-vars-action@v2 #https://github.com/marketplace/actions/github-environment-variables-action + - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action - name: Set build version number env variables run: .github/scripts/set_version_numbers_env.sh @@ -35,6 +36,12 @@ jobs: git config --global user.email "github-actions[bot]@users.noreply.github.com" git config --global user.name "github-actions[bot]" + - name: Setup Python for docs + uses: actions/setup-python@v5 + with: + python-version: '3.11' + cache: 'pip' + - name: Build and publish documentation run: | pip install mkdocs @@ -69,9 +76,10 @@ jobs: name: Post Workflow Status To Slack needs: [ upload_artifacts ] runs-on: ubuntu-latest + timeout-minutes: 10 steps: - name: Slack Workflow Notification - uses: Gamesight/slack-workflow-status@master + uses: Gamesight/slack-workflow-status@v1.3.0 with: repo_token: ${{secrets.GITHUB_TOKEN}} slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} From c2138900c2585bea7de12e7a92e239d9b11a603d Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 13:13:49 +0000 Subject: [PATCH 501/887] Fixing 19c --- .github/workflows/build.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3c7f80b93..80f734149 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -62,11 +62,7 @@ jobs: ports: - 1521:1521 options: >- - --health-interval 10s - --health-timeout 5s - --health-retries 10 --name oracle - --health-cmd healthcheck.sh steps: - uses: actions/checkout@v4 From 77d2eccf177284e6a469aef703a88751fa628ddc Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 13:19:26 +0000 Subject: [PATCH 502/887] Adding healthchecks --- .github/workflows/build.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 80f734149..ffdab246b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -63,6 +63,10 @@ jobs: - 1521:1521 options: >- --name oracle + --health-interval 10s + --health-timeout 5s + --health-retries 10 + --health-cmd healthcheck.sh steps: - uses: actions/checkout@v4 From 6dd676436709c07c1cd63a9ea0004bbd51730cfd Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 13:39:45 +0000 Subject: [PATCH 503/887] Testing delays --- .github/workflows/build.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ffdab246b..113f9a06a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -116,6 +116,9 @@ jobs: id: install-utplsql-cli run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli + - name: Wait for Oracle DB to be fully ready + run: sleep 30 + - name: Install utPLSQL id: install-utplsql run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh From a0d13444cf332bc02a9197572698045112779af7 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 13:53:20 +0000 Subject: [PATCH 504/887] Change images --- .github/workflows/build.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 113f9a06a..5ea5e3706 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -36,12 +36,12 @@ jobs: - id: 2 db_version_name: '21XE' oracle-sid: 'XE' - oracle-version: "gvenzl/oracle-xe:21-slim" + oracle-version: "gvenzl/oracle-xe:21-slim-faststart" oracle-base: '/opt/oracle' - id: 3 db_version_name: '23free' oracle-sid: 'FREEPDB1' - oracle-version: "gvenzl/oracle-free:23-slim" + oracle-version: "gvenzl/oracle-free:23-slim-faststart" oracle-base: '/opt/oracle' # TODO - need to add healthcheck.sh into our containers @@ -116,9 +116,6 @@ jobs: id: install-utplsql-cli run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli - - name: Wait for Oracle DB to be fully ready - run: sleep 30 - - name: Install utPLSQL id: install-utplsql run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh From 55b02ba924251f6626616d2e67fb87511af478b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 15:56:13 +0200 Subject: [PATCH 505/887] Removed 11 and 12 DB's - added support for 19c (added health check in docker repository) --- .github/workflows/build.yml | 29 ++++------------------------- 1 file changed, 4 insertions(+), 25 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index af2e4875d..870f4b007 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -28,37 +28,16 @@ jobs: matrix: include: - id: 1 - db_version_name: '11XE' - oracle-sid: 'XE' - oracle-version: "gvenzl/oracle-xe:11-full" - oracle-base: '/u01/app/oracle' - - id: 2 - db_version_name: '12.1EE' + db_version_name: '19se' oracle-sid: 'ORCLCDB' - oracle-version: "utplsqlv3/oracledb:12c-r1-ee-small" + oracle-version: "utplsqlv3/oracledb:19c-se2-small" oracle-base: '/opt/oracle' -# - id: 3 -# db_version_name: '12.2se' -# oracle-sid: 'ORCLCDB' -# oracle-version: "utplsqlv3/oracledb:12c-r2-se2-small" -# oracle-base: '/opt/oracle' - - id: 4 - db_version_name: '18XE' - oracle-sid: 'XE' - oracle-version: "gvenzl/oracle-xe:18-slim" - oracle-base: '/opt/oracle' -# TODO - need to add healthcheck.sh into our containers -# - id: 5 -# db_version_name: '19se' -# oracle-sid: 'ORCLCDB' -# oracle-version: "utplsqlv3/oracledb:19c-se2-small" -# oracle-base: '/opt/oracle' - - id: 6 + - id: 2 db_version_name: '21XE' oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:21-slim" oracle-base: '/opt/oracle' - - id: 7 + - id: 3 db_version_name: '23free' oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23-slim" From 9df078c1323ea77c03c8047d65da3eb5916573a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 15:59:35 +0200 Subject: [PATCH 506/887] Fixing Sonar Scan --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 870f4b007..0be56e66d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -178,7 +178,7 @@ jobs: - name: SonarCloud Scan id: sonar if: ${{ always() && matrix.db_version_name == '21XE' }} - uses: SonarSource/sonarcloud-github-action@master + uses: SonarSource/sonarqube-scan-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} From 40d9998230260225681885f73c9ba51ee7780df9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 16:36:34 +0200 Subject: [PATCH 507/887] Update of CONTRIBUTING.md --- CONTRIBUTING.md | 42 +++++++++--------------------------------- 1 file changed, 9 insertions(+), 33 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 926f0df80..744495e76 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -162,44 +162,20 @@ Dependencies to `ut_util` are not shown as most of modules are depending on it. ## Build Environment -We are using private docker images to test utPLSQL for our Travis CI builds. The following versions of Oracle Database are being used. +We are using a combination of private and publicly available docker images to test utPLSQL. The following versions of Oracle Database are used for testing: -* 11g XE R2 -* 12c SE R1 -* 12c SE R2 -* 18c SE +* 19c-Standard Edition (private image) +* 21-free +* 23-free -These images are based on the slimmed versions [official dockerfiles released by Oracle](https://github.com/utPLSQL/docker-scripts), but due to licensing restrictions, we can't make the images public. -You can build your own and use it locally, or push to a private docker repository. - -The build steps are simple if you already have some experience using Docker. You can find detailed information about how to build your own image with a running database in: [example of creating an image with pre-built DB](https://github.com/oracle/docker-images/blob/master/OracleDatabase/samples/prebuiltdb/README.md) - -> You can find more info about the official Oracle images on the [Oracle Database on Docker](https://github.com/oracle/docker-images/tree/master/OracleDatabase) GitHub page. +The Free varsions are publicly available and you can set up your local development environment to use one of from [here](https://github.com/gvenzl/oci-oracle-free) -> If you are new to Docker, you can start by reading the [Getting Started With Docker](https://docs.docker.com/engine/getstarted/) docs. +These [private image]((https://github.com/utPLSQL/docker-scripts) is a slimmed version of [the official Oracle database dockerfiles](https://github.com/oracle/docker-images/tree/master/OracleDatabase) . Due to licensing restrictions, the image cannot be public. -### Docker Build Notes - -* You need to comment out the VOLUME line. This step is required, because volumes are not saved when using `docker commit` command. -* When the build process is complete, you will run the container to install the database. Once everything is set up and you see the message "DATABASE IS READY!", you may change the password and stop the running container. After the container is stopped, you can safely commit the container. -* You can use the --squash experimental docker tag to reduce the image size. Example: -``` -docker build --force-rm --no-cache --squash -t oracle/db-prebuilt . -``` - -Travis will use your Docker Hub credentials to pull the private images, and the following secure environment variables must be defined. - -| Variable | Description | -|------------------------------------------|-----------------------------------------------------------------------------------------------| -| **DOCKER_USER**
    **DOCKER_PASSWORD** | _Your Docker Hub website credentials. They will be used to pull the private database images._ | - -### SQLCL - -Our build configuration uses SQLCL to run the scripts, and you need to configure a few additional secure environment variables. After the first build, the downloaded file will be cached. +You can build your own and use it locally, or push to a private docker repository. +The build steps are simple if you already have some experience using Docker. You can find detailed information about how to build your own image with a running database in: [example of creating an image with pre-built DB](https://github.com/oracle/docker-images/blob/master/OracleDatabase/samples/prebuiltdb/README.md) -| Variable | Description | -|----------------------------------------------|-------------------------------------------------------------------------| -| **ORACLE_OTN_USER
    ORACLE_OTN_PASSWORD** | _Your Oracle website credentials. They will be used to download SQLCL._ | +> If you are new to Docker, you can start by reading the [Getting Started With Docker](https://docs.docker.com/get-started/) docs. ## New to GIT From 39d36dc1134e598d71114e056cfb0dcff0241012 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 16:55:04 +0200 Subject: [PATCH 508/887] Update of sonar-project.properties --- sonar-project.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sonar-project.properties b/sonar-project.properties index d088e9ccb..f23e8cf71 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -1,6 +1,6 @@ # must be unique in a given SonarQube instance sonar.organization=utplsql -sonar.projectKey=utPLSQL +sonar.projectKey=utPLSQL_utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL sonar.projectVersion=v3.1.14-develop From ead391da8d88628b47cbbedef268e67d4ed6c111 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 17:08:29 +0200 Subject: [PATCH 509/887] Cleanup of build process --- .github/workflows/build.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0be56e66d..92dd64549 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,17 +31,14 @@ jobs: db_version_name: '19se' oracle-sid: 'ORCLCDB' oracle-version: "utplsqlv3/oracledb:19c-se2-small" - oracle-base: '/opt/oracle' - id: 2 db_version_name: '21XE' oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:21-slim" - oracle-base: '/opt/oracle' - id: 3 db_version_name: '23free' oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23-slim" - oracle-base: '/opt/oracle' services: html_checker: From e07c6199109faaa3db0071adb3b3621497e9ba89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 17:56:18 +0200 Subject: [PATCH 510/887] Testing sonar scanner updates --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 92dd64549..f4c9da997 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -182,7 +182,7 @@ jobs: with: args: > -Dsonar.buildString=${{ format( '{0}.{1}', env.UTPLSQL_BUILD_VERSION, matrix.id ) }} - -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//oracle:1521/{0}', env.ORACLE_SID ) }} + -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//localhost:1521/{0}', env.ORACLE_SID ) }} -Dsonar.plsql.jdbc.driver.path=${{ format( '{0}/ojdbc8.jar', env.OJDBC_HOME ) }} publish: From 3e3c5603d4e080a704beec7ad9927f76ca8672c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 18:47:53 +0200 Subject: [PATCH 511/887] Attempting to fix 19c install issues --- .github/workflows/build.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f4c9da997..1eed2f9b8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -97,7 +97,8 @@ jobs: - name: Install utPLSQL id: install-utplsql - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh +# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle bash .github/scripts/install.sh - name: Check code style if: ${{ matrix.id == 1 }} From 229d07242da8d6d479ec403f55afc5c846e25e3d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 19:04:12 +0200 Subject: [PATCH 512/887] Change of strategy for installation and execution inside the pipeline. --- .github/workflows/build.yml | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1eed2f9b8..afe3df27b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -97,39 +97,38 @@ jobs: - name: Install utPLSQL id: install-utplsql -# run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle bash .github/scripts/install.sh - name: Check code style if: ${{ matrix.id == 1 }} id: check-coding-style - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint "$SQLCLI" ${DOCKER_ENV} ${ORACLE_VERSION} $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @development/utplsql_style_check.sql + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle bash "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @development/utplsql_style_check.sql - name: Validate utPLSQL uninstall if: ${{ matrix.id == 1 }} id: validate-uninstall - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/uninstall_validate_utplsql.sh + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle bash .github/scripts/uninstall_validate_utplsql.sh - name: Reinstall utPLSQL if: ${{ matrix.id == 1 }} id: reinstall-utplsql - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install.sh + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install.sh - name: Create test users id: create-test-users - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/create_test_users.sh + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/create_test_users.sh - name: Install utPLSQL release id: install-utplsql-release - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/install_utplsql_release.sh + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install_utplsql_release.sh - name: Run Examples id: run-examples - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} .github/scripts/run_examples.sh + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/run_examples.sh - name: Install tests id: install-tests - run: docker run --rm -v $(pwd):/utPLSQL -w /utPLSQL --network host --entrypoint bash ${DOCKER_ENV} ${ORACLE_VERSION} test/install_tests.sh + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle test/install_tests.sh - name: Run Tests id: run-tests From 60dff1d596ba3d2700cc0b38b5a7f30bd2aec5ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 19:19:21 +0200 Subject: [PATCH 513/887] Fixing the utplsql_style_check code --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index afe3df27b..f08ce33cd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -102,7 +102,7 @@ jobs: - name: Check code style if: ${{ matrix.id == 1 }} id: check-coding-style - run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle bash "$SQLCLI" $UT3_DEVELOP_SCHEMA/$UT3_DEVELOP_SCHEMA_PASSWORD@//$CONNECTION_STR @development/utplsql_style_check.sql + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle "$SQLCLI" ${UT3_DEVELOP_SCHEMA}/${UT3_DEVELOP_SCHEMA_PASSWORD}@//${CONNECTION_STR} @/utPLSQL/development/utplsql_style_check.sql - name: Validate utPLSQL uninstall if: ${{ matrix.id == 1 }} From e97b917bf30c722d69014a87fe94d80685687d7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 19:41:53 +0200 Subject: [PATCH 514/887] Adding debug information to test runner --- .github/workflows/build.yml | 6 +++--- test/run_tests.sh | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f08ce33cd..60c83779c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -97,17 +97,17 @@ jobs: - name: Install utPLSQL id: install-utplsql - run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle bash .github/scripts/install.sh + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install.sh - name: Check code style if: ${{ matrix.id == 1 }} id: check-coding-style - run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle "$SQLCLI" ${UT3_DEVELOP_SCHEMA}/${UT3_DEVELOP_SCHEMA_PASSWORD}@//${CONNECTION_STR} @/utPLSQL/development/utplsql_style_check.sql + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle "$SQLCLI" ${UT3_DEVELOP_SCHEMA}/${UT3_DEVELOP_SCHEMA_PASSWORD}@//${CONNECTION_STR} @/utPLSQL/development/utplsql_style_check.sql - name: Validate utPLSQL uninstall if: ${{ matrix.id == 1 }} id: validate-uninstall - run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle bash .github/scripts/uninstall_validate_utplsql.sh + run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/uninstall_validate_utplsql.sh - name: Reinstall utPLSQL if: ${{ matrix.id == 1 }} diff --git a/test/run_tests.sh b/test/run_tests.sh index 118bab920..4213b463f 100755 --- a/test/run_tests.sh +++ b/test/run_tests.sh @@ -4,7 +4,7 @@ set -ev #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" -time utPLSQL-cli/bin/utplsql run UT3_TESTER_HELPER/ut3@${CONNECTION_STR} \ +time utPLSQL-cli/bin/utplsql run UT3_TESTER_HELPER/ut3@${CONNECTION_STR} -d -D \ -source_path=source -owner=ut3_develop \ -p='ut3_tester,ut3_user' \ -test_path=test -c \ From 5fb2c098538a3049ee7d29df99704e799dca2cd6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 19:49:31 +0200 Subject: [PATCH 515/887] Remove profiler run around examples --- examples/RunAllExamples.sql | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/examples/RunAllExamples.sql b/examples/RunAllExamples.sql index faa3388cf..f5f42b7f3 100644 --- a/examples/RunAllExamples.sql +++ b/examples/RunAllExamples.sql @@ -3,22 +3,8 @@ set echo on set feedback on set linesize 1000 -declare - l_run_number binary_integer; -begin - dbms_profiler.start_profiler( run_number => l_run_number); -end; -/ - -- Examples for users @@RunUserExamples.sql -- Framework developer examples @@RunDeveloperExamples.sql - -declare - l_return_code binary_integer; -begin - l_return_code := dbms_profiler.stop_profiler(); -end; -/ From 2e22a4b0551e2a95e591743b03a0edbeb44b327c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 19:57:12 +0200 Subject: [PATCH 516/887] Switch to utPLSQL-cli version 3.1.9 --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 60c83779c..38478a425 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -93,7 +93,7 @@ jobs: - name: Install utPLSQL-cli id: install-utplsql-cli - run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/v3.1.8/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli + run: curl -Lk -o utPLSQL-cli.zip "https://github.com/utPLSQL/utPLSQL-cli/releases/download/3.1.9/utPLSQL-cli.zip" && unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli - name: Install utPLSQL id: install-utplsql From 6adb4294ce32d6fe0e71cd0e774bf2a36ee02bec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 20:47:23 +0200 Subject: [PATCH 517/887] Testing other 23-free images --- .github/workflows/build.yml | 12 ++++++++++-- test/run_tests.sh | 2 +- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 38478a425..2cc3da4e0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -36,9 +36,17 @@ jobs: oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:21-slim" - id: 3 - db_version_name: '23free' + db_version_name: '23-slim' oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23-slim" + - id: 4 + db_version_name: '23.26.0-slim' + oracle-sid: 'FREEPDB1' + oracle-version: "gvenzl/oracle-free:23.26.0-slim" + - id: 5 + db_version_name: '23-regular' + oracle-sid: 'FREEPDB1' + oracle-version: "gvenzl/oracle-free:23" services: html_checker: @@ -132,7 +140,7 @@ jobs: - name: Run Tests id: run-tests - run: bash test/run_tests.sh + run: test/run_tests.sh #Start Needed to diagnose occasional failures of DB on test runs - name: Prepare diagnostic directory diff --git a/test/run_tests.sh b/test/run_tests.sh index 4213b463f..d1127f87d 100755 --- a/test/run_tests.sh +++ b/test/run_tests.sh @@ -4,7 +4,7 @@ set -ev #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" -time utPLSQL-cli/bin/utplsql run UT3_TESTER_HELPER/ut3@${CONNECTION_STR} -d -D \ +time utPLSQL-cli/bin/utplsql run UT3_TESTER_HELPER/ut3@//${CONNECTION_STR} -d -D \ -source_path=source -owner=ut3_develop \ -p='ut3_tester,ut3_user' \ -test_path=test -c \ From 71f4911ed3920bff2b6b01b9be6caaf2dfea8219 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 21:24:52 +0200 Subject: [PATCH 518/887] Fixing 19c build issues. --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2cc3da4e0..aae9159bd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -23,6 +23,7 @@ jobs: CONNECTION_STR: ${{ format( '127.0.0.1:1521/{0}', matrix.oracle-sid ) }} ORACLE_PASSWORD: oracle DOCKER_VOLUME: ${{matrix.docker-volume}} + JAVA_TOOL_OPTIONS: '-Doracle:net:disableOob=true' # needed as a workaround for 19c docker connectivity issues. See: https://github.com/gvenzl/oci-oracle-xe/issues/43 strategy: fail-fast: false matrix: From 9278f67f006bd5ab265aa9a5986246b16c24198c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 23:22:17 +0200 Subject: [PATCH 519/887] Fixing 19c build issues. Changed the way docker image is created. See commit: https://github.com/utPLSQL/docker-scripts/commit/0f1b3a4f3e71cdb417b219c3782adf01c4c11744#diff-6d4effe667dc45652da52fb0e218549914006349f7be3da5ab7dc774fbfa53deR85 And issue: https://github.com/gvenzl/oci-oracle-xe/issues/43 --- .github/workflows/build.yml | 1 - test/run_tests.sh | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index aae9159bd..2cc3da4e0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -23,7 +23,6 @@ jobs: CONNECTION_STR: ${{ format( '127.0.0.1:1521/{0}', matrix.oracle-sid ) }} ORACLE_PASSWORD: oracle DOCKER_VOLUME: ${{matrix.docker-volume}} - JAVA_TOOL_OPTIONS: '-Doracle:net:disableOob=true' # needed as a workaround for 19c docker connectivity issues. See: https://github.com/gvenzl/oci-oracle-xe/issues/43 strategy: fail-fast: false matrix: diff --git a/test/run_tests.sh b/test/run_tests.sh index d1127f87d..9f69bd1a1 100755 --- a/test/run_tests.sh +++ b/test/run_tests.sh @@ -4,7 +4,7 @@ set -ev #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" -time utPLSQL-cli/bin/utplsql run UT3_TESTER_HELPER/ut3@//${CONNECTION_STR} -d -D \ +time utPLSQL-cli/bin/utplsql run UT3_TESTER_HELPER/ut3@//${CONNECTION_STR} -D \ -source_path=source -owner=ut3_develop \ -p='ut3_tester,ut3_user' \ -test_path=test -c \ From 223f2f73739765f3af75306ed9759b9512bebd7e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Mar 2026 23:33:11 +0200 Subject: [PATCH 520/887] Update of pipeline to use 23.26.0 DB version as 23.26.1 was causing problems --- .github/workflows/build.yml | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2cc3da4e0..b10f4ef8f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -36,17 +36,9 @@ jobs: oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:21-slim" - id: 3 - db_version_name: '23-slim' - oracle-sid: 'FREEPDB1' - oracle-version: "gvenzl/oracle-free:23-slim" - - id: 4 - db_version_name: '23.26.0-slim' + db_version_name: '23-free' oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23.26.0-slim" - - id: 5 - db_version_name: '23-regular' - oracle-sid: 'FREEPDB1' - oracle-version: "gvenzl/oracle-free:23" services: html_checker: @@ -182,7 +174,7 @@ jobs: - name: SonarCloud Scan id: sonar - if: ${{ always() && matrix.db_version_name == '21XE' }} + if: ${{ always() && matrix.db_version_name == '23-free' }} uses: SonarSource/sonarqube-scan-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any From 668c2985421fdcd3dda37bfb910c0f3116f52f04 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 8 Mar 2026 21:39:02 +0000 Subject: [PATCH 521/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index fab85b21d..60233a917 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4206 +4252 diff --git a/docs/about/authors.md b/docs/about/authors.md index 499398993..7790ca3a0 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 03cc286eb..cf433448e 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 5579a943b..259cb7b0f 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 6d68864bd..b7231e190 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b277c9d16..d02272506 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 45fca1871..7200bfaa9 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 31a91cac2..d733b0142 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 6becefc5c..2883542fa 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index c9015b438..6ca83be3f 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 824aaecd5..121785710 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 54c204d58..5ed52b617 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 1ff54a7d6..a288d34eb 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 9d8167739..3c0b564a7 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 24159fede..a27038eac 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 24d1065fe..ea200df89 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 375a05125..34bc2b71d 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 6fdaa6a48..a3c319315 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4206--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 0e1e0a851..19fb3d0f3 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4206-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4252-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 780d4b17b8c029de7df4e33e8dda7003afb68eef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Mar 2026 00:06:23 +0200 Subject: [PATCH 522/887] Adding parameter to allow running a manual build for a Pull Request --- .github/workflows/build.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b10f4ef8f..bfda01497 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,6 +6,10 @@ on: branches: [ develop ] workflow_dispatch: + inputs: + pr_number: + description: Pull request number + required: false concurrency: ${{github.ref}} defaults: From 825a6fdb44225680e88d2f4a5cf96f366fbab742 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 8 Mar 2026 22:12:20 +0000 Subject: [PATCH 523/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 60233a917..d3acd1135 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4252 +4253 diff --git a/docs/about/authors.md b/docs/about/authors.md index 7790ca3a0..e9031c587 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index cf433448e..151ffbc09 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 259cb7b0f..9ab358e7e 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index b7231e190..9172ffd73 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index d02272506..d5970b658 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7200bfaa9..8529cc58b 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index d733b0142..f6b43f37b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 2883542fa..a690b5627 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 6ca83be3f..bce23f6fb 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 121785710..a3cbb9c56 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 5ed52b617..03f17b058 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index a288d34eb..183b51a43 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 3c0b564a7..8d464cf21 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index a27038eac..45f2b8ca2 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ea200df89..1739a7c5b 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 34bc2b71d..ed1226190 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index a3c319315..011271ef3 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4252--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 19fb3d0f3..d8048e58e 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4252-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4253-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From f27c37c2ef135c5d87744a240c0f87951c3a2005 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Mar 2026 00:36:13 +0200 Subject: [PATCH 524/887] Do not push into branch if the build is on a pull request --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index bfda01497..04856a894 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -224,6 +224,7 @@ jobs: - name: Push version update to repository id: push-version-number-update + if: ${{ github.event_name != 'pull_request' }} run: | git add sonar-project.properties VERSION BUILD_NO source/* docs/* git commit -m 'Updated project version after build [skip ci]' From 10b589f3df406a2445768310d245372ad749a964 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Mar 2026 00:37:23 +0200 Subject: [PATCH 525/887] Do not push into branch if the build is on a pull request --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 04856a894..1fccaf331 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -8,7 +8,7 @@ on: workflow_dispatch: inputs: pr_number: - description: Pull request number + description: Pull request number (optional) required: false concurrency: ${{github.ref}} From af0ec153e10108641c7124d9b50246a037a0ccc1 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 8 Mar 2026 22:49:35 +0000 Subject: [PATCH 526/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index d3acd1135..842b1acc0 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4253 +4258 diff --git a/docs/about/authors.md b/docs/about/authors.md index e9031c587..7f5301bac 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 151ffbc09..b3022f494 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 9ab358e7e..2865e3dd7 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 9172ffd73..813a9b339 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index d5970b658..f0c219240 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 8529cc58b..80fc2f91f 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index f6b43f37b..7651f9e18 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index a690b5627..755ff6c3a 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index bce23f6fb..f4931f432 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a3cbb9c56..287b078ac 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 03f17b058..5ae611b7d 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 183b51a43..6fd19df5c 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 8d464cf21..7c1d7f9d2 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 45f2b8ca2..9b13c95d0 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 1739a7c5b..41ff8ad29 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index ed1226190..56c8bc387 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 011271ef3..f33d02059 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4253--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index d8048e58e..278834177 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4253-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4258-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 25dd48ba22151523c1d461e200cdacbf9cf9de46 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Mar 2026 00:56:51 +0200 Subject: [PATCH 527/887] Reverting unneeded changes for PR builds --- .github/workflows/build.yml | 5 ----- 1 file changed, 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1fccaf331..b10f4ef8f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,10 +6,6 @@ on: branches: [ develop ] workflow_dispatch: - inputs: - pr_number: - description: Pull request number (optional) - required: false concurrency: ${{github.ref}} defaults: @@ -224,7 +220,6 @@ jobs: - name: Push version update to repository id: push-version-number-update - if: ${{ github.event_name != 'pull_request' }} run: | git add sonar-project.properties VERSION BUILD_NO source/* docs/* git commit -m 'Updated project version after build [skip ci]' From efc5ba87b75e541c41ce500f29e281d7d7aac39a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 8 Mar 2026 23:07:11 +0000 Subject: [PATCH 528/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 842b1acc0..63ac185e9 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4258 +4259 diff --git a/docs/about/authors.md b/docs/about/authors.md index 7f5301bac..c82fedcbf 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index b3022f494..64a1c0b7f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 2865e3dd7..05c3e91ef 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 813a9b339..5054f4209 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index f0c219240..a3d635866 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 80fc2f91f..eea340c51 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 7651f9e18..cde703327 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 755ff6c3a..3eed598cf 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index f4931f432..aee30ae0e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 287b078ac..4ece3de5e 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 5ae611b7d..eb8148c22 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 6fd19df5c..d9ba7dba1 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 7c1d7f9d2..6ce52c108 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 9b13c95d0..2bb819610 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 41ff8ad29..0f4ed8d0c 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 56c8bc387..369a4b83e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index f33d02059..e9bc089a3 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4258--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 278834177..c4a4738d4 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4258-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4259-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From e10f48b99e7a2268bcc135041ef5182ac3a3b1bc Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 23:18:48 +0000 Subject: [PATCH 529/887] faststart --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d9a20634c..41ccf2942 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -36,11 +36,11 @@ jobs: - id: 2 db_version_name: '21XE' oracle-sid: 'XE' - oracle-version: "gvenzl/oracle-xe:21-slim" + oracle-version: "gvenzl/oracle-xe:21-slim-faststart" - id: 3 db_version_name: '23free' oracle-sid: 'FREEPDB1' - oracle-version: "gvenzl/oracle-free:23-slim" + oracle-version: "gvenzl/oracle-free:23-slim-faststart" env: ORACLE_PASSWORD: oracle credentials: From 5862a5f613c6d64dda1c6b719fd5d989df972e97 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 23:24:51 +0000 Subject: [PATCH 530/887] update --- .github/workflows/build.yml | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 41ccf2942..d1af0637c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -32,7 +32,6 @@ jobs: db_version_name: '19se' oracle-sid: 'ORCLCDB' oracle-version: "utplsqlv3/oracledb:19c-se2-small" - oracle-base: '/opt/oracle' - id: 2 db_version_name: '21XE' oracle-sid: 'XE' @@ -41,20 +40,23 @@ jobs: db_version_name: '23free' oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23-slim-faststart" + services: + html_checker: + image: ghcr.io/validator/validator:latest + options: >- + -p 8888:8888 + oracle: + image: ${{matrix.oracle-version}} env: ORACLE_PASSWORD: oracle credentials: - username: ${{ secrets.DOCKER_USER }} - password: ${{ secrets.DOCKER_PASSWORD }} - volumes: - - ${{github.workspace}}:/utPLSQL ports: - 1521:1521 options: >- - --name oracle --health-interval 10s --health-timeout 5s --health-retries 10 + --name oracle --health-cmd healthcheck.sh steps: From 8c6fe6adea87b753a31230c163478c609473ded6 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 23:25:45 +0000 Subject: [PATCH 531/887] upoate --- .github/workflows/build.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d1af0637c..2155b15d6 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -50,6 +50,10 @@ jobs: env: ORACLE_PASSWORD: oracle credentials: + username: ${{ secrets.DOCKER_USER }} + password: ${{ secrets.DOCKER_PASSWORD }} + volumes: + - ${{github.workspace}}:/utPLSQL ports: - 1521:1521 options: >- From 7ea7198cd21944c56bde8ff2f478bd26acdf5f87 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 23:26:13 +0000 Subject: [PATCH 532/887] Correct blanks --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2155b15d6..d0a0cb51f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -53,7 +53,7 @@ jobs: username: ${{ secrets.DOCKER_USER }} password: ${{ secrets.DOCKER_PASSWORD }} volumes: - - ${{github.workspace}}:/utPLSQL + - ${{github.workspace}}:/utPLSQL ports: - 1521:1521 options: >- From 62889256165a233e6025c627daf25b6a56fdad53 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 23:28:36 +0000 Subject: [PATCH 533/887] Update --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d0a0cb51f..874628682 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -175,7 +175,7 @@ jobs: run: bash .github/scripts/validate_report_files.sh - name: Codecov - uses: codecov/codecov-action@v5 + uses: codecov/codecov-action@master with: token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos files: ./cobertura.xml @@ -290,7 +290,7 @@ jobs: timeout-minutes: 10 steps: - name: Slack Workflow Notification - uses: Gamesight/slack-workflow-status@v1.3.0 + uses: Gamesight/slack-workflow-status@master with: repo_token: ${{secrets.GITHUB_TOKEN}} slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} From f1585ae6cd721e2907c4cdf7402d51bc3b2192c8 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 23:42:52 +0000 Subject: [PATCH 534/887] Fixing duration --- source/core/types/ut_reporter_base.tpb | 45 +++++++++++++------------- 1 file changed, 23 insertions(+), 22 deletions(-) diff --git a/source/core/types/ut_reporter_base.tpb b/source/core/types/ut_reporter_base.tpb index 3f8984331..432bbc7d8 100644 --- a/source/core/types/ut_reporter_base.tpb +++ b/source/core/types/ut_reporter_base.tpb @@ -165,52 +165,53 @@ create or replace type body ut_reporter_base is end; overriding member procedure on_event( self in out nocopy ut_reporter_base, a_event_name varchar2, a_event_item ut_event_item) is + l_event_item ut_event_item := a_event_item; -- ADD THIS LINE begin case a_event_name when ut_event_manager.gc_initialize - then self.on_initialize(treat(a_event_item as ut_run)); + then self.on_initialize(treat(l_event_item as ut_run)); when ut_event_manager.gc_before_run - then self.before_calling_run(treat(a_event_item as ut_run)); + then self.before_calling_run(treat(l_event_item as ut_run)); when ut_event_manager.gc_before_suite - then self.before_calling_suite(treat(a_event_item as ut_logical_suite)); + then self.before_calling_suite(treat(l_event_item as ut_logical_suite)); when ut_event_manager.gc_before_before_all - then self.before_calling_before_all(treat(a_event_item as ut_executable)); + then self.before_calling_before_all(treat(l_event_item as ut_executable)); when ut_event_manager.gc_before_before_each - then self.before_calling_before_each(treat(a_event_item as ut_executable)); + then self.before_calling_before_each(treat(l_event_item as ut_executable)); when ut_event_manager.gc_before_test - then self.before_calling_test(treat(a_event_item as ut_test)); + then self.before_calling_test(treat(l_event_item as ut_test)); when ut_event_manager.gc_before_before_test - then self.before_calling_before_test(treat(a_event_item as ut_executable)); + then self.before_calling_before_test(treat(l_event_item as ut_executable)); when ut_event_manager.gc_before_test_execute - then self.before_calling_test_execute(treat(a_event_item as ut_executable)); + then self.before_calling_test_execute(treat(l_event_item as ut_executable)); when ut_event_manager.gc_before_after_test - then self.before_calling_after_test(treat(a_event_item as ut_executable)); + then self.before_calling_after_test(treat(l_event_item as ut_executable)); when ut_event_manager.gc_before_after_each - then self.before_calling_after_each(treat(a_event_item as ut_executable)); + then self.before_calling_after_each(treat(l_event_item as ut_executable)); when ut_event_manager.gc_before_after_all - then self.before_calling_after_all(treat(a_event_item as ut_executable)); + then self.before_calling_after_all(treat(l_event_item as ut_executable)); when ut_event_manager.gc_after_run - then self.after_calling_run(treat(a_event_item as ut_run)); + then self.after_calling_run(treat(l_event_item as ut_run)); when ut_event_manager.gc_after_suite - then self.after_calling_suite(treat(a_event_item as ut_logical_suite)); + then self.after_calling_suite(treat(l_event_item as ut_logical_suite)); when ut_event_manager.gc_after_before_all - then self.after_calling_before_all(treat(a_event_item as ut_executable)); + then self.after_calling_before_all(treat(l_event_item as ut_executable)); when ut_event_manager.gc_after_before_each - then self.after_calling_before_each(treat(a_event_item as ut_executable)); + then self.after_calling_before_each(treat(l_event_item as ut_executable)); when ut_event_manager.gc_after_test - then self.after_calling_test(treat(a_event_item as ut_test)); + then self.after_calling_test(treat(l_event_item as ut_test)); when ut_event_manager.gc_after_before_test - then self.after_calling_before_test(treat(a_event_item as ut_executable)); + then self.after_calling_before_test(treat(l_event_item as ut_executable)); when ut_event_manager.gc_after_test_execute - then self.after_calling_test_execute(treat(a_event_item as ut_executable)); + then self.after_calling_test_execute(treat(l_event_item as ut_executable)); when ut_event_manager.gc_after_after_test - then self.after_calling_after_test(treat(a_event_item as ut_executable)); + then self.after_calling_after_test(treat(l_event_item as ut_executable)); when ut_event_manager.gc_after_after_each - then self.after_calling_after_each(treat(a_event_item as ut_executable)); + then self.after_calling_after_each(treat(l_event_item as ut_executable)); when ut_event_manager.gc_after_after_all - then self.after_calling_after_all(treat(a_event_item as ut_executable)); + then self.after_calling_after_all(treat(l_event_item as ut_executable)); when ut_event_manager.gc_finalize - then self.on_finalize(treat(a_event_item as ut_run)); + then self.on_finalize(treat(l_event_item as ut_run)); else null; end case; end; From 5400c7caadac1656613f61a861ffcf429e3aa67c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 23:44:29 +0000 Subject: [PATCH 535/887] Correct wrong vrsion --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 874628682..1c38a2ec0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -175,7 +175,7 @@ jobs: run: bash .github/scripts/validate_report_files.sh - name: Codecov - uses: codecov/codecov-action@master + uses: codecov/codecov-action@v4 with: token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos files: ./cobertura.xml From fdf4abaef4a02148e9ce8044185a66e0d2cd2f1a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 8 Mar 2026 23:59:04 +0000 Subject: [PATCH 536/887] revert --- .github/workflows/build.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1c38a2ec0..5d4c44108 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -37,7 +37,7 @@ jobs: oracle-sid: 'XE' oracle-version: "gvenzl/oracle-xe:21-slim-faststart" - id: 3 - db_version_name: '23free' + db_version_name: '23-free' oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23-slim-faststart" services: @@ -116,17 +116,17 @@ jobs: run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install.sh - name: Check code style - if: ${{ matrix.db_version_name == '21XE' }} + if: ${{ matrix.id == 1 }} id: check-coding-style run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle "$SQLCLI" ${UT3_DEVELOP_SCHEMA}/${UT3_DEVELOP_SCHEMA_PASSWORD}@//${CONNECTION_STR} @/utPLSQL/development/utplsql_style_check.sql - name: Validate utPLSQL uninstall - if: ${{ matrix.db_version_name == '21XE' }} + if: ${{ matrix.id == 1 }} id: validate-uninstall run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/uninstall_validate_utplsql.sh - name: Reinstall utPLSQL - if: ${{ matrix.db_version_name == '21XE' }} + if: ${{ matrix.id == 1 }} id: reinstall-utplsql run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install.sh @@ -190,15 +190,15 @@ jobs: - name: SonarCloud Scan id: sonar - if: ${{ always() && matrix.db_version_name == '21XE' }} - uses: SonarSource/sonarcloud-github-action@v5.0.0 + if: ${{ always() && matrix.db_version_name == '23-free' }} + uses: SonarSource/sonarcloud-github-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} with: args: > -Dsonar.buildString=${{ format( '{0}.{1}', env.UTPLSQL_BUILD_VERSION, matrix.id ) }} - -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//oracle:1521/{0}', env.ORACLE_SID ) }} + -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//localhost:1521/{0}', env.ORACLE_SID ) }} -Dsonar.plsql.jdbc.driver.path=${{ format( '{0}/ojdbc8.jar', env.OJDBC_HOME ) }} publish: From 83b486ad76231c73a2b734ac72b316f73266b19c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 00:00:07 +0000 Subject: [PATCH 537/887] update task --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5d4c44108..796017d5c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -191,7 +191,7 @@ jobs: - name: SonarCloud Scan id: sonar if: ${{ always() && matrix.db_version_name == '23-free' }} - uses: SonarSource/sonarcloud-github-action@master + uses: SonarSource/sonarqube-scan-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} From 40cbed5a40b6a88b86acb3777b02715e9426f9f1 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 00:01:24 +0000 Subject: [PATCH 538/887] Update release ver --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 738f4960a..fe8f028c3 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -79,7 +79,7 @@ jobs: timeout-minutes: 10 steps: - name: Slack Workflow Notification - uses: Gamesight/slack-workflow-status@v1.3.0 + uses: Gamesight/slack-workflow-status@master with: repo_token: ${{secrets.GITHUB_TOKEN}} slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} From a7b4d84d470bda2382e9079b498786e7170bf1be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Mar 2026 12:50:39 +0200 Subject: [PATCH 539/887] Update source/core/types/ut_reporter_base.tpb --- source/core/types/ut_reporter_base.tpb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/core/types/ut_reporter_base.tpb b/source/core/types/ut_reporter_base.tpb index 432bbc7d8..017dc8971 100644 --- a/source/core/types/ut_reporter_base.tpb +++ b/source/core/types/ut_reporter_base.tpb @@ -165,7 +165,8 @@ create or replace type body ut_reporter_base is end; overriding member procedure on_event( self in out nocopy ut_reporter_base, a_event_name varchar2, a_event_item ut_event_item) is - l_event_item ut_event_item := a_event_item; -- ADD THIS LINE + /* Resolves issue with ORA-21779 being thrown see issue: 1309 -> ( https://github.com/utPLSQL/utPLSQL/issues/1309#issuecomment-4020289898 ) */ + l_event_item ut_event_item := a_event_item; begin case a_event_name when ut_event_manager.gc_initialize From a5ef47631e34fa1d3271a8bbf6bf3e12328bf94c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Mar 2026 13:26:52 +0200 Subject: [PATCH 540/887] CONTRIBUTING.md Documentation update --- CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 744495e76..3cac5c86f 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -40,7 +40,7 @@ Changes are welcome from all members of the Community. # Configuring local environment Your local environment can be of any flavor (Unix/Linux/Windows/Mac). -At minimum you need to have Oracle database 11.2 XE accessible for the project and SYS account access to install and develop utPLSQL. +At minimum, you need to have Oracle database 19c accessible for the project and SYS account access to install and develop utPLSQL. We use four different database accounts (users) for development process. * `ut3` - holds latest released version of utPLSQL. This schema holds the testing framework used for self-testing of utPLSQL development. From 1c85f36ec610d3ab133b0be3b83a872aa186c7c1 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 9 Mar 2026 11:33:36 +0000 Subject: [PATCH 541/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 63ac185e9..6a22fb16a 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4259 +4280 diff --git a/docs/about/authors.md b/docs/about/authors.md index c82fedcbf..1b31a03bc 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 64a1c0b7f..757e370e8 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 05c3e91ef..265e594b1 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 5054f4209..dac308a65 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index a3d635866..8c88a4d15 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index eea340c51..9b1d31d05 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index cde703327..7c500b509 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 3eed598cf..5a7b71af3 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index aee30ae0e..6bb0738b7 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 4ece3de5e..43b61dc73 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index eb8148c22..5bf9787b1 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index d9ba7dba1..febe7f0c4 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 6ce52c108..766b54b0b 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 2bb819610..77fead32d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 0f4ed8d0c..839908ca4 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 369a4b83e..fec85d57e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e9bc089a3..645f8549f 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4259--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c4a4738d4..7b14f44ae 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4259-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4280-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ea7bfd07b85ac57b41a57a79e8adef3c7a7d32e6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 9 Mar 2026 11:43:23 +0000 Subject: [PATCH 542/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 6a22fb16a..0c1460d8f 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4280 +4281 diff --git a/docs/about/authors.md b/docs/about/authors.md index 1b31a03bc..de163c0cf 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 757e370e8..18a13cd81 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 265e594b1..382b0e1c5 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index dac308a65..4a88483a5 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 8c88a4d15..30ad6eaff 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 9b1d31d05..d8ddad0c5 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 7c500b509..3d32b9de6 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 5a7b71af3..d5412673e 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 6bb0738b7..b6b66830d 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 43b61dc73..0ea567077 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 5bf9787b1..3c49f0cb5 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index febe7f0c4..2c86f390e 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 766b54b0b..876a73cf5 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 77fead32d..49c608edf 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 839908ca4..6f8339a52 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index fec85d57e..e9b646142 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 645f8549f..110be8f01 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4280--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 7b14f44ae..939384a85 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4280-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4281-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 7e2b8fb4f83cf26b815e207edf7cad12403f8e8c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 22:19:01 +0000 Subject: [PATCH 543/887] Removing the uncessary setup --- .github/workflows/release.yml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index fe8f028c3..ab043b6eb 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -36,12 +36,6 @@ jobs: git config --global user.email "github-actions[bot]@users.noreply.github.com" git config --global user.name "github-actions[bot]" - - name: Setup Python for docs - uses: actions/setup-python@v5 - with: - python-version: '3.11' - cache: 'pip' - - name: Build and publish documentation run: | pip install mkdocs From 38e02ab70b05a8e67510dfe5366b6962766005c5 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 22:47:53 +0000 Subject: [PATCH 544/887] Testing something --- .../core/annotations/ut_annotation_parser.pkb | 80 ++++++++++++++----- 1 file changed, 61 insertions(+), 19 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 10bb76b3c..0816b0652 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -136,9 +136,17 @@ create or replace package body ut_annotation_parser as l_comment_pos binary_integer; l_comment_line binary_integer; l_comment_replacer varchar2(50); - l_source clob := a_source; + l_comment_text varchar2(32767); + l_comment_match varchar2(32767); + l_result clob; + l_copy_pos binary_integer := 1; + l_next_newline binary_integer := 0; + l_source_length binary_integer; begin l_comment_pos := 1; + l_comment_line := 1; + l_source_length := coalesce(dbms_lob.getlength(a_source), 0); + l_next_newline := dbms_lob.instr(a_source, chr(10), 1, 1); loop l_comment_pos := regexp_instr(srcstr => a_source @@ -151,30 +159,64 @@ create or replace package body ut_annotation_parser as -- position index is shifted by 1 because gc_annot_comment_pattern contains ^ as first sign -- but after instr index already points to the char on that line - l_comment_pos := l_comment_pos-1; - l_comment_line := length(substr(a_source,1,l_comment_pos))-length(replace(substr(a_source,1,l_comment_pos),chr(10)))+1; - l_comments(l_comment_line) := trim(regexp_substr(srcstr => a_source - ,pattern => gc_annot_comment_pattern - ,occurrence => 1 - ,position => l_comment_pos - ,modifier => 'm' - ,subexpression => 2)); + l_comment_pos := greatest(l_comment_pos - 1, 1); + while l_next_newline > 0 and l_next_newline < l_comment_pos loop + l_comment_line := l_comment_line + 1; + l_next_newline := dbms_lob.instr(a_source, chr(10), l_next_newline + 1, 1); + end loop; + + l_comment_text := trim(regexp_substr(srcstr => a_source + ,pattern => gc_annot_comment_pattern + ,occurrence => 1 + ,position => l_comment_pos + ,modifier => 'm' + ,subexpression => 2)); + l_comment_match := regexp_substr(srcstr => a_source + ,pattern => gc_annot_comment_pattern + ,occurrence => 1 + ,position => l_comment_pos + ,modifier => 'm'); + l_comments(l_comment_line) := l_comment_text; l_comment_replacer := replace(gc_comment_replacer_patter, '%N%', l_comment_line); - l_source := regexp_replace(srcstr => a_source - ,pattern => gc_annot_comment_pattern - ,replacestr => l_comment_replacer - ,position => l_comment_pos - ,occurrence => 1 - ,modifier => 'm'); - dbms_lob.freetemporary(a_source); - a_source := l_source; - dbms_lob.freetemporary(l_source); - l_comment_pos := l_comment_pos + length(l_comment_replacer); + if l_result is null then + dbms_lob.createtemporary(l_result, true); + end if; + + if l_comment_pos > l_copy_pos then + dbms_lob.copy( + dest_lob => l_result, + src_lob => a_source, + amount => l_comment_pos - l_copy_pos, + dest_offset => dbms_lob.getlength(l_result) + 1, + src_offset => l_copy_pos + ); + end if; + + ut_utils.append_to_clob(l_result, l_comment_replacer); + + l_copy_pos := l_comment_pos + length(l_comment_match); + l_comment_pos := l_copy_pos; end loop; + if l_result is not null then + if l_copy_pos <= l_source_length then + dbms_lob.copy( + dest_lob => l_result, + src_lob => a_source, + amount => l_source_length - l_copy_pos + 1, + dest_offset => dbms_lob.getlength(l_result) + 1, + src_offset => l_copy_pos + ); + end if; + if dbms_lob.istemporary(a_source) = 1 then + dbms_lob.freetemporary(a_source); + end if; + a_source := l_result; + end if; + ut_utils.debug_log(a_source); return l_comments; end extract_and_replace_comments; From 461ad5dc46fb8a8f0e8619b9db15b39618c90335 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 22:53:29 +0000 Subject: [PATCH 545/887] Another test --- source/core/annotations/ut_annotation_parser.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 0816b0652..08b051b14 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -160,7 +160,7 @@ create or replace package body ut_annotation_parser as -- position index is shifted by 1 because gc_annot_comment_pattern contains ^ as first sign -- but after instr index already points to the char on that line l_comment_pos := greatest(l_comment_pos - 1, 1); - while l_next_newline > 0 and l_next_newline < l_comment_pos loop + while l_next_newline > 0 and l_next_newline <= l_comment_pos loop l_comment_line := l_comment_line + 1; l_next_newline := dbms_lob.instr(a_source, chr(10), l_next_newline + 1, 1); end loop; From 44f5495bec78d91cb3ab947f6f71e741978ffedf Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 22:57:50 +0000 Subject: [PATCH 546/887] Test --- source/core/annotations/ut_annotation_parser.pkb | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 08b051b14..e0cd25712 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -140,13 +140,10 @@ create or replace package body ut_annotation_parser as l_comment_match varchar2(32767); l_result clob; l_copy_pos binary_integer := 1; - l_next_newline binary_integer := 0; l_source_length binary_integer; begin l_comment_pos := 1; - l_comment_line := 1; l_source_length := coalesce(dbms_lob.getlength(a_source), 0); - l_next_newline := dbms_lob.instr(a_source, chr(10), 1, 1); loop l_comment_pos := regexp_instr(srcstr => a_source @@ -159,11 +156,10 @@ create or replace package body ut_annotation_parser as -- position index is shifted by 1 because gc_annot_comment_pattern contains ^ as first sign -- but after instr index already points to the char on that line - l_comment_pos := greatest(l_comment_pos - 1, 1); - while l_next_newline > 0 and l_next_newline <= l_comment_pos loop - l_comment_line := l_comment_line + 1; - l_next_newline := dbms_lob.instr(a_source, chr(10), l_next_newline + 1, 1); - end loop; + l_comment_pos := l_comment_pos - 1; + l_comment_line := length(substr(a_source,1,l_comment_pos)) + - length(replace(substr(a_source,1,l_comment_pos),chr(10))) + + 1; l_comment_text := trim(regexp_substr(srcstr => a_source ,pattern => gc_annot_comment_pattern From b5f2dc78a4dae632af850c6a0027ddc2bd800fb4 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 23:02:05 +0000 Subject: [PATCH 547/887] Thats funny:) --- source/core/annotations/ut_annotation_parser.pkb | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index e0cd25712..2de9120f0 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -134,10 +134,10 @@ create or replace package body ut_annotation_parser as function extract_and_replace_comments(a_source in out nocopy clob) return tt_comment_list is l_comments tt_comment_list; l_comment_pos binary_integer; + l_comment_end_pos binary_integer; l_comment_line binary_integer; l_comment_replacer varchar2(50); l_comment_text varchar2(32767); - l_comment_match varchar2(32767); l_result clob; l_copy_pos binary_integer := 1; l_source_length binary_integer; @@ -167,11 +167,12 @@ create or replace package body ut_annotation_parser as ,position => l_comment_pos ,modifier => 'm' ,subexpression => 2)); - l_comment_match := regexp_substr(srcstr => a_source - ,pattern => gc_annot_comment_pattern - ,occurrence => 1 - ,position => l_comment_pos - ,modifier => 'm'); + l_comment_end_pos := regexp_instr(srcstr => a_source + ,pattern => gc_annot_comment_pattern + ,occurrence => 1 + ,return_option => 1 + ,position => l_comment_pos + ,modifier => 'm'); l_comments(l_comment_line) := l_comment_text; l_comment_replacer := replace(gc_comment_replacer_patter, '%N%', l_comment_line); @@ -192,7 +193,7 @@ create or replace package body ut_annotation_parser as ut_utils.append_to_clob(l_result, l_comment_replacer); - l_copy_pos := l_comment_pos + length(l_comment_match); + l_copy_pos := l_comment_end_pos; l_comment_pos := l_copy_pos; end loop; From 0dd7dba66794cd8b18d83d0a3bcac20836fa95de Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 23:05:56 +0000 Subject: [PATCH 548/887] that is rubbish --- source/core/annotations/ut_annotation_parser.pkb | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 2de9120f0..2aaa82a19 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -167,12 +167,7 @@ create or replace package body ut_annotation_parser as ,position => l_comment_pos ,modifier => 'm' ,subexpression => 2)); - l_comment_end_pos := regexp_instr(srcstr => a_source - ,pattern => gc_annot_comment_pattern - ,occurrence => 1 - ,return_option => 1 - ,position => l_comment_pos - ,modifier => 'm'); + l_comment_end_pos := regexp_instr(a_source, gc_annot_comment_pattern, l_comment_pos, 1, 1, 'm'); l_comments(l_comment_line) := l_comment_text; l_comment_replacer := replace(gc_comment_replacer_patter, '%N%', l_comment_line); From 4ea0fcb8278353fb3992c3bff6835940b634a927 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 23:09:29 +0000 Subject: [PATCH 549/887] revert test --- .../core/annotations/ut_annotation_parser.pkb | 66 +++++-------------- 1 file changed, 17 insertions(+), 49 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 2aaa82a19..3ec54c5c0 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -134,16 +134,11 @@ create or replace package body ut_annotation_parser as function extract_and_replace_comments(a_source in out nocopy clob) return tt_comment_list is l_comments tt_comment_list; l_comment_pos binary_integer; - l_comment_end_pos binary_integer; l_comment_line binary_integer; l_comment_replacer varchar2(50); - l_comment_text varchar2(32767); - l_result clob; - l_copy_pos binary_integer := 1; - l_source_length binary_integer; + l_source clob := a_source; begin l_comment_pos := 1; - l_source_length := coalesce(dbms_lob.getlength(a_source), 0); loop l_comment_pos := regexp_instr(srcstr => a_source @@ -160,55 +155,28 @@ create or replace package body ut_annotation_parser as l_comment_line := length(substr(a_source,1,l_comment_pos)) - length(replace(substr(a_source,1,l_comment_pos),chr(10))) + 1; - - l_comment_text := trim(regexp_substr(srcstr => a_source - ,pattern => gc_annot_comment_pattern - ,occurrence => 1 - ,position => l_comment_pos - ,modifier => 'm' - ,subexpression => 2)); - l_comment_end_pos := regexp_instr(a_source, gc_annot_comment_pattern, l_comment_pos, 1, 1, 'm'); - l_comments(l_comment_line) := l_comment_text; + l_comments(l_comment_line) := trim(regexp_substr(srcstr => a_source + ,pattern => gc_annot_comment_pattern + ,occurrence => 1 + ,position => l_comment_pos + ,modifier => 'm' + ,subexpression => 2)); l_comment_replacer := replace(gc_comment_replacer_patter, '%N%', l_comment_line); - if l_result is null then - dbms_lob.createtemporary(l_result, true); - end if; - - if l_comment_pos > l_copy_pos then - dbms_lob.copy( - dest_lob => l_result, - src_lob => a_source, - amount => l_comment_pos - l_copy_pos, - dest_offset => dbms_lob.getlength(l_result) + 1, - src_offset => l_copy_pos - ); - end if; - - ut_utils.append_to_clob(l_result, l_comment_replacer); - - l_copy_pos := l_comment_end_pos; - l_comment_pos := l_copy_pos; + l_source := regexp_replace(srcstr => a_source + ,pattern => gc_annot_comment_pattern + ,replacestr => l_comment_replacer + ,position => l_comment_pos + ,occurrence => 1 + ,modifier => 'm'); + dbms_lob.freetemporary(a_source); + a_source := l_source; + dbms_lob.freetemporary(l_source); + l_comment_pos := l_comment_pos + length(l_comment_replacer); end loop; - if l_result is not null then - if l_copy_pos <= l_source_length then - dbms_lob.copy( - dest_lob => l_result, - src_lob => a_source, - amount => l_source_length - l_copy_pos + 1, - dest_offset => dbms_lob.getlength(l_result) + 1, - src_offset => l_copy_pos - ); - end if; - if dbms_lob.istemporary(a_source) = 1 then - dbms_lob.freetemporary(a_source); - end if; - a_source := l_result; - end if; - ut_utils.debug_log(a_source); return l_comments; end extract_and_replace_comments; From 17604d8cb39aaec8d120974a98769d94d04eb074 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 23:23:59 +0000 Subject: [PATCH 550/887] Small tweaks --- .../core/annotations/ut_annotation_parser.pkb | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 3ec54c5c0..cbb577e1a 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -74,15 +74,12 @@ create or replace package body ut_annotation_parser as l_loop_index binary_integer := 1; l_annotation_index binary_integer; begin - -- loop while there are unprocessed comment blocks - while 0 != nvl(regexp_instr(srcstr => a_source - ,pattern => gc_comment_replacer_regex_ptrn - ,occurrence => l_loop_index - ,subexpression => 1) - ,0) loop + -- loop while there are unprocessed comment blocks + loop -- define index of the comment block and get it's content from cache l_annotation_index := regexp_substr( a_source ,gc_comment_replacer_regex_ptrn ,1 ,l_loop_index ,subexpression => 1); + exit when l_annotation_index is null; add_annotation( a_annotations, l_annotation_index, a_comments( l_annotation_index ), a_subobject_name ); l_loop_index := l_loop_index + 1; end loop; @@ -98,20 +95,13 @@ create or replace package body ut_annotation_parser as -- loop through procedures and functions of the package and get all the comment blocks just before it's declaration l_annot_proc_ind := 1; loop - --find annotated procedure index - l_annot_proc_ind := regexp_instr(srcstr => a_source - ,pattern => gc_annotation_block_pattern - ,occurrence => 1 - ,modifier => 'i' - ,position => l_annot_proc_ind); - exit when l_annot_proc_ind = 0; - --get the annotations with procedure name l_annot_proc_block := regexp_substr(srcstr => a_source ,pattern => gc_annotation_block_pattern ,position => l_annot_proc_ind ,occurrence => 1 ,modifier => 'i'); + exit when l_annot_proc_block is null; --extract the annotations l_proc_comments := trim(regexp_substr(srcstr => l_annot_proc_block From 5869f32585995336e1792180ec545c8a72fe28f0 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 23:26:56 +0000 Subject: [PATCH 551/887] one at the time --- source/core/annotations/ut_annotation_parser.pkb | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index cbb577e1a..4f5833ff3 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -95,13 +95,21 @@ create or replace package body ut_annotation_parser as -- loop through procedures and functions of the package and get all the comment blocks just before it's declaration l_annot_proc_ind := 1; loop + --find annotated procedure index + l_annot_proc_ind := regexp_instr(srcstr => a_source + ,pattern => gc_annotation_block_pattern + ,occurrence => 1 + ,modifier => 'i' + ,position => l_annot_proc_ind); + exit when l_annot_proc_ind = 0; + --get the annotations with procedure name l_annot_proc_block := regexp_substr(srcstr => a_source ,pattern => gc_annotation_block_pattern ,position => l_annot_proc_ind ,occurrence => 1 ,modifier => 'i'); - exit when l_annot_proc_block is null; + --extract the annotations l_proc_comments := trim(regexp_substr(srcstr => l_annot_proc_block From 3f8d2cf6012decdc999b29e6a7319ead46f55f04 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 23:38:51 +0000 Subject: [PATCH 552/887] Move out outside --- source/core/annotations/ut_annotation_parser.pkb | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 4f5833ff3..c10f42679 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -168,13 +168,14 @@ create or replace package body ut_annotation_parser as ,position => l_comment_pos ,occurrence => 1 ,modifier => 'm'); - dbms_lob.freetemporary(a_source); + --dbms_lob.freetemporary(a_source); a_source := l_source; - dbms_lob.freetemporary(l_source); + --dbms_lob.freetemporary(l_source); l_comment_pos := l_comment_pos + length(l_comment_replacer); end loop; - + dbms_lob.freetemporary(l_source); + dbms_lob.freetemporary(a_source); ut_utils.debug_log(a_source); return l_comments; end extract_and_replace_comments; From 37fae24df5988c122f3e61e3b15e1333e139727a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 23:41:55 +0000 Subject: [PATCH 553/887] fix invalid locator --- source/core/annotations/ut_annotation_parser.pkb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index c10f42679..3524b9669 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -137,6 +137,8 @@ create or replace package body ut_annotation_parser as l_source clob := a_source; begin l_comment_pos := 1; + dbms_lob.createtemporary(l_source, true); + dbms_lob.createtemporary(a_source, true); loop l_comment_pos := regexp_instr(srcstr => a_source From 518995584dccb4f269d6170224dd2d38dcbb7f11 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 9 Mar 2026 23:44:18 +0000 Subject: [PATCH 554/887] revert --- source/core/annotations/ut_annotation_parser.pkb | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 3524b9669..4f5833ff3 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -137,8 +137,6 @@ create or replace package body ut_annotation_parser as l_source clob := a_source; begin l_comment_pos := 1; - dbms_lob.createtemporary(l_source, true); - dbms_lob.createtemporary(a_source, true); loop l_comment_pos := regexp_instr(srcstr => a_source @@ -170,14 +168,13 @@ create or replace package body ut_annotation_parser as ,position => l_comment_pos ,occurrence => 1 ,modifier => 'm'); - --dbms_lob.freetemporary(a_source); + dbms_lob.freetemporary(a_source); a_source := l_source; - --dbms_lob.freetemporary(l_source); + dbms_lob.freetemporary(l_source); l_comment_pos := l_comment_pos + length(l_comment_replacer); end loop; - dbms_lob.freetemporary(l_source); - dbms_lob.freetemporary(a_source); + ut_utils.debug_log(a_source); return l_comments; end extract_and_replace_comments; From 9ac4a7ed0269773f02b96bc5d5333f9a5a4bf7ab Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 10 Mar 2026 06:28:04 +0000 Subject: [PATCH 555/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 0c1460d8f..fda0cb436 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4281 +4298 diff --git a/docs/about/authors.md b/docs/about/authors.md index de163c0cf..3c0117b09 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 18a13cd81..1e030f3f5 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 382b0e1c5..26c89912d 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 4a88483a5..058b84479 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 30ad6eaff..53f4c94aa 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index d8ddad0c5..5de9fb7fb 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 3d32b9de6..0c7c469ee 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index d5412673e..bd09e2d83 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index b6b66830d..0ea6a1208 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 0ea567077..e4143411e 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3c49f0cb5..bf9f29504 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 2c86f390e..c710607bc 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 876a73cf5..423eccea4 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 49c608edf..bef1e2156 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 6f8339a52..f86bce299 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index e9b646142..750497394 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 110be8f01..9effdcdbc 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4281--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 939384a85..a0d1e612c 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4281-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4298-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 5a217746ef9109cd96185310f92ee8ca6b01e32a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 14 Mar 2026 01:27:26 +0000 Subject: [PATCH 556/887] Changing a code to validate by lines instead of clobs for performance. --- .../core/annotations/ut_annotation_parser.pkb | 153 ++++++++++++++- .../core/annotations/ut_annotation_parser.pks | 2 + source/core/ut_utils.pkb | 176 ++++++++++++++++++ source/core/ut_utils.pks | 3 + 4 files changed, 330 insertions(+), 4 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 4f5833ff3..e3f8e8493 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -129,6 +129,78 @@ create or replace package body ut_annotation_parser as end loop; end add_procedure_annotations; + procedure add_procedure_annotations( + a_annotations in out nocopy ut_annotations, + a_source in dbms_preprocessor.source_lines_t, + a_comments in out nocopy tt_comment_list + ) is + l_proc_comments varchar2(32767); + l_proc_name varchar2(250); + l_line varchar2(32767); + l_in_comment_block boolean := false; + l_i binary_integer; + begin + l_i := 1; + while l_i <= a_source.count loop + l_line := a_source(l_i); + + -- ----------------------------------------------------------------- + -- Comment placeholder line: start/continue accumulating a block + -- ----------------------------------------------------------------- + if instr(l_line, '{COMMENT#') > 0 then + if l_in_comment_block then + l_proc_comments := l_proc_comments || l_line || chr(10); + else + l_in_comment_block := true; + l_proc_comments := l_line || chr(10); + end if; + l_i := l_i + 1; + + -- ----------------------------------------------------------------- + -- Whitespace-only line: allowed between comment block and proc decl + -- ----------------------------------------------------------------- + elsif l_in_comment_block and trim(replace(l_line, chr(9))) is null then + l_i := l_i + 1; + + -- ----------------------------------------------------------------- + -- procedure/function declaration following a comment block + -- ----------------------------------------------------------------- + elsif l_in_comment_block + and regexp_like(l_line, '^\s*(procedure|function)\s+', 'i') + then + -- extract just the identifier name (subexpression 2) + l_proc_name := trim(regexp_substr(l_line + ,pattern => '^\s*(procedure|function)\s+('||gc_regexp_identifier||')' + ,modifier => 'i' + ,subexpression => 2)); + + -- pass accumulated comment placeholders + proc name to add_annotations + add_annotations(a_annotations, l_proc_comments, a_comments, l_proc_name); + + -- reset comment block state + l_in_comment_block := false; + l_proc_comments := null; + + -- advance past proc header to the terminating ';' + -- the header may span multiple lines e.g. with multi-line parameter lists + while l_i <= a_source.count loop + exit when instr(a_source(l_i), ';') > 0; + l_i := l_i + 1; + end loop; + l_i := l_i + 1; -- step past the ';' line itself + + -- ----------------------------------------------------------------- + -- Any other line: reset comment block accumulator + -- ----------------------------------------------------------------- + else + l_in_comment_block := false; + l_proc_comments := null; + l_i := l_i + 1; + end if; + + end loop; + end add_procedure_annotations; + function extract_and_replace_comments(a_source in out nocopy clob) return tt_comment_list is l_comments tt_comment_list; l_comment_pos binary_integer; @@ -175,13 +247,87 @@ create or replace package body ut_annotation_parser as end loop; - ut_utils.debug_log(a_source); + return l_comments; + end extract_and_replace_comments; + + function extract_and_replace_comments( + a_source in out nocopy dbms_preprocessor.source_lines_t + ) return tt_comment_list is + l_comments tt_comment_list; + l_line varchar2(32767); + l_comment_pos binary_integer; + l_comment_replacer varchar2(50); + begin + for i in 1 .. a_source.count loop + l_line := a_source(i); + + -- fast path: skip lines that can't possibly match + -- must contain '--' and '%' to be an annotation comment + if instr(l_line, '--') = 0 or instr(l_line, gc_annotation_qualifier) = 0 then + continue; + end if; + + -- find '--' on the line + l_comment_pos := instr(l_line, '--'); + + -- verify everything before '--' is only spaces/tabs (matches ^ *( |\t)*--) + if trim(replace(substr(l_line, 1, l_comment_pos - 1), chr(9))) is not null then + continue; + end if; + + -- skip '--' and any spaces after it, then check for annotation qualifier '%' + l_comment_pos := l_comment_pos + 2; + -- skip optional spaces between -- and % + while l_comment_pos <= length(l_line) + and substr(l_line, l_comment_pos, 1) = ' ' + loop + l_comment_pos := l_comment_pos + 1; + end loop; + + -- must start with annotation qualifier at this position + if substr(l_line, l_comment_pos, 1) != gc_annotation_qualifier then + continue; + end if; + + -- extract annotation text (from % to end of line, trimmed) + l_comments(i) := trim(substr(l_line, l_comment_pos)); + + -- replace line with placeholder, preserving line number in token + l_comment_replacer := replace(gc_comment_replacer_patter, '%N%', i); + a_source(i) := l_comment_replacer; + + end loop; + return l_comments; end extract_and_replace_comments; ------------------------------------------------------------ --public definitions ------------------------------------------------------------ + function parse_object_annotations(a_source dbms_preprocessor.source_lines_t) return ut_annotations is + l_source dbms_preprocessor.source_lines_t := a_source; + l_comments tt_comment_list; + l_annotations ut_annotations := ut_annotations(); + l_result ut_annotations; + l_comment_index positive; + begin + l_source := ut_utils.replace_multiline_comments(l_source); + l_comments := extract_and_replace_comments(l_source); + add_procedure_annotations(l_annotations, l_source, l_comments); + delete_processed_comments(l_comments, l_annotations); + + --at this point, only the comments not related to procedures are left, so we process them all as top-level + l_comment_index := l_comments.first; + while l_comment_index is not null loop + add_annotation( l_annotations, l_comment_index, l_comments( l_comment_index ) ); + l_comment_index := l_comments.next(l_comment_index); + end loop; + + select /*+ no_parallel */ value(x) bulk collect into l_result from table(l_annotations) x order by x.position; + + return l_result; + + end parse_object_annotations; function parse_object_annotations(a_source clob) return ut_annotations is l_source clob := a_source; @@ -217,7 +363,7 @@ create or replace package body ut_annotation_parser as function parse_object_annotations(a_source_lines dbms_preprocessor.source_lines_t, a_object_type varchar2) return ut_annotations is l_processed_lines dbms_preprocessor.source_lines_t; - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_annotations ut_annotations := ut_annotations(); ex_package_is_wrapped exception; pragma exception_init(ex_package_is_wrapped, -24241); @@ -235,11 +381,10 @@ create or replace package body ut_annotation_parser as end if; --convert to clob for i in 1..l_processed_lines.count loop - ut_utils.append_to_clob(l_source, replace(l_processed_lines(i), chr(13)||chr(10), chr(10))); + l_source(i) := replace(l_processed_lines(i), chr(13)||chr(10), chr(10)); end loop; --parse annotations l_annotations := parse_object_annotations(l_source); - dbms_lob.freetemporary(l_source); exception when ex_package_is_wrapped or source_text_is_empty then null; diff --git a/source/core/annotations/ut_annotation_parser.pks b/source/core/annotations/ut_annotation_parser.pks index 2f474c883..5a041ccb4 100644 --- a/source/core/annotations/ut_annotation_parser.pks +++ b/source/core/annotations/ut_annotation_parser.pks @@ -40,5 +40,7 @@ create or replace package ut_annotation_parser authid current_user as */ function parse_object_annotations(a_source clob) return ut_annotations; + function parse_object_annotations(a_source dbms_preprocessor.source_lines_t) return ut_annotations; + end; / diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 81d47221b..a5f69a54e 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -658,6 +658,182 @@ create or replace package body ut_utils is return l_result; end; + function replace_multiline_comments(a_source dbms_preprocessor.source_lines_t) + return dbms_preprocessor.source_lines_t + is + l_result dbms_preprocessor.source_lines_t; + l_line varchar2(32767); + l_remaining varchar2(32767); + l_in_ml_comment boolean := false; + l_ml_end binary_integer; + l_ml_start binary_integer; + l_comment_start binary_integer; + l_text_start binary_integer; + l_eq_text_start binary_integer; + l_eq_end_char varchar2(1 char); + l_pos binary_integer; + l_end binary_integer; + l_token_count binary_integer; + l_has_ml_comment boolean := false; + begin + + -- Guard: empty source + if a_source.count = 0 then + return a_source; + end if; + + -- Fast pre-scan: check if any /* exists at all if not, nothing to do — return source as-is + for i in 1 .. a_source.count loop + if instr(a_source(i), '/*') > 0 then + l_has_ml_comment := true; + exit prescan; + end if; + end loop prescan; + + if not l_has_ml_comment then + return a_source; + end if; + + <> + for i in 1 .. a_source.count loop + l_line := a_source(i); + -- Fast path: currently inside a multi-line comment + if l_in_ml_comment then + l_ml_end := instr(l_line, '*/'); + if l_ml_end > 0 then + l_in_ml_comment := false; + l_line := substr(l_line, l_ml_end + 2); + -- fall through to normal scan of remainder + else + l_result(i) := ''; + continue process_lines; + end if; + end if; + + -- Fast path: no special tokens on this line at all + if instr(l_line, '/') = 0 + and instr(l_line, '-') = 0 + and instr(l_line, '''') = 0 + then + l_result(i) := l_line; + continue process_lines; + end if; + + -- Normal scan: consume one token at a time, advance l_remaining + l_remaining := l_line; + l_line := null; + + <> + loop + exit when l_remaining is null or l_remaining = ''; + + l_ml_start := instr(l_remaining, '/*'); + l_comment_start := instr(l_remaining, '--'); + l_text_start := instr(l_remaining, ''''); + -- only search for q' if ' was found — q' always contains ' + l_eq_text_start := case when l_text_start > 0 + then instr(l_remaining, 'q''') + else 0 + end; + + -- count how many tokens are present + l_token_count := sign(l_ml_start) + sign(l_comment_start) + + sign(l_text_start) + sign(l_eq_text_start); + + -- no special tokens left — consume remainder and stop + if l_token_count = 0 then + l_line := l_line || l_remaining; + exit scan_line; + end if; + + -- only one token present — skip LEAST, use GREATEST to find it + if l_token_count = 1 then + l_pos := greatest(l_ml_start, l_comment_start, l_text_start, l_eq_text_start); + else + l_pos := least( + case when l_ml_start > 0 then l_ml_start else 32767 end, + case when l_comment_start > 0 then l_comment_start else 32767 end, + case when l_text_start > 0 then l_text_start else 32767 end, + case when l_eq_text_start > 0 then l_eq_text_start else 32767 end + ); + end if; + + -- q-quoted string: checked before plain quote because q' contains ' and would be misidentified + if l_pos = l_eq_text_start + and (l_ml_start = 0 or l_eq_text_start < l_ml_start) + and (l_comment_start = 0 or l_eq_text_start < l_comment_start) + and (l_text_start = 0 or l_eq_text_start < l_text_start) + then + l_eq_end_char := translate( + substr(l_remaining, l_eq_text_start + 2, 1), + '[{(<', ']})>' + ); + l_end := instr(l_remaining, l_eq_end_char || '''', l_eq_text_start + 3); + if l_end > 0 then + l_line := l_line || substr(l_remaining, 1, l_end + 1); + l_remaining := substr(l_remaining, l_end + 2); + else + l_line := l_line || l_remaining; + exit scan_line; + end if; + + -- Multi-line comment: skip it, continue scanning remainder of line after comment end + elsif l_pos = l_ml_start + and (l_comment_start = 0 or l_ml_start < l_comment_start) + and (l_text_start = 0 or l_ml_start < l_text_start) + and (l_eq_text_start = 0 or l_ml_start < l_eq_text_start) + then + l_line := l_line || substr(l_remaining, 1, l_ml_start - 1); + l_ml_end := instr(l_remaining, '*/', l_ml_start + 2); + if l_ml_end > 0 then + l_remaining := substr(l_remaining, l_ml_end + 2); + else + l_in_ml_comment := true; + exit scan_line; + end if; + + -- Single-line comment: keep it, stop scanning this line + elsif l_pos = l_comment_start + and (l_ml_start = 0 or l_comment_start < l_ml_start) + and (l_text_start = 0 or l_comment_start < l_text_start) + and (l_eq_text_start = 0 or l_comment_start < l_eq_text_start) + then + l_line := l_line || l_remaining; + exit scan_line; + + -- Regular string literal: keep it, continue scanning remainder of line after closing quote + else + -- scan forward continuously to handle '' escaped quotes + l_end := l_text_start + 1; + loop + l_end := instr(l_remaining, '''', l_end); + exit when l_end = 0; + if substr(l_remaining, l_end, 2) = '''''' then + l_end := l_end + 2; -- skip escaped quote, keep scanning + else + exit; -- found real closing quote + end if; + end loop; + + if l_end > 0 then + l_line := l_line || substr(l_remaining, 1, l_end); + l_remaining := substr(l_remaining, l_end + 1); + else + l_line := l_line || l_remaining; + exit scan_line; + end if; + end if; + + end loop scan_line; + + l_result(i) := l_line; + + end loop process_lines; + + return l_result; + end replace_multiline_comments; + + function replace_multiline_comments(a_source clob) return clob is l_result clob; l_ml_comment_start binary_integer := 1; diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 939384a85..49ea0615f 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -405,6 +405,9 @@ create or replace package ut_utils authid definer is /** * Replaces multi-line comments in given source-code with empty lines */ + function replace_multiline_comments(a_source dbms_preprocessor.source_lines_t) + return dbms_preprocessor.source_lines_t; + function replace_multiline_comments(a_source clob) return clob; /** From 39f5d6474ac57706171cdc395aa0215555962555 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sat, 14 Mar 2026 01:33:05 +0000 Subject: [PATCH 557/887] Fixing loop syntax --- source/core/ut_utils.pkb | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index a5f69a54e..ca7a5e412 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -683,6 +683,7 @@ create or replace package body ut_utils is end if; -- Fast pre-scan: check if any /* exists at all if not, nothing to do — return source as-is + <> for i in 1 .. a_source.count loop if instr(a_source(i), '/*') > 0 then l_has_ml_comment := true; @@ -697,20 +698,21 @@ create or replace package body ut_utils is <> for i in 1 .. a_source.count loop l_line := a_source(i); - -- Fast path: currently inside a multi-line comment + + -- Fast path: currently inside a multi-line comment, look only for closing */ if l_in_ml_comment then l_ml_end := instr(l_line, '*/'); if l_ml_end > 0 then l_in_ml_comment := false; l_line := substr(l_line, l_ml_end + 2); - -- fall through to normal scan of remainder + -- fall through to normal scan of remainder of line, in case there are more /* comments on the same line else l_result(i) := ''; continue process_lines; end if; end if; - -- Fast path: no special tokens on this line at all + -- Fast path: no special tokens on this line at all, just copy it to result and move on if instr(l_line, '/') = 0 and instr(l_line, '-') = 0 and instr(l_line, '''') = 0 @@ -719,7 +721,7 @@ create or replace package body ut_utils is continue process_lines; end if; - -- Normal scan: consume one token at a time, advance l_remaining + -- Normal scan: consume one token at a time, advance l_remaining until end of line l_remaining := l_line; l_line := null; @@ -730,23 +732,23 @@ create or replace package body ut_utils is l_ml_start := instr(l_remaining, '/*'); l_comment_start := instr(l_remaining, '--'); l_text_start := instr(l_remaining, ''''); - -- only search for q' if ' was found — q' always contains ' + -- only search for q' if ' was found — q' always contains ' and would be misidentified otherwise l_eq_text_start := case when l_text_start > 0 then instr(l_remaining, 'q''') else 0 end; - -- count how many tokens are present + -- count how many tokens are present to decide if we can skip LEAST/GREATEST and just use the one that is present l_token_count := sign(l_ml_start) + sign(l_comment_start) + sign(l_text_start) + sign(l_eq_text_start); - -- no special tokens left — consume remainder and stop + -- no special tokens left — consume remainder and stop scanning this line if l_token_count = 0 then l_line := l_line || l_remaining; exit scan_line; end if; - -- only one token present — skip LEAST, use GREATEST to find it + -- only one token present — skip LEAST, use GREATEST to find it since 0 means not present and any positive value is a valid position if l_token_count = 1 then l_pos := greatest(l_ml_start, l_comment_start, l_text_start, l_eq_text_start); else @@ -777,7 +779,7 @@ create or replace package body ut_utils is exit scan_line; end if; - -- Multi-line comment: skip it, continue scanning remainder of line after comment end + -- Multi-line comment start: skip it, look for end of comment, continue scanning line after it elsif l_pos = l_ml_start and (l_comment_start = 0 or l_ml_start < l_comment_start) and (l_text_start = 0 or l_ml_start < l_text_start) @@ -792,7 +794,7 @@ create or replace package body ut_utils is exit scan_line; end if; - -- Single-line comment: keep it, stop scanning this line + -- Single-line comment: keep it, stop scanning this line since everything after -- is comment anyway elsif l_pos = l_comment_start and (l_ml_start = 0 or l_comment_start < l_ml_start) and (l_text_start = 0 or l_comment_start < l_text_start) @@ -801,7 +803,7 @@ create or replace package body ut_utils is l_line := l_line || l_remaining; exit scan_line; - -- Regular string literal: keep it, continue scanning remainder of line after closing quote + -- Regular string literal start: keep it, scan forward for closing quote, handle '' escaped quotes properly by skipping them and keep scanning else -- scan forward continuously to handle '' escaped quotes l_end := l_text_start + 1; @@ -833,7 +835,6 @@ create or replace package body ut_utils is return l_result; end replace_multiline_comments; - function replace_multiline_comments(a_source clob) return clob is l_result clob; l_ml_comment_start binary_integer := 1; @@ -1201,4 +1202,4 @@ create or replace package body ut_utils is end; end ut_utils; -/ +/ \ No newline at end of file From 393cfec4c19850833ef29a241f3f61246c1752f9 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 01:13:39 +0000 Subject: [PATCH 558/887] Update code --- source/core/annotations/ut_annotation_parser.pkb | 1 - 1 file changed, 1 deletion(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index e3f8e8493..6e790a861 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -379,7 +379,6 @@ create or replace package body ut_annotation_parser as else l_processed_lines := sys.dbms_preprocessor.get_post_processed_source(a_source_lines); end if; - --convert to clob for i in 1..l_processed_lines.count loop l_source(i) := replace(l_processed_lines(i), chr(13)||chr(10), chr(10)); end loop; From 8d794f013eb19c14aae121f1921794785864802c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 01:19:45 +0000 Subject: [PATCH 559/887] Update block --- source/core/annotations/ut_annotation_parser.pkb | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 6e790a861..9dc0b6aef 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -143,20 +143,16 @@ create or replace package body ut_annotation_parser as l_i := 1; while l_i <= a_source.count loop l_line := a_source(l_i); - - -- ----------------------------------------------------------------- -- Comment placeholder line: start/continue accumulating a block - -- ----------------------------------------------------------------- - if instr(l_line, '{COMMENT#') > 0 then + if instr(l_line, chr(123) ||'COMMENT#') > 0 then if l_in_comment_block then l_proc_comments := l_proc_comments || l_line || chr(10); else l_in_comment_block := true; - l_proc_comments := l_line || chr(10); + l_proc_comments := l_line || chr(10); end if; l_i := l_i + 1; - -- ----------------------------------------------------------------- -- Whitespace-only line: allowed between comment block and proc decl -- ----------------------------------------------------------------- elsif l_in_comment_block and trim(replace(l_line, chr(9))) is null then From a32e09da846cafb5c673d481594a18a60a60424c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 01:31:11 +0000 Subject: [PATCH 560/887] Small fixes --- source/core/annotations/ut_annotation_parser.pkb | 11 +---------- source/core/ut_utils.pkb | 10 ++++++---- 2 files changed, 7 insertions(+), 14 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 9dc0b6aef..8df89be28 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -152,15 +152,10 @@ create or replace package body ut_annotation_parser as l_proc_comments := l_line || chr(10); end if; l_i := l_i + 1; - -- Whitespace-only line: allowed between comment block and proc decl - -- ----------------------------------------------------------------- elsif l_in_comment_block and trim(replace(l_line, chr(9))) is null then l_i := l_i + 1; - - -- ----------------------------------------------------------------- -- procedure/function declaration following a comment block - -- ----------------------------------------------------------------- elsif l_in_comment_block and regexp_like(l_line, '^\s*(procedure|function)\s+', 'i') then @@ -184,16 +179,12 @@ create or replace package body ut_annotation_parser as l_i := l_i + 1; end loop; l_i := l_i + 1; -- step past the ';' line itself - - -- ----------------------------------------------------------------- -- Any other line: reset comment block accumulator - -- ----------------------------------------------------------------- else l_in_comment_block := false; - l_proc_comments := null; + l_proc_comments := null; l_i := l_i + 1; end if; - end loop; end add_procedure_annotations; diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index ca7a5e412..3790af93e 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -675,6 +675,9 @@ create or replace package body ut_utils is l_end binary_integer; l_token_count binary_integer; l_has_ml_comment boolean := false; + + l_open_chars varchar2(4):= chr(91) || chr(123) || chr(40) || chr(60); -- [{( + l_close_chars varchar2(4):= chr(93) || chr(125) || chr(41) || chr(62); -- ]})> begin -- Guard: empty source @@ -766,10 +769,9 @@ create or replace package body ut_utils is and (l_comment_start = 0 or l_eq_text_start < l_comment_start) and (l_text_start = 0 or l_eq_text_start < l_text_start) then - l_eq_end_char := translate( - substr(l_remaining, l_eq_text_start + 2, 1), - '[{(<', ']})>' - ); + + + l_eq_end_char := translate(substr(l_remaining, l_eq_text_start + 2, 1),l_open_chars,l_close_chars); l_end := instr(l_remaining, l_eq_end_char || '''', l_eq_text_start + 3); if l_end > 0 then l_line := l_line || substr(l_remaining, 1, l_end + 1); From b2e914f3dc783a794c05c24bf7ea50ee3824f97c Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 01:34:53 +0000 Subject: [PATCH 561/887] Update comment --- source/core/ut_utils.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 3790af93e..4b341e1a1 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -895,7 +895,7 @@ create or replace package body ut_utils is and (l_escaped_text_start < l_comment_start or l_comment_start = 0) and (l_escaped_text_start < l_text_start or l_text_start = 0) then --translate char "[" from the start of quoted text "q'[someting]'" into "]" - l_escaped_text_end_char := translate( substr(a_source, l_escaped_text_start + 2, 1), '[{(<', ']})>'); + l_escaped_text_end_char := translate(substr(a_source, l_escaped_text_start + 2, 1),l_open_chars,l_close_chars); l_end := instr(a_source,l_escaped_text_end_char||'''',l_escaped_text_start + 3 ); if l_end > 0 then l_end := l_end + 2; From 66de806889fa5aae6308954cc8440036d75e13e6 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 01:43:13 +0000 Subject: [PATCH 562/887] Introduce global variable --- source/core/ut_utils.pkb | 61 +++++++++++++++------------------------- 1 file changed, 22 insertions(+), 39 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 4b341e1a1..b525ca7d8 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -23,7 +23,8 @@ create or replace package body ut_utils is gc_invalid_xml_char constant varchar2(50) := '[^_[:alnum:]\.-]'; gc_full_valid_xml_name constant varchar2(50) := '^([[:alpha:]])([_[:alnum:]\.-])*$'; gc_owner_hash constant integer(11) := dbms_utility.get_hash_value( ut_owner(), 0, power(2,31)-1); - + gc_open_chars constant varchar2(4):= chr(91) || chr(123) || chr(40) || chr(60); -- [{( + gc_close_chars constant varchar2(4):= chr(93) || chr(125) || chr(41) || chr(62); -- ]})> function surround_with(a_value varchar2, a_quote_char varchar2) return varchar2 is begin @@ -674,10 +675,7 @@ create or replace package body ut_utils is l_pos binary_integer; l_end binary_integer; l_token_count binary_integer; - l_has_ml_comment boolean := false; - - l_open_chars varchar2(4):= chr(91) || chr(123) || chr(40) || chr(60); -- [{( - l_close_chars varchar2(4):= chr(93) || chr(125) || chr(41) || chr(62); -- ]})> + l_has_ml_comment boolean := false; begin -- Guard: empty source @@ -686,19 +684,17 @@ create or replace package body ut_utils is end if; -- Fast pre-scan: check if any /* exists at all if not, nothing to do — return source as-is - <> for i in 1 .. a_source.count loop if instr(a_source(i), '/*') > 0 then l_has_ml_comment := true; - exit prescan; + exit; end if; - end loop prescan; + end loop; if not l_has_ml_comment then return a_source; end if; - <> for i in 1 .. a_source.count loop l_line := a_source(i); @@ -711,7 +707,7 @@ create or replace package body ut_utils is -- fall through to normal scan of remainder of line, in case there are more /* comments on the same line else l_result(i) := ''; - continue process_lines; + continue; end if; end if; @@ -721,7 +717,7 @@ create or replace package body ut_utils is and instr(l_line, '''') = 0 then l_result(i) := l_line; - continue process_lines; + continue; end if; -- Normal scan: consume one token at a time, advance l_remaining until end of line @@ -731,16 +727,11 @@ create or replace package body ut_utils is <> loop exit when l_remaining is null or l_remaining = ''; - l_ml_start := instr(l_remaining, '/*'); l_comment_start := instr(l_remaining, '--'); l_text_start := instr(l_remaining, ''''); -- only search for q' if ' was found — q' always contains ' and would be misidentified otherwise - l_eq_text_start := case when l_text_start > 0 - then instr(l_remaining, 'q''') - else 0 - end; - + l_eq_text_start := case when l_text_start > 0 then instr(l_remaining, 'q''') else 0 end; -- count how many tokens are present to decide if we can skip LEAST/GREATEST and just use the one that is present l_token_count := sign(l_ml_start) + sign(l_comment_start) + sign(l_text_start) + sign(l_eq_text_start); @@ -756,38 +747,35 @@ create or replace package body ut_utils is l_pos := greatest(l_ml_start, l_comment_start, l_text_start, l_eq_text_start); else l_pos := least( - case when l_ml_start > 0 then l_ml_start else 32767 end, + case when l_ml_start > 0 then l_ml_start else 32767 end, case when l_comment_start > 0 then l_comment_start else 32767 end, - case when l_text_start > 0 then l_text_start else 32767 end, + case when l_text_start > 0 then l_text_start else 32767 end, case when l_eq_text_start > 0 then l_eq_text_start else 32767 end ); end if; -- q-quoted string: checked before plain quote because q' contains ' and would be misidentified if l_pos = l_eq_text_start - and (l_ml_start = 0 or l_eq_text_start < l_ml_start) + and (l_ml_start = 0 or l_eq_text_start < l_ml_start) and (l_comment_start = 0 or l_eq_text_start < l_comment_start) - and (l_text_start = 0 or l_eq_text_start < l_text_start) + and (l_text_start = 0 or l_eq_text_start < l_text_start) then - - - l_eq_end_char := translate(substr(l_remaining, l_eq_text_start + 2, 1),l_open_chars,l_close_chars); + l_eq_end_char := translate(substr(l_remaining, l_eq_text_start + 2, 1),gc_open_chars,gc_close_chars); l_end := instr(l_remaining, l_eq_end_char || '''', l_eq_text_start + 3); if l_end > 0 then - l_line := l_line || substr(l_remaining, 1, l_end + 1); + l_line := l_line || substr(l_remaining, 1, l_end + 1); l_remaining := substr(l_remaining, l_end + 2); else l_line := l_line || l_remaining; exit scan_line; end if; - -- Multi-line comment start: skip it, look for end of comment, continue scanning line after it elsif l_pos = l_ml_start and (l_comment_start = 0 or l_ml_start < l_comment_start) - and (l_text_start = 0 or l_ml_start < l_text_start) + and (l_text_start = 0 or l_ml_start < l_text_start) and (l_eq_text_start = 0 or l_ml_start < l_eq_text_start) then - l_line := l_line || substr(l_remaining, 1, l_ml_start - 1); + l_line := l_line || substr(l_remaining, 1, l_ml_start - 1); l_ml_end := instr(l_remaining, '*/', l_ml_start + 2); if l_ml_end > 0 then l_remaining := substr(l_remaining, l_ml_end + 2); @@ -795,16 +783,14 @@ create or replace package body ut_utils is l_in_ml_comment := true; exit scan_line; end if; - -- Single-line comment: keep it, stop scanning this line since everything after -- is comment anyway elsif l_pos = l_comment_start - and (l_ml_start = 0 or l_comment_start < l_ml_start) - and (l_text_start = 0 or l_comment_start < l_text_start) + and (l_ml_start = 0 or l_comment_start < l_ml_start) + and (l_text_start = 0 or l_comment_start < l_text_start) and (l_eq_text_start = 0 or l_comment_start < l_eq_text_start) then l_line := l_line || l_remaining; exit scan_line; - -- Regular string literal start: keep it, scan forward for closing quote, handle '' escaped quotes properly by skipping them and keep scanning else -- scan forward continuously to handle '' escaped quotes @@ -820,20 +806,17 @@ create or replace package body ut_utils is end loop; if l_end > 0 then - l_line := l_line || substr(l_remaining, 1, l_end); + l_line := l_line || substr(l_remaining, 1, l_end); l_remaining := substr(l_remaining, l_end + 1); else l_line := l_line || l_remaining; exit scan_line; end if; - end if; + end if; end loop scan_line; - l_result(i) := l_line; - - end loop process_lines; - + end loop; return l_result; end replace_multiline_comments; @@ -895,7 +878,7 @@ create or replace package body ut_utils is and (l_escaped_text_start < l_comment_start or l_comment_start = 0) and (l_escaped_text_start < l_text_start or l_text_start = 0) then --translate char "[" from the start of quoted text "q'[someting]'" into "]" - l_escaped_text_end_char := translate(substr(a_source, l_escaped_text_start + 2, 1),l_open_chars,l_close_chars); + l_escaped_text_end_char := translate(substr(a_source, l_escaped_text_start + 2, 1),gc_open_chars,gc_close_chars); l_end := instr(a_source,l_escaped_text_end_char||'''',l_escaped_text_start + 3 ); if l_end > 0 then l_end := l_end + 2; From f82a3b556c2a5a64c196f0fb1a7b22b77999079b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 01:50:31 +0000 Subject: [PATCH 563/887] Cleanup --- source/core/ut_utils.pkb | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index b525ca7d8..ffce364ae 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -25,7 +25,8 @@ create or replace package body ut_utils is gc_owner_hash constant integer(11) := dbms_utility.get_hash_value( ut_owner(), 0, power(2,31)-1); gc_open_chars constant varchar2(4):= chr(91) || chr(123) || chr(40) || chr(60); -- [{( gc_close_chars constant varchar2(4):= chr(93) || chr(125) || chr(41) || chr(62); -- ]})> - + gc_max_plsql_source_len constant integer := 32767; + function surround_with(a_value varchar2, a_quote_char varchar2) return varchar2 is begin return case when a_quote_char is not null then a_quote_char||a_value||a_quote_char else a_value end; @@ -677,8 +678,6 @@ create or replace package body ut_utils is l_token_count binary_integer; l_has_ml_comment boolean := false; begin - - -- Guard: empty source if a_source.count = 0 then return a_source; end if; @@ -747,10 +746,10 @@ create or replace package body ut_utils is l_pos := greatest(l_ml_start, l_comment_start, l_text_start, l_eq_text_start); else l_pos := least( - case when l_ml_start > 0 then l_ml_start else 32767 end, - case when l_comment_start > 0 then l_comment_start else 32767 end, - case when l_text_start > 0 then l_text_start else 32767 end, - case when l_eq_text_start > 0 then l_eq_text_start else 32767 end + case when l_ml_start > 0 then l_ml_start else gc_max_plsql_source_len end, + case when l_comment_start > 0 then l_comment_start else gc_max_plsql_source_len end, + case when l_text_start > 0 then l_text_start else gc_max_plsql_source_len end, + case when l_eq_text_start > 0 then l_eq_text_start else gc_max_plsql_source_len end ); end if; From 934df679122110a3bf23634d325065d585b1bf00 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 01:55:50 +0000 Subject: [PATCH 564/887] Optimization fiurther --- source/core/ut_utils.pkb | 101 +++++++++++++++++---------------------- 1 file changed, 45 insertions(+), 56 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index ffce364ae..f62e10aa2 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -675,14 +675,13 @@ create or replace package body ut_utils is l_eq_end_char varchar2(1 char); l_pos binary_integer; l_end binary_integer; - l_token_count binary_integer; - l_has_ml_comment boolean := false; + l_has_ml_comment boolean := false; begin if a_source.count = 0 then return a_source; end if; - -- Fast pre-scan: check if any /* exists at all if not, nothing to do — return source as-is + -- Fast pre-scan to check for presence of multi-line comments; if none, return original source unmodified for i in 1 .. a_source.count loop if instr(a_source(i), '/*') > 0 then l_has_ml_comment := true; @@ -697,20 +696,20 @@ create or replace package body ut_utils is for i in 1 .. a_source.count loop l_line := a_source(i); - -- Fast path: currently inside a multi-line comment, look only for closing */ + -- Fast path: inside multi-line comment if l_in_ml_comment then l_ml_end := instr(l_line, '*/'); if l_ml_end > 0 then l_in_ml_comment := false; l_line := substr(l_line, l_ml_end + 2); - -- fall through to normal scan of remainder of line, in case there are more /* comments on the same line + -- fall through to normal scan else l_result(i) := ''; continue; end if; end if; - -- Fast path: no special tokens on this line at all, just copy it to result and move on + -- Fast path: no special tokens on this line if instr(l_line, '/') = 0 and instr(l_line, '-') = 0 and instr(l_line, '''') = 0 @@ -719,7 +718,7 @@ create or replace package body ut_utils is continue; end if; - -- Normal scan: consume one token at a time, advance l_remaining until end of line + -- Normal scan l_remaining := l_line; l_line := null; @@ -729,83 +728,71 @@ create or replace package body ut_utils is l_ml_start := instr(l_remaining, '/*'); l_comment_start := instr(l_remaining, '--'); l_text_start := instr(l_remaining, ''''); - -- only search for q' if ' was found — q' always contains ' and would be misidentified otherwise - l_eq_text_start := case when l_text_start > 0 then instr(l_remaining, 'q''') else 0 end; - -- count how many tokens are present to decide if we can skip LEAST/GREATEST and just use the one that is present - l_token_count := sign(l_ml_start) + sign(l_comment_start) - + sign(l_text_start) + sign(l_eq_text_start); - - -- no special tokens left — consume remainder and stop scanning this line - if l_token_count = 0 then + -- q' always puts ' at l_text_start; just check the char immediately before it + l_eq_text_start := case + when l_text_start > 1 and substr(l_remaining, l_text_start - 1, 1) = 'q' + then l_text_start - 1 + else 0 + end; + -- Sentinel gc_max_plsql_source_len means "not present"; 32767 is beyond any VARCHAR2 position + l_pos := least( + case when l_ml_start > 0 then l_ml_start else gc_max_plsql_source_len end, + case when l_comment_start > 0 then l_comment_start else gc_max_plsql_source_len end, + case when l_text_start > 0 then l_text_start else gc_max_plsql_source_len end, + case when l_eq_text_start > 0 then l_eq_text_start else gc_max_plsql_source_len end + ); + + if l_pos = gc_max_plsql_source_len then l_line := l_line || l_remaining; exit scan_line; end if; - -- only one token present — skip LEAST, use GREATEST to find it since 0 means not present and any positive value is a valid position - if l_token_count = 1 then - l_pos := greatest(l_ml_start, l_comment_start, l_text_start, l_eq_text_start); - else - l_pos := least( - case when l_ml_start > 0 then l_ml_start else gc_max_plsql_source_len end, - case when l_comment_start > 0 then l_comment_start else gc_max_plsql_source_len end, - case when l_text_start > 0 then l_text_start else gc_max_plsql_source_len end, - case when l_eq_text_start > 0 then l_eq_text_start else gc_max_plsql_source_len end - ); - end if; - - -- q-quoted string: checked before plain quote because q' contains ' and would be misidentified - if l_pos = l_eq_text_start - and (l_ml_start = 0 or l_eq_text_start < l_ml_start) - and (l_comment_start = 0 or l_eq_text_start < l_comment_start) - and (l_text_start = 0 or l_eq_text_start < l_text_start) - then - l_eq_end_char := translate(substr(l_remaining, l_eq_text_start + 2, 1),gc_open_chars,gc_close_chars); - l_end := instr(l_remaining, l_eq_end_char || '''', l_eq_text_start + 3); + l_line := l_line || substr(l_remaining, 1, l_pos - 1); + l_remaining := substr(l_remaining, l_pos); + -- l_remaining now starts exactly at the token; all branch offsets below are relative to 1 + if l_pos = l_eq_text_start then + -- q-quoted string: l_remaining starts at 'q', delimiter is at position 3 + l_eq_end_char := translate(substr(l_remaining, 3, 1), gc_open_chars, gc_close_chars); + l_end := instr(l_remaining, l_eq_end_char || '''', 4); if l_end > 0 then - l_line := l_line || substr(l_remaining, 1, l_end + 1); + l_line := l_line || substr(l_remaining, 1, l_end + 1); l_remaining := substr(l_remaining, l_end + 2); else l_line := l_line || l_remaining; exit scan_line; end if; - -- Multi-line comment start: skip it, look for end of comment, continue scanning line after it - elsif l_pos = l_ml_start - and (l_comment_start = 0 or l_ml_start < l_comment_start) - and (l_text_start = 0 or l_ml_start < l_text_start) - and (l_eq_text_start = 0 or l_ml_start < l_eq_text_start) - then - l_line := l_line || substr(l_remaining, 1, l_ml_start - 1); - l_ml_end := instr(l_remaining, '*/', l_ml_start + 2); + + elsif l_pos = l_ml_start then + -- Multi-line comment: l_remaining starts at '/*', so end search starts at 3 + l_ml_end := instr(l_remaining, '*/', 3); if l_ml_end > 0 then l_remaining := substr(l_remaining, l_ml_end + 2); else l_in_ml_comment := true; exit scan_line; end if; - -- Single-line comment: keep it, stop scanning this line since everything after -- is comment anyway - elsif l_pos = l_comment_start - and (l_ml_start = 0 or l_comment_start < l_ml_start) - and (l_text_start = 0 or l_comment_start < l_text_start) - and (l_eq_text_start = 0 or l_comment_start < l_eq_text_start) - then + + elsif l_pos = l_comment_start then + -- Single-line comment: everything from here is comment, keep and stop l_line := l_line || l_remaining; exit scan_line; - -- Regular string literal start: keep it, scan forward for closing quote, handle '' escaped quotes properly by skipping them and keep scanning + else - -- scan forward continuously to handle '' escaped quotes - l_end := l_text_start + 1; + -- Regular string literal: l_remaining starts at the opening quote + -- scan from position 2 to skip the opening quote + l_end := 2; loop l_end := instr(l_remaining, '''', l_end); exit when l_end = 0; if substr(l_remaining, l_end, 2) = '''''' then - l_end := l_end + 2; -- skip escaped quote, keep scanning + l_end := l_end + 2; -- skip escaped quote pair else - exit; -- found real closing quote + exit; -- real closing quote end if; end loop; if l_end > 0 then - l_line := l_line || substr(l_remaining, 1, l_end); + l_line := l_line || substr(l_remaining, 1, l_end); l_remaining := substr(l_remaining, l_end + 1); else l_line := l_line || l_remaining; @@ -814,8 +801,10 @@ create or replace package body ut_utils is end if; end loop scan_line; + l_result(i) := l_line; end loop; + return l_result; end replace_multiline_comments; From 65145c2381762d2f0acf0ffe3aab602b86273c31 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 02:02:44 +0000 Subject: [PATCH 565/887] Trim spaces --- source/core/ut_utils.pkb | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index f62e10aa2..5501d6c9f 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -725,9 +725,9 @@ create or replace package body ut_utils is <> loop exit when l_remaining is null or l_remaining = ''; - l_ml_start := instr(l_remaining, '/*'); + l_ml_start := instr(l_remaining, '/*'); l_comment_start := instr(l_remaining, '--'); - l_text_start := instr(l_remaining, ''''); + l_text_start := instr(l_remaining, ''''); -- q' always puts ' at l_text_start; just check the char immediately before it l_eq_text_start := case when l_text_start > 1 and substr(l_remaining, l_text_start - 1, 1) = 'q' @@ -736,9 +736,9 @@ create or replace package body ut_utils is end; -- Sentinel gc_max_plsql_source_len means "not present"; 32767 is beyond any VARCHAR2 position l_pos := least( - case when l_ml_start > 0 then l_ml_start else gc_max_plsql_source_len end, + case when l_ml_start > 0 then l_ml_start else gc_max_plsql_source_len end, case when l_comment_start > 0 then l_comment_start else gc_max_plsql_source_len end, - case when l_text_start > 0 then l_text_start else gc_max_plsql_source_len end, + case when l_text_start > 0 then l_text_start else gc_max_plsql_source_len end, case when l_eq_text_start > 0 then l_eq_text_start else gc_max_plsql_source_len end ); @@ -747,7 +747,7 @@ create or replace package body ut_utils is exit scan_line; end if; - l_line := l_line || substr(l_remaining, 1, l_pos - 1); + l_line := l_line || substr(l_remaining, 1, l_pos - 1); l_remaining := substr(l_remaining, l_pos); -- l_remaining now starts exactly at the token; all branch offsets below are relative to 1 if l_pos = l_eq_text_start then @@ -755,7 +755,7 @@ create or replace package body ut_utils is l_eq_end_char := translate(substr(l_remaining, 3, 1), gc_open_chars, gc_close_chars); l_end := instr(l_remaining, l_eq_end_char || '''', 4); if l_end > 0 then - l_line := l_line || substr(l_remaining, 1, l_end + 1); + l_line := l_line || substr(l_remaining, 1, l_end + 1); l_remaining := substr(l_remaining, l_end + 2); else l_line := l_line || l_remaining; @@ -792,7 +792,7 @@ create or replace package body ut_utils is end loop; if l_end > 0 then - l_line := l_line || substr(l_remaining, 1, l_end); + l_line := l_line || substr(l_remaining, 1, l_end); l_remaining := substr(l_remaining, l_end + 1); else l_line := l_line || l_remaining; From 2c8811d6a429d10fc1b026ec73ca0e3da1f2d6da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 15 Mar 2026 12:55:59 +0200 Subject: [PATCH 566/887] Added tests to reproduce the issue. --- test/run_tests.sh | 2 ++ test/ut3_tester/core/test_suite_manager.pks | 2 +- test/ut3_tester_helper/run_helper.pkb | 11 +++++++++++ 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/test/run_tests.sh b/test/run_tests.sh index 9f69bd1a1..7d0431aec 100755 --- a/test/run_tests.sh +++ b/test/run_tests.sh @@ -4,6 +4,8 @@ set -ev #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" +export NLS_LANG=AMERICAN_AMERICA.AL32UTF8 + time utPLSQL-cli/bin/utplsql run UT3_TESTER_HELPER/ut3@//${CONNECTION_STR} -D \ -source_path=source -owner=ut3_develop \ -p='ut3_tester,ut3_user' \ diff --git a/test/ut3_tester/core/test_suite_manager.pks b/test/ut3_tester/core/test_suite_manager.pks index ac7818f4f..44f102716 100644 --- a/test/ut3_tester/core/test_suite_manager.pks +++ b/test/ut3_tester/core/test_suite_manager.pks @@ -163,7 +163,7 @@ create or replace package test_suite_manager is --%context(get_schema_ut_packages) - --%test(returns list of all unit test packages in given schema) + --%test(returns list of all unit test packages in given schema excluding packages that are not suites) --%beforetest(create_ut3_suite) --%aftertest(drop_ut3_suite) procedure test_get_schema_ut_packages; diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index 6289b1642..9d65d6667 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -855,12 +855,23 @@ create or replace package body run_helper is --%test procedure some_test; + end;]'; + execute immediate q'[ + create or replace package ut3_develop.package_that_is_not_a_test + as + --%parameter(a comment inside) + --%parameters( description ) + + --%test + procedure some_test; + end;]'; end; procedure drop_ut3_suite is pragma autonomous_transaction; begin + execute immediate q'[drop package ut3_develop.package_that_is_not_a_test]'; execute immediate q'[drop package ut3_develop.some_test_package]'; end; From f3c0d3f288404b952b8960e93b574342228de09e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 15 Mar 2026 13:12:37 +0200 Subject: [PATCH 567/887] Fixed the problem where `suite_cache_package` and `suite_cache_schema` are getting populated even package is not a suite. --- source/core/ut_suite_cache_manager.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 6d621c339..e5fdae7ac 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -306,7 +306,7 @@ create or replace package body ut_suite_cache_manager is l_object_owner varchar2(250) := upper(a_object_owner); l_object_name varchar2(250) := upper(a_object_name); begin - if a_suite_items is not null and a_suite_items.count = 0 then + if a_suite_items is null or a_suite_items.count = 0 then delete from ut_suite_cache t where t.object_owner = l_object_owner From 810517930f5e7310ebc45a48cf23e0558da66e97 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 14:17:46 +0000 Subject: [PATCH 568/887] Added extra tests. Added example --- test/ut3_tester/core/annotations/test_annotation_parser.pks | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pks b/test/ut3_tester/core/annotations/test_annotation_parser.pks index a4fe3ed70..898bdc363 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pks +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pks @@ -20,7 +20,7 @@ create or replace package test_annotation_parser is --%test(Ignores content of multi-line comments) procedure ignore_annotations_in_comments; - --%test(Ignores wrapped package and does not raise exception) + -- %test(ignore wrapped package source) procedure ignore_wrapped_package; --%test(Parses package level annotations with annotation params containing brackets) @@ -32,7 +32,7 @@ create or replace package test_annotation_parser is -- %test(Parses source-code with Windows-style newline) procedure test_windows_newline; - -- %test(Parses annotations with very long object names) + -- %test(parse annotations with very long procedure name) procedure test_annot_very_long_name; -- %test(Parses upper case annotations) From cc491cfb2e259d6c5160f986fa7f4812664c1db0 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 14:17:58 +0000 Subject: [PATCH 569/887] Enhance annotation parser with new tests and source line handling functions --- .../annotation_parser_test.sql | 298 +++++++++++++ .../create_test_packages.sql | 185 ++++++++ source/core/ut_utils.pkb | 6 +- .../annotations/test_annotation_parser.pkb | 404 +++++++++++++++++- .../annotations/test_annotation_parser.pks | 46 +- 5 files changed, 930 insertions(+), 9 deletions(-) create mode 100644 examples/annoation_parser_testing/annotation_parser_test.sql create mode 100644 examples/annoation_parser_testing/create_test_packages.sql diff --git a/examples/annoation_parser_testing/annotation_parser_test.sql b/examples/annoation_parser_testing/annotation_parser_test.sql new file mode 100644 index 000000000..d1ff43fcd --- /dev/null +++ b/examples/annoation_parser_testing/annotation_parser_test.sql @@ -0,0 +1,298 @@ +-- Annotation Manager Volume Benchmark +-- 1000 generated packages, cold cache per iteration + +set serveroutput on size unlimited +set timing off +set feedback off + +declare + c_packages constant pls_integer := 1000; + c_procs_per_pkg constant pls_integer := 20; + c_contexts_per_pkg constant pls_integer := 4; + c_pkg_prefix constant varchar2(20) := 'TST_GEN_PKG_'; + c_iterations constant pls_integer := 4; + c_perf_threshold constant number := 0.80; + + l_baseline_total_ms number := 0; + l_new_total_ms number := 0; + l_start timestamp; + l_elapsed interval day to second; + + -- Source holders + l_source_lines dbms_preprocessor.source_lines_t; + l_source_clob clob; + l_result ut_annotations; + + -- Correctness tracking + l_missing_from_cache pls_integer := 0; + l_count_mismatches pls_integer := 0; + l_mismatch_detail varchar2(32767); + + -- Cache check + l_cursor sys_refcursor; + l_annotated_obj ut_annotated_object; + l_name varchar2(128); + l_annotations ut_annotations; + l_cache_count pls_integer := 0; + + -- Per-package timing + l_pkg_baseline_ms number; + l_pkg_new_ms number; + l_pkg varchar2(30); + l_ratio number; + + -- Expected annotation count — mirrors generator logic exactly + function expected_annotation_count( + a_pkg_number pls_integer, + a_procs pls_integer, + a_contexts pls_integer + ) return pls_integer is + l_count pls_integer := 0; + begin + l_count := l_count + 2; -- %suite + %suitepath + l_count := l_count + 2; -- %beforeall + %afterall + l_count := l_count + 2; -- %beforeeach + %aftereach + + -- package level conditional + if mod(a_pkg_number, 3) = 0 then l_count := l_count + 1; end if; -- %displayname + if mod(a_pkg_number, 5) = 0 then l_count := l_count + 1; end if; -- %rollback + + -- contexts: each contributes %context + %endcontext + l_count := l_count + (a_contexts * 2); + + -- per procedure + for i in 1 .. a_procs loop + l_count := l_count + 1; -- %test + if mod(i, 3) = 0 then l_count := l_count + 1; end if; -- %tags + if mod(i, 6) = 0 then l_count := l_count + 1; end if; -- %throws + if mod(i, 8) = 0 then l_count := l_count + 1; end if; -- %disabled + if mod(i, 5) = 0 then l_count := l_count + 2; end if; -- %beforetest + %aftertest + end loop; + + return l_count; + end expected_annotation_count; + +begin + dbms_output.put_line('Packages : ' || c_packages); + dbms_output.put_line('Procs/pkg : ' || c_procs_per_pkg); + dbms_output.put_line('Contexts/pkg: ' || c_contexts_per_pkg); + dbms_output.put_line('Iterations : ' || c_iterations); + dbms_output.put_line('Started : ' || to_char(systimestamp,'YYYY-MM-DD HH24:MI:SS.FF3')); + + -- Phase 1: Performance benchmark (cold cache per package per iteration) + dbms_output.put_line(chr(10) || '-- Phase 1: Performance --'); + dbms_output.put_line( + rpad('package', 20) || ' | ' || + lpad('baseline_ms', 11) || ' | ' || + lpad('new_ms', 6) || ' | ' || + lpad('ratio', 5) || ' | ' || + 'status' + ); + dbms_output.put_line(rpad('-', 70, '-')); + + for p in 1 .. c_packages loop + l_pkg := c_pkg_prefix || lpad(p, 4, '0'); + + -- load source once per package + l_source_lines := dbms_preprocessor.get_post_processed_source( + object_type => 'PACKAGE', + schema_name => user, + object_name => l_pkg + ); + + dbms_lob.createtemporary(l_source_clob, true); + for i in 1 .. l_source_lines.count loop + dbms_lob.writeappend(l_source_clob, length(l_source_lines(i)), l_source_lines(i)); + end loop; + + -- baseline: clob version + l_pkg_baseline_ms := 0; + for iter in 1 .. c_iterations loop + ut_annotation_manager.purge_cache(user, 'PACKAGE'); + l_start := systimestamp; + l_result := ut_annotation_parser.parse_object_annotations(l_source_clob); + l_elapsed := systimestamp - l_start; + l_pkg_baseline_ms := l_pkg_baseline_ms + + extract(second from l_elapsed) * 1000; + end loop; + l_pkg_baseline_ms := l_pkg_baseline_ms / c_iterations; + + -- new: source_lines_t version + l_pkg_new_ms := 0; + for iter in 1 .. c_iterations loop + ut_annotation_manager.purge_cache(user, 'PACKAGE'); + l_start := systimestamp; + l_result := ut_annotation_parser.parse_object_annotations(l_source_lines); + l_elapsed := systimestamp - l_start; + l_pkg_new_ms := l_pkg_new_ms + + extract(second from l_elapsed) * 1000; + end loop; + l_pkg_new_ms := l_pkg_new_ms / c_iterations; + + -- accumulate + l_baseline_total_ms := l_baseline_total_ms + l_pkg_baseline_ms; + l_new_total_ms := l_new_total_ms + l_pkg_new_ms; + + l_ratio := round(l_pkg_new_ms / nullif(l_pkg_baseline_ms, 0), 3); + + -- print every 100 packages to avoid flooding output + if mod(p, 100) = 0 or p = 1 then + dbms_output.put_line( + rpad(l_pkg, 20) || ' | ' || + lpad(round(l_pkg_baseline_ms, 3), 11) || ' | ' || + lpad(round(l_pkg_new_ms, 3), 6) || ' | ' || + lpad(l_ratio, 5) || ' | ' || + case when l_ratio <= c_perf_threshold + then 'PASS (' || round((1-l_ratio)*100,1) || '% faster)' + else 'SLOW (ratio=' || l_ratio || ')' + end + ); + end if; + + dbms_lob.freetemporary(l_source_clob); + end loop; + + -- ------------------------------------------------------------------------- + -- Phase 1 summary + -- ------------------------------------------------------------------------- + l_ratio := round(l_new_total_ms / nullif(l_baseline_total_ms, 0), 3); + + dbms_output.put_line(rpad('-', 70, '-')); + dbms_output.put_line('Baseline total ms : ' || round(l_baseline_total_ms, 3)); + dbms_output.put_line('New total ms : ' || round(l_new_total_ms, 3)); + dbms_output.put_line('Overall ratio : ' || l_ratio); + dbms_output.put_line('Improvement : ' || round((1 - l_ratio) * 100, 1) || '%'); + + -- Phase 2: Cache presence check + dbms_output.put_line(chr(10) || '-- Phase 2: Cache presence --'); + + ut_annotation_manager.purge_cache(user, 'PACKAGE'); + ut_annotation_manager.rebuild_annotation_cache(user, 'PACKAGE'); + + -- query cache tables directly to avoid validate_annotation_cache side effects + open l_cursor for + select ut_annotated_object( + i.object_owner, i.object_name, i.object_type, i.parse_time, + cast( + collect( + ut_annotation( + c.annotation_position, c.annotation_name, + c.annotation_text, c.subobject_name + ) order by c.annotation_position + ) as ut_annotations + ) + ) + from ut_annotation_cache_info i + join ut_annotation_cache c on i.cache_id = c.cache_id + where i.object_owner = user + and i.object_type = 'PACKAGE' + and i.object_name like c_pkg_prefix || '%' + group by i.object_owner, i.object_type, i.object_name, i.parse_time; + + loop + fetch l_cursor into l_annotated_obj; + exit when l_cursor%notfound; + l_cache_count := l_cache_count + 1; + end loop; + close l_cursor; + + dbms_output.put_line('Expected in cache : ' || c_packages); + dbms_output.put_line('Found in cache : ' || l_cache_count); + dbms_output.put_line('Cache check : ' || + case when l_cache_count = c_packages + then 'PASS — all ' || c_packages || ' packages found in cache' + else 'FAIL — missing ' || (c_packages - l_cache_count) || ' packages from cache' + end + ); + + -- Phase 3: Annotation count correctness + dbms_output.put_line(chr(10) || '-- Phase 3: Annotation count correctness --'); + + -- reopen same direct cache query for correctness check + open l_cursor for + select ut_annotated_object( + i.object_owner, i.object_name, i.object_type, i.parse_time, + cast( + collect( + ut_annotation( + c.annotation_position, c.annotation_name, + c.annotation_text, c.subobject_name + ) order by c.annotation_position + ) as ut_annotations + ) + ) + from ut_annotation_cache_info i + join ut_annotation_cache c on i.cache_id = c.cache_id + where i.object_owner = user + and i.object_type = 'PACKAGE' + and i.object_name like c_pkg_prefix || '%' + group by i.object_owner, i.object_type, i.object_name, i.parse_time; + + loop + fetch l_cursor into l_annotated_obj; + exit when l_cursor%notfound; + l_name := l_annotated_obj.object_name; + l_annotations := l_annotated_obj.annotations; + + declare + l_pkg_number pls_integer; + l_expected pls_integer; + begin + l_pkg_number := to_number(substr(l_name, length(c_pkg_prefix) + 1)); + l_expected := expected_annotation_count( + l_pkg_number, + c_procs_per_pkg, + c_contexts_per_pkg + ); + + if l_annotations.count != l_expected then + l_count_mismatches := l_count_mismatches + 1; + if l_count_mismatches <= 10 then + l_mismatch_detail := l_mismatch_detail || chr(10) || + ' ' || l_name || + ': expected=' || l_expected || + ' actual=' || l_annotations.count; + end if; + end if; + end; + end loop; + close l_cursor; + + dbms_output.put_line('Packages checked : ' || c_packages); + dbms_output.put_line('Count mismatches : ' || l_count_mismatches); + if l_count_mismatches > 0 then + dbms_output.put_line('Mismatch detail (first 10):' || l_mismatch_detail); + end if; + dbms_output.put_line('Count check : ' || + case when l_count_mismatches = 0 + then 'PASS — all annotation counts match expected' + else 'FAIL — ' || l_count_mismatches || ' packages have wrong annotation count' + end + ); + + dbms_output.put_line(chr(10) || '================================================='); + dbms_output.put_line('FINAL RESULTS'); + dbms_output.put_line('================================================='); + dbms_output.put_line('Performance : ' || + case when l_ratio <= c_perf_threshold then 'PASS' else 'FAIL' end); + dbms_output.put_line('Cache : ' || + case when l_cache_count = c_packages then 'PASS' else 'FAIL' end); + dbms_output.put_line('Counts : ' || + case when l_count_mismatches = 0 then 'PASS' else 'FAIL' end); + dbms_output.put_line('Overall : ' || + case when l_ratio <= c_perf_threshold + and l_cache_count = c_packages + and l_count_mismatches = 0 + then 'PASS' + else 'FAIL' + end + ); + dbms_output.put_line('Finished : ' || + to_char(systimestamp, 'YYYY-MM-DD HH24:MI:SS.FF3')); + dbms_output.put_line('================================================='); + + -- cleanup + ut_annotation_manager.purge_cache(user, 'PACKAGE'); + +end; +/ diff --git a/examples/annoation_parser_testing/create_test_packages.sql b/examples/annoation_parser_testing/create_test_packages.sql new file mode 100644 index 000000000..94a7f3de2 --- /dev/null +++ b/examples/annoation_parser_testing/create_test_packages.sql @@ -0,0 +1,185 @@ +declare + c_packages constant pls_integer := 1000; + c_procs_per_pkg constant pls_integer := 20; + + l_spec varchar2(32767); + l_body varchar2(32767); + l_pkg varchar2(30); + l_errors pls_integer := 0; + + procedure append_to_source(a_source in out nocopy varchar2, a_text varchar2) is + begin + a_source := a_source || a_text; + end; + + procedure append_line(a_source in out nocopy varchar2, a_text varchar2 default null) is + begin + a_source := a_source || a_text || chr(10); + end; + +begin + + for r in ( + select object_name + from user_objects + where object_name like 'TST_GEN_PKG_%' + and object_type = 'PACKAGE' + order by object_name + ) loop + begin + execute immediate 'drop package ' || r.object_name; + exception + when others then + dbms_output.put_line('ERROR dropping ' || r.object_name || ': ' || sqlerrm); + end; + end loop; + dbms_output.put_line('Existing packages dropped.'); + + for p in 1 .. c_packages loop + l_pkg := 'TST_GEN_PKG_' || lpad(p, 4, '0'); + l_spec := null; + l_body := null; + + -- Package spec + append_line(l_spec, 'create or replace package ' || l_pkg || ' as'); + append_line(l_spec); + append_line(l_spec, ' --%suite(Generated suite ' || p || ')'); + append_line(l_spec, ' --%suitepath(generated.vol_test)'); + + if mod(p, 3) = 0 then + append_line(l_spec, ' --%displayname(Suite display name for pkg ' || p || ')'); + end if; + if mod(p, 5) = 0 then + append_line(l_spec, ' --%rollback(manual)'); + end if; + + append_line(l_spec); + append_line(l_spec, ' --%beforeall'); + append_line(l_spec, ' procedure setup_suite;'); + append_line(l_spec); + append_line(l_spec, ' --%afterall'); + append_line(l_spec, ' procedure teardown_suite;'); + append_line(l_spec); + append_line(l_spec, ' --%beforeeach'); + append_line(l_spec, ' procedure setup_test;'); + append_line(l_spec); + append_line(l_spec, ' --%aftereach'); + append_line(l_spec, ' procedure teardown_test;'); + append_line(l_spec); + + for i in 1 .. c_procs_per_pkg loop + declare + l_proc varchar2(30) := 'test_proc_' || lpad(i, 3, '0'); + begin + if mod(i - 1, 5) = 0 then + append_line(l_spec, ' --%context(context_' || ceil(i/5) || ')'); + append_line(l_spec); + end if; + + if mod(i, 4) = 0 then + append_line(l_spec, ' /* multi-line comment for ' || l_proc || ' */'); + end if; + + append_line(l_spec, ' --%test(Test ' || i || ' in pkg ' || p || ')'); + + if mod(i, 3) = 0 then + append_line(l_spec, ' --%tags(tag_' || mod(i,5) || ',smoke)'); + end if; + if mod(i, 6) = 0 then + append_line(l_spec, ' --%throws(-20001)'); + end if; + if mod(i, 8) = 0 then + append_line(l_spec, ' --%disabled(generated disabled test ' || i || ')'); + end if; + if mod(i, 5) = 0 then + append_line(l_spec, ' --%beforetest(setup_test)'); + append_line(l_spec, ' --%aftertest(teardown_test)'); + end if; + + append_line(l_spec, ' -- regular comment'); + append_line(l_spec, ' procedure ' || l_proc || ';'); + append_line(l_spec); + + if mod(i, 5) = 0 then + append_line(l_spec, ' --%endcontext'); + append_line(l_spec); + end if; + end; + end loop; + + append_line(l_spec, 'end ' || l_pkg || ';'); + + -- ----------------------------------------------------------------------- + -- Package body + -- ----------------------------------------------------------------------- + append_line(l_body, 'create or replace package body ' || l_pkg || ' as'); + append_line(l_body); + + for stub in ( + select column_value as proc_name + from table(ut_varchar2_list( + 'setup_suite','teardown_suite', + 'setup_test','teardown_test' + )) + ) loop + append_line(l_body, ' procedure ' || stub.proc_name || ' is'); + append_line(l_body, ' begin'); + append_line(l_body, ' null;'); + append_line(l_body, ' end ' || stub.proc_name || ';'); + append_line(l_body); + end loop; + + for i in 1 .. c_procs_per_pkg loop + declare + l_proc varchar2(30) := 'test_proc_' || lpad(i, 3, '0'); + begin + append_line(l_body, ' procedure ' || l_proc || ' is'); + append_line(l_body, ' begin'); + if mod(i, 4) = 0 then + append_line(l_body, ' ut.expect(''/* not a comment */'').to_equal(''/* not a comment */'');'); + elsif mod(i, 4) = 1 then + append_line(l_body, ' ut.expect(' || i || ').to_be_greater_than(0);'); + elsif mod(i, 4) = 2 then + append_line(l_body, ' ut.expect(q''[-- not a comment]'').to_equal(q''[-- not a comment]'');'); + else + append_line(l_body, ' ut.expect(''test_' || i || ''').not_to_be_null();'); + end if; + append_line(l_body, ' end ' || l_proc || ';'); + append_line(l_body); + end; + end loop; + + append_line(l_body, 'end ' || l_pkg || ';'); + + -- Execute DDL — with error capture so one bad package doesn't stop all + begin + execute immediate l_spec; + execute immediate l_body; + exception + when others then + l_errors := l_errors + 1; + dbms_output.put_line('ERROR on ' || l_pkg || ': ' || sqlerrm); + end; + + if mod(p, 100) = 0 then + dbms_output.put_line('Created ' || p || ' packages...'); + end if; + + end loop; + + dbms_output.put_line('----------------------------------------'); + dbms_output.put_line('Done. packages=' || c_packages || + ' errors=' || l_errors); + + -- quick sanity check + declare + l_count pls_integer; + begin + select count(*) into l_count + from user_objects + where object_name like 'TST_GEN_PKG_%' + and object_type = 'PACKAGE'; + dbms_output.put_line('Packages in user_objects: ' || l_count); + end; +end; +/ diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 5501d6c9f..92c47c301 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -769,6 +769,10 @@ create or replace package body ut_utils is l_remaining := substr(l_remaining, l_ml_end + 2); else l_in_ml_comment := true; + -- preserve trailing newline if present — it belongs to this line, not the comment + if substr(l_remaining, -1) = chr(10) then + l_line := l_line || chr(10); + end if; exit scan_line; end if; @@ -1175,4 +1179,4 @@ create or replace package body ut_utils is end; end ut_utils; -/ \ No newline at end of file +/ diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pkb b/test/ut3_tester/core/annotations/test_annotation_parser.pkb index bc789c377..34aa51383 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pkb @@ -1,5 +1,23 @@ create or replace package body test_annotation_parser is + function lines_to_str(a_lines dbms_preprocessor.source_lines_t) return varchar2 is + l_result varchar2(32767); + begin + for i in 1 .. a_lines.count loop + l_result := l_result || a_lines(i); + end loop; + return l_result; + end; + + function make_source(a_lines ut_varchar2_list) return dbms_preprocessor.source_lines_t is + l_result dbms_preprocessor.source_lines_t; + begin + for i in 1 .. a_lines.count loop + l_result(i) := a_lines(i); + end loop; + return l_result; + end; + procedure test_proc_comments is l_source clob; l_actual ut3_develop.ut_annotations; @@ -457,5 +475,389 @@ END;'; end; + ------------------------------------------------------------ + -- source_lines_t overload equivalents of existing tests + ------------------------------------------------------------ + + procedure test_proc_comments_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' -- %ann1(Name of suite)' || chr(10), + ' -- wrong line' || chr(10), + ' -- %ann2(some_value)' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(2,'suite',null, null), + ut3_develop.ut_annotation(3,'displayname','Name of suite',null), + ut3_develop.ut_annotation(4,'suitepath','all.globaltests',null), + ut3_develop.ut_annotation(6,'ann1','Name of suite',null), + ut3_develop.ut_annotation(8,'ann2','some_value','foo') + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + end; + + procedure include_floating_annotations_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' -- %ann1(Name of suite)' || chr(10), + ' -- %ann2(all.globaltests)' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' procedure foo;' || chr(10), + '' || chr(10), + ' -- %ann3(Name of suite)' || chr(10), + ' -- %ann4(all.globaltests)' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' procedure bar;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), + ut3_develop.ut_annotation( 6, 'ann1', 'Name of suite', null ), + ut3_develop.ut_annotation( 7, 'ann2', 'all.globaltests', null ), + ut3_develop.ut_annotation( 9, 'test', null, 'foo'), + ut3_develop.ut_annotation( 12, 'ann3', 'Name of suite', null ), + ut3_develop.ut_annotation( 13, 'ann4', 'all.globaltests', null ), + ut3_develop.ut_annotation( 15, 'test', null, 'bar') + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + + end; + + procedure ignore_annotations_in_comments_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' /*' || chr(10), + ' Some comment' || chr(10), + ' -- inlined' || chr(10), + ' -- %ignored' || chr(10), + ' */' || chr(10), + ' -- %suite' || chr(10), + ' --%displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 7, 'suite', null, null ), + ut3_develop.ut_annotation( 8, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 9, 'suitepath', 'all.globaltests', null ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + + end; + + procedure no_procedure_annotation_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + + end; + + ------------------------------------------------------------ + -- replace_multiline_comments coverage tests + ------------------------------------------------------------ + + procedure test_rmc_empty_source is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result.count).to_equal(0); + end; + + procedure test_rmc_no_ml_comment_marker is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + 'procedure foo is' || chr(10), + 'begin' || chr(10), + ' null;' || chr(10), + 'end;' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(lines_to_str(l_result)).to_equal(lines_to_str(l_input)); + end; + + procedure test_rmc_line_inside_ml_comment is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + 'x := 1; /* start' || chr(10), + 'this whole line is comment' || chr(10), + 'end comment */ x := 2;' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(1)).to_equal('x := 1; ' || chr(10)); + ut.expect(l_result(2)).to_equal(''); + ut.expect(l_result(3)).to_equal(' x := 2;' || chr(10)); + end; + + procedure test_rmc_ml_comment_closed_midline is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + '/* open' || chr(10), + 'still inside' || chr(10), + '*/ code /* remove this too */ kept' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(2)).to_equal(''); + ut.expect(l_result(3)).to_equal(' code kept' || chr(10)); + end; + + procedure test_rmc_fast_path_no_tokens is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + -- line 2 has none of / - ' so hits fast path B; line 1 needed to pass pre-scan + l_input := make_source(ut_varchar2_list( + '/* comment */' || chr(10), + 'begin' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(2)).to_equal('begin' || chr(10)); + end; + + procedure test_rmc_ml_comment_single_line is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + 'x := /* inline comment */ 42;' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(1)).to_equal('x := 42;' || chr(10)); + end; + + procedure test_rmc_single_line_comment_preserved is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + '/* marker */' || chr(10), + ' -- %test annotation' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(2)).to_equal(' -- %test annotation' || chr(10)); + end; + + procedure test_rmc_string_literal_protects_markers is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + 'v := ''val /* not a comment */ here'';' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(1)).to_equal('v := ''val /* not a comment */ here'';' || chr(10)); + end; + + procedure test_rmc_string_literal_escaped_quotes is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + 'v := ''it''''s a /* test */'';' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(1)).to_equal('v := ''it''''s a /* test */'';' || chr(10)); + end; + + procedure test_rmc_q_quoted_string_literal is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + 'v := q''[/* not a comment */]'';' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(1)).to_equal('v := q''[/* not a comment */]'';' || chr(10)); + end; + + procedure test_rmc_unclosed_string_literal is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + 'v := ''hello /* inside unclosed' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(1)).to_equal('v := ''hello /* inside unclosed' || chr(10)); + end; + + procedure test_rmc_unclosed_q_string is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + c_line constant varchar2(100) := q'(v := q'[/* unclosed q-string)' || chr(10); + begin + --Arrange + l_input := make_source(ut_varchar2_list(c_line)); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(1)).to_equal(c_line); + end; + + procedure test_rmc_multiple_ml_comments_one_line is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + 'a /* one */ := /* two */ 1;' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(1)).to_equal('a := 1;' || chr(10)); + end; + + procedure test_rmc_comment_after_string_with_slash is + l_input dbms_preprocessor.source_lines_t; + l_result dbms_preprocessor.source_lines_t; + begin + --Arrange + l_input := make_source(ut_varchar2_list( + 'v := ''a/b''; -- this is /* not */ a ml comment' || chr(10) + )); + + --Act + l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); + + --Assert + ut.expect(l_result(1)).to_equal('v := ''a/b''; -- this is /* not */ a ml comment' || chr(10)); + end; + end test_annotation_parser; -/ +/ \ No newline at end of file diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pks b/test/ut3_tester/core/annotations/test_annotation_parser.pks index 898bdc363..439974769 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pks +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pks @@ -19,24 +19,56 @@ create or replace package test_annotation_parser is procedure complex_text; --%test(Ignores content of multi-line comments) procedure ignore_annotations_in_comments; - -- %test(ignore wrapped package source) procedure ignore_wrapped_package; - --%test(Parses package level annotations with annotation params containing brackets) procedure brackets_in_desc; - --%test(Parses annotation text even with spaces before brackets) procedure test_space_before_annot_params; - -- %test(Parses source-code with Windows-style newline) procedure test_windows_newline; - -- %test(parse annotations with very long procedure name) procedure test_annot_very_long_name; - -- %test(Parses upper case annotations) procedure test_upper_annot; + --%test(Treats procedure level annotations as package level using source lines overload) + procedure test_proc_comments_lines; + --%test(Includes floating annotations between procedures using source lines overload) + procedure include_floating_annotations_lines; + --%test(Ignores content of multi-line comments using source lines overload) + procedure ignore_annotations_in_comments_lines; + --%test(Parses package annotations without any procedure annotations using source lines overload) + procedure no_procedure_annotation_lines; + + -- %test(empty source returns immediately without processing) + procedure test_rmc_empty_source; + -- %test(source with no multiline comment markers returned unchanged) + procedure test_rmc_no_ml_comment_marker; + -- %test(line entirely inside multiline comment is blanked) + procedure test_rmc_line_inside_ml_comment; + -- %test(closing delimiter mid-line falls through to scan remainder) + procedure test_rmc_ml_comment_closed_midline; + -- %test(fast path line with no slash dash or quote copied unchanged) + procedure test_rmc_fast_path_no_tokens; + -- %test(single-line block comment removed on same line) + procedure test_rmc_ml_comment_single_line; + -- %test(single-line comment preserved intact) + procedure test_rmc_single_line_comment_preserved; + -- %test(string literal containing comment markers not stripped) + procedure test_rmc_string_literal_protects_markers; + -- %test(string literal with escaped quotes handled correctly) + procedure test_rmc_string_literal_escaped_quotes; + -- %test(q-quoted string literal protects interior comment markers) + procedure test_rmc_q_quoted_string_literal; + -- %test(unclosed string literal copies remainder and exits scan) + procedure test_rmc_unclosed_string_literal; + -- %test(unclosed q-quoted string copies remainder and exits scan) + procedure test_rmc_unclosed_q_string; + -- %test(multiple block comments on single line all removed) + procedure test_rmc_multiple_ml_comments_one_line; + -- %test(comment markers after string with slash handled correctly) + procedure test_rmc_comment_after_string_with_slash; + end test_annotation_parser; -/ +/ \ No newline at end of file From 6717ad3d645498481c117c97097f406acd5032ca Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 14:46:40 +0000 Subject: [PATCH 570/887] Add tests for Windows-style newlines and long procedure names in annotation parser --- .../annotations/test_annotation_parser.pkb | 60 +++++++++++++++++++ .../annotations/test_annotation_parser.pks | 5 ++ 2 files changed, 65 insertions(+) diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pkb b/test/ut3_tester/core/annotations/test_annotation_parser.pkb index 34aa51383..2ec0b2551 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pkb @@ -859,5 +859,65 @@ END;'; ut.expect(l_result(1)).to_equal('v := ''a/b''; -- this is /* not */ a ml comment' || chr(10)); end; +procedure test_windows_newline_lines + as + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(13) || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + end; + + procedure test_annot_very_long_name_lines + as + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + l_source := make_source(ut_varchar2_list( + 'PACKAGE very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' procedure very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), + ut3_develop.ut_annotation( 6, 'test', null, 'very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it' ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + end; + end test_annotation_parser; / \ No newline at end of file diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pks b/test/ut3_tester/core/annotations/test_annotation_parser.pks index 439974769..7b995b438 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pks +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pks @@ -69,6 +69,11 @@ create or replace package test_annotation_parser is procedure test_rmc_multiple_ml_comments_one_line; -- %test(comment markers after string with slash handled correctly) procedure test_rmc_comment_after_string_with_slash; + --%test(Parses source-code with Windows-style newline using source lines overload) + procedure test_windows_newline_lines; + --%test(parse annotations with very long procedure name using source lines overload) + procedure test_annot_very_long_name_lines; + end test_annotation_parser; / \ No newline at end of file From 6c513bea386d9880250938818fc2fd3c8beae3d4 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 15:41:05 +0000 Subject: [PATCH 571/887] Fix regex extraction for procedure/function names and ensure ordered results in annotation processing --- source/core/annotations/ut_annotation_parser.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 8df89be28..cca422ec0 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -160,7 +160,7 @@ create or replace package body ut_annotation_parser as and regexp_like(l_line, '^\s*(procedure|function)\s+', 'i') then -- extract just the identifier name (subexpression 2) - l_proc_name := trim(regexp_substr(l_line + l_proc_name := trim(regexp_substr(srcstr =>l_line ,pattern => '^\s*(procedure|function)\s+('||gc_regexp_identifier||')' ,modifier => 'i' ,subexpression => 2)); @@ -310,7 +310,7 @@ create or replace package body ut_annotation_parser as l_comment_index := l_comments.next(l_comment_index); end loop; - select /*+ no_parallel */ value(x) bulk collect into l_result from table(l_annotations) x order by x.position; + select /*+ no_parallel */ value(x) bulk collect into l_result from table(l_annotations) x order by x.position asc; return l_result; From b389671cc77cf46004bffd6ad450f129e7a08f46 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 15 Mar 2026 20:53:43 +0200 Subject: [PATCH 572/887] Implementing github discussions --- .github/DISCUSSION_TEMPLATE/README.md | 150 ++++++++++++++++++ .github/DISCUSSION_TEMPLATE/announcements.yml | 54 +++++++ .github/DISCUSSION_TEMPLATE/architecture.yml | 100 ++++++++++++ .github/DISCUSSION_TEMPLATE/contributors.yml | 56 +++++++ .github/DISCUSSION_TEMPLATE/general.yml | 28 ++++ .github/DISCUSSION_TEMPLATE/q-a.yml | 87 ++++++++++ .../DISCUSSION_TEMPLATE/release-planning.yml | 90 +++++++++++ .github/DISCUSSION_TEMPLATE/rfcs-design.yml | 88 ++++++++++ .github/DISCUSSION_TEMPLATE/show-and-tell.yml | 79 +++++++++ .github/ISSUE_TEMPLATE/feature_request.md | 2 +- docs/about/authors.md | 2 +- docs/about/project-details.md | 2 +- mkdocs.yml | 6 +- mkdocs_offline.yml | 4 +- readme.md | 7 +- 15 files changed, 742 insertions(+), 13 deletions(-) create mode 100644 .github/DISCUSSION_TEMPLATE/README.md create mode 100644 .github/DISCUSSION_TEMPLATE/announcements.yml create mode 100644 .github/DISCUSSION_TEMPLATE/architecture.yml create mode 100644 .github/DISCUSSION_TEMPLATE/contributors.yml create mode 100644 .github/DISCUSSION_TEMPLATE/general.yml create mode 100644 .github/DISCUSSION_TEMPLATE/q-a.yml create mode 100644 .github/DISCUSSION_TEMPLATE/release-planning.yml create mode 100644 .github/DISCUSSION_TEMPLATE/rfcs-design.yml create mode 100644 .github/DISCUSSION_TEMPLATE/show-and-tell.yml diff --git a/.github/DISCUSSION_TEMPLATE/README.md b/.github/DISCUSSION_TEMPLATE/README.md new file mode 100644 index 000000000..f6c0905f4 --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/README.md @@ -0,0 +1,150 @@ +# GitHub Discussions — setup guide for utPLSQL/utPLSQL + +This folder contains the discussion category form templates that power structured +GitHub Discussions for the utPLSQL project. + +--- + +## File → category mapping + + + +| File | Category name to create in GitHub | Format | Who can post | +|------------------------|-----------------------------------|-----------------------|--------------------------------| +| `announcements.yml` | 📢 Announcements | Announcement | Maintainers only | +| `rfcs-design.yml` | 💡 RFCs & Design | Open-ended discussion | Everyone | +| `architecture.yml` | 🏗 Architecture | Open-ended discussion | Everyone | +| `release-planning.yml` | 🗓 Release Planning | Open-ended discussion | Maintainers only (recommended) | +| `q-a.yml` | ❓ Q&A | Question / Answer | Everyone | +| `show-and-tell.yml` | 🔬 Show & Tell | Open-ended discussion | Everyone | +| `contributors.yml` | 🤝 Contributors | Open-ended discussion | Everyone | +| `general.yml` | 💬 General | Open-ended discussion | Everyone | + +> **Polls** are a built-in GitHub Discussions type and do not support YAML templates. +> Create a 🗳 Polls category manually (type: Poll) — no template file needed. + +--- + +## Step-by-step setup + +### 1. Enable Discussions +Go to **Settings → Features** and check **Discussions**. + +### 2. Create the categories +Go to **Discussions → Categories → ✏️ Edit categories** (gear icon). + +Create each category listed in the table above. +**Order matters** — drag to set the display order shown below: + +1. 📢 Announcements +2. 💡 RFCs & Design +3. 🏗 Architecture +4. 🗓 Release Planning +5. ❓ Q&A +6. 🔬 Show & Tell +7. 🤝 Contributors +8. 🗳 Polls +9. 💬 General + +### 3. Commit the templates +Copy all `.yml` files from this folder into `.github/DISCUSSION_TEMPLATE/` in +the **default branch** (usually `develop` for utPLSQL). + +``` +.github/ +└── DISCUSSION_TEMPLATE/ + ├── announcements.yml + ├── rfcs-design.yml + ├── architecture.yml + ├── release-planning.yml + ├── q-a.yml + ├── show-and-tell.yml + ├── contributors.yml + └── general.yml +``` + +### 4. Configure category permissions + +| Category | Setting | +|------------------|--------------------------------------------------| +| Announcements | Set to **Maintainers only** in category settings | +| Release Planning | Recommended: **Maintainers only** | +| All others | Open to all | + +### 5. Create the welcome pinned post + +Create a first discussion in **Announcements** titled +**"Welcome to utPLSQL Discussions — how to use this space"** + +Suggested body: + +```markdown +## Welcome 👋 + +This is the place for design discussions, feature proposals, and community +conversation around utPLSQL. + +### Where to post + +| I want to… | Use | +|---|---| +| Propose a new feature or behaviour change | 💡 RFCs & Design | +| Discuss internal architecture | 🏗 Architecture | +| Ask a usage / how-to question | ❓ Q&A | +| Share a CI pipeline, integration, or tip | 🔬 Show & Tell | +| Ask about contributing / development setup | 🤝 Contributors | +| Vote on priorities | 🗳 Polls | +| Anything else | 💬 General | + +### Discussions vs Issues + +**Discussions** are for ideas that are still open, need input, or require consensus. +**Issues** are for well-scoped work that someone can pick up and implement. + +A maintainer will convert a Discussion to an Issue once scope is agreed. + +### Real-time chat + +For quick questions: [utPLSQL Slack](https://utplsql.slack.com) +For decisions that need a permanent record: post here. +``` + +Pin this post from the discussion's `…` menu → **Pin discussion**. + +### 6. Update the README + +Add a Discussions badge to the project README: + +```markdown +[![GitHub Discussions](https://img.shields.io/github/discussions/utPLSQL/utPLSQL)](https://github.com/utPLSQL/utPLSQL/discussions) +``` + +And add a short paragraph in the "Community" or "Contributing" section pointing +to Discussions as the place for design proposals. + +--- + +## Operating guidelines + +### Discussion → Issue conversion rule + +| Category | Convert when… | +|---------------|----------------------------------------------------------------------| +| RFCs & Design | Consensus reached, scope is defined | +| Architecture | Breaking change formally agreed by maintainers | +| Q&A | A confirmed bug surfaces in the thread | +| Contributors | A gap in docs or tooling is identified that can be filed as an issue | + +Use the **"Create issue from discussion"** button (available in the discussion's sidebar). + +### Housekeeping + +- Lock **Announcements** threads after 30 days. +- Close **Polls** after 14 days; post a summary comment with the result before closing. +- Label cross-references: apply the same labels used on issues + (`enhancement`, `breaking-change`, `coverage`, `oracle-version`, etc.) + to discussions for consistent search. diff --git a/.github/DISCUSSION_TEMPLATE/announcements.yml b/.github/DISCUSSION_TEMPLATE/announcements.yml new file mode 100644 index 000000000..262746e11 --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/announcements.yml @@ -0,0 +1,54 @@ +title: "[Announcement] " +labels: ["announcement"] +body: + - type: markdown + attributes: + value: | + > **Maintainers only.** This category is restricted to project maintainers. + > Announcements are pinned and locked after 30 days. + + - type: dropdown + id: announcement_type + attributes: + label: Announcement type + options: + - New release + - Release candidate / pre-release + - Roadmap update + - Deprecation notice + - Security advisory + - Community / governance update + - Other + validations: + required: true + + - type: input + id: version + attributes: + label: Version (if applicable) + placeholder: "e.g. 3.2.0" + validations: + required: false + + - type: textarea + id: body + attributes: + label: Announcement body + description: | + Write the full announcement here. + For releases, include: highlights, breaking changes, upgrade notes, and a link to the full changelog. + validations: + required: true + + - type: textarea + id: links + attributes: + label: Key links + description: Release tag, changelog, migration guide, Docker image, CLI download, etc. + placeholder: | + - Release: https://github.com/utPLSQL/utPLSQL/releases/tag/v… + - Changelog: … + - Docker: … + - CLI: … + validations: + required: false diff --git a/.github/DISCUSSION_TEMPLATE/architecture.yml b/.github/DISCUSSION_TEMPLATE/architecture.yml new file mode 100644 index 000000000..f3df8e29c --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/architecture.yml @@ -0,0 +1,100 @@ +title: "[Architecture] " +labels: ["architecture", "design"] +body: + - type: markdown + attributes: + value: | + ## Architecture discussion + Use this template for internal design decisions: changes to the suite-loading mechanism, + the coverage engine, DDL trigger behaviour, reporter infrastructure, or any + cross-cutting concern that affects the internals of utPLSQL. + + This category is primarily for **contributors and maintainers**. + If you want to propose a user-facing feature, use **RFCs & Design** instead. + + - type: input + id: title_short + attributes: + label: Component / area + description: Which internal component or subsystem does this discussion concern? + placeholder: "e.g. Suite loader, Coverage engine, Annotation parser, Event system" + validations: + required: true + + - type: textarea + id: context + attributes: + label: Context and current design + description: Briefly describe how the relevant part works today. + validations: + required: true + + - type: textarea + id: problem + attributes: + label: Problem or design question + description: What specific decision needs to be made, or what limitation needs to be addressed? + validations: + required: true + + - type: textarea + id: options + attributes: + label: Options under consideration + description: | + List the design options you are weighing. For each option describe: + - How it works + - Pros + - Cons + - Impact on Oracle compatibility + placeholder: | + **Option A — …** + How: … + Pros: … + Cons: … + + **Option B — …** + How: … + Pros: … + Cons: … + validations: + required: true + + - type: textarea + id: preferred + attributes: + label: Preferred direction (if any) + description: If you already lean toward one option, say so and why. Leave blank if genuinely open. + validations: + required: false + + - type: dropdown + id: breaking + attributes: + label: Does this introduce a breaking change? + options: + - "No" + - "Yes — public API change (ut_runner, ut packages, annotations)" + - "Yes — output/reporter format change" + - "Yes — internal package change (no public API impact)" + - "Unsure" + validations: + required: true + + - type: textarea + id: migration + attributes: + label: Migration / compatibility notes + description: If breaking, describe the migration path for users and downstream integrations. + validations: + required: false + + - type: checkboxes + id: checklist + attributes: + label: Checklist + options: + - label: I have reviewed the existing architecture docs and source + required: true + - label: Relevant unit / integration tests have been considered + required: false diff --git a/.github/DISCUSSION_TEMPLATE/contributors.yml b/.github/DISCUSSION_TEMPLATE/contributors.yml new file mode 100644 index 000000000..6325961de --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/contributors.yml @@ -0,0 +1,56 @@ +title: "[Contributors] " +labels: ["contributors"] +body: + - type: markdown + attributes: + value: | + ## Contributors + Questions about **contributing to utPLSQL** — development environment setup, + the test suite, pull request process, coding conventions, or anything else + that helps you get your first (or next) contribution merged. + + **Useful links before posting:** + - [CONTRIBUTING.md](../../blob/develop/CONTRIBUTING.md) + - [Development environment setup](../../blob/develop/docs/development/developer-guide.md) + - [Open issues labelled `good first issue`](../../issues?q=is%3Aopen+label%3A%22good+first+issue%22) + + - type: dropdown + id: topic + attributes: + label: Topic + options: + - Dev environment / Docker setup + - Running the test suite locally + - Understanding the codebase + - PR review process + - Coding conventions / style + - Good first issue — looking for guidance + - Release process + - Documentation contribution + - Other + validations: + required: true + + - type: textarea + id: question + attributes: + label: Question or request + description: What do you need help with? + validations: + required: true + + - type: textarea + id: context + attributes: + label: What you have tried + description: Steps already taken, error messages, links to relevant code, etc. + validations: + required: false + + - type: input + id: os + attributes: + label: Host OS / environment + placeholder: "e.g. macOS 14, Windows 11, Ubuntu 22.04, Docker on Linux" + validations: + required: false diff --git a/.github/DISCUSSION_TEMPLATE/general.yml b/.github/DISCUSSION_TEMPLATE/general.yml new file mode 100644 index 000000000..0e3b8d100 --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/general.yml @@ -0,0 +1,28 @@ +title: "" +labels: ["general"] +body: + - type: markdown + attributes: + value: | + ## General discussion + For open-ended conversations that don't fit another category: + project direction, community topics, suggestions, or anything else. + + If your post turns out to be a feature proposal, a maintainer may move it to + **RFCs & Design**. If it is a question about using utPLSQL, consider posting + in **Q&A** instead so a helpful answer can be marked. + + - type: textarea + id: body + attributes: + label: What's on your mind? + validations: + required: true + + - type: textarea + id: context + attributes: + label: Additional context + description: Background, links, related issues or discussions. + validations: + required: false diff --git a/.github/DISCUSSION_TEMPLATE/q-a.yml b/.github/DISCUSSION_TEMPLATE/q-a.yml new file mode 100644 index 000000000..e4ff1d452 --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/q-a.yml @@ -0,0 +1,87 @@ +title: "[Q&A] " +labels: ["question"] +body: + - type: markdown + attributes: + value: | + ## Question & Answer + Ask anything about **using** utPLSQL — installation, writing tests, CI integration, + reporters, annotations, code coverage, etc. + + **Tips for a fast answer:** + - Include your utPLSQL version and Oracle version. + - Paste a minimal reproducer (test package + expected vs actual output). + - Check the [documentation](https://utplsql.github.io/utPLSQL/) and + [closed Q&A discussions](../../discussions/categories/q-a?discussions_q=is%3Aclosed) first. + + > If this turns out to be a **bug**, a maintainer will convert this discussion into an Issue. + + - type: input + id: utplsql_version + attributes: + label: utPLSQL version + placeholder: "e.g. 3.1.13" + validations: + required: true + + - type: dropdown + id: oracle_version + attributes: + label: Oracle version + options: + - Oracle 11g + - Oracle 12c + - Oracle 18c + - Oracle 19c + - Oracle 21c + - Oracle 23c / 23ai + - Other / unsure + validations: + required: true + + - type: textarea + id: question + attributes: + label: Question + description: Describe what you are trying to do and what you have tried so far. + validations: + required: true + + - type: textarea + id: reproducer + attributes: + label: Minimal reproducer + description: | + Paste a minimal test package and/or the relevant ut_runner call. + Include the full error message or unexpected output if applicable. + render: sql + validations: + required: false + + - type: textarea + id: expected + attributes: + label: Expected behaviour + validations: + required: false + + - type: textarea + id: actual + attributes: + label: Actual behaviour / error + validations: + required: false + + - type: dropdown + id: install_method + attributes: + label: Installation method + options: + - utPLSQL-cli + - SQL*Plus script + - Docker / utPLSQL-docker + - Liquibase / Flyway + - Other + - N/A + validations: + required: false diff --git a/.github/DISCUSSION_TEMPLATE/release-planning.yml b/.github/DISCUSSION_TEMPLATE/release-planning.yml new file mode 100644 index 000000000..5663d7613 --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/release-planning.yml @@ -0,0 +1,90 @@ +title: "[Release] v" +labels: ["release-planning"] +body: + - type: markdown + attributes: + value: | + ## Release planning discussion + Use this template to discuss the scope of an upcoming release: + what goes in, what gets deferred, and what the acceptance criteria are. + + **Maintainers:** pin this discussion and link it from the corresponding GitHub Milestone. + + - type: input + id: version + attributes: + label: Target version + placeholder: "e.g. 3.2.0" + validations: + required: true + + - type: dropdown + id: release_type + attributes: + label: Release type + options: + - Major (breaking changes) + - Minor (new features, backward-compatible) + - Patch (bug fixes only) + validations: + required: true + + - type: textarea + id: goals + attributes: + label: Release goals + description: What are the 2–4 key things this release should achieve? + placeholder: | + 1. + 2. + 3. + validations: + required: true + + - type: textarea + id: scope_in + attributes: + label: In scope (proposed issues / PRs) + description: | + Link the GitHub Issues and PRs targeted for this release. + Use the format: `- [ ] #123 — short description` + placeholder: | + - [ ] #123 — ... + - [ ] #456 — ... + validations: + required: false + + - type: textarea + id: scope_out + attributes: + label: Out of scope / explicitly deferred + description: Issues that were considered but will not be included — and why. + validations: + required: false + + - type: input + id: target_date + attributes: + label: Target release date (approximate) + placeholder: "e.g. 2025-Q2" + validations: + required: false + + - type: textarea + id: oracle_matrix + attributes: + label: Oracle version test matrix + description: Which Oracle versions must pass CI before this release ships? + placeholder: | + - [ ] Oracle 19c + - [ ] Oracle 21c + - [ ] Oracle 23ai + validations: + required: false + + - type: textarea + id: notes + attributes: + label: Additional notes + validations: + required: false diff --git a/.github/DISCUSSION_TEMPLATE/rfcs-design.yml b/.github/DISCUSSION_TEMPLATE/rfcs-design.yml new file mode 100644 index 000000000..32c0a33c7 --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/rfcs-design.yml @@ -0,0 +1,88 @@ +title: "[RFC] " +labels: ["rfc", "design"] +body: + - type: markdown + attributes: + value: | + ## Request for Comments — design proposal + Use this template to propose a new feature, a change to existing behaviour, or a significant refactoring. + Once there is consensus and a clear scope, a maintainer will convert this discussion into one or more GitHub Issues. + + **Before posting:** search existing RFCs and open issues to avoid duplicates. + + - type: input + id: summary + attributes: + label: Summary + description: One sentence — what are you proposing? + placeholder: "Add support for ..." + validations: + required: true + + - type: textarea + id: problem + attributes: + label: Problem / motivation + description: What problem does this solve? Who is affected and how often? + placeholder: | + Currently, when ... it is not possible to ... + This forces users to ... + validations: + required: true + + - type: textarea + id: proposal + attributes: + label: Proposed solution + description: Describe the solution in as much detail as you have. Pseudo-code, SQL, or PL/SQL snippets are welcome. + placeholder: | + ```sql + -- example of the proposed API + ``` + validations: + required: true + + - type: textarea + id: alternatives + attributes: + label: Alternatives considered + description: What other approaches did you look at? Why did you rule them out? + validations: + required: false + + - type: textarea + id: breaking + attributes: + label: Breaking-change impact + description: | + Does this change affect existing annotations, package APIs, or test output formats? + List affected public symbols (ut_runner, ut, annotations, reporters …). + validations: + required: false + + - type: dropdown + id: oracle_versions + attributes: + label: Oracle version relevance + description: Which Oracle versions does this apply to? + multiple: true + options: + - All supported versions + - Oracle 11g + - Oracle 12c + - Oracle 18c + - Oracle 19c + - Oracle 21c + - Oracle 23c / 23ai + validations: + required: true + + - type: checkboxes + id: checklist + attributes: + label: Checklist + options: + - label: I have searched existing discussions and issues for duplicates + required: true + - label: I am willing to help implement or review this feature + required: false diff --git a/.github/DISCUSSION_TEMPLATE/show-and-tell.yml b/.github/DISCUSSION_TEMPLATE/show-and-tell.yml new file mode 100644 index 000000000..4443c5de6 --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/show-and-tell.yml @@ -0,0 +1,79 @@ +title: "[Show & Tell] " +labels: ["show-and-tell"] +body: + - type: markdown + attributes: + value: | + ## Show & Tell + Share how you are using utPLSQL in the wild — CI pipelines, IDE integrations, + custom reporters, coverage setups, framework wrappers, or anything else the + community might learn from. + + Posts here are a great source of real-world examples for the documentation. + + - type: input + id: title_short + attributes: + label: What are you sharing? + placeholder: "e.g. utPLSQL + GitHub Actions CI pipeline for Oracle 23ai" + validations: + required: true + + - type: dropdown + id: category + attributes: + label: Category + multiple: true + options: + - CI/CD integration + - IDE / SQL client integration + - Custom reporter + - Code coverage setup + - Framework wrapper / helper library + - Docker / containerised testing + - Annotation patterns + - Performance / large test suite + - Other + validations: + required: true + + - type: textarea + id: description + attributes: + label: Description + description: Describe what you built or configured and why it might be useful to others. + validations: + required: true + + - type: textarea + id: snippet + attributes: + label: Code or configuration snippet + description: Paste the most relevant excerpt. Link to a repo or Gist if you have one. + render: yaml + validations: + required: false + + - type: input + id: utplsql_version + attributes: + label: utPLSQL version used + placeholder: "e.g. 3.1.13" + validations: + required: false + + - type: input + id: oracle_version + attributes: + label: Oracle version + placeholder: "e.g. Oracle 19c" + validations: + required: false + + - type: textarea + id: links + attributes: + label: Links + description: Repository, blog post, documentation page, etc. + validations: + required: false diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index 681bc7f3a..f0335781e 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -23,4 +23,4 @@ Add any other context or screenshots about the feature request here. > Please do not create issues for generic SQL or PL/SQL questions. There are other forums and communities to help you with those. See [ASKTom](https://asktom.oracle.com) for example. **Want to discuss** -If you want to discuss your issue, join [our SLACK chat](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww). +If you want to discuss a problem, please go to [utPLSQL discussions](https://github.com/utPLSQL/utPLSQL/discussions) diff --git a/docs/about/authors.md b/docs/about/authors.md index 3c0117b09..f752302de 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -20,7 +20,7 @@ Many thanks to all the [contributors](https://github.com/utPLSQL/utPLSQL/graphs/ ### Special thanks to prior major contributors -- Steven Feuerstein - Original Author +- Steven Feuerstein - Original Author of utPLSQL v1 and v2 - Chris Rimmer - Patrick Barel - Paul Walker diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 26c89912d..976f8bc99 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -4,7 +4,7 @@ [![chat](http://img.shields.io/badge/GitHub_Project-Active-blue.svg)](https://github.com/utPLSQL/utPLSQL) [![license](http://img.shields.io/badge/license-apache%202.0-blue.svg)](https://www.apache.org/licenses/LICENSE-2.0) -[![chat](http://img.shields.io/badge/chat-slack-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) +[![GitHub Discussions](https://img.shields.io/github/discussions/utPLSQL/utPLSQL)](https://github.com/utPLSQL/utPLSQL/discussions) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) diff --git a/mkdocs.yml b/mkdocs.yml index 713722620..49356fd4e 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -8,7 +8,7 @@ edit_uri: "" site_url: http://utPLSQL.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL -copyright: Copyright © 2016 - 2022 utPLSQL Team +copyright: Copyright © 2016 - 2026 utPLSQL Team repo_url: https://github.com/utPLSQL/utPLSQL extra_css: - stylesheets/extra.css @@ -44,8 +44,8 @@ extra: social: - icon: fontawesome/brands/twitter link: https://twitter.com/utPLSQL - - icon: fontawesome/brands/slack - link: https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww + - icon: fontawesome/regular/comment + link: https://github.com/utPLSQL/utPLSQL/discussions - icon: fontawesome/brands/github link: https://github.com/utPLSQL - icon: fontawesome/solid/envelope diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index 31c90615e..9f0ef57af 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -44,8 +44,8 @@ extra: social: - icon: fontawesome/brands/twitter link: https://twitter.com/utPLSQL - - icon: fontawesome/brands/slack - link: https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww + - icon: fontawesome/regular/comment + link: https://github.com/utPLSQL/utPLSQL/discussions - icon: fontawesome/brands/github link: https://github.com/utPLSQL - icon: fontawesome/solid/envelope diff --git a/readme.md b/readme.md index 3c2d7fb3a..a8523b4d7 100644 --- a/readme.md +++ b/readme.md @@ -5,7 +5,7 @@ [![license](https://img.shields.io/github/license/utPLSQL/utPLSQL.svg)](https://www.apache.org/licenses/LICENSE-2.0) [![latest-release](https://img.shields.io/github/release/utPLSQL/utPLSQL.svg)](https://github.com/utPLSQL/utPLSQL/releases) [![Download statistics](https://img.shields.io/github/downloads/utPLSQL/utPLSQL/total.svg)](http://gra.caldis.me/?url=https://github.com/utPLSQL/utPLSQL) -[![chat](http://img.shields.io/badge/slack-team--chat-blue.svg)](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) +[![GitHub Discussions](https://img.shields.io/github/discussions/utPLSQL/utPLSQL)](https://github.com/utPLSQL/utPLSQL/discussions) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) [![build](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml/badge.svg)](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml) @@ -161,8 +161,7 @@ Finished in .036027 seconds We welcome new developers to join our community and contribute to the utPLSQL project. If you are interested in helping please read our [guide to contributing](CONTRIBUTING.md) The best place to start is to read the documentation and get familiar with the existing code base. -A [slack chat](https://utplsql.slack.com/) is the place to go if you want to talk with team members. -To sign up to the chat use [this link](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww). +[Github discussions](https://github.com/utPLSQL/utPLSQL/discussions) is the place to go if you want to talk with team members. ---------- @@ -183,8 +182,6 @@ __Project Directories__ ---------- -If you have a great feature in mind, that you would like to see in utPLSQL v3 please create an [issue on GitHub](https://github.com/utPLSQL/utPLSQL/issues) or discuss it with us in the [slack chat rooms](https://utplsql.slack.com/). Use [invite link](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) to join the chat. - # Version 2 to Version 3 Comparison From 46f3d127a32e66026de41326199f178e5f9a270a Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Sun, 15 Mar 2026 21:20:02 +0000 Subject: [PATCH 573/887] Update tests --- .../core/annotations/ut_annotation_parser.pkb | 13 +- source/core/ut_utils.pkb | 4 +- .../annotations/test_annotation_parser.pkb | 145 ++++++++++++++++++ .../annotations/test_annotation_parser.pks | 11 +- 4 files changed, 164 insertions(+), 9 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index cca422ec0..8bb9b1b5e 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -72,16 +72,17 @@ create or replace package body ut_annotation_parser as a_subobject_name varchar2 := null ) is l_loop_index binary_integer := 1; - l_annotation_index binary_integer; + l_annotation_index binary_integer := 1; begin -- loop while there are unprocessed comment blocks - loop + while l_annotation_index is not null loop -- define index of the comment block and get it's content from cache l_annotation_index := regexp_substr( a_source ,gc_comment_replacer_regex_ptrn ,1 ,l_loop_index ,subexpression => 1); - exit when l_annotation_index is null; - add_annotation( a_annotations, l_annotation_index, a_comments( l_annotation_index ), a_subobject_name ); - l_loop_index := l_loop_index + 1; + if l_annotation_index is not null then + add_annotation( a_annotations, l_annotation_index, a_comments( l_annotation_index ), a_subobject_name ); + l_loop_index := l_loop_index + 1; + end if; end loop; end add_annotations; @@ -343,7 +344,7 @@ create or replace package body ut_annotation_parser as dbms_lob.freetemporary(l_source); - select /*+ no_parallel */ value(x) bulk collect into l_result from table(l_annotations) x order by x.position; + select /*+ no_parallel */ value(x) bulk collect into l_result from table(l_annotations) x order by x.position asc; return l_result; end parse_object_annotations; diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 92c47c301..e43dc5644 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -23,8 +23,8 @@ create or replace package body ut_utils is gc_invalid_xml_char constant varchar2(50) := '[^_[:alnum:]\.-]'; gc_full_valid_xml_name constant varchar2(50) := '^([[:alpha:]])([_[:alnum:]\.-])*$'; gc_owner_hash constant integer(11) := dbms_utility.get_hash_value( ut_owner(), 0, power(2,31)-1); - gc_open_chars constant varchar2(4):= chr(91) || chr(123) || chr(40) || chr(60); -- [{( - gc_close_chars constant varchar2(4):= chr(93) || chr(125) || chr(41) || chr(62); -- ]})> + gc_open_chars constant varchar2(4):= chr(91) || chr(123) || chr(40) || chr(60); -- [{( this has very specific purpose to not confuse lexer in IDE + gc_close_chars constant varchar2(4):= chr(93) || chr(125) || chr(41) || chr(62); -- ]})> this has very specific purpose to not confuse lexer in IDE gc_max_plsql_source_len constant integer := 32767; function surround_with(a_value varchar2, a_quote_char varchar2) return varchar2 is diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pkb b/test/ut3_tester/core/annotations/test_annotation_parser.pkb index 2ec0b2551..5613896cc 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pkb @@ -919,5 +919,150 @@ procedure test_windows_newline_lines ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); end; + procedure test_multiline_proc_header_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + -- procedure header spans multiple lines before terminating ; + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' procedure foo(' || chr(10), + ' a_param1 varchar2' || chr(10), + ' ,a_param2 number default null' || chr(10), + ' );' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 4, 'test', null, 'foo' ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + end; + + procedure test_non_comment_line_resets_block_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + -- a non-comment non-proc line between annotation and procedure breaks the association + -- %test becomes a floating top-level annotation with no subobject + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' pragma serially_reusable;' || chr(10), -- resets accumulator + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + -- %test is NOT associated with foo — accumulator was reset by pragma line + -- it surfaces as a top-level annotation with no subobject_name + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 4, 'test', null, null ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + end; + + procedure test_annotation_not_at_line_start_ignored_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + -- % appears in line but comment is not at start of line — should be ignored + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' x := ''value%with%percent'';' || chr(10), -- % present but -- not at line start + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + end; + + procedure test_space_between_dashes_and_qualifier_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + -- spaces between -- and % are skipped and annotation is still recognised + -- annotations are not adjacent to a procedure so they are top-level + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), -- multiple spaces between -- and % + ' -- %displayname(my suite)' || chr(10), + '' || chr(10), -- blank line breaks association with foo + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'my suite', null ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + end; + + procedure test_percent_not_after_dashes_ignored_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + -- -- present and % present on line but % is not immediately after -- + -- e.g. a regular comment that happens to mention 100% + l_source := make_source(ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- coverage is 100% on this module' || chr(10), -- % after text, not annotation + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + end; + end test_annotation_parser; / \ No newline at end of file diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pks b/test/ut3_tester/core/annotations/test_annotation_parser.pks index 7b995b438..92860769c 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pks +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pks @@ -73,7 +73,16 @@ create or replace package test_annotation_parser is procedure test_windows_newline_lines; --%test(parse annotations with very long procedure name using source lines overload) procedure test_annot_very_long_name_lines; - + --%test(Procedure header spanning multiple lines is handled correctly) + procedure test_multiline_proc_header_lines; + --%test(Non-comment line between annotation and procedure resets association) + procedure test_non_comment_line_resets_block_lines; + --%test(Comment with non-whitespace before dashes is not treated as annotation) + procedure test_annotation_not_at_line_start_ignored_lines; + --%test(Spaces between dashes and annotation qualifier are skipped correctly) + procedure test_space_between_dashes_and_qualifier_lines; + --%test(Percent sign not immediately after dashes is not treated as annotation) + procedure test_percent_not_after_dashes_ignored_lines; end test_annotation_parser; / \ No newline at end of file From 707fadd55cc93b475efaf30ebc00382d4468b20c Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Mon, 16 Mar 2026 10:49:55 +0100 Subject: [PATCH 574/887] Added empty lines at the end --- source/reporters/ut_tap_reporter.tpb | 2 +- source/reporters/ut_tap_reporter.tps | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 5a75fcac8..ff095a369 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -121,4 +121,4 @@ create or replace type body ut_tap_reporter is self.lvl := 0; end; end; -/ \ No newline at end of file +/ diff --git a/source/reporters/ut_tap_reporter.tps b/source/reporters/ut_tap_reporter.tps index e38d809f9..bed809059 100644 --- a/source/reporters/ut_tap_reporter.tps +++ b/source/reporters/ut_tap_reporter.tps @@ -15,4 +15,4 @@ create or replace type ut_tap_reporter under ut_documentation_reporter( ) not final -/ \ No newline at end of file +/ From e539ed0981c204580f596985b16ad097a3894451 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 16 Mar 2026 11:00:19 +0000 Subject: [PATCH 575/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index fda0cb436..22543040d 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4298 +4339 diff --git a/docs/about/authors.md b/docs/about/authors.md index f752302de..4f1e4c0b7 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 1e030f3f5..717cc388a 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 976f8bc99..b69bf3235 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 058b84479..9383d5c01 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 53f4c94aa..b5b393656 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 5de9fb7fb..fdfe3c26b 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 0c7c469ee..4b5be5595 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index bd09e2d83..1688ea95e 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0ea6a1208..10a75ebed 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e4143411e..078973d65 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index bf9f29504..2bbcbcf12 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c710607bc..5488dc66f 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 423eccea4..3416f60bc 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index bef1e2156..4c9bef2ef 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index f86bce299..6d2e166e9 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 750497394..6f216032d 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 9effdcdbc..a4449fa26 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4298--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index a0d1e612c..2e220f148 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4298-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4339-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 93e3b1ad4754a894f04be1a43346973df142a586 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 16 Mar 2026 13:03:42 +0200 Subject: [PATCH 576/887] Removing the uncessary setup of Python --- .github/workflows/build.yml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 796017d5c..be6e18ca2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -247,12 +247,6 @@ jobs: git config --global user.email "github-actions[bot]@users.noreply.github.com" git config --global user.name "github-actions[bot]" - - name: Setup Python for docs - uses: actions/setup-python@v5 - with: - python-version: '3.11' - cache: 'pip' - - name: Build and publish documentation run: | pip install mkdocs From 0dda69a2de27e183d935245385dc434425467937 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 16 Mar 2026 11:27:46 +0000 Subject: [PATCH 577/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 22543040d..f60afa776 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4339 +4340 diff --git a/docs/about/authors.md b/docs/about/authors.md index 4f1e4c0b7..a996db919 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 717cc388a..cc562f01d 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index b69bf3235..2631bae92 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 9383d5c01..670377f05 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b5b393656..616eeeb8f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index fdfe3c26b..e2e9cf4c3 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 4b5be5595..9e240b337 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 1688ea95e..054875070 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 10a75ebed..c6c6a94c8 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 078973d65..b5b119fba 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 2bbcbcf12..b723bb29b 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 5488dc66f..253d6aec2 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 3416f60bc..ac2064011 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 4c9bef2ef..66dca6bf3 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 6d2e166e9..79e9d8fa7 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 6f216032d..3fc402e56 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index a4449fa26..1a5c9ed05 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4339--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 2e220f148..22d43aece 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4339-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4340-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From e1d039dffadb69bdf3f4d87670e8a43e789f9508 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 16 Mar 2026 14:24:32 +0200 Subject: [PATCH 578/887] Update of documentation to remove references to SLACK. --- docs/about/support.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/about/support.md b/docs/about/support.md index 670377f05..e628c86a7 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -2,5 +2,6 @@ # How to get support -- Feel free to post questions, bugs or issues in the [issues area of GitHub](https://github.com/utPLSQL/utPLSQL/issues) -- [Join](https://join.slack.com/t/utplsql/shared_invite/zt-xwm68udy-4cF_3PNEyczYEbWr38W5ww) developers team on [utPLSQL Slack](https://utplsql.slack.com/) +- Look into [utPLSQL github discussions](https://github.com/utPLSQL/utPLSQL/discussions) to find support, ask questions and share ideas +- If needed open a new [issue on github](https://github.com/utPLSQL/utPLSQL/issues) for bugs or feature requests + From adeedf1091ea24010640103714d267a422f0c2ff Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 16 Mar 2026 12:30:47 +0000 Subject: [PATCH 579/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index f60afa776..cbc92e381 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4340 +4341 diff --git a/docs/about/authors.md b/docs/about/authors.md index a996db919..45d729d3d 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index cc562f01d..37c7ed3b8 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 2631bae92..9765acd75 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index e628c86a7..feb3051b4 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 616eeeb8f..ebe93b0fe 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index e2e9cf4c3..caefa6622 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 9e240b337..b56c3622e 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 054875070..3ea8a286b 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index c6c6a94c8..18583b6b0 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index b5b119fba..cecb2bdfd 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b723bb29b..3e5cd70c2 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 253d6aec2..15ec2b881 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ac2064011..9da2da1c8 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 66dca6bf3..829f8bcac 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 79e9d8fa7..f46556c22 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 3fc402e56..bb39a331c 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 1a5c9ed05..68bcab1f4 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4340--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 22d43aece..32555e6aa 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4340-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4341-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 92336cb3ca454b43fba3512e2b6c92d58b7212b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 16 Mar 2026 18:19:48 +0200 Subject: [PATCH 580/887] Update badge --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index a8523b4d7..1ca252558 100644 --- a/readme.md +++ b/readme.md @@ -9,7 +9,7 @@ [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) [![build](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml/badge.svg)](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml) -[![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL_utPLSQL&metric=sqale_rating)](https://sonarcloud.io/summary/new_code?id=utPLSQL) +[![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL_utPLSQL&metric=sqale_rating)](https://sonarcloud.io/summary/new_code?id=utPLSQL_utPLSQL) [![Coverage](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL_utPLSQL&metric=coverage)](https://sonarcloud.io/summary/new_code?id=utPLSQL_utPLSQL) ---------- From c36fbb31401bb7678f7a0477b31c30035c278b50 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 16 Mar 2026 16:26:31 +0000 Subject: [PATCH 581/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index cbc92e381..2bfcb2370 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4341 +4342 diff --git a/docs/about/authors.md b/docs/about/authors.md index 45d729d3d..2c2abf826 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 37c7ed3b8..0485779e5 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 9765acd75..81e4f976e 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index feb3051b4..4ac661e10 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index ebe93b0fe..459bc9535 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index caefa6622..c0cbffb0e 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index b56c3622e..3dc42e429 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 3ea8a286b..45be3be59 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 18583b6b0..adf36baa6 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index cecb2bdfd..e042d61ed 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3e5cd70c2..0ea5e2e73 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 15ec2b881..cd4feb46a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 9da2da1c8..6724ac6ab 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 829f8bcac..0cdc2d7fa 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index f46556c22..fe9143fe7 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index bb39a331c..28e02d5b8 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 68bcab1f4..818a592bc 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4341--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 32555e6aa..9615c7b4d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4341-develop'; + gc_version constant varchar2(50) := 'v3.1.14.4342-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 81e1752350f06f46f21aa24be867e36b7e6a1466 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 16 Mar 2026 22:12:00 +0000 Subject: [PATCH 582/887] Refactor annotation parser tests and utility functions - Removed unused test procedures from test_annotation_parser package. - Updated replace_multiline_comments procedure in test_ut_utils to use dbms_preprocessor.source_lines_t for actual and expected results. - Added lines_to_str and make_source functions in main_helper to facilitate conversion between source lines and string formats. --- .../annotations/test_annotation_parser.pkb | 678 +++++++----------- .../annotations/test_annotation_parser.pks | 13 - test/ut3_tester/core/test_ut_utils.pkb | 29 +- test/ut3_tester_helper/main_helper.pkb | 18 + test/ut3_tester_helper/main_helper.pks | 4 + 5 files changed, 296 insertions(+), 446 deletions(-) diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pkb b/test/ut3_tester/core/annotations/test_annotation_parser.pkb index 5613896cc..beb526863 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pkb @@ -1,45 +1,28 @@ create or replace package body test_annotation_parser is - function lines_to_str(a_lines dbms_preprocessor.source_lines_t) return varchar2 is - l_result varchar2(32767); - begin - for i in 1 .. a_lines.count loop - l_result := l_result || a_lines(i); - end loop; - return l_result; - end; - - function make_source(a_lines ut_varchar2_list) return dbms_preprocessor.source_lines_t is - l_result dbms_preprocessor.source_lines_t; - begin - for i in 1 .. a_lines.count loop - l_result(i) := a_lines(i); - end loop; - return l_result; - end; - procedure test_proc_comments is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; - begin - l_source := 'PACKAGE test_tt AS - -- %suite - -- %displayname(Name of suite) - -- %suitepath(all.globaltests) - - -- %ann1(Name of suite) - -- wrong line - -- %ann2(some_value) - procedure foo; - END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' -- %ann1(Name of suite)' || chr(10), + ' -- wrong line' || chr(10), + ' -- %ann2(some_value)' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert - l_expected := ut3_develop.ut_annotations( ut3_develop.ut_annotation(2,'suite',null, null), ut3_develop.ut_annotation(3,'displayname','Name of suite',null), @@ -52,30 +35,33 @@ create or replace package body test_annotation_parser is end; procedure include_floating_annotations is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt AS - -- %suite - -- %displayname(Name of suite) - -- %suitepath(all.globaltests) - - -- %ann1(Name of suite) - -- %ann2(all.globaltests) - - --%test - procedure foo; - - -- %ann3(Name of suite) - -- %ann4(all.globaltests) - - --%test - procedure bar; - END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' -- %ann1(Name of suite)' || chr(10), + ' -- %ann2(all.globaltests)' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' procedure foo;' || chr(10), + '' || chr(10), + ' -- %ann3(Name of suite)' || chr(10), + ' -- %ann4(all.globaltests)' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' procedure bar;' || chr(10), + ' END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -95,40 +81,41 @@ create or replace package body test_annotation_parser is end; procedure parse_complex_with_functions is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt AS - -- %suite - -- %displayname(Name of suite) - -- %suitepath(all.globaltests) - - --%test - procedure foo; - - - --%beforeeach - procedure foo2; - - --test comment - -- wrong comment - - - /* - describtion of the procedure - */ - --%beforeeach(key=testval) - PROCEDURE foo3(a_value number default null); - - --%all - function foo4(a_val number default null - , a_par varchar2 default := ''asdf''); - END;'; + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' procedure foo;' || chr(10), + '' || chr(10), + '' || chr(10), + ' --%beforeeach' || chr(10), + ' procedure foo2;' || chr(10), + '' || chr(10), + ' --test comment' || chr(10), + ' -- wrong comment' || chr(10), + '' || chr(10), + '' || chr(10), + '/*' || chr(10), + ' describtion of the procedure' || chr(10), + ' */' || chr(10), + ' --%beforeeach(key=testval)' || chr(10), + ' PROCEDURE foo3(a_value number default null);' || chr(10), + '' || chr(10), + ' --%all' || chr(10), + ' function foo4(a_val number default null' || chr(10), + ' , a_par varchar2 default := ''asdf'');' || chr(10), + 'END;')); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -146,21 +133,24 @@ create or replace package body test_annotation_parser is end; procedure no_procedure_annotation is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt AS - -- %suite - -- %displayname(Name of suite) - -- %suitepath(all.globaltests) - - procedure foo; - END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -174,21 +164,24 @@ create or replace package body test_annotation_parser is end; procedure parse_accessible_by is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt accessible by (foo) AS - -- %suite - -- %displayname(Name of suite) - -- %suitepath(all.globaltests) - - procedure foo; - END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt accessible by (foo) AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -202,24 +195,27 @@ create or replace package body test_annotation_parser is end; procedure complex_package_declaration is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt - ACCESSIBLE BY (calling_proc) - authid current_user - AS - -- %suite - -- %displayname(Name of suite) - -- %suitepath(all.globaltests) - - procedure foo; - END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt' || chr(10), + ' ACCESSIBLE BY (calling_proc)' || chr(10), + ' authid current_user' || chr(10), + ' AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -233,21 +229,24 @@ create or replace package body test_annotation_parser is end; procedure complex_text is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt AS - -- %suite - --%displayname(name = Name of suite) - -- %suitepath(key=all.globaltests,key2=foo,"--%some text") - - procedure foo; - END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' --%displayname(name = Name of suite)' || chr(10), + ' -- %suitepath(key=all.globaltests,key2=foo,"--%some text")' || chr(10), + '' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -261,26 +260,29 @@ create or replace package body test_annotation_parser is end; procedure ignore_annotations_in_comments is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt AS - /* - Some comment - -- inlined - -- %ignored - */ - -- %suite - --%displayname(Name of suite) - -- %suitepath(all.globaltests) - - procedure foo; - END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' /*' || chr(10), + ' Some comment' || chr(10), + ' -- inlined' || chr(10), + ' -- %ignored' || chr(10), + ' */' || chr(10), + ' -- %suite' || chr(10), + ' --%displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -329,17 +331,19 @@ v58yvbLAXLi9gYHwoIvAgccti+Cmpg0DKLY= end; procedure brackets_in_desc is - - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt AS - -- %suite(Name of suite (including some brackets) and some more text) -END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite(Name of suite (including some brackets) and some more text)' || chr(10), + 'END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -350,24 +354,27 @@ END;'; end; procedure test_space_before_annot_params is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; - l_expected ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt AS - /* - Some comment - -- inlined - */ - -- %suite - -- %suitepath (all.globaltests) - - procedure foo; -END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' /*' || chr(10), + ' Some comment' || chr(10), + ' -- inlined' || chr(10), + ' */' || chr(10), + ' -- %suite' || chr(10), + ' -- %suitepath (all.globaltests)'|| chr(10), + '' || chr(10), + ' procedure foo;' || chr(10), + 'END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -380,18 +387,21 @@ END;'; procedure test_windows_newline as - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin - l_source := 'PACKAGE test_tt AS - -- %suite - -- %displayname(Name of suite)' || chr(13) || chr(10) - || ' -- %suitepath(all.globaltests) - END;'; + --Arrange + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(13) || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + ' END;' || chr(10) + )); --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); --Assert l_expected := ut3_develop.ut_annotations( @@ -405,97 +415,20 @@ END;'; procedure test_annot_very_long_name as - l_source clob; - l_actual ut3_develop.ut_annotations; - l_expected ut3_develop.ut_annotations; - begin - l_source := 'PACKAGE very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it AS - -- %suite - -- %displayname(Name of suite) - -- %suitepath(all.globaltests) - - --%test - procedure very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it; - END;'; - - --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); - - --Assert - l_expected := ut3_develop.ut_annotations( - ut3_develop.ut_annotation( 2, 'suite', null, null ), - ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), - ut3_develop.ut_annotation( 6, 'test', null, 'very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it' ) - ); - - ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); - end; - - procedure test_upper_annot is - l_source clob; + l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; - begin - l_source := 'PACKAGE test_tt AS - -- %SUITE - -- %DISPLAYNAME(Name of suite) - -- %SUITEPATH(all.globaltests) - - -- %ANN1(Name of suite) - -- %ANN2(all.globaltests) - - --%TEST - procedure foo; - - -- %ANN3(Name of suite) - -- %ANN4(all.globaltests) - - --%TEST - procedure bar; - END;'; - - --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source); - - --Assert - l_expected := ut3_develop.ut_annotations( - ut3_develop.ut_annotation( 2, 'suite', null, null ), - ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), - ut3_develop.ut_annotation( 6, 'ann1', 'Name of suite', null ), - ut3_develop.ut_annotation( 7, 'ann2', 'all.globaltests', null ), - ut3_develop.ut_annotation( 9, 'test', null, 'foo'), - ut3_develop.ut_annotation( 12, 'ann3', 'Name of suite', null ), - ut3_develop.ut_annotation( 13, 'ann4', 'all.globaltests', null ), - ut3_develop.ut_annotation( 15, 'test', null, 'bar') - ); - - ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); - - end; - - ------------------------------------------------------------ - -- source_lines_t overload equivalents of existing tests - ------------------------------------------------------------ - - procedure test_proc_comments_lines is - l_source dbms_preprocessor.source_lines_t; - l_actual ut3_develop.ut_annotations; - l_expected ut3_develop.ut_annotations; begin --Arrange - l_source := make_source(ut_varchar2_list( - 'PACKAGE test_tt AS' || chr(10), - ' -- %suite' || chr(10), - ' -- %displayname(Name of suite)' || chr(10), - ' -- %suitepath(all.globaltests)' || chr(10), - '' || chr(10), - ' -- %ann1(Name of suite)' || chr(10), - ' -- wrong line' || chr(10), - ' -- %ann2(some_value)' || chr(10), - ' procedure foo;' || chr(10), - ' END;' || chr(10) + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it AS' || chr(10), + ' -- %suite' || chr(10), + ' -- %displayname(Name of suite)' || chr(10), + ' -- %suitepath(all.globaltests)' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' procedure very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it;' || chr(10), + ' END;' || chr(10) )); --Act @@ -503,38 +436,37 @@ END;'; --Assert l_expected := ut3_develop.ut_annotations( - ut3_develop.ut_annotation(2,'suite',null, null), - ut3_develop.ut_annotation(3,'displayname','Name of suite',null), - ut3_develop.ut_annotation(4,'suitepath','all.globaltests',null), - ut3_develop.ut_annotation(6,'ann1','Name of suite',null), - ut3_develop.ut_annotation(8,'ann2','some_value','foo') + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), + ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), + ut3_develop.ut_annotation( 6, 'test', null, 'very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it' ) ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); end; - procedure include_floating_annotations_lines is + procedure test_upper_annot is l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; begin --Arrange - l_source := make_source(ut_varchar2_list( + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'PACKAGE test_tt AS' || chr(10), - ' -- %suite' || chr(10), - ' -- %displayname(Name of suite)' || chr(10), - ' -- %suitepath(all.globaltests)' || chr(10), + ' -- %SUITE' || chr(10), + ' -- %DISPLAYNAME(Name of suite)' || chr(10), + ' -- %SUITEPATH(all.globaltests)' || chr(10), '' || chr(10), - ' -- %ann1(Name of suite)' || chr(10), - ' -- %ann2(all.globaltests)' || chr(10), + ' -- %ANN1(Name of suite)' || chr(10), + ' -- %ANN2(all.globaltests)' || chr(10), '' || chr(10), - ' --%test' || chr(10), + ' --%TEST' || chr(10), ' procedure foo;' || chr(10), '' || chr(10), - ' -- %ann3(Name of suite)' || chr(10), - ' -- %ann4(all.globaltests)' || chr(10), + ' -- %ANN3(Name of suite)' || chr(10), + ' -- %ANN4(all.globaltests)' || chr(10), '' || chr(10), - ' --%test' || chr(10), + ' --%TEST' || chr(10), ' procedure bar;' || chr(10), ' END;' || chr(10) )); @@ -553,72 +485,7 @@ END;'; ut3_develop.ut_annotation( 12, 'ann3', 'Name of suite', null ), ut3_develop.ut_annotation( 13, 'ann4', 'all.globaltests', null ), ut3_develop.ut_annotation( 15, 'test', null, 'bar') - ); - - ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); - - end; - - procedure ignore_annotations_in_comments_lines is - l_source dbms_preprocessor.source_lines_t; - l_actual ut3_develop.ut_annotations; - l_expected ut3_develop.ut_annotations; - begin - --Arrange - l_source := make_source(ut_varchar2_list( - 'PACKAGE test_tt AS' || chr(10), - ' /*' || chr(10), - ' Some comment' || chr(10), - ' -- inlined' || chr(10), - ' -- %ignored' || chr(10), - ' */' || chr(10), - ' -- %suite' || chr(10), - ' --%displayname(Name of suite)' || chr(10), - ' -- %suitepath(all.globaltests)' || chr(10), - '' || chr(10), - ' procedure foo;' || chr(10), - ' END;' || chr(10) - )); - - --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); - - --Assert - l_expected := ut3_develop.ut_annotations( - ut3_develop.ut_annotation( 7, 'suite', null, null ), - ut3_develop.ut_annotation( 8, 'displayname', 'Name of suite', null ), - ut3_develop.ut_annotation( 9, 'suitepath', 'all.globaltests', null ) - ); - - ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); - - end; - - procedure no_procedure_annotation_lines is - l_source dbms_preprocessor.source_lines_t; - l_actual ut3_develop.ut_annotations; - l_expected ut3_develop.ut_annotations; - begin - --Arrange - l_source := make_source(ut_varchar2_list( - 'PACKAGE test_tt AS' || chr(10), - ' -- %suite' || chr(10), - ' -- %displayname(Name of suite)' || chr(10), - ' -- %suitepath(all.globaltests)' || chr(10), - '' || chr(10), - ' procedure foo;' || chr(10), - ' END;' || chr(10) - )); - - --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); - - --Assert - l_expected := ut3_develop.ut_annotations( - ut3_develop.ut_annotation( 2, 'suite', null, null ), - ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) - ); + ); ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); @@ -644,7 +511,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'procedure foo is' || chr(10), 'begin' || chr(10), ' null;' || chr(10), @@ -655,7 +522,7 @@ END;'; l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); --Assert - ut.expect(lines_to_str(l_result)).to_equal(lines_to_str(l_input)); + ut.expect(ut3_tester_helper.main_helper.lines_to_str(l_result)).to_equal(ut3_tester_helper.main_helper.lines_to_str(l_input)); end; procedure test_rmc_line_inside_ml_comment is @@ -663,7 +530,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'x := 1; /* start' || chr(10), 'this whole line is comment' || chr(10), 'end comment */ x := 2;' || chr(10) @@ -683,7 +550,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( '/* open' || chr(10), 'still inside' || chr(10), '*/ code /* remove this too */ kept' || chr(10) @@ -703,7 +570,7 @@ END;'; begin --Arrange -- line 2 has none of / - ' so hits fast path B; line 1 needed to pass pre-scan - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( '/* comment */' || chr(10), 'begin' || chr(10) )); @@ -720,7 +587,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'x := /* inline comment */ 42;' || chr(10) )); @@ -736,7 +603,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( '/* marker */' || chr(10), ' -- %test annotation' || chr(10) )); @@ -753,7 +620,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'v := ''val /* not a comment */ here'';' || chr(10) )); @@ -769,7 +636,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'v := ''it''''s a /* test */'';' || chr(10) )); @@ -785,7 +652,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'v := q''[/* not a comment */]'';' || chr(10) )); @@ -801,7 +668,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'v := ''hello /* inside unclosed' || chr(10) )); @@ -818,7 +685,7 @@ END;'; c_line constant varchar2(100) := q'(v := q'[/* unclosed q-string)' || chr(10); begin --Arrange - l_input := make_source(ut_varchar2_list(c_line)); + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list(c_line)); --Act l_result := ut3_develop.ut_utils.replace_multiline_comments(l_input); @@ -832,7 +699,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'a /* one */ := /* two */ 1;' || chr(10) )); @@ -848,7 +715,7 @@ END;'; l_result dbms_preprocessor.source_lines_t; begin --Arrange - l_input := make_source(ut_varchar2_list( + l_input := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'v := ''a/b''; -- this is /* not */ a ml comment' || chr(10) )); @@ -859,66 +726,6 @@ END;'; ut.expect(l_result(1)).to_equal('v := ''a/b''; -- this is /* not */ a ml comment' || chr(10)); end; -procedure test_windows_newline_lines - as - l_source dbms_preprocessor.source_lines_t; - l_actual ut3_develop.ut_annotations; - l_expected ut3_develop.ut_annotations; - begin - --Arrange - l_source := make_source(ut_varchar2_list( - 'PACKAGE test_tt AS' || chr(10), - ' -- %suite' || chr(10), - ' -- %displayname(Name of suite)' || chr(13) || chr(10), - ' -- %suitepath(all.globaltests)' || chr(10), - ' END;' || chr(10) - )); - - --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); - - --Assert - l_expected := ut3_develop.ut_annotations( - ut3_develop.ut_annotation( 2, 'suite', null, null ), - ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ) - ); - - ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); - end; - - procedure test_annot_very_long_name_lines - as - l_source dbms_preprocessor.source_lines_t; - l_actual ut3_develop.ut_annotations; - l_expected ut3_develop.ut_annotations; - begin - --Arrange - l_source := make_source(ut_varchar2_list( - 'PACKAGE very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it AS' || chr(10), - ' -- %suite' || chr(10), - ' -- %displayname(Name of suite)' || chr(10), - ' -- %suitepath(all.globaltests)' || chr(10), - '' || chr(10), - ' --%test' || chr(10), - ' procedure very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it;' || chr(10), - ' END;' || chr(10) - )); - - --Act - l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); - - --Assert - l_expected := ut3_develop.ut_annotations( - ut3_develop.ut_annotation( 2, 'suite', null, null ), - ut3_develop.ut_annotation( 3, 'displayname', 'Name of suite', null ), - ut3_develop.ut_annotation( 4, 'suitepath', 'all.globaltests', null ), - ut3_develop.ut_annotation( 6, 'test', null, 'very_long_procedure_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_dit_it' ) - ); - - ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); - end; - procedure test_multiline_proc_header_lines is l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; @@ -926,7 +733,7 @@ procedure test_windows_newline_lines begin --Arrange -- procedure header spans multiple lines before terminating ; - l_source := make_source(ut_varchar2_list( + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'PACKAGE test_tt AS' || chr(10), ' -- %suite' || chr(10), '' || chr(10), @@ -958,12 +765,12 @@ procedure test_windows_newline_lines --Arrange -- a non-comment non-proc line between annotation and procedure breaks the association -- %test becomes a floating top-level annotation with no subobject - l_source := make_source(ut_varchar2_list( + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'PACKAGE test_tt AS' || chr(10), ' -- %suite' || chr(10), '' || chr(10), ' --%test' || chr(10), - ' pragma serially_reusable;' || chr(10), -- resets accumulator + ' pragma serially_reusable;' || chr(10), ' procedure foo;' || chr(10), ' END;' || chr(10) )); @@ -988,13 +795,13 @@ procedure test_windows_newline_lines l_expected ut3_develop.ut_annotations; begin --Arrange - -- % appears in line but comment is not at start of line — should be ignored - l_source := make_source(ut_varchar2_list( - 'PACKAGE test_tt AS' || chr(10), - ' -- %suite' || chr(10), - ' x := ''value%with%percent'';' || chr(10), -- % present but -- not at line start - ' procedure foo;' || chr(10), - ' END;' || chr(10) + -- code before -- means it is not at start of line and must be ignored + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' x := 1; -- %not_an_annotation' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) )); --Act @@ -1008,7 +815,36 @@ procedure test_windows_newline_lines ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); end; - procedure test_space_between_dashes_and_qualifier_lines is + procedure test_whitespace_line_between_comment_and_proc_lines is + l_source dbms_preprocessor.source_lines_t; + l_actual ut3_develop.ut_annotations; + l_expected ut3_develop.ut_annotations; + begin + --Arrange + -- space-only line between annotation comment and procedure declaration is tolerated + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + '' || chr(10), + ' --%test' || chr(10), + ' ' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) + )); + + --Act + l_actual := ut3_develop.ut_annotation_parser.parse_object_annotations(l_source, 'PACKAGE'); + + --Assert + l_expected := ut3_develop.ut_annotations( + ut3_develop.ut_annotation( 2, 'suite', null, null ), + ut3_develop.ut_annotation( 4, 'test', null, 'foo' ) + ); + + ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); + end; + + procedure test_space_between_dashes_and_qualifier_lines is l_source dbms_preprocessor.source_lines_t; l_actual ut3_develop.ut_annotations; l_expected ut3_develop.ut_annotations; @@ -1016,11 +852,11 @@ procedure test_windows_newline_lines --Arrange -- spaces between -- and % are skipped and annotation is still recognised -- annotations are not adjacent to a procedure so they are top-level - l_source := make_source(ut_varchar2_list( + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( 'PACKAGE test_tt AS' || chr(10), - ' -- %suite' || chr(10), -- multiple spaces between -- and % + ' -- %suite' || chr(10), ' -- %displayname(my suite)' || chr(10), - '' || chr(10), -- blank line breaks association with foo + '' || chr(10), ' procedure foo;' || chr(10), ' END;' || chr(10) )); @@ -1045,12 +881,12 @@ procedure test_windows_newline_lines --Arrange -- -- present and % present on line but % is not immediately after -- -- e.g. a regular comment that happens to mention 100% - l_source := make_source(ut_varchar2_list( - 'PACKAGE test_tt AS' || chr(10), - ' -- %suite' || chr(10), - ' -- coverage is 100% on this module' || chr(10), -- % after text, not annotation - ' procedure foo;' || chr(10), - ' END;' || chr(10) + l_source := ut3_tester_helper.main_helper.make_source(ut3_develop.ut_varchar2_list( + 'PACKAGE test_tt AS' || chr(10), + ' -- %suite' || chr(10), + ' -- coverage is 100% on this module' || chr(10), + ' procedure foo;' || chr(10), + ' END;' || chr(10) )); --Act diff --git a/test/ut3_tester/core/annotations/test_annotation_parser.pks b/test/ut3_tester/core/annotations/test_annotation_parser.pks index 92860769c..c61c14d3a 100644 --- a/test/ut3_tester/core/annotations/test_annotation_parser.pks +++ b/test/ut3_tester/core/annotations/test_annotation_parser.pks @@ -32,15 +32,6 @@ create or replace package test_annotation_parser is -- %test(Parses upper case annotations) procedure test_upper_annot; - --%test(Treats procedure level annotations as package level using source lines overload) - procedure test_proc_comments_lines; - --%test(Includes floating annotations between procedures using source lines overload) - procedure include_floating_annotations_lines; - --%test(Ignores content of multi-line comments using source lines overload) - procedure ignore_annotations_in_comments_lines; - --%test(Parses package annotations without any procedure annotations using source lines overload) - procedure no_procedure_annotation_lines; - -- %test(empty source returns immediately without processing) procedure test_rmc_empty_source; -- %test(source with no multiline comment markers returned unchanged) @@ -69,10 +60,6 @@ create or replace package test_annotation_parser is procedure test_rmc_multiple_ml_comments_one_line; -- %test(comment markers after string with slash handled correctly) procedure test_rmc_comment_after_string_with_slash; - --%test(Parses source-code with Windows-style newline using source lines overload) - procedure test_windows_newline_lines; - --%test(parse annotations with very long procedure name using source lines overload) - procedure test_annot_very_long_name_lines; --%test(Procedure header spanning multiple lines is handled correctly) procedure test_multiline_proc_header_lines; --%test(Non-comment line between annotation and procedure resets association) diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 433987c01..4dc10492b 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -375,8 +375,8 @@ end;'; procedure replace_multiline_comments is l_source clob; - l_actual clob; - l_expected clob; + l_actual dbms_preprocessor.source_lines_t; + l_expected dbms_preprocessor.source_lines_t; begin --Arrange l_source := q'[ @@ -390,11 +390,11 @@ create or replace package dummy as gv_text2 varchar2(200) := '/* multi-line comment in a multi-line string*/'; - -- ignored start of multi-line comment with multi-byte text � /* - -- ignored end of multi-line comment with multi-byte text � */ + -- ignored start of multi-line comment with multi-byte text ☺ /* + -- ignored end of multi-line comment with multi-byte text ☺ */ /* multi-line comment with - multi-byte characters ��� + multi-byte characters ☺☺☺ in it */ gv_text3 varchar2(200) := 'some text'; /* multiline comment*/ --followed by single-line comment /* multi-line comment in one line*/ @@ -403,7 +403,14 @@ create or replace package dummy as string*/}'; end; ]'; - l_expected := q'[ + + --Act + l_actual := ut3_develop.ut_utils.replace_multiline_comments( + ut3_tester_helper.main_helper.make_source( ut3_develop.ut_utils.clob_to_table(l_source) ) + ); + + --Assert + l_expected := ut3_tester_helper.main_helper.make_source( ut3_develop.ut_utils.clob_to_table( q'[ create or replace package dummy as -- single line comment with disabled /* multi-line comment */ @@ -414,8 +421,8 @@ create or replace package dummy as gv_text2 varchar2(200) := '/* multi-line comment in a multi-line string*/'; - -- ignored start of multi-line comment with multi-byte text � /* - -- ignored end of multi-line comment with multi-byte text � */ + -- ignored start of multi-line comment with multi-byte text ☺ /* + -- ignored end of multi-line comment with multi-byte text ☺ */ ]'||q'[ @@ -426,11 +433,9 @@ create or replace package dummy as in escaped q'multi-line string*/}'; end; -]'; +]' ) ); --Act - l_actual := ut3_develop.ut_utils.replace_multiline_comments(l_source); - --Assert - ut.expect(l_actual).to_equal(l_expected); + ut.expect(ut3_tester_helper.main_helper.lines_to_str(l_actual)).to_equal(ut3_tester_helper.main_helper.lines_to_str(l_expected)); end; procedure int_conv_ds_sec is diff --git a/test/ut3_tester_helper/main_helper.pkb b/test/ut3_tester_helper/main_helper.pkb index f1dadec66..f60ce796c 100644 --- a/test/ut3_tester_helper/main_helper.pkb +++ b/test/ut3_tester_helper/main_helper.pkb @@ -155,6 +155,24 @@ create or replace package body main_helper is begin ut3_develop.ut_session_context.clear_all_context; end; + + function lines_to_str(a_lines dbms_preprocessor.source_lines_t) return varchar2 is + l_result varchar2(32767); + begin + for i in 1 .. a_lines.count loop + l_result := l_result || a_lines(i); + end loop; + return l_result; + end; + + function make_source(a_lines ut3_develop.ut_varchar2_list) return dbms_preprocessor.source_lines_t is + l_result dbms_preprocessor.source_lines_t; + begin + for i in 1 .. a_lines.count loop + l_result(i) := a_lines(i); + end loop; + return l_result; + end; end; / diff --git a/test/ut3_tester_helper/main_helper.pks b/test/ut3_tester_helper/main_helper.pks index 7decad88d..71575e145 100644 --- a/test/ut3_tester_helper/main_helper.pks +++ b/test/ut3_tester_helper/main_helper.pks @@ -47,5 +47,9 @@ create or replace package main_helper is procedure clear_ut_run_context; + function lines_to_str(a_lines dbms_preprocessor.source_lines_t) return varchar2; + + function make_source(a_lines ut3_develop.ut_varchar2_list) return dbms_preprocessor.source_lines_t; + end; / From fecbcc11649fd20fd04c6977b3c68dc6f6bbd64e Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Mon, 16 Mar 2026 22:25:09 +0000 Subject: [PATCH 583/887] Remove redundant parse_object_annotations function overloads and update documentation --- .../core/annotations/ut_annotation_parser.pkb | 124 ------------------ .../core/annotations/ut_annotation_parser.pks | 13 -- 2 files changed, 137 deletions(-) diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 8bb9b1b5e..6fcd7a5bf 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -87,49 +87,6 @@ create or replace package body ut_annotation_parser as end add_annotations; - procedure add_procedure_annotations(a_annotations in out nocopy ut_annotations, a_source clob, a_comments in out nocopy tt_comment_list) is - l_proc_comments varchar2(32767); - l_proc_name varchar2(250); - l_annot_proc_ind number; - l_annot_proc_block varchar2(32767); - begin - -- loop through procedures and functions of the package and get all the comment blocks just before it's declaration - l_annot_proc_ind := 1; - loop - --find annotated procedure index - l_annot_proc_ind := regexp_instr(srcstr => a_source - ,pattern => gc_annotation_block_pattern - ,occurrence => 1 - ,modifier => 'i' - ,position => l_annot_proc_ind); - exit when l_annot_proc_ind = 0; - - --get the annotations with procedure name - l_annot_proc_block := regexp_substr(srcstr => a_source - ,pattern => gc_annotation_block_pattern - ,position => l_annot_proc_ind - ,occurrence => 1 - ,modifier => 'i'); - - - --extract the annotations - l_proc_comments := trim(regexp_substr(srcstr => l_annot_proc_block - ,pattern => gc_annotation_block_pattern - ,modifier => 'i' - ,subexpression => 1)); - --extract the procedure name - l_proc_name := trim(regexp_substr(srcstr => l_annot_proc_block - ,pattern => gc_annotation_block_pattern - ,modifier => 'i' - ,subexpression => 5)); - - -- parse the comment block for the syntactically correct annotations and store them as an array - add_annotations(a_annotations, l_proc_comments, a_comments, l_proc_name); - - l_annot_proc_ind := instr(a_source, ';', l_annot_proc_ind + length(l_annot_proc_block) ); - end loop; - end add_procedure_annotations; - procedure add_procedure_annotations( a_annotations in out nocopy ut_annotations, a_source in dbms_preprocessor.source_lines_t, @@ -189,55 +146,6 @@ create or replace package body ut_annotation_parser as end loop; end add_procedure_annotations; - function extract_and_replace_comments(a_source in out nocopy clob) return tt_comment_list is - l_comments tt_comment_list; - l_comment_pos binary_integer; - l_comment_line binary_integer; - l_comment_replacer varchar2(50); - l_source clob := a_source; - begin - l_comment_pos := 1; - loop - - l_comment_pos := regexp_instr(srcstr => a_source - ,pattern => gc_annot_comment_pattern - ,occurrence => 1 - ,modifier => 'm' - ,position => l_comment_pos); - - exit when l_comment_pos = 0; - - -- position index is shifted by 1 because gc_annot_comment_pattern contains ^ as first sign - -- but after instr index already points to the char on that line - l_comment_pos := l_comment_pos - 1; - l_comment_line := length(substr(a_source,1,l_comment_pos)) - - length(replace(substr(a_source,1,l_comment_pos),chr(10))) - + 1; - l_comments(l_comment_line) := trim(regexp_substr(srcstr => a_source - ,pattern => gc_annot_comment_pattern - ,occurrence => 1 - ,position => l_comment_pos - ,modifier => 'm' - ,subexpression => 2)); - - l_comment_replacer := replace(gc_comment_replacer_patter, '%N%', l_comment_line); - - l_source := regexp_replace(srcstr => a_source - ,pattern => gc_annot_comment_pattern - ,replacestr => l_comment_replacer - ,position => l_comment_pos - ,occurrence => 1 - ,modifier => 'm'); - dbms_lob.freetemporary(a_source); - a_source := l_source; - dbms_lob.freetemporary(l_source); - l_comment_pos := l_comment_pos + length(l_comment_replacer); - - end loop; - - return l_comments; - end extract_and_replace_comments; - function extract_and_replace_comments( a_source in out nocopy dbms_preprocessor.source_lines_t ) return tt_comment_list is @@ -317,38 +225,6 @@ create or replace package body ut_annotation_parser as end parse_object_annotations; - function parse_object_annotations(a_source clob) return ut_annotations is - l_source clob := a_source; - l_comments tt_comment_list; - l_annotations ut_annotations := ut_annotations(); - l_result ut_annotations; - l_comment_index positive; - begin - - l_source := ut_utils.replace_multiline_comments(l_source); - - -- replace all single line comments with {COMMENT#12} element and store it's content for easier processing - -- this call modifies l_source - l_comments := extract_and_replace_comments(l_source); - - add_procedure_annotations(l_annotations, l_source, l_comments); - - delete_processed_comments(l_comments, l_annotations); - - --at this point, only the comments not related to procedures are left, so we process them all as top-level - l_comment_index := l_comments.first; - while l_comment_index is not null loop - add_annotation( l_annotations, l_comment_index, l_comments( l_comment_index ) ); - l_comment_index := l_comments.next(l_comment_index); - end loop; - - dbms_lob.freetemporary(l_source); - - select /*+ no_parallel */ value(x) bulk collect into l_result from table(l_annotations) x order by x.position asc; - - return l_result; - end parse_object_annotations; - function parse_object_annotations(a_source_lines dbms_preprocessor.source_lines_t, a_object_type varchar2) return ut_annotations is l_processed_lines dbms_preprocessor.source_lines_t; l_source dbms_preprocessor.source_lines_t; diff --git a/source/core/annotations/ut_annotation_parser.pks b/source/core/annotations/ut_annotation_parser.pks index 5a041ccb4..8182acbc7 100644 --- a/source/core/annotations/ut_annotation_parser.pks +++ b/source/core/annotations/ut_annotation_parser.pks @@ -29,18 +29,5 @@ create or replace package ut_annotation_parser authid current_user as */ function parse_object_annotations(a_source_lines dbms_preprocessor.source_lines_t, a_object_type varchar2) return ut_annotations; - - /** - * - * @private - * Parses source code and converts it to annotations - * - * @param a_source_lines ordered lines of source code to be parsed - * @return array containing annotations - */ - function parse_object_annotations(a_source clob) return ut_annotations; - - function parse_object_annotations(a_source dbms_preprocessor.source_lines_t) return ut_annotations; - end; / From 2547b4010eddb17eebb0a3f77a2eed74587c329e Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 17 Mar 2026 00:04:45 +0000 Subject: [PATCH 584/887] Update code to avoid --- source/core/annotations/ut_annotation_manager.pkb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 65f7b3e40..05301ea94 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -241,12 +241,12 @@ create or replace package body ut_annotation_manager as l_sql_clob := ut_utils.replace_multiline_comments(l_sql_clob); -- replace comment lines that contain "-- create or replace" l_sql_clob := regexp_replace(l_sql_clob, '^.*[-]{2,}\s*create(\s+or\s+replace).*$', modifier => 'mi'); - -- remove the "create [or replace] [[non]editionable] " so that we have only "type|package" for parsing + -- remove the "create [or replace] [[non]editionable] " so that we have only "type|package|procedure|function" for parsing -- needed for dbms_preprocessor - l_sql_clob := regexp_replace(l_sql_clob, '^(.*?\s*create(\s+or\s+replace)?(\s+(editionable|noneditionable))?\s+?)((package|type).*)', '\5', 1, 1, 'ni'); + l_sql_clob := regexp_replace(l_sql_clob, '^(.*?\s*create(\s+or\s+replace)?(\s+(editionable|noneditionable))?\s+?)((package|type|procedure|function).*)', '\5', 1, 1, 'ni'); -- remove "OWNER." from create or replace statement. -- Owner is not supported along with AUTHID - see issue https://github.com/utPLSQL/utPLSQL/issues/1088 - l_sql_clob := regexp_replace(l_sql_clob, '^(package|type)\s+("?[[:alpha:]][[:alnum:]$#_]*"?\.)(.*)', '\1 \3', 1, 1, 'ni'); + l_sql_clob := regexp_replace(l_sql_clob, '^(package|type|procedure|function)\s+("?[[:alpha:]][[:alnum:]$#_]*"?\.)(.*)', '\1 \3', 1, 1, 'ni'); l_sql_lines := ut_utils.convert_collection( ut_utils.clob_to_table(l_sql_clob) ); end if; open l_result for From 7ddbacc4b02faadb614e2855758724d47f99dc75 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Tue, 17 Mar 2026 11:34:59 +0100 Subject: [PATCH 585/887] Added tests for contexts and suites --- test/ut3_user/reporters/test_tap_reporter.pkb | 34 +++++++++++++++++-- test/ut3_user/reporters/test_tap_reporter.pks | 8 ++++- 2 files changed, 39 insertions(+), 3 deletions(-) diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index 87ec1dd9d..ed10a5aaf 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -159,7 +159,7 @@ create or replace package body test_tap_reporter as end escape_multiple_characters_test_name; - procedure special_characters_in_deisabled_reason as + procedure special_characters_in_disabled_reason as l_output_data ut3_develop.ut_varchar2_list; l_expected varchar2(32767); begin @@ -170,7 +170,7 @@ create or replace package body test_tap_reporter as from table(ut3_develop.ut.run('test_tap_escaping.not_skipping_escapes',ut3_develop.ut_tap_reporter())); ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); - end special_characters_in_deisabled_reason; + end special_characters_in_disabled_reason; procedure special_characters_in_comment as @@ -187,6 +187,36 @@ create or replace package body test_tap_reporter as end special_characters_in_comment; + procedure context_as_commented_subtests as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[%# Subtest: A suite for testing different outcomes from reporters%# Subtest: A description of some context%]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_reporters.passing_test',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); + + end context_as_commented_subtests; + + + procedure suitepath_as_chopped_subtests as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[.*# Subtest: org.*1\s{5}# Subtest: utplsql.*1\s{9}# Subtest: tests.*1\s{13}# Subtest: helpers.*1\s{17}# Subtest: A suite for testing different outcomes from reporters.*]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_reporters.passing_test',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_match(l_expected, 'n'); + + end suitepath_as_chopped_subtests; + + procedure drop_help_tests as pragma autonomous_transaction; begin diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index aef27fa0a..d24c76e32 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -31,11 +31,17 @@ create or replace package test_tap_reporter as procedure escape_multiple_characters_test_name; --%test(Disabled Test with special characters in disable reason) - procedure special_characters_in_deisabled_reason; + procedure special_characters_in_disabled_reason; --%test(Don't escape special characters in comment) procedure special_characters_in_comment; + --%test(Include context as commented subtests) + procedure context_as_commented_subtests; + + --%test(Suitepath as chopped subtests) + procedure suitepath_as_chopped_subtests; + --%afterall procedure drop_help_tests; From 3d38fbe72cf28bd2b8af08bd8fb4e2d3b92122b4 Mon Sep 17 00:00:00 2001 From: Jakob Drees Date: Tue, 17 Mar 2026 11:50:51 +0100 Subject: [PATCH 586/887] Added TAP subtests to documentation --- docs/images/tap_reporter_suitepath.png | Bin 0 -> 43331 bytes docs/userguide/reporters.md | 4 ++++ 2 files changed, 4 insertions(+) create mode 100644 docs/images/tap_reporter_suitepath.png diff --git a/docs/images/tap_reporter_suitepath.png b/docs/images/tap_reporter_suitepath.png new file mode 100644 index 0000000000000000000000000000000000000000..488c7cfbf9486c2e641177c61ad6480e8546af4f GIT binary patch literal 43331 zcmdqJby$?`+W)K4NQZQ%bayC?fPkbR9nxJ=qkzQFpnxEq(jX}@G$6a~vEO49tC8_jTX*b$-t8`8_8}>!~s>HYN6*J9ltZRTQ4x zxpS`w`E8Afj(nxt7($O69(pMnddYj(Sa{jHy3p&|JKNk*u&3u2rPui3K`+23AVSa2 zFCiouEQ2Pp<*@tPq1X~OnBdM zHEkB#8bj90$89=y?VphpL@LmGMLuSDBqw2?V9mf_YzrTCxfhmVLf_#QEPK8&T>bfY zNO08Ya^rlcvTtk44p-s!%isgyuTi4I{K@SPU;d|&K6FHFBF4^NUJCux>1`hoNH01v zGIGm9;$^SywiK<-9*A%`$!i{(4y8|N7p5swbCgS;-g+Q)cEnyMQ~O{7Y#QcNzX4CD z28O+4%>|#L6Yli{L8nT@>M(X54ELr7_2*=cRl0nIZ~0x{Il+CRX!=d2z{tJVE(w4B zj4HO}+UL=usRw~)^9CxPGo@XUG|3hbCvJXKAL0P87hcd9ZbCxBF^Ulib#6&Sw83~g zk(%k23nF4*Bgva4_**6SCE&zWVOh*R(yZ@4NXP^`%ydwJf>4au*Sig(*INp z45Ne;4soKb~s8&yTTDPLwkV}iEvsmOtY`Wfo3Qu^4 z?PlJIAa7ncT-PvINvyWh_VZok~|o7%%w4F^m3g710ihU*mRs4O0N)IG8QXT?*RiM-=CKQyq^MtQu!%4Bd-QDk}ZvTj7P^KhjB^XN1@ zrSYyO=tbPg6JH)IzB~yl3fr5Pg207X#VXImZg-qmS85;w6yNIf#G8Gb{7Dq@wwd=i zoJr&0{w~r*{0hUz(rlVPtic6i^mtJ(xs_nKP&$OGS4`KzcdkwvAUTemL4Vb^!{8W~ zv-LJkRH3WEmo2zaY~C>}EitNTuJ(bT>4%t9xD4GZ!ftohK+jE>qY5AT!0h>Hi{Eio z6=YEQZlq=tsRqpq5cu$F&$oxk4Uw95)OGB)w~k*uLLFWy`c|wlRpG7I4w1XNT z&?Q1q1*7Vho2G^|q|fE=D+n1RHrr4E75sDt&n+kR1W=Wgx**m}lul^ZHN`JTA0Ibu zS;=t4!U$LF@Z*5h*vYQsMvC>1h~q7p0hhEg#u;Whq&`m0pMlqg+Ci0Tl?)`S!*7O$ zzYg#jYw4u{V?n98_J)3$url_=)Su-mc^vlx6#UNbJKaO!$z&=~#-{*2Ri3ecYrd+c zN(bi1(E9ou5#^@PjU&%B&v8QW{VeswKrqxe*Z#Q(UgXNlh3u%n(S`3tg&~tc4f6q? z28^Up%$zGi9ICp;jyPt2zQER^Q`HrYZbSfYmPJ>KR@TMFTZtLt_B#O+G-SmR4Wb?9 z2TCVf%<2?+Es33|#tlA32NRPzpT@sH?lVK(8hGFaZ{8{1C-hRLMrSz-%ii~X^h!b> z;rl?J&TEtSsU@NoC@~yuMS@7cEymD<>Q?AY2K81_ZKx6ac)hpf`5DMfSD{qNbaB)| zdb_~^Iuu7>{&^-l8(R0e_zq7E#k#UO?G*AGIuj;5pFRy*h^OmZWzrKyGD=O6BYnC%(?PRrH+TAlN71)_@;CoxiAo>2_MRrP~V^NDvwv3O1>0|gc zR%{lt(9CL=>4x-Dr?wur9z~JF8!eH6I4|rOG7h0Tz3d_Gch+eAN%`wdgd<0+-`vh@ z-rK!%lDP=lEwr0;j4iXYcEOhzbFexJi7IJ0NcGeTLC>M>i<_iA*^#(oLPgiVkN8^h zsYzni)143e8qU8&;7^Zs8SZvMA&jH_>iF<5{y9%~E^FhXu8H{E;pO?0EAE`xZL#{pY{0J$pLVjdj7m5NG6lKsxs0{j~Ig}d%MTG{5O$l{3x2{@E0*s)s8*2B?$QtGJa_o*!-fMeD6EtO))>* z_P$8@(@+ZB9gjxM+rU3Vd$}k|rJY%WBM3hfPdY9eJK*uXzWs|=h4`j!djYA%^*m!g z5s6Ui;F8Sksh9*@tg_u6cpME~=Z}#hRb`?;&FI$wf4J>wu1E7d0JayZoBmNd$wUvhrsI)!UgG(8%80j{h^o{7;ng z|Chhh&oqut+DIk!d57oOAMBnHB<+F5ns@OYuAt)pb`@LUXOb7!8LAf(OH1E}ww4=^ zSSFbrKox&}QhFZzWRb});K;4+-IC+EoXOr9GGIq;y*ozN(GbkD(Zzfsh}VIRywf|` zzYY-$R@xge_2AIOW=xU0R33v)~%*S*{2Zb=$JFC=+Ek>R?w#7a;Jym%|i+2SRXO4sLyRMqXaf~&xU#pmih=>V@H&F81h|oT9^1WQOC7EM> z320q7>7PxMCfs%r7DYx3UI-`Me*q z#+Abek^zY;gx3Uc4`V_&Y>&u#j)tbOn?o+2Rama^7ekQ-EX!|^tV9njmP&m6ekT| z@JSgj2hXcV2-ADxf0V+E=Eroo(z5*5N>)YW*}F1OK13%cS~SR&sr2@NG4j+5o3_m2 zwz5Ba&tjihX*P3w@uJ2MJhIqciNAxQz=x}llRc1|A`{J{55)cqF2n(4UZ!>M$plWhCivp1vYYIaG(mm#!W zCf&zwE6Eys-O}lpk?Bla4skYw->v6{FJ8XxT#4NpQ%w{2*`vYAPg)fv9M`T#Z!;!` zx+vq`xKIM2c5s`esr< zL-(XMu~ixab|s>ma4$`9rSz*s+>-If1#%p8!pYs@dL~t+&4@yw&DvcYhrKCdX!Sxo z!|B4zf!;iY&GJ0l7|BO(Fu#t#DPaVXK1AV5%UCAY-{nkl}%a3^oa9Ix^lKE5L#WNQ0(&&0xK5z)*J#wd0-+i0ET%sK>ze^!OS0 z(@e>&e=pL@X@7!JwB8}6c1^w*qw%MMVcQMi?&e)Z!gImtv(c>R&`WfMJ}>!_RGemQ z)T_Acuqap;y<|w`;yquPV^&t&xYw!7d6m{7j8EQ|`Y3TpnO)ZxD2bZ)B#*9sIFu#~ zWH5Wka+S&=XRR>AZTB#4G+$M@r~X(`+vh>)((H@zZ`G?Ug##yaui4;N5~i(HD0Q_Q z1h;q4;E43Ya@70}X5v8XUEx8vjqspLlG6vnGcd~m^%z-vdmx!q-4hZhIMTI!378+} zD5m&c$a{=BERF)`&fDKTVHEx`^Z0Q1OOnK@fuiasvMcFJ4#uE2z!>keMuGbdnQl(1 z*A$LlmLe>8HG1s`YoOc5het!!x}7n@$F}*;*9fE}Y*3}@t=OM{BYPi;3ok^Qr?pxN zc11kxcxTE=sP8P6o((KC+n1>@@?SpFTvWD4MZ9Lk)D2u^k!;yrzOb`(N|z;Lh{E#w zvEIoyH$0$b96rbCc)h9AhZGJ%coB!up3f&p7WqW5#%|j6ZpkJ*^LQsu1wn20sxU3a zttT-4^;2>Y3!zHzq0I90bWbC{TTc0+e_$mv!@)x7%O)L3PKTAQp&NEy*>@xS3a9Yb zU1Hh$?soI_dPDjr&iuxj|F`23GGrb-UI@;2_XXo&mduBYnqFhuH-umBcbNSdR=Wni zGyD=2vidGExM!;+aBYRke}k5o3A&ClL*uW68sf>kX^_AAI~>bxdvKVI1FM6a6RohY zDVNt>vTx6Uhx(sMC}+Y^eW}=foTcIyvju(MEIv|9dq;`}yx^y#?tB*hm_G_Y#b7`G z^;$L7>Y$^{6*A0*k@L1Zb86&rx@F-HJI`APZpIv&^NGakWNcIVVI_? zYST`let3NI4>(84^o!0^kn8*Z0iBuK&DU+40;&4EGWygg->mjt@1 z9?cabZYbgL0L=3xX_8QXU-^~}$iRF?v{mVjv#>Y`)+lRk_RakU>xGd3S(ZJ*8)ql- zGv^B$oAezY-pO?rgvYMg1c?_dLL!SU`}N~cbc;t|6#v6T}}FZ4mFmS(I+8 zFjzwH&X(&nF1C>(YCf|dib!LFbC^rFGKAGzSSAQcMsn@bIdI72rkTy9Zsv}e-b3Ko ztdd09((aEo8pI9%iPeUpDKkxtyZ!sHJfWX{0Pgo`Y{iza$|P`Rb^OQ@XuS!fuMfuY z&G^MlFkJE*0+Ny(H!Ey`;Rkl44=?t1928WiMyApiiI}ng)Wg9~yFem_9~qjE(ohpP zfWq|BiIb~-n0@BFw}%Wuu+E#$$VB0ZI7T^3zl)I3q_e8$9I#Le=vbIY z$yd=OV*$mfsHi_uPs5KndqPrB+41phhPHKb51je$x)P@9=kAYfq|qSLFcalPN09AD z|CP?-@Z9&WXyCAABJ26Za))Wp8^EO(CuJ|9c^O9bggfD2D0_^96Y{v8ElZ~)3`><=T^f}(6etNX`uOt)v>rh-8czWKA`gZ)x zyG?bzh-?e|TYOp_{8#v7!u_6bvL}Sswlzd^3|*dCXb2qr#LDyJN$Y(RSM100ny+{kWWV~8DC4E()wNRVaZrX?`MuaPE2YT3QzaKD z81x3SG?)D1g4i-Jm<*D=qT7i` zzjp6U&+7gwSbE}ifOlutZoOJZS1PZxTK`pyEf5|K821s_O?; zxW4xL0a@M1AH3jh3FRDO*`%^FM|)+R8gu`jQTa;p?yd+9>F+-|qp^O;NcJB5m$3<+!>6N!Wuc2&bnTZNXiO(Vm`mr z!-NJ(8bzNj=hj3zL*I0L{3wxql}fl+Bgsg!a9!7@Q9+qse(~L2SWefV`{#PRxhy_A zuqnHy0dV$$dPtOBpomJY&3Yh~@w@L0v-&O>`W&Ix`h%w952F0`Zm6xy%J&2x6Bg>~ zNivaVRl$s&{6YipYRQX#ToJgS``&9Y3RYwSkz+V7sD zj^ec?@C9OC`C@e**0H3u1=7Wd%PvAfMWnxUe$KhG>KoHra#ysg_<)Sdu&JJPcDgn- zMc%>t{vL@l&QCCYkP)roQ3@B~9@oGqd&s^93ZGY)p|7z}VBBs;JZD4xtags>FuT+| z`B+=H`9*>xAD_$vZZ6R3^;^fpAa&2BVCP4vmC!M*T` z+A7aLsUy$tmMgHPL2;R#5lT9!AJ)(^jaxvM7BkLneDI-Y2jo0<*0UgQ8ItNojfVE1 zE|MnFLjEd0U=T7O&2_K#3x@2>CGEm-J*e^HDw2k_jF^!D{Mh6pPvo)eBjg5+yva$2 z)GNEzH=6du{MCv2(jH6&nvj4ZQjq@)Ad=lwzYXJ{Kv-4 zTvZvn1y`ZHy@k7X^^6bZ9L*SpS#xt={6SKc!U9`d=_Idd@ugx9MUAU1yeWt54F8b8 z@*D|6x5X*`O5~cMeY&0<`rkyZvHHl)KcVpVIFn||sFBQLFMWH0Q|5fq7|Q=QF=~ts ztN3WNmmn^8^aiUfo#N^8Nr$mX?%bKV>3D=8p!G~i)uUkOxY4uybg$u7OFO|}{Do1< zw`*xY^PgYS+vEQI8VPK*s+;sN*}r(no{m21g3quGr^+1MOStFKanNttv*QX11%W<< z$u2G74#(^{mwnA`I&N+}^wX^J-!JZw4rye=S5}*A^Wh~~KyHwEoKc-8QbNO#DcTI| z!(w-+NE8%qnMj_i<+Jm@mW+N0dYiZBE%-3=@ev5^T=P%%`KI;h+riQC8(r-Xv(%^E zA2X-@8+~=9h_fyQyF}rng2|kUTJKlrrYN+Zp*QTy-kTzLLpUlMXDiFLYDUF1La-=v zsJOV_hEo;TK>9%b{^nUlZIZhb2c9-ufI}dO|6Eqqyo%yr{}?qXT%n6ywHP{+0z+BO zYM@rM1SFX$Gc&W&vkqY>1+ZX0GcX_N8fLFm9fAKHeb~EdX*PB%3~x>ucO}+LuZ1C# zDEKnMI2A)X2m9wK^b@Sj)W(~JFV^8?z~fi#P@TaGFM1@i82QC+i`)Hc&1dHT?V91H zp%}ICj550O%z78Od3}t5&Tbg8HP^Hy$K**|y zc!{Je>AK8ZIJ-b#lMt?!e29;sqTNJ+(w2w-p{Q|+WgjP%_U_c(ZaSLi0LU?4&@0+q zk2_z$gz+7)Z1Zn7Z6!h?%2hor-%pDO3SjRxYhlUd%I-hh9zGcy)GqwutD96{0)r32 zPhG0M1jQlKj}iv{w5$k*0<`q><3y&7J=|3b%+dkH6v^WYw=iBRft0{VWW8XeAOnR+8)OPpkPBQ=&a;`Dhy>?NaBJhL+dkf6o%YSGAq|HxD*N z&_nN*I>_ep{wc2DXgF<}woT!+z{sD0f^f|W=SHL+ZSp$8S-A)p=H|@u=`8!7c2zG( zS}c`2SDT)euCDKc+T)SQ5q?`1hOTbc~x7&kIzJ6wyG z!XqE^ghm#N`1xn)QS9YqnHT#QcAcv^n6I*&#L`uP zc1fXl&}M%pJdR+;B|3aGk>!N`mH}2Ya z`^tqX+^unM?X9tE+c3)eiC-Sl*!+B}M_Hwhs7Md^btk{?t%|;_!!Vkx2>-{z?SBmo ze-Gmlh5t4T^Sr|ur}-Cx##pa8-xLc|sbGplpRA0sN3ig3-D0cDox?1GxdL-x=7D%h zPR?(cg9knIPoDTaR`Iv>*{6G{?%Wn7PC`0$Bd9H&>65Up_1n3js!^c#GQ*w23hdeT z*@WXdQL5TwMYE}2KdAN5m)tb|vvg!YRD5(g@P8hKz0g$0#>Ti3Z{z-$UjJ{x`8}im z@EDS7KT!lg+fMp4=%>ENYXKR#mu5-VcmJ@|PzF^m>4gg?+T!a~2whi@FMe;%^3r#n z17wQ2v6lAJ-&g}rvFo$y78@djd#>SlSu-jC6+lH59z+$a{9)tE(tYpddEfJkk>-k` zoa2j`!4e<*a$4!`cSP7DBQcd!ZPA@v zoEI?pZ>0=jwCwgX#-gDYu|SbqDZ^YP9sP@6l67xom1(EvsB{Eb5h6^U<2D|=al5^) z2xC4MIadYY!#6JuQCZL5t*&pPd^)viT9Cr^^fB6T?O2J(d4%?sN+-d-;Zd1Nr>~g- z)00x4%IO~|fH6^V8HX3R7yWRf)Pvzs8$DQPwvbzcO=?_;g0a7CqP z*zoTa44!g_PhogH5LJG=?fbga1pVjh9t8%|sOSFIuAjTy(RW2iH-VQUz+FLrQrTi` z366b)xvZ<*B~>OQHFz@i%yG28siSQ+FFem#5a74qaWMFix5g5n*9J*7>XVg1?ppJ` z=B4uUiKiEVMl5}@0H*PxkuH6&-cVkzE}oj!rJqU{wRBys0Z-fm^@Sz7@u>!j<`V+L(VJs}^JNOQ9Br_I@wj z8@9|K{?}Dsgu?~ywPGI*pP;e7ljA=)Wb3(r@$~U_+g$r>o)N{|6*y}{@NA?8`lutc>kJSVpNM!l>5*;{;?Pe|DddcDK8e$bTkb6r(1zy#UsyN45-(t$OQ`uF zAE+;Lr?D5OyT_uvdZWO6%pi~P)$9^59T;LJY7S`D<0`b;gk$%hqjkSlFGtM)Y~jz@fJbTFfDJwsX-MErSG96j=B_a*5)gdTD{(-#JQ&E+eoL zZ`K10H!*eBls%?`xuJF(57afK-6xy)IPjp$%pBi*N;Y(zWcg5O?qx(mh&v}05oL=` zAU^4-=Xc-gN1p8FZxK(b*JZEP!oH>FhgO)&p1muxREdL_E6H%t+z^`I!G@m3(;+vT zdSIvSOX`WHL|^qDY4_X%gE+|QR}+SSiw=WNJz@PCY1d-{)=m62-1fG+*RQfJ2nS6q zwxstM7KNqoF=XaY1sC(9UYCf6#BCTpxT~776azpf$61b~%?x{(|8&usNarx!5VB>A z_Ur+-!gm^X@^`bu!R<45*S8H};OB-x-+`QpIu&g3ntF=bzdcTuui&8iy5RY}%GDF~;p^w9v@HWtwVm!)j+N}fP!BEjpq1HCaC-}qxw;p^-Dl(a3qZ+R=3N3nD^&~PXDR0;L7WL zJXQUk3q6T`bs6WI7j^r6^g97J$UTV%PxgJ48n#@BI{QPuXe&MD(%giG-M3~LJbZm|aYudv3@r2`+=T560Xm(A9JY}#ILLe4IbvC72CkbjDag?#wto3^fb)$=pnvgba@ z)`LB@2%a~ak?npb>n$q`r9O(+qH7thjcX+k%BO_I&&Y-!Z>8mupL%DvDp9@Z|VjMsGbo#3#v{Q#aZ8#p>m+o?IF{`G-Z*&u7rI{U{`jRyt+tw*d zlxmnLVrA?h)5<3rdF?ADuBTr=&6%Qp{y~~SDC2dn=tLlj&$fH)Mwbibe{Mh3e%t_9 zlX=2)fg$ubXYD@k+}t|)Y7#qya)sA)4No0gVwT8xUEcHoA=ddLC2H)<0@cgBQ!H~-30qw&r{O z*~aUrzMW+E8nbQ`*XoHMTfs~bzyYe>EMTfmJYCjwpbo__4We?D5x>K2 z4K4Q>XIc7U?uoZhXf#T}@)^;KEl`5Sj>~Nln zB3Q1ltOSAujI#tn9`RC;vY*J=hhUwspM*lm!+dq@De6Z7jeEaAjk~; zU!kXk8Oo)Qe$xQTbFb5$EZhLCV2U$sUU35V{Qdq8DiUj!;=F?xPtUn{Gd!iyYr1}> z^VpshNp#Cc_yB9f5$BUhPC+~a*dfI7riw)QPAu&)nbce%&eyf(;G;`u9-wjrJS79F ze6e?2bq+Ig@s~yTpM&5RCHTch+aIZ2^?wmr4U)+0NC{(-hHz#V=NkyW;NE&~rY=tE z&9rtG(3tw;k=~nHzMx(PJ0i0*YN`1;rQ@S}B$rBgLBteuiUtiFEcU&I(t=o2ES#m~ z2CK2+t&%R$l}bl-sntcZhXdp0pCu&1Wy8v(;gwB4v&)Xpm1RKyFDZmq4Y~R@R}zAo zTr^iSFa6?CrQf~efM1HtN8M=Ps{M*BGI8*q4!g9S-)&E|S*?@CaLeh-uaU;@CiG!U*FtwqS z@*G^goOLrZh)IFr*hAsmh3+aVb!B4a8rgtON_E7w?|{Bz-^R248E4?VP$)YdnL(F7 zyCC#t&qz&e|dDAQfI*qH^IX2!uJBW-?1ar9*%Z?80&JZfMV;x9bv#={!G4p=-~YtAV-Z+YJvy-&sEYD_uU1Xp%5= z8pW$D2h>Kqx9lqOr=%NRCtscI7r5@~ z)h=5|=N%OMa{+M_)K9f?`UwtktUeB);7=QWUdOa^cv<%(1^`zo(8zpSu?561+X^$W zeAOcPp5|ZZU7J4jy8n0Sc1^WdHP2G=KOlFlb+P~9S9kQW1RpNAIqvuz+`J+#U8JN$ zAkp8qrkR<;+!&6Qx;{yp?H7ujP_qy7y#0uh8jtTgVrF|CVDb^% zcN$+6eQb>B+aQa$XolU$>|Y4`Kn`EI#1)4R_GfRz^5pM5#vdgK6g~~IcHkxifMHE9 z?d~pLc(9eOUuDycz{u5VPCqxRw4K|WZ~^cI+ar5*06_T&7La8!betBPdUMn8MFN!S z6PQuq)?Fyu{!e+q^~C-f?4f)NxUeml)b!_0a@kp-nk2~J9x^Z{|JE06&2j!gUu?aY z|LYte&uexGH1ID9ool>q?qnH1FOJE6B>_{^e>&>jsDRXfT%)sFM}3cyQWwgrk}#_P zQdTfu9k5gZo-222o}U)aO8Dm_fWX7tSmBDMt1`%zx_sn~L^-Zeh6uw{1=-XU5=k|N zK8gG21;st$Hd(v)f<2QWt#;5Ut1o9SekVT8AuPLiwBO~>p>)1XYjw7Y2zapZXk*RV zI;|paEeq+y$5%+Lb{h+h69bGez5XL_SWAfiTi)=xgmMxDP{oMPzUl*o1G|Dg36t76 zJ~*?ckyke-KD;37oFs^RB%3HN>M93!CpDVl*_9AOg)RjNi=r}!J(54e?mrXJ)>sU2 z{(v&pw`GcWktsW~IWu)35#YA``)>H;A_E$g4c?QI8691R$YT*gGZNYySb}-Ihv=Z4 z@tzYFFSBe(`f>rm$V6Sxn}-5CnMPf>Y#0*)R0yALZKGk^;Yf%7sig z|4lAL=C(Q6fXsz7`JVd-!YR!8{FwZ`h>Bt)+>=$+-`eqsUF-kZI`A=#X9r6byz~0V zs~o=1RW7qNT{h3+u3mUi@A|gLW=@RWRLtpGFmeAC)qI_9!k1C+E6_a5SGc`WMPCpv zHQfTIE;7Nqw`QD?BwJ*Pb3RqC#9J=$m%FaGzUpu0I;T6SPub$>pt?{EPbsW|@GE3h zUVO-C=}<2-z|GZ>Y;&~Yc&87t*}6HiwE@|$jm-{-AB|>^PD5sQ5wMf0(y==gACz9BMzJAbgNXO z#fe&n{I=x+Ob(Nu$+fQT+QNTq2q*l_!>8>zZ1rC%)_z@+QkpdQpmfeBxagsNj0?#0 z404s4E~>8D`bjLyZm;dtyhS6O{LjX!)iR-l4;WiFHpAdBG)890YsVA$-C0#~p8&S< zjQZgU#}l4dw)uJ&JQjK!VzYQ}FKqOD!q|Cq`KP1qjvR&U@aRUA#=i5lW?HbCi`jdN z(qty<&|N=oWqF!6gRq^;Lo43LUkP)p`pI8pr-!WdWqyA+bbr9N@$Rs8q&Ro+*IF+$ z+2l3LKogm-yyuY7SlG<fG>+M(B$UmEs-4tsBcq~{OKd)P5A92M4A(#*>e8EM_73=NHOB5 z_4%lbVE)pl?!iu*ycOZXJjz>fac`MZUZy51Uj>PVbNko~BVncIhq)8kvzAwV|EhGZ zaGLwCjD(PD3YKI~Y?Y}Izd5mgG7@r`btpnu`JL&CEY3d~9CY31UAf$3gJgeYu_Ky# z0C$mMGC2eHUPy2>DD@vk(&6{RnNea`laIlDU%&>h5+MO!6|SE%S}XP-n>+Flv>FnO zm6^Q2+Rs|C=w9z>WnJPCuT+dEL;@R0KEP29dd$rFqtCrx>u*d?eXZ{|h(Yf4bz8_< z{Ndg<;UZclQ|nXo2{mZ;4$N!~Qk+W*;K>4?LP5*@#l}^xr@LUI*X2_8yDYErG+tw| zB1E=)XQas|#R*C!uYL0oxJMW5FDfUGL0Pbt;J~Q!;$L2X^v&kdfj-ITIFJe32nnJE_VY9-d-9qZd>>TA>$ zz+!}#_PVQ6i!AH>Q0kFe_Ml+0qT+wGL23q;3Kup|KFpf^$|=GWxP_{|Z9}AKONDF< zvD}_%(Y$s%Y=vew#gAjc?`jZ~Ty&}V_{_Df#@a=vgohfQwm=-{`|C=9H)iK~j19u` zqDG-+Lp-K0UYvl}FDMr*bjMM9F0)iRoewrar$m55y2s!8UCl@K8`P-4YCoEAtS4@o zF;&$&n0WESzq%-y&I=5gK3@n%335AekPhZ}e|8#&*lnx4b{U4DnZY4so3#*~6VVtA zxw;GhwRnj0H(xN*+VbNIkZ44XfGfr`e7#Kn3ywW$8J-l#&9r3uJd4XdYwGB}|Ct#W zGSN2Ecy(qL1w95mc3U%#31XmKc54l;?Em=oQ?*!?MI``H32*Qg4|b7h=S@|UZV#UY z?ewPt*ND)9veH8I;g%j!R?x5K#o_+2FIzKg22iv0;~hL?*FZW#6(6blMdp`&N{boc z?321DVKEyv))d@-?f23?jz>mM?F97mZ`nPsc~Qt>A2O#Ot5=HZTSC6KPdUVvm^8Vq zj2{py)Bf{qt&8JXsoHl6$4e*x$|XJ&|4wnZkTTe@2{2` zuT^V;?HE?HoPHEdtDE5mPKKH2f|S#LC;~iqp%1qc{wnDw3)Q(Sko?tM7)`CF_5IHV z9WQrs_1h|l3fb?`FZQ9ygpkIUg45f&J{?X`fn?n8MjWw_LYz=bB7}(CcwO>&GG+hD z8v}4(h9=&l`_CoIGLI{K8-H2oYQ^4bURh!Ge}4%NGabfZbM;3yJAHQw;N#tvFPAk9 z$Y&ORwsE;24)*u`qsspT+3jR|JCDf7N(udcn$ho>{pUv2Mx;jp(j3>qcX|xv>ye3h zIq%#%$?Ma_p=yVjK8X{W75qRN8`M#TP<>m`U~*d$K??B~eFl7j&DdmW$)RJOyD;)u ze)1U#7CX|6gF{E~imx%!$eDLl@Ni2i7`t!j2bwB%m91KT2q^gVkNhO#9Zkm_sb7*3 zG6hym{cUM5L|Pi^fVZ`gaKrY2vmbq!_{Va=wicOpY(j^N9@m>Vm7VHzwLluS9GEo& zupEIj*Wb-Q1I-NhL8`wkpSa|5`yI*g!l0bfV#)Ih`y{$9V-EHKc86+N#@iC?o6dJ$ z%19Fgg!Rw98BKE!O$yUsnFJ%*@Rs2TzL&*Q&;}uvJ5bl{=nG?4g_Sqrerl)_I=foJ zhY08^f zC3zj@lECiX_sH&L*D73xBmf(Z26ap&;oXC}4~Z=S!W+XHN|jC7Oz#>s0|_Db&Ml)U zfephqtImU+yq@hnK$xBj)C_Mo#v*@TVJ0P5Yto8+IV0xsv%%V<_xackZ>>N~MNH(<8@DZ+M{v3i=9%utp^Do2X5%OO5RGLylke#8nol4YfBAV5N_}o=+9rjp zs&r%_vIQo<5<)0@;NCjPOKdz{*^|!wT&11b@1le6R=`vDMG>}UN+@s9!N&g6pG!hp({4QhK z--{hTO5FZSp0oHFmF~uhopmj;Eii zW1h1G7!i*y)m0rkY} zzpsK^9VDd9^E|9nN<9#<1M}m*>Xl3|@UB#~Zz;Km+WzUOuTB$GGlgn2T*GxQk88%1 z*5PkGGNorD=)_KQ>4r>lAEsiu3vJ0!xGhT;fL4Wy>@vnuP=W%!;E zOkPkTt-1g&yc9{2WSNK@ww(N2)?Fleng+iq({$lnljj2&4 zCd)MgeFqi%jYbdcDDyAqy<*o2G=dcA$7<^bmavM=|7t}ZNOQqFO=1uQJ^~*m^VOJ< zTMx&k=gi7*(nUr#qj4)<{{wsCiZ(5RxHw7~b2#F#%W>juMe}s-SAEXfHL_vhI*?as zl2r$aJw?_<(ie6{MT668Xu{*^fYT`^7aN(42cvV24su9CLE`=Lv?Mrtr`?7@T;9Ea z;ab4+;UmQag@n>?OX2&n;PCgX>nBwiM=_657XosFR7o40zsjxJe|Yxa+F}MTI~i03 zt&Usg>{7%~4)&Q^8pgUJ* z@$x;2L%7Y<2sI~!$HWiwMTtG}R`|Iuzw^9Mt0W5{G#2Ok-k0fYu)++-)AeK?@vf); z)Rpmv1JR30hEnuX+2OV$C}+0uzET|Bn}928iz}e~cV;ZqfBu*dc;hlX%ili>q<(eu z64@E@?BVK?yRnyWQgK_DaBtkpIP?s?o3-xjNUxaxIdIp*(Q$$?v30eY_|ZPt-me3a z1fF{f=M^|?I%v2={Y&d&%DnBnoomarX!ppYRPDsXm}bP~-GJfOfNZt|A!ee!`PbKz zEo~n`&U3OWQ2Rmc0@Z|@zX??eH5gIti1CC1c-3bE0sp%s`zb;+P!Zfe9r(S*xkhC z2IMbnHfjk^Ed&oYZ-?bZg^md`-pLXX^zg0fYi<5IKzjGA2X6dZQU}5|ojVqJQ<>Vv zhbi9p&&zrzk&rtnyEiovO%pe^xCbvu$Rg9w*Ek}-Eusk%`K`})t@C7c#3S$_^MY@OSH0;cxdtX`WLp_b7K~>imAm8Hr57EGjd7Qu&OBQ|CdHl~? zS*%e&Xj}Z6$aQ?0ILwo4?nTH3Oew$koYraCjA5A^#cd(zJl}hoOC7f96o@#cRdM#u z$@dj`hOgh`gh2he6`uml=sq3@b^?D`5A62MAd1Vvs;PF(j&S}tyfxKIP1Ug3x$)GE z5aK%+gr5_Ai4n*LQ@crOPRG|Ms{@%Ura!gt{lzTm4LRzt=$cbhe?&2?i4TSRCc724&l%w*U2 zPd#xGn^DKQG%<~B77H3B3(TmeFS&&^qVF9bTvz+ zWO_;s(0oXd4dA;Ec9x9UXpHaRjy+>!F$qJ=_Zx5yJ_y{NMO--vH9M2I*tcR(oqvHt zI`pplsP=l*G-EqoXBg)sz9g7G-wl-sx@MH=BNKlJ%GLFDk2A@nn=4+1sXeA~U%;I* z6od&{*Qr19IwZR=FO1piUdTV%gbqx-kdk>p1KKdzhjee`0ZwB9-CoSL9?`5>*qA{kI4ZLW=RgA-q{RfvVTL`k-;=hUD@}EoknjAnWK0>7Ti;AA;ICxuG$rFU22w7LnhTT9!w4LYwkeX-t`thwW zyD~BoxI@7Eg>hG>v^Qesj_=UlPc^ff#;A1$?>;o>W$j0PSPoqZ9vqYJk#0qg5&ui5 z*t?&{?PF!^>Y5dwzT5w;vFLKxEhu<3FG#**OE#fdjDo_ptYo&>60(mn#=`Z28W1N2 zpNH+2ErEpZ2h_$fuvSOS0z_We5*tAGpNHVXYlxl<-u3g+WxA0HlJSWKfph~%ITq8u z`ML+c*ag?zA9i?LUjzh;7?yHZ8yG})*o9fTm6sz9wbx4nfYJT^g>eWL84wMu(fa1K z_)Z?5`wxXMv(1RM`^(*D9;YE$U zHq3`^q%cssW@t|coUh&b6e&zWNSmKnP`>00z- zK*dTuRKdj(nFG1&OM(!XU_Y7IFkn2t)q4u<{H)&B8(f&;^@}(4aBKsqUnqa zcWYko^$zCoMlK88spsiM)4gA7GRW;hJ&(`rA;QE>|3Kaq9P**;{-U1?At8td=%w;l zB>{^C&Gr!eN7M>E%9Ci0r7E#VQTo5?>(Uk{+JQzSyf=IMeWWqJ{{QOjEu*Sh-}Y@3 z5CjD2ZjkP7k(3lkMY>C*L1IZa2&fyszs#j#Fckm>_s)fP}WKHGMZ7gkMKoN!gQMt!OdUm%;Wa2rVAcd@GeETN{FS zu=^}I06@S`O*)(E++ZmTD#-g}Rh$SU-fkY@Oo_S-M4DtqCkXum8&EuD@03AV+pyi^->I~8pHi(oxjhrqb7Oi zJFM-AlHHol-9`g;S7#579frZYkSsSciUph^tZ>rsTg2#t9k>$157H!I%i7i}1x2DO zK)B&((T{|L3C!J?5005gNFiEM`r?%sS#Nj{?7*WpYQQPoB62pl?#Uv&YI1i$FLXI~ z8KjgvtBr?ivW$o2BbhKiLn`4CC{Jd(qc^?$(}J*nlJ`~O?KJ;o@_w}_$e()MBx~7` z)UTQoJ4NDl{IJ!8 z=tB4C#g-*8qDGB*#*bJ2?=_nD&(#YqG2wu9(2p-x@foL>d&vw#4CAIRGGYt)ZH@js(g z|NURvqy8-v20(Y-0SYO<4~12zvBhA-HwCPO7{zRdcSgL?3H5XO5*MrBwxLg4LiyKx zc#!^|{sL_S8T;$s=fn0$-gMpg|F7wJ5a*juH2hKIL}H1@m`}Ml-c&7nmR8&;T>mP= za$XOOoRfaNXuasRI&O7Ak)T~%QH=xr{%_~QhBwi*-~c_*@{Mi0zCvsQSpwky$BYep zhwwdAphl5nZiuxmhx7<3@AGel$#qiyfK1lI z&2le(X`}}&=qXB*YZM#kK!zwSQXF*I(s(uXdw%KNE3?O0>Rs#8gKViO*CVOwwDYd@ zLLtNjs>?-?;_oU(?DHSNA$jPFyipr#eI0w#jJFwN*p=ZWq8~Djo%e&a@??NnkJRLk zbk)S>uc-f+)Xr*vPa|BT&vC73uDIw5Qrm+ve2J2iaL^!nSwCQe&>{hV5R)!I`UB*~ zJ66mAEho#z!3tUm`Fwt-Tka3N*Gem9`n9>ZeGbpHr{vldKl##E5OI&w<3yP&W`>=l6h)8}#|!$7$}x6KZb`MwOdJWy>1>=FJt_u9FwtnhU$WOI zNr={{hRh0*e#1!F6xf6y(g0??>8;zS^s8g4JEp~Qc?l6cyJy6=aZhj4xUHpk)kbL4TJ>_+w;+4tg zj(JG&S7Do;qRZ)d_huuJ*X+phv!H#mJSYsG_bsI-ykU-6B#vs#4dnzkqffW%xg{@XgAFYfY)+MggHA zSc@!*Z)#4$ftW22upI`JcJWOx-dT6DF)LImkNg=Qi?{@bba`~ntb;L7O59^=4s@%P zyG#n!6T=6g))4$sZPTOt!3P6mtp$bfEg$B^D#9DJwu!qMRSE~DE(WLOBhf{Fgz@|5 zpO%^(@K<9hAN9OE$$HPLc+FZoT%rDj63t`wz;x$!7YM=H5kQ^PeR))(RswHTG*YeC zh9eYK#Q}K~1Ju(=UB{n1illDcn_qWyjZ@{WdQQQu)*!?OFT*|}Jn#{gr!reCu)aJY z6;J#&A^lKN3;_6Eist4SzbG5IO==yBA(2DBvk-OPZgeU5k%(B%G(Yut5FQRZnFxTF zwk5fPM}~pVvC!?1AD+-|nf9RDth*__i1%IL*tFn#wrN5$dnDh$cIMZtzO|ZS2q)D- z{z=_)X7n0Q@s22v8W@>k3=T?ydtjsDY~;*Yi5~yZIo_?n!WMb#xGgS*llQ82*e2;q zxtmVD4>hOl%eA9)RT@2-!u?Z}T47RJ=gvyILpM2I7O`6%J*HznN0n3K5U8<$;7(n553}(sVBhnCe#_dB-e=`40?m$28zT9# z57azox5!Vf*0A(N9&ilUSE4m&#|CvLGaT$4JG&UOXXrLBxD<9X z+8~m|vtLd4mWX^Yvb(qfeB3*O=+V24F4Q)=qbY$oRPbf@IPi3jqWMSs*^t+H0K|cdm{x5`|?sr$wcP#yX_)pPm z=l zywWgN)LiJfmRub7jZKBS;;ysBP#rQyC$|nBFtB>o0p6kFy;JeK+3Dfl<0I>Od#QcX z1>z1TjNwh|X@Bfw^pTG=w=S+T?tMGLT+)B?>nPRTH19zZ%XQGrMG_tP9WiHFczAq? zJQ+|-9T`Q%t&0cG1snd~Sc^)KcRm(zVpYxA3=U*zCjX=(DIv-J{a8M`>p>jxJmy&p zD=FUkOIm3yPd;Rxl#gmOrgTUsB`Lg*9$n8YJ~$X5yLJ3K_g~N{-yN6JM%>@~{{|ph z+0n292182%-No-ovG(zT4sRJi)?V`7Q>}ELMa82k*_^1Lt19|x(3;GtO$btcsYq>4 zMxq!bDy#E$<{4h%#RT)doe-EJ#*yF{k)-EIe8ngL_ItXW7fwz%#E+!>rBTLzy6@UBo2cTyzHB|!=wQ{MNgv{09eo76oC=? z)4ZjqPF9c>$<@dBehD6@d381-O7829n<-`O5K3bOD3L68^jnvj?xp2wgt$ZXTIYsp z=jC)ZyeD?ZoI5CYP7~a_KI9^{uz^3`J-$I5i#F4EAoSkQ4N}MGR=Um_J1Km%loLag zsrpf$>J7vdXTl0Ul4iw3w-6TwZn9D{(vToF{lQdNUi$tTkoviDH(tI0iKx?OBsX4n zoL83gP5bVCDW?vuc{bMN8X)3|u~WPg*Uj2N=m{3GN2^3ijuv6t3?Lzp6A z!)DB3_Xmv_TfC%dKeFair^SPjKpVl%BbkTzJv`Q;sIjxDM@iC4B!SHX_vhxL>vme` zXfV;2F#t|vQTMxNM?dbnl+dnOi$hYs@f|`}i6O^8TWk>1gN4{U`+=hT8yO$VxmC}E zf7!w+pfBlrdr26!`HcVc>PY$aUX~EfCr}?vkuoF|5j~TV;;QfLT{I}wDl*Nz;Zg=m29abLpT1$ehs{JW1s_|SyPaWx%Yj1BdA8aOr zRC|;xPdKl~DTJu+TT2UQ_$qjM&K%k5s^1ZZ%6-%>#;A#Y*eG-`)l#mL!kL!UA+db{ zwE4&trUk_+=bzW!v`4h0DCx}Mc(q8X)2ikPyNat1^_w^CF6WtX74cc*XKY?AEUB+w zcBe?r^s9T3hT6jEcsZ~6FT9=`w@yM%D;i5ZMb??HXfwvYYKHh@CjX$n^;+JrswwxW z%ZYyG^`cmV2XNvKa3`kXb~*lbXRFP%GFg)e;cMo7 zcPc%GJ$Xf5t~gUD*ZXWV(B@?ml(V}=*}z!nh2IM?UZydNjQzQzv@o#D4t!{?cMmO` z-t=I~>+ql+A>%E|`+$`L*PBj>_;34Mlh`sacafOJ;d0y%K7KHG`+R#y_B^86idZdM z1|9oTMX`WDL1~t_ZBvBZHHy3JK_#4v{C9nrrSA2amlpnzBEB9}tWaLZ9L)sWhqiAl zpA#=*IhHl_LsoTIP8;=xo|n*`IuZyEd5Di`itfckvo+h#C{S<)!!UmS5GHYbBY-(s zzk-7cLG{Vtaf`YcLFnkoo@96!gjQBF{QV}#b5bVzaTvfHYB8Tx&?XnsB3@@tdRNPM zHS#C*pFnn(zU?(({?u%`^Q;a-#Of&QA&sNI`gkr=rHQD9oKDeo*1EaLYv&sk2;Te%_0=H&n|}7kEQw zP^^obSCS?=6PzG0^5zr4u6acwfX`2zjxo9j@}6p}!#lkrSfv!0e7?$NqPOC!1$6;$ z7n9T`n_1WC&o>I8M@(FxR&EZrfR}MA>NpP<) zhq}$mii@8BuR`5?rr)6RONdjxTf};6C_2f4?^)ZOA*%EPH9|}78yV~Rn%RjM6U3zw z>Xa@cvKq>3LqNfU>RIF#g3ZQuKb442smi_QN^qHb{`e?BfDph2y7B)5hCcpSR{3fd zg^RTXPz?Z6H}dHw_(bEHp{d}gF#NM*1A^06JT67SO+IOEsfqSWjaNu60+h8;!K}_SO6?)90X6G zfQI5c^f{+M+puQ-(W=Cd1Ki_coz0^l-4U}nN@wZO;1^sB+r1rvM1y$u0t5DHzb+&L z6!;RnX*&58p7&Tx&>H6mB?ka6v3H!h3qM-f*quTztQH z^iONXE3-EaXWoBk)~#)4>iWomxbAu&nh2&KYB{2yndf<73UD!_hc6hPC7z#@a)>l+D z)Y1Jk+xwD`o58({6qXoK%P%HyG-I_KsVqt6P9D z9YL#f)7*_Z8)Z4JlnkNWM)~X>m3_Flfd$>p&S%}@*%wiP0rr8wqr{H&o1a)bzx{8K zEJTBzR`Yo}?lcPNVU_LEEVaupiiB?P4J4chHcZD$=n1yMFOEIeS5w}gET0}*7!u-s zL=k|p9e3-#+wQ!oXoJ=@d0;SE^OZBX#|x+Pyx@8xw&hivWVd zdv>R<21?(4i@qqV!S3C??y#n-nGY9-wDw8=&A6)z_yHQfalHS>9Ee0(6QU@gt8pZSyDzvKu8*3jY3NTu+r8@8fs9J5@ z-!D9(xm&S9{cuSQr-3Cv!ldu6U4SYv!J$hcb$SXZfs?o7E2V6UcFj1O*$mLwk^l* zCEzIa4)FVY;CgJ{k7v~6Z|;@yCqd7mMMUGlgX7y@q{SnLKZhCSWp(4{>OaMRyr?O2 z0|&8}ZO9{0a`(jPRQo#u+7~SVB*DDd5l`5I_MxWZbez*fy@*L}`gPzEY~K%H+xEA9 z1=_)gk%(&l<>UK%jGs@WmJ%3M{EkuQ+rN@=aza%y`I|Mwz~kKViHZ1g&0nbZ>z3cC zcjgk@Ixd$cV;{8mXLQwa6j>urI7P658HM}9;=PNwf9G-Y;8U33)N1(Pmzam*;!nTK z68c~NpAW~sT*mkOoKaSWkwU32DxjhXfiux1=HJ;Z!k}AR4Yg2Lgxrb2>yq;Rb&3a4 zEu#o;t)aZ)k9^Cq0Yh$;kPGj_PthipkBW0ocf|lVcmOanUz|$ADG5OmHEX^)^!BZ) zII9dhN8^q}2@Q{=a}4ed2eMw&yAe&RykX9?l3=U-oya2ntc2G-p^@0CYS%%6i^3wY zbN*YekdWAebYDUOX77mGAODXo`W=r&D33n=WePv`$0>Z;tIN@-nD5c3=MPiMf0iXl zQ#cPJ59ppu)`*qR#}CvD9MkcVjNyoalR++otcRcHrE{~E6EPeGHssfWQRT5!u;1w) zc5^SOaFOPEE-uCWNNt@8{c5W@mHz!G0=m7)f3-45N81(}Nm5dxA80>E;ND;o5_*xIOkv`r zGPky9Dk}L*ogDlc4C8yB_L?vR4zS1&0~VQpvOYYv21$wvTl@({8PPx|nh>`$;gFC? zZ>LvtwSP6<4rV6bsn`#uTEo(+&S`N97Kz=q~LUDFFPW{mqB?2)< z4IPFn9lat{uCe{q`D?+MU{tB&AjMP-s#q2(q5Jp7=ANQiGW4cN^{`kf_21b0<8rE5lK5 zu#Vhxb0IVI9pA~~QtAqAQoV70ZN>n;z|S{{MpC3-HF>x#iv{jH9pQ$VwVwOP`Je{d zqNOpy?P}6`J7S#K{Rf(Q(|f|`-4X_@)ENynR%ZX{{w^lR^qV8yMBJw+c*?OO$gKT@ zU&x#4^K(;acB$$p2Q5I1?&> zoQd{OE5`|xx90GaCQPy7e&T!1U+sE9gN+27W839|BG3MPDUbd#eE93Zo$gj)E+*jP zkO&TpkH}vloFome?js!@9nkB~z%q_v(?WKe7kz!cT7nn#=alEXM=n)dpRUdJn8Bc#@GWKMm2>oOmr^J3m`5xN1WewW;Lds2kiB_6<5iu?}}8vDjPm|Ak+oU zzCQ1Iip_c0;dV#Q$QB^qw?_qjTuKef$u>?s-T~X_*xGSvrW;zJ#}+#mJ$z}}z`q8f z;}OjN7g+}qU}CWSs6{L01 z>HoYgzr;y}UaDP+4RtrU#=btiBy!*pg8wF%r)J^?vf!gEr+X1KD_T{h$y0q0PC%*l zqGBa6sCoZTN1qoMJAL-9djaG#{vXUK!9k`HNZ`{70;T(0V-!51!MZGSR@%XnLG%*O z$Gl%MsMR@FUqi#EaIVnE9pFq!=hk3)Rp|XL6QX4f1yDR@jEi~4UjV95^Q7~e9;3=$ zny#Tux~}Ywsq112&5o9KS#}>rXj{Xen4X2H!VGr_=s`N6$29^_YOl=T{pgVz*>w>h z3nB3(3n3^LE)I!@_tl;U?o} zfkm#Q{r%0f*#>py0l@aEg~}eVL}gOE1@zancTj%RJ{O*NI&0OYz|>MlI@!>Nzu|ko zy$`80oG5_s%zPtL)riu?6&0mDmQvbgEcuRVQ&gueZ+R$V>LS|jJ{}#I0$x$AoSH^R`NqW$Xub}3lfe1mTHpI}_XLkmC3L#gNYN(c zIWtJG&Bmn1(k78VYo~mmKZo=1iTel5?t%z(l6L+Six+?@c-LHbKlc^c;yvtGConOw zSJf2p5UTs>p~Qz&_6${?fx$>aO01~sLCJk*ct(dOi{^l!y4&bNpuC&Rmdwv-04FIJ z|12onME4~hQc41G044MU#v-f?s=`)WhD|9o7N(E{+3KQKDiVR0H35Z>V;4_~t$<+t z#yQ~F&>^hD;mNv(z~HwUwY-=#$JRs9Z04rDwd$_Wd*9{NeA5o3cX3?NtK-Kc%IfEK z#R(T5G=Nt7vaFo)2R?U~0oDIK4D<*1+R*^?oF%N5AuEeaqKd6GIH!)Q$(`%dWJUUX zmVfL)li;#)Yb}lsJM*Djqt1!y)MxdY#$2`QGKhAdC|&>zkuNc1F39O-Vu;rKZdSYXY~LH&%qf09Shpc%`>{;uHEsrTq(cdgrus zL>DNx8dX&pUGGxKe-y{_+X7tj4S1jcH+^Hp5BZ-RwqRFZciQy27X75dWqW`2&h!L0~Lywx5# zQt+nDfVkrpP|!2lJ=n2iDeh@xb4@>R@VVZP6x?*RA6?o)Ed95GRw8UEd9R-%&}5-Y zBhc?AZ;jCb<;??INQn{jS?LERsfY#oBZ99g_(J@q_2y(;=I3>2qMk@dJgH>8mY!-6 zUYpvUt}y{ENU%Vu+!xX3JBDu|Fm)xH{Yy}6zmkpBFVv2W<8${FL{ND)BGkj_dcj(l-+J<= zg_9%dZyI0m>|=@{wCPeI>ayZN4U`fZ1CtTqIYY}9Zj)J>1D2FPs8ZWgmg{^ZJbHTu zhq@YW1QQP!>01hb-S9TxLmC8pNL)HZ&@Kebh@nlg39VPK0?eVej>#V{5eG18`5jIu zir&4Avf+})Fh}$VOMd6hXXbTuL%QaQ`%2Y)1eC@@(&FmO4X1aL-8U8Rj*r~&@M{n@ z8Cz{!Adj-0&aT+eg|h%>b0Baw6QPhZb@jaoCsLAR_wgrBqriQjp7)MQb-l3)w2^h( z5isyyuDX;qsxc1%i3C2Ha zYr3f9m1yGno-Ug?vTNMdp}0&`n7U}@G1-xgJnG6!5BVsd(@Y47q*{E}?=9zPqyG_QGGjtxShMS=NuSj~n;i7dAW=@$0kJX;3#adEsJl zYJH)wN$l&Jch7i=0R=n zE0P#4?cJ(7piJ&WN^YqNVM|pWt>6be6|Mn*@CZ?HlY2KY4Da0ad?1eZ&0*>i>T|#D zPq!=a_pLv(`FF#7jDQBZK%jw+H8aPr|1)Ww2gyAw_@M6UStqw6NyjmrGrSvNR)%<3 z`DjhsqC`9^K@?;srOTlLnEL1olq1^~p+_;V@^BZDhvK~wf5z!YT{)KnE?R&;b$IR0 zDj$gHyZ=j@x>$q;WA^eTMac;{)fj2&$ZQ1htPx9dQUk_A`ykOg=^BzctuDU$%qukY zP0sj421{vMK?iYPm%m_*N`BDeL>&qWVxYEdNlu0}_V{H=TCH~BnvPnbTj&!xZ|mQU zb<>aMz`y3l`u$Rl(=|@^H+nP7UKJ(gr;fVg9rUP#;G};{5GG~ml#_g!`Rws`5r%^N z8g->8{HqL?i!})d+$wUb0pi}MmVNJ+J*iPodfa2cCW~X5z>EjJo@i75J=;6Xm zm4)@&E97j{;eJW4KIpdY&{Cm#kXVNn)G>Cn1N^W;F)-&Uckuw$e9{+eaOvO$8~neo zEe9-|$xyx6xjlofo$%-W;9S%mYcxZYX2x=Cu&# z9SJ!CV*k8Vh?Dk)9Kgmc8URM3ZK3W*dc4#XM8JRS@Xg-Y{QyvW7}$cY6FTA4Vx6*T z2dFpgkf%lZFo;^%Ba^tUn~nAMW4dy$iIzL+ovO}|)J-<~=}r1gDy4GCC34A&E^g-r z;}-oxZtf_@*@|FwIvL(_E37F`6E@;dmOiKtdDP$7($f=@^tRkQz1v==bzbq&rz#kW zi#Iv>J0i!pmaQd8Nqi(8Ew+w&4Po~mfli+^`r{Z_jF4;C7?DJSux{+1b#qcCx17N% zI?{<1I5XKC?$6o^f^xaR9%cDDU=QGKZOWT}z#k!NTbNc+yuNR%$X-!})`kQkU<)eg$eW-a$# zfYF0%v^*z2|160+bYB_Q?wBlDBi%YEnx}n1!8&u?(!I7wb!Oq+RGxcT@fox}SKEQd zeWGA*wTvJkjJO&WM{T_MX(h3fb6%=fnjO0%5YickY%1nKe0C6MlThf%mIa(QX` z*Oxhw3qL$sZRNT1+r>V56u?Z2zNz^&2q+!W9e5s!JQmDkPCLTA>tD)*P}6pd!Em4+ z@A&3bn@;|whI&!RO_uql9Mb5pk`zhdV5Jpx=fz5M6z3ECMr=3W+!_h)K%-9T&9$B? zWO{YdS(7&5Qo0P==$Gi<>ho?da+_4|Mbw-ELvYFxjuQ$!nap&PDA=#Rzhnv44ri&{M ziR{Lqnl_!)uw6=fH5cNiaL3yA0pFONV^j?kxAUVEu*W01Gmf|=lrMhz5q6@qqZ`N{ zz@9u12rPSBjb2?}x;oVhe!8!!Oaw=LodGtVlE(<0nCHD!HoIxAT@7|T;DlJ8cj=S5 zhYqFF2}wM)u=HO_iX|i{%qB=Qf(G=OkvnIGO%j{t4%PW5`yO={Ne19^V|2gF-1dkZ z+OXb@!0sWXoYj0Z)U@->KTi$#=bwEF_)_G=^s!W1=H;Dwhr!qP-22=T=u1%mDnMgv zBF=d~v@?J71CL*me}%hSWImRrh%4#jBDa+EvA)|@6Sp**&62KQzXzbuA82!iX8|9O zo(&v1hOFUkSn5PI9)(@(7m9)Xf??I(;qk{{yfD|q7ZD_w$gH8 zXo1Mr<{cgVPsp9K<kR3y&^4F7*PL}t?<9?0m-PrBe2PFJt3Fj79kn%3I&4a` zwmuM-P1TXRdd?%6H3TvN`W&hcC?Y3LQQ?^|o)6_pc!z-Gp%+bqXdRFmJ|4nQuj(;W zWViDtDfGTva9x=; zo#bHm(a)=DIgQ7%xk8|am+4O_S5$moH6sTJQ0#Ee4 z-4b2Rh1*3oyW<1<5HSg;CvZoYK{LLb2|ZtY`>7vwYz?###6)viqqSF)U3tE^>MuLE zv)b|!sJmD3Hz1(;+ODXg67jo&fg$G2;CH*Lf+MAOdJ8OxZn7|zoWK5fSarkdA-(kY zqO)oQ5SmO|NspFWP2zk<YK+bG-89bECd4+hM$tfU#e7Wl=xi{4;%D#rkNIh+%_Sc;eI2 znh@YeC?&S8otR5{p`=wJ4&!MI`BU$~8Ig5ZwD)CVcuz*IlAt@yignIjs!67bE^yTF zSViY6AuJ3K!cWGGNLBl)!ub*)IEzfcZK3M8ud3@4*anaL9n&XpydPQ#Df+4MO`!#& z5VmQ8zK!MG5U1 z`W%+=iT;o@Za|EdpTyfy>Dr5PkDD&H(Dp(eU(4-@r&S#nfDW9=Yi!+>mzU$X+&Z~X z)tu+S95&gV8j}OIF%>ELI2=;+OarCb9oaZX_#AURlF_SJZJCJq_)ha-WTHsU$e=m9 zeEgf4A@zo8+ko?n6zeF@$1r=OLz1NE5fIp;ZxeL3KZ|tHU}U27?P62a=uE-;@mWvu zCx*jDu0XR>)*F?JRbIH-&R04`MDU?<%%V|gC0kB{2HEf*KNXTOrm~E{#pv!>dwV#I zdyB@yDkk2->=pY;vfNg}qHP|5jG~b<)F36rTT5Ax!vCza99c~_+`dCUQHCuAFX<;$ zNZ6g;G&~psTvKL@2GPi;A*_5OxFWXk7BTN6!!}{uP&-3519gYb)n%ocG;*vuO`n^e zq{KAVgg(|mm_LH0q~Smq=t3>)KD?^4@F*-?!0<~=M1J+mkMeM?y31F!vq=Z^yFj6b8fvfdip1;XTR*{c9~wkQGTAW zut1m_JnQ5EleQ`yVyf=-a(6+u!>Mw5(24WJpU!~*eU^~epH_zr47O@KIw=zY11@Hp zZt$1(Ow(?DX`ncDeA*~5=)*{KxJ!RoXCtI&hcfhk-&>XJ_AwYorWwgX>h z=M>-$HE7ULucEQyV{wOke7qo2XXlHJ?( zjh-zYA0MXp-gV$;uD@~_Yb|qaSAm{jav!*$cuO9NZ{Uhh4z}mIMLY@#cUAdOjDef> zQN!Pbq3{j1$gfVQPRv9k#n$w6#ERnyiql}8jfiow_a46T)M0fFrPgX#Sed4MJ9$S; z8PtQ=u;9U2X$bmZM~$1)93`>+VN6~azS!YkKQ>7A<@8{WQ*cn#(By1#* z8)>VrzQ@}m0k^}|UObMcHxCqaLPAC?wtiG&$m+Wd0`G+w%-hGXxa$^|ZU|Yn4U|IVcNZzB*sg?E3F6(V#CI|K%<5_sra2k0V(Uh9u5%_t(eh>mnp3ZQ9({D8 z1i(Lo;hz;Ru9zThp8yEWT?mi}a>7FWn8D3b>y+X~6mWJ!=&-OOA z=hauoAhB4(lY|x)QC6~o zPPDVaH$seC_8dH+@AI$#=m4tytgj7e2y$E0b4g}qwWa_6tjYse9KHEXE#?i0s93!z zXtlTc<|^E*L{VmIU75p}o%8wTrv6BgnX{7&#R#Edamr7=_)OhD*YPx(ALzCB;i@-h~*#5pjSLFmJ@jQCUoLkV|dcquNZL@*|CH89sR5N^=`UF>d9md z@C%G%Arx_QDDxLf-G7&0xlP&}9hUbUTq2+^-H5cLrqoXN!x9lw<0XZ?{EMok9~5GU zthY7TgkE_G6xIUoGWOTjKR$I6&c>KctU)(ZHqm3Kn5o0%*NfJec2Xr>5GW@7ld7=+h%5WL^4Do{*EfjOYvn?2 zP!f&4w60s+Y-^eLP2FY-vp7sq(6iLLp4vd!R`kF1axErPV#vZKy=;{nau0yWhe~-P%8JAyzVk-zn=O+AkD2Sz+r|$zCg_ z+79m?4KdV;Bk-n$IxZ{7EVWWGucf*&NdL zZRJ79PNt6lrQK}R0sA`?8&H`sk2tY;bg&hvPSu|H4%O)KJ+$8lJ(@t9E=LXCKFP|? zd-60fK)MvzF|It3Gmx5KLqBZvt=HiT^QUq0U7Lp0d5?h!>>4(tK0nv9L$_?~bGU26 zRpC=AdK%{PkzvBKD#Om5w}qMBgTAPcK2_4ko;0v>M&NB=`U1E2qQi4g=5Ved*X)yY z{N~%iF`r7lC~Oo}Y{!wb{?V#6AFHAKfpjIk%w&8UKGKob=}GIl?885{Y@L6m>frHk zpbNco6URd+_Bf4poDy;y253>n|MF^SZt!PUBv8=P@8^iPD(sFaKxxp;0~R51O&2LB z&2Gq0rTfS_c*zxs6Jt2Zi$d6gV>GGIfG`>!;7S)jvdi8a({+0-?-FKYB2%`vw~*{! z_a%9po_^gzQlv2~-bb(0slMXDDDxDo>>`N>!tY&?_+x;u(|meR0zF>ho05i2V(q(< z2I)PGbR?49f+XXSGyTNTpv>IKLG5|q__XSwMW~?&9Gr852;gEe&?-pdm3fY>*!f_xz$w+2l{Y3q;2R9`pO$ra=J7q5OAqgyM$%i3M*7x| z$ff-{hkcV6q$3+1??C*X;n%V9z_+n7cH5AkHFqpEYF&!5WUaD*U-Dk4#+yjk{j2n; zxZ_~NoXeCmFr}Wsi}t8KEizwr8NEmag^*rWKz?hvT9Lo#>-_(rBKm*lFf5-waia#d zfu-8EY&~gXd5dDy+0BXjqN0-MSv{o2tU$3P&Hp4#oCILQ z0x_R{ukFadEW(1nHmXF#oa58~(5~{yPbYVa1v1dRh{AkF9nHh25;Kfwl56GI`ehA2_IB5hneS z9wM*Lz9LF&EjHNIaI_p1&Su?oZH{~0TZv6_ZNwf%>U}eS_$1p@pR3#a9S8m*P;A~3 zSa9E?!$~EQG|eRs*oKUkS3ByXbaHq^s`>4;Yd-g0D5LYB#i)=<&M(GtIX22Wv-#92 zEhFC{rDq#6YuvV)Ivz5aY$ppU9`7Wt;Siexv(`0+PL&qvdoMKRnW1l zGLEzs)$a0tF?;j|9%O*TM(XJ8kx;NA*nWGy3cLjxVe}jUHka~M`+L60)E`;Ox_|_ zO!oFB**jJf@FYwrW%-RJ66ur8{LCr`qNxhs*{jYTriehQV#+rNrI7`%QI ztE5{pguTQ`Ds!YKeeBEpj~%p!RCbYqNT0Gz=T}Gb#_cNezMASxh=8yiUGP+9#)sy{ zFB&_A&6?DQ7FVmw;#QV|sVcdCJ%J6biBL$0zq9_bGtLOb|I^Yq-fZsVj|31r{z65u z(097G_iEG{p}(HkNb=gK*^%xkx(y3_w}Eyu9wtEm@nvyyTP&F~-RNiGoRi!jXy9q< zhvxgg0KDZbox|F{C4V@|FoD!f{pEZx#ch|bGZdN9JImK2-_^e6c!o}3$JY4+=952o+7J(Orm`IpwtGX?S>4X=6_u>j^K4f6f;zO7F@Z>` z^dVrn;E%!xG4`0JrOz8=JdN&W)PcL(bML=#2y1DWVltYE7|55NvaY>P$78ymB;+ov zo$#8GKJpj($7M!&n~sl*l*~3lo;n+{&V_p({q7gDnIv`4LGFdx4A=2|(WMz}09J!@ zok=6>O&JYE#lROBcmMw<826fT50i5AwsX!bv)s9x07^dE>}y9&w*BDvJQ)lEFM!^8 z`yo*xyq;xi1$1ApveuD{4^OCNBHWYM+a_MgOD+F8Y0be6kJA34i_0m`Q(S|EK6u_V zZn;FQgS*OIE@xOFm95B;yd>?f!r(#YFs)M5fO&dgfI18f*d+S`DNQY)e(|BC?^{lT zE0*`V=qd21U*qc^Q;bFtQVO;qAHVi>xcce_cigppN1JT=Uku6IoI_bNgQ{)T-}jt4 zuzp-sYmrSJHGHopm!yAJ+K0_C(4{=e8h3P7>aEn(;d zqbl8rb|Hbm`^+s;aJ>qYq;+B=+V8R+1SUEzOqVrZ*!`o!E@aUH1tf`znT5{=TCn#*a3f^xmZCEKfL=v|cyv@8zQ4O_MY=ri0b|}kb#vcO0|$E1f8hirqtDqt zRFn|oJ3QiT`S@1}21SMRSIz6%pEa+h`0SRwsfln(iF~U z_BdB$^2qe}z^Zt30Jd@u>A!*1hkt`rvf2&JU65WehToZ)THGF>C2TuRKPuiEg4d}u zy9?M?E5`lxSmc{bBM8?2N|F?lJ_1g&@%6-~&Kw?(Ca*Y6LfI?g#1SAMfkPa9b%$D; zqnge(Lw(WF*V69@46ZhD;!BN;ba@FQ(#w;l=Hm!-;Usn4kxjaXZq5&HCWgGte3VRv zx4rQU{bc}c1Y9l}xjCzTTT{sOpu;rGMcWdCDhZ+PS?bsD$6%M&g$E;Vnq2rq4)_7P zTw5%InqmKLdr8>l=5FhdUHNPQ)Wp86SqNq_CnGnvvlJNyM!5r983rbZOzsK{trsgi z%v;2IESP5$i2vo^zOx|F8kKnw$Ol=_J6;!irg(VOu>q=tZ(LnMAQ zZh5wnqiP#6=CL}060VvUr#aZm0eu6S8!J~_SoyrsHh^OXw$dpAS8TMMc^dIKHFLOB z@iFX%t+YBdI~k5MG1zS`L{u+2wF`6A5b_Ek8#@{q4q^@;4Qwxy;(r3=j6Tm_sm&#Y zd8TMl{!&NXf6>GQZLXzV%61(TZM3zcI_$7EgYw44l7OjXqjHg{BNxP;;Qv_D{a$iW z^}g!zn$_GeAxk@y`BB2lxTkg_Gs^6R8HW(8={f3P_C-L5?Y8B`SmUA0Z$g9v1Cy$- z%8*K2XgkK%Iv_A;{COk4&ssRbKT-Qdlrd>E0G|t-%4Jt98ns$0d^&1SH`#yH-RgNz zU$l#0vX}_sqn2`XW33@^r{_6ejTIbF7%C|S^UqdtoAeU4w^FaSmM{r$RJ^6BCTqqL!DR9WC9B%p1&q|hk5{(e}652fOXHgP|8ppOPO2%SFu@FSfl7@4#uZHXv z&g{_>&vqJ{wwL4W5BN*~=gehd1BCz%&haY8_*~ zHs$UaS~N{b+4eY>CpnhpXgJh*vCC3MZ=oF@r3@-3^CvD6*c*K?i5m~G)%IZGTk!Ga zd-{~J*ZANAs3hAB=2?0lzZ{KUp}PsY({$@=J8|`ja6xhr=(N*r&+h2%hRI@>aJ1`V z?KmM3eg>0x=c76ow?6d;I>@T$Pe~p+sFxg^QGhC+xV$>|5M3FRx(ZX0 z)RlbKiXV1{0f=4CRoHdsshq**ZFNSnjbLdn(3V<)AyeCp$RU zJQ{u@_wy&&f%Ws6oJ!jn(rdkgTXJf^S9yPbf1fy#OKniKBGn-^_H1=yy|YK;oLefl zh8=gZpC5b$hBps&eDqnxiEYOeY2j7?{r=IY%kt|}j=fssWGoonAff{Gi_c3i0?iee zdvJP4Ft^ct=wM(ZZl=P(V2Q?D{a^phX`#3l1BxOYR^Ss019MkGK|JS Date: Tue, 17 Mar 2026 11:58:37 +0100 Subject: [PATCH 587/887] Added test for including context when it only contains skipped tests --- test/ut3_user/reporters/test_tap_reporter.pkb | 28 +++++++++++++++++++ test/ut3_user/reporters/test_tap_reporter.pks | 3 ++ 2 files changed, 31 insertions(+) diff --git a/test/ut3_user/reporters/test_tap_reporter.pkb b/test/ut3_user/reporters/test_tap_reporter.pkb index ed10a5aaf..786c53ee0 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pkb +++ b/test/ut3_user/reporters/test_tap_reporter.pkb @@ -20,6 +20,14 @@ create or replace package body test_tap_reporter as --%test(Escaped Comments) procedure escaped_comments; + + --%context(Some context) + + --%test(Another disabled test) + --%disabled + procedure another_disabled_test; + + --%endcontext end test_tap_escaping; ]'; @@ -42,6 +50,11 @@ create or replace package body test_tap_reporter as dbms_output.put_line('This \ and # should not be escaped, and this not as well!!!'); ut.expect(1).to_equal(1); end escaped_comments; + + procedure another_disabled_test as + begin + ut.expect(10).to_equal(1); + end; end test_tap_escaping; ]'; @@ -217,6 +230,21 @@ create or replace package body test_tap_reporter as end suitepath_as_chopped_subtests; + procedure include_context_with_skipped_tests as + l_output_data ut3_develop.ut_varchar2_list; + l_expected varchar2(32767); + begin + l_expected := q'[%# Subtest: Some context%]'; + + select * + bulk collect into l_output_data + from table(ut3_develop.ut.run('test_tap_escaping.another_disabled_test',ut3_develop.ut_tap_reporter())); + + ut.expect(ut3_tester_helper.main_helper.table_to_clob(l_output_data)).to_be_like(l_expected); + + end include_context_with_skipped_tests; + + procedure drop_help_tests as pragma autonomous_transaction; begin diff --git a/test/ut3_user/reporters/test_tap_reporter.pks b/test/ut3_user/reporters/test_tap_reporter.pks index d24c76e32..27f9651bc 100644 --- a/test/ut3_user/reporters/test_tap_reporter.pks +++ b/test/ut3_user/reporters/test_tap_reporter.pks @@ -42,6 +42,9 @@ create or replace package test_tap_reporter as --%test(Suitepath as chopped subtests) procedure suitepath_as_chopped_subtests; + --%test(Include context with only skipped tests in output) + procedure include_context_with_skipped_tests; + --%afterall procedure drop_help_tests; From 40eb166c1a228b7d2ced30a471c8dd41335b8cb7 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Tue, 17 Mar 2026 22:14:55 +0000 Subject: [PATCH 588/887] Enhance annotation processing by improving SQL text handling and adding header stripping functionality --- .../annotations/ut_annotation_manager.pkb | 24 ++-- source/core/ut_utils.pkb | 132 +++++++----------- source/core/ut_utils.pks | 11 +- 3 files changed, 71 insertions(+), 96 deletions(-) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 05301ea94..0688f24b1 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -231,23 +231,25 @@ create or replace package body ut_annotation_manager as function get_source_from_sql_text(a_object_name varchar2, a_sql_text ora_name_list_t, a_parts binary_integer) return sys_refcursor is l_sql_clob clob; - l_sql_lines ut_varchar2_rows := ut_varchar2_rows(); + l_sql_lines dbms_preprocessor.source_lines_t := dbms_preprocessor.source_lines_t(); + l_sql_lines_clob ut_varchar2_list := ut_varchar2_list(); l_result sys_refcursor; + l_replaced boolean := false; begin if a_parts > 0 then for i in 1..a_parts loop ut_utils.append_to_clob(l_sql_clob, a_sql_text(i)); end loop; - l_sql_clob := ut_utils.replace_multiline_comments(l_sql_clob); - -- replace comment lines that contain "-- create or replace" - l_sql_clob := regexp_replace(l_sql_clob, '^.*[-]{2,}\s*create(\s+or\s+replace).*$', modifier => 'mi'); - -- remove the "create [or replace] [[non]editionable] " so that we have only "type|package|procedure|function" for parsing - -- needed for dbms_preprocessor - l_sql_clob := regexp_replace(l_sql_clob, '^(.*?\s*create(\s+or\s+replace)?(\s+(editionable|noneditionable))?\s+?)((package|type|procedure|function).*)', '\5', 1, 1, 'ni'); - -- remove "OWNER." from create or replace statement. - -- Owner is not supported along with AUTHID - see issue https://github.com/utPLSQL/utPLSQL/issues/1088 - l_sql_clob := regexp_replace(l_sql_clob, '^(package|type|procedure|function)\s+("?[[:alpha:]][[:alnum:]$#_]*"?\.)(.*)', '\1 \3', 1, 1, 'ni'); - l_sql_lines := ut_utils.convert_collection( ut_utils.clob_to_table(l_sql_clob) ); + + l_sql_lines_clob := ut_utils.clob_to_table(l_sql_clob); + for i in 1..l_sql_lines_clob.count loop + l_sql_lines(i) := l_sql_lines_clob(i); + end loop; + + -- replace multiline comments that contain "-- create or replace" with single line comment to avoid parsing issues with dbms_preprocessor + l_sql_lines := ut_utils.replace_multiline_comments(l_sql_lines); + -- strip CREATE header (possibly split across lines) while preserving line numbers + l_sql_lines := ut_utils.strip_create_header_lines(l_sql_lines); end if; open l_result for select /*+ no_parallel */ a_object_name as name, column_value||chr(10) as text from table(l_sql_lines); diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index e43dc5644..c81d86883 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -812,94 +812,62 @@ create or replace package body ut_utils is return l_result; end replace_multiline_comments; - function replace_multiline_comments(a_source clob) return clob is - l_result clob; - l_ml_comment_start binary_integer := 1; - l_comment_start binary_integer := 1; - l_text_start binary_integer := 1; - l_escaped_text_start binary_integer := 1; - l_escaped_text_end_char varchar2(1 char); - l_end binary_integer := 1; - l_ml_comment clob; - l_newlines_count binary_integer; - l_offset binary_integer := 1; - l_length binary_integer := coalesce(dbms_lob.getlength(a_source), 0); - begin - l_ml_comment_start := instr(a_source,'/*'); - l_comment_start := instr(a_source,'--'); - l_text_start := instr(a_source,''''); - l_escaped_text_start := instr(a_source,q'[q']'); - while l_offset > 0 and l_ml_comment_start > 0 loop - - if l_ml_comment_start > 0 and (l_ml_comment_start < l_comment_start or l_comment_start = 0) - and (l_ml_comment_start < l_text_start or l_text_start = 0)and (l_ml_comment_start < l_escaped_text_start or l_escaped_text_start = 0) - then - l_end := instr(a_source,'*/',l_ml_comment_start+2); - append_to_clob(l_result, dbms_lob.substr(a_source, l_ml_comment_start-l_offset, l_offset)); - if l_end > 0 then - l_ml_comment := substr(a_source, l_ml_comment_start, l_end-l_ml_comment_start); - l_newlines_count := length( l_ml_comment ) - length( translate( l_ml_comment, 'a'||chr(10), 'a') ); - if l_newlines_count > 0 then - append_to_clob(l_result, lpad( chr(10), l_newlines_count, chr(10) ) ); - end if; - l_end := l_end + 2; - end if; - else + function strip_create_header_lines(a_source dbms_preprocessor.source_lines_t) + return dbms_preprocessor.source_lines_t + is + l_result dbms_preprocessor.source_lines_t := a_source; + l_rebased dbms_preprocessor.source_lines_t; + l_create_line pls_integer; + l_header_line pls_integer; + l_header_pos pls_integer := 0; + begin + if l_result.count = 0 then + return l_result; + end if; - if l_comment_start > 0 and (l_comment_start < l_ml_comment_start or l_ml_comment_start = 0) - and (l_comment_start < l_text_start or l_text_start = 0) and (l_comment_start < l_escaped_text_start or l_escaped_text_start = 0) - then - l_end := instr(a_source,chr(10),l_comment_start+2); - if l_end > 0 then - l_end := l_end + 1; - end if; - elsif l_text_start > 0 and (l_text_start < l_ml_comment_start or l_ml_comment_start = 0) - and (l_text_start < l_comment_start or l_comment_start = 0) and (l_text_start < l_escaped_text_start or l_escaped_text_start = 0) - then - l_end := instr(a_source,q'[']',l_text_start+1); - - --skip double quotes while searching for end of quoted text - while l_end > 0 and l_end = instr(a_source,q'['']',l_text_start+1) loop - l_end := instr(a_source,q'[']',l_end+1); - end loop; - if l_end > 0 then - l_end := l_end + 1; - end if; + -- remove comment lines that contain "-- create or replace" and find first CREATE + for i in 1..l_result.count loop + l_result(i) := regexp_replace(l_result(i), '^.*[-]{2,}\s*create(\s+or\s+replace).*$', null, 1, 1, 'i'); + if l_create_line is null and regexp_like(l_result(i), '(^|[[:space:]])create([[:space:]]|$)', 'i') then + l_create_line := i; + end if; + end loop; - elsif l_escaped_text_start > 0 and (l_escaped_text_start < l_ml_comment_start or l_ml_comment_start = 0) - and (l_escaped_text_start < l_comment_start or l_comment_start = 0) and (l_escaped_text_start < l_text_start or l_text_start = 0) - then - --translate char "[" from the start of quoted text "q'[someting]'" into "]" - l_escaped_text_end_char := translate(substr(a_source, l_escaped_text_start + 2, 1),gc_open_chars,gc_close_chars); - l_end := instr(a_source,l_escaped_text_end_char||'''',l_escaped_text_start + 3 ); - if l_end > 0 then - l_end := l_end + 2; - end if; + -- find first occurrence of object keyword after CREATE (may be on later line) + if l_create_line is not null then + for i in l_create_line..l_result.count loop + l_header_pos := regexp_instr( + l_result(i), + '(^|[[:space:]])(package|type|procedure|function)([[:space:]]|$)', + 1, 1, 0, 'i', 2 + ); + if l_header_pos > 0 then + l_header_line := i; + exit; end if; + end loop; - if l_end = 0 then - append_to_clob(l_result, substr(a_source, l_offset, l_length-l_offset)); - else - append_to_clob(l_result, substr(a_source, l_offset, l_end-l_offset)); - end if; - end if; - l_offset := l_end; - if l_offset >= l_ml_comment_start then - l_ml_comment_start := instr(a_source,'/*',l_offset); - end if; - if l_offset >= l_comment_start then - l_comment_start := instr(a_source,'--',l_offset); - end if; - if l_offset >= l_text_start then - l_text_start := instr(a_source,'''',l_offset); - end if; - if l_offset >= l_escaped_text_start then - l_escaped_text_start := instr(a_source,q'[q']',l_offset); + if l_header_line is not null then + -- keep from keyword onward on the header line + l_result(l_header_line) := substr(l_result(l_header_line), l_header_pos); + -- remove "OWNER." from create or replace statement. + -- Owner is not supported along with AUTHID - see issue https://github.com/utPLSQL/utPLSQL/issues/1088 + l_result(l_header_line) := regexp_replace( + l_result(l_header_line), + '^(package|type|procedure|function)\s+("?[[:alpha:]][[:alnum:]$#_]*"?\.)(.*)', + '\1 \3', 1, 1, 'ni' + ); + + -- rebase so header line becomes line 1 (matches preprocessor expectations) + for i in l_header_line .. l_result.count loop + l_rebased(i - l_header_line + 1) := l_result(i); + end loop; + return l_rebased; end if; - end loop; - append_to_clob(l_result, substr(a_source, l_end)); + end if; + return l_result; - end; + end strip_create_header_lines; function get_child_reporters(a_for_reporters ut_reporters_info := null) return ut_reporters_info is l_for_reporters ut_reporters_info := a_for_reporters; diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index b0edc47f0..43b28e6eb 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -406,9 +406,14 @@ create or replace package ut_utils authid definer is * Replaces multi-line comments in given source-code with empty lines */ function replace_multiline_comments(a_source dbms_preprocessor.source_lines_t) - return dbms_preprocessor.source_lines_t; - - function replace_multiline_comments(a_source clob) return clob; + return dbms_preprocessor.source_lines_t; + + /** + * Strips the CREATE header (possibly split across lines) so source starts at + * package/type/procedure/function keyword, preserving line numbers. + */ + function strip_create_header_lines(a_source dbms_preprocessor.source_lines_t) + return dbms_preprocessor.source_lines_t; /** * Returns list of sub-type reporters for given list of super-type reporters From 1cdeb9c666ba412cebdc5b9e8baa9be41dc63de3 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 18 Mar 2026 21:44:45 +0000 Subject: [PATCH 589/887] Refactor annotation processing and enhance line scanning functionality in ut_utils --- .../annotations/ut_annotation_manager.pkb | 54 +++-- source/core/ut_utils.pkb | 210 ++++++++++-------- 2 files changed, 147 insertions(+), 117 deletions(-) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 0688f24b1..117a28729 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -143,31 +143,41 @@ create or replace package body ut_annotation_manager as l_parse_time date := sysdate; pragma autonomous_transaction; begin - loop - fetch a_sources_cursor bulk collect into l_names, l_lines limit c_lines_fetch_limit; - for i in 1 .. l_names.count loop - if l_names(i) != l_name then - l_annotations := ut_annotation_parser.parse_object_annotations(l_object_lines, a_object_type); - ut_annotation_cache_manager.update_cache( - ut_annotated_object(a_object_owner, l_name, a_object_type, l_parse_time, l_annotations) - ); - l_object_lines.delete; - end if; + begin + loop + fetch a_sources_cursor bulk collect into l_names, l_lines limit c_lines_fetch_limit; + for i in 1 .. l_names.count loop + if l_names(i) != l_name then + l_annotations := ut_annotation_parser.parse_object_annotations(l_object_lines, a_object_type); + ut_annotation_cache_manager.update_cache( + ut_annotated_object(a_object_owner, l_name, a_object_type, l_parse_time, l_annotations) + ); + l_object_lines.delete; + end if; + + l_name := l_names(i); + l_object_lines(l_object_lines.count+1) := l_lines(i); + end loop; + exit when a_sources_cursor%notfound; - l_name := l_names(i); - l_object_lines(l_object_lines.count+1) := l_lines(i); end loop; - exit when a_sources_cursor%notfound; - - end loop; - if a_sources_cursor%rowcount > 0 then - l_annotations := ut_annotation_parser.parse_object_annotations(l_object_lines, a_object_type); - ut_annotation_cache_manager.update_cache( - ut_annotated_object(a_object_owner, l_name, a_object_type, l_parse_time, l_annotations) - ); - l_object_lines.delete; + if a_sources_cursor%rowcount > 0 then + l_annotations := ut_annotation_parser.parse_object_annotations(l_object_lines, a_object_type); + ut_annotation_cache_manager.update_cache( + ut_annotated_object(a_object_owner, l_name, a_object_type, l_parse_time, l_annotations) + ); + l_object_lines.delete; + end if; + exception + when others then + if a_sources_cursor%isopen then + close a_sources_cursor; + end if; + raise; + end; + if a_sources_cursor%isopen then + close a_sources_cursor; end if; - close a_sources_cursor; end; diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index c81d86883..ccde8f966 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -23,8 +23,8 @@ create or replace package body ut_utils is gc_invalid_xml_char constant varchar2(50) := '[^_[:alnum:]\.-]'; gc_full_valid_xml_name constant varchar2(50) := '^([[:alpha:]])([_[:alnum:]\.-])*$'; gc_owner_hash constant integer(11) := dbms_utility.get_hash_value( ut_owner(), 0, power(2,31)-1); - gc_open_chars constant varchar2(4):= chr(91) || chr(123) || chr(40) || chr(60); -- [{( this has very specific purpose to not confuse lexer in IDE - gc_close_chars constant varchar2(4):= chr(93) || chr(125) || chr(41) || chr(62); -- ]})> this has very specific purpose to not confuse lexer in IDE + gc_open_chars constant varchar2(4):= '[{(<'; + gc_close_chars constant varchar2(4):= ']})>'; gc_max_plsql_source_len constant integer := 32767; function surround_with(a_value varchar2, a_quote_char varchar2) return varchar2 is @@ -660,6 +660,115 @@ create or replace package body ut_utils is return l_result; end; + function scan_line(a_line in varchar2, a_in_ml_comment in out boolean) return varchar2 is + -- Normal scan + l_remaining varchar2(32767) := a_line; + l_line varchar2(32767); + l_ml_start binary_integer; + l_comment_start binary_integer; + l_text_start binary_integer; + l_eq_text_start binary_integer; + l_eq_end_char varchar2(1 char); + l_pos binary_integer; + l_end binary_integer; + l_ml_end binary_integer; + begin + if a_in_ml_comment then + l_ml_end := instr(l_remaining, '*/'); + if l_ml_end > 0 then + a_in_ml_comment := false; + l_remaining := substr(l_remaining, l_ml_end + 2); + else + return null; + end if; + end if; + + loop + exit when l_remaining is null; + l_ml_start := instr(l_remaining, '/*'); + l_comment_start := instr(l_remaining, '--'); + l_text_start := instr(l_remaining, ''''); + -- q' always puts ' at l_text_start; just check the char immediately before it + l_eq_text_start := case + when l_text_start > 1 and substr(l_remaining, l_text_start - 1, 1) = 'q' + then l_text_start - 1 + else 0 + end; + -- Sentinel gc_max_plsql_source_len means "not present"; 32767 is beyond any VARCHAR2 position + l_pos := least( + case when l_ml_start > 0 then l_ml_start else gc_max_plsql_source_len end, + case when l_comment_start > 0 then l_comment_start else gc_max_plsql_source_len end, + case when l_text_start > 0 then l_text_start else gc_max_plsql_source_len end, + case when l_eq_text_start > 0 then l_eq_text_start else gc_max_plsql_source_len end + ); + + if l_pos = gc_max_plsql_source_len then + l_line := l_line || l_remaining; + exit; + end if; + + l_line := l_line || substr(l_remaining, 1, l_pos - 1); + l_remaining := substr(l_remaining, l_pos); + -- l_remaining now starts exactly at the token; all branch offsets below are relative to 1 + if l_pos = l_eq_text_start then + -- q-quoted string: l_remaining starts at 'q', delimiter is at position 3 + l_eq_end_char := translate(substr(l_remaining, 3, 1), gc_open_chars, gc_close_chars); + l_end := instr(l_remaining, l_eq_end_char || '''', 4); + if l_end > 0 then + l_line := l_line || substr(l_remaining, 1, l_end + 1); + l_remaining := substr(l_remaining, l_end + 2); + else + l_line := l_line || l_remaining; + exit; + end if; + + elsif l_pos = l_ml_start then + -- Multi-line comment: l_remaining starts at '/*', so end search starts at 3 + l_ml_end := instr(l_remaining, '*/', 3); + if l_ml_end > 0 then + l_remaining := substr(l_remaining, l_ml_end + 2); + else + a_in_ml_comment := true; + -- preserve trailing newline if present — it belongs to this line, not the comment + if substr(l_remaining, -1) = chr(10) then + l_line := l_line || chr(10); + end if; + return l_line; + end if; + + elsif l_pos = l_comment_start then + -- Single-line comment: everything from here is comment, keep and stop + l_line := l_line || l_remaining; + return l_line; + + else + -- Regular string literal: l_remaining starts at the opening quote + -- scan from position 2 to skip the opening quote + l_end := 2; + loop + l_end := instr(l_remaining, '''', l_end); + exit when l_end = 0; + if substr(l_remaining, l_end, 2) = '''''' then + l_end := l_end + 2; -- skip escaped quote pair + else + exit; -- real closing quote + end if; + end loop; + + if l_end > 0 then + l_line := l_line || substr(l_remaining, 1, l_end); + l_remaining := substr(l_remaining, l_end + 1); + else + l_line := l_line || l_remaining; + exit; + end if; + + end if; + end loop; + + return l_line; + end; + function replace_multiline_comments(a_source dbms_preprocessor.source_lines_t) return dbms_preprocessor.source_lines_t is @@ -668,13 +777,6 @@ create or replace package body ut_utils is l_remaining varchar2(32767); l_in_ml_comment boolean := false; l_ml_end binary_integer; - l_ml_start binary_integer; - l_comment_start binary_integer; - l_text_start binary_integer; - l_eq_text_start binary_integer; - l_eq_end_char varchar2(1 char); - l_pos binary_integer; - l_end binary_integer; l_has_ml_comment boolean := false; begin if a_source.count = 0 then @@ -720,92 +822,10 @@ create or replace package body ut_utils is -- Normal scan l_remaining := l_line; - l_line := null; - - <> - loop - exit when l_remaining is null or l_remaining = ''; - l_ml_start := instr(l_remaining, '/*'); - l_comment_start := instr(l_remaining, '--'); - l_text_start := instr(l_remaining, ''''); - -- q' always puts ' at l_text_start; just check the char immediately before it - l_eq_text_start := case - when l_text_start > 1 and substr(l_remaining, l_text_start - 1, 1) = 'q' - then l_text_start - 1 - else 0 - end; - -- Sentinel gc_max_plsql_source_len means "not present"; 32767 is beyond any VARCHAR2 position - l_pos := least( - case when l_ml_start > 0 then l_ml_start else gc_max_plsql_source_len end, - case when l_comment_start > 0 then l_comment_start else gc_max_plsql_source_len end, - case when l_text_start > 0 then l_text_start else gc_max_plsql_source_len end, - case when l_eq_text_start > 0 then l_eq_text_start else gc_max_plsql_source_len end - ); - - if l_pos = gc_max_plsql_source_len then - l_line := l_line || l_remaining; - exit scan_line; - end if; - - l_line := l_line || substr(l_remaining, 1, l_pos - 1); - l_remaining := substr(l_remaining, l_pos); - -- l_remaining now starts exactly at the token; all branch offsets below are relative to 1 - if l_pos = l_eq_text_start then - -- q-quoted string: l_remaining starts at 'q', delimiter is at position 3 - l_eq_end_char := translate(substr(l_remaining, 3, 1), gc_open_chars, gc_close_chars); - l_end := instr(l_remaining, l_eq_end_char || '''', 4); - if l_end > 0 then - l_line := l_line || substr(l_remaining, 1, l_end + 1); - l_remaining := substr(l_remaining, l_end + 2); - else - l_line := l_line || l_remaining; - exit scan_line; - end if; - - elsif l_pos = l_ml_start then - -- Multi-line comment: l_remaining starts at '/*', so end search starts at 3 - l_ml_end := instr(l_remaining, '*/', 3); - if l_ml_end > 0 then - l_remaining := substr(l_remaining, l_ml_end + 2); - else - l_in_ml_comment := true; - -- preserve trailing newline if present — it belongs to this line, not the comment - if substr(l_remaining, -1) = chr(10) then - l_line := l_line || chr(10); - end if; - exit scan_line; - end if; - - elsif l_pos = l_comment_start then - -- Single-line comment: everything from here is comment, keep and stop - l_line := l_line || l_remaining; - exit scan_line; - - else - -- Regular string literal: l_remaining starts at the opening quote - -- scan from position 2 to skip the opening quote - l_end := 2; - loop - l_end := instr(l_remaining, '''', l_end); - exit when l_end = 0; - if substr(l_remaining, l_end, 2) = '''''' then - l_end := l_end + 2; -- skip escaped quote pair - else - exit; -- real closing quote - end if; - end loop; - - if l_end > 0 then - l_line := l_line || substr(l_remaining, 1, l_end); - l_remaining := substr(l_remaining, l_end + 1); - else - l_line := l_line || l_remaining; - exit scan_line; - end if; - - end if; - end loop scan_line; - + l_line := scan_line(l_remaining, l_in_ml_comment); + if l_line is null then + l_line := ''; + end if; l_result(i) := l_line; end loop; From c4d0ab07e7440dc7cc50d3d2a1dbcdb88f4ae17b Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 18 Mar 2026 21:57:39 +0000 Subject: [PATCH 590/887] Remove redundant exception handling in build_annot_cache_for_sources procedure --- source/core/annotations/ut_annotation_manager.pkb | 6 ------ 1 file changed, 6 deletions(-) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 117a28729..5b4ee09c2 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -168,12 +168,6 @@ create or replace package body ut_annotation_manager as ); l_object_lines.delete; end if; - exception - when others then - if a_sources_cursor%isopen then - close a_sources_cursor; - end if; - raise; end; if a_sources_cursor%isopen then close a_sources_cursor; From aa3bfe7e54c814915a550dfd54cc2d552083ee65 Mon Sep 17 00:00:00 2001 From: Lukasz Wasylow Date: Wed, 18 Mar 2026 22:14:45 +0000 Subject: [PATCH 591/887] Refactor annotation patterns in ut_annotation_parser and remove unused constants --- source/core/annotations/ut_annotation_manager.pkb | 2 -- source/core/annotations/ut_annotation_parser.pkb | 4 +--- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 5b4ee09c2..6767411f1 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -174,7 +174,6 @@ create or replace package body ut_annotation_manager as end if; end; - procedure validate_annotation_cache( a_object_owner varchar2, a_object_type varchar2, @@ -238,7 +237,6 @@ create or replace package body ut_annotation_manager as l_sql_lines dbms_preprocessor.source_lines_t := dbms_preprocessor.source_lines_t(); l_sql_lines_clob ut_varchar2_list := ut_varchar2_list(); l_result sys_refcursor; - l_replaced boolean := false; begin if a_parts > 0 then for i in 1..a_parts loop diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 6fcd7a5bf..d356a1ebf 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -22,12 +22,10 @@ create or replace package body ut_annotation_parser as type tt_comment_list is table of varchar2(32767) index by binary_integer; gc_annotation_qualifier constant varchar2(1) := '%'; - gc_annot_comment_pattern constant varchar2(30) := '^( |'||chr(09)||')*-- *('||gc_annotation_qualifier||'.*?)$'; -- chr(09) is a tab character gc_comment_replacer_patter constant varchar2(50) := '{COMMENT#%N%}'; gc_comment_replacer_regex_ptrn constant varchar2(25) := '{COMMENT#(\d+)}'; gc_regexp_identifier constant varchar2(50) := '[[:alpha:]][[:alnum:]$#_]*'; - gc_annotation_block_pattern constant varchar2(200) := '(({COMMENT#.+}'||chr(10)||')+)( |'||chr(09)||')*(procedure|function)\s+(' || - gc_regexp_identifier || ')'; + gc_annotation_pattern constant varchar2(50) := gc_annotation_qualifier || gc_regexp_identifier || '[ '||chr(9)||']*(\(.*?\)\s*?$)?'; From d9a068b7a3a08987e82566c07f84aa479fa47785 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 09:29:48 +0300 Subject: [PATCH 592/887] Update of version number of utPLSQL to 3.2.01 This version drops support for Oracle versions older than Oracle 19c. --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 5fcdcb942..48e1527d1 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.1.14-develop +v3.2.01-develop From 3724a364a543a33a10dc9614f3c0b3cc105dae0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 10:06:13 +0300 Subject: [PATCH 593/887] Fixing uninstall script. Added missing removal of UT_TAP_REPORTER. --- source/uninstall_objects.sql | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index dde9a824f..df8b51d35 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -273,6 +273,8 @@ drop type ut_stack force; drop sequence ut_savepoint_seq; +drop type ut_tap_reporter force; + drop type ut_documentation_reporter force; drop type ut_debug_reporter force; From c6ca071005684549b715ae7b481ae0df68cfc745 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 22 Apr 2026 08:12:28 +0100 Subject: [PATCH 594/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pks | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 2bfcb2370..4b0190a75 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4342 +4361 diff --git a/docs/about/authors.md b/docs/about/authors.md index 2c2abf826..b2ee45733 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 0485779e5..4f97da2a1 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 81e4f976e..3833254af 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 4ac661e10..3f6297dc5 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 459bc9535..667092b1c 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index c0cbffb0e..420aa96ce 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 3dc42e429..8f3f03beb 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 45be3be59..16f6e1471 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index adf36baa6..68ddee6c9 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e042d61ed..96cb4b0be 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0ea5e2e73..b1baa871b 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index cd4feb46a..025046ebc 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 6724ac6ab..e5d3b8129 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 0cdc2d7fa..fca25c6ee 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index b417ba25c..7ef328f3e 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 28e02d5b8..aa190fb2f 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 818a592bc..2ef1a898b 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.1.14.4342--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index f23e8cf71..24e77c11f 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -3,7 +3,7 @@ sonar.organization=utplsql sonar.projectKey=utPLSQL_utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.1.14-develop +sonar.projectVersion=v3.2.01-develop # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 9615c7b4d..27ad1823b 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.1.14.4342-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4361-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 06cdd33004d9450eb288a4d4a84f66d48542401f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 11:37:31 +0300 Subject: [PATCH 595/887] Update of Copyright banner Added copyright banner to files that were missing the banner. Set 2026 in Copyright banner --- source/api/ut.pkb | 2 +- source/api/ut.pks | 2 +- source/api/ut_runner.pkb | 2 +- source/api/ut_runner.pks | 2 +- source/api/ut_suite_item_info.tpb | 2 +- source/api/ut_suite_item_info.tps | 2 +- source/api/ut_suite_items_info.tps | 2 +- source/check_object_grants.sql | 17 ++++++++++++++ source/check_sys_grants.sql | 17 ++++++++++++++ .../core/annotations/ut_annotated_object.tps | 2 +- .../core/annotations/ut_annotated_objects.tps | 2 +- source/core/annotations/ut_annotation.tps | 2 +- .../core/annotations/ut_annotation_cache.sql | 2 +- .../annotations/ut_annotation_cache_info.sql | 2 +- .../ut_annotation_cache_manager.pkb | 2 +- .../ut_annotation_cache_manager.pks | 2 +- .../ut_annotation_cache_schema.sql | 2 +- .../annotations/ut_annotation_cache_seq.sql | 2 +- .../annotations/ut_annotation_manager.pkb | 2 +- .../annotations/ut_annotation_manager.pks | 2 +- .../ut_annotation_obj_cache_info.tps | 2 +- .../ut_annotation_objs_cache_info.tps | 2 +- .../core/annotations/ut_annotation_parser.pkb | 2 +- .../core/annotations/ut_annotation_parser.pks | 2 +- source/core/annotations/ut_annotations.tps | 2 +- .../ut_trigger_annotation_parsing.trg | 16 +++++++++++++ source/core/annotations/ut_trigger_check.pkb | 2 +- source/core/annotations/ut_trigger_check.pks | 2 +- source/core/coverage/ut_coverage.pkb | 2 +- source/core/coverage/ut_coverage.pks | 2 +- source/core/coverage/ut_coverage_block.pkb | 2 +- source/core/coverage/ut_coverage_block.pks | 2 +- source/core/coverage/ut_coverage_helper.pkb | 2 +- source/core/coverage/ut_coverage_helper.pks | 2 +- .../coverage/ut_coverage_helper_block.pkb | 2 +- .../coverage/ut_coverage_helper_block.pks | 2 +- .../coverage/ut_coverage_helper_profiler.pkb | 2 +- .../coverage/ut_coverage_helper_profiler.pks | 2 +- source/core/coverage/ut_coverage_profiler.pkb | 2 +- source/core/coverage/ut_coverage_profiler.pks | 2 +- .../coverage/ut_coverage_reporter_base.tpb | 2 +- .../coverage/ut_coverage_reporter_base.tps | 2 +- .../core/coverage/ut_coverage_sources_tmp.sql | 2 +- source/core/events/ut_event_item.tps | 2 +- source/core/events/ut_event_listener.tps | 2 +- source/core/events/ut_event_manager.pkb | 2 +- source/core/events/ut_event_manager.pks | 2 +- .../output_buffers/ut_output_buffer_base.tpb | 2 +- .../output_buffers/ut_output_buffer_base.tps | 2 +- .../ut_output_buffer_info_tmp.sql | 2 +- .../output_buffers/ut_output_buffer_tmp.sql | 2 +- .../output_buffers/ut_output_bulk_buffer.tpb | 2 +- .../output_buffers/ut_output_bulk_buffer.tps | 2 +- .../ut_output_clob_buffer_tmp.sql | 2 +- .../ut_output_clob_table_buffer.tpb | 2 +- .../ut_output_clob_table_buffer.tps | 2 +- .../output_buffers/ut_output_data_row.tps | 2 +- .../output_buffers/ut_output_data_rows.tps | 2 +- .../output_buffers/ut_output_table_buffer.tpb | 2 +- .../output_buffers/ut_output_table_buffer.tps | 2 +- .../session_context/ut_session_context.pkb | 2 +- .../session_context/ut_session_context.pks | 2 +- .../core/session_context/ut_session_info.tpb | 2 +- .../core/session_context/ut_session_info.tps | 2 +- .../core/types/ut_console_reporter_base.tpb | 2 +- .../core/types/ut_console_reporter_base.tps | 2 +- source/core/types/ut_coverage_options.tpb | 2 +- source/core/types/ut_coverage_options.tps | 2 +- source/core/types/ut_executable.tpb | 2 +- source/core/types/ut_executable.tps | 2 +- source/core/types/ut_executable_test.tpb | 2 +- source/core/types/ut_executable_test.tps | 2 +- source/core/types/ut_executables.tps | 2 +- source/core/types/ut_expectation_result.tpb | 2 +- source/core/types/ut_expectation_result.tps | 2 +- source/core/types/ut_expectation_results.tps | 2 +- source/core/types/ut_file_mapping.tpb | 2 +- source/core/types/ut_file_mapping.tps | 2 +- source/core/types/ut_file_mappings.tps | 2 +- source/core/types/ut_integer_list.tps | 2 +- source/core/types/ut_key_value_pair.tps | 2 +- source/core/types/ut_key_value_pairs.tps | 2 +- source/core/types/ut_logical_suite.tpb | 2 +- source/core/types/ut_logical_suite.tps | 2 +- source/core/types/ut_object_name.tpb | 2 +- source/core/types/ut_object_name.tps | 2 +- source/core/types/ut_object_names.tps | 2 +- source/core/types/ut_output_reporter_base.tpb | 2 +- source/core/types/ut_output_reporter_base.tps | 2 +- source/core/types/ut_path_item.tpb | 2 +- source/core/types/ut_path_item.tps | 2 +- source/core/types/ut_path_items.tps | 2 +- source/core/types/ut_reporter_base.tpb | 2 +- source/core/types/ut_reporter_base.tps | 2 +- source/core/types/ut_reporter_info.tps | 2 +- source/core/types/ut_reporters.tps | 2 +- source/core/types/ut_reporters_info.tps | 2 +- source/core/types/ut_results_counter.tpb | 2 +- source/core/types/ut_results_counter.tps | 2 +- source/core/types/ut_run.tpb | 2 +- source/core/types/ut_run.tps | 2 +- source/core/types/ut_run_info.tpb | 2 +- source/core/types/ut_run_info.tps | 2 +- source/core/types/ut_stack.tpb | 2 +- source/core/types/ut_stack.tps | 2 +- source/core/types/ut_suite.tpb | 2 +- source/core/types/ut_suite.tps | 2 +- source/core/types/ut_suite_cache_row.tps | 2 +- source/core/types/ut_suite_cache_rows.tps | 2 +- source/core/types/ut_suite_context.tpb | 2 +- source/core/types/ut_suite_context.tps | 2 +- source/core/types/ut_suite_item.tpb | 2 +- source/core/types/ut_suite_item.tps | 2 +- source/core/types/ut_suite_items.tps | 2 +- source/core/types/ut_test.tpb | 2 +- source/core/types/ut_test.tps | 2 +- source/core/types/ut_varchar2_list.tps | 2 +- source/core/types/ut_varchar2_rows.tps | 2 +- source/core/ut_dbms_output_cache.sql | 23 ++++++++++--------- source/core/ut_expectation_processor.pkb | 2 +- source/core/ut_expectation_processor.pks | 2 +- source/core/ut_file_mapper.pkb | 2 +- source/core/ut_file_mapper.pks | 2 +- source/core/ut_metadata.pkb | 2 +- source/core/ut_metadata.pks | 2 +- source/core/ut_savepoint_seq.sql | 2 +- source/core/ut_suite_builder.pkb | 2 +- source/core/ut_suite_builder.pks | 2 +- source/core/ut_suite_cache.sql | 2 +- source/core/ut_suite_cache_manager.pkb | 2 +- source/core/ut_suite_cache_manager.pks | 2 +- source/core/ut_suite_cache_package.sql | 2 +- source/core/ut_suite_cache_schema.sql | 2 +- source/core/ut_suite_cache_seq.sql | 2 +- source/core/ut_suite_manager.pkb | 2 +- source/core/ut_suite_manager.pks | 2 +- source/core/ut_suite_tag_filter.pkb | 2 +- source/core/ut_suite_tag_filter.pks | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- source/create_grants.sql | 2 +- source/create_synonyms.sql | 2 +- .../create_synonyms_and_grants_for_public.sql | 2 +- source/create_user_grants.sql | 2 +- source/create_user_synonyms.sql | 2 +- source/create_utplsql_owner.sql | 2 +- source/define_ut3_owner_param.sql | 2 +- .../data_values/ut_compound_data_diff_tmp.sql | 2 +- .../data_values/ut_compound_data_helper.pkb | 2 +- .../data_values/ut_compound_data_helper.pks | 2 +- .../data_values/ut_compound_data_tmp.sql | 2 +- .../data_values/ut_compound_data_value.tpb | 2 +- .../data_values/ut_compound_data_value.tps | 2 +- .../data_values/ut_cursor_column.tpb | 18 ++++++++++++++- .../data_values/ut_cursor_column.tps | 2 +- .../data_values/ut_cursor_column_tab.tps | 2 +- .../data_values/ut_cursor_details.tpb | 17 ++++++++++++++ .../data_values/ut_cursor_details.tps | 2 +- .../data_values/ut_data_value.tpb | 2 +- .../data_values/ut_data_value.tps | 2 +- .../data_values/ut_data_value_anydata.tpb | 2 +- .../data_values/ut_data_value_anydata.tps | 2 +- .../data_values/ut_data_value_blob.tpb | 2 +- .../data_values/ut_data_value_blob.tps | 2 +- .../data_values/ut_data_value_boolean.tpb | 2 +- .../data_values/ut_data_value_boolean.tps | 2 +- .../data_values/ut_data_value_clob.tpb | 2 +- .../data_values/ut_data_value_clob.tps | 2 +- .../data_values/ut_data_value_date.tpb | 2 +- .../data_values/ut_data_value_date.tps | 2 +- .../data_values/ut_data_value_dsinterval.tpb | 2 +- .../data_values/ut_data_value_dsinterval.tps | 2 +- .../data_values/ut_data_value_json.tpb | 2 +- .../data_values/ut_data_value_json.tps | 2 +- .../data_values/ut_data_value_number.tpb | 2 +- .../data_values/ut_data_value_number.tps | 2 +- .../data_values/ut_data_value_refcursor.tpb | 2 +- .../data_values/ut_data_value_refcursor.tps | 2 +- .../data_values/ut_data_value_timestamp.tpb | 2 +- .../data_values/ut_data_value_timestamp.tps | 2 +- .../ut_data_value_timestamp_ltz.tpb | 2 +- .../ut_data_value_timestamp_ltz.tps | 2 +- .../ut_data_value_timestamp_tz.tpb | 2 +- .../ut_data_value_timestamp_tz.tps | 2 +- .../data_values/ut_data_value_varchar2.tpb | 2 +- .../data_values/ut_data_value_varchar2.tps | 2 +- .../data_values/ut_data_value_xmltype.tpb | 2 +- .../data_values/ut_data_value_xmltype.tps | 2 +- .../data_values/ut_data_value_yminterval.tpb | 2 +- .../data_values/ut_data_value_yminterval.tps | 2 +- .../data_values/ut_json_data_diff_tmp.sql | 2 +- .../expectations/data_values/ut_json_leaf.tpb | 18 ++++++++++++++- .../expectations/data_values/ut_json_leaf.tps | 2 +- .../data_values/ut_json_leaf_tab.tps | 2 +- .../data_values/ut_json_tree_details.tpb | 16 +++++++++++++ .../data_values/ut_json_tree_details.tps | 2 +- .../data_values/ut_key_anyval_pair.tps | 2 +- .../data_values/ut_key_anyval_pairs.tps | 2 +- .../data_values/ut_key_anyvalues.tpb | 2 +- .../data_values/ut_key_anyvalues.tps | 2 +- .../expectations/matchers/ut_be_between.tpb | 2 +- .../expectations/matchers/ut_be_between.tps | 2 +- source/expectations/matchers/ut_be_empty.tpb | 2 +- source/expectations/matchers/ut_be_empty.tps | 2 +- source/expectations/matchers/ut_be_false.tpb | 2 +- source/expectations/matchers/ut_be_false.tps | 2 +- .../matchers/ut_be_greater_or_equal.tpb | 2 +- .../matchers/ut_be_greater_or_equal.tps | 2 +- .../matchers/ut_be_greater_than.tpb | 2 +- .../matchers/ut_be_greater_than.tps | 2 +- .../matchers/ut_be_less_or_equal.tpb | 2 +- .../matchers/ut_be_less_or_equal.tps | 2 +- .../expectations/matchers/ut_be_less_than.tpb | 2 +- .../expectations/matchers/ut_be_less_than.tps | 2 +- source/expectations/matchers/ut_be_like.tpb | 2 +- source/expectations/matchers/ut_be_like.tps | 2 +- .../expectations/matchers/ut_be_not_null.tpb | 2 +- .../expectations/matchers/ut_be_not_null.tps | 2 +- source/expectations/matchers/ut_be_null.tpb | 2 +- source/expectations/matchers/ut_be_null.tps | 2 +- source/expectations/matchers/ut_be_true.tpb | 2 +- source/expectations/matchers/ut_be_true.tps | 2 +- source/expectations/matchers/ut_be_within.tpb | 2 +- source/expectations/matchers/ut_be_within.tps | 2 +- .../matchers/ut_be_within_helper.pkb | 2 +- .../matchers/ut_be_within_helper.pks | 2 +- .../matchers/ut_be_within_pct.tpb | 2 +- .../matchers/ut_be_within_pct.tps | 3 +-- .../matchers/ut_comparison_matcher.tpb | 2 +- .../matchers/ut_comparison_matcher.tps | 2 +- source/expectations/matchers/ut_contain.tpb | 2 +- source/expectations/matchers/ut_contain.tps | 2 +- source/expectations/matchers/ut_equal.tpb | 2 +- source/expectations/matchers/ut_equal.tps | 2 +- .../expectations/matchers/ut_have_count.tpb | 2 +- .../expectations/matchers/ut_have_count.tps | 2 +- source/expectations/matchers/ut_match.tpb | 2 +- source/expectations/matchers/ut_match.tps | 2 +- source/expectations/matchers/ut_matcher.tpb | 2 +- source/expectations/matchers/ut_matcher.tps | 2 +- .../expectations/matchers/ut_matcher_base.tps | 17 ++++++++++++++ .../matchers/ut_matcher_options.tpb | 2 +- .../matchers/ut_matcher_options.tps | 2 +- .../matchers/ut_matcher_options_items.tpb | 2 +- .../matchers/ut_matcher_options_items.tps | 2 +- source/expectations/ut_expectation.tpb | 2 +- source/expectations/ut_expectation.tps | 2 +- source/expectations/ut_expectation_base.tpb | 3 ++- source/expectations/ut_expectation_base.tps | 3 ++- .../expectations/ut_expectation_compound.tpb | 2 +- .../expectations/ut_expectation_compound.tps | 2 +- source/expectations/ut_expectation_json.tpb | 2 +- source/expectations/ut_expectation_json.tps | 2 +- source/install.sql | 2 +- source/install_above_12_1.sql | 17 ++++++++++++++ source/install_component.sql | 2 +- source/install_ddl_trigger.sql | 2 +- source/install_headless.sql | 2 +- source/install_headless_with_trigger.sql | 2 +- source/reporters/ut_ansiconsole_helper.pkb | 2 +- source/reporters/ut_ansiconsole_helper.pks | 2 +- .../ut_coverage_cobertura_reporter.tpb | 2 +- .../ut_coverage_cobertura_reporter.tps | 2 +- .../reporters/ut_coverage_html_reporter.tpb | 2 +- .../reporters/ut_coverage_html_reporter.tps | 2 +- .../ut_coverage_report_html_helper.pkb | 2 +- .../ut_coverage_report_html_helper.pks | 2 +- .../reporters/ut_coverage_sonar_reporter.tpb | 2 +- .../reporters/ut_coverage_sonar_reporter.tps | 2 +- source/reporters/ut_coveralls_reporter.tpb | 2 +- source/reporters/ut_coveralls_reporter.tps | 2 +- source/reporters/ut_debug_reporter.tpb | 2 +- source/reporters/ut_debug_reporter.tps | 2 +- .../reporters/ut_documentation_reporter.tpb | 2 +- .../reporters/ut_documentation_reporter.tps | 2 +- source/reporters/ut_junit_reporter.tpb | 2 +- source/reporters/ut_junit_reporter.tps | 2 +- source/reporters/ut_realtime_reporter.tpb | 2 +- source/reporters/ut_realtime_reporter.tps | 2 +- source/reporters/ut_sonar_test_reporter.tpb | 2 +- source/reporters/ut_sonar_test_reporter.tps | 2 +- source/reporters/ut_tap_reporter.tpb | 17 +++++++++++++- source/reporters/ut_tap_reporter.tps | 16 +++++++++++++ source/reporters/ut_teamcity_reporter.tpb | 2 +- source/reporters/ut_teamcity_reporter.tps | 2 +- .../reporters/ut_teamcity_reporter_helper.pkb | 2 +- .../reporters/ut_teamcity_reporter_helper.pks | 2 +- source/reporters/ut_tfs_junit_reporter.tpb | 2 +- source/reporters/ut_tfs_junit_reporter.tps | 2 +- source/reporters/ut_xunit_reporter.tpb | 2 +- source/reporters/ut_xunit_reporter.tps | 2 +- source/set_install_params.sql | 2 +- source/uninstall.sql | 2 +- source/uninstall_all.sql | 2 +- source/uninstall_coverage_tables.sql | 17 ++++++++++++++ source/uninstall_objects.sql | 17 ++++++++++++++ source/uninstall_synonyms.sql | 17 ++++++++++++++ 297 files changed, 530 insertions(+), 297 deletions(-) diff --git a/source/api/ut.pkb b/source/api/ut.pkb index cff35b771..d61de040a 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -2,7 +2,7 @@ create or replace package body ut is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut.pks b/source/api/ut.pks index f72c82a0c..6fd98dd9f 100644 --- a/source/api/ut.pks +++ b/source/api/ut.pks @@ -2,7 +2,7 @@ create or replace package ut authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 3ec2a5393..755683cc9 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -2,7 +2,7 @@ create or replace package body ut_runner is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_runner.pks b/source/api/ut_runner.pks index 85eff1c93..2c6bba888 100644 --- a/source/api/ut_runner.pks +++ b/source/api/ut_runner.pks @@ -2,7 +2,7 @@ create or replace package ut_runner authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_suite_item_info.tpb b/source/api/ut_suite_item_info.tpb index 3315f7a16..727707ae9 100644 --- a/source/api/ut_suite_item_info.tpb +++ b/source/api/ut_suite_item_info.tpb @@ -1,7 +1,7 @@ create or replace type body ut_suite_item_info is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_suite_item_info.tps b/source/api/ut_suite_item_info.tps index 2c92f261d..f632b2f52 100644 --- a/source/api/ut_suite_item_info.tps +++ b/source/api/ut_suite_item_info.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_item_info as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/api/ut_suite_items_info.tps b/source/api/ut_suite_items_info.tps index 208098f9d..e47b350e5 100644 --- a/source/api/ut_suite_items_info.tps +++ b/source/api/ut_suite_items_info.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_items_info as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/check_object_grants.sql b/source/check_object_grants.sql index 5f560e6b1..0e7a9b4c9 100644 --- a/source/check_object_grants.sql +++ b/source/check_object_grants.sql @@ -1,3 +1,20 @@ +/* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + declare $if dbms_db_version.version >= 18 $then c_expected_grants constant dbmsoutput_linesarray := dbmsoutput_linesarray('DBMS_CRYPTO'); diff --git a/source/check_sys_grants.sql b/source/check_sys_grants.sql index 79b657328..f81157183 100644 --- a/source/check_sys_grants.sql +++ b/source/check_sys_grants.sql @@ -1,3 +1,20 @@ +/* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + define expected_grants = "&1" declare c_expected_grants constant dbmsoutput_linesarray := dbmsoutput_linesarray( &expected_grants ); diff --git a/source/core/annotations/ut_annotated_object.tps b/source/core/annotations/ut_annotated_object.tps index 3fda363fe..21f6ab330 100644 --- a/source/core/annotations/ut_annotated_object.tps +++ b/source/core/annotations/ut_annotated_object.tps @@ -1,7 +1,7 @@ create type ut_annotated_object as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotated_objects.tps b/source/core/annotations/ut_annotated_objects.tps index c67c1bd53..63679b699 100644 --- a/source/core/annotations/ut_annotated_objects.tps +++ b/source/core/annotations/ut_annotated_objects.tps @@ -1,7 +1,7 @@ create type ut_annotated_objects as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation.tps b/source/core/annotations/ut_annotation.tps index 3d0311571..18747516a 100644 --- a/source/core/annotations/ut_annotation.tps +++ b/source/core/annotations/ut_annotation.tps @@ -1,7 +1,7 @@ create type ut_annotation as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_cache.sql b/source/core/annotations/ut_annotation_cache.sql index 67149ce60..7d69b1db6 100644 --- a/source/core/annotations/ut_annotation_cache.sql +++ b/source/core/annotations/ut_annotation_cache.sql @@ -1,7 +1,7 @@ create table ut_annotation_cache ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/annotations/ut_annotation_cache_info.sql b/source/core/annotations/ut_annotation_cache_info.sql index 167973a04..6248f4fbc 100644 --- a/source/core/annotations/ut_annotation_cache_info.sql +++ b/source/core/annotations/ut_annotation_cache_info.sql @@ -1,7 +1,7 @@ create table ut_annotation_cache_info ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index e1131b3bd..52184e17d 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_annotation_cache_manager as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_cache_manager.pks b/source/core/annotations/ut_annotation_cache_manager.pks index 1e9734934..55d109f91 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pks +++ b/source/core/annotations/ut_annotation_cache_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_annotation_cache_manager authid definer as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_cache_schema.sql b/source/core/annotations/ut_annotation_cache_schema.sql index 8889b9abf..b8ebaa40b 100644 --- a/source/core/annotations/ut_annotation_cache_schema.sql +++ b/source/core/annotations/ut_annotation_cache_schema.sql @@ -1,7 +1,7 @@ create table ut_annotation_cache_schema ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/annotations/ut_annotation_cache_seq.sql b/source/core/annotations/ut_annotation_cache_seq.sql index b371b382b..f0f1f17d7 100644 --- a/source/core/annotations/ut_annotation_cache_seq.sql +++ b/source/core/annotations/ut_annotation_cache_seq.sql @@ -1,7 +1,7 @@ create sequence ut_annotation_cache_seq /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 65f7b3e40..6d986473b 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_annotation_manager as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_manager.pks b/source/core/annotations/ut_annotation_manager.pks index 20fcd810f..637577d59 100644 --- a/source/core/annotations/ut_annotation_manager.pks +++ b/source/core/annotations/ut_annotation_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_annotation_manager authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_obj_cache_info.tps b/source/core/annotations/ut_annotation_obj_cache_info.tps index 1db3fd190..f7bdfa9a8 100644 --- a/source/core/annotations/ut_annotation_obj_cache_info.tps +++ b/source/core/annotations/ut_annotation_obj_cache_info.tps @@ -1,7 +1,7 @@ create type ut_annotation_obj_cache_info as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_objs_cache_info.tps b/source/core/annotations/ut_annotation_objs_cache_info.tps index fc96e7d25..eb69f41e9 100644 --- a/source/core/annotations/ut_annotation_objs_cache_info.tps +++ b/source/core/annotations/ut_annotation_objs_cache_info.tps @@ -1,7 +1,7 @@ create type ut_annotation_objs_cache_info as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 10bb76b3c..1176ffb6c 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -1,7 +1,7 @@ create or replace package body ut_annotation_parser as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotation_parser.pks b/source/core/annotations/ut_annotation_parser.pks index 2f474c883..91f1b7b47 100644 --- a/source/core/annotations/ut_annotation_parser.pks +++ b/source/core/annotations/ut_annotation_parser.pks @@ -1,7 +1,7 @@ create or replace package ut_annotation_parser authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_annotations.tps b/source/core/annotations/ut_annotations.tps index a6579d236..7669f008b 100644 --- a/source/core/annotations/ut_annotations.tps +++ b/source/core/annotations/ut_annotations.tps @@ -1,7 +1,7 @@ create type ut_annotations /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_trigger_annotation_parsing.trg b/source/core/annotations/ut_trigger_annotation_parsing.trg index 437b7742d..75caea5e8 100644 --- a/source/core/annotations/ut_trigger_annotation_parsing.trg +++ b/source/core/annotations/ut_trigger_annotation_parsing.trg @@ -2,6 +2,22 @@ create or replace trigger ut_trigger_annotation_parsing after create or alter or drop on database begin + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ if (ora_dict_obj_owner = UPPER('&&UT3_OWNER') and ora_dict_obj_name = 'UT3_TRIGGER_ALIVE' and ora_dict_obj_type = 'SYNONYM') diff --git a/source/core/annotations/ut_trigger_check.pkb b/source/core/annotations/ut_trigger_check.pkb index 34e43ba46..d533044bb 100644 --- a/source/core/annotations/ut_trigger_check.pkb +++ b/source/core/annotations/ut_trigger_check.pkb @@ -1,7 +1,7 @@ create or replace package body ut_trigger_check is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/annotations/ut_trigger_check.pks b/source/core/annotations/ut_trigger_check.pks index cee0b06fd..8c095c71a 100644 --- a/source/core/annotations/ut_trigger_check.pks +++ b/source/core/annotations/ut_trigger_check.pks @@ -1,7 +1,7 @@ create or replace package ut_trigger_check authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 7eb5a34c2..e8e6ed529 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage.pks b/source/core/coverage/ut_coverage.pks index 21f3b1f9e..6bcde8e64 100644 --- a/source/core/coverage/ut_coverage.pks +++ b/source/core/coverage/ut_coverage.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_block.pkb b/source/core/coverage/ut_coverage_block.pkb index a906b81a3..2d7e8bdac 100644 --- a/source/core/coverage/ut_coverage_block.pkb +++ b/source/core/coverage/ut_coverage_block.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_block is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_block.pks b/source/core/coverage/ut_coverage_block.pks index 01caca035..1bd9c2d39 100644 --- a/source/core/coverage/ut_coverage_block.pks +++ b/source/core/coverage/ut_coverage_block.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_block authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper.pkb b/source/core/coverage/ut_coverage_helper.pkb index e249b3381..16e0bf7a1 100644 --- a/source/core/coverage/ut_coverage_helper.pkb +++ b/source/core/coverage/ut_coverage_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper.pks b/source/core/coverage/ut_coverage_helper.pks index cd6ed9ec7..da4cba087 100644 --- a/source/core/coverage/ut_coverage_helper.pks +++ b/source/core/coverage/ut_coverage_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_helper authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index fb4d4812e..0cf009a10 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_helper_block is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper_block.pks b/source/core/coverage/ut_coverage_helper_block.pks index a147d9f4f..3ee1f266c 100644 --- a/source/core/coverage/ut_coverage_helper_block.pks +++ b/source/core/coverage/ut_coverage_helper_block.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_helper_block authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper_profiler.pkb b/source/core/coverage/ut_coverage_helper_profiler.pkb index f29291efb..7f6e6e51d 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pkb +++ b/source/core/coverage/ut_coverage_helper_profiler.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_helper_profiler is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_helper_profiler.pks b/source/core/coverage/ut_coverage_helper_profiler.pks index 0c54a83bf..2e56d10f7 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pks +++ b/source/core/coverage/ut_coverage_helper_profiler.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_helper_profiler authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_profiler.pkb b/source/core/coverage/ut_coverage_profiler.pkb index 663ceab7f..1dc40bcbc 100644 --- a/source/core/coverage/ut_coverage_profiler.pkb +++ b/source/core/coverage/ut_coverage_profiler.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_profiler is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_profiler.pks b/source/core/coverage/ut_coverage_profiler.pks index 9ce9a27f0..16145c34a 100644 --- a/source/core/coverage/ut_coverage_profiler.pks +++ b/source/core/coverage/ut_coverage_profiler.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_profiler authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_reporter_base.tpb b/source/core/coverage/ut_coverage_reporter_base.tpb index da2bd27ad..f28226428 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tpb +++ b/source/core/coverage/ut_coverage_reporter_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_reporter_base is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_reporter_base.tps b/source/core/coverage/ut_coverage_reporter_base.tps index 305c5d757..b917ea707 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tps +++ b/source/core/coverage/ut_coverage_reporter_base.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_reporter_base under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/coverage/ut_coverage_sources_tmp.sql b/source/core/coverage/ut_coverage_sources_tmp.sql index c091d5955..35eb05510 100644 --- a/source/core/coverage/ut_coverage_sources_tmp.sql +++ b/source/core/coverage/ut_coverage_sources_tmp.sql @@ -1,7 +1,7 @@ create global temporary table ut_coverage_sources_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/events/ut_event_item.tps b/source/core/events/ut_event_item.tps index c0ea653ea..bb4556e03 100644 --- a/source/core/events/ut_event_item.tps +++ b/source/core/events/ut_event_item.tps @@ -1,7 +1,7 @@ create or replace type ut_event_item authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/events/ut_event_listener.tps b/source/core/events/ut_event_listener.tps index bbcdbf218..ee34bb009 100644 --- a/source/core/events/ut_event_listener.tps +++ b/source/core/events/ut_event_listener.tps @@ -1,7 +1,7 @@ create or replace type ut_event_listener authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/events/ut_event_manager.pkb b/source/core/events/ut_event_manager.pkb index f51019421..0b80b5a98 100644 --- a/source/core/events/ut_event_manager.pkb +++ b/source/core/events/ut_event_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_event_manager as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/events/ut_event_manager.pks b/source/core/events/ut_event_manager.pks index 03b18b728..9cea89898 100644 --- a/source/core/events/ut_event_manager.pks +++ b/source/core/events/ut_event_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_event_manager authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index 20cec335e..f92827d28 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_output_buffer_base is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_buffer_base.tps b/source/core/output_buffers/ut_output_buffer_base.tps index f2d9ec686..9615cdc5e 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tps +++ b/source/core/output_buffers/ut_output_buffer_base.tps @@ -1,7 +1,7 @@ create or replace type ut_output_buffer_base force authid definer as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_buffer_info_tmp.sql b/source/core/output_buffers/ut_output_buffer_info_tmp.sql index af730d394..2aba5a55c 100644 --- a/source/core/output_buffers/ut_output_buffer_info_tmp.sql +++ b/source/core/output_buffers/ut_output_buffer_info_tmp.sql @@ -1,7 +1,7 @@ create table ut_output_buffer_info_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/output_buffers/ut_output_buffer_tmp.sql b/source/core/output_buffers/ut_output_buffer_tmp.sql index 1ab19e534..68b738d3f 100644 --- a/source/core/output_buffers/ut_output_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_buffer_tmp.sql @@ -1,7 +1,7 @@ create table ut_output_buffer_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tpb b/source/core/output_buffers/ut_output_bulk_buffer.tpb index cfc173e95..bc0ec6128 100644 --- a/source/core/output_buffers/ut_output_bulk_buffer.tpb +++ b/source/core/output_buffers/ut_output_bulk_buffer.tpb @@ -1,7 +1,7 @@ create or replace type body ut_output_bulk_buffer is /* utPLSQL - Version 3 - Copyright 2016 - 2023 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tps b/source/core/output_buffers/ut_output_bulk_buffer.tps index d74d4ee14..31d7271fa 100644 --- a/source/core/output_buffers/ut_output_bulk_buffer.tps +++ b/source/core/output_buffers/ut_output_bulk_buffer.tps @@ -1,7 +1,7 @@ create or replace type ut_output_bulk_buffer under ut_output_buffer_base ( /* utPLSQL - Version 3 - Copyright 2016 - 2023 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql index 9ff9f7413..fa61191ce 100644 --- a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql @@ -6,7 +6,7 @@ begin v_table_sql := 'create table ut_output_clob_buffer_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index 3d49ab08d..8f1cd3187 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -1,7 +1,7 @@ create or replace type body ut_output_clob_table_buffer is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tps b/source/core/output_buffers/ut_output_clob_table_buffer.tps index 191e64c01..2cfb2538b 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tps +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tps @@ -1,7 +1,7 @@ create or replace type ut_output_clob_table_buffer under ut_output_buffer_base ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_data_row.tps b/source/core/output_buffers/ut_output_data_row.tps index c5dd95e98..ecfde404a 100644 --- a/source/core/output_buffers/ut_output_data_row.tps +++ b/source/core/output_buffers/ut_output_data_row.tps @@ -1,7 +1,7 @@ create or replace type ut_output_data_row as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_data_rows.tps b/source/core/output_buffers/ut_output_data_rows.tps index 097e9beff..c505e2fbf 100644 --- a/source/core/output_buffers/ut_output_data_rows.tps +++ b/source/core/output_buffers/ut_output_data_rows.tps @@ -1,7 +1,7 @@ create or replace type ut_output_data_rows as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index e8e2442a7..5fbd39907 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -1,7 +1,7 @@ create or replace type body ut_output_table_buffer is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/output_buffers/ut_output_table_buffer.tps b/source/core/output_buffers/ut_output_table_buffer.tps index 154ce4de6..6c75421db 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tps +++ b/source/core/output_buffers/ut_output_table_buffer.tps @@ -1,7 +1,7 @@ create or replace type ut_output_table_buffer under ut_output_buffer_base ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/session_context/ut_session_context.pkb b/source/core/session_context/ut_session_context.pkb index a97505e9c..2443a350a 100644 --- a/source/core/session_context/ut_session_context.pkb +++ b/source/core/session_context/ut_session_context.pkb @@ -1,7 +1,7 @@ create or replace package body ut_session_context as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/session_context/ut_session_context.pks b/source/core/session_context/ut_session_context.pks index 63da3399e..8df2decee 100644 --- a/source/core/session_context/ut_session_context.pks +++ b/source/core/session_context/ut_session_context.pks @@ -1,7 +1,7 @@ create or replace package ut_session_context as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/session_context/ut_session_info.tpb b/source/core/session_context/ut_session_info.tpb index 7d469651a..d9d576fb9 100644 --- a/source/core/session_context/ut_session_info.tpb +++ b/source/core/session_context/ut_session_info.tpb @@ -1,7 +1,7 @@ create or replace type body ut_session_info as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/session_context/ut_session_info.tps b/source/core/session_context/ut_session_info.tps index 17e596d88..aeb3361c3 100644 --- a/source/core/session_context/ut_session_info.tps +++ b/source/core/session_context/ut_session_info.tps @@ -1,7 +1,7 @@ create or replace type ut_session_info under ut_event_listener ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_console_reporter_base.tpb b/source/core/types/ut_console_reporter_base.tpb index 909e9355a..282a52a9a 100644 --- a/source/core/types/ut_console_reporter_base.tpb +++ b/source/core/types/ut_console_reporter_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_console_reporter_base is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_console_reporter_base.tps b/source/core/types/ut_console_reporter_base.tps index a2c4b6b8c..077af7e37 100644 --- a/source/core/types/ut_console_reporter_base.tps +++ b/source/core/types/ut_console_reporter_base.tps @@ -1,7 +1,7 @@ create or replace type ut_console_reporter_base under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_coverage_options.tpb b/source/core/types/ut_coverage_options.tpb index a091802af..6c81af773 100644 --- a/source/core/types/ut_coverage_options.tpb +++ b/source/core/types/ut_coverage_options.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_options as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_coverage_options.tps b/source/core/types/ut_coverage_options.tps index a8e3d5129..3813232df 100644 --- a/source/core/types/ut_coverage_options.tps +++ b/source/core/types/ut_coverage_options.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_options force as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executable.tpb b/source/core/types/ut_executable.tpb index d2ce9b79d..c78cf4d77 100644 --- a/source/core/types/ut_executable.tpb +++ b/source/core/types/ut_executable.tpb @@ -1,7 +1,7 @@ create or replace type body ut_executable is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executable.tps b/source/core/types/ut_executable.tps index aaa5a3a72..7d04c4e41 100644 --- a/source/core/types/ut_executable.tps +++ b/source/core/types/ut_executable.tps @@ -1,7 +1,7 @@ create or replace type ut_executable under ut_event_item( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index fa5872e04..e816a1b1b 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -1,7 +1,7 @@ create or replace type body ut_executable_test as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executable_test.tps b/source/core/types/ut_executable_test.tps index 42b6080df..76f2d1c7d 100644 --- a/source/core/types/ut_executable_test.tps +++ b/source/core/types/ut_executable_test.tps @@ -1,7 +1,7 @@ create or replace type ut_executable_test authid current_user under ut_executable ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_executables.tps b/source/core/types/ut_executables.tps index d6d52b3d2..f5fbbdfad 100644 --- a/source/core/types/ut_executables.tps +++ b/source/core/types/ut_executables.tps @@ -1,7 +1,7 @@ create or replace type ut_executables as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_expectation_result.tpb b/source/core/types/ut_expectation_result.tpb index 0b3adf983..cf445b705 100644 --- a/source/core/types/ut_expectation_result.tpb +++ b/source/core/types/ut_expectation_result.tpb @@ -1,7 +1,7 @@ create or replace type body ut_expectation_result is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_expectation_result.tps b/source/core/types/ut_expectation_result.tps index d4b4c7548..5a430fe64 100644 --- a/source/core/types/ut_expectation_result.tps +++ b/source/core/types/ut_expectation_result.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation_result under ut_event_item( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_expectation_results.tps b/source/core/types/ut_expectation_results.tps index e5e4c6223..50cc046ec 100644 --- a/source/core/types/ut_expectation_results.tps +++ b/source/core/types/ut_expectation_results.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation_results as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_file_mapping.tpb b/source/core/types/ut_file_mapping.tpb index dab1e35c5..5b7133c56 100644 --- a/source/core/types/ut_file_mapping.tpb +++ b/source/core/types/ut_file_mapping.tpb @@ -1,7 +1,7 @@ create or replace type body ut_file_mapping as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_file_mapping.tps b/source/core/types/ut_file_mapping.tps index 941d95283..8fed2df00 100644 --- a/source/core/types/ut_file_mapping.tps +++ b/source/core/types/ut_file_mapping.tps @@ -1,7 +1,7 @@ create or replace type ut_file_mapping as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_file_mappings.tps b/source/core/types/ut_file_mappings.tps index 240fb8dd7..0e1653969 100644 --- a/source/core/types/ut_file_mappings.tps +++ b/source/core/types/ut_file_mappings.tps @@ -1,7 +1,7 @@ create or replace type ut_file_mappings as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_integer_list.tps b/source/core/types/ut_integer_list.tps index ec9a2a78f..00bce87c4 100644 --- a/source/core/types/ut_integer_list.tps +++ b/source/core/types/ut_integer_list.tps @@ -1,7 +1,7 @@ create or replace type ut_integer_list as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_key_value_pair.tps b/source/core/types/ut_key_value_pair.tps index 5a337e608..38dee5a7d 100644 --- a/source/core/types/ut_key_value_pair.tps +++ b/source/core/types/ut_key_value_pair.tps @@ -1,7 +1,7 @@ create or replace type ut_key_value_pair force as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_key_value_pairs.tps b/source/core/types/ut_key_value_pairs.tps index 24bdded36..327986e19 100644 --- a/source/core/types/ut_key_value_pairs.tps +++ b/source/core/types/ut_key_value_pairs.tps @@ -1,7 +1,7 @@ create or replace type ut_key_value_pairs as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_logical_suite.tpb b/source/core/types/ut_logical_suite.tpb index 036d40d51..ea9b42857 100644 --- a/source/core/types/ut_logical_suite.tpb +++ b/source/core/types/ut_logical_suite.tpb @@ -1,7 +1,7 @@ create or replace type body ut_logical_suite as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_logical_suite.tps b/source/core/types/ut_logical_suite.tps index c4f2f699b..ab2271e32 100644 --- a/source/core/types/ut_logical_suite.tps +++ b/source/core/types/ut_logical_suite.tps @@ -1,7 +1,7 @@ create or replace type ut_logical_suite force under ut_suite_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_object_name.tpb b/source/core/types/ut_object_name.tpb index 76acc15bf..e39231b0f 100644 --- a/source/core/types/ut_object_name.tpb +++ b/source/core/types/ut_object_name.tpb @@ -1,7 +1,7 @@ create or replace type body ut_object_name as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_object_name.tps b/source/core/types/ut_object_name.tps index 5f8f724c4..dc4fe2bca 100644 --- a/source/core/types/ut_object_name.tps +++ b/source/core/types/ut_object_name.tps @@ -1,7 +1,7 @@ create or replace type ut_object_name as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_object_names.tps b/source/core/types/ut_object_names.tps index 03830be17..2b42cce21 100644 --- a/source/core/types/ut_object_names.tps +++ b/source/core/types/ut_object_names.tps @@ -1,7 +1,7 @@ create or replace type ut_object_names as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_output_reporter_base.tpb b/source/core/types/ut_output_reporter_base.tpb index 48970be5a..fec4ebfab 100644 --- a/source/core/types/ut_output_reporter_base.tpb +++ b/source/core/types/ut_output_reporter_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_output_reporter_base is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_output_reporter_base.tps b/source/core/types/ut_output_reporter_base.tps index 21eed9957..f5827a97d 100644 --- a/source/core/types/ut_output_reporter_base.tps +++ b/source/core/types/ut_output_reporter_base.tps @@ -1,7 +1,7 @@ create or replace type ut_output_reporter_base under ut_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_path_item.tpb b/source/core/types/ut_path_item.tpb index 6cdb2b8ad..685178987 100644 --- a/source/core/types/ut_path_item.tpb +++ b/source/core/types/ut_path_item.tpb @@ -1,7 +1,7 @@ create or replace type body ut_path_item as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_path_item.tps b/source/core/types/ut_path_item.tps index c8ec81be5..5946cacbf 100644 --- a/source/core/types/ut_path_item.tps +++ b/source/core/types/ut_path_item.tps @@ -1,7 +1,7 @@ create or replace type ut_path_item as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_path_items.tps b/source/core/types/ut_path_items.tps index 0c87cf28c..7ae04e0b9 100644 --- a/source/core/types/ut_path_items.tps +++ b/source/core/types/ut_path_items.tps @@ -1,7 +1,7 @@ create or replace type ut_path_items as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporter_base.tpb b/source/core/types/ut_reporter_base.tpb index 017dc8971..445d9d351 100644 --- a/source/core/types/ut_reporter_base.tpb +++ b/source/core/types/ut_reporter_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_reporter_base is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporter_base.tps b/source/core/types/ut_reporter_base.tps index de157136e..9df353060 100644 --- a/source/core/types/ut_reporter_base.tps +++ b/source/core/types/ut_reporter_base.tps @@ -1,7 +1,7 @@ create or replace type ut_reporter_base under ut_event_listener ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporter_info.tps b/source/core/types/ut_reporter_info.tps index f09c42e07..3491f7679 100644 --- a/source/core/types/ut_reporter_info.tps +++ b/source/core/types/ut_reporter_info.tps @@ -1,7 +1,7 @@ create or replace type ut_reporter_info as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporters.tps b/source/core/types/ut_reporters.tps index a2802bb26..ab6439dce 100644 --- a/source/core/types/ut_reporters.tps +++ b/source/core/types/ut_reporters.tps @@ -1,7 +1,7 @@ create or replace type ut_reporters as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_reporters_info.tps b/source/core/types/ut_reporters_info.tps index 82c264f36..3639f4c2c 100644 --- a/source/core/types/ut_reporters_info.tps +++ b/source/core/types/ut_reporters_info.tps @@ -1,7 +1,7 @@ create or replace type ut_reporters_info as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_results_counter.tpb b/source/core/types/ut_results_counter.tpb index 811389e0e..87fd83cf9 100644 --- a/source/core/types/ut_results_counter.tpb +++ b/source/core/types/ut_results_counter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_results_counter as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_results_counter.tps b/source/core/types/ut_results_counter.tps index 913ae0967..62b3d9ffd 100644 --- a/source/core/types/ut_results_counter.tps +++ b/source/core/types/ut_results_counter.tps @@ -1,7 +1,7 @@ create or replace type ut_results_counter as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_run.tpb b/source/core/types/ut_run.tpb index 660c88791..0956be32d 100644 --- a/source/core/types/ut_run.tpb +++ b/source/core/types/ut_run.tpb @@ -1,7 +1,7 @@ create or replace type body ut_run as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_run.tps b/source/core/types/ut_run.tps index 1878a2d46..ef3631082 100644 --- a/source/core/types/ut_run.tps +++ b/source/core/types/ut_run.tps @@ -1,7 +1,7 @@ create or replace type ut_run under ut_suite_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_run_info.tpb b/source/core/types/ut_run_info.tpb index 6edc0f109..1370de3cc 100644 --- a/source/core/types/ut_run_info.tpb +++ b/source/core/types/ut_run_info.tpb @@ -1,7 +1,7 @@ create or replace type body ut_run_info as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_run_info.tps b/source/core/types/ut_run_info.tps index 4a3da691f..df82c380d 100644 --- a/source/core/types/ut_run_info.tps +++ b/source/core/types/ut_run_info.tps @@ -1,7 +1,7 @@ create or replace type ut_run_info under ut_event_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_stack.tpb b/source/core/types/ut_stack.tpb index b5f4e8747..da0c371a6 100644 --- a/source/core/types/ut_stack.tpb +++ b/source/core/types/ut_stack.tpb @@ -1,7 +1,7 @@ create or replace type body ut_stack as /* utPLSQL - Version 3 - Copyright 2016 - 2023 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_stack.tps b/source/core/types/ut_stack.tps index 23112fdde..5a5f90263 100644 --- a/source/core/types/ut_stack.tps +++ b/source/core/types/ut_stack.tps @@ -3,7 +3,7 @@ create or replace type ut_stack as object ( tokens ut_varchar2_list, /* utPLSQL - Version 3 - Copyright 2016 - 2023 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite.tpb b/source/core/types/ut_suite.tpb index e3a4687d8..9558565ed 100644 --- a/source/core/types/ut_suite.tpb +++ b/source/core/types/ut_suite.tpb @@ -1,7 +1,7 @@ create or replace type body ut_suite as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite.tps b/source/core/types/ut_suite.tps index ff7f3e171..199e05ea4 100644 --- a/source/core/types/ut_suite.tps +++ b/source/core/types/ut_suite.tps @@ -1,7 +1,7 @@ create or replace type ut_suite under ut_logical_suite ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_cache_row.tps b/source/core/types/ut_suite_cache_row.tps index c147a8757..f294b3697 100644 --- a/source/core/types/ut_suite_cache_row.tps +++ b/source/core/types/ut_suite_cache_row.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_cache_row as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_cache_rows.tps b/source/core/types/ut_suite_cache_rows.tps index 9b6919df5..c69c8672f 100644 --- a/source/core/types/ut_suite_cache_rows.tps +++ b/source/core/types/ut_suite_cache_rows.tps @@ -1,7 +1,7 @@ create type ut_suite_cache_rows as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_context.tpb b/source/core/types/ut_suite_context.tpb index be92e6fc9..52e57924a 100644 --- a/source/core/types/ut_suite_context.tpb +++ b/source/core/types/ut_suite_context.tpb @@ -1,7 +1,7 @@ create or replace type body ut_suite_context as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_context.tps b/source/core/types/ut_suite_context.tps index 5e3d20f87..51d318235 100644 --- a/source/core/types/ut_suite_context.tps +++ b/source/core/types/ut_suite_context.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_context under ut_suite ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_item.tpb b/source/core/types/ut_suite_item.tpb index 648f10dd1..965d2416e 100644 --- a/source/core/types/ut_suite_item.tpb +++ b/source/core/types/ut_suite_item.tpb @@ -1,7 +1,7 @@ create or replace type body ut_suite_item as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_item.tps b/source/core/types/ut_suite_item.tps index 8184f2a63..8ba3c6183 100644 --- a/source/core/types/ut_suite_item.tps +++ b/source/core/types/ut_suite_item.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_item force under ut_event_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_suite_items.tps b/source/core/types/ut_suite_items.tps index 615283446..ee3466c5d 100644 --- a/source/core/types/ut_suite_items.tps +++ b/source/core/types/ut_suite_items.tps @@ -1,7 +1,7 @@ create or replace type ut_suite_items as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_test.tpb b/source/core/types/ut_test.tpb index 946f8990d..21ca44713 100644 --- a/source/core/types/ut_test.tpb +++ b/source/core/types/ut_test.tpb @@ -1,7 +1,7 @@ create or replace type body ut_test as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_test.tps b/source/core/types/ut_test.tps index dbba64961..215e3e9d6 100644 --- a/source/core/types/ut_test.tps +++ b/source/core/types/ut_test.tps @@ -1,7 +1,7 @@ create or replace type ut_test force under ut_suite_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_varchar2_list.tps b/source/core/types/ut_varchar2_list.tps index f0b5df509..95a5545a8 100644 --- a/source/core/types/ut_varchar2_list.tps +++ b/source/core/types/ut_varchar2_list.tps @@ -1,7 +1,7 @@ create or replace type ut_varchar2_list as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/types/ut_varchar2_rows.tps b/source/core/types/ut_varchar2_rows.tps index e7fa29c29..c6f05df86 100644 --- a/source/core/types/ut_varchar2_rows.tps +++ b/source/core/types/ut_varchar2_rows.tps @@ -1,7 +1,7 @@ create or replace type ut_varchar2_rows as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_dbms_output_cache.sql b/source/core/ut_dbms_output_cache.sql index e61b403c8..802f30942 100644 --- a/source/core/ut_dbms_output_cache.sql +++ b/source/core/ut_dbms_output_cache.sql @@ -1,15 +1,16 @@ /* -utPLSQL - Version 3 -Copyright 2016 - 2021 utPLSQL Project -Licensed under the Apache License, Version 2.0 (the "License"): -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - http://www.apache.org/licenses/LICENSE-2.0 -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + http://www.apache.org/licenses/LICENSE-2.0 + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. */ /* * This table is not a global temporary table as it needs to allow cross-session data exchange diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index c165a9ee5..654a838ca 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -1,7 +1,7 @@ create or replace package body ut_expectation_processor as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_expectation_processor.pks b/source/core/ut_expectation_processor.pks index dd9187526..1837188eb 100644 --- a/source/core/ut_expectation_processor.pks +++ b/source/core/ut_expectation_processor.pks @@ -1,7 +1,7 @@ create or replace package ut_expectation_processor authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_file_mapper.pkb b/source/core/ut_file_mapper.pkb index 425360533..077319d76 100644 --- a/source/core/ut_file_mapper.pkb +++ b/source/core/ut_file_mapper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_file_mapper is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_file_mapper.pks b/source/core/ut_file_mapper.pks index adc4c983f..71e045d7e 100644 --- a/source/core/ut_file_mapper.pks +++ b/source/core/ut_file_mapper.pks @@ -1,7 +1,7 @@ create or replace package ut_file_mapper authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index 360b7b97d..aec9a3c8d 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -1,7 +1,7 @@ create or replace package body ut_metadata as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_metadata.pks b/source/core/ut_metadata.pks index 27bfa5d30..31cf4889b 100644 --- a/source/core/ut_metadata.pks +++ b/source/core/ut_metadata.pks @@ -1,7 +1,7 @@ create or replace package ut_metadata authid current_user as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_savepoint_seq.sql b/source/core/ut_savepoint_seq.sql index 5b0cda35e..2026ab0e3 100644 --- a/source/core/ut_savepoint_seq.sql +++ b/source/core/ut_savepoint_seq.sql @@ -1,7 +1,7 @@ create sequence ut_savepoint_seq /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index ebb113370..2ebdb980c 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -1,7 +1,7 @@ create or replace package body ut_suite_builder is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_builder.pks b/source/core/ut_suite_builder.pks index 352601a6d..7e43a720e 100644 --- a/source/core/ut_suite_builder.pks +++ b/source/core/ut_suite_builder.pks @@ -1,7 +1,7 @@ create or replace package ut_suite_builder authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_cache.sql b/source/core/ut_suite_cache.sql index 182caabd0..1d7389e9f 100644 --- a/source/core/ut_suite_cache.sql +++ b/source/core/ut_suite_cache.sql @@ -1,7 +1,7 @@ create table ut_suite_cache /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index e5fdae7ac..fb7c2c888 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_suite_cache_manager is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 81b1e0136..bd236678d 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_suite_cache_manager authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_cache_package.sql b/source/core/ut_suite_cache_package.sql index 7a146ff83..40b7b8dec 100644 --- a/source/core/ut_suite_cache_package.sql +++ b/source/core/ut_suite_cache_package.sql @@ -1,7 +1,7 @@ create table ut_suite_cache_package ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_cache_schema.sql b/source/core/ut_suite_cache_schema.sql index 636816e65..cace332e3 100644 --- a/source/core/ut_suite_cache_schema.sql +++ b/source/core/ut_suite_cache_schema.sql @@ -1,7 +1,7 @@ create table ut_suite_cache_schema ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_cache_seq.sql b/source/core/ut_suite_cache_seq.sql index e1e560286..020c25c4d 100644 --- a/source/core/ut_suite_cache_seq.sql +++ b/source/core/ut_suite_cache_seq.sql @@ -1,7 +1,7 @@ create sequence ut_suite_cache_seq /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index c418de638..ad7f27f59 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -1,7 +1,7 @@ create or replace package body ut_suite_manager is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 07539139a..8ac7cc8ad 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -1,7 +1,7 @@ create or replace package ut_suite_manager authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index 2d9436301..353793bc5 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -1,7 +1,7 @@ create or replace package body ut_suite_tag_filter is /* utPLSQL - Version 3 - Copyright 2016 - 2023 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_suite_tag_filter.pks b/source/core/ut_suite_tag_filter.pks index e824ae275..0493bd194 100644 --- a/source/core/ut_suite_tag_filter.pks +++ b/source/core/ut_suite_tag_filter.pks @@ -1,7 +1,7 @@ create or replace package ut_suite_tag_filter authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2023 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 81d47221b..6582aec3d 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -1,7 +1,7 @@ create or replace package body ut_utils is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 27ad1823b..470fcd275 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -1,7 +1,7 @@ create or replace package ut_utils authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_grants.sql b/source/create_grants.sql index 2cdea9970..0656ec82f 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index d839e11b7..3cc642921 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_synonyms_and_grants_for_public.sql b/source/create_synonyms_and_grants_for_public.sql index 050162d72..25f14217e 100644 --- a/source/create_synonyms_and_grants_for_public.sql +++ b/source/create_synonyms_and_grants_for_public.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_user_grants.sql b/source/create_user_grants.sql index 83e594884..c1b81efa4 100644 --- a/source/create_user_grants.sql +++ b/source/create_user_grants.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_user_synonyms.sql b/source/create_user_synonyms.sql index a1e7a6acc..7b0e49553 100644 --- a/source/create_user_synonyms.sql +++ b/source/create_user_synonyms.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/create_utplsql_owner.sql b/source/create_utplsql_owner.sql index d7e4f3040..a5b70ffda 100644 --- a/source/create_utplsql_owner.sql +++ b/source/create_utplsql_owner.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/define_ut3_owner_param.sql b/source/define_ut3_owner_param.sql index 259b49712..192e810b7 100644 --- a/source/define_ut3_owner_param.sql +++ b/source/define_ut3_owner_param.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_compound_data_diff_tmp.sql b/source/expectations/data_values/ut_compound_data_diff_tmp.sql index c10e8d2e8..edd27f766 100644 --- a/source/expectations/data_values/ut_compound_data_diff_tmp.sql +++ b/source/expectations/data_values/ut_compound_data_diff_tmp.sql @@ -1,7 +1,7 @@ create global temporary table ut_compound_data_diff_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 875ec760a..42feb2a47 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_compound_data_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_compound_data_helper.pks b/source/expectations/data_values/ut_compound_data_helper.pks index 451cd9bac..dd2e2ec3d 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pks +++ b/source/expectations/data_values/ut_compound_data_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_compound_data_helper authid definer is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_compound_data_tmp.sql b/source/expectations/data_values/ut_compound_data_tmp.sql index 1bfa77fca..01cedd97b 100644 --- a/source/expectations/data_values/ut_compound_data_tmp.sql +++ b/source/expectations/data_values/ut_compound_data_tmp.sql @@ -1,7 +1,7 @@ create global temporary table ut_compound_data_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/expectations/data_values/ut_compound_data_value.tpb b/source/expectations/data_values/ut_compound_data_value.tpb index 2c52ff8fa..5fd3154b1 100644 --- a/source/expectations/data_values/ut_compound_data_value.tpb +++ b/source/expectations/data_values/ut_compound_data_value.tpb @@ -1,7 +1,7 @@ create or replace type body ut_compound_data_value as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_compound_data_value.tps b/source/expectations/data_values/ut_compound_data_value.tps index c14dadceb..ca2206e2a 100644 --- a/source/expectations/data_values/ut_compound_data_value.tps +++ b/source/expectations/data_values/ut_compound_data_value.tps @@ -1,7 +1,7 @@ create or replace type ut_compound_data_value force under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_cursor_column.tpb b/source/expectations/data_values/ut_cursor_column.tpb index a9fb6b0f4..13fbb86b7 100644 --- a/source/expectations/data_values/ut_cursor_column.tpb +++ b/source/expectations/data_values/ut_cursor_column.tpb @@ -1,5 +1,21 @@ create or replace type body ut_cursor_column as - + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + member procedure init( self in out nocopy ut_cursor_column, a_col_name varchar2, a_col_schema_name varchar2, diff --git a/source/expectations/data_values/ut_cursor_column.tps b/source/expectations/data_values/ut_cursor_column.tps index 77bf78f01..98ca78b6e 100644 --- a/source/expectations/data_values/ut_cursor_column.tps +++ b/source/expectations/data_values/ut_cursor_column.tps @@ -1,7 +1,7 @@ create or replace type ut_cursor_column authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_cursor_column_tab.tps b/source/expectations/data_values/ut_cursor_column_tab.tps index 106023d96..258624691 100644 --- a/source/expectations/data_values/ut_cursor_column_tab.tps +++ b/source/expectations/data_values/ut_cursor_column_tab.tps @@ -1,7 +1,7 @@ create or replace type ut_cursor_column_tab as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_cursor_details.tpb b/source/expectations/data_values/ut_cursor_details.tpb index b823ff944..cce0751d1 100644 --- a/source/expectations/data_values/ut_cursor_details.tpb +++ b/source/expectations/data_values/ut_cursor_details.tpb @@ -1,4 +1,21 @@ create or replace type body ut_cursor_details as + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + member function equals( a_other ut_cursor_details, a_match_options ut_matcher_options ) return boolean is l_diffs integer; diff --git a/source/expectations/data_values/ut_cursor_details.tps b/source/expectations/data_values/ut_cursor_details.tps index e7f9405eb..981fda8e5 100644 --- a/source/expectations/data_values/ut_cursor_details.tps +++ b/source/expectations/data_values/ut_cursor_details.tps @@ -1,7 +1,7 @@ create or replace type ut_cursor_details authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value.tpb b/source/expectations/data_values/ut_data_value.tpb index 6b1763dd0..6eb352b77 100644 --- a/source/expectations/data_values/ut_data_value.tpb +++ b/source/expectations/data_values/ut_data_value.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value.tps b/source/expectations/data_values/ut_data_value.tps index beda3d911..91a07e463 100644 --- a/source/expectations/data_values/ut_data_value.tps +++ b/source/expectations/data_values/ut_data_value.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value force authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_anydata.tpb b/source/expectations/data_values/ut_data_value_anydata.tpb index f6fbdc840..189d2e032 100644 --- a/source/expectations/data_values/ut_data_value_anydata.tpb +++ b/source/expectations/data_values/ut_data_value_anydata.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_anydata as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_anydata.tps b/source/expectations/data_values/ut_data_value_anydata.tps index 60dba5515..ee9725d58 100644 --- a/source/expectations/data_values/ut_data_value_anydata.tps +++ b/source/expectations/data_values/ut_data_value_anydata.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_anydata under ut_data_value_refcursor( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_blob.tpb b/source/expectations/data_values/ut_data_value_blob.tpb index e145a8d4f..42e35fc55 100644 --- a/source/expectations/data_values/ut_data_value_blob.tpb +++ b/source/expectations/data_values/ut_data_value_blob.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_blob as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_blob.tps b/source/expectations/data_values/ut_data_value_blob.tps index 6df3f3273..08813371e 100644 --- a/source/expectations/data_values/ut_data_value_blob.tps +++ b/source/expectations/data_values/ut_data_value_blob.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_blob under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_boolean.tpb b/source/expectations/data_values/ut_data_value_boolean.tpb index 867c3c19c..84af1c34c 100644 --- a/source/expectations/data_values/ut_data_value_boolean.tpb +++ b/source/expectations/data_values/ut_data_value_boolean.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_boolean as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_boolean.tps b/source/expectations/data_values/ut_data_value_boolean.tps index e25b6e0fd..4d7af837b 100644 --- a/source/expectations/data_values/ut_data_value_boolean.tps +++ b/source/expectations/data_values/ut_data_value_boolean.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_boolean under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_clob.tpb b/source/expectations/data_values/ut_data_value_clob.tpb index f8a53a035..2dd00c023 100644 --- a/source/expectations/data_values/ut_data_value_clob.tpb +++ b/source/expectations/data_values/ut_data_value_clob.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_clob as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_clob.tps b/source/expectations/data_values/ut_data_value_clob.tps index 6869798d1..abcc635c9 100644 --- a/source/expectations/data_values/ut_data_value_clob.tps +++ b/source/expectations/data_values/ut_data_value_clob.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_clob under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_date.tpb b/source/expectations/data_values/ut_data_value_date.tpb index 20424d193..dc1c4d22f 100644 --- a/source/expectations/data_values/ut_data_value_date.tpb +++ b/source/expectations/data_values/ut_data_value_date.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_date as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_date.tps b/source/expectations/data_values/ut_data_value_date.tps index f64a577e0..8db1850c2 100644 --- a/source/expectations/data_values/ut_data_value_date.tps +++ b/source/expectations/data_values/ut_data_value_date.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_date under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tpb b/source/expectations/data_values/ut_data_value_dsinterval.tpb index 026d4970f..bcfb48a2b 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tpb +++ b/source/expectations/data_values/ut_data_value_dsinterval.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_dsinterval as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tps b/source/expectations/data_values/ut_data_value_dsinterval.tps index 6f5cb708c..5add4adf9 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tps +++ b/source/expectations/data_values/ut_data_value_dsinterval.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_dsinterval under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_json.tpb b/source/expectations/data_values/ut_data_value_json.tpb index b703af181..9f65ef618 100644 --- a/source/expectations/data_values/ut_data_value_json.tpb +++ b/source/expectations/data_values/ut_data_value_json.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_json as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_json.tps b/source/expectations/data_values/ut_data_value_json.tps index 3b77e54eb..46a78e00e 100644 --- a/source/expectations/data_values/ut_data_value_json.tps +++ b/source/expectations/data_values/ut_data_value_json.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_json under ut_compound_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_number.tpb b/source/expectations/data_values/ut_data_value_number.tpb index 382e6e9aa..53b8ce413 100644 --- a/source/expectations/data_values/ut_data_value_number.tpb +++ b/source/expectations/data_values/ut_data_value_number.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_number as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_number.tps b/source/expectations/data_values/ut_data_value_number.tps index 86d68f356..914252b9f 100644 --- a/source/expectations/data_values/ut_data_value_number.tps +++ b/source/expectations/data_values/ut_data_value_number.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_number under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_refcursor.tpb b/source/expectations/data_values/ut_data_value_refcursor.tpb index a4f0cf7a0..ee1408b56 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tpb +++ b/source/expectations/data_values/ut_data_value_refcursor.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_refcursor as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_refcursor.tps b/source/expectations/data_values/ut_data_value_refcursor.tps index 594695e32..7d336bd78 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tps +++ b/source/expectations/data_values/ut_data_value_refcursor.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_refcursor under ut_compound_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp.tpb b/source/expectations/data_values/ut_data_value_timestamp.tpb index 318f799a3..bfb0ab734 100644 --- a/source/expectations/data_values/ut_data_value_timestamp.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_timestamp as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp.tps b/source/expectations/data_values/ut_data_value_timestamp.tps index c047e3c79..5c1f0b879 100644 --- a/source/expectations/data_values/ut_data_value_timestamp.tps +++ b/source/expectations/data_values/ut_data_value_timestamp.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_timestamp under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb index 6127de5f1..ba1610d31 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_timestamp_ltz as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp_ltz.tps b/source/expectations/data_values/ut_data_value_timestamp_ltz.tps index 7bb296bc9..51bf615af 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_ltz.tps +++ b/source/expectations/data_values/ut_data_value_timestamp_ltz.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_timestamp_ltz under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb index d5d5cdd13..ea0d28090 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_timestamp_tz as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_timestamp_tz.tps b/source/expectations/data_values/ut_data_value_timestamp_tz.tps index 01cf11124..435dc8df0 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_tz.tps +++ b/source/expectations/data_values/ut_data_value_timestamp_tz.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_timestamp_tz under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_varchar2.tpb b/source/expectations/data_values/ut_data_value_varchar2.tpb index d04398697..923ef7b9e 100644 --- a/source/expectations/data_values/ut_data_value_varchar2.tpb +++ b/source/expectations/data_values/ut_data_value_varchar2.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_varchar2 as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_varchar2.tps b/source/expectations/data_values/ut_data_value_varchar2.tps index 3fbeb378b..8db175d90 100644 --- a/source/expectations/data_values/ut_data_value_varchar2.tps +++ b/source/expectations/data_values/ut_data_value_varchar2.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_varchar2 under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_xmltype.tpb b/source/expectations/data_values/ut_data_value_xmltype.tpb index 4b21a8937..dc518da54 100644 --- a/source/expectations/data_values/ut_data_value_xmltype.tpb +++ b/source/expectations/data_values/ut_data_value_xmltype.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_xmltype as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_xmltype.tps b/source/expectations/data_values/ut_data_value_xmltype.tps index 9ba738b88..3929b4d7c 100644 --- a/source/expectations/data_values/ut_data_value_xmltype.tps +++ b/source/expectations/data_values/ut_data_value_xmltype.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_xmltype under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_yminterval.tpb b/source/expectations/data_values/ut_data_value_yminterval.tpb index a3a1e7a2f..abba0bc20 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tpb +++ b/source/expectations/data_values/ut_data_value_yminterval.tpb @@ -1,7 +1,7 @@ create or replace type body ut_data_value_yminterval as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_data_value_yminterval.tps b/source/expectations/data_values/ut_data_value_yminterval.tps index c9ad2e776..734ed545d 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tps +++ b/source/expectations/data_values/ut_data_value_yminterval.tps @@ -1,7 +1,7 @@ create or replace type ut_data_value_yminterval under ut_data_value( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_json_data_diff_tmp.sql b/source/expectations/data_values/ut_json_data_diff_tmp.sql index 5ff3440d8..4eda07d7c 100644 --- a/source/expectations/data_values/ut_json_data_diff_tmp.sql +++ b/source/expectations/data_values/ut_json_data_diff_tmp.sql @@ -1,7 +1,7 @@ create global temporary table ut_json_data_diff_tmp( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/source/expectations/data_values/ut_json_leaf.tpb b/source/expectations/data_values/ut_json_leaf.tpb index 83f1009ef..b7a20f11b 100644 --- a/source/expectations/data_values/ut_json_leaf.tpb +++ b/source/expectations/data_values/ut_json_leaf.tpb @@ -1,5 +1,21 @@ create or replace type body ut_json_leaf as - + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + member procedure init( self in out nocopy ut_json_leaf, a_element_name varchar2, a_element_value varchar2,a_parent_name varchar2, a_access_path varchar2, a_hierarchy_level integer, a_index_position integer, a_json_type in varchar2, diff --git a/source/expectations/data_values/ut_json_leaf.tps b/source/expectations/data_values/ut_json_leaf.tps index 8aa8afd6a..70d4df71d 100644 --- a/source/expectations/data_values/ut_json_leaf.tps +++ b/source/expectations/data_values/ut_json_leaf.tps @@ -1,7 +1,7 @@ create or replace type ut_json_leaf authid current_user as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_json_leaf_tab.tps b/source/expectations/data_values/ut_json_leaf_tab.tps index 395ab5d9e..10fd3eef6 100644 --- a/source/expectations/data_values/ut_json_leaf_tab.tps +++ b/source/expectations/data_values/ut_json_leaf_tab.tps @@ -1,7 +1,7 @@ create or replace type ut_json_leaf_tab as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_json_tree_details.tpb b/source/expectations/data_values/ut_json_tree_details.tpb index a333ea71c..f82aac5a0 100644 --- a/source/expectations/data_values/ut_json_tree_details.tpb +++ b/source/expectations/data_values/ut_json_tree_details.tpb @@ -1,4 +1,20 @@ create or replace type body ut_json_tree_details as + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ member function get_json_type(a_json_piece json_element_t) return varchar2 is begin diff --git a/source/expectations/data_values/ut_json_tree_details.tps b/source/expectations/data_values/ut_json_tree_details.tps index 20ac2fdcc..9c37f99ea 100644 --- a/source/expectations/data_values/ut_json_tree_details.tps +++ b/source/expectations/data_values/ut_json_tree_details.tps @@ -1,7 +1,7 @@ create or replace type ut_json_tree_details force as object ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_key_anyval_pair.tps b/source/expectations/data_values/ut_key_anyval_pair.tps index d1068f109..7935ffa09 100644 --- a/source/expectations/data_values/ut_key_anyval_pair.tps +++ b/source/expectations/data_values/ut_key_anyval_pair.tps @@ -1,7 +1,7 @@ create or replace type ut_key_anyval_pair force as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_key_anyval_pairs.tps b/source/expectations/data_values/ut_key_anyval_pairs.tps index 7e10bf50f..2cc1ff225 100644 --- a/source/expectations/data_values/ut_key_anyval_pairs.tps +++ b/source/expectations/data_values/ut_key_anyval_pairs.tps @@ -1,7 +1,7 @@ create or replace type ut_key_anyval_pairs as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_key_anyvalues.tpb b/source/expectations/data_values/ut_key_anyvalues.tpb index d30d8a841..67b877874 100644 --- a/source/expectations/data_values/ut_key_anyvalues.tpb +++ b/source/expectations/data_values/ut_key_anyvalues.tpb @@ -1,7 +1,7 @@ create or replace type body ut_key_anyvalues as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/data_values/ut_key_anyvalues.tps b/source/expectations/data_values/ut_key_anyvalues.tps index 8c672bd00..df14a8101 100644 --- a/source/expectations/data_values/ut_key_anyvalues.tps +++ b/source/expectations/data_values/ut_key_anyvalues.tps @@ -1,7 +1,7 @@ create or replace type ut_key_anyvalues under ut_event_item ( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_between.tpb b/source/expectations/matchers/ut_be_between.tpb index 6aea96f55..787be701b 100644 --- a/source/expectations/matchers/ut_be_between.tpb +++ b/source/expectations/matchers/ut_be_between.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_between is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_between.tps b/source/expectations/matchers/ut_be_between.tps index 9e984085b..a08d7a823 100644 --- a/source/expectations/matchers/ut_be_between.tps +++ b/source/expectations/matchers/ut_be_between.tps @@ -1,7 +1,7 @@ create or replace type ut_be_between under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_empty.tpb b/source/expectations/matchers/ut_be_empty.tpb index e5e02f6b2..bac77166a 100644 --- a/source/expectations/matchers/ut_be_empty.tpb +++ b/source/expectations/matchers/ut_be_empty.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_empty as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_empty.tps b/source/expectations/matchers/ut_be_empty.tps index 9e9f899d0..948e771a3 100644 --- a/source/expectations/matchers/ut_be_empty.tps +++ b/source/expectations/matchers/ut_be_empty.tps @@ -1,7 +1,7 @@ create or replace type ut_be_empty under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_false.tpb b/source/expectations/matchers/ut_be_false.tpb index 4cc88600a..5a5421e8b 100644 --- a/source/expectations/matchers/ut_be_false.tpb +++ b/source/expectations/matchers/ut_be_false.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_false as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_false.tps b/source/expectations/matchers/ut_be_false.tps index ede510719..b6906ece8 100644 --- a/source/expectations/matchers/ut_be_false.tps +++ b/source/expectations/matchers/ut_be_false.tps @@ -1,7 +1,7 @@ create or replace type ut_be_false under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_greater_or_equal.tpb b/source/expectations/matchers/ut_be_greater_or_equal.tpb index 1c2a19c09..fbd165b1d 100644 --- a/source/expectations/matchers/ut_be_greater_or_equal.tpb +++ b/source/expectations/matchers/ut_be_greater_or_equal.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_greater_or_equal AS /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_greater_or_equal.tps b/source/expectations/matchers/ut_be_greater_or_equal.tps index b3ab54ff1..e87740134 100644 --- a/source/expectations/matchers/ut_be_greater_or_equal.tps +++ b/source/expectations/matchers/ut_be_greater_or_equal.tps @@ -1,7 +1,7 @@ create or replace type ut_be_greater_or_equal under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_greater_than.tpb b/source/expectations/matchers/ut_be_greater_than.tpb index 9cce79119..f59c2f0be 100644 --- a/source/expectations/matchers/ut_be_greater_than.tpb +++ b/source/expectations/matchers/ut_be_greater_than.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_greater_than AS /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_greater_than.tps b/source/expectations/matchers/ut_be_greater_than.tps index a5a44692d..b66009bab 100644 --- a/source/expectations/matchers/ut_be_greater_than.tps +++ b/source/expectations/matchers/ut_be_greater_than.tps @@ -1,7 +1,7 @@ create or replace type ut_be_greater_than under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_less_or_equal.tpb b/source/expectations/matchers/ut_be_less_or_equal.tpb index 6acec1dda..24c1f9c96 100644 --- a/source/expectations/matchers/ut_be_less_or_equal.tpb +++ b/source/expectations/matchers/ut_be_less_or_equal.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_less_or_equal AS /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_less_or_equal.tps b/source/expectations/matchers/ut_be_less_or_equal.tps index 118611a41..5114644b0 100644 --- a/source/expectations/matchers/ut_be_less_or_equal.tps +++ b/source/expectations/matchers/ut_be_less_or_equal.tps @@ -1,7 +1,7 @@ create or replace type ut_be_less_or_equal under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_less_than.tpb b/source/expectations/matchers/ut_be_less_than.tpb index 7608e4917..011ad392f 100644 --- a/source/expectations/matchers/ut_be_less_than.tpb +++ b/source/expectations/matchers/ut_be_less_than.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_less_than as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_less_than.tps b/source/expectations/matchers/ut_be_less_than.tps index b652de789..81a25144d 100644 --- a/source/expectations/matchers/ut_be_less_than.tps +++ b/source/expectations/matchers/ut_be_less_than.tps @@ -1,7 +1,7 @@ create or replace type ut_be_less_than under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_like.tpb b/source/expectations/matchers/ut_be_like.tpb index 6865c2942..953adbe5b 100644 --- a/source/expectations/matchers/ut_be_like.tpb +++ b/source/expectations/matchers/ut_be_like.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_like as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_like.tps b/source/expectations/matchers/ut_be_like.tps index dae93a1d9..1d907ed03 100644 --- a/source/expectations/matchers/ut_be_like.tps +++ b/source/expectations/matchers/ut_be_like.tps @@ -1,7 +1,7 @@ create or replace type ut_be_like under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_not_null.tpb b/source/expectations/matchers/ut_be_not_null.tpb index 194e2ea32..df9366fa7 100644 --- a/source/expectations/matchers/ut_be_not_null.tpb +++ b/source/expectations/matchers/ut_be_not_null.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_not_null as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_not_null.tps b/source/expectations/matchers/ut_be_not_null.tps index 196aac9fb..6cd11fc64 100644 --- a/source/expectations/matchers/ut_be_not_null.tps +++ b/source/expectations/matchers/ut_be_not_null.tps @@ -1,7 +1,7 @@ create or replace type ut_be_not_null under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_null.tpb b/source/expectations/matchers/ut_be_null.tpb index 8c672791b..d806bba34 100644 --- a/source/expectations/matchers/ut_be_null.tpb +++ b/source/expectations/matchers/ut_be_null.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_null as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_null.tps b/source/expectations/matchers/ut_be_null.tps index 3b2d6ac84..28f3ac796 100644 --- a/source/expectations/matchers/ut_be_null.tps +++ b/source/expectations/matchers/ut_be_null.tps @@ -1,7 +1,7 @@ create or replace type ut_be_null under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_true.tpb b/source/expectations/matchers/ut_be_true.tpb index fe78b4e22..442e57d7f 100644 --- a/source/expectations/matchers/ut_be_true.tpb +++ b/source/expectations/matchers/ut_be_true.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_true as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_true.tps b/source/expectations/matchers/ut_be_true.tps index 8b5491e39..b55fa484d 100644 --- a/source/expectations/matchers/ut_be_true.tps +++ b/source/expectations/matchers/ut_be_true.tps @@ -1,7 +1,7 @@ create or replace type ut_be_true under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index e2aa792d0..f77e9feec 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_within as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_within.tps b/source/expectations/matchers/ut_be_within.tps index 576f9ff37..06a685832 100644 --- a/source/expectations/matchers/ut_be_within.tps +++ b/source/expectations/matchers/ut_be_within.tps @@ -1,7 +1,7 @@ create or replace type ut_be_within force under ut_be_within_pct( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_within_helper.pkb b/source/expectations/matchers/ut_be_within_helper.pkb index 5dd82baa2..561bf230b 100644 --- a/source/expectations/matchers/ut_be_within_helper.pkb +++ b/source/expectations/matchers/ut_be_within_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_be_within_helper as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_within_helper.pks b/source/expectations/matchers/ut_be_within_helper.pks index 41737cc8f..b8480e249 100644 --- a/source/expectations/matchers/ut_be_within_helper.pks +++ b/source/expectations/matchers/ut_be_within_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_be_within_helper authid definer as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_within_pct.tpb b/source/expectations/matchers/ut_be_within_pct.tpb index 8b280ffff..ad821d72c 100644 --- a/source/expectations/matchers/ut_be_within_pct.tpb +++ b/source/expectations/matchers/ut_be_within_pct.tpb @@ -1,7 +1,7 @@ create or replace type body ut_be_within_pct as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_be_within_pct.tps b/source/expectations/matchers/ut_be_within_pct.tps index 499e9a2d8..645e9c485 100644 --- a/source/expectations/matchers/ut_be_within_pct.tps +++ b/source/expectations/matchers/ut_be_within_pct.tps @@ -1,7 +1,7 @@ create or replace type ut_be_within_pct force under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. @@ -16,7 +16,6 @@ create or replace type ut_be_within_pct force under ut_comparison_matcher( limitations under the License. */ - /** * Holds information about mather options */ diff --git a/source/expectations/matchers/ut_comparison_matcher.tpb b/source/expectations/matchers/ut_comparison_matcher.tpb index 20ed35927..b7cef4f59 100644 --- a/source/expectations/matchers/ut_comparison_matcher.tpb +++ b/source/expectations/matchers/ut_comparison_matcher.tpb @@ -1,7 +1,7 @@ create or replace type body ut_comparison_matcher as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_comparison_matcher.tps b/source/expectations/matchers/ut_comparison_matcher.tps index 68ecb4462..11b46d47c 100644 --- a/source/expectations/matchers/ut_comparison_matcher.tps +++ b/source/expectations/matchers/ut_comparison_matcher.tps @@ -1,7 +1,7 @@ create or replace type ut_comparison_matcher under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_contain.tpb b/source/expectations/matchers/ut_contain.tpb index c9691f731..a8eb71ecd 100644 --- a/source/expectations/matchers/ut_contain.tpb +++ b/source/expectations/matchers/ut_contain.tpb @@ -1,7 +1,7 @@ create or replace type body ut_contain as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_contain.tps b/source/expectations/matchers/ut_contain.tps index e572edf62..6d7c525c6 100644 --- a/source/expectations/matchers/ut_contain.tps +++ b/source/expectations/matchers/ut_contain.tps @@ -1,7 +1,7 @@ create or replace type ut_contain under ut_equal( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_equal.tpb b/source/expectations/matchers/ut_equal.tpb index d514e34d0..f5932b2ad 100644 --- a/source/expectations/matchers/ut_equal.tpb +++ b/source/expectations/matchers/ut_equal.tpb @@ -1,7 +1,7 @@ create or replace type body ut_equal as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_equal.tps b/source/expectations/matchers/ut_equal.tps index e48b797ed..e23eaf23b 100644 --- a/source/expectations/matchers/ut_equal.tps +++ b/source/expectations/matchers/ut_equal.tps @@ -1,7 +1,7 @@ create or replace type ut_equal force under ut_comparison_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_have_count.tpb b/source/expectations/matchers/ut_have_count.tpb index 457cd6272..0d4cfbcc0 100644 --- a/source/expectations/matchers/ut_have_count.tpb +++ b/source/expectations/matchers/ut_have_count.tpb @@ -1,7 +1,7 @@ create or replace type body ut_have_count as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_have_count.tps b/source/expectations/matchers/ut_have_count.tps index d48dc44c8..bd075e8f4 100644 --- a/source/expectations/matchers/ut_have_count.tps +++ b/source/expectations/matchers/ut_have_count.tps @@ -1,7 +1,7 @@ create or replace type ut_have_count under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_match.tpb b/source/expectations/matchers/ut_match.tpb index 3c7a71402..de645a135 100644 --- a/source/expectations/matchers/ut_match.tpb +++ b/source/expectations/matchers/ut_match.tpb @@ -1,7 +1,7 @@ create or replace type body ut_match as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_match.tps b/source/expectations/matchers/ut_match.tps index ee51a4c28..ababff18f 100644 --- a/source/expectations/matchers/ut_match.tps +++ b/source/expectations/matchers/ut_match.tps @@ -1,7 +1,7 @@ create or replace type ut_match under ut_matcher( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher.tpb b/source/expectations/matchers/ut_matcher.tpb index 6b5b98465..07e082a71 100644 --- a/source/expectations/matchers/ut_matcher.tpb +++ b/source/expectations/matchers/ut_matcher.tpb @@ -1,7 +1,7 @@ create or replace type body ut_matcher as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher.tps b/source/expectations/matchers/ut_matcher.tps index a034e4ed2..2551ce003 100644 --- a/source/expectations/matchers/ut_matcher.tps +++ b/source/expectations/matchers/ut_matcher.tps @@ -1,7 +1,7 @@ create or replace type ut_matcher under ut_matcher_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher_base.tps b/source/expectations/matchers/ut_matcher_base.tps index ef7fd98a2..c6d44468d 100644 --- a/source/expectations/matchers/ut_matcher_base.tps +++ b/source/expectations/matchers/ut_matcher_base.tps @@ -1,4 +1,21 @@ create or replace type ut_matcher_base force authid current_user as object( + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + self_type varchar2(250) ) not final not instantiable diff --git a/source/expectations/matchers/ut_matcher_options.tpb b/source/expectations/matchers/ut_matcher_options.tpb index 8730c204b..1acb4405b 100644 --- a/source/expectations/matchers/ut_matcher_options.tpb +++ b/source/expectations/matchers/ut_matcher_options.tpb @@ -1,7 +1,7 @@ create or replace type body ut_matcher_options as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher_options.tps b/source/expectations/matchers/ut_matcher_options.tps index 276cad2ec..835316e7c 100644 --- a/source/expectations/matchers/ut_matcher_options.tps +++ b/source/expectations/matchers/ut_matcher_options.tps @@ -1,7 +1,7 @@ create or replace type ut_matcher_options authid current_user as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher_options_items.tpb b/source/expectations/matchers/ut_matcher_options_items.tpb index 92da588ce..921d3ecd2 100644 --- a/source/expectations/matchers/ut_matcher_options_items.tpb +++ b/source/expectations/matchers/ut_matcher_options_items.tpb @@ -1,7 +1,7 @@ create or replace type body ut_matcher_options_items is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/matchers/ut_matcher_options_items.tps b/source/expectations/matchers/ut_matcher_options_items.tps index 53787070d..73c2bb92d 100644 --- a/source/expectations/matchers/ut_matcher_options_items.tps +++ b/source/expectations/matchers/ut_matcher_options_items.tps @@ -1,7 +1,7 @@ create or replace type ut_matcher_options_items authid current_user as object( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index 309759d48..12aef603a 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -1,7 +1,7 @@ create or replace type body ut_expectation as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index 30fe985d3..b015a95a7 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation force under ut_expectation_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation_base.tpb b/source/expectations/ut_expectation_base.tpb index 20b3e7a95..3d6e9b469 100644 --- a/source/expectations/ut_expectation_base.tpb +++ b/source/expectations/ut_expectation_base.tpb @@ -1,7 +1,7 @@ create or replace type body ut_expectation_base as /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. @@ -15,6 +15,7 @@ create or replace type body ut_expectation_base as See the License for the specific language governing permissions and limitations under the License. */ + member procedure to_(self in ut_expectation_base, a_matcher ut_matcher_base) is l_expectation_result boolean; l_matcher ut_matcher := treat(a_matcher as ut_matcher); diff --git a/source/expectations/ut_expectation_base.tps b/source/expectations/ut_expectation_base.tps index a542d26ea..24e180b92 100644 --- a/source/expectations/ut_expectation_base.tps +++ b/source/expectations/ut_expectation_base.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation_base authid current_user as object( /* utPLSQL - Version 3 - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. @@ -15,6 +15,7 @@ create or replace type ut_expectation_base authid current_user as object( See the License for the specific language governing permissions and limitations under the License. */ + actual_data ut_data_value, description varchar2(4000 char), diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index 6fc2e2647..1131885b0 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -1,7 +1,7 @@ create or replace type body ut_expectation_compound as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index 46da23fea..ebf534222 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation_compound under ut_expectation( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation_json.tpb b/source/expectations/ut_expectation_json.tpb index b71e8ea83..90a3a3d31 100644 --- a/source/expectations/ut_expectation_json.tpb +++ b/source/expectations/ut_expectation_json.tpb @@ -1,7 +1,7 @@ create or replace type body ut_expectation_json as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/expectations/ut_expectation_json.tps b/source/expectations/ut_expectation_json.tps index 561c5d11f..d873cc99c 100644 --- a/source/expectations/ut_expectation_json.tps +++ b/source/expectations/ut_expectation_json.tps @@ -1,7 +1,7 @@ create or replace type ut_expectation_json under ut_expectation( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install.sql b/source/install.sql index 22ce75365..a2c73ef17 100644 --- a/source/install.sql +++ b/source/install.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install_above_12_1.sql b/source/install_above_12_1.sql index 69e47ce9a..5a1943358 100644 --- a/source/install_above_12_1.sql +++ b/source/install_above_12_1.sql @@ -1,3 +1,20 @@ +/* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + def FILE_NAME = '&&1' column SCRIPT_NAME new_value SCRIPT_NAME noprint diff --git a/source/install_component.sql b/source/install_component.sql index 373c85c54..1189df496 100644 --- a/source/install_component.sql +++ b/source/install_component.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install_ddl_trigger.sql b/source/install_ddl_trigger.sql index bc147c2be..b23b4bc63 100644 --- a/source/install_ddl_trigger.sql +++ b/source/install_ddl_trigger.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install_headless.sql b/source/install_headless.sql index 183262675..be1e5becf 100644 --- a/source/install_headless.sql +++ b/source/install_headless.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/install_headless_with_trigger.sql b/source/install_headless_with_trigger.sql index 76ae48ccb..2c05403c5 100644 --- a/source/install_headless_with_trigger.sql +++ b/source/install_headless_with_trigger.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_ansiconsole_helper.pkb b/source/reporters/ut_ansiconsole_helper.pkb index 53e6bc6aa..46960cf5c 100644 --- a/source/reporters/ut_ansiconsole_helper.pkb +++ b/source/reporters/ut_ansiconsole_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_ansiconsole_helper as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_ansiconsole_helper.pks b/source/reporters/ut_ansiconsole_helper.pks index 217d36a49..fd4549965 100644 --- a/source/reporters/ut_ansiconsole_helper.pks +++ b/source/reporters/ut_ansiconsole_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_ansiconsole_helper as /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index d833ac0aa..833ca09be 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_cobertura_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_cobertura_reporter.tps b/source/reporters/ut_coverage_cobertura_reporter.tps index 1292e60fb..ee2d9b71d 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tps +++ b/source/reporters/ut_coverage_cobertura_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_cobertura_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_html_reporter.tpb b/source/reporters/ut_coverage_html_reporter.tpb index b1f9f6651..253c067e5 100644 --- a/source/reporters/ut_coverage_html_reporter.tpb +++ b/source/reporters/ut_coverage_html_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_html_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_html_reporter.tps b/source/reporters/ut_coverage_html_reporter.tps index 42f2fd4e3..db65e1e00 100644 --- a/source/reporters/ut_coverage_html_reporter.tps +++ b/source/reporters/ut_coverage_html_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_html_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index f7e0b5ed0..7ebf891f9 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_coverage_report_html_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_report_html_helper.pks b/source/reporters/ut_coverage_report_html_helper.pks index 42a59c123..c028168a8 100644 --- a/source/reporters/ut_coverage_report_html_helper.pks +++ b/source/reporters/ut_coverage_report_html_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_coverage_report_html_helper authid current_user is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_sonar_reporter.tpb b/source/reporters/ut_coverage_sonar_reporter.tpb index 1861a9be3..8148fc7fc 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tpb +++ b/source/reporters/ut_coverage_sonar_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coverage_sonar_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coverage_sonar_reporter.tps b/source/reporters/ut_coverage_sonar_reporter.tps index 715bdefd2..b5e964a3a 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tps +++ b/source/reporters/ut_coverage_sonar_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_coverage_sonar_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coveralls_reporter.tpb b/source/reporters/ut_coveralls_reporter.tpb index 14672303e..fc459c906 100644 --- a/source/reporters/ut_coveralls_reporter.tpb +++ b/source/reporters/ut_coveralls_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_coveralls_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_coveralls_reporter.tps b/source/reporters/ut_coveralls_reporter.tps index 74363b751..e547793d1 100644 --- a/source/reporters/ut_coveralls_reporter.tps +++ b/source/reporters/ut_coveralls_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_coveralls_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_debug_reporter.tpb b/source/reporters/ut_debug_reporter.tpb index 879725172..b17f039ea 100644 --- a/source/reporters/ut_debug_reporter.tpb +++ b/source/reporters/ut_debug_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_debug_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_debug_reporter.tps b/source/reporters/ut_debug_reporter.tps index 2123f19cc..85c0eeb54 100644 --- a/source/reporters/ut_debug_reporter.tps +++ b/source/reporters/ut_debug_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_debug_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_documentation_reporter.tpb b/source/reporters/ut_documentation_reporter.tpb index e8c0a4e31..489b6efd2 100644 --- a/source/reporters/ut_documentation_reporter.tpb +++ b/source/reporters/ut_documentation_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_documentation_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_documentation_reporter.tps b/source/reporters/ut_documentation_reporter.tps index 422225117..23b86226f 100644 --- a/source/reporters/ut_documentation_reporter.tps +++ b/source/reporters/ut_documentation_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_documentation_reporter under ut_console_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_junit_reporter.tpb b/source/reporters/ut_junit_reporter.tpb index 3bceb52a4..a2cffd287 100644 --- a/source/reporters/ut_junit_reporter.tpb +++ b/source/reporters/ut_junit_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_junit_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_junit_reporter.tps b/source/reporters/ut_junit_reporter.tps index 6cdaff1b9..5999c33f5 100644 --- a/source/reporters/ut_junit_reporter.tps +++ b/source/reporters/ut_junit_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_junit_reporter force under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_realtime_reporter.tpb b/source/reporters/ut_realtime_reporter.tpb index 9c2af57ec..fac7cd9b8 100644 --- a/source/reporters/ut_realtime_reporter.tpb +++ b/source/reporters/ut_realtime_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_realtime_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_realtime_reporter.tps b/source/reporters/ut_realtime_reporter.tps index 0501006e4..5ab350162 100644 --- a/source/reporters/ut_realtime_reporter.tps +++ b/source/reporters/ut_realtime_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_realtime_reporter force under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_sonar_test_reporter.tpb b/source/reporters/ut_sonar_test_reporter.tpb index 7c46879d2..dfa6a7421 100644 --- a/source/reporters/ut_sonar_test_reporter.tpb +++ b/source/reporters/ut_sonar_test_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_sonar_test_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_sonar_test_reporter.tps b/source/reporters/ut_sonar_test_reporter.tps index ac3b16bd1..d9f98071d 100644 --- a/source/reporters/ut_sonar_test_reporter.tps +++ b/source/reporters/ut_sonar_test_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_sonar_test_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index ff095a369..02246b97e 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -1,5 +1,20 @@ create or replace type body ut_tap_reporter is - + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ constructor function ut_tap_reporter(self in out nocopy ut_tap_reporter) return self as result is begin diff --git a/source/reporters/ut_tap_reporter.tps b/source/reporters/ut_tap_reporter.tps index bed809059..94423b6fc 100644 --- a/source/reporters/ut_tap_reporter.tps +++ b/source/reporters/ut_tap_reporter.tps @@ -1,4 +1,20 @@ create or replace type ut_tap_reporter under ut_documentation_reporter( + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ constructor function ut_tap_reporter(self in out nocopy ut_tap_reporter) return self as result, member procedure print_comment(self in out nocopy ut_tap_reporter, a_comment clob), diff --git a/source/reporters/ut_teamcity_reporter.tpb b/source/reporters/ut_teamcity_reporter.tpb index e05dc994f..2e09c7103 100644 --- a/source/reporters/ut_teamcity_reporter.tpb +++ b/source/reporters/ut_teamcity_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_teamcity_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_teamcity_reporter.tps b/source/reporters/ut_teamcity_reporter.tps index e03fa3643..e5c43b59e 100644 --- a/source/reporters/ut_teamcity_reporter.tps +++ b/source/reporters/ut_teamcity_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_teamcity_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_teamcity_reporter_helper.pkb b/source/reporters/ut_teamcity_reporter_helper.pkb index 1633d10aa..575af645d 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pkb +++ b/source/reporters/ut_teamcity_reporter_helper.pkb @@ -1,7 +1,7 @@ create or replace package body ut_teamcity_reporter_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_teamcity_reporter_helper.pks b/source/reporters/ut_teamcity_reporter_helper.pks index d7fa86cdc..727d02913 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pks +++ b/source/reporters/ut_teamcity_reporter_helper.pks @@ -1,7 +1,7 @@ create or replace package ut_teamcity_reporter_helper is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_tfs_junit_reporter.tpb b/source/reporters/ut_tfs_junit_reporter.tpb index 5e36aad17..8c2bd6333 100644 --- a/source/reporters/ut_tfs_junit_reporter.tpb +++ b/source/reporters/ut_tfs_junit_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_tfs_junit_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_tfs_junit_reporter.tps b/source/reporters/ut_tfs_junit_reporter.tps index 61cbc3fd8..3af2226a5 100644 --- a/source/reporters/ut_tfs_junit_reporter.tps +++ b/source/reporters/ut_tfs_junit_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_tfs_junit_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_xunit_reporter.tpb b/source/reporters/ut_xunit_reporter.tpb index 4612fb640..164703917 100644 --- a/source/reporters/ut_xunit_reporter.tpb +++ b/source/reporters/ut_xunit_reporter.tpb @@ -1,7 +1,7 @@ create or replace type body ut_xunit_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/reporters/ut_xunit_reporter.tps b/source/reporters/ut_xunit_reporter.tps index 6c530fee4..970e4d162 100644 --- a/source/reporters/ut_xunit_reporter.tps +++ b/source/reporters/ut_xunit_reporter.tps @@ -1,7 +1,7 @@ create or replace type ut_xunit_reporter under ut_junit_reporter( /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/set_install_params.sql b/source/set_install_params.sql index 34a23dc93..b559b8023 100644 --- a/source/set_install_params.sql +++ b/source/set_install_params.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/uninstall.sql b/source/uninstall.sql index ced7b8dc4..712845fb7 100644 --- a/source/uninstall.sql +++ b/source/uninstall.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/uninstall_all.sql b/source/uninstall_all.sql index cfaaaa29f..d3d3f3fbe 100644 --- a/source/uninstall_all.sql +++ b/source/uninstall_all.sql @@ -1,6 +1,6 @@ /* utPLSQL - Version 3 - Copyright 2016 - 2021 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project Licensed under the Apache License, Version 2.0 (the "License"): you may not use this file except in compliance with the License. diff --git a/source/uninstall_coverage_tables.sql b/source/uninstall_coverage_tables.sql index 890aa7090..df3c19627 100644 --- a/source/uninstall_coverage_tables.sql +++ b/source/uninstall_coverage_tables.sql @@ -1,3 +1,20 @@ +/* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + set echo off set feedback off begin diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index df8b51d35..8ef644aa9 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -1,3 +1,20 @@ +/* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + set echo off declare procedure drop_if_exists(a_object_type varchar2, a_object_name varchar2) is diff --git a/source/uninstall_synonyms.sql b/source/uninstall_synonyms.sql index 2c96c03a4..4a12340f6 100644 --- a/source/uninstall_synonyms.sql +++ b/source/uninstall_synonyms.sql @@ -1,3 +1,20 @@ +/* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"): + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + set echo off set feedback off declare From 5633cae49b40742a824ce78c33f15d871c351af9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 12:50:37 +0300 Subject: [PATCH 596/887] Rewrite of README.md file Added CHANGELOG.md --- CHANGELOG.md | 599 +++++++++++++++++++++++++++++++++++++++++++++++++++ readme.md | 196 +++++++---------- 2 files changed, 673 insertions(+), 122 deletions(-) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 000000000..aae364bab --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,599 @@ +# Changelog + +All notable changes to utPLSQL are documented here. +Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/utPLSQL/releases). + +--- + +## [v3.2.01] - unreleased + +## Important + - Dropped support for Oracle Database versions older than 19c + +## New features + - Add TAP reporter by @WayneNani in [#1305](https://github.com/utPLSQL/utPLSQL/pull/1305) + +## Enhancements and bug fixes + - Added duplicate detection on cursor comparison using `join_by` by @lwasylow in [#1295](https://github.com/utPLSQL/utPLSQL/pull/1295) + - Fix code causing the object duration Oracle exception on oracle 23.26 by @lwasylow in [#1310](https://github.com/utPLSQL/utPLSQL/pull/1310) + - Packages with annotation-like comments are not test suites by @jgebal in [#1313](https://github.com/utPLSQL/utPLSQL/pull/1313) + - Updated documentation and copyright banners across source files @jgebal in [#1319](https://github.com/utPLSQL/utPLSQL/pull/1319) + +--- + +## [v3.1.14] - 2024-02-19 + +## New features + + - Added support for `and` and `or` operators when running tests by tags by @lwasylow in [#1250](https://github.com/utPLSQL/utPLSQL/pull/1250) + +## Enhancements + + - Allow for test runs over 4 hours by @jgebal in [#1243](https://github.com/utPLSQL/utPLSQL/pull/1243) + - Framework performance improvements by @jgebal in [#1249](https://github.com/utPLSQL/utPLSQL/pull/1249) + - Support multiple expectation failures with teamcity reporter by @jgebal in [#1251](https://github.com/utPLSQL/utPLSQL/pull/1251) + - Update TFS reporter to correct format by @lwasylow in [#1270](https://github.com/utPLSQL/utPLSQL/pull/1270) + +## Bug fixes + + - Address issue where the `not_to(contain)` did not run correctly by @lwasylow in [#1246](https://github.com/utPLSQL/utPLSQL/pull/1246) + - Fix regex to be NLS_SORT independent by @jgebal in [#1253](https://github.com/utPLSQL/utPLSQL/pull/1253) + - Fix output length error and output buffer. by @jgebal in [#1255](https://github.com/utPLSQL/utPLSQL/pull/1255) + - (docs): Update running-unit-tests.md - remove example by @gassenmj in [#1261](https://github.com/utPLSQL/utPLSQL/pull/1261) + - The line-rate is not recorded for packages and classes in cobertura coverage reporter by @lwasylow in [#1269](https://github.com/utPLSQL/utPLSQL/pull/1269) + - (docs): Fix nested list issue by @iamrachid in [#1274](https://github.com/utPLSQL/utPLSQL/pull/1274) + +--- + +## [v3.1.13] - 2022-12-11 + +## New features + + - Add ability to run tests by part of a name. Fixed in [#1203](https://github.com/utPLSQL/utPLSQL/pull/1203), resolves [#470](https://github.com/utPLSQL/utPLSQL/issues/470) + +## Enhancements + + - Added documentation section on creating a custom reporter. Fixed in [#1225](https://github.com/utPLSQL/utPLSQL/pull/1225), resolves [#710](https://github.com/utPLSQL/utPLSQL/issues/701) + - Add ability to specify code coverage objects include/exclude masks as regular expressions. Fixed in [#1186](https://github.com/utPLSQL/utPLSQL/issues/1186), resolves [#1053](https://github.com/utPLSQL/utPLSQL/issues/1053) + +## Bug fixes + + - Comparing collection that have long type names. Fixed in [#1238](https://github.com/utPLSQL/utPLSQL/issues/1238), resolves [#1235](https://github.com/utPLSQL/utPLSQL/issues/1235). + - Code coverage reporting on code with long lines. Fixed in [#1240](https://github.com/utPLSQL/utPLSQL/issues/1240), resolves [#1232](https://github.com/utPLSQL/utPLSQL/issues/1232), [#1087](https://github.com/utPLSQL/utPLSQL/issues/1087). + - Code coverage reporting does not exclude tests. Fixed in [#1226](https://github.com/utPLSQL/utPLSQL/issues/1226), resolves [#1222](https://github.com/utPLSQL/utPLSQL/issues/1222). + - Uninstall script buffer overflow. Fixed in [#1221](https://github.com/utPLSQL/utPLSQL/issues/1221), resolves [#1220](https://github.com/utPLSQL/utPLSQL/issues/1220). + +## Internal improvements + + - Improved process of generating utPLSQL documentation. Implemented in [689bbd0](https://github.com/utPLSQL/utPLSQL/commit/689bbd0e365ed919315c29727bc10fbfc0dadce8), resolves [#1237](https://github.com/utPLSQL/utPLSQL/issues/1237). + - Removed username env variables for internal development. Implemented in [#1201](https://github.com/utPLSQL/utPLSQL/issues/1221), resolves [#1200](https://github.com/utPLSQL/utPLSQL/issues/1200). + - Test execution data of utPLSQL project not showing on SonarCloud. Implemented in [#1199](https://github.com/utPLSQL/utPLSQL/issues/1199), resolves [#1198](https://github.com/utPLSQL/utPLSQL/issues/1198). + +--- + +## [v3.1.12] - 2022-02-25 + +## New features + - Added support for description in the `--%disabled` annotation. See [documentation](https://github.com/utPLSQL/utPLSQL/blob/4515e0b5a3b4b0de0c2198db3235ef8614bff4d8/docs/userguide/annotations.md#disabled). Implemented in: [#1183](https://github.com/utPLSQL/utPLSQL/pull/1183), resolves [#610](https://github.com/utPLSQL/utPLSQL/issues/610). + - Added support for native `JSON` datatype on Oracle `21c`. Implemented in [#1181](https://github.com/utPLSQL/utPLSQL/pull/1181), resolves [#1114](https://github.com/utPLSQL/utPLSQL/issues/1114). + - Added new mather `to_be_within( distance|pct ).of_(expoected)`. See [documentation](https://github.com/utPLSQL/utPLSQL/blob/fd7ef9c14111a48e03fff7851f990c7192539170/docs/userguide/expectations.md#to_be_within-of). Implemented in [#1076](https://github.com/utPLSQL/utPLSQL/pull/1076), resolves [#77](https://github.com/utPLSQL/utPLSQL/issues/77). + +## Enhancements + +- Improved performance of SQL used to retrieve Coverage sources. Implemented in [#1187](https://github.com/utPLSQL/utPLSQL/pull/1187), resolves [#1169](https://github.com/utPLSQL/utPLSQL/issues/1169). +- Added ability for utPLSQL to gather coverage on code invoking DBMS_STATS package. Implemented in [#1184](https://github.com/utPLSQL/utPLSQL/pull/1184), resolves [#1097](https://github.com/utPLSQL/utPLSQL/issues/1097), [#1094](https://github.com/utPLSQL/utPLSQL/issues/1094). +- Fixed typos and improved documentation. Implemented in [#1173](https://github.com/utPLSQL/utPLSQL/pull/1173), [#1171](https://github.com/utPLSQL/utPLSQL/pull/1171) + +## Bug fixes + +- Actual and Expected are now correctly reported when comparing `JSON` data. Implemented in [#1181](https://github.com/utPLSQL/utPLSQL/pull/1181), resolves [#1113](https://github.com/utPLSQL/utPLSQL/issues/1113). +- Packages with removed annotations are now correctly recognized as non-utPLSQL packages. Implemented in [#1180](https://github.com/utPLSQL/utPLSQL/pull/1180), resolves [#1177](https://github.com/utPLSQL/utPLSQL/issues/1177). +- Fixed issues with comparison of nested object structures. Implemented in [#1179](https://github.com/utPLSQL/utPLSQL/pull/1179), resolves [#1082](https://github.com/utPLSQL/utPLSQL/issues/1082), [#1083](https://github.com/utPLSQL/utPLSQL/issues/1083), [#1098](https://github.com/utPLSQL/utPLSQL/issues/1098). + +## Internal improvements + +- Moved build and test process for utPLSQL from Travis to GithubActions. Implemented in [#1175](https://github.com/utPLSQL/utPLSQL/pull/1175) + +--- + +## [v3.1.11] - 2021-11-17 + +## Enhancements + +- utPLSQL can now be used to generate coverage reports for external tools. See [documentation](https://github.com/utPLSQL/utPLSQL/blob/955de5c2dc527a98a6f5dc0dd8bd8d81a44c459f/docs/userguide/coverage.md#reporting-coverage-outside-of-utplsql) + Implemented in: [#1079](https://github.com/utPLSQL/utPLSQL/pull/1079), resolves [#1025](https://github.com/utPLSQL/utPLSQL/issues/1025) +- Enhanced UT_COVERAGE_COBERTURA_REPORTER to better support TFS and GitLab. Implemented in [#1137](https://github.com/utPLSQL/utPLSQL/pull/1137) and [#1140](https://github.com/utPLSQL/utPLSQL/pull/1140), resolves [#1107](https://github.com/utPLSQL/utPLSQL/issues/1107) +- Added support for installation on Oracle 21c - removed dependency on DBMS_OBFUSCATION_TOOLKIT. Implemented in [#1112](https://github.com/utPLSQL/utPLSQL/pull/1112), resolves [#1111](https://github.com/utPLSQL/utPLSQL/issues/1111) and [#1127](https://github.com/utPLSQL/utPLSQL/issues/1127) +- Added support for running utPLSQL framework in parallel-enabled database. Implemented in [#1160](https://github.com/utPLSQL/utPLSQL/pull/1160), resolves [#1134](https://github.com/utPLSQL/utPLSQL/issues/1134) + +## Bug fixes + +- Suite structure is built properly even with other than English TNS settings. Implemented in [#1061](https://github.com/utPLSQL/utPLSQL/pull/1061), resolves [#1060](https://github.com/utPLSQL/utPLSQL/issues/1060) +- Fixed XML content reporting (CDATA) in UT_REALTIME_REPORTER used by SQLDeveloper plugin. Implemented in [#1075](https://github.com/utPLSQL/utPLSQL/pull/1075), resolves [#1073](https://github.com/utPLSQL/utPLSQL/issues/1073) +- Fixed XML content reporting (CDATA) in JUnit reporter - regression. Implemented in [#1085](https://github.com/utPLSQL/utPLSQL/pull/1085), resolves [#1084](https://github.com/utPLSQL/utPLSQL/issues/1084) +- Fixed issue with utPLSQL failing to run coverage reporting when trigger has overlapping name with procedure/function/package/type. Implemented in [#1091](https://github.com/utPLSQL/utPLSQL/pull/1091), resolves [#1086](https://github.com/utPLSQL/utPLSQL/issues/1086) +- Fixed issue with parsing utPLSQL suites with DDL trigger when usign AUTHID clause. Implemented in [#1093](https://github.com/utPLSQL/utPLSQL/pull/1093), resolves [#1088](https://github.com/utPLSQL/utPLSQL/issues/1088) + +## Internal improvements + +- Improved how privilege checks are handled by framework installation. Implemented in [#1056](https://github.com/utPLSQL/utPLSQL/pull/1056), resolves [#1050](https://github.com/utPLSQL/utPLSQL/issues/1050) +- Restructured installation instructions to make it more readable. Implemented in [#1063](https://github.com/utPLSQL/utPLSQL/pull/1063), resolves [#1062](https://github.com/utPLSQL/utPLSQL/issues/1062) +- Updated database requirements in documentation. Implemented in [#1065](https://github.com/utPLSQL/utPLSQL/pull/1065), resolves [#1064](https://github.com/utPLSQL/utPLSQL/issues/1064) +- Removed duplicated call to install profiler tables. Implemented in [#1164](https://github.com/utPLSQL/utPLSQL/pull/1164), resolves [#1149](https://github.com/utPLSQL/utPLSQL/issues/1149) +- Fixed failing internal framework tests on Oracle 21c. Implemented in [#1158](https://github.com/utPLSQL/utPLSQL/pull/1158), resolves [#1151](https://github.com/utPLSQL/utPLSQL/issues/1151) +- Fixed confusing typo in documentation. Resolves [#1154](https://github.com/utPLSQL/utPLSQL/issues/1154) +- Moved build process from travis-ci.org to travis-ci.com. Implemented in [#1152](https://github.com/utPLSQL/utPLSQL/pull/1152) +- Added an example of reporter reporting all expectations, not only the failing ones. Implemented in [#1092](https://github.com/utPLSQL/utPLSQL/pull/1092) + +--- + +## [v3.1.10] - 2020-02-23 + +## Enhancements + +- utPLSQL test runner is now validating arguments of `--%throws` annotations at runtime [#721](https://github.com/utPLSQL/utPLSQL/issues/721) [#1033](https://github.com/utPLSQL/utPLSQL/issues/1033) +- Documented limitations of insignificant spaces comparison in compound data [#880](https://github.com/utPLSQL/utPLSQL/issues/880) +- utPLSQL will now detect empty annotation cache for schema even with DLL trigger enabled [#975](https://github.com/utPLSQL/utPLSQL/issues/975) +- Order of procedures and annotation now determines default order of tests in suite [#1036](https://github.com/utPLSQL/utPLSQL/issues/1036) + +## Bug fixes + +- Nested contexts are now properly identified [#1034](https://github.com/utPLSQL/utPLSQL/issues/1034) +- TeamCity test reporter is now including error message [#1045](https://github.com/utPLSQL/utPLSQL/issues/1045) + +## Internal improvements + +- All self-tests for utPLSQL framework can now be executed using test-owner schema [#969](https://github.com/utPLSQL/utPLSQL/issues/969) +- Misleading rollback warning is no longer showing when running self-tests for utPLSQL [#982](https://github.com/utPLSQL/utPLSQL/issues/982) + +--- + +## [v3.1.9] - 2019-11-10 + +## New features + +- Added ability to define [nested contexts](https://github.com/utPLSQL/utPLSQL/blob/v3.1.9/docs/userguide/annotations.md#context) within test suite [#938](https://github.com/utPLSQL/utPLSQL/issues/938) +- Added ability to [exclude tests/suites by tags](https://github.com/utPLSQL/utPLSQL/blob/v3.1.9/docs/userguide/annotations.md#excluding-testssuites-by-tags) when invoking a test-run [#1007](https://github.com/utPLSQL/utPLSQL/issues/1007) [#983](https://github.com/utPLSQL/utPLSQL/issues/983) +- Added new annotation [`--%name`](https://github.com/utPLSQL/utPLSQL/blob/v3.1.9/docs/userguide/annotations.md#name) to allow for providing custom name for contexts [#1016](https://github.com/utPLSQL/utPLSQL/issues/1016) + +## Important changes + +The value of `--%context` annotation is no longer representing context `name`. +This value is now context description (displayname). +With this change, the `--%context` annotation is now aligned with `--%test` and `--%suite` annotation syntax. + +New annotation `--%name` was introduced to facilitate naming of contexts. + +## Enhancements + +- Improved documentation for running tests +- Improved documentation for tags [#1003](https://github.com/utPLSQL/utPLSQL/issues/1003) +- Improved documentation for annotations + +## Bug fixes + +- Fixed bug with bad stacktrace showing in failing/erroring test [#1000](https://github.com/utPLSQL/utPLSQL/issues/1000) +- Fixed issue with lack of validation for context name [#966](https://github.com/utPLSQL/utPLSQL/issues/966) +- Fixed problem with install script privilege check for installation with DDL trigger [#992](https://github.com/utPLSQL/utPLSQL/issues/992) +- Fixed issue with some common column names causing cursor comparison to fail [#997](https://github.com/utPLSQL/utPLSQL/issues/997) +- Fixed issue with invocation of standalone expectations on cursor [#998](https://github.com/utPLSQL/utPLSQL/issues/998) + +## Internal improvements + +- Fixed runability of utplsql self-tests [#968](https://github.com/utPLSQL/utPLSQL/issues/968) + +--- + +## [v3.1.8] - 2019-09-03 + +## New features + +- Added support for [session context](https://github.com/utPLSQL/utPLSQL/blob/v3.1.8/docs/userguide/annotations.md#sys_context) to provide test and suite information during test run [#963](https://github.com/utPLSQL/utPLSQL/issues/963) [#781](https://github.com/utPLSQL/utPLSQL/issues/781) +- Added ability to [invoke expectations without running framework](https://github.com/utPLSQL/utPLSQL/blob/v3.1.8/docs/userguide/expectations.md#running-expectations-outside-utplsql-framework) [#956](https://github.com/utPLSQL/utPLSQL/issues/956) [#963](https://github.com/utPLSQL/utPLSQL/issues/963) +- Failing expectations are now reported with call stack [#967](https://github.com/utPLSQL/utPLSQL/issues/967) [#963](https://github.com/utPLSQL/utPLSQL/issues/963) + +## Enhancements + +- Improved framework table private data protection [#922](https://github.com/utPLSQL/utPLSQL/issues/922) [#954](https://github.com/utPLSQL/utPLSQL/issues/954) +- Improved install process. It is now unified for installation with both public and private synonyms [#957](https://github.com/utPLSQL/utPLSQL/issues/957) [#954](https://github.com/utPLSQL/utPLSQL/issues/954) +- Improved reporting of warnings for integration with SQLDeveloper [#964](https://github.com/utPLSQL/utPLSQL/issues/964) +- Improved query to retrieve coverage sources [#981](https://github.com/utPLSQL/utPLSQL/issues/981) [#970](https://github.com/utPLSQL/utPLSQL/issues/970) +- Improved security around malicious utPLSQL owner name [#920](https://github.com/utPLSQL/utPLSQL/issues/920) + +## Bug fixes + +- Fixed cursor comparison on Oracle 11.2 [#947](https://github.com/utPLSQL/utPLSQL/issues/947) +- Fixed issue with retrieving suite data [#977](https://github.com/utPLSQL/utPLSQL/issues/977) [#974](https://github.com/utPLSQL/utPLSQL/issues/974) [#978](https://github.com/utPLSQL/utPLSQL/issues/978) +- Application context is now reset in session after test run [#951](https://github.com/utPLSQL/utPLSQL/issues/951) + +--- + +## [v3.1.7] - 2019-06-18 + +## New features + +- Added support for [comparing `json`](https://github.com/utPLSQL/utPLSQL/blob/v3.1.7/docs/userguide/expectations.md#comparing-json-objects) in Oracle 12.2 and above [#924](https://github.com/utPLSQL/utPLSQL/issues/924) +- Introduced [`tag` annotation](https://github.com/utPLSQL/utPLSQL/blob/v3.1.7/docs/userguide/annotations.md#tags) to enable tagging of tests and suites [#66](https://github.com/utPLSQL/utPLSQL/issues/66) +- Added support for [random order](https://github.com/utPLSQL/utPLSQL/blob/v3.1.7/docs/userguide/running-unit-tests.md#random-order) of test execution [#422](https://github.com/utPLSQL/utPLSQL/issues/422) + +## Enhancements + +- Added optional [install with DDL trigger](https://github.com/utPLSQL/utPLSQL/blob/v3.1.7/docs/userguide/install.md#installation-with-ddl-trigger) to speed up framework start [#901](https://github.com/utPLSQL/utPLSQL/issues/901) +- Removed dependency on `dbms_utility.name_resolve` [#569](https://github.com/utPLSQL/utPLSQL/issues/569) [#885](https://github.com/utPLSQL/utPLSQL/issues/885) +- New output buffer table structures improving performance and addressing timeout issues [#915](https://github.com/utPLSQL/utPLSQL/issues/915) + +## Bug fixes + +- Fixed `ut_realtime_reporter` missing warnings in test and suite output structures [#936](https://github.com/utPLSQL/utPLSQL/issues/936) +- Fixed output_buffer purging error [#934](https://github.com/utPLSQL/utPLSQL/issues/934) +- Fixed `join_by / exclude / include` invalid syntax on collection in anydata compare [#912](https://github.com/utPLSQL/utPLSQL/issues/912) +- Fixed `ut_junit_reporter` producing invalid output on failing tests with long failure message [#927](https://github.com/utPLSQL/utPLSQL/issues/927) +- Fixed `ut_sonar_test_reporter` producing invalid output on failing tests with long failure message [#925](https://github.com/utPLSQL/utPLSQL/issues/925) +- Fixed `ut_coverage_cobertura_reporter` producing wrong line breaks which breaks the xml validation against DTD [#917](https://github.com/utPLSQL/utPLSQL/issues/917) +- Fixed `exclude` option for ref cursor where column order was not resolved correctly [#911](https://github.com/utPLSQL/utPLSQL/issues/911) +- Fixed `unordered` option for ref cursor with null values [#914](https://github.com/utPLSQL/utPLSQL/issues/914) +- Fixed number precision when selecting from dual [#907](https://github.com/utPLSQL/utPLSQL/issues/907) +- Fixed ref cursor errors with generated column names [#902](https://github.com/utPLSQL/utPLSQL/issues/902) +- Fixed `ORA-00907` when comparing ref cursors with BINARY_ columns [#899](https://github.com/utPLSQL/utPLSQL/issues/899) +- Fixed wrong results when comparing CLOBs with `to_be_like` in Oracle Database 11.2.0.4 due to Oracle Bug 14402514 [#891](https://github.com/utPLSQL/utPLSQL/issues/891) +- Fixed performance issue with code coverage report on huge PL/SQL code base [#882](https://github.com/utPLSQL/utPLSQL/issues/882) + +## Documentation improvements + +- Added install instructions for DDL trigger [#874](https://github.com/utPLSQL/utPLSQL/issues/874) + +## Internal enhancements + +- Fixed SQL vulnerability on all input parameters used in dynamic SQL and PL/SQL [#921](https://github.com/utPLSQL/utPLSQL/issues/921) +- Fixed message id in output buffer [#916](https://github.com/utPLSQL/utPLSQL/issues/916) +- Included 19c database in self testing [#909](https://github.com/utPLSQL/utPLSQL/issues/909) +- Introduced testing with multiple schemas and different grants [#893](https://github.com/utPLSQL/utPLSQL/issues/893) +- Fixed installation script warnings [#879](https://github.com/utPLSQL/utPLSQL/issues/879) + +--- + +## [v3.1.6] - 2019-03-24 + +Bugfix release for `v3.1.5` + +## Bug fixes + +- Fixed a bug in release `3.1.5` where `to_equal` matcher was failing due to privileges when comparing non sql diffable types [#870](https://github.com/utPLSQL/utPLSQL/issues/870) + +## Improvements +- Reduced number of information displaying about user defined type. We will now display only type name instead of full structure [#866](https://github.com/utPLSQL/utPLSQL/issues/866) + +--- + +## [v3.1.5] - 2019-03-20 + +Bugfix release for `v3.1.4` + +## Bug fixes + +- Fixed a bug in release `3.1.4` where `to_be_empty` matcher was failing due to privileges [#864](https://github.com/utPLSQL/utPLSQL/issues/864) + +--- + +## [v3.1.4] - 2019-03-19 + +**This release contains a bug that is fixed by release 3.1.5** +Please use release 3.1.5 rather than this release. + +## New features + +- Added `to_contain` matcher for collections and cursors [#79](https://github.com/utPLSQL/utPLSQL/issues/79) +- Added `unordered_columns` (`uc`) option for cursor comparison to ignore the order of the columns [#779](https://github.com/utPLSQL/utPLSQL/issues/779) +- Added `ut_debug_reporter` for debug logging [#480](https://github.com/utPLSQL/utPLSQL/issues/480) +- Added `ut_realtime_reporter` for utPLSQL-SQLDeveloper extension [#795](https://github.com/utPLSQL/utPLSQL/issues/795) + +## Important Changes + +- Due to improvements of the cursor comparison, it is now necessary to use `ut.set_nls()` before creating the cursor and `ut.reset_nls()` after the __expectation__ when comparing dates. [More info in the docs](https://github.com/utPLSQL/utPLSQL/blob/v3.1.4/docs/userguide/expectations.md#comparing-cursor-data-containing-date-fields) + +## Enhancements + +- Improved performance of cursor comparison [#780](https://github.com/utPLSQL/utPLSQL/issues/780) +- Added support for installation on databases with block size < 8KB [#848](https://github.com/utPLSQL/utPLSQL/issues/848) +- Added initial timeout to `ut_output_buffer` [#840](https://github.com/utPLSQL/utPLSQL/issues/840) +- Enhanced performance of `get_reporters_list` function [#814](https://github.com/utPLSQL/utPLSQL/issues/814) +- Moved calls of `dbms_lock.sleep` to `dbms_session` for newer DB versions [#806](https://github.com/utPLSQL/utPLSQL/issues/806) +- utPLSQL coverage will now work without re-install after DB-upgrade from 12.1 to 12.2 [#803](https://github.com/utPLSQL/utPLSQL/issues/803) + +## Bug fixes + +- Fixed problem with REGEXP in annotation parsing with NLS CANADIAN FRENCH [#844](https://github.com/utPLSQL/utPLSQL/issues/844) +- Fixed issue with Rollback to savepoint failing on distributed transaction [#839](https://github.com/utPLSQL/utPLSQL/issues/839) +- Fixed reporting of differences when comparing collections scalar values [#835](https://github.com/utPLSQL/utPLSQL/issues/835) +- Fixed issue with test run failing due to too many transaction invalidators [#834](https://github.com/utPLSQL/utPLSQL/issues/834) +- Fixed randomly occurring error during cursor comparison [#827](https://github.com/utPLSQL/utPLSQL/issues/827) +- utPLSQL install script will now support special characters in passwords [#804](https://github.com/utPLSQL/utPLSQL/issues/804) + +## Documentation improvements + +- Fixed documentation examples for context annotation [#851](https://github.com/utPLSQL/utPLSQL/issues/851) +- Added description on how to check version of utPLSQL [#822](https://github.com/utPLSQL/utPLSQL/issues/822) + +## Internal enhancements + +- Implemented Sonar analysis on DBA Views [#850](https://github.com/utPLSQL/utPLSQL/issues/850) +- Finished migration from old-tests [#475](https://github.com/utPLSQL/utPLSQL/issues/475) +- Fixed shell scripts to support multiple unix dialects (especially for macOS) [#796](https://github.com/utPLSQL/utPLSQL/issues/796) +- Added info on project support from Redgate [#841](https://github.com/utPLSQL/utPLSQL/issues/841) +- Added `code_of_conduct` [#836](https://github.com/utPLSQL/utPLSQL/issues/836) +- Added issue templates [#842](https://github.com/utPLSQL/utPLSQL/issues/842) +- Added utPLSQL logo [#845](https://github.com/utPLSQL/utPLSQL/issues/845) + +--- + +## [v3.1.3] - 2018-11-20 + +## New features + +- added function `ut_runner.is_test` [#788](https://github.com/utPLSQL/utPLSQL/issues/788) +- added function `ut_runner.is_suite` [#787](https://github.com/utPLSQL/utPLSQL/issues/787) +- added function `ut_runner.has_suites` [#786](https://github.com/utPLSQL/utPLSQL/issues/786) +- added ability to disable automatic rollback for a test-run [#784](https://github.com/utPLSQL/utPLSQL/issues/784) +- when invoked with package name, utPLSQL will now run only tests from specified package even if package has child packages by suitepath [#776](https://github.com/utPLSQL/utPLSQL/issues/776) + +## Enhancements + +- Improved performance of schema-scanning and utPLSQL startup [#778](https://github.com/utPLSQL/utPLSQL/issues/778) +- Improved performance of output-buffer [#777](https://github.com/utPLSQL/utPLSQL/issues/777) +- Improved documentation to mention ability to pass client encoding for HTML & XML reports [#775](https://github.com/utPLSQL/utPLSQL/issues/775) +- Improved documentation for cursor comparison to mention challenges with TIMESTAMP bind variables + +## Bug-fixes + +- utPLSQL code coverage will now work properly with long object names [#716](https://github.com/utPLSQL/utPLSQL/issues/716) +- utPLSQL installation will now also work properly, when user performing the install has `ANY` grants [#737](https://github.com/utPLSQL/utPLSQL/issues/737) +- fixed documentation bug for `--%context` with `--%displayname` [#726](https://github.com/utPLSQL/utPLSQL/issues/726) +- fixed Teamcity reporter issues with missing escape for some characters and long messages [#747](https://github.com/utPLSQL/utPLSQL/issues/747) +- fixed issue with sonar test results reporter when contexts are used [#749](https://github.com/utPLSQL/utPLSQL/issues/749) +- fixed issue with ORA-07455 getting thrown on cursor comparison [#752](https://github.com/utPLSQL/utPLSQL/issues/752) +- fixed issue with wrong failure message for unordered data [#764](https://github.com/utPLSQL/utPLSQL/issues/764) +- fixed missing privilege issue for unordered/join-by cursor data comparison [#765](https://github.com/utPLSQL/utPLSQL/issues/765) [#770](https://github.com/utPLSQL/utPLSQL/issues/770) + +## Internal enhancements + +- added suite-level cache to allow for faster retrieval of suite contents and enable implementation of additional features [#783](https://github.com/utPLSQL/utPLSQL/issues/783) + +--- + +## [v3.1.2] - 2018-07-22 + +## New features + +- Added ability to join and compare cursor content by specific columns (PK/UK) [#453](https://github.com/utPLSQL/utPLSQL/issues/453) +- Added support for comma separated list of suite paths/packages when calling `ut.run` [#479](https://github.com/utPLSQL/utPLSQL/issues/479) +- Added ability to run a test package that got invalidated due to dependency invalidation [#489](https://github.com/utPLSQL/utPLSQL/issues/489) +- Added support for package level constants and predefined exceptions in `--%throws` annotation [#685](https://github.com/utPLSQL/utPLSQL/issues/685) +- Added support for standalone `--%beforeall`, `--%beforeeach`, `--%afterall`, `--%aftereach` annotations with list of procedures to execute [#649](https://github.com/utPLSQL/utPLSQL/issues/649) +- Added support for list of procedure names in before/after annotations [#649](https://github.com/utPLSQL/utPLSQL/issues/649) +- Added support for BLOB/CLOB in `is_empty()` matcher [#707](https://github.com/utPLSQL/utPLSQL/issues/707) + +## Enhancements + +- utPLSQL will now provide additional warnings, when unsupported annotations are found in a unit test suite package [#624](https://github.com/utPLSQL/utPLSQL/issues/624) +- utPLSQL will now produce valid XML in UT_JUNIT_REPORTER when dbms_output or test results contain ` supported_by_redgate -utPLSQL has been supported by Redgate in the form of sponsored stickers and t-shirts. Thank you for helping us spreading the word! +utPLSQL has been supported by Redgate in the form of sponsored stickers and t-shirts. Thank you for helping us spread the word! +--- + +[Authors](docs/about/authors.md) From 1ab7ab68c7341d658e135d7b56914c7a7c88bddc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 13:01:19 +0300 Subject: [PATCH 597/887] Update CHANGELOG.md --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index aae364bab..d3ad2141f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,7 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ - Added duplicate detection on cursor comparison using `join_by` by @lwasylow in [#1295](https://github.com/utPLSQL/utPLSQL/pull/1295) - Fix code causing the object duration Oracle exception on oracle 23.26 by @lwasylow in [#1310](https://github.com/utPLSQL/utPLSQL/pull/1310) - Packages with annotation-like comments are not test suites by @jgebal in [#1313](https://github.com/utPLSQL/utPLSQL/pull/1313) + - Performance improvements to annotation parsing by @lwasylow in [#1312](https://github.com/utPLSQL/utPLSQL/pull/1319) - Updated documentation and copyright banners across source files @jgebal in [#1319](https://github.com/utPLSQL/utPLSQL/pull/1319) --- From b32e2fbf705140bfccde3251fa98f160367ecb9b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 22 Apr 2026 11:04:38 +0100 Subject: [PATCH 598/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4b0190a75..591b9b6dc 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4361 +4366 diff --git a/docs/about/authors.md b/docs/about/authors.md index b2ee45733..73564c8cf 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 4f97da2a1..7d78f5480 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 3833254af..523623762 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 3f6297dc5..52ff83e1c 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 667092b1c..f027f41a7 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 420aa96ce..9177d4a1e 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8f3f03beb..8f370fa5d 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 16f6e1471..18864b297 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 68ddee6c9..f574c9e1e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 96cb4b0be..d32e2f975 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b1baa871b..f9f114fe0 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 025046ebc..efcb0832b 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index e5d3b8129..987e50672 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index fca25c6ee..1651fcb1d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 7ef328f3e..c7e36ed40 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index aa190fb2f..13341367e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 2ef1a898b..b8bd93570 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c0af7012e..d3a6e2af9 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4361-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4366-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From e5b966b01a192d2b9714117b9582249edab8e353 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 13:40:18 +0300 Subject: [PATCH 599/887] Removed references to Oracle 11, 12, 18 in documentation. --- docs/userguide/annotations.md | 6 +++--- docs/userguide/coverage.md | 19 ++++++++++--------- docs/userguide/expectations.md | 10 +++------- docs/userguide/install.md | 18 +++++------------- 4 files changed, 21 insertions(+), 32 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8f3f03beb..47818e02f 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -46,7 +46,7 @@ package test_package is --%disabled procedure my_first_procedure; - $if dbms_db_version.version >= 12 $then --This is ok - annotation before procedure + $if dbms_db_version.version >= 19 $then --This is ok - annotation before procedure --%test() procedure my_first_procedure; $end @@ -71,7 +71,7 @@ package test_package is procedure proc1; --%test() --This is wrong as there is a compiler directive between procedure and annotation - $if dbms_db_version.version >= 12 $then + $if dbms_db_version.version >= 19 $then procedure proc_12; $end @@ -1755,7 +1755,7 @@ The `--%throws` annotation allows you to specify a list of exceptions as one of: - number literals - example `--%throws(-20134)` - variables of type exception defined in a package specification - example `--%throws(exc_pkg.c_exception_No_variable)` - variables of type number defined in a package specification - example `--%throws(exc_pkg.c_some_exception)` -- [predefined oracle exceptions](https://docs.oracle.com/cd/E11882_01/timesten.112/e21639/exceptions.htm#CIHFIGFE) - example `--%throws(no_data_found)` +- [predefined oracle exceptions](https://docs.oracle.com/en//database/oracle/oracle-database/19/lnpls/predefined-exceptions.html) - example `--%throws(no_data_found)` The annotation is ignored, when no valid arguments are provided. Examples of invalid annotations `--%throws()`,`--%throws`, `--%throws(abe, 723pf)`. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 68ddee6c9..4ca496d54 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,6 +1,6 @@ ![version](https://img.shields.io/badge/version-v3.2.01.4361--develop-blue.svg) -utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting uses package DBMS_PROFILER (and DBMS_PLSQL_CODE_COVERAGE on Oracle database version 12.2 and above) provided with Oracle database. +utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: * package bodies @@ -27,7 +27,7 @@ The following code coverage reporters are supplied with utPLSQL: * `ut_coverage_cobertura_reporter` - generates a basic Cobertura coverage (http://cobertura.sourceforge.net/xml/coverage-04.dtd) report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by services like TFS and Jenkins. Check this link for an example of XML generated by Java: https://raw.githubusercontent.com/jenkinsci/cobertura-plugin/master/src/test/resources/hudson/plugins/cobertura/coverage-with-data.xml ## Security model -utPLSQL code coverage uses DBMS_PROFILER to gather information about the execution of code under test and therefore follows the [DBMS_PROFILER's Security Model](https://docs.oracle.com/database/121/ARPLS/d_profil.htm#ARPLS67465). +utPLSQL code coverage uses DBMS_PROFILER to gather information about the execution of code under test and therefore follows the [DBMS_PROFILER's Security Model](https://docs.oracle.com/en/database/oracle/oracle-database/19/arpls/DBMS_PROFILER.html#GUID-DEE5EA97-14AA-4AF2-A5F7-4AB1D004B99F). In order to be able to gather coverage information, the user executing unit tests needs to be either: * The owner of the code that is being tested @@ -63,14 +63,15 @@ The report allow you to navigate to each source file and inspect line by line co ![Coverage Details page](../images/coverage_html_details.png) -### Oracle 12.2 extended coverage with profiler and block coverage -Using data collected from profiler and block coverage running parallel we are able to enrich information about coverage. -For every line recorded by the profiler if we have a partially covered same line in block coverage we will display that information -presenting line as partially covered, displaying number of block and how many blocks have been covered in that line.The feature will be automatically enabled in the Oracle database version 12.2 and higher, for older versions current profiler will be used. +### Partial Coverage -utPLSQL installation automatically creates tables needed by `dbms_plsql_code_coverage` on databases in versions above 12c Release 1. -Due to security model of `dbms_plsql_code_coverage` package, utPLSQL grants access to those tables and creates synonyms for those tables. -The access and synonyms will be public when using the headless installation. This approach avoids complexity of forcing every user of utPLSQL framework to create tables on their own. +#### What it does +Partial coverage combines two data sources — the profiler and block coverage — to give you a more detailed picture of which parts of your code have been tested. +When a line appears in both sources, and block coverage shows it was only partially covered, the display will reflect that: you'll see the line marked as partially covered, along with how many blocks on that line were executed out of the total. + +#### Setup and permissions +utPLSQL automatically creates the tables required by Oracle's dbms_plsql_code_coverage package — you don't need to create them manually. +Because of how dbms_plsql_code_coverage handles security, utPLSQL also takes care of granting access to those tables and creating the necessary synonyms. In a headless installation, both the grants and synonyms are made public, keeping things simple without requiring every utPLSQL user to set up their own tables. Sample output: diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b1baa871b..3f4bd6222 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -648,9 +648,7 @@ Syntax: `ut.expect( a_actual ).to_be_like( a_mask [, a_escape_char] )` -Parameters `a_mask` and `a_escape_char` represent valid parameters of the [Oracle LIKE condition](https://docs.oracle.com/database/121/SQLRF/conditions007.htm#SQLRF52142). - -If you use Oracle Database version 11.2.0.4, you may run into Oracle Bug 14402514: WRONG RESULTS WITH LIKE ON CLOB USING ESCAPE CHARACTER. In this case we recommend to use `match` instead of `be_like`. +Parameters `a_mask` and `a_escape_char` represent valid parameters of the [Oracle LIKE condition](https://docs.oracle.com/en/database/oracle/oracle-database/19/sqlrf/Pattern-matching-Conditions.html). Usage: ```sql linenums="1" @@ -1224,9 +1222,7 @@ utPLSQL is capable of comparing compound data-types including: - Comparison of cursor returning `TIMESTAMP` **columns** against cursor returning `TIMESTAMP` **bind variables** requires variables to be cast to proper precision. This is an Oracle SQL - PLSQL compatibility issue and usage of CAST is the only known workaround for now. See [Comparing cursor data containing TIMESTAMP bind variables](#comparing-cursor-data-containing-timestamp-bind-variables) for examples. - To compare nested table/varray type you need to convert it to `anydata` by using `anydata.convertCollection()` - To compare object type you need to convert it to `anydata` by using `anydata.convertObject()` -- It is possible to compare PL/SQL records, collections, varrays and associative arrays. To compare this types of data, use cursor comparison feature of utPLSQL and TABLE operator in SQL query - - On Oracle 11g Release 2 - pipelined table functions are needed (see section [Implicit (Shadow) Types in this artcile](https://oracle-base.com/articles/misc/pipelined-table-functions)) - - On Oracle 12c and above - use [TABLE function on nested tables/varrays/associative arrays of PL/SQL records](https://oracle-base.com/articles/12c/using-the-table-operator-with-locally-defined-types-in-plsql-12cr1) +- It is possible to compare PL/SQL records, collections, varrays and associative arrays. To compare this types of data, use cursor comparison feature of utPLSQL and [TABLE operator in SQL query](https://oracle-base.com/articles/12c/using-the-table-operator-with-locally-defined-types-in-plsql-12cr1) - utPLSQL is not able to distinguish between NULL and whitespace-only column/attribute value when comparing compound data. This is due to Oracle limitation on of XMLType. See [issue #880](https://github.com/utPLSQL/utPLSQL/issues/880) for details. *Note: This behavior might be fixed in future releases, when utPLSQL is no longer depending on XMLType for compound data comparison.* @@ -1763,7 +1759,7 @@ FAILURE ## Comparing Json objects -utPLSQL is capable of comparing json data-types of `json_element_t` **on Oracle 12.2 and above**, and also `json` **on Oracle 21 and above** +utPLSQL is capable of comparing json data-types of `json_element_t`, and also `json` **on Oracle 21 and above** !!! note Whenever a database is upgraded to compatible version the utPLSQL needs to be reinstalled to pick up json changes. E.g. upgrade from 18c to 21c to enable `json` type compare. diff --git a/docs/userguide/install.md b/docs/userguide/install.md index e5d3b8129..235e3ad82 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -2,19 +2,11 @@ ## Supported database versions -utPLSQL is continuously tested against following versions of Oracle databases +- Oracle Database 19c or newer (SE/EE/Cloud/Free) -* 11g R2 -* 12c -* 12c R2 -* 18c -* 19c +We do our best to assure full compatibility with **actively supported** versions of Oracle databases. +See [this page](https://www.oracle.com/us/support/library/lifetime-support-technology-069183.pdf#page=6) for Oracle Database Releases and their Support Lifetime by Oracle. -We do our best to assure full compatibility with supported versions of Oracle databases [See](http://www.oracle.com/us/support/library/lifetime-support-technology-069183.pdf#page=6) - -## Requirements - -utPLSQL will run on any Oracle Database version 11g relase 2 or above. ### Licensed features required @@ -179,7 +171,7 @@ If the installing user and utPLSQL owner is one and the same, the user must have In addition, the user must be granted the execute privilege on `DBMS_LOCK` and `DBMS_CRYPTO` packages. -utPLSQL is using [DBMS_PROFILER tables](https://docs.oracle.com/cd/E18283_01/appdev.112/e16760/d_profil.htm#i999476) for code coverage. The tables required by DBMS_PROFILER will be created in the installation schema unless they already exist. +utPLSQL is using [DBMS_PROFILER tables](https://docs.oracle.com/en/database/oracle/oracle-database/19/arpls/DBMS_PROFILER.html) for code coverage. The tables required by DBMS_PROFILER will be created in the installation schema unless they already exist. It is up to DBA to maintain the storage of the profiler tables. @@ -274,7 +266,7 @@ select ## Additional requirements In order to use the Code Coverage functionality of utPLSQL, users executing the tests must have the CREATE privilege on the PLSQL code that the coverage is gathered on. -This is a requirement of [DBMS_PROFILER package](https://docs.oracle.com/cd/E18283_01/appdev.112/e16760/d_profil.htm#i999476). +This is a requirement of [DBMS_PROFILER package](https://docs.oracle.com/en/database/oracle/oracle-database/19/arpls/DBMS_PROFILER.html#GUID-DEE5EA97-14AA-4AF2-A5F7-4AB1D004B99F). In practice, user running tests for PLSQL code that he does not own, needs to have CREATE ANY PROCEDURE/CREATE ANY TRIGGER privileges. Running code coverage on objects that the user does not own will **not produce any coverage information** without those privileges. From 8fa483ec14bad87785006b43c01d8bacf05ec63f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 22 Apr 2026 12:11:22 +0100 Subject: [PATCH 600/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 591b9b6dc..81b1d8a7e 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4366 +4371 diff --git a/docs/about/authors.md b/docs/about/authors.md index 73564c8cf..ae790e611 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 7d78f5480..160567b6f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 523623762..e867e7ad4 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 52ff83e1c..f8e806019 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index f027f41a7..c797cd6d1 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 9177d4a1e..c56e413ba 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 7259e9f68..466f755b7 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 18864b297..ce901fe8d 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 59b70270c..c7ae7b6ad 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index d32e2f975..e16981591 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0b490ac5b..dea108844 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index efcb0832b..c63ced510 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 9673668ef..a7dbf0cf4 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 1651fcb1d..623694390 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index c7e36ed40..297881659 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 13341367e..565f1c1ff 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index b8bd93570..17de0556a 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4366--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 921996f7f..eea9ee5cc 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4366-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4371-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ee69baffc4bf5f5255407664288e2675f29a625c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 14:12:40 +0300 Subject: [PATCH 601/887] Update of refresh sources - remove git repo references --- development/refresh_sources.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/development/refresh_sources.sh b/development/refresh_sources.sh index 83518d7cc..87869d581 100755 --- a/development/refresh_sources.sh +++ b/development/refresh_sources.sh @@ -9,6 +9,7 @@ git rev-parse && cd "$(git rev-parse --show-cdup)" rm -rf ${UTPLSQL_DIR:-utPLSQL_latest_release} # clone utPLSQL main branch from upstream into utPLSQL sub-directory of your project git clone --depth=1 --branch=${SELFTESTING_BRANCH:-main} https://github.com/utPLSQL/utPLSQL.git ${UTPLSQL_DIR:-utPLSQL_latest_release} +rm -rf ${UTPLSQL_DIR:-utPLSQL_latest_release}/.git rm -rf utPLSQL-cli/* # download latest release version of utPLSQL-cli From 5b79bd8267cd8ec5c871b3c13a22b72616c07ff4 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 22 Apr 2026 12:18:50 +0100 Subject: [PATCH 602/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 81b1d8a7e..12cd854ce 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4371 +4372 diff --git a/docs/about/authors.md b/docs/about/authors.md index ae790e611..3041eb36b 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 160567b6f..e78d36f14 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index e867e7ad4..360cc4e07 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index f8e806019..4169c1a88 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index c797cd6d1..8b3283ca9 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index c56e413ba..adb623892 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 466f755b7..8d8405c29 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index ce901fe8d..ccfdd5aa5 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index c7ae7b6ad..a46add1f4 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e16981591..d0753bf3b 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index dea108844..17a39d362 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c63ced510..460766ca8 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index a7dbf0cf4..402180d1f 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 623694390..5a970b328 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 297881659..cef7a944b 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 565f1c1ff..0d9e4d706 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 17de0556a..425bd69be 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4371--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index eea9ee5cc..6c3555cd8 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4371-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4372-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 5e80efae15a9c798e4f86fb7d94b5178384eee13 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 14:21:25 +0300 Subject: [PATCH 603/887] Update documentation --- docs/userguide/expectations.md | 4 ++-- docs/userguide/install.md | 7 +------ 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 17a39d362..109799dfc 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -804,7 +804,7 @@ Syntax: `ut.expect( a_actual ).to_match( a_pattern [, a_modifiers] );` -Parameters `a_pattern` and `a_modifiers` represent a valid regexp pattern accepted by [Oracle REGEXP_LIKE condition](https://docs.oracle.com/database/121/SQLRF/conditions007.htm#SQLRF00501) +Parameters `a_pattern` and `a_modifiers` represent a valid regexp pattern accepted by [Oracle REGEXP_LIKE condition](https://docs.oracle.com/en/database/oracle/oracle-database/19/sqlrf/Pattern-matching-Conditions.html#GUID-D2124F3A-C6E4-4CCA-A40E-2FFCABFD8E19) Usage: ```sql linenums="1" @@ -1762,7 +1762,7 @@ FAILURE utPLSQL is capable of comparing json data-types of `json_element_t`, and also `json` **on Oracle 21 and above** !!! note - Whenever a database is upgraded to compatible version the utPLSQL needs to be reinstalled to pick up json changes. E.g. upgrade from 18c to 21c to enable `json` type compare. + Whenever a database is upgraded to compatible version the utPLSQL needs to be reinstalled to pick up json changes. E.g. upgrade from 19c to 23 AI to enable `json` type compare. ### Notes on comparison of json data diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 402180d1f..a286cbe18 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -10,9 +10,7 @@ See [this page](https://www.oracle.com/us/support/library/lifetime-support-techn ### Licensed features required -utPLSQL doesn't require any extra licensed features of Oracle database. It can be installed on any Standard Edition Oracle Database. - -In fact, it even supports Oracle 11g XE which is a free Oracle Database version with minimal features and storage limits. +utPLSQL doesn't require any extra licensed features of Oracle database. It can be installed on any Edition of Oracle Database. ### Storage requirements @@ -116,9 +114,6 @@ The scripts need to be executed by `SYSDBA`, in order to grant access to `DBMS_L - `DBMS_LOCK` is required for session synchronization between main session and session consuming realtime reports.
    - The user performing the installation must have the `ADMINISTER DATABASE TRIGGER` privilege. This is required for installation of trigger that is responsible for parsing annotations at at compile-time of a package.
    - When installed with DDL trigger, utPLSQL will not be registering unit tests for any of oracle-maintained schemas.
    - - For Oracle 11g following users are excluded:
    - ANONYMOUS, APPQOSSYS, AUDSYS, DBSFWUSER, DBSNMP, DIP, GGSYS, GSMADMIN_INTERNAL, GSMCATUSER, GSMUSER, ORACLE_OCM, OUTLN, REMOTE_SCHEDULER_AGENT, SYS, SYS$UMF, SYSBACKUP, SYSDG, SYSKM, SYSRAC, SYSTEM, WMSYS, XDB, XS$NULL
    - - For Oracle 12c and above the users returned by below query are excluded by utPLSQL:
    `select username from all_users where oracle_maintained='Y';`
    ### Installation without DDL trigger From 9e659c4d4b169258257caefc67df5c622b7c924f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 22 Apr 2026 12:27:44 +0100 Subject: [PATCH 604/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 12cd854ce..ae1550799 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4372 +4373 diff --git a/docs/about/authors.md b/docs/about/authors.md index 3041eb36b..e3736ca96 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index e78d36f14..a8bc7c21a 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 360cc4e07..722f603ee 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 4169c1a88..eb73d4adb 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 8b3283ca9..eb44d57c4 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index adb623892..5a2d2cd83 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8d8405c29..8add10a7b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index ccfdd5aa5..100b7da11 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index a46add1f4..7c80396b2 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index d0753bf3b..9648be0f6 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 109799dfc..b4745dd18 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 460766ca8..8e5b8d9bd 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index a286cbe18..23b5f5cb4 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 5a970b328..76044c619 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index cef7a944b..7d7606963 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 0d9e4d706..d8e5ad36c 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 425bd69be..88ca240c1 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4372--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6c3555cd8..388928a74 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4372-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4373-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From d4478651d7e066ea54d7fdd492d0e9a22d87246c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 14:43:56 +0300 Subject: [PATCH 605/887] Update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d3ad2141f..f75662f75 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,7 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ --- -## [v3.2.01] - unreleased +## [v3.2.01] - 2026-04-22 ## Important - Dropped support for Oracle Database versions older than 19c From 3d21de6520d0480f302296d288882dc0ad02298b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 22 Apr 2026 12:50:14 +0100 Subject: [PATCH 606/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index ae1550799..bce5ffdd8 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4373 +4374 diff --git a/docs/about/authors.md b/docs/about/authors.md index e3736ca96..8d53b662c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index a8bc7c21a..3d02ef041 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 722f603ee..6e101b18a 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index eb73d4adb..529a89cd4 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index eb44d57c4..2bb7d19e0 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 5a2d2cd83..8e21d13ff 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8add10a7b..5ee141ad7 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 100b7da11..65db4a49c 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 7c80396b2..dcf7855f8 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 9648be0f6..fef6e5602 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b4745dd18..2cb1aeca7 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8e5b8d9bd..c07624cd2 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 23b5f5cb4..0d3ba6790 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 76044c619..5bd1755a2 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 7d7606963..e08f035ae 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index d8e5ad36c..889455594 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 88ca240c1..13063c3d5 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4373--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 388928a74..f28dc4e1d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4373-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4374-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 8db20e2e62fd6fbbac617418d354f9b36c3509fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 22 Apr 2026 14:50:26 +0300 Subject: [PATCH 607/887] Removed old references to travis from links and documentation. --- docs/about/license.md | 4 ---- sonar-project.properties | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/docs/about/license.md b/docs/about/license.md index 3d02ef041..320b7c24f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -9,9 +9,5 @@ External code used in the development of this project, but is not required for u | Tool | License | Purpose | | ---- | --------| --------| -| [Travis-Oracle](https://github.com/cbandy/travis-oracle) | [ISC](https://github.com/cbandy/travis-oracle/blob/master/LICENSE) | Install Oracle for Travis Builds | | [mkDocs](http://www.mkdocs.org/) | [BSD](http://www.mkdocs.org/about/license/) | Produce HTML version of documentation | -**Note:** - -Version 1 & 2 of utPLSQL were licensed under GPL, version 3 was a complete rewrite from scratch which a allowed us to change the license to be more permissive. diff --git a/sonar-project.properties b/sonar-project.properties index 24e77c11f..efcaeb5e6 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -15,7 +15,7 @@ sonar.coverage.exclusions=**/*.sql,**/*.pks sonar.tests=./test sonar.testExecutionReportPaths=./test_results.xml sonar.links.issue=https://github.com/utPLSQL/utPLSQL/issues -sonar.links.ci=https://travis-ci.org/utPLSQL/utPLSQL +sonar.links.ci=https://github.com/utPLSQL/utPLSQL/actions sonar.links.homepage=https://github.com/utPLSQL/utPLSQL sonar.projectDescription=PL/SQL Unit Testing Framework sonar.plsql.file.suffixes=sql,tab,pkb,tpb From 698dcd65cda1c47e66c9c46ba8805ab130a33288 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 22 Apr 2026 12:57:43 +0100 Subject: [PATCH 608/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index bce5ffdd8..61cb37f72 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4374 +4375 diff --git a/docs/about/authors.md b/docs/about/authors.md index 8d53b662c..e55e244a7 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 320b7c24f..bd60e0af4 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 6e101b18a..4f1086a89 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 529a89cd4..ae284c8b7 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 2bb7d19e0..bced9d1e9 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 8e21d13ff..d18e15f23 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 5ee141ad7..6ee24ed59 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 65db4a49c..0bd08a80d 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index dcf7855f8..43187f22c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index fef6e5602..6b6ae8bc9 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 2cb1aeca7..aa7efdde0 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c07624cd2..db5a08115 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 0d3ba6790..095fd4085 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 5bd1755a2..4f2a53b28 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index e08f035ae..a29c5c3ef 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 889455594..a9906cb78 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 13063c3d5..f3ffa333c 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4374--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f28dc4e1d..6f9a3abfd 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4374-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4375-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 87b85e2e8ec9506e5f51f0c0dc3c477ab0d1d15a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 28 Apr 2026 14:17:44 +0300 Subject: [PATCH 609/887] update project badges --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index df3da2749..7af2183c5 100644 --- a/readme.md +++ b/readme.md @@ -1,7 +1,7 @@ ![utPLSQL v3 | Testing Framework for PL/SQL](docs/images/utPLSQL-testing-framework-transparent_120.png) -[![license](https://img.shields.io/github/license/utPLSQL/utPLSQL.svg)](https://www.apache.org/licenses/LICENSE-2.0) [![latest-release](https://img.shields.io/github/release/utPLSQL/utPLSQL.svg)](https://github.com/utPLSQL/utPLSQL/releases) +[![license](https://img.shields.io/github/license/utPLSQL/utPLSQL.svg)](https://www.apache.org/licenses/LICENSE-2.0) [![GitHub Discussions](https://img.shields.io/github/discussions/utPLSQL/utPLSQL)](https://github.com/utPLSQL/utPLSQL/discussions) [![X](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) [![build](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml/badge.svg)](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml) From f8ca2a1638e0be6f5a96c8f9da51f818d0384a2f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 28 Apr 2026 12:25:13 +0100 Subject: [PATCH 610/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 61cb37f72..2de2f86bc 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4375 +4376 diff --git a/docs/about/authors.md b/docs/about/authors.md index e55e244a7..9e579017d 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index bd60e0af4..8c578d28b 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 4f1086a89..92f88cc49 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index ae284c8b7..54ad28b4c 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index bced9d1e9..f35b69f33 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index d18e15f23..8f0fd070c 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 6ee24ed59..41eee96cf 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0bd08a80d..1e1044f65 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 43187f22c..4448609b0 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 6b6ae8bc9..c3b844893 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index aa7efdde0..75fec8c59 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index db5a08115..e8e9b7215 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 095fd4085..d31f5b9a0 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 4f2a53b28..020d372f0 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index a29c5c3ef..abbe1a216 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a9906cb78..7248c6e40 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index f3ffa333c..207cfeb84 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4375--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6f9a3abfd..1e0e38b93 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4375-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4376-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 955c7cdb9f0545dcfab4abe5667f8656c6b22757 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 28 Apr 2026 19:46:07 +0300 Subject: [PATCH 611/887] Removed publishing of build status to slack. --- .github/workflows/build.yml | 14 -------------- .github/workflows/release.yml | 15 --------------- 2 files changed, 29 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index be6e18ca2..a83281b38 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -276,17 +276,3 @@ jobs: repository: ${{ matrix.repo }} event-type: utPLSQL-build - slack-workflow-status: - if: always() - name: Post Workflow Status To Slack - needs: [ build, publish, dispatch ] - runs-on: ubuntu-latest - timeout-minutes: 10 - steps: - - name: Slack Workflow Notification - uses: Gamesight/slack-workflow-status@master - with: - repo_token: ${{secrets.GITHUB_TOKEN}} - slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} - name: 'Github Actions[bot]' - icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ab043b6eb..4b5d59463 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -65,18 +65,3 @@ jobs: utPLSQL.tar.gz utPLSQL.tar.gz.md5 - slack-workflow-status: - if: always() - name: Post Workflow Status To Slack - needs: [ upload_artifacts ] - runs-on: ubuntu-latest - timeout-minutes: 10 - steps: - - name: Slack Workflow Notification - uses: Gamesight/slack-workflow-status@master - with: - repo_token: ${{secrets.GITHUB_TOKEN}} - slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL}} - name: 'Github Actions[bot]' - icon_url: 'https://octodex.github.com/images/mona-the-rivetertocat.png' - From 2742ab43bb9736416131762bd172e44de20d9195 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 28 Apr 2026 17:53:21 +0100 Subject: [PATCH 612/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 2de2f86bc..730c621b8 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4376 +4377 diff --git a/docs/about/authors.md b/docs/about/authors.md index 9e579017d..518900d79 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 8c578d28b..c32e5ea2f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 92f88cc49..b08ff3eda 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 54ad28b4c..9b71734f8 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index f35b69f33..a7d507ea1 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 8f0fd070c..429163a3b 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 41eee96cf..6ada50701 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 1e1044f65..2f8981533 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4448609b0..4d60ea34b 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index c3b844893..cd4651b5c 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 75fec8c59..198c285ee 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index e8e9b7215..7c93fc1e6 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index d31f5b9a0..482529af3 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 020d372f0..65fa92216 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index abbe1a216..7f74eca6b 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 7248c6e40..7e60f81f2 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 207cfeb84..2941d90d3 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4376--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 1e0e38b93..c80ff9c50 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4376-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4377-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 566b9ec8b05e8a58eee4c3f864a458bdb124cba3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 6 May 2026 23:51:38 +0300 Subject: [PATCH 613/887] Filtering by tags fixed for schemas containing suite-paths and contexts Resolves: #1324 --- source/core/ut_suite_tag_filter.pkb | 187 +++++++++--------- test/install_and_run_tests.sh | 3 +- .../core/test_ut_suite_tag_filter.pkb | 32 +++ .../core/test_ut_suite_tag_filter.pks | 5 +- 4 files changed, 128 insertions(+), 99 deletions(-) diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index 353793bc5..17b5ba4b0 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -19,29 +19,28 @@ create or replace package body ut_suite_tag_filter is /** * Constants use in postfix and infix transformations */ - gc_operators constant ut_varchar2_list := ut_varchar2_list('|','&','!'); + gc_operators constant ut_varchar2_list := ut_varchar2_list('|','&','!'); gc_unary_operators constant ut_varchar2_list := ut_varchar2_list('!'); -- right side associative operator gc_binary_operators constant ut_varchar2_list := ut_varchar2_list('|','&'); -- left side associative operator gc_reserved_tag_words constant ut_varchar2_list := ut_varchar2_list('none','any'); - gc_tags_column_name constant varchar2(250) := 'tags'; gc_exception_msg constant varchar2(200) := 'Invalid tag expression'; - - type t_precedence_table is table of number index by varchar2(1); - g_precedence t_precedence_table; + + type t_precedence_table is table of number index by varchar2(1); + g_precedence t_precedence_table; function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list is - l_tags_tokens ut_varchar2_list := ut_varchar2_list(); + l_tags_tokens ut_varchar2_list := ut_varchar2_list(); begin --Tokenize a string into operators and tags select regexp_substr(a_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts bulk collect into l_tags_tokens from dual connect by regexp_substr (a_tags, '([^!()|&]+)|([!()|&])', 1, level) is not null; - + return l_tags_tokens; end; /* - To support a legact tag notation + To support a legact tag notation , = OR - = NOT we will perform a replace of that characters into @@ -57,36 +56,36 @@ create or replace package body ut_suite_tag_filter is l_tags_exclude varchar2(4000); l_return_tag varchar2(4000); begin - if instr(a_tags,',') > 0 or instr(a_tags,'-') > 0 then + if instr(a_tags,',') > 0 or instr(a_tags,'-') > 0 then select '('||listagg( t.column_value,'|') - within group( order by column_value)||')' + within group( order by column_value)||')' into l_tags_include from table(l_tags) t where t.column_value not like '-%'; - + select '('||listagg( replace(t.column_value,'-','!'),' & ') within group( order by column_value)||')' into l_tags_exclude from table(l_tags) t - where t.column_value like '-%'; - + where t.column_value like '-%'; + l_return_tag:= - case + case when l_tags_include <> '()' and l_tags_exclude <> '()' then l_tags_include || ' & ' || l_tags_exclude when l_tags_include <> '()' then l_tags_include when l_tags_exclude <> '()' - then l_tags_exclude + then l_tags_exclude end; - else + else l_return_tag := a_tags; - end if; + end if; return l_return_tag; end; - + /* https://stackoverflow.com/questions/29634992/shunting-yard-validate-expression */ @@ -97,14 +96,14 @@ create or replace package body ut_suite_tag_filter is l_expect_operand boolean := true; l_expect_operator boolean := false; l_idx pls_integer; - begin + begin l_idx := a_tags.first; --Exuecute modified shunting algorithm WHILE (l_idx is not null) loop l_token := a_tags(l_idx); if (l_token member of gc_operators and l_token member of gc_binary_operators) then - if not(l_expect_operator) then - raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); + if not(l_expect_operator) then + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); end if; while l_operator_stack.top > 0 and (g_precedence(l_operator_stack.peek) > g_precedence(l_token)) loop l_rnp_tokens.extend; @@ -113,56 +112,56 @@ create or replace package body ut_suite_tag_filter is l_operator_stack.push(a_tags(l_idx)); l_expect_operand := true; l_expect_operator:= false; - elsif (l_token member of gc_operators and l_token member of gc_unary_operators) then - if not(l_expect_operand) then - raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); - end if; + elsif (l_token member of gc_operators and l_token member of gc_unary_operators) then + if not(l_expect_operand) then + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); + end if; l_operator_stack.push(a_tags(l_idx)); l_expect_operand := true; - l_expect_operator:= false; + l_expect_operator:= false; elsif l_token = '(' then - if not(l_expect_operand) then - raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); - end if; + if not(l_expect_operand) then + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); + end if; l_operator_stack.push(a_tags(l_idx)); l_expect_operand := true; - l_expect_operator:= false; + l_expect_operator:= false; elsif l_token = ')' then - if not(l_expect_operator) then - raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); - end if; + if not(l_expect_operator) then + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); + end if; while l_operator_stack.peek <> '(' loop l_rnp_tokens.extend; l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; end loop; l_operator_stack.pop; --Pop the open bracket and discard it l_expect_operand := false; - l_expect_operator:= true; + l_expect_operator:= true; else - if not(l_expect_operand) then - raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); + if not(l_expect_operand) then + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); end if; l_rnp_tokens.extend; l_rnp_tokens(l_rnp_tokens.last) :=l_token; l_expect_operator := true; l_expect_operand := false; end if; - + l_idx := a_tags.next(l_idx); end loop; - + while l_operator_stack.peek is not null loop - if l_operator_stack.peek in ('(',')') then - raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); - end if; + if l_operator_stack.peek in ('(',')') then + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); + end if; l_rnp_tokens.extend; - l_rnp_tokens(l_rnp_tokens.last):=l_operator_stack.pop; + l_rnp_tokens(l_rnp_tokens.last):=l_operator_stack.pop; end loop; - + return l_rnp_tokens; end shunt_logical_expression; - - function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list,a_tags_column_name in varchar2) + + function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list,a_tags_column_name in varchar2) return varchar2 is l_infix_stack ut_stack := ut_stack(); l_right_side varchar2(32767); @@ -175,9 +174,9 @@ create or replace package body ut_suite_tag_filter is while ( l_idx is not null) loop --If the token we got is a none or any keyword if a_postfix_exp(l_idx) member of gc_reserved_tag_words then - - l_infix_stack.push( - case + + l_infix_stack.push( + case when a_postfix_exp(l_idx) = 'none' then '('||a_tags_column_name||' is empty or '||a_tags_column_name||' is null)' else a_tags_column_name||' is not empty' end @@ -185,12 +184,12 @@ create or replace package body ut_suite_tag_filter is --If token is operand but also single tag elsif regexp_count(a_postfix_exp(l_idx),'[!()|&]') = 0 then l_infix_stack.push(q'[']'||a_postfix_exp(l_idx)||q'[']'||l_member_token); - --If token is unary operator not + --If token is unary operator not elsif a_postfix_exp(l_idx) member of gc_unary_operators then l_right_side := l_infix_stack.pop; l_infix_exp := a_postfix_exp(l_idx)||'('||l_right_side||')'; l_infix_stack.push(l_infix_exp); - --If token is binary operator + --If token is binary operator elsif a_postfix_exp(l_idx) member of gc_binary_operators then l_right_side := l_infix_stack.pop; l_left_side := l_infix_stack.pop; @@ -199,7 +198,7 @@ create or replace package body ut_suite_tag_filter is end if; l_idx := a_postfix_exp.next(l_idx); end loop; - + return l_infix_stack.pop; end conv_postfix_to_infix_sql; @@ -208,73 +207,69 @@ create or replace package body ut_suite_tag_filter is l_tags varchar2(4000); begin l_tags := replace(replace_legacy_tag_notation(a_tags),' '); - l_tags := conv_postfix_to_infix_sql(shunt_logical_expression(tokenize_tags_string(l_tags)),gc_tags_column_name); + l_tags := conv_postfix_to_infix_sql(shunt_logical_expression(tokenize_tags_string(l_tags)),'tags'); l_tags := replace(l_tags, '|',' or '); l_tags := replace(l_tags ,'&',' and '); l_tags := replace(l_tags ,'!','not'); - return l_tags; - end; + return l_tags; + end; /* Having a base set of suites we will do a further filter down if there are any tags defined. - */ + */ function get_tags_suites ( a_suite_items ut_suite_cache_rows, a_tags varchar2 ) return ut_suite_cache_rows is - l_suite_tags ut_suite_cache_rows := ut_suite_cache_rows(); + l_results ut_suite_cache_rows; l_sql varchar2(32000); - l_tags varchar2(4000):= create_where_filter(a_tags); + l_tags_filter_clause varchar2(4000):= create_where_filter(a_tags); begin l_sql := q'[ -with - suites_mv as ( - select c.id,value(c) as obj,c.path as path,c.self_type,c.object_owner,c.tags as ]'||gc_tags_column_name||q'[ - from table(:suite_items) c - ), - suites_matching_expr as ( - select c.id,c.path as path,c.self_type,c.object_owner,c.tags - from suites_mv c - where c.self_type in ('UT_SUITE','UT_CONTEXT') - and ]'||l_tags||q'[ - ), - tests_matching_expr as ( - select c.id,c.path as path,c.self_type,c.object_owner,c.tags as ]'||gc_tags_column_name||q'[ - from suites_mv c where c.self_type in ('UT_TEST') - and ]'||l_tags||q'[ - ), - tests_with_tags_inh_from_suite as ( - select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags as ]'||gc_tags_column_name||q'[ ,c.object_owner - from suites_mv c join suites_matching_expr t - on (c.path||'.' like t.path || '.%' /*all descendants and self*/ and c.object_owner = t.object_owner) - ), - tests_with_tags_prom_to_suite as ( - select c.id,c.self_type,c.path,c.tags multiset union distinct t.tags as ]'||gc_tags_column_name||q'[ ,c.object_owner - from suites_mv c join tests_matching_expr t - on (t.path||'.' like c.path || '.%' /*all ancestors and self*/ and c.object_owner = t.object_owner) - ) - select obj from suites_mv c, - (select id,row_number() over (partition by id order by id) r_num from - (select id - from tests_with_tags_prom_to_suite tst - where ]'||l_tags||q'[ - union all - select id from tests_with_tags_inh_from_suite tst - where ]'||l_tags||q'[ - ) - ) t where c.id = t.id and r_num = 1 ]'; - execute immediate l_sql bulk collect into l_suite_tags using a_suite_items; - return l_suite_tags; + with + suites_mv as ( + select c.id,value(c) as obj,c.path as path,c.self_type,c.object_owner,c.tags as tags + from table(:suite_items) c + ), + propagate_tags_from_ancestors as ( + select c.id, c.self_type, c.path, c.object_owner, cast(collect(c_tags.tag) as ut_varchar2_rows) as tags + from suites_mv c + left join suites_mv t + on t.self_type in ('UT_SUITE','UT_SUITE_CONTEXT') + and c.path like t.path||'.%' /* all descendants */ + and c.object_owner = t.object_owner + outer apply (select column_value tag from table(c.tags) union select column_value tag from table(t.tags) ) c_tags + group by c.id, c.self_type, c.path, c.object_owner + ), + filter_by_tags as ( + select * + from propagate_tags_from_ancestors x + where ( ]'||l_tags_filter_clause||q'[ ) + ), + only_items_with_tests as ( + select item.obj + from suites_mv item + where exists ( + select 1 + from filter_by_tags tst + where tst.self_type in ('UT_TEST') + and (tst.path||'.' like item.path || '.%' /*all descendants and self*/ and item.object_owner = tst.object_owner) + ) + ) + select obj from only_items_with_tests]'; + execute immediate l_sql bulk collect into l_results using a_suite_items; + + return l_results; end; function apply( a_unfiltered_rows ut_suite_cache_rows, a_tags varchar2 := null ) return ut_suite_cache_rows is - l_suite_items ut_suite_cache_rows := a_unfiltered_rows; + l_suite_items ut_suite_cache_rows := a_unfiltered_rows; begin if length(a_tags) > 0 then l_suite_items := get_tags_suites(l_suite_items,a_tags); diff --git a/test/install_and_run_tests.sh b/test/install_and_run_tests.sh index 1719f137a..0c17b08b7 100755 --- a/test/install_and_run_tests.sh +++ b/test/install_and_run_tests.sh @@ -1,10 +1,9 @@ #!/bin/bash set -ev -. ./development/env.sh - #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" +. ./development/env.sh cd test time . ./install_tests.sh diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index edfb27cfc..dd0bb5f71 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -78,5 +78,37 @@ create or replace package body test_ut_suite_tag_filter is ut.expect(l_sql_filter).to_equal(q'[('test1' member of tags and not('test2' member of tags))]'); end; + procedure filtering_is_correctly_applied_to_all_items is + l_input_data ut3_develop.ut_suite_cache_rows; + l_expected sys_refcursor; + l_actual sys_refcursor; + begin + l_input_data := ut3_develop.ut_suite_cache_rows( + ut3_develop.ut_suite_cache_row( + 1, 'UT_SUITE', 'some.path.test_tags', 'TEST_USER', 'TEST_TAGS', 'TEST_TAGS', 3, timestamp '2026-05-06 10:23:38.461299', NULL, NULL, 0, NULL, null, null, null, null, null, null, null, null, + ut3_develop.ut_varchar2_rows('slow'), null), + ut3_develop.ut_suite_cache_row( + 2, 'UT_SUITE_CONTEXT', 'some.path.test_tags.nested_context_#1', 'TEST_USER', 'TEST_TAGS', 'NESTED_CONTEXT_#1', 9, timestamp '2026-05-06 10:23:38.461299', 'tags_are_applied_in_contexts', NULL, 0, NULL, null, null, null, null, null, null, null, null, + ut3_develop.ut_varchar2_rows('context_tag'), null), + ut3_develop.ut_suite_cache_row( + 3, 'UT_TEST', 'some.path.test_tags.nested_context_#1.create_new_mapping', 'TEST_USER', 'TEST_TAGS', 'CREATE_NEW_MAPPING', 11, timestamp '2026-05-06 10:23:38.461299', NULL, NULL, 0, NULL, null, null, null, null, null, null, null, null, + ut3_develop.ut_varchar2_rows('test_tag'), ut3_develop.ut_executable_test('UT_EXECUTABLE_TEST', 'test', 'TEST_USER', 'test_tags', 'create_new_mapping', NULL, NULL, NULL, NULL)) + ); + + ut.expect(ut3_develop.ut_suite_tag_filter.apply( l_input_data, 'slow').count).to_equal(3 ); + + open l_expected for select * from table( l_input_data ); + open l_actual for select * from table( ut3_develop.ut_suite_tag_filter.apply( l_input_data, 'slow') ); + ut.expect(l_actual).to_equal(l_expected).join_by('ID'); + + ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, '!slow').count ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, 'bad').count ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, '!bad').count ).to_equal(3); + ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, '!context_tag').count ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, 'context_tag').count ).to_equal(3); + ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, '!test_tag').count ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, 'test_tag').count ).to_equal(3); + end; + end test_ut_suite_tag_filter; / diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pks b/test/ut3_tester/core/test_ut_suite_tag_filter.pks index 0f84b751b..fd29bc87e 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pks +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pks @@ -27,7 +27,10 @@ create or replace package test_ut_suite_tag_filter is --%endcontext --%test( Test conversion of expression from tag into custom where filter for SQL) - procedure conv_from_tag_to_sql_filter; + procedure conv_from_tag_to_sql_filter; + + --%test( Regression for issue #1324 - corect filtering by tags with suitepath and contexts) + procedure filtering_is_correctly_applied_to_all_items; end test_ut_suite_tag_filter; / From 30aeb0037ba5abf7f8f15417d3b20e0c825345d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 7 May 2026 00:39:53 +0300 Subject: [PATCH 614/887] Added missing unit tests --- test/ut3_tester/core/test_ut_suite_tag_filter.pkb | 9 +++++++++ test/ut3_tester/core/test_ut_suite_tag_filter.pks | 4 ++++ 2 files changed, 13 insertions(+) diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index dd0bb5f71..7ce6a1c3e 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -62,6 +62,15 @@ create or replace package body test_ut_suite_tag_filter is ut.fail('Expected exception but nothing was raised'); end; + procedure conversion_throws_when_lb_rb is + l_postfix ut3_develop.ut_varchar2_list; + l_input_token ut3_develop.ut_varchar2_list; + begin + l_input_token := ut3_develop.ut_varchar2_list('(',')'); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); + ut.fail('Expected exception but nothing was raised'); + end; + procedure conv_from_tag_to_sql_filter is l_sql_filter varchar2(4000); begin diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pks b/test/ut3_tester/core/test_ut_suite_tag_filter.pks index fd29bc87e..e7b255d4b 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pks +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pks @@ -24,6 +24,10 @@ create or replace package test_ut_suite_tag_filter is --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) procedure test_conversion_rb_by_oprd; + --%test(Conversion raises exception when empty brackets) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure conversion_throws_when_lb_rb; + --%endcontext --%test( Test conversion of expression from tag into custom where filter for SQL) From fae8eb8cefcee72485ba0fcd36f8132f805996b7 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 6 May 2026 23:19:48 +0100 Subject: [PATCH 615/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 730c621b8..0241eeb6f 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4377 +4384 diff --git a/docs/about/authors.md b/docs/about/authors.md index 518900d79..10ce0a2cc 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index c32e5ea2f..c62c5d762 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index b08ff3eda..a5c8fa3fb 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 9b71734f8..41d5ea28c 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index a7d507ea1..102f5c16b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 429163a3b..0c0219622 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 6ada50701..5e1a51713 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 2f8981533..afa5bf798 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4d60ea34b..696cd5bcc 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index cd4651b5c..60c17a283 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 198c285ee..6ff63caee 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 7c93fc1e6..caab0595c 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 482529af3..cfae29f06 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 65fa92216..259508283 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 7f74eca6b..7fba55680 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 7e60f81f2..37bef053d 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 2941d90d3..07ee3c8d3 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4377--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c80ff9c50..816eac6ab 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4377-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4384-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From d22124bbd914e7b10e851122b6478ba498c7ec88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 23 May 2026 12:02:58 +0300 Subject: [PATCH 616/887] Added test to reproduce issue #985 --- .github/scripts/create_test_users.sh | 2 +- test/ut3_tester/core/test_output_buffer.pkb | 27 ++++++++++++--- test/ut3_tester/core/test_output_buffer.pks | 5 +++ test/ut3_tester_helper/run_helper.pkb | 38 +++++++++++++++++++-- test/ut3_tester_helper/run_helper.pks | 5 +++ 5 files changed, 69 insertions(+), 8 deletions(-) diff --git a/.github/scripts/create_test_users.sh b/.github/scripts/create_test_users.sh index fe43b7467..fff44f1bd 100755 --- a/.github/scripts/create_test_users.sh +++ b/.github/scripts/create_test_users.sh @@ -86,7 +86,7 @@ PROMPT Grants for testing coverage outside of main $UT3_DEVELOP_SCHEMA schema. grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type, select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table, select any dictionary, create any synonym, drop any synonym, - grant any object privilege, grant any privilege, create public synonym, drop public synonym, create any trigger + grant any object privilege, grant any privilege, create public synonym, drop public synonym, create any trigger, drop any trigger to UT3_TESTER_HELPER; grant create job to UT3_TESTER_HELPER; diff --git a/test/ut3_tester/core/test_output_buffer.pkb b/test/ut3_tester/core/test_output_buffer.pkb index 317e7e3d5..55670b8b8 100644 --- a/test/ut3_tester/core/test_output_buffer.pkb +++ b/test/ut3_tester/core/test_output_buffer.pkb @@ -1,5 +1,13 @@ create or replace package body test_output_buffer is + function long_text return varchar2 is + l_txt varchar2(32767); + begin + for i in 1 .. 100 loop + l_txt := l_txt||lpad('a text', 310, ',a text'); + end loop; + return l_txt; + end; procedure test_receive is l_actual_text clob; l_actual_item_type varchar2(1000); @@ -10,10 +18,10 @@ create or replace package body test_output_buffer is begin --Arrange l_buffer := ut3_develop.ut_output_clob_table_buffer(); - l_expected_text := to_clob(lpad('a text', 31000, ',a text')) - || chr(10) || to_clob(lpad('a text', 31000, ',a text')) - || chr(13) || to_clob(lpad('a text', 31000, ',a text')) - || chr(13) || chr(10) || to_clob(lpad('a text', 31000, ',a text')) || to_clob(lpad('a text', 31000, ',a text')); + l_expected_text := to_clob('a text') ||long_text() + || chr(10) || long_text() + || chr(13) || long_text() + || chr(13) || chr(10) || long_text() || long_text(); l_expected_item_type := lpad('some item type',1000,'-'); --Act l_buffer.lock_buffer(); @@ -196,5 +204,14 @@ create or replace package body test_output_buffer is ut.expect(lengthb(l_text)).to_be_less_or_equal(l_max_len); end; - end test_output_buffer; + procedure concurrent_calls_do_not_cause_exception is + l_consumer_buffer_instance ut3_develop.ut_output_buffer_base; + l_shared_output_id raw(32) := sys_guid(); + begin + ut3_tester_helper.run_helper.run_as_job('declare x ut3_develop.ut_output_buffer_base; begin x := ut3_develop.ut_output_table_buffer(a_output_id => '''||l_shared_output_id||'''); end;'); + dbms_session.sleep(0.5); + l_consumer_buffer_instance := ut3_develop.ut_output_table_buffer(a_output_id => l_shared_output_id); + end; + +end test_output_buffer; / diff --git a/test/ut3_tester/core/test_output_buffer.pks b/test/ut3_tester/core/test_output_buffer.pks index 5b6cd678b..aa5c830d3 100644 --- a/test/ut3_tester/core/test_output_buffer.pks +++ b/test/ut3_tester/core/test_output_buffer.pks @@ -53,5 +53,10 @@ create or replace package test_output_buffer is --%test(Successfully sends multibyte long clob line into text buffer) procedure text_buffer_send_clob_multib; + --%beforetest(ut3_tester_helper.run_helper.slow_down_insert_into_table_buffer) + --%aftertest(ut3_tester_helper.run_helper.cleanup_slow_down_insert_into_table_buffer) + --%test(concurrent calls to init() procedure do not cause errors - Issue #985) + procedure concurrent_calls_do_not_cause_exception; + end test_output_buffer; / diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index 9d65d6667..c56f31dc0 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -211,7 +211,7 @@ create or replace package body run_helper is begin execute immediate 'drop package ut3_user.test_db_link'; exception when others then null; end; end; - procedure create_suite_with_link is + procedure create_suite_with_link is pragma autonomous_transaction; begin create_db_link; @@ -250,7 +250,7 @@ create or replace package body run_helper is execute immediate 'grant execute on test_distributed_savepoint to public'; end; - procedure drop_suite_with_link is + procedure drop_suite_with_link is pragma autonomous_transaction; begin drop_db_link; @@ -926,5 +926,39 @@ create or replace package body run_helper is return l_result; end; + procedure slow_down_insert_into_table_buffer is + pragma autonomous_transaction; + begin + execute immediate q'[ + create or replace trigger ut3_develop.slow_down_buffer_insert + before insert on ut3_develop.ut_output_buffer_info_tmp + begin + dbms_session.sleep(1); + end;]'; + end; + + procedure cleanup_slow_down_insert_into_table_buffer is + pragma autonomous_transaction; + begin + execute immediate 'drop trigger ut3_develop.slow_down_buffer_insert'; + exception when others then + if sqlcode <> -4080 then raise; end if; + end; + + procedure run_as_job(a_job_action varchar2) is + l_job_name varchar2(50); + l_timestamp timestamp with time zone := current_timestamp; + pragma autonomous_transaction; + begin + l_job_name := 'utPLSQL__'||to_char(l_timestamp,'yyyymmddhh24missff'); + dbms_scheduler.create_job( + job_name => l_job_name, + job_type => 'PLSQL_BLOCK', + job_action => a_job_action, + start_date => l_timestamp, + enabled => TRUE, + auto_drop => TRUE + ); + end; end; / diff --git a/test/ut3_tester_helper/run_helper.pks b/test/ut3_tester_helper/run_helper.pks index ad0f615e5..6c5dd4a3b 100644 --- a/test/ut3_tester_helper/run_helper.pks +++ b/test/ut3_tester_helper/run_helper.pks @@ -74,5 +74,10 @@ create or replace package run_helper is a_name varchar2 := null ) return sys_refcursor; + procedure slow_down_insert_into_table_buffer; + + procedure cleanup_slow_down_insert_into_table_buffer; + + procedure run_as_job(a_job_action varchar2); end; / From cbd68eea3b70d0488dde386e3d7bbab0e170e304 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 23 May 2026 12:13:32 +0300 Subject: [PATCH 617/887] Fixing issue with output buffer initialization handling #985 --- .../output_buffers/ut_output_buffer_base.tpb | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index f92827d28..dc9b34b88 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -18,18 +18,20 @@ create or replace type body ut_output_buffer_base is member procedure init(self in out nocopy ut_output_buffer_base, a_output_id raw := null, a_self_type varchar2 := null) is pragma autonomous_transaction; - l_exists int; begin cleanup_buffer(); self.self_type := coalesce(a_self_type,self.self_type); self.output_id := coalesce(a_output_id, self.output_id, sys_guid()); self.start_date := coalesce(self.start_date, sysdate); - select /*+ no_parallel */ count(*) into l_exists from ut_output_buffer_info_tmp where output_id = self.output_id; - if ( l_exists > 0 ) then - update /*+ no_parallel */ ut_output_buffer_info_tmp set start_date = self.start_date where output_id = self.output_id; - else - insert /*+ no_parallel */ into ut_output_buffer_info_tmp(output_id, start_date) values (self.output_id, self.start_date); - end if; + merge /*+ no_parallel */ into ut_output_buffer_info_tmp dst + using (select 1 from dual) src + on (dst.output_id = self.output_id) + when matched then + update + set dst.start_date = self.start_date + when not matched then + insert (output_id, start_date) + values (self.output_id, self.start_date); commit; dbms_lock.allocate_unique( self.output_id, self.lock_handle); self.is_closed := 0; From be3a2e46df196c10da24979b7897f9a4da2a222c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 23 May 2026 20:11:08 +0100 Subject: [PATCH 618/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 0241eeb6f..e4feae55d 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4384 +4389 diff --git a/docs/about/authors.md b/docs/about/authors.md index 10ce0a2cc..9cf8f6a6b 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index c62c5d762..03179cbea 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index a5c8fa3fb..698024f0a 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 41d5ea28c..79c12f657 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 102f5c16b..db3e730f8 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 0c0219622..bf2b1ea13 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 5e1a51713..2471c2009 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index afa5bf798..d21d1b0ea 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 696cd5bcc..2c5c73d1c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 60c17a283..744f27f20 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 6ff63caee..d9b3854e4 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index caab0595c..94cd114d2 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index cfae29f06..91054f907 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 259508283..04243fb02 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 7fba55680..9c9d1d6ea 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 37bef053d..f9f6a911a 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 07ee3c8d3..7844d4eca 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4384--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 816eac6ab..178205334 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4384-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4389-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From b6ea7473fc118f6008c8476c4329cbe22dfbb4b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 23 May 2026 22:45:59 +0300 Subject: [PATCH 619/887] Fixed issue with duplicate sources from dba_source Resolves #1323 --- .../annotations/ut_annotation_manager.pkb | 2 ++ source/core/coverage/ut_coverage.pkb | 1 + .../test_coverage/test_proftab_coverage.pkb | 24 +++++++++++++++++++ .../test_coverage/test_proftab_coverage.pks | 3 +++ 4 files changed, 30 insertions(+) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 992af2fe0..e7d9f2719 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -121,6 +121,7 @@ create or replace package body ut_annotation_manager as and s.type = r.object_type where s.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' and s.type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' + and s.origin_con_id = sys_context('userenv', 'con_id') ) x where x.is_annotated = 'Y' order by x.name, x.line]' @@ -268,6 +269,7 @@ create or replace package body ut_annotation_manager as where s.type = :a_object_type and s.owner = :a_object_owner and s.name = :a_object_name + and s.origin_con_id = sys_context('userenv', 'con_id') order by s.line]' using a_object_name, a_object_type, a_object_owner, a_object_name; return l_result; diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index e8e6ed529..df65879af 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -55,6 +55,7 @@ create or replace package body ut_coverage is s.text from {sources_view} s {join_file_mappings} where s.type in ('PACKAGE BODY', 'TYPE BODY', 'PROCEDURE', 'FUNCTION', 'TRIGGER') + and s.origin_con_id = sys_context('userenv', 'con_id') {filters} {regex_exc_filters} and not exists ( diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index f3aad5702..3c79f4429 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -207,5 +207,29 @@ create or replace package body test_proftab_coverage is ut.expect(l_actual).to_be_like(coverage_helper.substitute_covered_package(l_expected)); end; + procedure no_issue_with_duplicate_source is + l_expected clob; + l_actual clob; + begin + --Arrange + l_expected := '%%'; + --Act + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + coverage_helper.substitute_covered_package( + q'[ + ut3_develop.ut.run( + 'ut3_develop.test_dummy_coverage.zero_coverage', + ut3_develop.ut_coverage_sonar_reporter(), + a_include_objects => ut3_develop.ut_varchar2_list('MDSYS.SDO_UTIL') + ) + ]' + ) + ); + + --Running above line is successful if there is no exception thrown due to duplicate lines in coverage + ut.expect(l_actual).to_be_like(l_expected); + end; + end; / diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks index 740862f86..fb1d0cfe3 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pks @@ -28,5 +28,8 @@ create or replace package test_proftab_coverage is --%test(reports zero coverage on each line of non-executed database object - Issue #917) procedure report_zero_coverage; + --%test(Allows reporting coverage on objects across SYS or MDSYS without errors - Issue #1323 ) + procedure no_issue_with_duplicate_source; + end; / From 9badaa4cc52029df5c901e235f1dea5d0d5ba5d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 23 May 2026 23:15:30 +0300 Subject: [PATCH 620/887] Changed usage of MD5 to SHA256 Resolves #1316 --- source/reporters/ut_coverage_report_html_helper.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index 7ebf891f9..149e49729 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -90,7 +90,7 @@ create or replace package body ut_coverage_report_html_helper is function object_id(a_object_full_name varchar2) return varchar2 is begin - return rawtohex(dbms_crypto.hash(src => utl_raw.cast_to_raw(a_object_full_name), typ => dbms_crypto.hash_md5)); + return rawtohex(dbms_crypto.hash(src => utl_raw.cast_to_raw(a_object_full_name), typ => dbms_crypto.hash_sh256)); end; function link_to_source_file(a_object_full_name varchar2) return varchar2 is @@ -231,7 +231,7 @@ create or replace package body ut_coverage_report_html_helper is l_title varchar2(100) := 'All files'; l_coverage_pct number(5, 2); l_result ut_varchar2_rows; - l_id varchar2(50) := object_id(a_title); + l_id varchar2(100) := object_id(a_title); l_unit_coverage ut_coverage.t_unit_coverage; l_unit ut_coverage.t_object_name; begin From 9397ab434f2cc3217cce7dbdde0f88f460589349 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 23 May 2026 23:24:08 +0300 Subject: [PATCH 621/887] Enabling FIPS-140 on Oracle 23 --- .github/workflows/build.yml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a83281b38..770289c57 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -40,6 +40,7 @@ jobs: db_version_name: '23-free' oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23-slim-faststart" + fips-enabled: true services: html_checker: image: ghcr.io/validator/validator:latest @@ -84,6 +85,22 @@ jobs: # For PR build - test using target branch as framework, for branch build use self as testing framework run: git clone --depth=1 --branch=${CI_BASE_REF:-$CI_REF_NAME} https://github.com/utPLSQL/utPLSQL.git $UTPLSQL_DIR + - name: Enable FIPS 140 on Oracle DB + id: enable-fips + if: ${{ matrix.fips_enabled == true }} + run: | + docker exec oracle sqlplus -s / as sysdba <<'EOF' + ALTER SYSTEM SET DBFIPS_140=TRUE SCOPE=SPFILE; + SHUTDOWN IMMEDIATE; + STARTUP; + EXIT; + EOF + docker exec oracle bash -c " + until healthcheck.sh; do + echo 'Waiting for DB to come back up after FIPS restart...' + sleep 1 + done + " - name: Update privileges on sources run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} From 03d5e680691372d0838481a17d5f7b9a64dfec41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 23 May 2026 23:36:35 +0300 Subject: [PATCH 622/887] Small pipeline readability improvements --- .github/workflows/build.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a83281b38..502158235 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -32,6 +32,8 @@ jobs: db_version_name: '19se' oracle-sid: 'ORCLCDB' oracle-version: "utplsqlv3/oracledb:19c-se2-small" + check-coding-style: true + validate-utplsql-uninstall: true - id: 2 db_version_name: '21XE' oracle-sid: 'XE' @@ -40,6 +42,7 @@ jobs: db_version_name: '23-free' oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23-slim-faststart" + run-sonar-scanner: true services: html_checker: image: ghcr.io/validator/validator:latest @@ -116,17 +119,17 @@ jobs: run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install.sh - name: Check code style - if: ${{ matrix.id == 1 }} + if: ${{ matrix.check-style == true }} id: check-coding-style run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle "$SQLCLI" ${UT3_DEVELOP_SCHEMA}/${UT3_DEVELOP_SCHEMA_PASSWORD}@//${CONNECTION_STR} @/utPLSQL/development/utplsql_style_check.sql - name: Validate utPLSQL uninstall - if: ${{ matrix.id == 1 }} + if: ${{ validate-utplsql-uninstall == true }} id: validate-uninstall run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/uninstall_validate_utplsql.sh - name: Reinstall utPLSQL - if: ${{ matrix.id == 1 }} + if: ${{ validate-utplsql-uninstall == true }} id: reinstall-utplsql run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install.sh @@ -190,7 +193,7 @@ jobs: - name: SonarCloud Scan id: sonar - if: ${{ always() && matrix.db_version_name == '23-free' }} + if: ${{ always() && run-sonar-scanner == true }} uses: SonarSource/sonarqube-scan-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any From 59686d9477a59c1e9361040d5181cecd8025e981 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 23 May 2026 23:57:39 +0300 Subject: [PATCH 623/887] Test improvements --- .../reporters/test_coverage/test_proftab_coverage.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index 3c79f4429..bf6a7f41d 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -212,7 +212,7 @@ create or replace package body test_proftab_coverage is l_actual clob; begin --Arrange - l_expected := '%%'; + l_expected := '%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( @@ -221,7 +221,7 @@ create or replace package body test_proftab_coverage is ut3_develop.ut.run( 'ut3_develop.test_dummy_coverage.zero_coverage', ut3_develop.ut_coverage_sonar_reporter(), - a_include_objects => ut3_develop.ut_varchar2_list('MDSYS.SDO_UTIL') + a_include_schema_expr =>'MDSYS' ) ]' ) From 3c98adf4dfe5fcffbbf59a14e3386cbd4a354358 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 23 May 2026 23:58:00 +0300 Subject: [PATCH 624/887] Improvements to utplsql cleanup script. --- development/cleanup.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/development/cleanup.sh b/development/cleanup.sh index 65f3ab0c1..d36f21540 100755 --- a/development/cleanup.sh +++ b/development/cleanup.sh @@ -29,11 +29,13 @@ drop user ut3_select_catalog_user cascade; drop user ut3_select_any_table_user cascade; drop user ut3_execute_any_proc_user cascade; +set serveroutput on begin for i in ( select decode(owner,'PUBLIC','drop public synonym "','drop synonym "'||owner||'"."')|| synonym_name ||'"' drop_orphaned_synonym, owner||'.'||synonym_name syn from dba_synonyms a where not exists (select 1 from dba_objects b where (a.table_name=b.object_name and a.table_owner=b.owner or b.owner='SYS' and a.table_owner=b.object_name) ) - and a.table_owner not in ('SYS','SYSTEM') + and a.table_owner not in (select username from dba_users where oracle_maintained = 'Y') + and a.origin_con_id = sys_context('userenv', 'con_id') ) loop execute immediate i.drop_orphaned_synonym; dbms_output.put_line('synonym '||i.syn||' dropped'); From 028f18a0662d24e11dee213208e15ae9d3aeaf1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 23 May 2026 23:59:53 +0300 Subject: [PATCH 625/887] Checking to see if build will fail with MD5 enabled on FIPS-ENABLED DB. --- source/reporters/ut_coverage_report_html_helper.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index 149e49729..d87be7efb 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -90,7 +90,7 @@ create or replace package body ut_coverage_report_html_helper is function object_id(a_object_full_name varchar2) return varchar2 is begin - return rawtohex(dbms_crypto.hash(src => utl_raw.cast_to_raw(a_object_full_name), typ => dbms_crypto.hash_sh256)); + return rawtohex(dbms_crypto.hash(src => utl_raw.cast_to_raw(a_object_full_name), typ => dbms_crypto.HASH_MD5)); end; function link_to_source_file(a_object_full_name varchar2) return varchar2 is From a3b18e4fa67d92174f23ed50b20831825f21876a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 00:01:43 +0300 Subject: [PATCH 626/887] Pipeline improvements --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 502158235..3e4f605f0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -124,12 +124,12 @@ jobs: run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle "$SQLCLI" ${UT3_DEVELOP_SCHEMA}/${UT3_DEVELOP_SCHEMA_PASSWORD}@//${CONNECTION_STR} @/utPLSQL/development/utplsql_style_check.sql - name: Validate utPLSQL uninstall - if: ${{ validate-utplsql-uninstall == true }} + if: ${{ matrix.validate-utplsql-uninstall == true }} id: validate-uninstall run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/uninstall_validate_utplsql.sh - name: Reinstall utPLSQL - if: ${{ validate-utplsql-uninstall == true }} + if: ${{ matrix.validate-utplsql-uninstall == true }} id: reinstall-utplsql run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install.sh From 4d45a418ab8b37fa4f3a1a3e0641efd86beea7bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 00:02:48 +0300 Subject: [PATCH 627/887] Pipeline improvements --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3e4f605f0..179fe626f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -193,7 +193,7 @@ jobs: - name: SonarCloud Scan id: sonar - if: ${{ always() && run-sonar-scanner == true }} + if: ${{ always() && matrix.run-sonar-scanner == true }} uses: SonarSource/sonarqube-scan-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any From dee15ded7c84a30962f37b47389e26fcd9190d99 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 23 May 2026 22:09:06 +0100 Subject: [PATCH 628/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index e4feae55d..f993a7058 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4389 +4400 diff --git a/docs/about/authors.md b/docs/about/authors.md index 9cf8f6a6b..50318ec3c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 03179cbea..caae4d8d9 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 698024f0a..2a1a9f0ae 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 79c12f657..01eb1241c 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index db3e730f8..98274531f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index bf2b1ea13..023f6956a 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 2471c2009..feff57ad5 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index d21d1b0ea..854978e3a 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 2c5c73d1c..bbb357f20 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 744f27f20..4ed7dbece 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index d9b3854e4..858e9ea8b 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 94cd114d2..8bf5acaa6 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 91054f907..a01caa652 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 04243fb02..cc76cbfde 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 9c9d1d6ea..622d3e3eb 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index f9f6a911a..69f8e3d32 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 7844d4eca..42929c1c5 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4389--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 178205334..a14528d0b 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4389-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4400-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 1031f25b0cf101a922aea15d7449287061634834 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 00:11:18 +0300 Subject: [PATCH 629/887] Enabling FIPS-140 on Oracle 23 --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 770289c57..e612f2fdc 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -87,7 +87,7 @@ jobs: - name: Enable FIPS 140 on Oracle DB id: enable-fips - if: ${{ matrix.fips_enabled == true }} + if: ${{ matrix.fips-enabled == true }} run: | docker exec oracle sqlplus -s / as sysdba <<'EOF' ALTER SYSTEM SET DBFIPS_140=TRUE SCOPE=SPFILE; From 24dad816cea13c4336112fbcc72c61f54727fdd0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 00:25:10 +0300 Subject: [PATCH 630/887] Enabling FIPS-140 on Oracle 23 --- .github/workflows/build.yml | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e612f2fdc..1c07c53a4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -89,18 +89,13 @@ jobs: id: enable-fips if: ${{ matrix.fips-enabled == true }} run: | - docker exec oracle sqlplus -s / as sysdba <<'EOF' - ALTER SYSTEM SET DBFIPS_140=TRUE SCOPE=SPFILE; + docker exec oracle bash -c " + echo \"ALTER SYSTEM SET DBFIPS_140=TRUE SCOPE=SPFILE; SHUTDOWN IMMEDIATE; STARTUP; - EXIT; - EOF - docker exec oracle bash -c " - until healthcheck.sh; do - echo 'Waiting for DB to come back up after FIPS restart...' - sleep 1 - done + EXIT;\" | sqlplus -s / as sysdba " + docker exec oracle bash -c "until healthcheck.sh; do echo 'Waiting for DB restart...'; sleep 1; done" - name: Update privileges on sources run: chmod -R go+w ./{source,test,examples,${UTPLSQL_DIR}/source} From 2fc67bbb06dce9f026d6e43885bc0e3ae648fb17 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 00:29:56 +0300 Subject: [PATCH 631/887] Enabling FIPS-140 on Oracle 23 --- .github/workflows/build.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1c07c53a4..44c3d1b76 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -93,6 +93,8 @@ jobs: echo \"ALTER SYSTEM SET DBFIPS_140=TRUE SCOPE=SPFILE; SHUTDOWN IMMEDIATE; STARTUP; + PROMPT Should show true for DBFIPS_140 + SELECT name, value FROM v$parameter WHERE name = 'DBFIPS_140'; EXIT;\" | sqlplus -s / as sysdba " docker exec oracle bash -c "until healthcheck.sh; do echo 'Waiting for DB restart...'; sleep 1; done" From 9c64af0be4001c387b9fe14eb50c989f897708ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 00:33:32 +0300 Subject: [PATCH 632/887] Changed MD5 to SH256 --- source/reporters/ut_coverage_report_html_helper.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index d87be7efb..d81211f03 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -90,7 +90,7 @@ create or replace package body ut_coverage_report_html_helper is function object_id(a_object_full_name varchar2) return varchar2 is begin - return rawtohex(dbms_crypto.hash(src => utl_raw.cast_to_raw(a_object_full_name), typ => dbms_crypto.HASH_MD5)); + return rawtohex(dbms_crypto.hash(src => utl_raw.cast_to_raw(a_object_full_name), typ => dbms_crypto.HASH_SH256)); end; function link_to_source_file(a_object_full_name varchar2) return varchar2 is From 534e4499ad1958f0f35e20c1c12d50f5e6d8ae02 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 00:41:55 +0300 Subject: [PATCH 633/887] Making the test more generic. --- .../reporters/test_coverage/test_proftab_coverage.pkb | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb index bf6a7f41d..4b06f725f 100644 --- a/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_proftab_coverage.pkb @@ -208,11 +208,8 @@ create or replace package body test_proftab_coverage is end; procedure no_issue_with_duplicate_source is - l_expected clob; l_actual clob; begin - --Arrange - l_expected := '%%'; --Act l_actual := ut3_tester_helper.coverage_helper.run_tests_as_job( @@ -221,14 +218,14 @@ create or replace package body test_proftab_coverage is ut3_develop.ut.run( 'ut3_develop.test_dummy_coverage.zero_coverage', ut3_develop.ut_coverage_sonar_reporter(), - a_include_schema_expr =>'MDSYS' + a_include_schema_expr =>'SYS' ) ]' ) ); --Running above line is successful if there is no exception thrown due to duplicate lines in coverage - ut.expect(l_actual).to_be_like(l_expected); + ut.expect(l_actual).not_to_be_null(); end; end; From 2cde2b61c4bc42a898fa0a8fc3db2d04803eb758 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 00:42:33 +0300 Subject: [PATCH 634/887] Fixing typo --- source/core/coverage/ut_coverage.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index df65879af..f3181fdc7 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -59,7 +59,7 @@ create or replace package body ut_coverage is {filters} {regex_exc_filters} and not exists ( - select /*+ cardinality(el {excuded_objects_cardinality})*/ 1 + select /*+ cardinality(el {excluded_objects_cardinality})*/ 1 from table(:l_excluded_objects) el where s.owner = el.owner and s.name = el.name ) @@ -153,7 +153,7 @@ create or replace package body ut_coverage is l_result := replace(l_result, '{filters}', l_filters); l_result := replace(l_result, '{mappings_cardinality}', l_mappings_cardinality); l_result := replace(l_result, '{skipped_objects_cardinality}', ut_utils.scale_cardinality(cardinality(a_skip_objects))); - l_result := replace(l_result, '{excuded_objects_cardinality}', ut_utils.scale_cardinality(cardinality(coalesce(a_coverage_options.exclude_objects, ut_object_names())))); + l_result := replace(l_result, '{excluded_objects_cardinality}', ut_utils.scale_cardinality(cardinality(coalesce(a_coverage_options.exclude_objects, ut_object_names())))); l_result := replace(l_result, '{regex_exc_filters}', l_regex_exc_filters); return l_result; From 5e95b94faf15082a8151352b47ff57faee111d94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 00:51:56 +0300 Subject: [PATCH 635/887] Replacing hash_sh1 with hash_sh256 to avoid issues on 23.26 with FIPS 140-3 compliance --- source/core/ut_utils.pkb | 4 ++-- source/core/ut_utils.pks | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 9afb2ffb0..32cbb3f8c 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -1024,13 +1024,13 @@ create or replace package body ut_utils is return regexp_replace(a_item,a_prefix||a_connector); end; - function get_hash(a_data raw, a_hash_type binary_integer := dbms_crypto.hash_sh1) return t_hash is + function get_hash(a_data raw, a_hash_type binary_integer := dbms_crypto.hash_sh256) return t_hash is begin --We cannot run hash on null return case when a_data is null then null else dbms_crypto.hash(a_data, a_hash_type) end; end; - function get_hash(a_data clob, a_hash_type binary_integer := dbms_crypto.hash_sh1) return t_hash is + function get_hash(a_data clob, a_hash_type binary_integer := dbms_crypto.hash_sh256) return t_hash is begin --We cannot run hash on null return case when a_data is null then null else dbms_crypto.hash(a_data, a_hash_type) end; diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 178205334..056cadd46 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -457,12 +457,12 @@ create or replace package ut_utils authid definer is /* * Wrapper function for calling dbms_crypto.hash */ - function get_hash(a_data raw, a_hash_type binary_integer := dbms_crypto.hash_sh1) return t_hash; + function get_hash(a_data raw, a_hash_type binary_integer := dbms_crypto.hash_sh256) return t_hash; /* * Wrapper function for calling dbms_crypto.hash */ - function get_hash(a_data clob, a_hash_type binary_integer := dbms_crypto.hash_sh1) return t_hash; + function get_hash(a_data clob, a_hash_type binary_integer := dbms_crypto.hash_sh256) return t_hash; /* * Returns a hash value of suitepath based on input path and random seed From b79032c4072fe16499ba07e807144cd5bf79611b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 23 May 2026 23:04:20 +0100 Subject: [PATCH 636/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index f993a7058..2e738db41 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4400 +4410 diff --git a/docs/about/authors.md b/docs/about/authors.md index 50318ec3c..953705528 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index caae4d8d9..1a4c32d4f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 2a1a9f0ae..4c7b73552 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 01eb1241c..64a3ec13b 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 98274531f..0277f24eb 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 023f6956a..2f842d427 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index feff57ad5..dc5d292d5 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 854978e3a..9c3a266c4 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index bbb357f20..5fe806c0b 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 4ed7dbece..5cd74f12c 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 858e9ea8b..5903ffecd 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8bf5acaa6..123250e64 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index a01caa652..471ac1eed 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index cc76cbfde..8e50403aa 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 622d3e3eb..2f1c764e0 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 69f8e3d32..d4950eb0b 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 42929c1c5..b0d4d65be 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4400--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index a14528d0b..42162f84e 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4400-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4410-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 327a57463a049be2a47a36f5cdd4b38773b3f5d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 24 May 2026 01:13:39 +0300 Subject: [PATCH 637/887] Fixing failing tests --- test/ut3_user/api/test_ut_run.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index f0cfd8373..b4040bb43 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -854,7 +854,7 @@ Failures:% l_results ut3_develop.ut_varchar2_list; begin select * bulk collect into l_random_results - from table ( ut3_develop.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 6 ) ) + from table ( ut3_develop.ut.run( 'ut3_tester_helper.test_package_1', a_random_test_order_seed => 123 ) ) where trim(column_value) is not null and column_value not like 'Finished in %' and column_value not like '%Tests were executed with random order %'; From 5852e44dfb8aad1d99c6db3140bf8967ca5c18e3 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 23 May 2026 23:39:37 +0100 Subject: [PATCH 638/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 2e738db41..dd37b7287 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4410 +4414 diff --git a/docs/about/authors.md b/docs/about/authors.md index 953705528..687c6cfaa 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 1a4c32d4f..6567b5db7 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 4c7b73552..df666731f 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 64a3ec13b..f27ee0c1e 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 0277f24eb..6ae326c1c 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 2f842d427..76d90bc30 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index dc5d292d5..fd51fec8f 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 9c3a266c4..c9f08eab5 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 5fe806c0b..03cb8bfd3 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 5cd74f12c..1e892215d 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 5903ffecd..c51e6c99c 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 123250e64..a722f8ac7 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 471ac1eed..615883720 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 8e50403aa..167fba1b4 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 2f1c764e0..807fa537f 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index d4950eb0b..606a5ef97 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index b0d4d65be..a49118fbd 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4410--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6679f8442..092c25583 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4410-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4414-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From b2282c3fb8ea0a894bcab835736510b8d2542ce4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 13:32:09 +0300 Subject: [PATCH 639/887] Removing code of conduct as it is now at the org level --- CODE_OF_CONDUCT.md | 76 ---------------------------------------------- 1 file changed, 76 deletions(-) delete mode 100644 CODE_OF_CONDUCT.md diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md deleted file mode 100644 index b90e5e80e..000000000 --- a/CODE_OF_CONDUCT.md +++ /dev/null @@ -1,76 +0,0 @@ -# Contributor Covenant Code of Conduct - -## Our Pledge - -In the interest of fostering an open and welcoming environment, we as -contributors and maintainers pledge to making participation in our project and -our community a harassment-free experience for everyone, regardless of age, body -size, disability, ethnicity, sex characteristics, gender identity and expression, -level of experience, education, socio-economic status, nationality, personal -appearance, race, religion, or sexual identity and orientation. - -## Our Standards - -Examples of behavior that contributes to creating a positive environment -include: - -* Using welcoming and inclusive language -* Being respectful of differing viewpoints and experiences -* Gracefully accepting constructive criticism -* Focusing on what is best for the community -* Showing empathy towards other community members - -Examples of unacceptable behavior by participants include: - -* The use of sexualized language or imagery and unwelcome sexual attention or - advances -* Trolling, insulting/derogatory comments, and personal or political attacks -* Public or private harassment -* Publishing others' private information, such as a physical or electronic - address, without explicit permission -* Other conduct which could reasonably be considered inappropriate in a - professional setting - -## Our Responsibilities - -Project maintainers are responsible for clarifying the standards of acceptable -behavior and are expected to take appropriate and fair corrective action in -response to any instances of unacceptable behavior. - -Project maintainers have the right and responsibility to remove, edit, or -reject comments, commits, code, wiki edits, issues, and other contributions -that are not aligned to this Code of Conduct, or to ban temporarily or -permanently any contributor for other behaviors that they deem inappropriate, -threatening, offensive, or harmful. - -## Scope - -This Code of Conduct applies both within project spaces and in public spaces -when an individual is representing the project or its community. Examples of -representing a project or community include using an official project e-mail -address, posting via an official social media account, or acting as an appointed -representative at an online or offline event. Representation of a project may be -further defined and clarified by project maintainers. - -## Enforcement - -Instances of abusive, harassing, or otherwise unacceptable behavior may be -reported by contacting the project team at utplsql@utplsql.org. All -complaints will be reviewed and investigated and will result in a response that -is deemed necessary and appropriate to the circumstances. The project team is -obligated to maintain confidentiality with regard to the reporter of an incident. -Further details of specific enforcement policies may be posted separately. - -Project maintainers who do not follow or enforce the Code of Conduct in good -faith may face temporary or permanent repercussions as determined by other -members of the project's leadership. - -## Attribution - -This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, -available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html - -[homepage]: https://www.contributor-covenant.org - -For answers to common questions about this code of conduct, see -https://www.contributor-covenant.org/faq From 404af3704ef15a10287470351a844d373f7093e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 15:37:51 +0300 Subject: [PATCH 640/887] Update fof discussions templates --- .github/DISCUSSION_TEMPLATE/README.md | 150 ------------------ .github/DISCUSSION_TEMPLATE/announcements.yml | 54 ------- .github/DISCUSSION_TEMPLATE/architecture.yml | 100 ------------ .github/DISCUSSION_TEMPLATE/bug-triage.yml | 69 ++++++++ .github/DISCUSSION_TEMPLATE/contributing.yml | 43 +++++ .github/DISCUSSION_TEMPLATE/contributors.yml | 56 ------- .../DISCUSSION_TEMPLATE/feature-requests.yml | 62 ++++++++ .github/DISCUSSION_TEMPLATE/general.yml | 28 ---- .github/DISCUSSION_TEMPLATE/q-a.yml | 46 ++---- .../DISCUSSION_TEMPLATE/release-planning.yml | 90 ----------- .github/DISCUSSION_TEMPLATE/rfcs-design.yml | 88 ---------- .github/DISCUSSION_TEMPLATE/show-and-tell.yml | 79 --------- 12 files changed, 184 insertions(+), 681 deletions(-) delete mode 100644 .github/DISCUSSION_TEMPLATE/README.md delete mode 100644 .github/DISCUSSION_TEMPLATE/announcements.yml delete mode 100644 .github/DISCUSSION_TEMPLATE/architecture.yml create mode 100644 .github/DISCUSSION_TEMPLATE/bug-triage.yml create mode 100644 .github/DISCUSSION_TEMPLATE/contributing.yml delete mode 100644 .github/DISCUSSION_TEMPLATE/contributors.yml create mode 100644 .github/DISCUSSION_TEMPLATE/feature-requests.yml delete mode 100644 .github/DISCUSSION_TEMPLATE/general.yml delete mode 100644 .github/DISCUSSION_TEMPLATE/release-planning.yml delete mode 100644 .github/DISCUSSION_TEMPLATE/rfcs-design.yml delete mode 100644 .github/DISCUSSION_TEMPLATE/show-and-tell.yml diff --git a/.github/DISCUSSION_TEMPLATE/README.md b/.github/DISCUSSION_TEMPLATE/README.md deleted file mode 100644 index f6c0905f4..000000000 --- a/.github/DISCUSSION_TEMPLATE/README.md +++ /dev/null @@ -1,150 +0,0 @@ -# GitHub Discussions — setup guide for utPLSQL/utPLSQL - -This folder contains the discussion category form templates that power structured -GitHub Discussions for the utPLSQL project. - ---- - -## File → category mapping - - - -| File | Category name to create in GitHub | Format | Who can post | -|------------------------|-----------------------------------|-----------------------|--------------------------------| -| `announcements.yml` | 📢 Announcements | Announcement | Maintainers only | -| `rfcs-design.yml` | 💡 RFCs & Design | Open-ended discussion | Everyone | -| `architecture.yml` | 🏗 Architecture | Open-ended discussion | Everyone | -| `release-planning.yml` | 🗓 Release Planning | Open-ended discussion | Maintainers only (recommended) | -| `q-a.yml` | ❓ Q&A | Question / Answer | Everyone | -| `show-and-tell.yml` | 🔬 Show & Tell | Open-ended discussion | Everyone | -| `contributors.yml` | 🤝 Contributors | Open-ended discussion | Everyone | -| `general.yml` | 💬 General | Open-ended discussion | Everyone | - -> **Polls** are a built-in GitHub Discussions type and do not support YAML templates. -> Create a 🗳 Polls category manually (type: Poll) — no template file needed. - ---- - -## Step-by-step setup - -### 1. Enable Discussions -Go to **Settings → Features** and check **Discussions**. - -### 2. Create the categories -Go to **Discussions → Categories → ✏️ Edit categories** (gear icon). - -Create each category listed in the table above. -**Order matters** — drag to set the display order shown below: - -1. 📢 Announcements -2. 💡 RFCs & Design -3. 🏗 Architecture -4. 🗓 Release Planning -5. ❓ Q&A -6. 🔬 Show & Tell -7. 🤝 Contributors -8. 🗳 Polls -9. 💬 General - -### 3. Commit the templates -Copy all `.yml` files from this folder into `.github/DISCUSSION_TEMPLATE/` in -the **default branch** (usually `develop` for utPLSQL). - -``` -.github/ -└── DISCUSSION_TEMPLATE/ - ├── announcements.yml - ├── rfcs-design.yml - ├── architecture.yml - ├── release-planning.yml - ├── q-a.yml - ├── show-and-tell.yml - ├── contributors.yml - └── general.yml -``` - -### 4. Configure category permissions - -| Category | Setting | -|------------------|--------------------------------------------------| -| Announcements | Set to **Maintainers only** in category settings | -| Release Planning | Recommended: **Maintainers only** | -| All others | Open to all | - -### 5. Create the welcome pinned post - -Create a first discussion in **Announcements** titled -**"Welcome to utPLSQL Discussions — how to use this space"** - -Suggested body: - -```markdown -## Welcome 👋 - -This is the place for design discussions, feature proposals, and community -conversation around utPLSQL. - -### Where to post - -| I want to… | Use | -|---|---| -| Propose a new feature or behaviour change | 💡 RFCs & Design | -| Discuss internal architecture | 🏗 Architecture | -| Ask a usage / how-to question | ❓ Q&A | -| Share a CI pipeline, integration, or tip | 🔬 Show & Tell | -| Ask about contributing / development setup | 🤝 Contributors | -| Vote on priorities | 🗳 Polls | -| Anything else | 💬 General | - -### Discussions vs Issues - -**Discussions** are for ideas that are still open, need input, or require consensus. -**Issues** are for well-scoped work that someone can pick up and implement. - -A maintainer will convert a Discussion to an Issue once scope is agreed. - -### Real-time chat - -For quick questions: [utPLSQL Slack](https://utplsql.slack.com) -For decisions that need a permanent record: post here. -``` - -Pin this post from the discussion's `…` menu → **Pin discussion**. - -### 6. Update the README - -Add a Discussions badge to the project README: - -```markdown -[![GitHub Discussions](https://img.shields.io/github/discussions/utPLSQL/utPLSQL)](https://github.com/utPLSQL/utPLSQL/discussions) -``` - -And add a short paragraph in the "Community" or "Contributing" section pointing -to Discussions as the place for design proposals. - ---- - -## Operating guidelines - -### Discussion → Issue conversion rule - -| Category | Convert when… | -|---------------|----------------------------------------------------------------------| -| RFCs & Design | Consensus reached, scope is defined | -| Architecture | Breaking change formally agreed by maintainers | -| Q&A | A confirmed bug surfaces in the thread | -| Contributors | A gap in docs or tooling is identified that can be filed as an issue | - -Use the **"Create issue from discussion"** button (available in the discussion's sidebar). - -### Housekeeping - -- Lock **Announcements** threads after 30 days. -- Close **Polls** after 14 days; post a summary comment with the result before closing. -- Label cross-references: apply the same labels used on issues - (`enhancement`, `breaking-change`, `coverage`, `oracle-version`, etc.) - to discussions for consistent search. diff --git a/.github/DISCUSSION_TEMPLATE/announcements.yml b/.github/DISCUSSION_TEMPLATE/announcements.yml deleted file mode 100644 index 262746e11..000000000 --- a/.github/DISCUSSION_TEMPLATE/announcements.yml +++ /dev/null @@ -1,54 +0,0 @@ -title: "[Announcement] " -labels: ["announcement"] -body: - - type: markdown - attributes: - value: | - > **Maintainers only.** This category is restricted to project maintainers. - > Announcements are pinned and locked after 30 days. - - - type: dropdown - id: announcement_type - attributes: - label: Announcement type - options: - - New release - - Release candidate / pre-release - - Roadmap update - - Deprecation notice - - Security advisory - - Community / governance update - - Other - validations: - required: true - - - type: input - id: version - attributes: - label: Version (if applicable) - placeholder: "e.g. 3.2.0" - validations: - required: false - - - type: textarea - id: body - attributes: - label: Announcement body - description: | - Write the full announcement here. - For releases, include: highlights, breaking changes, upgrade notes, and a link to the full changelog. - validations: - required: true - - - type: textarea - id: links - attributes: - label: Key links - description: Release tag, changelog, migration guide, Docker image, CLI download, etc. - placeholder: | - - Release: https://github.com/utPLSQL/utPLSQL/releases/tag/v… - - Changelog: … - - Docker: … - - CLI: … - validations: - required: false diff --git a/.github/DISCUSSION_TEMPLATE/architecture.yml b/.github/DISCUSSION_TEMPLATE/architecture.yml deleted file mode 100644 index f3df8e29c..000000000 --- a/.github/DISCUSSION_TEMPLATE/architecture.yml +++ /dev/null @@ -1,100 +0,0 @@ -title: "[Architecture] " -labels: ["architecture", "design"] -body: - - type: markdown - attributes: - value: | - ## Architecture discussion - Use this template for internal design decisions: changes to the suite-loading mechanism, - the coverage engine, DDL trigger behaviour, reporter infrastructure, or any - cross-cutting concern that affects the internals of utPLSQL. - - This category is primarily for **contributors and maintainers**. - If you want to propose a user-facing feature, use **RFCs & Design** instead. - - - type: input - id: title_short - attributes: - label: Component / area - description: Which internal component or subsystem does this discussion concern? - placeholder: "e.g. Suite loader, Coverage engine, Annotation parser, Event system" - validations: - required: true - - - type: textarea - id: context - attributes: - label: Context and current design - description: Briefly describe how the relevant part works today. - validations: - required: true - - - type: textarea - id: problem - attributes: - label: Problem or design question - description: What specific decision needs to be made, or what limitation needs to be addressed? - validations: - required: true - - - type: textarea - id: options - attributes: - label: Options under consideration - description: | - List the design options you are weighing. For each option describe: - - How it works - - Pros - - Cons - - Impact on Oracle compatibility - placeholder: | - **Option A — …** - How: … - Pros: … - Cons: … - - **Option B — …** - How: … - Pros: … - Cons: … - validations: - required: true - - - type: textarea - id: preferred - attributes: - label: Preferred direction (if any) - description: If you already lean toward one option, say so and why. Leave blank if genuinely open. - validations: - required: false - - - type: dropdown - id: breaking - attributes: - label: Does this introduce a breaking change? - options: - - "No" - - "Yes — public API change (ut_runner, ut packages, annotations)" - - "Yes — output/reporter format change" - - "Yes — internal package change (no public API impact)" - - "Unsure" - validations: - required: true - - - type: textarea - id: migration - attributes: - label: Migration / compatibility notes - description: If breaking, describe the migration path for users and downstream integrations. - validations: - required: false - - - type: checkboxes - id: checklist - attributes: - label: Checklist - options: - - label: I have reviewed the existing architecture docs and source - required: true - - label: Relevant unit / integration tests have been considered - required: false diff --git a/.github/DISCUSSION_TEMPLATE/bug-triage.yml b/.github/DISCUSSION_TEMPLATE/bug-triage.yml new file mode 100644 index 000000000..7a5da8d73 --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/bug-triage.yml @@ -0,0 +1,69 @@ +title: "[Bug?] " +labels: ["bug-triage"] +body: + - type: markdown + attributes: + value: | + Use this category if you think you have found a bug in the utPLSQL framework and want to discuss it before a formal issue is opened. + + Once a maintainer confirms the bug, they will open an issue and link it back here. You do not need to open an issue yourself. + + If you are certain it is a bug and can provide a reliable reproduction, you may open an issue directly instead. + + - type: input + id: utplsql-version + attributes: + label: utPLSQL version + placeholder: "e.g. 3.1.13" + validations: + required: true + + - type: input + id: oracle-version + attributes: + label: Oracle Database version + placeholder: "e.g. 19c, 21c" + validations: + required: true + + - type: input + id: os + attributes: + label: Operating system + placeholder: "e.g. Linux, Windows Server 2019" + validations: + required: false + + - type: textarea + id: description + attributes: + label: What did you observe? + description: Describe the unexpected behaviour. Include any error messages or stack traces. + render: text + validations: + required: true + + - type: textarea + id: expected + attributes: + label: What did you expect? + description: Describe what you expected to happen instead. + validations: + required: true + + - type: textarea + id: reproduction + attributes: + label: Reproduction case + description: Paste the minimal PL/SQL needed to reproduce the problem. The simpler, the better. + render: sql + validations: + required: false + + - type: textarea + id: investigation + attributes: + label: What have you investigated so far? + description: Any findings from your own debugging that might help narrow this down. + validations: + required: false diff --git a/.github/DISCUSSION_TEMPLATE/contributing.yml b/.github/DISCUSSION_TEMPLATE/contributing.yml new file mode 100644 index 000000000..31a213cbb --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/contributing.yml @@ -0,0 +1,43 @@ +title: "" +labels: ["contributing"] +body: + - type: markdown + attributes: + value: | + Use this category if you are working on or considering a contribution to the utPLSQL framework codebase and have questions about the internals, development setup, testing approach, or contribution process. + + Before posting, it is worth checking: + - [CONTRIBUTING.md](https://github.com/utPLSQL/utPLSQL/blob/develop/CONTRIBUTING.md) + - [Development setup guide](https://github.com/utPLSQL/utPLSQL/blob/develop/development/README.md) + + - type: dropdown + id: topic + attributes: + label: Topic + options: + - Development environment setup + - Understanding the codebase + - Test writing and running locally + - CI / build pipeline + - Pull request process + - Architectural question + - Other + validations: + required: true + + - type: textarea + id: question + attributes: + label: Question or topic + description: Describe what you are working on and what you need help with. + validations: + required: true + + - type: textarea + id: context + attributes: + label: Relevant code or context + description: Paste any relevant code, configuration, or error output here. + render: sql + validations: + required: false diff --git a/.github/DISCUSSION_TEMPLATE/contributors.yml b/.github/DISCUSSION_TEMPLATE/contributors.yml deleted file mode 100644 index 6325961de..000000000 --- a/.github/DISCUSSION_TEMPLATE/contributors.yml +++ /dev/null @@ -1,56 +0,0 @@ -title: "[Contributors] " -labels: ["contributors"] -body: - - type: markdown - attributes: - value: | - ## Contributors - Questions about **contributing to utPLSQL** — development environment setup, - the test suite, pull request process, coding conventions, or anything else - that helps you get your first (or next) contribution merged. - - **Useful links before posting:** - - [CONTRIBUTING.md](../../blob/develop/CONTRIBUTING.md) - - [Development environment setup](../../blob/develop/docs/development/developer-guide.md) - - [Open issues labelled `good first issue`](../../issues?q=is%3Aopen+label%3A%22good+first+issue%22) - - - type: dropdown - id: topic - attributes: - label: Topic - options: - - Dev environment / Docker setup - - Running the test suite locally - - Understanding the codebase - - PR review process - - Coding conventions / style - - Good first issue — looking for guidance - - Release process - - Documentation contribution - - Other - validations: - required: true - - - type: textarea - id: question - attributes: - label: Question or request - description: What do you need help with? - validations: - required: true - - - type: textarea - id: context - attributes: - label: What you have tried - description: Steps already taken, error messages, links to relevant code, etc. - validations: - required: false - - - type: input - id: os - attributes: - label: Host OS / environment - placeholder: "e.g. macOS 14, Windows 11, Ubuntu 22.04, Docker on Linux" - validations: - required: false diff --git a/.github/DISCUSSION_TEMPLATE/feature-requests.yml b/.github/DISCUSSION_TEMPLATE/feature-requests.yml new file mode 100644 index 000000000..130d30c28 --- /dev/null +++ b/.github/DISCUSSION_TEMPLATE/feature-requests.yml @@ -0,0 +1,62 @@ +title: "[Feature] " +labels: ["feature-request"] +body: + - type: markdown + attributes: + value: | + Use this category for feature ideas specific to the utPLSQL framework: new matchers, annotation behaviour, reporter output, suite control, coverage, or installation. + + > For ideas that affect multiple components or the project direction overall, use [org-level Feature Requests](https://github.com/orgs/utPLSQL/discussions/categories/feature-requests) instead. + + A maintainer will mark this discussion as answered once the proposal is accepted or declined. + If accepted, a maintainer will convert it to an issue for implementation tracking -- you do not need to open an issue yourself. + + - type: textarea + id: problem + attributes: + label: Problem or motivation + description: What problem does this feature solve? What is the current limitation or pain point? + validations: + required: true + + - type: textarea + id: proposal + attributes: + label: Proposed solution + description: Describe the feature you have in mind. Include examples of how it would be used, ideally with PL/SQL annotation or API examples. + render: sql + validations: + required: true + + - type: textarea + id: alternatives + attributes: + label: Alternatives or workarounds considered + description: Have you found any alternative approaches or partial workarounds? + validations: + required: false + + - type: dropdown + id: area + attributes: + label: Framework area + options: + - Annotations + - Matchers + - Reporters + - Suite / test control + - Coverage + - Transaction control + - Installation / upgrade + - Performance + - Other + validations: + required: true + + - type: input + id: utplsql-version + attributes: + label: utPLSQL version you are using + placeholder: "e.g. 3.1.13" + validations: + required: false diff --git a/.github/DISCUSSION_TEMPLATE/general.yml b/.github/DISCUSSION_TEMPLATE/general.yml deleted file mode 100644 index 0e3b8d100..000000000 --- a/.github/DISCUSSION_TEMPLATE/general.yml +++ /dev/null @@ -1,28 +0,0 @@ -title: "" -labels: ["general"] -body: - - type: markdown - attributes: - value: | - ## General discussion - For open-ended conversations that don't fit another category: - project direction, community topics, suggestions, or anything else. - - If your post turns out to be a feature proposal, a maintainer may move it to - **RFCs & Design**. If it is a question about using utPLSQL, consider posting - in **Q&A** instead so a helpful answer can be marked. - - - type: textarea - id: body - attributes: - label: What's on your mind? - validations: - required: true - - - type: textarea - id: context - attributes: - label: Additional context - description: Background, links, related issues or discussions. - validations: - required: false diff --git a/.github/DISCUSSION_TEMPLATE/q-a.yml b/.github/DISCUSSION_TEMPLATE/q-a.yml index e4ff1d452..30b372760 100644 --- a/.github/DISCUSSION_TEMPLATE/q-a.yml +++ b/.github/DISCUSSION_TEMPLATE/q-a.yml @@ -17,25 +17,18 @@ body: > If this turns out to be a **bug**, a maintainer will convert this discussion into an Issue. - type: input - id: utplsql_version + id: utplsql-version attributes: label: utPLSQL version placeholder: "e.g. 3.1.13" validations: required: true - - type: dropdown - id: oracle_version + - type: input + id: oracle-version attributes: - label: Oracle version - options: - - Oracle 11g - - Oracle 12c - - Oracle 18c - - Oracle 19c - - Oracle 21c - - Oracle 23c / 23ai - - Other / unsure + label: Oracle Database version + placeholder: "e.g. 19c, 21c" validations: required: true @@ -43,7 +36,7 @@ body: id: question attributes: label: Question - description: Describe what you are trying to do and what you have tried so far. + description: Describe what you are trying to do and what you have already tried. validations: required: true @@ -59,29 +52,10 @@ body: required: false - type: textarea - id: expected - attributes: - label: Expected behaviour - validations: - required: false - - - type: textarea - id: actual - attributes: - label: Actual behaviour / error - validations: - required: false - - - type: dropdown - id: install_method + id: output attributes: - label: Installation method - options: - - utPLSQL-cli - - SQL*Plus script - - Docker / utPLSQL-docker - - Liquibase / Flyway - - Other - - N/A + label: Actual output or error + description: Paste any error messages or unexpected output here. + render: text validations: required: false diff --git a/.github/DISCUSSION_TEMPLATE/release-planning.yml b/.github/DISCUSSION_TEMPLATE/release-planning.yml deleted file mode 100644 index 5663d7613..000000000 --- a/.github/DISCUSSION_TEMPLATE/release-planning.yml +++ /dev/null @@ -1,90 +0,0 @@ -title: "[Release] v" -labels: ["release-planning"] -body: - - type: markdown - attributes: - value: | - ## Release planning discussion - Use this template to discuss the scope of an upcoming release: - what goes in, what gets deferred, and what the acceptance criteria are. - - **Maintainers:** pin this discussion and link it from the corresponding GitHub Milestone. - - - type: input - id: version - attributes: - label: Target version - placeholder: "e.g. 3.2.0" - validations: - required: true - - - type: dropdown - id: release_type - attributes: - label: Release type - options: - - Major (breaking changes) - - Minor (new features, backward-compatible) - - Patch (bug fixes only) - validations: - required: true - - - type: textarea - id: goals - attributes: - label: Release goals - description: What are the 2–4 key things this release should achieve? - placeholder: | - 1. - 2. - 3. - validations: - required: true - - - type: textarea - id: scope_in - attributes: - label: In scope (proposed issues / PRs) - description: | - Link the GitHub Issues and PRs targeted for this release. - Use the format: `- [ ] #123 — short description` - placeholder: | - - [ ] #123 — ... - - [ ] #456 — ... - validations: - required: false - - - type: textarea - id: scope_out - attributes: - label: Out of scope / explicitly deferred - description: Issues that were considered but will not be included — and why. - validations: - required: false - - - type: input - id: target_date - attributes: - label: Target release date (approximate) - placeholder: "e.g. 2025-Q2" - validations: - required: false - - - type: textarea - id: oracle_matrix - attributes: - label: Oracle version test matrix - description: Which Oracle versions must pass CI before this release ships? - placeholder: | - - [ ] Oracle 19c - - [ ] Oracle 21c - - [ ] Oracle 23ai - validations: - required: false - - - type: textarea - id: notes - attributes: - label: Additional notes - validations: - required: false diff --git a/.github/DISCUSSION_TEMPLATE/rfcs-design.yml b/.github/DISCUSSION_TEMPLATE/rfcs-design.yml deleted file mode 100644 index 32c0a33c7..000000000 --- a/.github/DISCUSSION_TEMPLATE/rfcs-design.yml +++ /dev/null @@ -1,88 +0,0 @@ -title: "[RFC] " -labels: ["rfc", "design"] -body: - - type: markdown - attributes: - value: | - ## Request for Comments — design proposal - Use this template to propose a new feature, a change to existing behaviour, or a significant refactoring. - Once there is consensus and a clear scope, a maintainer will convert this discussion into one or more GitHub Issues. - - **Before posting:** search existing RFCs and open issues to avoid duplicates. - - - type: input - id: summary - attributes: - label: Summary - description: One sentence — what are you proposing? - placeholder: "Add support for ..." - validations: - required: true - - - type: textarea - id: problem - attributes: - label: Problem / motivation - description: What problem does this solve? Who is affected and how often? - placeholder: | - Currently, when ... it is not possible to ... - This forces users to ... - validations: - required: true - - - type: textarea - id: proposal - attributes: - label: Proposed solution - description: Describe the solution in as much detail as you have. Pseudo-code, SQL, or PL/SQL snippets are welcome. - placeholder: | - ```sql - -- example of the proposed API - ``` - validations: - required: true - - - type: textarea - id: alternatives - attributes: - label: Alternatives considered - description: What other approaches did you look at? Why did you rule them out? - validations: - required: false - - - type: textarea - id: breaking - attributes: - label: Breaking-change impact - description: | - Does this change affect existing annotations, package APIs, or test output formats? - List affected public symbols (ut_runner, ut, annotations, reporters …). - validations: - required: false - - - type: dropdown - id: oracle_versions - attributes: - label: Oracle version relevance - description: Which Oracle versions does this apply to? - multiple: true - options: - - All supported versions - - Oracle 11g - - Oracle 12c - - Oracle 18c - - Oracle 19c - - Oracle 21c - - Oracle 23c / 23ai - validations: - required: true - - - type: checkboxes - id: checklist - attributes: - label: Checklist - options: - - label: I have searched existing discussions and issues for duplicates - required: true - - label: I am willing to help implement or review this feature - required: false diff --git a/.github/DISCUSSION_TEMPLATE/show-and-tell.yml b/.github/DISCUSSION_TEMPLATE/show-and-tell.yml deleted file mode 100644 index 4443c5de6..000000000 --- a/.github/DISCUSSION_TEMPLATE/show-and-tell.yml +++ /dev/null @@ -1,79 +0,0 @@ -title: "[Show & Tell] " -labels: ["show-and-tell"] -body: - - type: markdown - attributes: - value: | - ## Show & Tell - Share how you are using utPLSQL in the wild — CI pipelines, IDE integrations, - custom reporters, coverage setups, framework wrappers, or anything else the - community might learn from. - - Posts here are a great source of real-world examples for the documentation. - - - type: input - id: title_short - attributes: - label: What are you sharing? - placeholder: "e.g. utPLSQL + GitHub Actions CI pipeline for Oracle 23ai" - validations: - required: true - - - type: dropdown - id: category - attributes: - label: Category - multiple: true - options: - - CI/CD integration - - IDE / SQL client integration - - Custom reporter - - Code coverage setup - - Framework wrapper / helper library - - Docker / containerised testing - - Annotation patterns - - Performance / large test suite - - Other - validations: - required: true - - - type: textarea - id: description - attributes: - label: Description - description: Describe what you built or configured and why it might be useful to others. - validations: - required: true - - - type: textarea - id: snippet - attributes: - label: Code or configuration snippet - description: Paste the most relevant excerpt. Link to a repo or Gist if you have one. - render: yaml - validations: - required: false - - - type: input - id: utplsql_version - attributes: - label: utPLSQL version used - placeholder: "e.g. 3.1.13" - validations: - required: false - - - type: input - id: oracle_version - attributes: - label: Oracle version - placeholder: "e.g. Oracle 19c" - validations: - required: false - - - type: textarea - id: links - attributes: - label: Links - description: Repository, blog post, documentation page, etc. - validations: - required: false From d9eb1aabb10a4000695a019c8dbea7dd95c2e223 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 15:41:46 +0300 Subject: [PATCH 641/887] Update changelog --- CHANGELOG.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index f75662f75..d304ab172 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,19 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ --- +## [v3.2.2] - 2026-05-24 + +## What's Changed +* Filtering by tags fixed for schemas containing suite-paths and contexts by @jgebal in [1325](https://github.com/utPLSQL/utPLSQL/pull/1325) +* Fixed issue with reporter failing to initialize by @jgebal in [1354](https://github.com/utPLSQL/utPLSQL/pull/1354) +* Fixed issue with duplicate sources from dba_source by @jgebal in [1355](https://github.com/utPLSQL/utPLSQL/pull/1355) +* Allow HTML coverage on FIPS-enabled DB by @jgebal in [1356](https://github.com/utPLSQL/utPLSQL/pull/1356) + + +**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.01...v3.2.2 + +--- + ## [v3.2.01] - 2026-04-22 ## Important From 9d5e1b02f96d8807dfd8db76def73d85c7ee9237 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 15:51:31 +0300 Subject: [PATCH 642/887] Add automatic update of changelog.md file with every release --- .github/workflows/release.yml | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4b5d59463..7bcaa033f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -36,6 +36,38 @@ jobs: git config --global user.email "github-actions[bot]@users.noreply.github.com" git config --global user.name "github-actions[bot]" + - name: Update CHANGELOG.md with release notes + env: + RELEASE_BODY: ${{ github.event.release.body }} + RELEASE_TAG: ${{ github.event.release.tag_name }} + RELEASE_DATE: ${{ github.event.release.published_at }} + TARGET_BRANCH: ${{ github.event.release.target_commitish }} + run: | + python3 - <<'PYEOF' + import os + + tag = os.environ['RELEASE_TAG'] + body = os.environ['RELEASE_BODY'].strip() + date = os.environ['RELEASE_DATE'][:10] + + new_section = f"## [{tag}] - {date}\n\n{body}\n\n---\n\n" + + with open('CHANGELOG.md', 'r') as f: + content = f.read() + + marker = '\n---\n' + pos = content.index(marker) + len(marker) + updated = content[:pos] + '\n' + new_section + content[pos:] + + with open('CHANGELOG.md', 'w') as f: + f.write(updated) + + print(f"Added {tag} to CHANGELOG.md") + PYEOF + git add CHANGELOG.md + git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" + git push origin HEAD:"${TARGET_BRANCH}" + - name: Build and publish documentation run: | pip install mkdocs From ae3185a523b6eaa35c12e7d9015760b72f9ea9cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 16:10:44 +0300 Subject: [PATCH 643/887] Adding automatic publishing of release announcements --- .github/workflows/release.yml | 45 +++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 7bcaa033f..7826c1f0d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -97,3 +97,48 @@ jobs: utPLSQL.tar.gz utPLSQL.tar.gz.md5 + - name: Post release announcement to org discussions + env: + GH_TOKEN: ${{ secrets.ORG_DISCUSSION_TOKEN }} + RELEASE_TAG: ${{ github.event.release.tag_name }} + RELEASE_BODY: ${{ github.event.release.body }} + RELEASE_URL: ${{ github.event.release.html_url }} + run: | + ORG="utPLSQL" + + ORG_DATA=$(gh api graphql -f query='query($org: String!) { + organization(login: $org) { + id + discussionCategories(first: 20) { + nodes { id name } + } + } + }' -f org="$ORG") + + ORG_ID=$(echo "$ORG_DATA" | jq -r '.data.organization.id') + CATEGORY_ID=$(echo "$ORG_DATA" | jq -r \ + '.data.organization.discussionCategories.nodes[] | select(.name == "Announcements") | .id') + + BODY="${RELEASE_BODY} + + --- + [View full release on GitHub](${RELEASE_URL})" + + DISCUSSION_URL=$(gh api graphql -f query='mutation($orgId: ID!, $categoryId: ID!, $title: String!, $body: String!) { + createDiscussion(input: { + organizationId: $orgId, + categoryId: $categoryId, + title: $title, + body: $body + }) { + discussion { url } + } + }' \ + -f orgId="$ORG_ID" \ + -f categoryId="$CATEGORY_ID" \ + -f title="utPLSQL ${RELEASE_TAG} released" \ + -f body="$BODY" \ + --jq '.data.createDiscussion.discussion.url') + + echo "Announcement posted: $DISCUSSION_URL" + From 3004afaf7cca0670399d8ff8f66b3a08ad2ee5a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 16:36:43 +0300 Subject: [PATCH 644/887] Update Release process --- .github/workflows/release.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 7826c1f0d..9de687830 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -42,7 +42,11 @@ jobs: RELEASE_TAG: ${{ github.event.release.tag_name }} RELEASE_DATE: ${{ github.event.release.published_at }} TARGET_BRANCH: ${{ github.event.release.target_commitish }} + GH_TOKEN: ${{ secrets.ELEVATED_TOKEN }} run: | + # Configure git to use the elevated token + git config --global credential.helper store + echo "https://x-access-token:${GH_TOKEN}@github.com" > ~/.git-credentials python3 - <<'PYEOF' import os From cc8711c86da69a7f3222ec126e11b9dcb595968d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 16:49:16 +0300 Subject: [PATCH 645/887] Update Release process --- .github/workflows/release.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9de687830..07dbaacbf 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -25,12 +25,6 @@ jobs: env-file: .github/variables/.env - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action - - name: Set build version number env variables - run: .github/scripts/set_release_version_numbers_env.sh - - - name: Update project version & build number in source code and documentation - run: .github/scripts/update_project_version.sh - - name: Setup git config run: | git config --global user.email "github-actions[bot]@users.noreply.github.com" @@ -72,6 +66,12 @@ jobs: git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" git push origin HEAD:"${TARGET_BRANCH}" + - name: Set build version number env variables + run: .github/scripts/set_release_version_numbers_env.sh + + - name: Update project version & build number in source code and documentation + run: .github/scripts/update_project_version.sh + - name: Build and publish documentation run: | pip install mkdocs From 2170365d76e3dfa6a0ea4267448109298f962737 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 17:33:08 +0300 Subject: [PATCH 646/887] Update Release process --- .github/workflows/release.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 07dbaacbf..25377d076 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -36,11 +36,8 @@ jobs: RELEASE_TAG: ${{ github.event.release.tag_name }} RELEASE_DATE: ${{ github.event.release.published_at }} TARGET_BRANCH: ${{ github.event.release.target_commitish }} - GH_TOKEN: ${{ secrets.ELEVATED_TOKEN }} + GITHUB_TOKEN: ${{ secrets.ELEVATED_TOKEN }} run: | - # Configure git to use the elevated token - git config --global credential.helper store - echo "https://x-access-token:${GH_TOKEN}@github.com" > ~/.git-credentials python3 - <<'PYEOF' import os From e773abce2fc34f359a70f6337786a858e6dab71a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 18:32:20 +0300 Subject: [PATCH 647/887] Update Release process --- .github/workflows/release.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 25377d076..c306cf899 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -59,8 +59,11 @@ jobs: print(f"Added {tag} to CHANGELOG.md") PYEOF + git config user.name "github-actions[bot]" + git config user.email "github-actions[bot]@users.noreply.github.com" git add CHANGELOG.md git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" + echo "TARGET_BRANCH=${TARGET_BRANCH}" git push origin HEAD:"${TARGET_BRANCH}" - name: Set build version number env variables From d5d98ba23763f446fbe3717735f82115b0a36873 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 3 Jun 2026 16:37:16 +0100 Subject: [PATCH 648/887] Add release notes for v3.2.2-test to CHANGELOG.md [skip ci] --- CHANGELOG.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d304ab172..494b7f642 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,20 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ --- +## [v3.2.2-test] - 2026-06-03 + +## This is a test of a release publishing + * no new features added + * no changes + * just a release tag + * new announcement should be created + * changelog should be updated + +**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test + +--- + + ## [v3.2.2] - 2026-05-24 ## What's Changed From 2ac7676c286b2feef8b569e3a67d9d9c6ab34c5d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 18:39:51 +0300 Subject: [PATCH 649/887] Update Release process --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c306cf899..09cbb573b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -19,6 +19,7 @@ jobs: steps: - uses: actions/checkout@v4 with: + token: ${{ secrets.ELEVATED_TOKEN }} fetch-depth: 0 - uses: c-py/action-dotenv-to-setenv@v5 with: @@ -36,7 +37,6 @@ jobs: RELEASE_TAG: ${{ github.event.release.tag_name }} RELEASE_DATE: ${{ github.event.release.published_at }} TARGET_BRANCH: ${{ github.event.release.target_commitish }} - GITHUB_TOKEN: ${{ secrets.ELEVATED_TOKEN }} run: | python3 - <<'PYEOF' import os From f7068950923f05d6c3b338814737df1ee3606482 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 18:45:44 +0300 Subject: [PATCH 650/887] Revert changelog changes --- CHANGELOG.md | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 494b7f642..d304ab172 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,20 +5,6 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ --- -## [v3.2.2-test] - 2026-06-03 - -## This is a test of a release publishing - * no new features added - * no changes - * just a release tag - * new announcement should be created - * changelog should be updated - -**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test - ---- - - ## [v3.2.2] - 2026-05-24 ## What's Changed From 00bbdb865683f01af23f56366d2826653928f5f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 3 Jun 2026 18:48:53 +0300 Subject: [PATCH 651/887] Update Release process --- .github/workflows/release.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 09cbb573b..0def9719a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -61,6 +61,7 @@ jobs: PYEOF git config user.name "github-actions[bot]" git config user.email "github-actions[bot]@users.noreply.github.com" + git config --global url."https://oauth2:${{ secrets.ELEVATED_TOKEN }}@github.com/".insteadOf "https://github.com/" git add CHANGELOG.md git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" echo "TARGET_BRANCH=${TARGET_BRANCH}" From e584991c81e52d278144e82cd01e679d2bc92287 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 08:57:16 +0300 Subject: [PATCH 652/887] Update Release process --- .github/workflows/release.yml | 12 +-- .github/workflows/test_publishing.yml | 112 ++++++++++++++++++++++++++ 2 files changed, 114 insertions(+), 10 deletions(-) create mode 100644 .github/workflows/test_publishing.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0def9719a..972e239ed 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -15,22 +15,18 @@ jobs: concurrency: upload runs-on: ubuntu-latest timeout-minutes: 60 + env: + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} steps: - uses: actions/checkout@v4 with: - token: ${{ secrets.ELEVATED_TOKEN }} fetch-depth: 0 - uses: c-py/action-dotenv-to-setenv@v5 with: env-file: .github/variables/.env - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action - - name: Setup git config - run: | - git config --global user.email "github-actions[bot]@users.noreply.github.com" - git config --global user.name "github-actions[bot]" - - name: Update CHANGELOG.md with release notes env: RELEASE_BODY: ${{ github.event.release.body }} @@ -59,12 +55,8 @@ jobs: print(f"Added {tag} to CHANGELOG.md") PYEOF - git config user.name "github-actions[bot]" - git config user.email "github-actions[bot]@users.noreply.github.com" - git config --global url."https://oauth2:${{ secrets.ELEVATED_TOKEN }}@github.com/".insteadOf "https://github.com/" git add CHANGELOG.md git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" - echo "TARGET_BRANCH=${TARGET_BRANCH}" git push origin HEAD:"${TARGET_BRANCH}" - name: Set build version number env variables diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml new file mode 100644 index 000000000..10b3665b5 --- /dev/null +++ b/.github/workflows/test_publishing.yml @@ -0,0 +1,112 @@ +name: Create and publish release artifacts +on: + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + + upload_artifacts: + name: Upload archives + concurrency: upload + runs-on: ubuntu-latest + timeout-minutes: 60 + env: + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} + + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - uses: c-py/action-dotenv-to-setenv@v5 + with: + env-file: .github/variables/.env + - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action + + - name: Update CHANGELOG.md with release notes + env: + RELEASE_BODY: | + ## This is a test of a release publishing + * no new features added + * no changes + * just a release tag + * new announcement should be created + * changelog should be updated + + **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test + RELEASE_TAG: "v3.2.2-test" + RELEASE_DATE: "2026-06-04" + TARGET_BRANCH: "develop" + run: | + python3 - <<'PYEOF' + import os + + tag = os.environ['RELEASE_TAG'] + body = os.environ['RELEASE_BODY'].strip() + date = os.environ['RELEASE_DATE'][:10] + + new_section = f"## [{tag}] - {date}\n\n{body}\n\n---\n\n" + + with open('CHANGELOG.md', 'r') as f: + content = f.read() + + marker = '\n---\n' + pos = content.index(marker) + len(marker) + updated = content[:pos] + '\n' + new_section + content[pos:] + + with open('CHANGELOG.md', 'w') as f: + f.write(updated) + + print(f"Added {tag} to CHANGELOG.md") + PYEOF + git add CHANGELOG.md + git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" + git push origin HEAD:"${TARGET_BRANCH}" + + - name: Post release announcement to org discussions + env: + GH_TOKEN: ${{ secrets.ORG_DISCUSSION_TOKEN }} + RELEASE_TAG: ${{ github.event.release.tag_name }} + RELEASE_BODY: ${{ github.event.release.body }} + RELEASE_URL: ${{ github.event.release.html_url }} + run: | + ORG="utPLSQL" + + ORG_DATA=$(gh api graphql -f query='query($org: String!) { + organization(login: $org) { + id + discussionCategories(first: 20) { + nodes { id name } + } + } + }' -f org="$ORG") + + ORG_ID=$(echo "$ORG_DATA" | jq -r '.data.organization.id') + CATEGORY_ID=$(echo "$ORG_DATA" | jq -r \ + '.data.organization.discussionCategories.nodes[] | select(.name == "Announcements") | .id') + + BODY="${RELEASE_BODY} + + --- + [View full release on GitHub](${RELEASE_URL})" + + DISCUSSION_URL=$(gh api graphql -f query='mutation($orgId: ID!, $categoryId: ID!, $title: String!, $body: String!) { + createDiscussion(input: { + organizationId: $orgId, + categoryId: $categoryId, + title: $title, + body: $body + }) { + discussion { url } + } + }' \ + -f orgId="$ORG_ID" \ + -f categoryId="$CATEGORY_ID" \ + -f title="utPLSQL ${RELEASE_TAG} released" \ + -f body="$BODY" \ + --jq '.data.createDiscussion.discussion.url') + + echo "Announcement posted: $DISCUSSION_URL" + From 42f883e1819894ffd42b7f43320274d3d4dcd496 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 08:58:16 +0300 Subject: [PATCH 653/887] Update Release process --- .github/workflows/test_publishing.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 10b3665b5..bf9f43644 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -1,4 +1,4 @@ -name: Create and publish release artifacts +name: TEst publishing of release announcement on: workflow_dispatch: From 0e740c35978cdfb2d38f01e4807f2240c14add2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 08:59:26 +0300 Subject: [PATCH 654/887] Update Release process --- .github/workflows/test_publishing.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index bf9f43644..459706632 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -14,7 +14,7 @@ jobs: runs-on: ubuntu-latest timeout-minutes: 60 env: - API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} + API_TOKEN_GITHUB: ${{ secrets.ELEVATED_TOKEN }} steps: - uses: actions/checkout@v4 From d34536c9e87b8b460adfe19216be732e697560be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:01:37 +0300 Subject: [PATCH 655/887] Testing Release process --- .github/workflows/test_publishing.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 459706632..9b614bf9c 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -14,12 +14,13 @@ jobs: runs-on: ubuntu-latest timeout-minutes: 60 env: - API_TOKEN_GITHUB: ${{ secrets.ELEVATED_TOKEN }} + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} steps: - uses: actions/checkout@v4 with: fetch-depth: 0 + token: ${{ env.API_TOKEN_GITHUB }} - uses: c-py/action-dotenv-to-setenv@v5 with: env-file: .github/variables/.env From 5e1ff2fda4b47b1950cb17c608746259b9489c51 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 4 Jun 2026 07:02:08 +0100 Subject: [PATCH 656/887] Add release notes for v3.2.2-test to CHANGELOG.md [skip ci] --- CHANGELOG.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d304ab172..f84ce7ecb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,20 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ --- +## [v3.2.2-test] - 2026-06-04 + +## This is a test of a release publishing + * no new features added + * no changes + * just a release tag + * new announcement should be created + * changelog should be updated + +**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test + +--- + + ## [v3.2.2] - 2026-05-24 ## What's Changed From 9555c026be4fdbbb60f9c92a9bcae03e55b15fd8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:06:01 +0300 Subject: [PATCH 657/887] Testing Release process --- .github/workflows/release.yml | 1 + .github/workflows/test_publishing.yml | 35 ++++++++++++++++----------- 2 files changed, 22 insertions(+), 14 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 972e239ed..3c490d18c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -22,6 +22,7 @@ jobs: - uses: actions/checkout@v4 with: fetch-depth: 0 + token: ${{ env.API_TOKEN_GITHUB }} - uses: c-py/action-dotenv-to-setenv@v5 with: env-file: .github/variables/.env diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 9b614bf9c..8b97381fe 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -78,24 +78,32 @@ jobs: ORG_DATA=$(gh api graphql -f query='query($org: String!) { organization(login: $org) { id - discussionCategories(first: 20) { - nodes { id name } - } } }' -f org="$ORG") ORG_ID=$(echo "$ORG_DATA" | jq -r '.data.organization.id') - CATEGORY_ID=$(echo "$ORG_DATA" | jq -r \ - '.data.organization.discussionCategories.nodes[] | select(.name == "Announcements") | .id') - + + # Get discussion categories - these are typically repo-level + # For org-level, you may need to use a repository instead + CATEGORY_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { + repository(owner: $owner, name: $name) { + discussionCategories(first: 20) { + nodes { id name } + } + } + }' -f owner="$ORG" -f name=".github") + + CATEGORY_ID=$(echo "$CATEGORY_DATA" | jq -r \ + '.data.repository.discussionCategories.nodes[] | select(.name == "Announcements") | .id') + BODY="${RELEASE_BODY} - + --- [View full release on GitHub](${RELEASE_URL})" - - DISCUSSION_URL=$(gh api graphql -f query='mutation($orgId: ID!, $categoryId: ID!, $title: String!, $body: String!) { + + DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $categoryId: ID!, $title: String!, $body: String!) { createDiscussion(input: { - organizationId: $orgId, + repositoryId: $repoId, categoryId: $categoryId, title: $title, body: $body @@ -103,11 +111,10 @@ jobs: discussion { url } } }' \ - -f orgId="$ORG_ID" \ + -f repoId="$REPO_ID" \ -f categoryId="$CATEGORY_ID" \ -f title="utPLSQL ${RELEASE_TAG} released" \ -f body="$BODY" \ --jq '.data.createDiscussion.discussion.url') - - echo "Announcement posted: $DISCUSSION_URL" - + + echo "Announcement posted: $DISCUSSION_URL" \ No newline at end of file From dd050afd50f88cbc09d05ad7ea5a8d316806da6c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 4 Jun 2026 07:07:00 +0100 Subject: [PATCH 658/887] Add release notes for v3.2.2-test to CHANGELOG.md [skip ci] --- CHANGELOG.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index f84ce7ecb..ae89774e6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,6 +19,20 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ --- +## [v3.2.2-test] - 2026-06-04 + +## This is a test of a release publishing + * no new features added + * no changes + * just a release tag + * new announcement should be created + * changelog should be updated + +**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test + +--- + + ## [v3.2.2] - 2026-05-24 ## What's Changed From 3571eed69d7ff0e8cf7bce9d4bea79ce6565e3ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:09:37 +0300 Subject: [PATCH 659/887] Testing Release process --- .github/workflows/test_publishing.yml | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 8b97381fe..d65613916 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -69,9 +69,17 @@ jobs: - name: Post release announcement to org discussions env: GH_TOKEN: ${{ secrets.ORG_DISCUSSION_TOKEN }} - RELEASE_TAG: ${{ github.event.release.tag_name }} - RELEASE_BODY: ${{ github.event.release.body }} - RELEASE_URL: ${{ github.event.release.html_url }} + RELEASE_TAG: "v3.2.2-test" + RELEASE_BODY: | + ## This is a test of a release publishing + * no new features added + * no changes + * just a release tag + * new announcement should be created + * changelog should be updated + + **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test + RELEASE_URL: "https://github.com/utPLSQL/utPLSQL/releases/tag/v3.2.2" run: | ORG="utPLSQL" From 16a3a8159d4c6e1569fa124a19eee87a0b7eceba Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 4 Jun 2026 07:10:23 +0100 Subject: [PATCH 660/887] Add release notes for v3.2.2-test to CHANGELOG.md [skip ci] --- CHANGELOG.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index ae89774e6..9c17688f7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -33,6 +33,20 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ --- +## [v3.2.2-test] - 2026-06-04 + +## This is a test of a release publishing + * no new features added + * no changes + * just a release tag + * new announcement should be created + * changelog should be updated + +**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test + +--- + + ## [v3.2.2] - 2026-05-24 ## What's Changed From 4cc16d63b97437d9209092e59301f00d9cbf0b2a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:17:53 +0300 Subject: [PATCH 661/887] Testing Release process --- .github/workflows/test_publishing.yml | 35 +++++++++------------------ 1 file changed, 11 insertions(+), 24 deletions(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index d65613916..1c5161871 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -82,37 +82,25 @@ jobs: RELEASE_URL: "https://github.com/utPLSQL/utPLSQL/releases/tag/v3.2.2" run: | ORG="utPLSQL" + REPO_NAME=".github" - ORG_DATA=$(gh api graphql -f query='query($org: String!) { - organization(login: $org) { + # Get repository ID + REPO_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { + repository(owner: $owner, name: $name) { id } - }' -f org="$ORG") + }' -f owner="$ORG" -f name="$REPO_NAME") + + REPO_ID=$(echo "$REPO_DATA" | jq -r '.data.repository.id') - ORG_ID=$(echo "$ORG_DATA" | jq -r '.data.organization.id') - - # Get discussion categories - these are typically repo-level - # For org-level, you may need to use a repository instead - CATEGORY_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { - repository(owner: $owner, name: $name) { - discussionCategories(first: 20) { - nodes { id name } - } - } - }' -f owner="$ORG" -f name=".github") - - CATEGORY_ID=$(echo "$CATEGORY_DATA" | jq -r \ - '.data.repository.discussionCategories.nodes[] | select(.name == "Announcements") | .id') - BODY="${RELEASE_BODY} - + --- [View full release on GitHub](${RELEASE_URL})" - - DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $categoryId: ID!, $title: String!, $body: String!) { + + DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $title: String!, $body: String!) { createDiscussion(input: { repositoryId: $repoId, - categoryId: $categoryId, title: $title, body: $body }) { @@ -120,9 +108,8 @@ jobs: } }' \ -f repoId="$REPO_ID" \ - -f categoryId="$CATEGORY_ID" \ -f title="utPLSQL ${RELEASE_TAG} released" \ -f body="$BODY" \ --jq '.data.createDiscussion.discussion.url') - + echo "Announcement posted: $DISCUSSION_URL" \ No newline at end of file From 46de75c18f84b97613474ff2ff986eafb126dd2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:18:24 +0300 Subject: [PATCH 662/887] Testing Release process --- .github/workflows/test_publishing.yml | 78 +++++++++++++-------------- 1 file changed, 39 insertions(+), 39 deletions(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 1c5161871..5e20e5bf4 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -26,45 +26,45 @@ jobs: env-file: .github/variables/.env - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action - - name: Update CHANGELOG.md with release notes - env: - RELEASE_BODY: | - ## This is a test of a release publishing - * no new features added - * no changes - * just a release tag - * new announcement should be created - * changelog should be updated - - **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test - RELEASE_TAG: "v3.2.2-test" - RELEASE_DATE: "2026-06-04" - TARGET_BRANCH: "develop" - run: | - python3 - <<'PYEOF' - import os - - tag = os.environ['RELEASE_TAG'] - body = os.environ['RELEASE_BODY'].strip() - date = os.environ['RELEASE_DATE'][:10] - - new_section = f"## [{tag}] - {date}\n\n{body}\n\n---\n\n" - - with open('CHANGELOG.md', 'r') as f: - content = f.read() - - marker = '\n---\n' - pos = content.index(marker) + len(marker) - updated = content[:pos] + '\n' + new_section + content[pos:] - - with open('CHANGELOG.md', 'w') as f: - f.write(updated) - - print(f"Added {tag} to CHANGELOG.md") - PYEOF - git add CHANGELOG.md - git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" - git push origin HEAD:"${TARGET_BRANCH}" +# - name: Update CHANGELOG.md with release notes +# env: +# RELEASE_BODY: | +# ## This is a test of a release publishing +# * no new features added +# * no changes +# * just a release tag +# * new announcement should be created +# * changelog should be updated +# +# **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test +# RELEASE_TAG: "v3.2.2-test" +# RELEASE_DATE: "2026-06-04" +# TARGET_BRANCH: "develop" +# run: | +# python3 - <<'PYEOF' +# import os +# +# tag = os.environ['RELEASE_TAG'] +# body = os.environ['RELEASE_BODY'].strip() +# date = os.environ['RELEASE_DATE'][:10] +# +# new_section = f"## [{tag}] - {date}\n\n{body}\n\n---\n\n" +# +# with open('CHANGELOG.md', 'r') as f: +# content = f.read() +# +# marker = '\n---\n' +# pos = content.index(marker) + len(marker) +# updated = content[:pos] + '\n' + new_section + content[pos:] +# +# with open('CHANGELOG.md', 'w') as f: +# f.write(updated) +# +# print(f"Added {tag} to CHANGELOG.md") +# PYEOF +# git add CHANGELOG.md +# git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" +# git push origin HEAD:"${TARGET_BRANCH}" - name: Post release announcement to org discussions env: From 3af7303c25b2edfc583b8fbb3d710341ca10504c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:37:18 +0300 Subject: [PATCH 663/887] Testing announcement of release in discussions --- .github/workflows/test_publishing.yml | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 5e20e5bf4..c48a3576e 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -83,6 +83,14 @@ jobs: run: | ORG="utPLSQL" REPO_NAME=".github" + + # Get org ID + ORG_DATA=$(gh api graphql -f query='query($org: String!) { + organization(login: $org) { + id + } + }' -f org="$ORG") + ORG_ID=$(echo "$ORG_DATA" | jq -r '.data.organization.id') # Get repository ID REPO_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { @@ -90,17 +98,29 @@ jobs: id } }' -f owner="$ORG" -f name="$REPO_NAME") - REPO_ID=$(echo "$REPO_DATA" | jq -r '.data.repository.id') + + # Get category id + CATEGORY_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { + repository(owner: $owner, name: $name) { + discussionCategories(first: 20) { + nodes { id name } + } + } + }' -f owner="$ORG" -f name="$REPO_NAME") + + CATEGORY_ID=$(echo "$CATEGORY_DATA" | jq -r \ + '.data.repository.discussionCategories.nodes[] | select(.name == "Announcements") | .id') BODY="${RELEASE_BODY} --- [View full release on GitHub](${RELEASE_URL})" - DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $title: String!, $body: String!) { + DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $categoryId: ID!, $title: String!, $body: String!) { createDiscussion(input: { repositoryId: $repoId, + categoryId: $categoryId, title: $title, body: $body }) { @@ -108,6 +128,7 @@ jobs: } }' \ -f repoId="$REPO_ID" \ + -f categoryId="$CATEGORY_ID" \ -f title="utPLSQL ${RELEASE_TAG} released" \ -f body="$BODY" \ --jq '.data.createDiscussion.discussion.url') From b6cac60d3a41e075453c3c6cdaf7d7f6d1780b01 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:44:51 +0300 Subject: [PATCH 664/887] Testing announcement of release in discussions --- .github/workflows/test_publishing.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index c48a3576e..df8595e07 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -68,7 +68,7 @@ jobs: - name: Post release announcement to org discussions env: - GH_TOKEN: ${{ secrets.ORG_DISCUSSION_TOKEN }} + GH_TOKEN: ${{ secrets.API_TOKEN_GITHUB }} RELEASE_TAG: "v3.2.2-test" RELEASE_BODY: | ## This is a test of a release publishing From ec37a0a57a02205077fcf1558fae9e1315395b96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:48:34 +0300 Subject: [PATCH 665/887] Testing announcement of release in discussions --- .github/workflows/test_publishing.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index df8595e07..4f5859bc4 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -114,8 +114,7 @@ jobs: BODY="${RELEASE_BODY} - --- - [View full release on GitHub](${RELEASE_URL})" +
    This discussion was created from the release ${RELEASE_TAG}." DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $categoryId: ID!, $title: String!, $body: String!) { createDiscussion(input: { From 5019705017257bbee56f159d390201706960cc8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:50:14 +0300 Subject: [PATCH 666/887] Testing announcement of release in discussions --- .github/workflows/test_publishing.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 4f5859bc4..0e0b0a622 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -114,7 +114,7 @@ jobs: BODY="${RELEASE_BODY} -
    This discussion was created from the release ${RELEASE_TAG}." +
    This discussion was created from the release ${RELEASE_TAG}." DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $categoryId: ID!, $title: String!, $body: String!) { createDiscussion(input: { From 0c6f25d7dfeb0bfa66ffbecc2f6528a327effb6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:58:47 +0300 Subject: [PATCH 667/887] Update of release process to include update of changelog and publishing of release announcement on Org Discussion. --- .github/scripts/post_release_announcement.sh | 63 +++++++++ .github/scripts/update_changelog.sh | 36 +++++ .github/workflows/release.yml | 73 +--------- .github/workflows/test_publishing.yml | 135 ------------------- 4 files changed, 105 insertions(+), 202 deletions(-) create mode 100755 .github/scripts/post_release_announcement.sh create mode 100755 .github/scripts/update_changelog.sh delete mode 100644 .github/workflows/test_publishing.yml diff --git a/.github/scripts/post_release_announcement.sh b/.github/scripts/post_release_announcement.sh new file mode 100755 index 000000000..c74394505 --- /dev/null +++ b/.github/scripts/post_release_announcement.sh @@ -0,0 +1,63 @@ +#!/bin/bash +# Posts a release announcement to the utPLSQL org .github repository's +# Announcements discussion category. +# +# Required environment variables: +# GH_TOKEN - GitHub token with write:discussion scope (ORG_DISCUSSION_TOKEN) +# RELEASE_TAG - e.g. v3.2.3 +# RELEASE_BODY - markdown release notes +# RELEASE_URL - URL of the GitHub release page + +set -euo pipefail + +ORG="utPLSQL" +REPO_NAME=".github" + +# Get org node ID +ORG_DATA=$(gh api graphql -f query='query($org: String!) { + organization(login: $org) { + id + } +}' -f org="$ORG") +ORG_ID=$(echo "$ORG_DATA" | jq -r '.data.organization.id') + +# Get repository node ID +REPO_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { + repository(owner: $owner, name: $name) { + id + } +}' -f owner="$ORG" -f name="$REPO_NAME") +REPO_ID=$(echo "$REPO_DATA" | jq -r '.data.repository.id') + +# Get Announcements category ID +CATEGORY_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { + repository(owner: $owner, name: $name) { + discussionCategories(first: 20) { + nodes { id name } + } + } +}' -f owner="$ORG" -f name="$REPO_NAME") +CATEGORY_ID=$(echo "$CATEGORY_DATA" | jq -r \ + '.data.repository.discussionCategories.nodes[] | select(.name == "Announcements") | .id') + +BODY="${RELEASE_BODY} + +
    This discussion was created from the release ${RELEASE_TAG}." + +DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $categoryId: ID!, $title: String!, $body: String!) { + createDiscussion(input: { + repositoryId: $repoId, + categoryId: $categoryId, + title: $title, + body: $body + }) { + discussion { url } + } +}' \ + -f repoId="$REPO_ID" \ + -f categoryId="$CATEGORY_ID" \ + -f title="utPLSQL ${RELEASE_TAG} released" \ + -f body="$BODY" \ + --jq '.data.createDiscussion.discussion.url') + +echo "Announcement posted: $DISCUSSION_URL" diff --git a/.github/scripts/update_changelog.sh b/.github/scripts/update_changelog.sh new file mode 100755 index 000000000..011c08819 --- /dev/null +++ b/.github/scripts/update_changelog.sh @@ -0,0 +1,36 @@ +#!/bin/bash +# Updates CHANGELOG.md by prepending a new section for the release. +# +# Required environment variables: +# RELEASE_TAG - e.g. v3.2.3 +# RELEASE_BODY - markdown release notes +# RELEASE_DATE - ISO-8601 date string (only the first 10 chars are used) +# TARGET_BRANCH - branch to push the updated changelog to + +set -euo pipefail + +python3 - <<'PYEOF' +import os + +tag = os.environ['RELEASE_TAG'] +body = os.environ['RELEASE_BODY'].strip() +date = os.environ['RELEASE_DATE'][:10] + +new_section = f"## [{tag}] - {date}\n\n{body}\n\n---\n\n" + +with open('CHANGELOG.md', 'r') as f: + content = f.read() + +marker = '\n---\n' +pos = content.index(marker) + len(marker) +updated = content[:pos] + '\n' + new_section + content[pos:] + +with open('CHANGELOG.md', 'w') as f: + f.write(updated) + +print(f"Added {tag} to CHANGELOG.md") +PYEOF + +git add CHANGELOG.md +git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" +git push origin HEAD:"${TARGET_BRANCH}" diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3c490d18c..9e0cc6554 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -34,31 +34,7 @@ jobs: RELEASE_TAG: ${{ github.event.release.tag_name }} RELEASE_DATE: ${{ github.event.release.published_at }} TARGET_BRANCH: ${{ github.event.release.target_commitish }} - run: | - python3 - <<'PYEOF' - import os - - tag = os.environ['RELEASE_TAG'] - body = os.environ['RELEASE_BODY'].strip() - date = os.environ['RELEASE_DATE'][:10] - - new_section = f"## [{tag}] - {date}\n\n{body}\n\n---\n\n" - - with open('CHANGELOG.md', 'r') as f: - content = f.read() - - marker = '\n---\n' - pos = content.index(marker) + len(marker) - updated = content[:pos] + '\n' + new_section + content[pos:] - - with open('CHANGELOG.md', 'w') as f: - f.write(updated) - - print(f"Added {tag} to CHANGELOG.md") - PYEOF - git add CHANGELOG.md - git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" - git push origin HEAD:"${TARGET_BRANCH}" + run: .github/scripts/update_changelog.sh - name: Set build version number env variables run: .github/scripts/set_release_version_numbers_env.sh @@ -83,17 +59,17 @@ jobs: run: | git archive --prefix=utPLSQL/ -o utPLSQL.zip --format=zip HEAD git archive --prefix=utPLSQL/ -o utPLSQL.tar.gz --format=tar.gz HEAD - md5sum utPLSQL.zip --tag > utPLSQL.zip.md5 - md5sum utPLSQL.tar.gz --tag > utPLSQL.tar.gz.md5 + sha256sum utPLSQL.zip --tag > utPLSQL.zip.sha256 + sha256sum utPLSQL.tar.gz --tag > utPLSQL.tar.gz.sha256 - name: Release uses: softprops/action-gh-release@v1 with: files: | utPLSQL.zip - utPLSQL.zip.md5 + utPLSQL.zip.sha256 utPLSQL.tar.gz - utPLSQL.tar.gz.md5 + utPLSQL.tar.gz.sha256 - name: Post release announcement to org discussions env: @@ -101,42 +77,5 @@ jobs: RELEASE_TAG: ${{ github.event.release.tag_name }} RELEASE_BODY: ${{ github.event.release.body }} RELEASE_URL: ${{ github.event.release.html_url }} - run: | - ORG="utPLSQL" - - ORG_DATA=$(gh api graphql -f query='query($org: String!) { - organization(login: $org) { - id - discussionCategories(first: 20) { - nodes { id name } - } - } - }' -f org="$ORG") - - ORG_ID=$(echo "$ORG_DATA" | jq -r '.data.organization.id') - CATEGORY_ID=$(echo "$ORG_DATA" | jq -r \ - '.data.organization.discussionCategories.nodes[] | select(.name == "Announcements") | .id') - - BODY="${RELEASE_BODY} - - --- - [View full release on GitHub](${RELEASE_URL})" - - DISCUSSION_URL=$(gh api graphql -f query='mutation($orgId: ID!, $categoryId: ID!, $title: String!, $body: String!) { - createDiscussion(input: { - organizationId: $orgId, - categoryId: $categoryId, - title: $title, - body: $body - }) { - discussion { url } - } - }' \ - -f orgId="$ORG_ID" \ - -f categoryId="$CATEGORY_ID" \ - -f title="utPLSQL ${RELEASE_TAG} released" \ - -f body="$BODY" \ - --jq '.data.createDiscussion.discussion.url') - - echo "Announcement posted: $DISCUSSION_URL" + run: .github/scripts/post_release_announcement.sh diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml deleted file mode 100644 index 0e0b0a622..000000000 --- a/.github/workflows/test_publishing.yml +++ /dev/null @@ -1,135 +0,0 @@ -name: TEst publishing of release announcement -on: - workflow_dispatch: - -defaults: - run: - shell: bash - -jobs: - - upload_artifacts: - name: Upload archives - concurrency: upload - runs-on: ubuntu-latest - timeout-minutes: 60 - env: - API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} - - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - token: ${{ env.API_TOKEN_GITHUB }} - - uses: c-py/action-dotenv-to-setenv@v5 - with: - env-file: .github/variables/.env - - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action - -# - name: Update CHANGELOG.md with release notes -# env: -# RELEASE_BODY: | -# ## This is a test of a release publishing -# * no new features added -# * no changes -# * just a release tag -# * new announcement should be created -# * changelog should be updated -# -# **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test -# RELEASE_TAG: "v3.2.2-test" -# RELEASE_DATE: "2026-06-04" -# TARGET_BRANCH: "develop" -# run: | -# python3 - <<'PYEOF' -# import os -# -# tag = os.environ['RELEASE_TAG'] -# body = os.environ['RELEASE_BODY'].strip() -# date = os.environ['RELEASE_DATE'][:10] -# -# new_section = f"## [{tag}] - {date}\n\n{body}\n\n---\n\n" -# -# with open('CHANGELOG.md', 'r') as f: -# content = f.read() -# -# marker = '\n---\n' -# pos = content.index(marker) + len(marker) -# updated = content[:pos] + '\n' + new_section + content[pos:] -# -# with open('CHANGELOG.md', 'w') as f: -# f.write(updated) -# -# print(f"Added {tag} to CHANGELOG.md") -# PYEOF -# git add CHANGELOG.md -# git commit -m "Add release notes for ${RELEASE_TAG} to CHANGELOG.md [skip ci]" -# git push origin HEAD:"${TARGET_BRANCH}" - - - name: Post release announcement to org discussions - env: - GH_TOKEN: ${{ secrets.API_TOKEN_GITHUB }} - RELEASE_TAG: "v3.2.2-test" - RELEASE_BODY: | - ## This is a test of a release publishing - * no new features added - * no changes - * just a release tag - * new announcement should be created - * changelog should be updated - - **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test - RELEASE_URL: "https://github.com/utPLSQL/utPLSQL/releases/tag/v3.2.2" - run: | - ORG="utPLSQL" - REPO_NAME=".github" - - # Get org ID - ORG_DATA=$(gh api graphql -f query='query($org: String!) { - organization(login: $org) { - id - } - }' -f org="$ORG") - ORG_ID=$(echo "$ORG_DATA" | jq -r '.data.organization.id') - - # Get repository ID - REPO_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { - repository(owner: $owner, name: $name) { - id - } - }' -f owner="$ORG" -f name="$REPO_NAME") - REPO_ID=$(echo "$REPO_DATA" | jq -r '.data.repository.id') - - # Get category id - CATEGORY_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { - repository(owner: $owner, name: $name) { - discussionCategories(first: 20) { - nodes { id name } - } - } - }' -f owner="$ORG" -f name="$REPO_NAME") - - CATEGORY_ID=$(echo "$CATEGORY_DATA" | jq -r \ - '.data.repository.discussionCategories.nodes[] | select(.name == "Announcements") | .id') - - BODY="${RELEASE_BODY} - -
    This discussion was created from the release ${RELEASE_TAG}." - - DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $categoryId: ID!, $title: String!, $body: String!) { - createDiscussion(input: { - repositoryId: $repoId, - categoryId: $categoryId, - title: $title, - body: $body - }) { - discussion { url } - } - }' \ - -f repoId="$REPO_ID" \ - -f categoryId="$CATEGORY_ID" \ - -f title="utPLSQL ${RELEASE_TAG} released" \ - -f body="$BODY" \ - --jq '.data.createDiscussion.discussion.url') - - echo "Announcement posted: $DISCUSSION_URL" \ No newline at end of file From 96ae186da2a19759bc292c35b4fc5a076490a3ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 09:59:56 +0300 Subject: [PATCH 668/887] Cleanup of changelog updates. --- CHANGELOG.md | 42 ------------------------------------------ 1 file changed, 42 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9c17688f7..d304ab172 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,48 +5,6 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ --- -## [v3.2.2-test] - 2026-06-04 - -## This is a test of a release publishing - * no new features added - * no changes - * just a release tag - * new announcement should be created - * changelog should be updated - -**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test - ---- - - -## [v3.2.2-test] - 2026-06-04 - -## This is a test of a release publishing - * no new features added - * no changes - * just a release tag - * new announcement should be created - * changelog should be updated - -**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test - ---- - - -## [v3.2.2-test] - 2026-06-04 - -## This is a test of a release publishing - * no new features added - * no changes - * just a release tag - * new announcement should be created - * changelog should be updated - -**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test - ---- - - ## [v3.2.2] - 2026-05-24 ## What's Changed From 54b772b698d0c5a17033757ad7f442a223f775ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 14:44:49 +0300 Subject: [PATCH 669/887] Fix issue with `UT_TAP_REPORTER` on Oracle 23.26 Tap reporter does not add '#' on empty lines anymore. Resolves: #1358 --- source/reporters/ut_tap_reporter.tpb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 02246b97e..c591c19f8 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -25,7 +25,7 @@ create or replace type body ut_tap_reporter is member procedure print_comment(self in out nocopy ut_tap_reporter, a_comment clob) as begin - self.print_clob(regexp_replace(a_comment, '^', '# ', 1, 0, 'm')); + self.print_clob(regexp_replace(a_comment, '^(.+)', '# \1', 1, 0, 'm')); end print_comment; member function escape_special_chars(self in out nocopy ut_tap_reporter, a_string_to_escape clob) return clob as From 4588df4035c085b9073b590e0dc818e8dfb9950c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 16:13:23 +0300 Subject: [PATCH 670/887] Testing publishing of release announcement post --- .github/scripts/publish_release_post.sh | 63 +++++++++++++++++++++++++ .github/workflows/release.yml | 18 +++---- .github/workflows/test_publishing.yml | 52 ++++++++++++++++++++ development/releasing.md | 27 +++++------ 4 files changed, 136 insertions(+), 24 deletions(-) create mode 100644 .github/scripts/publish_release_post.sh create mode 100644 .github/workflows/test_publishing.yml diff --git a/.github/scripts/publish_release_post.sh b/.github/scripts/publish_release_post.sh new file mode 100644 index 000000000..3e4539f4a --- /dev/null +++ b/.github/scripts/publish_release_post.sh @@ -0,0 +1,63 @@ +#!/bin/bash +# Publishes a release announcement post to utplsql.github.io. +# Creates the post file, prepends an entry to docs/index.md, +# and inserts the post into the mkdocs.yml nav. +# +# Required environment variables: +# API_TOKEN_GITHUB - GitHub token with write access to utPLSQL.github.io +# RELEASE_TAG - e.g. v3.2.01 +# RELEASE_BODY - markdown release notes (from github.event.release.body) +# RELEASE_DATE - ISO-8601 publish timestamp (from github.event.release.published_at) + +set -euo pipefail + +GITHUB_IO_REPO="utPLSQL/utPLSQL.github.io" +GITHUB_IO_BRANCH="main" + +VERSION="${RELEASE_TAG#v}" +POST_DATE=$(echo "${RELEASE_DATE}" | cut -c1-10) +POST_TIME=$(echo "${RELEASE_DATE}" | sed 's/T/ /' | sed 's/Z/ +0000/') +POST_FILENAME="${POST_DATE}-version${VERSION}-released.md" +POST_TITLE="utPLSQL ${RELEASE_TAG} released" +POST_NAV_TITLE="utPLSQL ${VERSION} released" + +mkdir -p github_io +cd github_io +git clone --depth 1 "https://${API_TOKEN_GITHUB}@github.com/${GITHUB_IO_REPO}" -b "${GITHUB_IO_BRANCH}" . + +# Create the post file +cat > "docs/_posts/${POST_FILENAME}" < /tmp/index_new.md +mv /tmp/index_new.md docs/index.md + +# Insert new post into mkdocs.yml nav immediately after "- index.md" +sed -i "s| - index.md| - index.md\n - ${POST_NAV_TITLE}: _posts/${POST_FILENAME}|" mkdocs.yml + +git add "docs/_posts/${POST_FILENAME}" docs/index.md mkdocs.yml +git commit -m "Release announcement for ${RELEASE_TAG}" +git push origin "${GITHUB_IO_BRANCH}" + +echo "Release post published: docs/_posts/${POST_FILENAME}" diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9e0cc6554..c4c76222c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -17,6 +17,11 @@ jobs: timeout-minutes: 60 env: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} + RELEASE_TAG: ${{ github.event.release.tag_name }} + RELEASE_BODY: ${{ github.event.release.body }} + RELEASE_DATE: ${{ github.event.release.published_at }} + RELEASE_URL: ${{ github.event.release.html_url }} + TARGET_BRANCH: ${{ github.event.release.target_commitish }} steps: - uses: actions/checkout@v4 @@ -29,11 +34,6 @@ jobs: - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action - name: Update CHANGELOG.md with release notes - env: - RELEASE_BODY: ${{ github.event.release.body }} - RELEASE_TAG: ${{ github.event.release.tag_name }} - RELEASE_DATE: ${{ github.event.release.published_at }} - TARGET_BRANCH: ${{ github.event.release.target_commitish }} run: .github/scripts/update_changelog.sh - name: Set build version number env variables @@ -73,9 +73,9 @@ jobs: - name: Post release announcement to org discussions env: - GH_TOKEN: ${{ secrets.ORG_DISCUSSION_TOKEN }} - RELEASE_TAG: ${{ github.event.release.tag_name }} - RELEASE_BODY: ${{ github.event.release.body }} - RELEASE_URL: ${{ github.event.release.html_url }} + GH_TOKEN: ${{ secrets.GITHUB_API_TOKEN }} run: .github/scripts/post_release_announcement.sh + - name: Publish release post to utplsql.github.io + run: .github/scripts/publish_release_post.sh + diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml new file mode 100644 index 000000000..bebd2f172 --- /dev/null +++ b/.github/workflows/test_publishing.yml @@ -0,0 +1,52 @@ +name: Test publishing +on: + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + + upload_artifacts: + name: Upload archives + concurrency: upload + runs-on: ubuntu-latest + timeout-minutes: 60 + env: + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} + RELEASE_TAG: "v3.2.2-test" + RELEASE_BODY: | + ## This is a test of a release publishing + * no new features added + * no changes + * just a release tag + * new announcement should be created + * changelog should be updated + + **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test + RELEASE_DATE: "2026-06-04" + RELEASE_URL: "https://github.com/utPLSQL/utPLSQL/releases/tag/v3.2.2" + TARGET_BRANCH: "develop" + + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + token: ${{ env.API_TOKEN_GITHUB }} + - uses: c-py/action-dotenv-to-setenv@v5 + with: + env-file: .github/variables/.env + - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action + +# - name: Update CHANGELOG.md with release notes +# run: .github/scripts/update_changelog.sh + + - name: Post release announcement to org discussions + env: + GH_TOKEN: ${{ secrets.GITHUB_API_TOKEN }} + run: .github/scripts/post_release_announcement.sh + + - name: Publish release post to utplsql.github.io + run: .github/scripts/publish_release_post.sh + diff --git a/development/releasing.md b/development/releasing.md index ac2091632..99c3f7114 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -1,6 +1,6 @@ -## Release process +# Release process -To create a release follow the below steps +To create a release, follow the below steps. ## Release preparation - Create a **draft** of a Release with a new tag number `vX.Y.X` sourced from the `develop` branch on [github releases page](https://github.com/utPLSQL/utPLSQL/releases) @@ -10,19 +10,16 @@ To create a release follow the below steps ## Performing a release - Publish [the previously prepared](#release-preparation) release draft. - - Wait for the [Github Actions `Release`](https://github.com/utPLSQL/utPLSQL/actions/workflows/release.yml) process to complete successfully. The process will upload release artifacts (`zip` and `tar.gz` files along with `md5`) - - After Release build was completed successfully, merge the `develop` branch into `main` branch. At this point, main branch and release tag should be at the same commit version and artifacts should be uploaded into Github release. - - Increase the version number in the `VERSION` file on `develop` branch to open start next release version. - - Clone `utplsql.githug.io` project and: - - Add a new announcement about next version being released in `docs/_posts`. Use previous announcements as a template. Make sure to set date, time and post title properly. - - Add the post to list in `mkdocs.yml` file in root directory of that repository. - - Add the link to the post at the beginning of the `docs/index.md` file. - - Send the announcement on Twitter(X) accoiunt abut utPLSQL release. - -The following will happen: - - When a Github release is published, a new tag is added in on the repository and a release build is executed - - With Release action, the documentation for new release is published on `utplsql.github.io` and installation archives are added to the release. + - Wait for the [Github Actions `Release`](https://github.com/utPLSQL/utPLSQL/actions/workflows/release.yml) process to complete successfully. The process will do the following: + - create a new tag + - generate html documentation to be included in the release file. + - publish documentation for the new version into utPLSQL site + - upload release artifacts (`zip` and `tar.gz` files along with `sha256` files) + - update the CHANGELOG.md file with the release details + - publish an announcement about the release in the utPLSQL Organization Discussions + - publish a release post on utplsql.github.io (new post in `docs/_posts`, updated `mkdocs.yml` nav and `docs/index.md`) + - After the release process is finished, manually increase the version number in the `VERSION` file on `develop` branch to start the next release version. + - Send an announcement about the release on:Twitter(X), BlueSky, LinkedIn account about the utPLSQL release. # Note: -The utPLSQL installation files are uploaded by the release build process as release artifacts (separate `zip` and `tar.gz` files). The release artifacts include HTML documentation generated from MD files, sources and tests From e3d45742abc00b9b77b7013ed74f55055facbf79 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 16:22:01 +0300 Subject: [PATCH 671/887] Testing publishing of release announcement post --- .github/workflows/test_publishing.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index bebd2f172..1f6cd6809 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -44,7 +44,7 @@ jobs: - name: Post release announcement to org discussions env: - GH_TOKEN: ${{ secrets.GITHUB_API_TOKEN }} + GH_TOKEN: ${{ secrets.API_TOKEN_GITHUB }} run: .github/scripts/post_release_announcement.sh - name: Publish release post to utplsql.github.io From f4cb121fd8cd1859b1a7971f13c586790ff5c3b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 16:27:18 +0300 Subject: [PATCH 672/887] Testing publishing of release announcement post --- .github/workflows/test_publishing.yml | 28 +++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 1f6cd6809..405a428f9 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -15,17 +15,17 @@ jobs: timeout-minutes: 60 env: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} - RELEASE_TAG: "v3.2.2-test" + RELEASE_TAG: "v3.2.2" RELEASE_BODY: | - ## This is a test of a release publishing - * no new features added - * no changes - * just a release tag - * new announcement should be created - * changelog should be updated - - **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v3.2.2-test - RELEASE_DATE: "2026-06-04" + ## What's Changed + * Filtering by tags fixed for schemas containing suite-paths and contexts by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1325 + * Fixed issue with reporter failing to initialize by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1354 + * Fixed issue with duplicate sources from dba_source by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1355 + * Allow HTML coverage on FIPS-enabled DB by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1356 + + + **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.01...v3.2.2 + RELEASE_DATE: "2026-05-24 10:48:22" RELEASE_URL: "https://github.com/utPLSQL/utPLSQL/releases/tag/v3.2.2" TARGET_BRANCH: "develop" @@ -42,10 +42,10 @@ jobs: # - name: Update CHANGELOG.md with release notes # run: .github/scripts/update_changelog.sh - - name: Post release announcement to org discussions - env: - GH_TOKEN: ${{ secrets.API_TOKEN_GITHUB }} - run: .github/scripts/post_release_announcement.sh +# - name: Post release announcement to org discussions +# env: +# GH_TOKEN: ${{ secrets.API_TOKEN_GITHUB }} +# run: .github/scripts/post_release_announcement.sh - name: Publish release post to utplsql.github.io run: .github/scripts/publish_release_post.sh From cd44e88b9d43a14f604d3ae851006598216ebfaf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 16:28:24 +0300 Subject: [PATCH 673/887] Testing publishing of release announcement post --- .github/scripts/publish_release_post.sh | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 .github/scripts/publish_release_post.sh diff --git a/.github/scripts/publish_release_post.sh b/.github/scripts/publish_release_post.sh old mode 100644 new mode 100755 From 41f887d8f439294dad7f206067710807416b5ee6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 16:36:33 +0300 Subject: [PATCH 674/887] Update of publishing of release announcement post --- .github/scripts/publish_release_post.sh | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/scripts/publish_release_post.sh b/.github/scripts/publish_release_post.sh index 3e4539f4a..53faf1ce2 100755 --- a/.github/scripts/publish_release_post.sh +++ b/.github/scripts/publish_release_post.sh @@ -25,6 +25,17 @@ mkdir -p github_io cd github_io git clone --depth 1 "https://${API_TOKEN_GITHUB}@github.com/${GITHUB_IO_REPO}" -b "${GITHUB_IO_BRANCH}" . +# Format the release body for the post: +# 1. Convert bare GitHub issue/PR URLs to [#NUMBER](URL) +# e.g. https://github.com/utPLSQL/utPLSQL/pull/1320 +# -> [#1320](https://github.com/utPLSQL/utPLSQL/pull/1320) +# 2. Convert the auto-generated "Full Changelog" bare URL to a labelled link +# e.g. **Full Changelog**: https://.../compare/v3.2.01...v3.2.2 +# -> **Full Changelog**: [v3.2.01...v3.2.2](https://.../compare/v3.2.01...v3.2.2) +FORMATTED_BODY=$(echo "${RELEASE_BODY}" \ + | sed -E 's|https://github\.com/([^/]+)/([^/]+)/(pull|issues)/([0-9]+)|[#\4](https://github.com/\1/\2/\3/\4)|g' \ + | sed -E 's|\*\*Full Changelog\*\*: (https://[^ ]+/compare/([^ ]+))|\*\*Full Changelog\*\*: [\2](\1)|g') + # Create the post file cat > "docs/_posts/${POST_FILENAME}" < Date: Thu, 4 Jun 2026 14:45:05 +0100 Subject: [PATCH 675/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index dd37b7287..4d3b908c9 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4414 +4445 diff --git a/docs/about/authors.md b/docs/about/authors.md index 687c6cfaa..050d0f379 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 6567b5db7..a75165ec2 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index df666731f..099e8ec49 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index f27ee0c1e..9c7fc6960 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 6ae326c1c..22874c15b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 76d90bc30..d24d2c7b9 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index fd51fec8f..d0fa59ac2 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index c9f08eab5..76519cc43 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 03cb8bfd3..30e37aa15 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 1e892215d..57c8b02a5 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c51e6c99c..c6b1cf9d0 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index a722f8ac7..31410af07 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 615883720..fde4541f4 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 167fba1b4..f404292d8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 807fa537f..9eabac070 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 606a5ef97..1cc34b62e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index a49118fbd..85172bd58 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4414--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 092c25583..0ec316d07 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4414-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4445-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 7469ede71858e83ab3f6941188985ba0a276d616 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 4 Jun 2026 16:46:15 +0300 Subject: [PATCH 676/887] Update of publishing of release announcement post --- .github/scripts/publish_release_post.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/scripts/publish_release_post.sh b/.github/scripts/publish_release_post.sh index 53faf1ce2..89438738c 100755 --- a/.github/scripts/publish_release_post.sh +++ b/.github/scripts/publish_release_post.sh @@ -33,8 +33,8 @@ git clone --depth 1 "https://${API_TOKEN_GITHUB}@github.com/${GITHUB_IO_REPO}" - # e.g. **Full Changelog**: https://.../compare/v3.2.01...v3.2.2 # -> **Full Changelog**: [v3.2.01...v3.2.2](https://.../compare/v3.2.01...v3.2.2) FORMATTED_BODY=$(echo "${RELEASE_BODY}" \ - | sed -E 's|https://github\.com/([^/]+)/([^/]+)/(pull|issues)/([0-9]+)|[#\4](https://github.com/\1/\2/\3/\4)|g' \ - | sed -E 's|\*\*Full Changelog\*\*: (https://[^ ]+/compare/([^ ]+))|\*\*Full Changelog\*\*: [\2](\1)|g') + | sed -E 's@https://github\.com/([^/]+)/([^/]+)/(pull|issues)/([0-9]+)@[#\4](https://github.com/\1/\2/\3/\4)@g' \ + | sed -E 's@\*\*Full Changelog\*\*: (https://[^ ]+/compare/([^ ]+))@\*\*Full Changelog\*\*: [\2](\1)@g') # Create the post file cat > "docs/_posts/${POST_FILENAME}" < Date: Thu, 4 Jun 2026 16:50:45 +0300 Subject: [PATCH 677/887] Disable the test workflow --- .github/workflows/test_publishing.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 405a428f9..0aac3805b 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -47,6 +47,6 @@ jobs: # GH_TOKEN: ${{ secrets.API_TOKEN_GITHUB }} # run: .github/scripts/post_release_announcement.sh - - name: Publish release post to utplsql.github.io - run: .github/scripts/publish_release_post.sh +# - name: Publish release post to utplsql.github.io +# run: .github/scripts/publish_release_post.sh From 6e2d8743ba485da6fb9906650100cfd8545663bd Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 4 Jun 2026 14:58:27 +0100 Subject: [PATCH 678/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4d3b908c9..17151eb01 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4445 +4447 diff --git a/docs/about/authors.md b/docs/about/authors.md index 050d0f379..812b0c6c1 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index a75165ec2..76f712192 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 099e8ec49..bb6dd6380 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 9c7fc6960..576fbf445 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 22874c15b..2307868ba 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index d24d2c7b9..010ceb7d2 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index d0fa59ac2..af36ac0ae 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 76519cc43..f9b363977 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 30e37aa15..329528134 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 57c8b02a5..67a15719b 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c6b1cf9d0..99a4958d6 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 31410af07..446571936 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index fde4541f4..48513cbb6 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index f404292d8..a6c8d37b4 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 9eabac070..3752137cd 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 1cc34b62e..f5efb4298 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 85172bd58..4ca5ec270 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4445--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 0ec316d07..7cffd26e8 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4445-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4447-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 674bfbe3f86c90a5d267ae676ba2c9bfdb0dcfa5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 7 Jun 2026 12:00:32 +0300 Subject: [PATCH 679/887] Fixed support for camelCase in context `--%name` annotation. Resolves: #1317 --- source/core/ut_suite_builder.pkb | 2 +- test/ut3_tester/core/test_suite_builder.pkb | 48 +++++++++++++++++++++ test/ut3_tester/core/test_suite_builder.pks | 5 ++- 3 files changed, 53 insertions(+), 2 deletions(-) diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 2ebdb980c..c403c29d8 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -754,7 +754,7 @@ create or replace package body ut_suite_builder is l_used_context_names(l_context_name) := true; l_context := ut_suite_context(a_parent.object_owner, a_parent.object_name, l_context_name, l_context_pos ); - l_context.path := a_parent.path||'.'||l_context_name; + l_context.path := a_parent.path||'.'||l_context.name; l_context.description := coalesce( a_annotations.by_line( l_context_pos ).text, l_context_name ); l_context.parse_time := a_annotations.parse_time; diff --git a/test/ut3_tester/core/test_suite_builder.pkb b/test/ut3_tester/core/test_suite_builder.pkb index 570d86a0d..9a86772c7 100644 --- a/test/ut3_tester/core/test_suite_builder.pkb +++ b/test/ut3_tester/core/test_suite_builder.pkb @@ -1370,6 +1370,54 @@ create or replace package body test_suite_builder is ); end; + procedure context_name_case_insensitive is + l_actual clob; + l_annotations ut3_develop.ut_annotations; + begin + --Arrange + l_annotations := ut3_develop.ut_annotations( + ut3_develop.ut_annotation(1, 'suite','Cool', null), + ut3_develop.ut_annotation(2, 'beforeall',null, 'suite_level_beforeall'), + ut3_develop.ut_annotation(3, 'test','In suite', 'suite_level_test'), + ut3_develop.ut_annotation(4, 'context','A context', null), + ut3_develop.ut_annotation(5, 'name','a_Context', null), + ut3_develop.ut_annotation(6, 'beforeall',null, 'context_setup'), + ut3_develop.ut_annotation(7, 'test', 'In context', 'test_in_a_context'), + ut3_develop.ut_annotation(8, 'endcontext',null, null) + ); + --Act + l_actual := invoke_builder_for_annotations(l_annotations, 'SOME_PACKAGE'); + --Assert + ut.expect(l_actual).to_be_like( + ''|| + '' || + '%' || + '%' || + '' || + '%suite_level_testIn suitesome_package.suite_level_test' || + '%' || + '' || + '%a_contextA contextsome_package.a_context' || + '%' || + '' || + '%test_in_a_contextIn contextsome_package.a_context.test_in_a_context' || + '%' || + '' || + '' || + '%some_packagecontext_setup' || + '%' || + '' || + '' || + '' || + '' || + '%some_packagesuite_level_beforeall' || + '%' || + '' || + ''|| + '' + ); + end; + procedure throws_value_empty is l_actual clob; l_annotations ut3_develop.ut_annotations; diff --git a/test/ut3_tester/core/test_suite_builder.pks b/test/ut3_tester/core/test_suite_builder.pks index 4cbfcad74..09ff3c0b3 100644 --- a/test/ut3_tester/core/test_suite_builder.pks +++ b/test/ut3_tester/core/test_suite_builder.pks @@ -142,7 +142,7 @@ create or replace package test_suite_builder is --%test(Falls back to default context name and gives warning when name contains spaces) procedure name_with_spaces_invalid; - --%test(Raises warning when more than one name annotation used ) + --%test(Raises warning when more than one name annotation used) procedure duplicate_name_annotation; --%test(Is ignored when used outside of context - no warning given) @@ -154,6 +154,9 @@ create or replace package test_suite_builder is --%test(Is applied to corresponding context when multiple contexts used) procedure multiple_contexts; + --%test(Context name is case insensitive) + procedure context_name_case_insensitive; + --%endcontext --%context(--%throws annotation) From f3bfcae13396db4840acf951230586dcbed41321 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 7 Jun 2026 12:33:55 +0300 Subject: [PATCH 680/887] utPLSQL can be installed in editioned schema. All utPLSQL objects are now explicitly defined as non-editionable. The framework can be installed into editioned schema without issues. Resolves: #1161 --- .github/scripts/create_test_users.sh | 6 ++++++ .github/scripts/install.sh | 10 ++++++++++ source/api/ut.pkb | 2 +- source/api/ut.pks | 2 +- source/api/ut_runner.pkb | 2 +- source/api/ut_runner.pks | 2 +- source/api/ut_suite_item_info.tpb | 2 +- source/api/ut_suite_item_info.tps | 2 +- source/api/ut_suite_items_info.tps | 2 +- source/core/annotations/ut_annotated_object.tps | 2 +- source/core/annotations/ut_annotated_objects.tps | 2 +- source/core/annotations/ut_annotation.tps | 2 +- .../core/annotations/ut_annotation_cache_manager.pkb | 2 +- .../core/annotations/ut_annotation_cache_manager.pks | 2 +- source/core/annotations/ut_annotation_manager.pkb | 2 +- source/core/annotations/ut_annotation_manager.pks | 2 +- .../core/annotations/ut_annotation_obj_cache_info.tps | 2 +- .../core/annotations/ut_annotation_objs_cache_info.tps | 2 +- source/core/annotations/ut_annotation_parser.pkb | 2 +- source/core/annotations/ut_annotation_parser.pks | 2 +- source/core/annotations/ut_annotations.tps | 2 +- source/core/annotations/ut_trigger_check.pkb | 2 +- source/core/annotations/ut_trigger_check.pks | 2 +- source/core/coverage/ut_coverage.pkb | 2 +- source/core/coverage/ut_coverage.pks | 2 +- source/core/coverage/ut_coverage_block.pkb | 2 +- source/core/coverage/ut_coverage_block.pks | 2 +- source/core/coverage/ut_coverage_helper.pkb | 2 +- source/core/coverage/ut_coverage_helper.pks | 2 +- source/core/coverage/ut_coverage_helper_block.pkb | 2 +- source/core/coverage/ut_coverage_helper_block.pks | 2 +- source/core/coverage/ut_coverage_helper_profiler.pkb | 2 +- source/core/coverage/ut_coverage_helper_profiler.pks | 2 +- source/core/coverage/ut_coverage_profiler.pkb | 2 +- source/core/coverage/ut_coverage_profiler.pks | 2 +- source/core/coverage/ut_coverage_reporter_base.tpb | 2 +- source/core/coverage/ut_coverage_reporter_base.tps | 2 +- source/core/events/ut_event_item.tps | 2 +- source/core/events/ut_event_listener.tps | 2 +- source/core/events/ut_event_manager.pkb | 2 +- source/core/events/ut_event_manager.pks | 2 +- source/core/output_buffers/ut_output_buffer_base.tpb | 2 +- source/core/output_buffers/ut_output_buffer_base.tps | 2 +- source/core/output_buffers/ut_output_bulk_buffer.tpb | 2 +- source/core/output_buffers/ut_output_bulk_buffer.tps | 2 +- .../output_buffers/ut_output_clob_table_buffer.tpb | 2 +- .../output_buffers/ut_output_clob_table_buffer.tps | 2 +- source/core/output_buffers/ut_output_data_row.tps | 2 +- source/core/output_buffers/ut_output_data_rows.tps | 2 +- source/core/output_buffers/ut_output_table_buffer.tpb | 2 +- source/core/output_buffers/ut_output_table_buffer.tps | 2 +- source/core/session_context/ut_session_context.pkb | 2 +- source/core/session_context/ut_session_context.pks | 2 +- source/core/session_context/ut_session_info.tpb | 2 +- source/core/session_context/ut_session_info.tps | 2 +- source/core/types/ut_console_reporter_base.tpb | 2 +- source/core/types/ut_console_reporter_base.tps | 2 +- source/core/types/ut_coverage_options.tpb | 2 +- source/core/types/ut_coverage_options.tps | 2 +- source/core/types/ut_executable.tpb | 2 +- source/core/types/ut_executable.tps | 2 +- source/core/types/ut_executable_test.tpb | 2 +- source/core/types/ut_executable_test.tps | 2 +- source/core/types/ut_executables.tps | 2 +- source/core/types/ut_expectation_result.tpb | 2 +- source/core/types/ut_expectation_result.tps | 2 +- source/core/types/ut_expectation_results.tps | 2 +- source/core/types/ut_file_mapping.tpb | 2 +- source/core/types/ut_file_mapping.tps | 2 +- source/core/types/ut_file_mappings.tps | 2 +- source/core/types/ut_integer_list.tps | 2 +- source/core/types/ut_key_value_pair.tps | 2 +- source/core/types/ut_key_value_pairs.tps | 2 +- source/core/types/ut_logical_suite.tpb | 2 +- source/core/types/ut_logical_suite.tps | 2 +- source/core/types/ut_object_name.tpb | 2 +- source/core/types/ut_object_name.tps | 2 +- source/core/types/ut_object_names.tps | 2 +- source/core/types/ut_output_reporter_base.tpb | 2 +- source/core/types/ut_output_reporter_base.tps | 2 +- source/core/types/ut_path_item.tpb | 2 +- source/core/types/ut_path_item.tps | 2 +- source/core/types/ut_path_items.tps | 2 +- source/core/types/ut_reporter_base.tpb | 2 +- source/core/types/ut_reporter_base.tps | 2 +- source/core/types/ut_reporter_info.tps | 2 +- source/core/types/ut_reporters.tps | 2 +- source/core/types/ut_reporters_info.tps | 2 +- source/core/types/ut_results_counter.tpb | 2 +- source/core/types/ut_results_counter.tps | 2 +- source/core/types/ut_run.tpb | 2 +- source/core/types/ut_run.tps | 2 +- source/core/types/ut_run_info.tpb | 2 +- source/core/types/ut_run_info.tps | 2 +- source/core/types/ut_stack.tpb | 2 +- source/core/types/ut_stack.tps | 2 +- source/core/types/ut_suite.tpb | 2 +- source/core/types/ut_suite.tps | 2 +- source/core/types/ut_suite_cache_row.tps | 2 +- source/core/types/ut_suite_cache_rows.tps | 2 +- source/core/types/ut_suite_context.tpb | 2 +- source/core/types/ut_suite_context.tps | 2 +- source/core/types/ut_suite_item.tpb | 2 +- source/core/types/ut_suite_item.tps | 2 +- source/core/types/ut_suite_items.tps | 2 +- source/core/types/ut_test.tpb | 2 +- source/core/types/ut_test.tps | 2 +- source/core/types/ut_varchar2_list.tps | 2 +- source/core/types/ut_varchar2_rows.tps | 2 +- source/core/ut_expectation_processor.pkb | 2 +- source/core/ut_expectation_processor.pks | 2 +- source/core/ut_file_mapper.pkb | 2 +- source/core/ut_file_mapper.pks | 2 +- source/core/ut_metadata.pkb | 2 +- source/core/ut_metadata.pks | 2 +- source/core/ut_suite_builder.pkb | 2 +- source/core/ut_suite_builder.pks | 2 +- source/core/ut_suite_cache_manager.pkb | 2 +- source/core/ut_suite_cache_manager.pks | 2 +- source/core/ut_suite_manager.pkb | 2 +- source/core/ut_suite_manager.pks | 2 +- source/core/ut_suite_tag_filter.pkb | 2 +- source/core/ut_suite_tag_filter.pks | 2 +- source/core/ut_utils.pkb | 2 +- source/core/ut_utils.pks | 2 +- .../data_values/ut_compound_data_helper.pkb | 2 +- .../data_values/ut_compound_data_helper.pks | 2 +- .../data_values/ut_compound_data_value.tpb | 2 +- .../data_values/ut_compound_data_value.tps | 2 +- source/expectations/data_values/ut_cursor_column.tpb | 2 +- source/expectations/data_values/ut_cursor_column.tps | 2 +- .../expectations/data_values/ut_cursor_column_tab.tps | 2 +- source/expectations/data_values/ut_cursor_details.tpb | 2 +- source/expectations/data_values/ut_cursor_details.tps | 2 +- source/expectations/data_values/ut_data_value.tpb | 2 +- source/expectations/data_values/ut_data_value.tps | 2 +- .../expectations/data_values/ut_data_value_anydata.tpb | 2 +- .../expectations/data_values/ut_data_value_anydata.tps | 2 +- source/expectations/data_values/ut_data_value_blob.tpb | 2 +- source/expectations/data_values/ut_data_value_blob.tps | 2 +- .../expectations/data_values/ut_data_value_boolean.tpb | 2 +- .../expectations/data_values/ut_data_value_boolean.tps | 2 +- source/expectations/data_values/ut_data_value_clob.tpb | 2 +- source/expectations/data_values/ut_data_value_clob.tps | 2 +- source/expectations/data_values/ut_data_value_date.tpb | 2 +- source/expectations/data_values/ut_data_value_date.tps | 2 +- .../data_values/ut_data_value_dsinterval.tpb | 2 +- .../data_values/ut_data_value_dsinterval.tps | 2 +- source/expectations/data_values/ut_data_value_json.tpb | 2 +- source/expectations/data_values/ut_data_value_json.tps | 2 +- .../expectations/data_values/ut_data_value_number.tpb | 2 +- .../expectations/data_values/ut_data_value_number.tps | 2 +- .../data_values/ut_data_value_refcursor.tpb | 2 +- .../data_values/ut_data_value_refcursor.tps | 2 +- .../data_values/ut_data_value_timestamp.tpb | 2 +- .../data_values/ut_data_value_timestamp.tps | 2 +- .../data_values/ut_data_value_timestamp_ltz.tpb | 2 +- .../data_values/ut_data_value_timestamp_ltz.tps | 2 +- .../data_values/ut_data_value_timestamp_tz.tpb | 2 +- .../data_values/ut_data_value_timestamp_tz.tps | 2 +- .../data_values/ut_data_value_varchar2.tpb | 2 +- .../data_values/ut_data_value_varchar2.tps | 2 +- .../expectations/data_values/ut_data_value_xmltype.tpb | 2 +- .../expectations/data_values/ut_data_value_xmltype.tps | 2 +- .../data_values/ut_data_value_yminterval.tpb | 2 +- .../data_values/ut_data_value_yminterval.tps | 2 +- source/expectations/data_values/ut_json_leaf.tpb | 2 +- source/expectations/data_values/ut_json_leaf.tps | 2 +- source/expectations/data_values/ut_json_leaf_tab.tps | 2 +- .../expectations/data_values/ut_json_tree_details.tpb | 2 +- .../expectations/data_values/ut_json_tree_details.tps | 2 +- source/expectations/data_values/ut_key_anyval_pair.tps | 2 +- .../expectations/data_values/ut_key_anyval_pairs.tps | 2 +- source/expectations/data_values/ut_key_anyvalues.tpb | 2 +- source/expectations/data_values/ut_key_anyvalues.tps | 2 +- source/expectations/json_objects_specs.sql | 10 +++++----- source/expectations/matchers/ut_be_between.tpb | 2 +- source/expectations/matchers/ut_be_between.tps | 2 +- source/expectations/matchers/ut_be_empty.tpb | 2 +- source/expectations/matchers/ut_be_empty.tps | 2 +- source/expectations/matchers/ut_be_false.tpb | 2 +- source/expectations/matchers/ut_be_false.tps | 2 +- .../expectations/matchers/ut_be_greater_or_equal.tpb | 2 +- .../expectations/matchers/ut_be_greater_or_equal.tps | 2 +- source/expectations/matchers/ut_be_greater_than.tpb | 2 +- source/expectations/matchers/ut_be_greater_than.tps | 2 +- source/expectations/matchers/ut_be_less_or_equal.tpb | 2 +- source/expectations/matchers/ut_be_less_or_equal.tps | 2 +- source/expectations/matchers/ut_be_less_than.tpb | 2 +- source/expectations/matchers/ut_be_less_than.tps | 2 +- source/expectations/matchers/ut_be_like.tpb | 2 +- source/expectations/matchers/ut_be_like.tps | 2 +- source/expectations/matchers/ut_be_not_null.tpb | 2 +- source/expectations/matchers/ut_be_not_null.tps | 2 +- source/expectations/matchers/ut_be_null.tpb | 2 +- source/expectations/matchers/ut_be_null.tps | 2 +- source/expectations/matchers/ut_be_true.tpb | 2 +- source/expectations/matchers/ut_be_true.tps | 2 +- source/expectations/matchers/ut_be_within.tpb | 2 +- source/expectations/matchers/ut_be_within.tps | 2 +- source/expectations/matchers/ut_be_within_helper.pkb | 2 +- source/expectations/matchers/ut_be_within_helper.pks | 2 +- source/expectations/matchers/ut_be_within_pct.tpb | 2 +- source/expectations/matchers/ut_be_within_pct.tps | 2 +- source/expectations/matchers/ut_comparison_matcher.tpb | 2 +- source/expectations/matchers/ut_comparison_matcher.tps | 2 +- source/expectations/matchers/ut_contain.tpb | 2 +- source/expectations/matchers/ut_contain.tps | 2 +- source/expectations/matchers/ut_equal.tpb | 2 +- source/expectations/matchers/ut_equal.tps | 2 +- source/expectations/matchers/ut_have_count.tpb | 2 +- source/expectations/matchers/ut_have_count.tps | 2 +- source/expectations/matchers/ut_match.tpb | 2 +- source/expectations/matchers/ut_match.tps | 2 +- source/expectations/matchers/ut_matcher.tpb | 2 +- source/expectations/matchers/ut_matcher.tps | 2 +- source/expectations/matchers/ut_matcher_base.tps | 2 +- source/expectations/matchers/ut_matcher_options.tpb | 2 +- source/expectations/matchers/ut_matcher_options.tps | 2 +- .../expectations/matchers/ut_matcher_options_items.tpb | 2 +- .../expectations/matchers/ut_matcher_options_items.tps | 2 +- source/expectations/ut_expectation.tpb | 2 +- source/expectations/ut_expectation.tps | 2 +- source/expectations/ut_expectation_base.tpb | 2 +- source/expectations/ut_expectation_base.tps | 2 +- source/expectations/ut_expectation_compound.tpb | 2 +- source/expectations/ut_expectation_compound.tps | 2 +- source/expectations/ut_expectation_json.tpb | 2 +- source/expectations/ut_expectation_json.tps | 2 +- source/reporters/ut_ansiconsole_helper.pkb | 2 +- source/reporters/ut_ansiconsole_helper.pks | 2 +- source/reporters/ut_coverage_cobertura_reporter.tpb | 2 +- source/reporters/ut_coverage_cobertura_reporter.tps | 2 +- source/reporters/ut_coverage_html_reporter.tpb | 2 +- source/reporters/ut_coverage_html_reporter.tps | 2 +- source/reporters/ut_coverage_report_html_helper.pkb | 2 +- source/reporters/ut_coverage_report_html_helper.pks | 2 +- source/reporters/ut_coverage_sonar_reporter.tpb | 2 +- source/reporters/ut_coverage_sonar_reporter.tps | 2 +- source/reporters/ut_coveralls_reporter.tpb | 2 +- source/reporters/ut_coveralls_reporter.tps | 2 +- source/reporters/ut_debug_reporter.tpb | 2 +- source/reporters/ut_debug_reporter.tps | 2 +- source/reporters/ut_documentation_reporter.tpb | 2 +- source/reporters/ut_documentation_reporter.tps | 2 +- source/reporters/ut_junit_reporter.tpb | 2 +- source/reporters/ut_junit_reporter.tps | 2 +- source/reporters/ut_realtime_reporter.tpb | 2 +- source/reporters/ut_realtime_reporter.tps | 2 +- source/reporters/ut_sonar_test_reporter.tpb | 2 +- source/reporters/ut_sonar_test_reporter.tps | 2 +- source/reporters/ut_tap_reporter.tpb | 2 +- source/reporters/ut_tap_reporter.tps | 2 +- source/reporters/ut_teamcity_reporter.tpb | 2 +- source/reporters/ut_teamcity_reporter.tps | 2 +- source/reporters/ut_teamcity_reporter_helper.pkb | 2 +- source/reporters/ut_teamcity_reporter_helper.pks | 2 +- source/reporters/ut_tfs_junit_reporter.tpb | 2 +- source/reporters/ut_tfs_junit_reporter.tps | 2 +- source/reporters/ut_xunit_reporter.tpb | 2 +- source/reporters/ut_xunit_reporter.tps | 2 +- 261 files changed, 279 insertions(+), 263 deletions(-) diff --git a/.github/scripts/create_test_users.sh b/.github/scripts/create_test_users.sh index fff44f1bd..6c3030206 100755 --- a/.github/scripts/create_test_users.sh +++ b/.github/scripts/create_test_users.sh @@ -18,6 +18,9 @@ PROMPT Creating UT3_TESTER - Power-user for testing internal framework code create user UT3_TESTER identified by "ut3" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; grant create session, create procedure, create type, create table to UT3_TESTER; +# Editioning is enable on test users to validate that utPLSQL works well with editioned schema +alter user UT3_TESTER enable editions; + grant execute on dbms_lock to UT3_TESTER; PROMPT Granting $UT3_DEVELOP_SCHEMA code to UT3_TESTER @@ -52,6 +55,9 @@ PROMPT Creating UT3_USER - minimal privileges user for API testing create user UT3_USER identified by "ut3" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE; grant create session, create procedure, create type, create table to UT3_USER; +# Editioning is enable on test users to validate that utPLSQL works well with editioned schema +alter user UT3_USER enable editions; + PROMPT Grants for starting a debugging session from UT3_USER grant debug connect session to UT3_USER; grant debug any procedure to UT3_USER; diff --git a/.github/scripts/install.sh b/.github/scripts/install.sh index 46750b89c..5f034951c 100755 --- a/.github/scripts/install.sh +++ b/.github/scripts/install.sh @@ -19,3 +19,13 @@ set verify off alter session set plsql_optimize_level=0; @${INSTALL_FILE} $UT3_DEVELOP_SCHEMA $UT3_DEVELOP_SCHEMA_PASSWORD SQL + +#Enable editioning on the UT3_DEVELOP schema +time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL +whenever sqlerror exit failure rollback +set feedback off +set verify off + +alter user $UT3_DEVELOP_SCHEMA enable editions; +exit +SQL diff --git a/source/api/ut.pkb b/source/api/ut.pkb index d61de040a..0a847cfaa 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -1,4 +1,4 @@ -create or replace package body ut is +create or replace noneditionable package body ut is /* utPLSQL - Version 3 diff --git a/source/api/ut.pks b/source/api/ut.pks index 6fd98dd9f..fdba6b019 100644 --- a/source/api/ut.pks +++ b/source/api/ut.pks @@ -1,4 +1,4 @@ -create or replace package ut authid current_user as +create or replace noneditionable package ut authid current_user as /* utPLSQL - Version 3 diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 755683cc9..0db1d6e96 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_runner is +create or replace noneditionable package body ut_runner is /* utPLSQL - Version 3 diff --git a/source/api/ut_runner.pks b/source/api/ut_runner.pks index 2c6bba888..17bd0fa7a 100644 --- a/source/api/ut_runner.pks +++ b/source/api/ut_runner.pks @@ -1,4 +1,4 @@ -create or replace package ut_runner authid current_user is +create or replace noneditionable package ut_runner authid current_user is /* utPLSQL - Version 3 diff --git a/source/api/ut_suite_item_info.tpb b/source/api/ut_suite_item_info.tpb index 727707ae9..d18f078ee 100644 --- a/source/api/ut_suite_item_info.tpb +++ b/source/api/ut_suite_item_info.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_suite_item_info is +create or replace noneditionable type body ut_suite_item_info is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/api/ut_suite_item_info.tps b/source/api/ut_suite_item_info.tps index f632b2f52..4b4f9d52c 100644 --- a/source/api/ut_suite_item_info.tps +++ b/source/api/ut_suite_item_info.tps @@ -1,4 +1,4 @@ -create or replace type ut_suite_item_info as object ( +create or replace noneditionable type ut_suite_item_info as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/api/ut_suite_items_info.tps b/source/api/ut_suite_items_info.tps index e47b350e5..5a04c9a74 100644 --- a/source/api/ut_suite_items_info.tps +++ b/source/api/ut_suite_items_info.tps @@ -1,4 +1,4 @@ -create or replace type ut_suite_items_info as +create or replace noneditionable type ut_suite_items_info as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotated_object.tps b/source/core/annotations/ut_annotated_object.tps index 21f6ab330..facc8d2d8 100644 --- a/source/core/annotations/ut_annotated_object.tps +++ b/source/core/annotations/ut_annotated_object.tps @@ -1,4 +1,4 @@ -create type ut_annotated_object as object( +create or replace noneditionable type( )ut_annotated_object as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotated_objects.tps b/source/core/annotations/ut_annotated_objects.tps index 63679b699..e86f102c9 100644 --- a/source/core/annotations/ut_annotated_objects.tps +++ b/source/core/annotations/ut_annotated_objects.tps @@ -1,4 +1,4 @@ -create type ut_annotated_objects as +create or replace noneditionable type( )ut_annotated_objects as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation.tps b/source/core/annotations/ut_annotation.tps index 18747516a..a6889540f 100644 --- a/source/core/annotations/ut_annotation.tps +++ b/source/core/annotations/ut_annotation.tps @@ -1,4 +1,4 @@ -create type ut_annotation as object( +create or replace noneditionable type( )ut_annotation as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index 52184e17d..afc473404 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_annotation_cache_manager as +create or replace noneditionable package body ut_annotation_cache_manager as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_cache_manager.pks b/source/core/annotations/ut_annotation_cache_manager.pks index 55d109f91..1aa4cb501 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pks +++ b/source/core/annotations/ut_annotation_cache_manager.pks @@ -1,4 +1,4 @@ -create or replace package ut_annotation_cache_manager authid definer as +create or replace noneditionable package ut_annotation_cache_manager authid definer as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index e7d9f2719..b35f40075 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_annotation_manager as +create or replace noneditionable package body ut_annotation_manager as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_manager.pks b/source/core/annotations/ut_annotation_manager.pks index 637577d59..eedef002a 100644 --- a/source/core/annotations/ut_annotation_manager.pks +++ b/source/core/annotations/ut_annotation_manager.pks @@ -1,4 +1,4 @@ -create or replace package ut_annotation_manager authid current_user as +create or replace noneditionable package ut_annotation_manager authid current_user as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_obj_cache_info.tps b/source/core/annotations/ut_annotation_obj_cache_info.tps index f7bdfa9a8..9e0f3aa71 100644 --- a/source/core/annotations/ut_annotation_obj_cache_info.tps +++ b/source/core/annotations/ut_annotation_obj_cache_info.tps @@ -1,4 +1,4 @@ -create type ut_annotation_obj_cache_info as object( +create or replace noneditionable type( )ut_annotation_obj_cache_info as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_objs_cache_info.tps b/source/core/annotations/ut_annotation_objs_cache_info.tps index eb69f41e9..f6b5ea20d 100644 --- a/source/core/annotations/ut_annotation_objs_cache_info.tps +++ b/source/core/annotations/ut_annotation_objs_cache_info.tps @@ -1,4 +1,4 @@ -create type ut_annotation_objs_cache_info as +create or replace noneditionable type( )ut_annotation_objs_cache_info as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 8682604f6..5680d3cd2 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_annotation_parser as +create or replace noneditionable package body ut_annotation_parser as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_parser.pks b/source/core/annotations/ut_annotation_parser.pks index 5bc2700a4..3e0eaf84c 100644 --- a/source/core/annotations/ut_annotation_parser.pks +++ b/source/core/annotations/ut_annotation_parser.pks @@ -1,4 +1,4 @@ -create or replace package ut_annotation_parser authid current_user as +create or replace noneditionable package ut_annotation_parser authid current_user as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotations.tps b/source/core/annotations/ut_annotations.tps index 7669f008b..dd5b79e71 100644 --- a/source/core/annotations/ut_annotations.tps +++ b/source/core/annotations/ut_annotations.tps @@ -1,4 +1,4 @@ -create type ut_annotations +create or replace noneditionable type( )ut_annotations /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_trigger_check.pkb b/source/core/annotations/ut_trigger_check.pkb index d533044bb..da8f98949 100644 --- a/source/core/annotations/ut_trigger_check.pkb +++ b/source/core/annotations/ut_trigger_check.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_trigger_check is +create or replace noneditionable package body ut_trigger_check is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_trigger_check.pks b/source/core/annotations/ut_trigger_check.pks index 8c095c71a..dae59f3aa 100644 --- a/source/core/annotations/ut_trigger_check.pks +++ b/source/core/annotations/ut_trigger_check.pks @@ -1,4 +1,4 @@ -create or replace package ut_trigger_check authid definer is +create or replace noneditionable package ut_trigger_check authid definer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index f3181fdc7..be9b4ad5d 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_coverage is +create or replace noneditionable package body ut_coverage is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage.pks b/source/core/coverage/ut_coverage.pks index 6bcde8e64..b8bc4e169 100644 --- a/source/core/coverage/ut_coverage.pks +++ b/source/core/coverage/ut_coverage.pks @@ -1,4 +1,4 @@ -create or replace package ut_coverage authid current_user is +create or replace noneditionable package ut_coverage authid current_user is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_block.pkb b/source/core/coverage/ut_coverage_block.pkb index 2d7e8bdac..bfdf13274 100644 --- a/source/core/coverage/ut_coverage_block.pkb +++ b/source/core/coverage/ut_coverage_block.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_coverage_block is +create or replace noneditionable package body ut_coverage_block is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_block.pks b/source/core/coverage/ut_coverage_block.pks index 1bd9c2d39..9fccb3272 100644 --- a/source/core/coverage/ut_coverage_block.pks +++ b/source/core/coverage/ut_coverage_block.pks @@ -1,4 +1,4 @@ -create or replace package ut_coverage_block authid current_user is +create or replace noneditionable package ut_coverage_block authid current_user is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_helper.pkb b/source/core/coverage/ut_coverage_helper.pkb index 16e0bf7a1..ed1bea2ce 100644 --- a/source/core/coverage/ut_coverage_helper.pkb +++ b/source/core/coverage/ut_coverage_helper.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_coverage_helper is +create or replace noneditionable package body ut_coverage_helper is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_helper.pks b/source/core/coverage/ut_coverage_helper.pks index da4cba087..11988d935 100644 --- a/source/core/coverage/ut_coverage_helper.pks +++ b/source/core/coverage/ut_coverage_helper.pks @@ -1,4 +1,4 @@ -create or replace package ut_coverage_helper authid definer is +create or replace noneditionable package ut_coverage_helper authid definer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index 0cf009a10..3abbd54fc 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_coverage_helper_block is +create or replace noneditionable package body ut_coverage_helper_block is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_helper_block.pks b/source/core/coverage/ut_coverage_helper_block.pks index 3ee1f266c..dd8c451d7 100644 --- a/source/core/coverage/ut_coverage_helper_block.pks +++ b/source/core/coverage/ut_coverage_helper_block.pks @@ -1,4 +1,4 @@ -create or replace package ut_coverage_helper_block authid current_user is +create or replace noneditionable package ut_coverage_helper_block authid current_user is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_helper_profiler.pkb b/source/core/coverage/ut_coverage_helper_profiler.pkb index 7f6e6e51d..f98631593 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pkb +++ b/source/core/coverage/ut_coverage_helper_profiler.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_coverage_helper_profiler is +create or replace noneditionable package body ut_coverage_helper_profiler is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_helper_profiler.pks b/source/core/coverage/ut_coverage_helper_profiler.pks index 2e56d10f7..ca2a44a64 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pks +++ b/source/core/coverage/ut_coverage_helper_profiler.pks @@ -1,4 +1,4 @@ -create or replace package ut_coverage_helper_profiler authid definer is +create or replace noneditionable package ut_coverage_helper_profiler authid definer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_profiler.pkb b/source/core/coverage/ut_coverage_profiler.pkb index 1dc40bcbc..4e874dabf 100644 --- a/source/core/coverage/ut_coverage_profiler.pkb +++ b/source/core/coverage/ut_coverage_profiler.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_coverage_profiler is +create or replace noneditionable package body ut_coverage_profiler is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_profiler.pks b/source/core/coverage/ut_coverage_profiler.pks index 16145c34a..788005e15 100644 --- a/source/core/coverage/ut_coverage_profiler.pks +++ b/source/core/coverage/ut_coverage_profiler.pks @@ -1,4 +1,4 @@ -create or replace package ut_coverage_profiler authid current_user is +create or replace noneditionable package ut_coverage_profiler authid current_user is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_reporter_base.tpb b/source/core/coverage/ut_coverage_reporter_base.tpb index f28226428..e86af3795 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tpb +++ b/source/core/coverage/ut_coverage_reporter_base.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_coverage_reporter_base is +create or replace noneditionable type body ut_coverage_reporter_base is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/coverage/ut_coverage_reporter_base.tps b/source/core/coverage/ut_coverage_reporter_base.tps index b917ea707..c4afe389b 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tps +++ b/source/core/coverage/ut_coverage_reporter_base.tps @@ -1,4 +1,4 @@ -create or replace type ut_coverage_reporter_base under ut_output_reporter_base( +create or replace noneditionable type ut_coverage_reporter_base under ut_output_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/events/ut_event_item.tps b/source/core/events/ut_event_item.tps index bb4556e03..d9e1b84fc 100644 --- a/source/core/events/ut_event_item.tps +++ b/source/core/events/ut_event_item.tps @@ -1,4 +1,4 @@ -create or replace type ut_event_item authid current_user as object ( +create or replace noneditionable type ut_event_item authid current_user as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/events/ut_event_listener.tps b/source/core/events/ut_event_listener.tps index ee34bb009..7236fd512 100644 --- a/source/core/events/ut_event_listener.tps +++ b/source/core/events/ut_event_listener.tps @@ -1,4 +1,4 @@ -create or replace type ut_event_listener authid current_user as object ( +create or replace noneditionable type ut_event_listener authid current_user as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/events/ut_event_manager.pkb b/source/core/events/ut_event_manager.pkb index 0b80b5a98..50c500d13 100644 --- a/source/core/events/ut_event_manager.pkb +++ b/source/core/events/ut_event_manager.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_event_manager as +create or replace noneditionable package body ut_event_manager as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/events/ut_event_manager.pks b/source/core/events/ut_event_manager.pks index 9cea89898..08db7f5da 100644 --- a/source/core/events/ut_event_manager.pks +++ b/source/core/events/ut_event_manager.pks @@ -1,4 +1,4 @@ -create or replace package ut_event_manager authid current_user as +create or replace noneditionable package ut_event_manager authid current_user as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index dc9b34b88..8b9c236ef 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_output_buffer_base is +create or replace noneditionable type body ut_output_buffer_base is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_buffer_base.tps b/source/core/output_buffers/ut_output_buffer_base.tps index 9615cdc5e..da2bc9143 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tps +++ b/source/core/output_buffers/ut_output_buffer_base.tps @@ -1,4 +1,4 @@ -create or replace type ut_output_buffer_base force authid definer as object( +create or replace noneditionable type ut_output_buffer_base force authid definer as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tpb b/source/core/output_buffers/ut_output_bulk_buffer.tpb index bc0ec6128..4f6698eaf 100644 --- a/source/core/output_buffers/ut_output_bulk_buffer.tpb +++ b/source/core/output_buffers/ut_output_bulk_buffer.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_output_bulk_buffer is +create or replace noneditionable type body ut_output_bulk_buffer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tps b/source/core/output_buffers/ut_output_bulk_buffer.tps index 31d7271fa..538bc12a5 100644 --- a/source/core/output_buffers/ut_output_bulk_buffer.tps +++ b/source/core/output_buffers/ut_output_bulk_buffer.tps @@ -1,4 +1,4 @@ -create or replace type ut_output_bulk_buffer under ut_output_buffer_base ( +create or replace noneditionable type ut_output_bulk_buffer under ut_output_buffer_base ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index 8f1cd3187..f6d7c9a66 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_output_clob_table_buffer is +create or replace noneditionable type body ut_output_clob_table_buffer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tps b/source/core/output_buffers/ut_output_clob_table_buffer.tps index 2cfb2538b..b254c1f47 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tps +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tps @@ -1,4 +1,4 @@ -create or replace type ut_output_clob_table_buffer under ut_output_buffer_base ( +create or replace noneditionable type ut_output_clob_table_buffer under ut_output_buffer_base ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_data_row.tps b/source/core/output_buffers/ut_output_data_row.tps index ecfde404a..2eed2ee1f 100644 --- a/source/core/output_buffers/ut_output_data_row.tps +++ b/source/core/output_buffers/ut_output_data_row.tps @@ -1,4 +1,4 @@ -create or replace type ut_output_data_row as object ( +create or replace noneditionable type ut_output_data_row as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_data_rows.tps b/source/core/output_buffers/ut_output_data_rows.tps index c505e2fbf..a10440617 100644 --- a/source/core/output_buffers/ut_output_data_rows.tps +++ b/source/core/output_buffers/ut_output_data_rows.tps @@ -1,4 +1,4 @@ -create or replace type ut_output_data_rows as +create or replace noneditionable type ut_output_data_rows as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index 5fbd39907..d87362572 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_output_table_buffer is +create or replace noneditionable type body ut_output_table_buffer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/output_buffers/ut_output_table_buffer.tps b/source/core/output_buffers/ut_output_table_buffer.tps index 6c75421db..3f13e736d 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tps +++ b/source/core/output_buffers/ut_output_table_buffer.tps @@ -1,4 +1,4 @@ -create or replace type ut_output_table_buffer under ut_output_buffer_base ( +create or replace noneditionable type ut_output_table_buffer under ut_output_buffer_base ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/session_context/ut_session_context.pkb b/source/core/session_context/ut_session_context.pkb index 2443a350a..12d104eed 100644 --- a/source/core/session_context/ut_session_context.pkb +++ b/source/core/session_context/ut_session_context.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_session_context as +create or replace noneditionable package body ut_session_context as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/session_context/ut_session_context.pks b/source/core/session_context/ut_session_context.pks index 8df2decee..a5e4038a0 100644 --- a/source/core/session_context/ut_session_context.pks +++ b/source/core/session_context/ut_session_context.pks @@ -1,4 +1,4 @@ -create or replace package ut_session_context as +create or replace noneditionable package ut_session_context as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/session_context/ut_session_info.tpb b/source/core/session_context/ut_session_info.tpb index d9d576fb9..14f52b003 100644 --- a/source/core/session_context/ut_session_info.tpb +++ b/source/core/session_context/ut_session_info.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_session_info as +create or replace noneditionable type body ut_session_info as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/session_context/ut_session_info.tps b/source/core/session_context/ut_session_info.tps index aeb3361c3..d682a6bad 100644 --- a/source/core/session_context/ut_session_info.tps +++ b/source/core/session_context/ut_session_info.tps @@ -1,4 +1,4 @@ -create or replace type ut_session_info under ut_event_listener ( +create or replace noneditionable type ut_session_info under ut_event_listener ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_console_reporter_base.tpb b/source/core/types/ut_console_reporter_base.tpb index 282a52a9a..0825b8ba2 100644 --- a/source/core/types/ut_console_reporter_base.tpb +++ b/source/core/types/ut_console_reporter_base.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_console_reporter_base is +create or replace noneditionable type body ut_console_reporter_base is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_console_reporter_base.tps b/source/core/types/ut_console_reporter_base.tps index 077af7e37..46b344e6e 100644 --- a/source/core/types/ut_console_reporter_base.tps +++ b/source/core/types/ut_console_reporter_base.tps @@ -1,4 +1,4 @@ -create or replace type ut_console_reporter_base under ut_output_reporter_base( +create or replace noneditionable type ut_console_reporter_base under ut_output_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_coverage_options.tpb b/source/core/types/ut_coverage_options.tpb index 6c81af773..2accd960a 100644 --- a/source/core/types/ut_coverage_options.tpb +++ b/source/core/types/ut_coverage_options.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_coverage_options as +create or replace noneditionable type body ut_coverage_options as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_coverage_options.tps b/source/core/types/ut_coverage_options.tps index 3813232df..f2db1dafe 100644 --- a/source/core/types/ut_coverage_options.tps +++ b/source/core/types/ut_coverage_options.tps @@ -1,4 +1,4 @@ -create or replace type ut_coverage_options force as object ( +create or replace noneditionable type ut_coverage_options force as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_executable.tpb b/source/core/types/ut_executable.tpb index c78cf4d77..6a45caa99 100644 --- a/source/core/types/ut_executable.tpb +++ b/source/core/types/ut_executable.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_executable is +create or replace noneditionable type body ut_executable is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_executable.tps b/source/core/types/ut_executable.tps index 7d04c4e41..6257e3e89 100644 --- a/source/core/types/ut_executable.tps +++ b/source/core/types/ut_executable.tps @@ -1,4 +1,4 @@ -create or replace type ut_executable under ut_event_item( +create or replace noneditionable type ut_executable under ut_event_item( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index e816a1b1b..5772cdbc4 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_executable_test as +create or replace noneditionable type body ut_executable_test as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_executable_test.tps b/source/core/types/ut_executable_test.tps index 76f2d1c7d..91a7c6be0 100644 --- a/source/core/types/ut_executable_test.tps +++ b/source/core/types/ut_executable_test.tps @@ -1,4 +1,4 @@ -create or replace type ut_executable_test authid current_user under ut_executable ( +create or replace noneditionable type ut_executable_test authid current_user under ut_executable ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_executables.tps b/source/core/types/ut_executables.tps index f5fbbdfad..7718c44b8 100644 --- a/source/core/types/ut_executables.tps +++ b/source/core/types/ut_executables.tps @@ -1,4 +1,4 @@ -create or replace type ut_executables as +create or replace noneditionable type ut_executables as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_expectation_result.tpb b/source/core/types/ut_expectation_result.tpb index cf445b705..3ffd11789 100644 --- a/source/core/types/ut_expectation_result.tpb +++ b/source/core/types/ut_expectation_result.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_expectation_result is +create or replace noneditionable type body ut_expectation_result is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_expectation_result.tps b/source/core/types/ut_expectation_result.tps index 5a430fe64..e7eedd5ce 100644 --- a/source/core/types/ut_expectation_result.tps +++ b/source/core/types/ut_expectation_result.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation_result under ut_event_item( +create or replace noneditionable type ut_expectation_result under ut_event_item( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_expectation_results.tps b/source/core/types/ut_expectation_results.tps index 50cc046ec..168941112 100644 --- a/source/core/types/ut_expectation_results.tps +++ b/source/core/types/ut_expectation_results.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation_results as +create or replace noneditionable type ut_expectation_results as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_file_mapping.tpb b/source/core/types/ut_file_mapping.tpb index 5b7133c56..d693ac633 100644 --- a/source/core/types/ut_file_mapping.tpb +++ b/source/core/types/ut_file_mapping.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_file_mapping as +create or replace noneditionable type body ut_file_mapping as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_file_mapping.tps b/source/core/types/ut_file_mapping.tps index 8fed2df00..d28ef40ae 100644 --- a/source/core/types/ut_file_mapping.tps +++ b/source/core/types/ut_file_mapping.tps @@ -1,4 +1,4 @@ -create or replace type ut_file_mapping as object( +create or replace noneditionable type ut_file_mapping as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_file_mappings.tps b/source/core/types/ut_file_mappings.tps index 0e1653969..715530ee0 100644 --- a/source/core/types/ut_file_mappings.tps +++ b/source/core/types/ut_file_mappings.tps @@ -1,4 +1,4 @@ -create or replace type ut_file_mappings as +create or replace noneditionable type ut_file_mappings as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_integer_list.tps b/source/core/types/ut_integer_list.tps index 00bce87c4..b15cf743c 100644 --- a/source/core/types/ut_integer_list.tps +++ b/source/core/types/ut_integer_list.tps @@ -1,4 +1,4 @@ -create or replace type ut_integer_list as +create or replace noneditionable type ut_integer_list as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_key_value_pair.tps b/source/core/types/ut_key_value_pair.tps index 38dee5a7d..e26fff031 100644 --- a/source/core/types/ut_key_value_pair.tps +++ b/source/core/types/ut_key_value_pair.tps @@ -1,4 +1,4 @@ -create or replace type ut_key_value_pair force as object( +create or replace noneditionable type ut_key_value_pair force as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_key_value_pairs.tps b/source/core/types/ut_key_value_pairs.tps index 327986e19..d9e829dc9 100644 --- a/source/core/types/ut_key_value_pairs.tps +++ b/source/core/types/ut_key_value_pairs.tps @@ -1,4 +1,4 @@ -create or replace type ut_key_value_pairs as +create or replace noneditionable type ut_key_value_pairs as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_logical_suite.tpb b/source/core/types/ut_logical_suite.tpb index ea9b42857..c91320d8a 100644 --- a/source/core/types/ut_logical_suite.tpb +++ b/source/core/types/ut_logical_suite.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_logical_suite as +create or replace noneditionable type body ut_logical_suite as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_logical_suite.tps b/source/core/types/ut_logical_suite.tps index ab2271e32..245c422a1 100644 --- a/source/core/types/ut_logical_suite.tps +++ b/source/core/types/ut_logical_suite.tps @@ -1,4 +1,4 @@ -create or replace type ut_logical_suite force under ut_suite_item ( +create or replace noneditionable type ut_logical_suite force under ut_suite_item ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_object_name.tpb b/source/core/types/ut_object_name.tpb index e39231b0f..67834a9ed 100644 --- a/source/core/types/ut_object_name.tpb +++ b/source/core/types/ut_object_name.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_object_name as +create or replace noneditionable type body ut_object_name as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_object_name.tps b/source/core/types/ut_object_name.tps index dc4fe2bca..7f6341a32 100644 --- a/source/core/types/ut_object_name.tps +++ b/source/core/types/ut_object_name.tps @@ -1,4 +1,4 @@ -create or replace type ut_object_name as object ( +create or replace noneditionable type ut_object_name as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_object_names.tps b/source/core/types/ut_object_names.tps index 2b42cce21..879493a63 100644 --- a/source/core/types/ut_object_names.tps +++ b/source/core/types/ut_object_names.tps @@ -1,4 +1,4 @@ -create or replace type ut_object_names as +create or replace noneditionable type ut_object_names as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_output_reporter_base.tpb b/source/core/types/ut_output_reporter_base.tpb index fec4ebfab..4553f1780 100644 --- a/source/core/types/ut_output_reporter_base.tpb +++ b/source/core/types/ut_output_reporter_base.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_output_reporter_base is +create or replace noneditionable type body ut_output_reporter_base is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_output_reporter_base.tps b/source/core/types/ut_output_reporter_base.tps index f5827a97d..b9ec4f7cd 100644 --- a/source/core/types/ut_output_reporter_base.tps +++ b/source/core/types/ut_output_reporter_base.tps @@ -1,4 +1,4 @@ -create or replace type ut_output_reporter_base under ut_reporter_base( +create or replace noneditionable type ut_output_reporter_base under ut_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_path_item.tpb b/source/core/types/ut_path_item.tpb index 685178987..486fde865 100644 --- a/source/core/types/ut_path_item.tpb +++ b/source/core/types/ut_path_item.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_path_item as +create or replace noneditionable type body ut_path_item as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_path_item.tps b/source/core/types/ut_path_item.tps index 5946cacbf..fdc1e8ac2 100644 --- a/source/core/types/ut_path_item.tps +++ b/source/core/types/ut_path_item.tps @@ -1,4 +1,4 @@ -create or replace type ut_path_item as object ( +create or replace noneditionable type ut_path_item as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_path_items.tps b/source/core/types/ut_path_items.tps index 7ae04e0b9..64f8dd5fe 100644 --- a/source/core/types/ut_path_items.tps +++ b/source/core/types/ut_path_items.tps @@ -1,4 +1,4 @@ -create or replace type ut_path_items as +create or replace noneditionable type ut_path_items as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_reporter_base.tpb b/source/core/types/ut_reporter_base.tpb index 445d9d351..e457645f4 100644 --- a/source/core/types/ut_reporter_base.tpb +++ b/source/core/types/ut_reporter_base.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_reporter_base is +create or replace noneditionable type body ut_reporter_base is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_reporter_base.tps b/source/core/types/ut_reporter_base.tps index 9df353060..af0472dc5 100644 --- a/source/core/types/ut_reporter_base.tps +++ b/source/core/types/ut_reporter_base.tps @@ -1,4 +1,4 @@ -create or replace type ut_reporter_base under ut_event_listener ( +create or replace noneditionable type ut_reporter_base under ut_event_listener ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_reporter_info.tps b/source/core/types/ut_reporter_info.tps index 3491f7679..29c7559f1 100644 --- a/source/core/types/ut_reporter_info.tps +++ b/source/core/types/ut_reporter_info.tps @@ -1,4 +1,4 @@ -create or replace type ut_reporter_info as object ( +create or replace noneditionable type ut_reporter_info as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_reporters.tps b/source/core/types/ut_reporters.tps index ab6439dce..fba22480f 100644 --- a/source/core/types/ut_reporters.tps +++ b/source/core/types/ut_reporters.tps @@ -1,4 +1,4 @@ -create or replace type ut_reporters as +create or replace noneditionable type ut_reporters as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_reporters_info.tps b/source/core/types/ut_reporters_info.tps index 3639f4c2c..4f6f054a3 100644 --- a/source/core/types/ut_reporters_info.tps +++ b/source/core/types/ut_reporters_info.tps @@ -1,4 +1,4 @@ -create or replace type ut_reporters_info as +create or replace noneditionable type ut_reporters_info as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_results_counter.tpb b/source/core/types/ut_results_counter.tpb index 87fd83cf9..54f9e0b48 100644 --- a/source/core/types/ut_results_counter.tpb +++ b/source/core/types/ut_results_counter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_results_counter as +create or replace noneditionable type body ut_results_counter as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_results_counter.tps b/source/core/types/ut_results_counter.tps index 62b3d9ffd..477d4b217 100644 --- a/source/core/types/ut_results_counter.tps +++ b/source/core/types/ut_results_counter.tps @@ -1,4 +1,4 @@ -create or replace type ut_results_counter as object( +create or replace noneditionable type ut_results_counter as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_run.tpb b/source/core/types/ut_run.tpb index 0956be32d..80621b5ad 100644 --- a/source/core/types/ut_run.tpb +++ b/source/core/types/ut_run.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_run as +create or replace noneditionable type body ut_run as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_run.tps b/source/core/types/ut_run.tps index ef3631082..551e56ac4 100644 --- a/source/core/types/ut_run.tps +++ b/source/core/types/ut_run.tps @@ -1,4 +1,4 @@ -create or replace type ut_run under ut_suite_item ( +create or replace noneditionable type ut_run under ut_suite_item ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_run_info.tpb b/source/core/types/ut_run_info.tpb index 1370de3cc..3de74b2b4 100644 --- a/source/core/types/ut_run_info.tpb +++ b/source/core/types/ut_run_info.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_run_info as +create or replace noneditionable type body ut_run_info as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_run_info.tps b/source/core/types/ut_run_info.tps index df82c380d..00919b172 100644 --- a/source/core/types/ut_run_info.tps +++ b/source/core/types/ut_run_info.tps @@ -1,4 +1,4 @@ -create or replace type ut_run_info under ut_event_item ( +create or replace noneditionable type ut_run_info under ut_event_item ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_stack.tpb b/source/core/types/ut_stack.tpb index da0c371a6..4298ae35c 100644 --- a/source/core/types/ut_stack.tpb +++ b/source/core/types/ut_stack.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_stack as +create or replace noneditionable type body ut_stack as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_stack.tps b/source/core/types/ut_stack.tps index 5a5f90263..ed79bea55 100644 --- a/source/core/types/ut_stack.tps +++ b/source/core/types/ut_stack.tps @@ -1,4 +1,4 @@ -create or replace type ut_stack as object ( +create or replace noneditionable type ut_stack as object ( top integer, tokens ut_varchar2_list, /* diff --git a/source/core/types/ut_suite.tpb b/source/core/types/ut_suite.tpb index 9558565ed..b4e3eabf0 100644 --- a/source/core/types/ut_suite.tpb +++ b/source/core/types/ut_suite.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_suite as +create or replace noneditionable type body ut_suite as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_suite.tps b/source/core/types/ut_suite.tps index 199e05ea4..edce778f1 100644 --- a/source/core/types/ut_suite.tps +++ b/source/core/types/ut_suite.tps @@ -1,4 +1,4 @@ -create or replace type ut_suite under ut_logical_suite ( +create or replace noneditionable type ut_suite under ut_logical_suite ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_suite_cache_row.tps b/source/core/types/ut_suite_cache_row.tps index f294b3697..1ee371a88 100644 --- a/source/core/types/ut_suite_cache_row.tps +++ b/source/core/types/ut_suite_cache_row.tps @@ -1,4 +1,4 @@ -create or replace type ut_suite_cache_row as object ( +create or replace noneditionable type ut_suite_cache_row as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_suite_cache_rows.tps b/source/core/types/ut_suite_cache_rows.tps index c69c8672f..b201e7bf0 100644 --- a/source/core/types/ut_suite_cache_rows.tps +++ b/source/core/types/ut_suite_cache_rows.tps @@ -1,4 +1,4 @@ -create type ut_suite_cache_rows as +create or replace noneditionable type( )ut_suite_cache_rows as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_suite_context.tpb b/source/core/types/ut_suite_context.tpb index 52e57924a..dad24e42e 100644 --- a/source/core/types/ut_suite_context.tpb +++ b/source/core/types/ut_suite_context.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_suite_context as +create or replace noneditionable type body ut_suite_context as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_suite_context.tps b/source/core/types/ut_suite_context.tps index 51d318235..b890e2633 100644 --- a/source/core/types/ut_suite_context.tps +++ b/source/core/types/ut_suite_context.tps @@ -1,4 +1,4 @@ -create or replace type ut_suite_context under ut_suite ( +create or replace noneditionable type ut_suite_context under ut_suite ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_suite_item.tpb b/source/core/types/ut_suite_item.tpb index 965d2416e..8e8c6fd90 100644 --- a/source/core/types/ut_suite_item.tpb +++ b/source/core/types/ut_suite_item.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_suite_item as +create or replace noneditionable type body ut_suite_item as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_suite_item.tps b/source/core/types/ut_suite_item.tps index 8ba3c6183..2e990353f 100644 --- a/source/core/types/ut_suite_item.tps +++ b/source/core/types/ut_suite_item.tps @@ -1,4 +1,4 @@ -create or replace type ut_suite_item force under ut_event_item ( +create or replace noneditionable type ut_suite_item force under ut_event_item ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_suite_items.tps b/source/core/types/ut_suite_items.tps index ee3466c5d..b7ce9873c 100644 --- a/source/core/types/ut_suite_items.tps +++ b/source/core/types/ut_suite_items.tps @@ -1,4 +1,4 @@ -create or replace type ut_suite_items as +create or replace noneditionable type ut_suite_items as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_test.tpb b/source/core/types/ut_test.tpb index 21ca44713..61a1e39f8 100644 --- a/source/core/types/ut_test.tpb +++ b/source/core/types/ut_test.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_test as +create or replace noneditionable type body ut_test as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_test.tps b/source/core/types/ut_test.tps index 215e3e9d6..cb50c2fd4 100644 --- a/source/core/types/ut_test.tps +++ b/source/core/types/ut_test.tps @@ -1,4 +1,4 @@ -create or replace type ut_test force under ut_suite_item ( +create or replace noneditionable type ut_test force under ut_suite_item ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_varchar2_list.tps b/source/core/types/ut_varchar2_list.tps index 95a5545a8..8203a4bab 100644 --- a/source/core/types/ut_varchar2_list.tps +++ b/source/core/types/ut_varchar2_list.tps @@ -1,4 +1,4 @@ -create or replace type ut_varchar2_list as +create or replace noneditionable type ut_varchar2_list as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_varchar2_rows.tps b/source/core/types/ut_varchar2_rows.tps index c6f05df86..a2e25e9fb 100644 --- a/source/core/types/ut_varchar2_rows.tps +++ b/source/core/types/ut_varchar2_rows.tps @@ -1,4 +1,4 @@ -create or replace type ut_varchar2_rows as +create or replace noneditionable type ut_varchar2_rows as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index 654a838ca..3fb39a5b9 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_expectation_processor as +create or replace noneditionable package body ut_expectation_processor as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_expectation_processor.pks b/source/core/ut_expectation_processor.pks index 1837188eb..5349ee70a 100644 --- a/source/core/ut_expectation_processor.pks +++ b/source/core/ut_expectation_processor.pks @@ -1,4 +1,4 @@ -create or replace package ut_expectation_processor authid current_user as +create or replace noneditionable package ut_expectation_processor authid current_user as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_file_mapper.pkb b/source/core/ut_file_mapper.pkb index 077319d76..40204a5da 100644 --- a/source/core/ut_file_mapper.pkb +++ b/source/core/ut_file_mapper.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_file_mapper is +create or replace noneditionable package body ut_file_mapper is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_file_mapper.pks b/source/core/ut_file_mapper.pks index 71e045d7e..1363e81ec 100644 --- a/source/core/ut_file_mapper.pks +++ b/source/core/ut_file_mapper.pks @@ -1,4 +1,4 @@ -create or replace package ut_file_mapper authid current_user is +create or replace noneditionable package ut_file_mapper authid current_user is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index aec9a3c8d..d9939ad45 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_metadata as +create or replace noneditionable package body ut_metadata as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_metadata.pks b/source/core/ut_metadata.pks index 31cf4889b..42f136504 100644 --- a/source/core/ut_metadata.pks +++ b/source/core/ut_metadata.pks @@ -1,4 +1,4 @@ -create or replace package ut_metadata authid current_user as +create or replace noneditionable package ut_metadata authid current_user as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 2ebdb980c..63aa01b24 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_suite_builder is +create or replace noneditionable package body ut_suite_builder is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_suite_builder.pks b/source/core/ut_suite_builder.pks index 7e43a720e..35f207ea4 100644 --- a/source/core/ut_suite_builder.pks +++ b/source/core/ut_suite_builder.pks @@ -1,4 +1,4 @@ -create or replace package ut_suite_builder authid current_user is +create or replace noneditionable package ut_suite_builder authid current_user is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index fb7c2c888..9aa3cf63d 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_suite_cache_manager is +create or replace noneditionable package body ut_suite_cache_manager is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index bd236678d..6ac1d7bd6 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -1,4 +1,4 @@ -create or replace package ut_suite_cache_manager authid definer is +create or replace noneditionable package ut_suite_cache_manager authid definer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index ad7f27f59..fa60be59e 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_suite_manager is +create or replace noneditionable package body ut_suite_manager is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 8ac7cc8ad..60c3595bb 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -1,4 +1,4 @@ -create or replace package ut_suite_manager authid current_user is +create or replace noneditionable package ut_suite_manager authid current_user is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index 17b5ba4b0..447ba47d5 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_suite_tag_filter is +create or replace noneditionable package body ut_suite_tag_filter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_suite_tag_filter.pks b/source/core/ut_suite_tag_filter.pks index 0493bd194..bb3d4ad73 100644 --- a/source/core/ut_suite_tag_filter.pks +++ b/source/core/ut_suite_tag_filter.pks @@ -1,4 +1,4 @@ -create or replace package ut_suite_tag_filter authid definer is +create or replace noneditionable package ut_suite_tag_filter authid definer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index 32cbb3f8c..c8ced3bb9 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_utils is +create or replace noneditionable package body ut_utils is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 7cffd26e8..26f878b8e 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -1,4 +1,4 @@ -create or replace package ut_utils authid definer is +create or replace noneditionable package ut_utils authid definer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 42feb2a47..763c133d7 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_compound_data_helper is +create or replace noneditionable package body ut_compound_data_helper is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_compound_data_helper.pks b/source/expectations/data_values/ut_compound_data_helper.pks index dd2e2ec3d..6069920c9 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pks +++ b/source/expectations/data_values/ut_compound_data_helper.pks @@ -1,4 +1,4 @@ -create or replace package ut_compound_data_helper authid definer is +create or replace noneditionable package ut_compound_data_helper authid definer is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_compound_data_value.tpb b/source/expectations/data_values/ut_compound_data_value.tpb index 5fd3154b1..7db47827e 100644 --- a/source/expectations/data_values/ut_compound_data_value.tpb +++ b/source/expectations/data_values/ut_compound_data_value.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_compound_data_value as +create or replace noneditionable type body ut_compound_data_value as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_compound_data_value.tps b/source/expectations/data_values/ut_compound_data_value.tps index ca2206e2a..c84a59db6 100644 --- a/source/expectations/data_values/ut_compound_data_value.tps +++ b/source/expectations/data_values/ut_compound_data_value.tps @@ -1,4 +1,4 @@ -create or replace type ut_compound_data_value force under ut_data_value( +create or replace noneditionable type ut_compound_data_value force under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_cursor_column.tpb b/source/expectations/data_values/ut_cursor_column.tpb index 13fbb86b7..3513de23e 100644 --- a/source/expectations/data_values/ut_cursor_column.tpb +++ b/source/expectations/data_values/ut_cursor_column.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_cursor_column as +create or replace noneditionable type body ut_cursor_column as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_cursor_column.tps b/source/expectations/data_values/ut_cursor_column.tps index 98ca78b6e..fcf3fe002 100644 --- a/source/expectations/data_values/ut_cursor_column.tps +++ b/source/expectations/data_values/ut_cursor_column.tps @@ -1,4 +1,4 @@ -create or replace type ut_cursor_column authid current_user as object ( +create or replace noneditionable type ut_cursor_column authid current_user as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_cursor_column_tab.tps b/source/expectations/data_values/ut_cursor_column_tab.tps index 258624691..169ba3ce4 100644 --- a/source/expectations/data_values/ut_cursor_column_tab.tps +++ b/source/expectations/data_values/ut_cursor_column_tab.tps @@ -1,4 +1,4 @@ -create or replace type ut_cursor_column_tab as +create or replace noneditionable type ut_cursor_column_tab as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_cursor_details.tpb b/source/expectations/data_values/ut_cursor_details.tpb index cce0751d1..ff204e3bd 100644 --- a/source/expectations/data_values/ut_cursor_details.tpb +++ b/source/expectations/data_values/ut_cursor_details.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_cursor_details as +create or replace noneditionable type body ut_cursor_details as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_cursor_details.tps b/source/expectations/data_values/ut_cursor_details.tps index 981fda8e5..c50ed16d3 100644 --- a/source/expectations/data_values/ut_cursor_details.tps +++ b/source/expectations/data_values/ut_cursor_details.tps @@ -1,4 +1,4 @@ -create or replace type ut_cursor_details authid current_user as object ( +create or replace noneditionable type ut_cursor_details authid current_user as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value.tpb b/source/expectations/data_values/ut_data_value.tpb index 6eb352b77..05eb3022e 100644 --- a/source/expectations/data_values/ut_data_value.tpb +++ b/source/expectations/data_values/ut_data_value.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value as +create or replace noneditionable type body ut_data_value as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value.tps b/source/expectations/data_values/ut_data_value.tps index 91a07e463..6e362a56d 100644 --- a/source/expectations/data_values/ut_data_value.tps +++ b/source/expectations/data_values/ut_data_value.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value force authid current_user as object ( +create or replace noneditionable type ut_data_value force authid current_user as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_anydata.tpb b/source/expectations/data_values/ut_data_value_anydata.tpb index 189d2e032..9fccb7582 100644 --- a/source/expectations/data_values/ut_data_value_anydata.tpb +++ b/source/expectations/data_values/ut_data_value_anydata.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_anydata as +create or replace noneditionable type body ut_data_value_anydata as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_anydata.tps b/source/expectations/data_values/ut_data_value_anydata.tps index ee9725d58..6ad692d31 100644 --- a/source/expectations/data_values/ut_data_value_anydata.tps +++ b/source/expectations/data_values/ut_data_value_anydata.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_anydata under ut_data_value_refcursor( +create or replace noneditionable type ut_data_value_anydata under ut_data_value_refcursor( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_blob.tpb b/source/expectations/data_values/ut_data_value_blob.tpb index 42e35fc55..c961ebaab 100644 --- a/source/expectations/data_values/ut_data_value_blob.tpb +++ b/source/expectations/data_values/ut_data_value_blob.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_blob as +create or replace noneditionable type body ut_data_value_blob as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_blob.tps b/source/expectations/data_values/ut_data_value_blob.tps index 08813371e..94124bfec 100644 --- a/source/expectations/data_values/ut_data_value_blob.tps +++ b/source/expectations/data_values/ut_data_value_blob.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_blob under ut_data_value( +create or replace noneditionable type ut_data_value_blob under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_boolean.tpb b/source/expectations/data_values/ut_data_value_boolean.tpb index 84af1c34c..dd253442c 100644 --- a/source/expectations/data_values/ut_data_value_boolean.tpb +++ b/source/expectations/data_values/ut_data_value_boolean.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_boolean as +create or replace noneditionable type body ut_data_value_boolean as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_boolean.tps b/source/expectations/data_values/ut_data_value_boolean.tps index 4d7af837b..b6df4e0b4 100644 --- a/source/expectations/data_values/ut_data_value_boolean.tps +++ b/source/expectations/data_values/ut_data_value_boolean.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_boolean under ut_data_value( +create or replace noneditionable type ut_data_value_boolean under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_clob.tpb b/source/expectations/data_values/ut_data_value_clob.tpb index 2dd00c023..76a55545e 100644 --- a/source/expectations/data_values/ut_data_value_clob.tpb +++ b/source/expectations/data_values/ut_data_value_clob.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_clob as +create or replace noneditionable type body ut_data_value_clob as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_clob.tps b/source/expectations/data_values/ut_data_value_clob.tps index abcc635c9..686757e85 100644 --- a/source/expectations/data_values/ut_data_value_clob.tps +++ b/source/expectations/data_values/ut_data_value_clob.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_clob under ut_data_value( +create or replace noneditionable type ut_data_value_clob under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_date.tpb b/source/expectations/data_values/ut_data_value_date.tpb index dc1c4d22f..2a1232a1c 100644 --- a/source/expectations/data_values/ut_data_value_date.tpb +++ b/source/expectations/data_values/ut_data_value_date.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_date as +create or replace noneditionable type body ut_data_value_date as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_date.tps b/source/expectations/data_values/ut_data_value_date.tps index 8db1850c2..0bb9a17cf 100644 --- a/source/expectations/data_values/ut_data_value_date.tps +++ b/source/expectations/data_values/ut_data_value_date.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_date under ut_data_value( +create or replace noneditionable type ut_data_value_date under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tpb b/source/expectations/data_values/ut_data_value_dsinterval.tpb index bcfb48a2b..adad0ef6d 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tpb +++ b/source/expectations/data_values/ut_data_value_dsinterval.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_dsinterval as +create or replace noneditionable type body ut_data_value_dsinterval as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tps b/source/expectations/data_values/ut_data_value_dsinterval.tps index 5add4adf9..3d15e2e09 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tps +++ b/source/expectations/data_values/ut_data_value_dsinterval.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_dsinterval under ut_data_value( +create or replace noneditionable type ut_data_value_dsinterval under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_json.tpb b/source/expectations/data_values/ut_data_value_json.tpb index 9f65ef618..e1b5aa995 100644 --- a/source/expectations/data_values/ut_data_value_json.tpb +++ b/source/expectations/data_values/ut_data_value_json.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_json as +create or replace noneditionable type body ut_data_value_json as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_json.tps b/source/expectations/data_values/ut_data_value_json.tps index 46a78e00e..c89088564 100644 --- a/source/expectations/data_values/ut_data_value_json.tps +++ b/source/expectations/data_values/ut_data_value_json.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_json under ut_compound_data_value( +create or replace noneditionable type ut_data_value_json under ut_compound_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_number.tpb b/source/expectations/data_values/ut_data_value_number.tpb index 53b8ce413..3ea08bbd4 100644 --- a/source/expectations/data_values/ut_data_value_number.tpb +++ b/source/expectations/data_values/ut_data_value_number.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_number as +create or replace noneditionable type body ut_data_value_number as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_number.tps b/source/expectations/data_values/ut_data_value_number.tps index 914252b9f..e7031de72 100644 --- a/source/expectations/data_values/ut_data_value_number.tps +++ b/source/expectations/data_values/ut_data_value_number.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_number under ut_data_value( +create or replace noneditionable type ut_data_value_number under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_refcursor.tpb b/source/expectations/data_values/ut_data_value_refcursor.tpb index ee1408b56..b7f79ac52 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tpb +++ b/source/expectations/data_values/ut_data_value_refcursor.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_refcursor as +create or replace noneditionable type body ut_data_value_refcursor as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_refcursor.tps b/source/expectations/data_values/ut_data_value_refcursor.tps index 7d336bd78..90a305d32 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tps +++ b/source/expectations/data_values/ut_data_value_refcursor.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_refcursor under ut_compound_data_value( +create or replace noneditionable type ut_data_value_refcursor under ut_compound_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_timestamp.tpb b/source/expectations/data_values/ut_data_value_timestamp.tpb index bfb0ab734..c6aabf7a3 100644 --- a/source/expectations/data_values/ut_data_value_timestamp.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_timestamp as +create or replace noneditionable type body ut_data_value_timestamp as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_timestamp.tps b/source/expectations/data_values/ut_data_value_timestamp.tps index 5c1f0b879..938b0d63c 100644 --- a/source/expectations/data_values/ut_data_value_timestamp.tps +++ b/source/expectations/data_values/ut_data_value_timestamp.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_timestamp under ut_data_value( +create or replace noneditionable type ut_data_value_timestamp under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb index ba1610d31..025314f4b 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_timestamp_ltz as +create or replace noneditionable type body ut_data_value_timestamp_ltz as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_timestamp_ltz.tps b/source/expectations/data_values/ut_data_value_timestamp_ltz.tps index 51bf615af..e7c61a878 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_ltz.tps +++ b/source/expectations/data_values/ut_data_value_timestamp_ltz.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_timestamp_ltz under ut_data_value( +create or replace noneditionable type ut_data_value_timestamp_ltz under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb index ea0d28090..6af5fea4d 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_timestamp_tz as +create or replace noneditionable type body ut_data_value_timestamp_tz as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_timestamp_tz.tps b/source/expectations/data_values/ut_data_value_timestamp_tz.tps index 435dc8df0..ad190d197 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_tz.tps +++ b/source/expectations/data_values/ut_data_value_timestamp_tz.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_timestamp_tz under ut_data_value( +create or replace noneditionable type ut_data_value_timestamp_tz under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_varchar2.tpb b/source/expectations/data_values/ut_data_value_varchar2.tpb index 923ef7b9e..7a26d7571 100644 --- a/source/expectations/data_values/ut_data_value_varchar2.tpb +++ b/source/expectations/data_values/ut_data_value_varchar2.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_varchar2 as +create or replace noneditionable type body ut_data_value_varchar2 as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_varchar2.tps b/source/expectations/data_values/ut_data_value_varchar2.tps index 8db175d90..56effd460 100644 --- a/source/expectations/data_values/ut_data_value_varchar2.tps +++ b/source/expectations/data_values/ut_data_value_varchar2.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_varchar2 under ut_data_value( +create or replace noneditionable type ut_data_value_varchar2 under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_xmltype.tpb b/source/expectations/data_values/ut_data_value_xmltype.tpb index dc518da54..f5ffcbc9a 100644 --- a/source/expectations/data_values/ut_data_value_xmltype.tpb +++ b/source/expectations/data_values/ut_data_value_xmltype.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_xmltype as +create or replace noneditionable type body ut_data_value_xmltype as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_xmltype.tps b/source/expectations/data_values/ut_data_value_xmltype.tps index 3929b4d7c..2d0257918 100644 --- a/source/expectations/data_values/ut_data_value_xmltype.tps +++ b/source/expectations/data_values/ut_data_value_xmltype.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_xmltype under ut_data_value( +create or replace noneditionable type ut_data_value_xmltype under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_yminterval.tpb b/source/expectations/data_values/ut_data_value_yminterval.tpb index abba0bc20..8d12d3544 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tpb +++ b/source/expectations/data_values/ut_data_value_yminterval.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_data_value_yminterval as +create or replace noneditionable type body ut_data_value_yminterval as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_data_value_yminterval.tps b/source/expectations/data_values/ut_data_value_yminterval.tps index 734ed545d..8c3ad8079 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tps +++ b/source/expectations/data_values/ut_data_value_yminterval.tps @@ -1,4 +1,4 @@ -create or replace type ut_data_value_yminterval under ut_data_value( +create or replace noneditionable type ut_data_value_yminterval under ut_data_value( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_json_leaf.tpb b/source/expectations/data_values/ut_json_leaf.tpb index b7a20f11b..d6c862286 100644 --- a/source/expectations/data_values/ut_json_leaf.tpb +++ b/source/expectations/data_values/ut_json_leaf.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_json_leaf as +create or replace noneditionable type body ut_json_leaf as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_json_leaf.tps b/source/expectations/data_values/ut_json_leaf.tps index 70d4df71d..ac478e34e 100644 --- a/source/expectations/data_values/ut_json_leaf.tps +++ b/source/expectations/data_values/ut_json_leaf.tps @@ -1,4 +1,4 @@ -create or replace type ut_json_leaf authid current_user as object ( +create or replace noneditionable type ut_json_leaf authid current_user as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_json_leaf_tab.tps b/source/expectations/data_values/ut_json_leaf_tab.tps index 10fd3eef6..c00f2a3a1 100644 --- a/source/expectations/data_values/ut_json_leaf_tab.tps +++ b/source/expectations/data_values/ut_json_leaf_tab.tps @@ -1,4 +1,4 @@ -create or replace type ut_json_leaf_tab as +create or replace noneditionable type ut_json_leaf_tab as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_json_tree_details.tpb b/source/expectations/data_values/ut_json_tree_details.tpb index f82aac5a0..0d457b2c5 100644 --- a/source/expectations/data_values/ut_json_tree_details.tpb +++ b/source/expectations/data_values/ut_json_tree_details.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_json_tree_details as +create or replace noneditionable type body ut_json_tree_details as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_json_tree_details.tps b/source/expectations/data_values/ut_json_tree_details.tps index 9c37f99ea..4f7e891be 100644 --- a/source/expectations/data_values/ut_json_tree_details.tps +++ b/source/expectations/data_values/ut_json_tree_details.tps @@ -1,4 +1,4 @@ -create or replace type ut_json_tree_details force as object ( +create or replace noneditionable type ut_json_tree_details force as object ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_key_anyval_pair.tps b/source/expectations/data_values/ut_key_anyval_pair.tps index 7935ffa09..6ed63ae7e 100644 --- a/source/expectations/data_values/ut_key_anyval_pair.tps +++ b/source/expectations/data_values/ut_key_anyval_pair.tps @@ -1,4 +1,4 @@ -create or replace type ut_key_anyval_pair force as object( +create or replace noneditionable type ut_key_anyval_pair force as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_key_anyval_pairs.tps b/source/expectations/data_values/ut_key_anyval_pairs.tps index 2cc1ff225..a75305f79 100644 --- a/source/expectations/data_values/ut_key_anyval_pairs.tps +++ b/source/expectations/data_values/ut_key_anyval_pairs.tps @@ -1,4 +1,4 @@ -create or replace type ut_key_anyval_pairs as +create or replace noneditionable type ut_key_anyval_pairs as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_key_anyvalues.tpb b/source/expectations/data_values/ut_key_anyvalues.tpb index 67b877874..4e6dd2c0f 100644 --- a/source/expectations/data_values/ut_key_anyvalues.tpb +++ b/source/expectations/data_values/ut_key_anyvalues.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_key_anyvalues as +create or replace noneditionable type body ut_key_anyvalues as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/data_values/ut_key_anyvalues.tps b/source/expectations/data_values/ut_key_anyvalues.tps index df14a8101..21a9a5c72 100644 --- a/source/expectations/data_values/ut_key_anyvalues.tps +++ b/source/expectations/data_values/ut_key_anyvalues.tps @@ -1,4 +1,4 @@ -create or replace type ut_key_anyvalues under ut_event_item ( +create or replace noneditionable type ut_key_anyvalues under ut_event_item ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/json_objects_specs.sql b/source/expectations/json_objects_specs.sql index a5d936afb..c0fc15ed6 100644 --- a/source/expectations/json_objects_specs.sql +++ b/source/expectations/json_objects_specs.sql @@ -2,13 +2,13 @@ BEGIN null; $if dbms_db_version.version < 21 $then dbms_output.put_line('Installing json structures specs for native json.'); - execute immediate q'[create or replace TYPE JSON FORCE AUTHID CURRENT_USER AS OBJECT( + execute immediate q'[create or replace noneditionable TYPE JSON FORCE AUTHID CURRENT_USER AS OBJECT( dummyobjt NUMBER ) NOT FINAL NOT INSTANTIABLE;]'; $end $if dbms_db_version.version = 12 and dbms_db_version.release = 1 or dbms_db_version.version < 12 $then dbms_output.put_line('Installing json structures specs.'); - execute immediate q'[create or replace TYPE JSON_Element_T FORCE AUTHID CURRENT_USER AS OBJECT( + execute immediate q'[create or replace noneditionable TYPE JSON_Element_T FORCE AUTHID CURRENT_USER AS OBJECT( dummyobjt NUMBER, STATIC FUNCTION parse(jsn VARCHAR2) RETURN JSON_Element_T, STATIC FUNCTION parse(jsn CLOB) RETURN JSON_Element_T, @@ -34,9 +34,9 @@ BEGIN MEMBER FUNCTION get_Size(self IN JSON_ELEMENT_T) RETURN NUMBER ) NOT FINAL NOT INSTANTIABLE;]'; - execute immediate q'[create or replace TYPE JSON_KEY_LIST FORCE AS VARRAY(32767) OF VARCHAR2(4000);]'; + execute immediate q'[create or replace noneditionable TYPE JSON_KEY_LIST FORCE AS VARRAY(32767) OF VARCHAR2(4000);]'; - execute immediate q'[create or replace TYPE JSON_Array_T FORCE AUTHID CURRENT_USER UNDER JSON_Element_T( + execute immediate q'[create or replace noneditionable TYPE JSON_Array_T FORCE AUTHID CURRENT_USER UNDER JSON_Element_T( CONSTRUCTOR FUNCTION JSON_Array_T RETURN SELF AS RESULT, MEMBER FUNCTION get(pos NUMBER) RETURN JSON_Element_T, MEMBER FUNCTION get_String(pos NUMBER) RETURN VARCHAR2, @@ -51,7 +51,7 @@ BEGIN MEMBER FUNCTION get_Type(pos NUMBER) RETURN VARCHAR2 ) FINAL;]'; - execute immediate q'[create or replace TYPE JSON_Object_T AUTHID CURRENT_USER UNDER JSON_Element_T( + execute immediate q'[create or replace noneditionable TYPE JSON_Object_T AUTHID CURRENT_USER UNDER JSON_Element_T( CONSTRUCTOR FUNCTION JSON_Object_T RETURN SELF AS RESULT, MEMBER FUNCTION get(key VARCHAR2) RETURN JSON_Element_T, MEMBER FUNCTION get_Object(key VARCHAR2) RETURN JSON_OBJECT_T, diff --git a/source/expectations/matchers/ut_be_between.tpb b/source/expectations/matchers/ut_be_between.tpb index 787be701b..83dfc4c25 100644 --- a/source/expectations/matchers/ut_be_between.tpb +++ b/source/expectations/matchers/ut_be_between.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_between is +create or replace noneditionable type body ut_be_between is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_between.tps b/source/expectations/matchers/ut_be_between.tps index a08d7a823..7f1403847 100644 --- a/source/expectations/matchers/ut_be_between.tps +++ b/source/expectations/matchers/ut_be_between.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_between under ut_matcher( +create or replace noneditionable type ut_be_between under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_empty.tpb b/source/expectations/matchers/ut_be_empty.tpb index bac77166a..af233aa8f 100644 --- a/source/expectations/matchers/ut_be_empty.tpb +++ b/source/expectations/matchers/ut_be_empty.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_empty as +create or replace noneditionable type body ut_be_empty as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_empty.tps b/source/expectations/matchers/ut_be_empty.tps index 948e771a3..a5672ba78 100644 --- a/source/expectations/matchers/ut_be_empty.tps +++ b/source/expectations/matchers/ut_be_empty.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_empty under ut_matcher( +create or replace noneditionable type ut_be_empty under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_false.tpb b/source/expectations/matchers/ut_be_false.tpb index 5a5421e8b..a02ac58cb 100644 --- a/source/expectations/matchers/ut_be_false.tpb +++ b/source/expectations/matchers/ut_be_false.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_false as +create or replace noneditionable type body ut_be_false as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_false.tps b/source/expectations/matchers/ut_be_false.tps index b6906ece8..d793844c1 100644 --- a/source/expectations/matchers/ut_be_false.tps +++ b/source/expectations/matchers/ut_be_false.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_false under ut_matcher( +create or replace noneditionable type ut_be_false under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_greater_or_equal.tpb b/source/expectations/matchers/ut_be_greater_or_equal.tpb index fbd165b1d..6e564a90c 100644 --- a/source/expectations/matchers/ut_be_greater_or_equal.tpb +++ b/source/expectations/matchers/ut_be_greater_or_equal.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_greater_or_equal AS +create or replace noneditionable type body ut_be_greater_or_equal AS /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_greater_or_equal.tps b/source/expectations/matchers/ut_be_greater_or_equal.tps index e87740134..d3e651958 100644 --- a/source/expectations/matchers/ut_be_greater_or_equal.tps +++ b/source/expectations/matchers/ut_be_greater_or_equal.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_greater_or_equal under ut_comparison_matcher( +create or replace noneditionable type ut_be_greater_or_equal under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_greater_than.tpb b/source/expectations/matchers/ut_be_greater_than.tpb index f59c2f0be..08628ae3a 100644 --- a/source/expectations/matchers/ut_be_greater_than.tpb +++ b/source/expectations/matchers/ut_be_greater_than.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_greater_than AS +create or replace noneditionable type body ut_be_greater_than AS /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_greater_than.tps b/source/expectations/matchers/ut_be_greater_than.tps index b66009bab..745b19f08 100644 --- a/source/expectations/matchers/ut_be_greater_than.tps +++ b/source/expectations/matchers/ut_be_greater_than.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_greater_than under ut_comparison_matcher( +create or replace noneditionable type ut_be_greater_than under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_less_or_equal.tpb b/source/expectations/matchers/ut_be_less_or_equal.tpb index 24c1f9c96..2df06a078 100644 --- a/source/expectations/matchers/ut_be_less_or_equal.tpb +++ b/source/expectations/matchers/ut_be_less_or_equal.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_less_or_equal AS +create or replace noneditionable type body ut_be_less_or_equal AS /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_less_or_equal.tps b/source/expectations/matchers/ut_be_less_or_equal.tps index 5114644b0..f0e297ad1 100644 --- a/source/expectations/matchers/ut_be_less_or_equal.tps +++ b/source/expectations/matchers/ut_be_less_or_equal.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_less_or_equal under ut_comparison_matcher( +create or replace noneditionable type ut_be_less_or_equal under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_less_than.tpb b/source/expectations/matchers/ut_be_less_than.tpb index 011ad392f..c0b059231 100644 --- a/source/expectations/matchers/ut_be_less_than.tpb +++ b/source/expectations/matchers/ut_be_less_than.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_less_than as +create or replace noneditionable type body ut_be_less_than as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_less_than.tps b/source/expectations/matchers/ut_be_less_than.tps index 81a25144d..594df9b71 100644 --- a/source/expectations/matchers/ut_be_less_than.tps +++ b/source/expectations/matchers/ut_be_less_than.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_less_than under ut_comparison_matcher( +create or replace noneditionable type ut_be_less_than under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_like.tpb b/source/expectations/matchers/ut_be_like.tpb index 953adbe5b..b94c3fa91 100644 --- a/source/expectations/matchers/ut_be_like.tpb +++ b/source/expectations/matchers/ut_be_like.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_like as +create or replace noneditionable type body ut_be_like as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_like.tps b/source/expectations/matchers/ut_be_like.tps index 1d907ed03..ca9ad45de 100644 --- a/source/expectations/matchers/ut_be_like.tps +++ b/source/expectations/matchers/ut_be_like.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_like under ut_matcher( +create or replace noneditionable type ut_be_like under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_not_null.tpb b/source/expectations/matchers/ut_be_not_null.tpb index df9366fa7..d291d2e35 100644 --- a/source/expectations/matchers/ut_be_not_null.tpb +++ b/source/expectations/matchers/ut_be_not_null.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_not_null as +create or replace noneditionable type body ut_be_not_null as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_not_null.tps b/source/expectations/matchers/ut_be_not_null.tps index 6cd11fc64..61f6c871d 100644 --- a/source/expectations/matchers/ut_be_not_null.tps +++ b/source/expectations/matchers/ut_be_not_null.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_not_null under ut_matcher( +create or replace noneditionable type ut_be_not_null under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_null.tpb b/source/expectations/matchers/ut_be_null.tpb index d806bba34..89fbaf563 100644 --- a/source/expectations/matchers/ut_be_null.tpb +++ b/source/expectations/matchers/ut_be_null.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_null as +create or replace noneditionable type body ut_be_null as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_null.tps b/source/expectations/matchers/ut_be_null.tps index 28f3ac796..063c7db29 100644 --- a/source/expectations/matchers/ut_be_null.tps +++ b/source/expectations/matchers/ut_be_null.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_null under ut_matcher( +create or replace noneditionable type ut_be_null under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_true.tpb b/source/expectations/matchers/ut_be_true.tpb index 442e57d7f..59368f342 100644 --- a/source/expectations/matchers/ut_be_true.tpb +++ b/source/expectations/matchers/ut_be_true.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_true as +create or replace noneditionable type body ut_be_true as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_true.tps b/source/expectations/matchers/ut_be_true.tps index b55fa484d..19d397371 100644 --- a/source/expectations/matchers/ut_be_true.tps +++ b/source/expectations/matchers/ut_be_true.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_true under ut_matcher( +create or replace noneditionable type ut_be_true under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index f77e9feec..f8f880ace 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_within as +create or replace noneditionable type body ut_be_within as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_within.tps b/source/expectations/matchers/ut_be_within.tps index 06a685832..276c529df 100644 --- a/source/expectations/matchers/ut_be_within.tps +++ b/source/expectations/matchers/ut_be_within.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_within force under ut_be_within_pct( +create or replace noneditionable type ut_be_within force under ut_be_within_pct( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_within_helper.pkb b/source/expectations/matchers/ut_be_within_helper.pkb index 561bf230b..635c1b111 100644 --- a/source/expectations/matchers/ut_be_within_helper.pkb +++ b/source/expectations/matchers/ut_be_within_helper.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_be_within_helper as +create or replace noneditionable package body ut_be_within_helper as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_within_helper.pks b/source/expectations/matchers/ut_be_within_helper.pks index b8480e249..5a59eea9e 100644 --- a/source/expectations/matchers/ut_be_within_helper.pks +++ b/source/expectations/matchers/ut_be_within_helper.pks @@ -1,4 +1,4 @@ -create or replace package ut_be_within_helper authid definer as +create or replace noneditionable package ut_be_within_helper authid definer as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_within_pct.tpb b/source/expectations/matchers/ut_be_within_pct.tpb index ad821d72c..82ce8e84e 100644 --- a/source/expectations/matchers/ut_be_within_pct.tpb +++ b/source/expectations/matchers/ut_be_within_pct.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_be_within_pct as +create or replace noneditionable type body ut_be_within_pct as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_be_within_pct.tps b/source/expectations/matchers/ut_be_within_pct.tps index 645e9c485..810eaa5b3 100644 --- a/source/expectations/matchers/ut_be_within_pct.tps +++ b/source/expectations/matchers/ut_be_within_pct.tps @@ -1,4 +1,4 @@ -create or replace type ut_be_within_pct force under ut_comparison_matcher( +create or replace noneditionable type ut_be_within_pct force under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_comparison_matcher.tpb b/source/expectations/matchers/ut_comparison_matcher.tpb index b7cef4f59..d6c47855d 100644 --- a/source/expectations/matchers/ut_comparison_matcher.tpb +++ b/source/expectations/matchers/ut_comparison_matcher.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_comparison_matcher as +create or replace noneditionable type body ut_comparison_matcher as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_comparison_matcher.tps b/source/expectations/matchers/ut_comparison_matcher.tps index 11b46d47c..b1ed08a84 100644 --- a/source/expectations/matchers/ut_comparison_matcher.tps +++ b/source/expectations/matchers/ut_comparison_matcher.tps @@ -1,4 +1,4 @@ -create or replace type ut_comparison_matcher under ut_matcher( +create or replace noneditionable type ut_comparison_matcher under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_contain.tpb b/source/expectations/matchers/ut_contain.tpb index a8eb71ecd..bcc3806b7 100644 --- a/source/expectations/matchers/ut_contain.tpb +++ b/source/expectations/matchers/ut_contain.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_contain as +create or replace noneditionable type body ut_contain as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_contain.tps b/source/expectations/matchers/ut_contain.tps index 6d7c525c6..bd67113c9 100644 --- a/source/expectations/matchers/ut_contain.tps +++ b/source/expectations/matchers/ut_contain.tps @@ -1,4 +1,4 @@ -create or replace type ut_contain under ut_equal( +create or replace noneditionable type ut_contain under ut_equal( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_equal.tpb b/source/expectations/matchers/ut_equal.tpb index f5932b2ad..f999995d1 100644 --- a/source/expectations/matchers/ut_equal.tpb +++ b/source/expectations/matchers/ut_equal.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_equal as +create or replace noneditionable type body ut_equal as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_equal.tps b/source/expectations/matchers/ut_equal.tps index e23eaf23b..eeb715a58 100644 --- a/source/expectations/matchers/ut_equal.tps +++ b/source/expectations/matchers/ut_equal.tps @@ -1,4 +1,4 @@ -create or replace type ut_equal force under ut_comparison_matcher( +create or replace noneditionable type ut_equal force under ut_comparison_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_have_count.tpb b/source/expectations/matchers/ut_have_count.tpb index 0d4cfbcc0..f6d3d2682 100644 --- a/source/expectations/matchers/ut_have_count.tpb +++ b/source/expectations/matchers/ut_have_count.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_have_count as +create or replace noneditionable type body ut_have_count as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_have_count.tps b/source/expectations/matchers/ut_have_count.tps index bd075e8f4..85cdf4393 100644 --- a/source/expectations/matchers/ut_have_count.tps +++ b/source/expectations/matchers/ut_have_count.tps @@ -1,4 +1,4 @@ -create or replace type ut_have_count under ut_matcher( +create or replace noneditionable type ut_have_count under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_match.tpb b/source/expectations/matchers/ut_match.tpb index de645a135..1836298e7 100644 --- a/source/expectations/matchers/ut_match.tpb +++ b/source/expectations/matchers/ut_match.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_match as +create or replace noneditionable type body ut_match as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_match.tps b/source/expectations/matchers/ut_match.tps index ababff18f..3f840545f 100644 --- a/source/expectations/matchers/ut_match.tps +++ b/source/expectations/matchers/ut_match.tps @@ -1,4 +1,4 @@ -create or replace type ut_match under ut_matcher( +create or replace noneditionable type ut_match under ut_matcher( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_matcher.tpb b/source/expectations/matchers/ut_matcher.tpb index 07e082a71..828e1ac51 100644 --- a/source/expectations/matchers/ut_matcher.tpb +++ b/source/expectations/matchers/ut_matcher.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_matcher as +create or replace noneditionable type body ut_matcher as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_matcher.tps b/source/expectations/matchers/ut_matcher.tps index 2551ce003..ee7f1b5dd 100644 --- a/source/expectations/matchers/ut_matcher.tps +++ b/source/expectations/matchers/ut_matcher.tps @@ -1,4 +1,4 @@ -create or replace type ut_matcher under ut_matcher_base( +create or replace noneditionable type ut_matcher under ut_matcher_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_matcher_base.tps b/source/expectations/matchers/ut_matcher_base.tps index c6d44468d..ba79a6aed 100644 --- a/source/expectations/matchers/ut_matcher_base.tps +++ b/source/expectations/matchers/ut_matcher_base.tps @@ -1,4 +1,4 @@ -create or replace type ut_matcher_base force authid current_user as object( +create or replace noneditionable type ut_matcher_base force authid current_user as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_matcher_options.tpb b/source/expectations/matchers/ut_matcher_options.tpb index 1acb4405b..57aca2617 100644 --- a/source/expectations/matchers/ut_matcher_options.tpb +++ b/source/expectations/matchers/ut_matcher_options.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_matcher_options as +create or replace noneditionable type body ut_matcher_options as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_matcher_options.tps b/source/expectations/matchers/ut_matcher_options.tps index 835316e7c..db076fd99 100644 --- a/source/expectations/matchers/ut_matcher_options.tps +++ b/source/expectations/matchers/ut_matcher_options.tps @@ -1,4 +1,4 @@ -create or replace type ut_matcher_options authid current_user as object( +create or replace noneditionable type ut_matcher_options authid current_user as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_matcher_options_items.tpb b/source/expectations/matchers/ut_matcher_options_items.tpb index 921d3ecd2..6e4841870 100644 --- a/source/expectations/matchers/ut_matcher_options_items.tpb +++ b/source/expectations/matchers/ut_matcher_options_items.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_matcher_options_items is +create or replace noneditionable type body ut_matcher_options_items is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/matchers/ut_matcher_options_items.tps b/source/expectations/matchers/ut_matcher_options_items.tps index 73c2bb92d..045a7ece7 100644 --- a/source/expectations/matchers/ut_matcher_options_items.tps +++ b/source/expectations/matchers/ut_matcher_options_items.tps @@ -1,4 +1,4 @@ -create or replace type ut_matcher_options_items authid current_user as object( +create or replace noneditionable type ut_matcher_options_items authid current_user as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index 12aef603a..5f7c9cce0 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_expectation as +create or replace noneditionable type body ut_expectation as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index b015a95a7..a423c39a4 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation force under ut_expectation_base( +create or replace noneditionable type ut_expectation force under ut_expectation_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/ut_expectation_base.tpb b/source/expectations/ut_expectation_base.tpb index 3d6e9b469..5ed630c63 100644 --- a/source/expectations/ut_expectation_base.tpb +++ b/source/expectations/ut_expectation_base.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_expectation_base as +create or replace noneditionable type body ut_expectation_base as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/ut_expectation_base.tps b/source/expectations/ut_expectation_base.tps index 24e180b92..86f274495 100644 --- a/source/expectations/ut_expectation_base.tps +++ b/source/expectations/ut_expectation_base.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation_base authid current_user as object( +create or replace noneditionable type ut_expectation_base authid current_user as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index 1131885b0..d76010f80 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_expectation_compound as +create or replace noneditionable type body ut_expectation_compound as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index ebf534222..54de48dd4 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation_compound under ut_expectation( +create or replace noneditionable type ut_expectation_compound under ut_expectation( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/ut_expectation_json.tpb b/source/expectations/ut_expectation_json.tpb index 90a3a3d31..68d4085ef 100644 --- a/source/expectations/ut_expectation_json.tpb +++ b/source/expectations/ut_expectation_json.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_expectation_json as +create or replace noneditionable type body ut_expectation_json as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/expectations/ut_expectation_json.tps b/source/expectations/ut_expectation_json.tps index d873cc99c..c75154bc8 100644 --- a/source/expectations/ut_expectation_json.tps +++ b/source/expectations/ut_expectation_json.tps @@ -1,4 +1,4 @@ -create or replace type ut_expectation_json under ut_expectation( +create or replace noneditionable type ut_expectation_json under ut_expectation( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_ansiconsole_helper.pkb b/source/reporters/ut_ansiconsole_helper.pkb index 46960cf5c..e8ee34531 100644 --- a/source/reporters/ut_ansiconsole_helper.pkb +++ b/source/reporters/ut_ansiconsole_helper.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_ansiconsole_helper as +create or replace noneditionable package body ut_ansiconsole_helper as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_ansiconsole_helper.pks b/source/reporters/ut_ansiconsole_helper.pks index fd4549965..e882de293 100644 --- a/source/reporters/ut_ansiconsole_helper.pks +++ b/source/reporters/ut_ansiconsole_helper.pks @@ -1,4 +1,4 @@ -create or replace package ut_ansiconsole_helper as +create or replace noneditionable package ut_ansiconsole_helper as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index 833ca09be..45c1935b1 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_coverage_cobertura_reporter is +create or replace noneditionable type body ut_coverage_cobertura_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coverage_cobertura_reporter.tps b/source/reporters/ut_coverage_cobertura_reporter.tps index ee2d9b71d..799840a55 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tps +++ b/source/reporters/ut_coverage_cobertura_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_coverage_cobertura_reporter under ut_coverage_reporter_base( +create or replace noneditionable type ut_coverage_cobertura_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coverage_html_reporter.tpb b/source/reporters/ut_coverage_html_reporter.tpb index 253c067e5..90419371a 100644 --- a/source/reporters/ut_coverage_html_reporter.tpb +++ b/source/reporters/ut_coverage_html_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_coverage_html_reporter is +create or replace noneditionable type body ut_coverage_html_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coverage_html_reporter.tps b/source/reporters/ut_coverage_html_reporter.tps index db65e1e00..23cf45c0b 100644 --- a/source/reporters/ut_coverage_html_reporter.tps +++ b/source/reporters/ut_coverage_html_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_coverage_html_reporter under ut_coverage_reporter_base( +create or replace noneditionable type ut_coverage_html_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index d81211f03..99c36ab73 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_coverage_report_html_helper is +create or replace noneditionable package body ut_coverage_report_html_helper is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coverage_report_html_helper.pks b/source/reporters/ut_coverage_report_html_helper.pks index c028168a8..8463e3e89 100644 --- a/source/reporters/ut_coverage_report_html_helper.pks +++ b/source/reporters/ut_coverage_report_html_helper.pks @@ -1,4 +1,4 @@ -create or replace package ut_coverage_report_html_helper authid current_user is +create or replace noneditionable package ut_coverage_report_html_helper authid current_user is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coverage_sonar_reporter.tpb b/source/reporters/ut_coverage_sonar_reporter.tpb index 8148fc7fc..a070572b7 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tpb +++ b/source/reporters/ut_coverage_sonar_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_coverage_sonar_reporter is +create or replace noneditionable type body ut_coverage_sonar_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coverage_sonar_reporter.tps b/source/reporters/ut_coverage_sonar_reporter.tps index b5e964a3a..fd160bdb5 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tps +++ b/source/reporters/ut_coverage_sonar_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_coverage_sonar_reporter under ut_coverage_reporter_base( +create or replace noneditionable type ut_coverage_sonar_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coveralls_reporter.tpb b/source/reporters/ut_coveralls_reporter.tpb index fc459c906..8d8884878 100644 --- a/source/reporters/ut_coveralls_reporter.tpb +++ b/source/reporters/ut_coveralls_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_coveralls_reporter is +create or replace noneditionable type body ut_coveralls_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_coveralls_reporter.tps b/source/reporters/ut_coveralls_reporter.tps index e547793d1..8518891d5 100644 --- a/source/reporters/ut_coveralls_reporter.tps +++ b/source/reporters/ut_coveralls_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_coveralls_reporter under ut_coverage_reporter_base( +create or replace noneditionable type ut_coveralls_reporter under ut_coverage_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_debug_reporter.tpb b/source/reporters/ut_debug_reporter.tpb index b17f039ea..547437cde 100644 --- a/source/reporters/ut_debug_reporter.tpb +++ b/source/reporters/ut_debug_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_debug_reporter is +create or replace noneditionable type body ut_debug_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_debug_reporter.tps b/source/reporters/ut_debug_reporter.tps index 85c0eeb54..edbf1cdc6 100644 --- a/source/reporters/ut_debug_reporter.tps +++ b/source/reporters/ut_debug_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_debug_reporter under ut_output_reporter_base( +create or replace noneditionable type ut_debug_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_documentation_reporter.tpb b/source/reporters/ut_documentation_reporter.tpb index 489b6efd2..83152ea1c 100644 --- a/source/reporters/ut_documentation_reporter.tpb +++ b/source/reporters/ut_documentation_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_documentation_reporter is +create or replace noneditionable type body ut_documentation_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_documentation_reporter.tps b/source/reporters/ut_documentation_reporter.tps index 23b86226f..bab9082c6 100644 --- a/source/reporters/ut_documentation_reporter.tps +++ b/source/reporters/ut_documentation_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_documentation_reporter under ut_console_reporter_base( +create or replace noneditionable type ut_documentation_reporter under ut_console_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_junit_reporter.tpb b/source/reporters/ut_junit_reporter.tpb index a2cffd287..bf62dc564 100644 --- a/source/reporters/ut_junit_reporter.tpb +++ b/source/reporters/ut_junit_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_junit_reporter is +create or replace noneditionable type body ut_junit_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_junit_reporter.tps b/source/reporters/ut_junit_reporter.tps index 5999c33f5..a20913980 100644 --- a/source/reporters/ut_junit_reporter.tps +++ b/source/reporters/ut_junit_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_junit_reporter force under ut_output_reporter_base( +create or replace noneditionable type ut_junit_reporter force under ut_output_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_realtime_reporter.tpb b/source/reporters/ut_realtime_reporter.tpb index fac7cd9b8..a8b7c566e 100644 --- a/source/reporters/ut_realtime_reporter.tpb +++ b/source/reporters/ut_realtime_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_realtime_reporter is +create or replace noneditionable type body ut_realtime_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_realtime_reporter.tps b/source/reporters/ut_realtime_reporter.tps index 5ab350162..b8686685b 100644 --- a/source/reporters/ut_realtime_reporter.tps +++ b/source/reporters/ut_realtime_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_realtime_reporter force under ut_output_reporter_base( +create or replace noneditionable type ut_realtime_reporter force under ut_output_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_sonar_test_reporter.tpb b/source/reporters/ut_sonar_test_reporter.tpb index dfa6a7421..da29b629d 100644 --- a/source/reporters/ut_sonar_test_reporter.tpb +++ b/source/reporters/ut_sonar_test_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_sonar_test_reporter is +create or replace noneditionable type body ut_sonar_test_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_sonar_test_reporter.tps b/source/reporters/ut_sonar_test_reporter.tps index d9f98071d..0884ad3d3 100644 --- a/source/reporters/ut_sonar_test_reporter.tps +++ b/source/reporters/ut_sonar_test_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_sonar_test_reporter under ut_output_reporter_base( +create or replace noneditionable type ut_sonar_test_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index c591c19f8..c807ab3e1 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_tap_reporter is +create or replace noneditionable type body ut_tap_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_tap_reporter.tps b/source/reporters/ut_tap_reporter.tps index 94423b6fc..150486648 100644 --- a/source/reporters/ut_tap_reporter.tps +++ b/source/reporters/ut_tap_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_tap_reporter under ut_documentation_reporter( +create or replace noneditionable type ut_tap_reporter under ut_documentation_reporter( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_teamcity_reporter.tpb b/source/reporters/ut_teamcity_reporter.tpb index 2e09c7103..94d5497d5 100644 --- a/source/reporters/ut_teamcity_reporter.tpb +++ b/source/reporters/ut_teamcity_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_teamcity_reporter is +create or replace noneditionable type body ut_teamcity_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_teamcity_reporter.tps b/source/reporters/ut_teamcity_reporter.tps index e5c43b59e..2def91c35 100644 --- a/source/reporters/ut_teamcity_reporter.tps +++ b/source/reporters/ut_teamcity_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_teamcity_reporter under ut_output_reporter_base( +create or replace noneditionable type ut_teamcity_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_teamcity_reporter_helper.pkb b/source/reporters/ut_teamcity_reporter_helper.pkb index 575af645d..1d33c43ae 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pkb +++ b/source/reporters/ut_teamcity_reporter_helper.pkb @@ -1,4 +1,4 @@ -create or replace package body ut_teamcity_reporter_helper is +create or replace noneditionable package body ut_teamcity_reporter_helper is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_teamcity_reporter_helper.pks b/source/reporters/ut_teamcity_reporter_helper.pks index 727d02913..bb9acef35 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pks +++ b/source/reporters/ut_teamcity_reporter_helper.pks @@ -1,4 +1,4 @@ -create or replace package ut_teamcity_reporter_helper is +create or replace noneditionable package ut_teamcity_reporter_helper is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_tfs_junit_reporter.tpb b/source/reporters/ut_tfs_junit_reporter.tpb index 8c2bd6333..5e24b2dca 100644 --- a/source/reporters/ut_tfs_junit_reporter.tpb +++ b/source/reporters/ut_tfs_junit_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_tfs_junit_reporter is +create or replace noneditionable type body ut_tfs_junit_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_tfs_junit_reporter.tps b/source/reporters/ut_tfs_junit_reporter.tps index 3af2226a5..560bb10dd 100644 --- a/source/reporters/ut_tfs_junit_reporter.tps +++ b/source/reporters/ut_tfs_junit_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_tfs_junit_reporter under ut_output_reporter_base( +create or replace noneditionable type ut_tfs_junit_reporter under ut_output_reporter_base( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_xunit_reporter.tpb b/source/reporters/ut_xunit_reporter.tpb index 164703917..74fc57ac0 100644 --- a/source/reporters/ut_xunit_reporter.tpb +++ b/source/reporters/ut_xunit_reporter.tpb @@ -1,4 +1,4 @@ -create or replace type body ut_xunit_reporter is +create or replace noneditionable type body ut_xunit_reporter is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/reporters/ut_xunit_reporter.tps b/source/reporters/ut_xunit_reporter.tps index 970e4d162..d701d8ab0 100644 --- a/source/reporters/ut_xunit_reporter.tps +++ b/source/reporters/ut_xunit_reporter.tps @@ -1,4 +1,4 @@ -create or replace type ut_xunit_reporter under ut_junit_reporter( +create or replace noneditionable type ut_xunit_reporter under ut_junit_reporter( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project From 98a6b3bf8b3e223df81845c6f54515e47d88cd34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 7 Jun 2026 12:36:09 +0300 Subject: [PATCH 681/887] Fixed failing test case --- test/ut3_user/reporters/test_tfs_junit_reporter.pkb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/ut3_user/reporters/test_tfs_junit_reporter.pkb b/test/ut3_user/reporters/test_tfs_junit_reporter.pkb index 1036be2ba..105517763 100644 --- a/test/ut3_user/reporters/test_tfs_junit_reporter.pkb +++ b/test/ut3_user/reporters/test_tfs_junit_reporter.pkb @@ -100,7 +100,7 @@ create or replace package body test_tfs_junit_reporter as --%displayname(Test in and out of context) -- %context(incontext) - -- %name(ProductincontextFeatures) + -- %name(Production_context_Features) --%test(inctx) --%displayname(inctx) @@ -298,7 +298,7 @@ create or replace package body test_tfs_junit_reporter as - + From fc00ada2d2087af7dff0b0ad43a7ec327cea9307 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 7 Jun 2026 12:39:31 +0300 Subject: [PATCH 682/887] Fixed incorrect code replacement --- source/core/annotations/ut_annotated_object.tps | 2 +- source/core/annotations/ut_annotated_objects.tps | 2 +- source/core/annotations/ut_annotation.tps | 2 +- source/core/annotations/ut_annotation_obj_cache_info.tps | 2 +- source/core/annotations/ut_annotation_objs_cache_info.tps | 2 +- source/core/annotations/ut_annotations.tps | 2 +- source/core/types/ut_suite_cache_rows.tps | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/source/core/annotations/ut_annotated_object.tps b/source/core/annotations/ut_annotated_object.tps index facc8d2d8..ca327d7fc 100644 --- a/source/core/annotations/ut_annotated_object.tps +++ b/source/core/annotations/ut_annotated_object.tps @@ -1,4 +1,4 @@ -create or replace noneditionable type( )ut_annotated_object as object( +create or replace noneditionable type ut_annotated_object as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotated_objects.tps b/source/core/annotations/ut_annotated_objects.tps index e86f102c9..2b338e7d9 100644 --- a/source/core/annotations/ut_annotated_objects.tps +++ b/source/core/annotations/ut_annotated_objects.tps @@ -1,4 +1,4 @@ -create or replace noneditionable type( )ut_annotated_objects as +create or replace noneditionable type ut_annotated_objects as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation.tps b/source/core/annotations/ut_annotation.tps index a6889540f..cc1f90e86 100644 --- a/source/core/annotations/ut_annotation.tps +++ b/source/core/annotations/ut_annotation.tps @@ -1,4 +1,4 @@ -create or replace noneditionable type( )ut_annotation as object( +create or replace noneditionable type ut_annotation as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_obj_cache_info.tps b/source/core/annotations/ut_annotation_obj_cache_info.tps index 9e0f3aa71..5436a11ed 100644 --- a/source/core/annotations/ut_annotation_obj_cache_info.tps +++ b/source/core/annotations/ut_annotation_obj_cache_info.tps @@ -1,4 +1,4 @@ -create or replace noneditionable type( )ut_annotation_obj_cache_info as object( +create or replace noneditionable type ut_annotation_obj_cache_info as object( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotation_objs_cache_info.tps b/source/core/annotations/ut_annotation_objs_cache_info.tps index f6b5ea20d..c29b7d208 100644 --- a/source/core/annotations/ut_annotation_objs_cache_info.tps +++ b/source/core/annotations/ut_annotation_objs_cache_info.tps @@ -1,4 +1,4 @@ -create or replace noneditionable type( )ut_annotation_objs_cache_info as +create or replace noneditionable type ut_annotation_objs_cache_info as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/annotations/ut_annotations.tps b/source/core/annotations/ut_annotations.tps index dd5b79e71..9e4adc5ae 100644 --- a/source/core/annotations/ut_annotations.tps +++ b/source/core/annotations/ut_annotations.tps @@ -1,4 +1,4 @@ -create or replace noneditionable type( )ut_annotations +create or replace noneditionable type ut_annotations /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project diff --git a/source/core/types/ut_suite_cache_rows.tps b/source/core/types/ut_suite_cache_rows.tps index b201e7bf0..84bcc9f75 100644 --- a/source/core/types/ut_suite_cache_rows.tps +++ b/source/core/types/ut_suite_cache_rows.tps @@ -1,4 +1,4 @@ -create or replace noneditionable type( )ut_suite_cache_rows as +create or replace noneditionable type ut_suite_cache_rows as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project From 3dcd837c48424ad120682bae8e5758cd6d090d51 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 7 Jun 2026 12:58:05 +0300 Subject: [PATCH 683/887] Fixed incorrect code replacement --- source/core/annotations/ut_trigger_check.pkb | 2 +- source/create_synonyms.sql | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/source/core/annotations/ut_trigger_check.pkb b/source/core/annotations/ut_trigger_check.pkb index da8f98949..463243c5e 100644 --- a/source/core/annotations/ut_trigger_check.pkb +++ b/source/core/annotations/ut_trigger_check.pkb @@ -22,7 +22,7 @@ create or replace noneditionable package body ut_trigger_check is function is_alive return boolean is pragma autonomous_transaction; begin - execute immediate 'create or replace synonym '||ut_utils.ut_owner||'.'||gc_check_object_name||' for no_object'; + execute immediate 'create or replace noneditionable synonym '||ut_utils.ut_owner||'.'||gc_check_object_name||' for no_object'; return g_is_trigger_live; end; diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index 3cc642921..242bd6d61 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -36,10 +36,10 @@ set termout off spool params.sql.tmp select case - when upper('&&ut3_user') = 'PUBLIC' then q'[define action_type='or replace public' + when upper('&&ut3_user') = 'PUBLIC' then q'[define action_type='or replace noneditionable public' ]'||q'[define ut3_user='' ]'||q'[define grantee='PUBLIC']' - else q'[define action_type='or replace' + else q'[define action_type='or replace noneditionable' ]'||q'[define grantee='&&ut3_user'] ]'||q'[define ut3_user='&&ut3_user..']' end From b876dd060b211f22e32351804515b5551acbbb91 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 7 Jun 2026 11:05:36 +0100 Subject: [PATCH 684/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 17151eb01..0129b6375 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4447 +4458 diff --git a/docs/about/authors.md b/docs/about/authors.md index 812b0c6c1..7eadabde4 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 76f712192..0459d0f20 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index bb6dd6380..281c38375 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 576fbf445..d323b17e0 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 2307868ba..86e6349a4 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 010ceb7d2..3f7bc74ef 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index af36ac0ae..8a5f0e2c6 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index f9b363977..4087b53f8 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 329528134..ad9e885c2 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 67a15719b..75fd2ad98 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 99a4958d6..cb3fc7207 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 446571936..550a7af23 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 48513cbb6..7bb410a9e 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index a6c8d37b4..a4904aa3a 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3752137cd..cc048e66a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index f5efb4298..f386c2ef0 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 4ca5ec270..2369c6549 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4447--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 7cffd26e8..89dad120f 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4447-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4458-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From a0620688dcc03bf011ab4d96fd9e08839b85f6f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 7 Jun 2026 13:09:51 +0300 Subject: [PATCH 685/887] Fixed incorrect code replacement --- source/api/be_between.syn | 2 +- source/api/be_empty.syn | 2 +- source/api/be_false.syn | 2 +- source/api/be_greater_or_equal.syn | 2 +- source/api/be_greater_than.syn | 2 +- source/api/be_less_or_equal.syn | 2 +- source/api/be_less_than.syn | 2 +- source/api/be_like.syn | 2 +- source/api/be_not_null.syn | 2 +- source/api/be_null.syn | 2 +- source/api/be_true.syn | 2 +- source/api/be_within.syn | 2 +- source/api/be_within_pct.syn | 2 +- source/api/contain.syn | 2 +- source/api/equal.syn | 2 +- source/api/have_count.syn | 2 +- source/api/match.syn | 2 +- 17 files changed, 17 insertions(+), 17 deletions(-) diff --git a/source/api/be_between.syn b/source/api/be_between.syn index c0972595d..013800746 100644 --- a/source/api/be_between.syn +++ b/source/api/be_between.syn @@ -1 +1 @@ -create synonym be_between for ut_be_between; +create noneditionable synonymbe_between for ut_be_between; diff --git a/source/api/be_empty.syn b/source/api/be_empty.syn index a8e28de6e..1b478188d 100644 --- a/source/api/be_empty.syn +++ b/source/api/be_empty.syn @@ -1 +1 @@ -create synonym be_empty for ut_be_empty; +create noneditionable synonymbe_empty for ut_be_empty; diff --git a/source/api/be_false.syn b/source/api/be_false.syn index c2665bbcb..0cca7fd90 100644 --- a/source/api/be_false.syn +++ b/source/api/be_false.syn @@ -1 +1 @@ -create synonym be_false for ut_be_false; +create noneditionable synonymbe_false for ut_be_false; diff --git a/source/api/be_greater_or_equal.syn b/source/api/be_greater_or_equal.syn index 386fe7f32..98103ab9f 100644 --- a/source/api/be_greater_or_equal.syn +++ b/source/api/be_greater_or_equal.syn @@ -1 +1 @@ -create synonym be_greater_or_equal for ut_be_greater_or_equal; +create noneditionable synonymbe_greater_or_equal for ut_be_greater_or_equal; diff --git a/source/api/be_greater_than.syn b/source/api/be_greater_than.syn index 6f97b7d22..2ac4f387a 100644 --- a/source/api/be_greater_than.syn +++ b/source/api/be_greater_than.syn @@ -1 +1 @@ -create synonym be_greater_than for ut_be_greater_than; +create noneditionable synonymbe_greater_than for ut_be_greater_than; diff --git a/source/api/be_less_or_equal.syn b/source/api/be_less_or_equal.syn index b2f836144..acde22516 100644 --- a/source/api/be_less_or_equal.syn +++ b/source/api/be_less_or_equal.syn @@ -1 +1 @@ -create synonym be_less_or_equal for ut_be_less_or_equal; +create noneditionable synonymbe_less_or_equal for ut_be_less_or_equal; diff --git a/source/api/be_less_than.syn b/source/api/be_less_than.syn index fbef3b4c3..38b940e10 100644 --- a/source/api/be_less_than.syn +++ b/source/api/be_less_than.syn @@ -1 +1 @@ -create synonym be_less_than for ut_be_less_than; +create noneditionable synonymbe_less_than for ut_be_less_than; diff --git a/source/api/be_like.syn b/source/api/be_like.syn index a8be1de71..cb1704c94 100644 --- a/source/api/be_like.syn +++ b/source/api/be_like.syn @@ -1 +1 @@ -create synonym be_like for ut_be_like; +create noneditionable synonymbe_like for ut_be_like; diff --git a/source/api/be_not_null.syn b/source/api/be_not_null.syn index d6458683a..f9ef61db3 100644 --- a/source/api/be_not_null.syn +++ b/source/api/be_not_null.syn @@ -1 +1 @@ -create synonym be_not_null for ut_be_not_null; +create noneditionable synonymbe_not_null for ut_be_not_null; diff --git a/source/api/be_null.syn b/source/api/be_null.syn index 42f6516c3..c3eff86c2 100644 --- a/source/api/be_null.syn +++ b/source/api/be_null.syn @@ -1 +1 @@ -create synonym be_null for ut_be_null; +create noneditionable synonymbe_null for ut_be_null; diff --git a/source/api/be_true.syn b/source/api/be_true.syn index bf7392a62..ecf3689ca 100644 --- a/source/api/be_true.syn +++ b/source/api/be_true.syn @@ -1 +1 @@ -create synonym be_true for ut_be_true; +create noneditionable synonymbe_true for ut_be_true; diff --git a/source/api/be_within.syn b/source/api/be_within.syn index e00005bb7..5790de956 100644 --- a/source/api/be_within.syn +++ b/source/api/be_within.syn @@ -1 +1 @@ -create synonym be_within for ut_be_within; +create noneditionable synonymbe_within for ut_be_within; diff --git a/source/api/be_within_pct.syn b/source/api/be_within_pct.syn index 40e3fb8b9..d954159d6 100644 --- a/source/api/be_within_pct.syn +++ b/source/api/be_within_pct.syn @@ -1 +1 @@ -create synonym be_within_pct for ut_be_within_pct; +create noneditionable synonymbe_within_pct for ut_be_within_pct; diff --git a/source/api/contain.syn b/source/api/contain.syn index 5bce7d1d2..0ba68f801 100644 --- a/source/api/contain.syn +++ b/source/api/contain.syn @@ -1 +1 @@ -create synonym contain for ut_contain; +create noneditionable synonymcontain for ut_contain; diff --git a/source/api/equal.syn b/source/api/equal.syn index 71ba58b53..344be182d 100644 --- a/source/api/equal.syn +++ b/source/api/equal.syn @@ -1 +1 @@ -create synonym equal for ut_equal; +create noneditionable synonymequal for ut_equal; diff --git a/source/api/have_count.syn b/source/api/have_count.syn index a406d47ec..9a2b0b60b 100644 --- a/source/api/have_count.syn +++ b/source/api/have_count.syn @@ -1 +1 @@ -create synonym have_count for ut_have_count; +create noneditionable synonymhave_count for ut_have_count; diff --git a/source/api/match.syn b/source/api/match.syn index ffbda35b1..2ed12ff41 100644 --- a/source/api/match.syn +++ b/source/api/match.syn @@ -1 +1 @@ -create synonym match for ut_match; +create noneditionable synonymmatch for ut_match; From 92a0c8173f283dd29001658f4d3460d0ea20ab1b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 7 Jun 2026 13:14:48 +0300 Subject: [PATCH 686/887] Fixed incorrect code replacement --- source/api/contain.syn | 2 +- source/api/equal.syn | 2 +- source/api/match.syn | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/source/api/contain.syn b/source/api/contain.syn index 0ba68f801..5b4158635 100644 --- a/source/api/contain.syn +++ b/source/api/contain.syn @@ -1 +1 @@ -create noneditionable synonymcontain for ut_contain; +create noneditionable synonym contain for ut_contain; diff --git a/source/api/equal.syn b/source/api/equal.syn index 344be182d..0d81fcf6f 100644 --- a/source/api/equal.syn +++ b/source/api/equal.syn @@ -1 +1 @@ -create noneditionable synonymequal for ut_equal; +create noneditionable synonym equal for ut_equal; diff --git a/source/api/match.syn b/source/api/match.syn index 2ed12ff41..13e8cc97d 100644 --- a/source/api/match.syn +++ b/source/api/match.syn @@ -1 +1 @@ -create noneditionable synonymmatch for ut_match; +create noneditionable synonym match for ut_match; From 3e061f8a1e220db01d207ea232adf7f566e4ce4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 7 Jun 2026 13:16:08 +0300 Subject: [PATCH 687/887] Fixed incorrect code replacement --- source/api/be_between.syn | 2 +- source/api/be_empty.syn | 2 +- source/api/be_false.syn | 2 +- source/api/be_greater_or_equal.syn | 2 +- source/api/be_greater_than.syn | 2 +- source/api/be_less_or_equal.syn | 2 +- source/api/be_less_than.syn | 2 +- source/api/be_like.syn | 2 +- source/api/be_not_null.syn | 2 +- source/api/be_null.syn | 2 +- source/api/be_true.syn | 2 +- source/api/be_within.syn | 2 +- source/api/be_within_pct.syn | 2 +- source/api/have_count.syn | 2 +- 14 files changed, 14 insertions(+), 14 deletions(-) diff --git a/source/api/be_between.syn b/source/api/be_between.syn index 013800746..233dd65bf 100644 --- a/source/api/be_between.syn +++ b/source/api/be_between.syn @@ -1 +1 @@ -create noneditionable synonymbe_between for ut_be_between; +create noneditionable synonym be_between for ut_be_between; diff --git a/source/api/be_empty.syn b/source/api/be_empty.syn index 1b478188d..f63366fa3 100644 --- a/source/api/be_empty.syn +++ b/source/api/be_empty.syn @@ -1 +1 @@ -create noneditionable synonymbe_empty for ut_be_empty; +create noneditionable synonym be_empty for ut_be_empty; diff --git a/source/api/be_false.syn b/source/api/be_false.syn index 0cca7fd90..cdf497235 100644 --- a/source/api/be_false.syn +++ b/source/api/be_false.syn @@ -1 +1 @@ -create noneditionable synonymbe_false for ut_be_false; +create noneditionable synonym be_false for ut_be_false; diff --git a/source/api/be_greater_or_equal.syn b/source/api/be_greater_or_equal.syn index 98103ab9f..67616dc1d 100644 --- a/source/api/be_greater_or_equal.syn +++ b/source/api/be_greater_or_equal.syn @@ -1 +1 @@ -create noneditionable synonymbe_greater_or_equal for ut_be_greater_or_equal; +create noneditionable synonym be_greater_or_equal for ut_be_greater_or_equal; diff --git a/source/api/be_greater_than.syn b/source/api/be_greater_than.syn index 2ac4f387a..c180f3d43 100644 --- a/source/api/be_greater_than.syn +++ b/source/api/be_greater_than.syn @@ -1 +1 @@ -create noneditionable synonymbe_greater_than for ut_be_greater_than; +create noneditionable synonym be_greater_than for ut_be_greater_than; diff --git a/source/api/be_less_or_equal.syn b/source/api/be_less_or_equal.syn index acde22516..0069f52ba 100644 --- a/source/api/be_less_or_equal.syn +++ b/source/api/be_less_or_equal.syn @@ -1 +1 @@ -create noneditionable synonymbe_less_or_equal for ut_be_less_or_equal; +create noneditionable synonym be_less_or_equal for ut_be_less_or_equal; diff --git a/source/api/be_less_than.syn b/source/api/be_less_than.syn index 38b940e10..5d2766d05 100644 --- a/source/api/be_less_than.syn +++ b/source/api/be_less_than.syn @@ -1 +1 @@ -create noneditionable synonymbe_less_than for ut_be_less_than; +create noneditionable synonym be_less_than for ut_be_less_than; diff --git a/source/api/be_like.syn b/source/api/be_like.syn index cb1704c94..6f62f21a0 100644 --- a/source/api/be_like.syn +++ b/source/api/be_like.syn @@ -1 +1 @@ -create noneditionable synonymbe_like for ut_be_like; +create noneditionable synonym be_like for ut_be_like; diff --git a/source/api/be_not_null.syn b/source/api/be_not_null.syn index f9ef61db3..a9e02b94d 100644 --- a/source/api/be_not_null.syn +++ b/source/api/be_not_null.syn @@ -1 +1 @@ -create noneditionable synonymbe_not_null for ut_be_not_null; +create noneditionable synonym be_not_null for ut_be_not_null; diff --git a/source/api/be_null.syn b/source/api/be_null.syn index c3eff86c2..4fe3fb9dd 100644 --- a/source/api/be_null.syn +++ b/source/api/be_null.syn @@ -1 +1 @@ -create noneditionable synonymbe_null for ut_be_null; +create noneditionable synonym be_null for ut_be_null; diff --git a/source/api/be_true.syn b/source/api/be_true.syn index ecf3689ca..1aa348c7e 100644 --- a/source/api/be_true.syn +++ b/source/api/be_true.syn @@ -1 +1 @@ -create noneditionable synonymbe_true for ut_be_true; +create noneditionable synonym be_true for ut_be_true; diff --git a/source/api/be_within.syn b/source/api/be_within.syn index 5790de956..4f4f77606 100644 --- a/source/api/be_within.syn +++ b/source/api/be_within.syn @@ -1 +1 @@ -create noneditionable synonymbe_within for ut_be_within; +create noneditionable synonym be_within for ut_be_within; diff --git a/source/api/be_within_pct.syn b/source/api/be_within_pct.syn index d954159d6..b9fc1cd53 100644 --- a/source/api/be_within_pct.syn +++ b/source/api/be_within_pct.syn @@ -1 +1 @@ -create noneditionable synonymbe_within_pct for ut_be_within_pct; +create noneditionable synonym be_within_pct for ut_be_within_pct; diff --git a/source/api/have_count.syn b/source/api/have_count.syn index 9a2b0b60b..9cbf8ebf2 100644 --- a/source/api/have_count.syn +++ b/source/api/have_count.syn @@ -1 +1 @@ -create noneditionable synonymhave_count for ut_have_count; +create noneditionable synonym have_count for ut_have_count; From 248899eb1d39e26739ecd16822f429390bd60538 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 7 Jun 2026 21:22:57 +0100 Subject: [PATCH 688/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 0129b6375..b8a6cc71b 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4458 +4465 diff --git a/docs/about/authors.md b/docs/about/authors.md index 7eadabde4..4415412f8 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 0459d0f20..f66476bcf 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 281c38375..766e0fd19 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index d323b17e0..cc8c5ef88 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 86e6349a4..2a91d52f0 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 3f7bc74ef..18461cf71 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 8a5f0e2c6..d650151f8 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 4087b53f8..424fce7e0 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index ad9e885c2..c428616fd 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 75fd2ad98..06d340418 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index cb3fc7207..afd2a2abd 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 550a7af23..6ec273ffb 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 7bb410a9e..ae5b0a622 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index a4904aa3a..ab2a552ac 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index cc048e66a..f71bd504a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index f386c2ef0..c106bc198 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 2369c6549..210871e4e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4458--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 358ed9b50..0df784d4a 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4458-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4465-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 193f6103ce5b7483db32e025148409725a7abe6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 7 Jun 2026 23:29:12 +0300 Subject: [PATCH 689/887] Removed coveralls reporter Resolves: 1172 --- docs/compare_version2_to_3.md | 1 - docs/userguide/coverage.md | 7 +- readme.md | 2 +- source/create_grants.sql | 1 - source/create_synonyms.sql | 1 - source/install.sql | 2 - source/reporters/ut_coveralls_reporter.tpb | 104 ------------------ source/reporters/ut_coveralls_reporter.tps | 31 ------ source/uninstall_objects.sql | 2 - test/run_tests.sh | 1 - test/ut3_user/api/test_ut_runner.pkb | 1 - .../test_coverage/test_coveralls_reporter.pkb | 77 ------------- .../test_coverage/test_coveralls_reporter.pks | 13 --- 13 files changed, 4 insertions(+), 239 deletions(-) delete mode 100644 source/reporters/ut_coveralls_reporter.tpb delete mode 100644 source/reporters/ut_coveralls_reporter.tps delete mode 100644 test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb delete mode 100644 test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pks diff --git a/docs/compare_version2_to_3.md b/docs/compare_version2_to_3.md index 5f53e41d4..121fafc59 100644 --- a/docs/compare_version2_to_3.md +++ b/docs/compare_version2_to_3.md @@ -37,7 +37,6 @@ There is a [migration tool](https://github.com/utPLSQL/utPLSQL-v2-v3-migration) | **Code Coverage Reporting** | No | Yes | | Html Coverage Report | No | Yes | | Sonar XML Coverage Report | No | Yes | -| Coveralls Json Coverage Report | No | Yes | | Framework Transaction Control | No | Yes - Annotations1 | | **Test Output** | | | | Real-time test execution progress reporting | No | Yes | diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index c428616fd..7c196aece 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -22,7 +22,6 @@ To obtain information about code coverage for unit tests, run utPLSQL with one o The following code coverage reporters are supplied with utPLSQL: * `ut_coverage_html_reporter` - generates a HTML coverage report providing summary and detailed information on code coverage. The HTML reporter is based on the open-source [simplecov-html](https://github.com/colszowka/simplecov-html) reporter for Ruby. It includes source code of the code that was covered (if the code is accessible for test user) -* `ut_coveralls_reporter` - generates a [Coveralls compatible JSON](https://coveralls.zendesk.com/hc/en-us/articles/201774865-API-Introduction) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by cloud services like [Coveralls](https://coveralls.io) * `ut_coverage_sonar_reporter` - generates a [Sonar Compatible XML](https://docs.sonarqube.org/latest/analysis/generic-test/) coverage report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by services like [SonarQube](https://www.sonarqube.org/) and [SonarCloud](https://about.sonarcloud.io/) * `ut_coverage_cobertura_reporter` - generates a basic Cobertura coverage (http://cobertura.sourceforge.net/xml/coverage-04.dtd) report providing detailed information on code coverage with line numbers. This coverage report is designed to be consumed by services like TFS and Jenkins. Check this link for an example of XML generated by Java: https://raw.githubusercontent.com/jenkinsci/cobertura-plugin/master/src/test/resources/hudson/plugins/cobertura/coverage-with-data.xml @@ -310,9 +309,9 @@ Executes test `test_award_bonus` in schema `unit_test_schema`. Coverage will be ### Project based Coverage -utPLSQL provides reporters that produce reports consumable by external tools like `Sonar`/`SonarCloud` & `Coveralls`. +utPLSQL provides reporters that produce reports consumable by external tools like `Sonar`/`SonarCloud`. -Services like Sonar, Coveralls and others perform analysis based on source code in project files. +Services like Sonar and others perform analysis based on source code in project files. They are abstracted from database, schema names, packages, procedures and functions, and operate on a more generic concept of project source code. To be able to effectively use reporters dedicated for those tools, utPLSQL provides functionality for mapping database object names to project files. @@ -320,7 +319,7 @@ To be able to effectively use reporters dedicated for those tools, utPLSQL provi There are a few significant differences when running coverage on project files compared to running coverage on schema(s). - Coverage is only reported on objects that were successfully mapped to project files. -- Project files (database objects) that were not executed at all are not reported as fully uncovered. It is up to the consumer (Sonar/Coveralls) to determine if project file should be considered as 0% coverage or just ignored. +- Project files (database objects) that were not executed at all are not reported as fully uncovered. It is up to the consumer (Sonar) to determine if project file should be considered as 0% coverage or just ignored. In order to successfully use coverage on project files, those files must be mapped to database objects. diff --git a/readme.md b/readme.md index 7af2183c5..bba640d17 100644 --- a/readme.md +++ b/readme.md @@ -19,7 +19,7 @@ utPLSQL is a unit testing framework for Oracle PL/SQL and SQL, following industr - Hierarchies of test suites configured with annotations - Automatic (configurable) transaction control - Built-in [coverage](docs/userguide/coverage.md) reporting -- Integration with SonarQube, Coveralls, Jenkins and TeamCity via [reporters](docs/userguide/reporters.md) +- Integration with SonarQube, Jenkins and TeamCity via [reporters](docs/userguide/reporters.md) - Plugin architecture for reporters and matchers - Flexible and simple test invocation - Multi-format reporting from the [command line client](https://github.com/utPLSQL/utPLSQL-cli) diff --git a/source/create_grants.sql b/source/create_grants.sql index 0656ec82f..9318a7220 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -108,7 +108,6 @@ grant execute on &&ut3_owner..ut_tap_reporter to &ut3_user; --reporters - coverage grant execute on &&ut3_owner..ut_coverage_html_reporter to &ut3_user; grant execute on &&ut3_owner..ut_coverage_sonar_reporter to &ut3_user; -grant execute on &&ut3_owner..ut_coveralls_reporter to &ut3_user; grant execute on &&ut3_owner..ut_coverage_cobertura_reporter to &ut3_user; --reporters - debug grant execute on &&ut3_owner..ut_debug_reporter to &ut3_user; diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index 242bd6d61..ab338f4f7 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -123,7 +123,6 @@ create &action_type. synonym &ut3_user.ut_tap_reporter for &&ut3_owner..ut_tap_r --reporters - coverage create &action_type. synonym &ut3_user.ut_coverage_html_reporter for &&ut3_owner..ut_coverage_html_reporter; create &action_type. synonym &ut3_user.ut_coverage_sonar_reporter for &&ut3_owner..ut_coverage_sonar_reporter; -create &action_type. synonym &ut3_user.ut_coveralls_reporter for &&ut3_owner..ut_coveralls_reporter; create &action_type. synonym &ut3_user.ut_coverage_cobertura_reporter for &&ut3_owner..ut_coverage_cobertura_reporter; --reporters - debug create &action_type. synonym &ut3_user.ut_debug_reporter for &&ut3_owner..ut_debug_reporter; diff --git a/source/install.sql b/source/install.sql index a2c73ef17..9af0a4f66 100644 --- a/source/install.sql +++ b/source/install.sql @@ -355,8 +355,6 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'reporters/ut_coverage_html_reporter.tpb' @@install_component.sql 'reporters/ut_coverage_sonar_reporter.tps' @@install_component.sql 'reporters/ut_coverage_sonar_reporter.tpb' -@@install_component.sql 'reporters/ut_coveralls_reporter.tps' -@@install_component.sql 'reporters/ut_coveralls_reporter.tpb' @@install_component.sql 'reporters/ut_coverage_cobertura_reporter.tps' @@install_component.sql 'reporters/ut_coverage_cobertura_reporter.tpb' @@install_component.sql 'reporters/ut_realtime_reporter.tps' diff --git a/source/reporters/ut_coveralls_reporter.tpb b/source/reporters/ut_coveralls_reporter.tpb deleted file mode 100644 index 8d8884878..000000000 --- a/source/reporters/ut_coveralls_reporter.tpb +++ /dev/null @@ -1,104 +0,0 @@ -create or replace noneditionable type body ut_coveralls_reporter is - /* - utPLSQL - Version 3 - Copyright 2016 - 2026 utPLSQL Project - - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - */ - - constructor function ut_coveralls_reporter( - self in out nocopy ut_coveralls_reporter - ) return self as result is - begin - self.init($$plsql_unit,ut_output_bulk_buffer()); - return; - end; - - overriding member procedure after_calling_run(self in out nocopy ut_coveralls_reporter, a_run in ut_run) as - - function get_lines_json(a_unit_coverage ut_coverage.t_unit_coverage) return ut_varchar2_rows is - l_file_part varchar2(32767); - l_result ut_varchar2_rows := ut_varchar2_rows(); - l_last_line_no binary_integer; - c_coverage_header constant varchar2(30) := '"coverage": ['; - c_null constant varchar2(4) := 'null'; - begin - ut_utils.append_to_list(l_result, c_coverage_header); - - l_last_line_no := a_unit_coverage.lines.last; - if l_last_line_no is null then - ut_utils.append_to_list( - l_result - , rpad( to_clob( '0' ), ( a_unit_coverage.total_lines * 3 ) - 2, ','||chr(10)||'0' ) - ); - else - for line_no in 1 .. l_last_line_no loop - if a_unit_coverage.lines.exists(line_no) then - l_file_part := to_char(a_unit_coverage.lines(line_no).executions); - else - l_file_part := c_null; - end if; - if line_no < l_last_line_no then - l_file_part := l_file_part ||','; - end if; - ut_utils.append_to_list(l_result, l_file_part); - end loop; - end if; - ut_utils.append_to_list(l_result, ']'); - return l_result; - end; - - function get_coverage_json( - a_coverage_data ut_coverage.t_coverage - ) return ut_varchar2_rows is - l_result ut_varchar2_rows := ut_varchar2_rows(); - l_unit ut_coverage.t_object_name; - c_coverage_header constant varchar2(30) := '{"source_files":['; - c_coverage_footer constant varchar2(30) := ']}'||chr(10)||' '; - begin - ut_utils.append_to_list(l_result, c_coverage_header); - l_unit := a_coverage_data.objects.first; - while l_unit is not null loop - ut_utils.append_to_list(l_result, '{ "name": "'||l_unit||'",'); - - ut_utils.append_to_list(l_result,get_lines_json(a_coverage_data.objects(l_unit))); - - ut_utils.append_to_list(l_result, '}'); - - l_unit := a_coverage_data.objects.next(l_unit); - if l_unit is not null then - ut_utils.append_to_list(l_result, ','); - end if; - end loop; - ut_utils.append_to_list(l_result, c_coverage_footer); - return l_result; - end; - begin - ut_coverage.coverage_stop(); - - self.print_text_lines( - get_coverage_json( - ut_coverage.get_coverage_data(a_run.coverage_options) - ) - ); - end; - - overriding member function get_description return varchar2 as - begin - return 'Generates a JSON coverage report providing information on code coverage with line numbers.' || chr(10) || - 'Designed for [Coveralls](https://coveralls.io/).' || chr(10) || - 'JSON format conforms with specification: https://docs.coveralls.io/api-introduction'; - end; - -end; -/ diff --git a/source/reporters/ut_coveralls_reporter.tps b/source/reporters/ut_coveralls_reporter.tps deleted file mode 100644 index 8518891d5..000000000 --- a/source/reporters/ut_coveralls_reporter.tps +++ /dev/null @@ -1,31 +0,0 @@ -create or replace noneditionable type ut_coveralls_reporter under ut_coverage_reporter_base( - /* - utPLSQL - Version 3 - Copyright 2016 - 2026 utPLSQL Project - - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - */ - - /** - * Builds a coverage XML report that follows rules described in - * https://docs.coveralls.io/api-introduction - */ - constructor function ut_coveralls_reporter( - self in out nocopy ut_coveralls_reporter - ) return self as result, - - overriding member procedure after_calling_run(self in out nocopy ut_coveralls_reporter, a_run in ut_run), - - overriding member function get_description return varchar2 -) -/ diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 8ef644aa9..fcc8dfa52 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -74,8 +74,6 @@ drop synonym be_within; drop synonym be_within_pct; -drop type ut_coveralls_reporter force; - drop type ut_coverage_sonar_reporter force; drop type ut_coverage_cobertura_reporter force; diff --git a/test/run_tests.sh b/test/run_tests.sh index 7d0431aec..078d011d6 100755 --- a/test/run_tests.sh +++ b/test/run_tests.sh @@ -17,7 +17,6 @@ time utPLSQL-cli/bin/utplsql run UT3_TESTER_HELPER/ut3@//${CONNECTION_STR} -D \ -f=ut_coverage_sonar_reporter -o=coverage.xml \ -f=ut_coverage_cobertura_reporter -o=cobertura.xml \ -f=ut_coverage_html_reporter -o=coverage.html \ --f=ut_coveralls_reporter -o=coverage.json \ -f=ut_sonar_test_reporter -o=test_results.xml \ -f=ut_junit_reporter -o=junit_test_results.xml \ -f=ut_tfs_junit_reporter -o=tfs_test_results.xml \ diff --git a/test/ut3_user/api/test_ut_runner.pkb b/test/ut3_user/api/test_ut_runner.pkb index d665718e1..d35495c70 100644 --- a/test/ut3_user/api/test_ut_runner.pkb +++ b/test/ut3_user/api/test_ut_runner.pkb @@ -386,7 +386,6 @@ end;'; select 'UT3_DEVELOP.UT_DEBUG_REPORTER', 'Y' from dual union all select 'UT3_DEVELOP.UT_COVERAGE_HTML_REPORTER', 'Y' from dual union all select 'UT3_DEVELOP.UT_COVERAGE_SONAR_REPORTER', 'Y' from dual union all - select 'UT3_DEVELOP.UT_COVERALLS_REPORTER', 'Y' from dual union all select 'UT3_DEVELOP.UT_DOCUMENTATION_REPORTER', 'Y' from dual union all select 'UT3_DEVELOP.UT_JUNIT_REPORTER', 'Y' from dual union all select 'UT3_DEVELOP.UT_REALTIME_REPORTER', 'Y' from dual union all diff --git a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb deleted file mode 100644 index e3806cd97..000000000 --- a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb +++ /dev/null @@ -1,77 +0,0 @@ -create or replace package body test_coveralls_reporter is - - procedure report_on_file is - l_expected clob; - l_actual clob; - l_file_path varchar2(250); - begin - --Arrange - l_file_path := 'test/ut3_develop.'||ut3_tester_helper.coverage_helper.covered_package_name||'.pkb'; - l_expected := q'[{"source_files":[ -{ "name": "]'||l_file_path||q'[", -"coverage": [ -null, -null, -null, -3, -null, -0 -] -} -]} - ]'; - l_actual := - ut3_tester_helper.coverage_helper.run_tests_as_job( - q'[ - ut3_develop.ut.run( - a_path => 'ut3_develop.test_dummy_coverage', - a_reporter => ut3_develop.ut_coveralls_reporter( ), - a_source_files => ut3_develop.ut_varchar2_list( ']'||l_file_path||q'[' ), - a_test_files => ut3_develop.ut_varchar2_list( ) - ) - ]' - ); - --Assert - ut.expect(l_actual).to_equal(l_expected); - end; - - procedure report_zero_coverage is - l_expected clob; - l_actual clob; - begin - --Arrange - l_expected := q'[{"source_files":[ -{ "name": "package body ut3_develop.]'||ut3_tester_helper.coverage_helper.covered_package_name||q'[", -"coverage": [ -0, -0, -0, -0, -0, -0, -0, -0, -0 -] -} -]} - ]'; - - --Act - l_actual := - ut3_tester_helper.coverage_helper.run_tests_as_job( - q'[ - ut3_develop.ut.run( - 'ut3_develop.test_dummy_coverage.zero_coverage', - ut3_develop.ut_coveralls_reporter(), - a_include_objects => ut3_develop.ut_varchar2_list('UT3_DEVELOP.]'||ut3_tester_helper.coverage_helper.covered_package_name||q'[') - ) - ]' - ); - --Assert - ut.expect(l_actual).to_equal(l_expected); - - end; - -end; -/ diff --git a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pks b/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pks deleted file mode 100644 index d958b8f12..000000000 --- a/test/ut3_user/reporters/test_coverage/test_coveralls_reporter.pks +++ /dev/null @@ -1,13 +0,0 @@ -create or replace package test_coveralls_reporter is - - --%suite(ut_coveralls_reporter) - --%suitepath(utplsql.test_user.reporters.test_coverage) - - --%test(reports on a project file mapped to database object) - procedure report_on_file; - - --%test(reports zero coverage on each line of non-executed database object) - procedure report_zero_coverage; - -end; -/ From 417d7075acd18f74715acdc85b4da638c17e5fe6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 8 Jun 2026 13:23:14 +0300 Subject: [PATCH 690/887] Fixing unit tests installation --- test/install_ut3_user_tests.sql | 2 -- 1 file changed, 2 deletions(-) diff --git a/test/install_ut3_user_tests.sql b/test/install_ut3_user_tests.sql index 518e07841..b74c5d7ae 100644 --- a/test/install_ut3_user_tests.sql +++ b/test/install_ut3_user_tests.sql @@ -50,7 +50,6 @@ set define on @@ut3_user/reporters/test_coverage/test_extended_coverage.pks @@ut3_user/reporters/test_coverage/test_html_coverage_reporter.pks set define off -@@ut3_user/reporters/test_coverage/test_coveralls_reporter.pks @@ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pks @@ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pks set define on @@ -93,7 +92,6 @@ set define on @@ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb set define off -@@ut3_user/reporters/test_coverage/test_coveralls_reporter.pkb @@ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb set define on From 291fe6ca6e8ff2c30ef6fe79f157af699a65b3aa Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 8 Jun 2026 11:45:50 +0100 Subject: [PATCH 691/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index b8a6cc71b..d5a8a7704 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4465 +4470 diff --git a/docs/about/authors.md b/docs/about/authors.md index 4415412f8..0a7e96e1a 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index f66476bcf..3e20a7d99 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 766e0fd19..a3dd5ecc4 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index cc8c5ef88..b80db02d0 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 2a91d52f0..6188cf063 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 18461cf71..4c949c4dd 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index d650151f8..dffd20d52 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 424fce7e0..53a915b5b 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 7c196aece..d0874cef8 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 06d340418..3799ad53f 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index afd2a2abd..34467066a 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 6ec273ffb..8e5c148a6 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ae5b0a622..64b6cbbff 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index ab2a552ac..61403752b 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index f71bd504a..00f083a6a 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c106bc198..b311351ff 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 210871e4e..554c88606 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4465--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 0df784d4a..4e689d901 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4465-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4470-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 397c9f30627d039dde0217107571983320c6d332 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 8 Jun 2026 14:24:57 +0300 Subject: [PATCH 692/887] Clarify behavior of before/after procedures in suitepath Clarify the scope of beforeall / afterall beforeeach and aftereach when using suitepaths. Resolves: #958 --- docs/userguide/annotations.md | 50 ++++++++++++++++++++++------------- 1 file changed, 31 insertions(+), 19 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index dffd20d52..e3a07c278 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -23,8 +23,8 @@ In below example we have a `suite` annotation with `Stuff) -- we should name thi Do not place comments within annotation line to avoid unexpected behaviors. -**Note:** ->Annotations are interpreted only in the package specification and are case-insensitive. We strongly recommend using lower-case annotations as described in this documentation. +!!! note + Annotations are interpreted only in the package specification and are case-insensitive. We strongly recommend using lower-case annotations as described in this documentation. There are two distinct types of annotations, identified by their location in package. - package annotations @@ -151,15 +151,13 @@ The `--%suite` annotation denotes PLSQL package as a unit test suite. It accepts an optional description that will be visible when running the tests. When description is not provided, package name is displayed on report. -**Note** ->Package is considered a test-suite only when package specification contains the `--%suite` annotation at the package level. -> ->Some annotations like `--%suite`, `--%test` and `--%displayname` accept parameters. The parameters for annotations need to be placed in brackets. -Values for parameters should be provided without any quotation marks. -If the parameters are placed without brackets or with incomplete brackets, they will be ignored. -> ->Example: `--%suite(The name of suite without closing bracket` ->Example: `--%suite The name of suite without brackets` +!!! note + Package is considered a test-suite only when package specification contains the `--%suite` annotation at the package level. + Some annotations like `--%suite`, `--%test` and `--%displayname` accept parameters. The parameters for annotations need to be placed in brackets. + Values for parameters should be provided without any quotation marks. + If the parameters are placed without brackets or with incomplete brackets, they will be ignored. + Example: `--%suite(The name of suite without closing bracket` + Example: `--%suite The name of suite without brackets` Suite package without description. @@ -459,7 +457,7 @@ Finished in .005868 seconds ### Beforeall -There are two possible ways to use the `--%beforeall` annotation. +There are two possible ways to use the `--%beforeall` annotation. As a procedure level annotation: ```sql linenums="1" @@ -545,7 +543,7 @@ Finished in .012292 seconds ``` In the below example a combination pacakge and procedure level `--%beforeall` annotations is used. -The order of execution of the beforeall procedures is determined by the annotation position in package. +The execution order of the `--%beforeall` procedures is determined by the annotation position in the package. All of the `--%beforeall` procedures get invoked before any test is executed in a suite. ```sql linenums="1" create or replace package test_package as @@ -672,6 +670,8 @@ Finished in .012158 seconds 2 tests, 0 failed, 0 errored, 0 disabled, 2 warning(s) ``` +!!! note "Suite scope" + The `--%beforeall` procedrues in parent suite package are always part of all suite packages that are children on the suitepath. ### Afterall @@ -759,6 +759,10 @@ Finished in .014161 seconds 2 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s) ``` +!!! note "Suite scope" + The `--%afterall` procedrues in parent suite package are always part of all suite packages that are children on the suitepath. + + ### Beforeeach The procedure annotated as `--%beforeeach` is getting executed before each test in a suite. @@ -868,6 +872,9 @@ Finished in .014683 seconds 2 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s) ``` +!!! note "Package scope" + Unlike `--%beforeall`, the `--%beforeeach` annotation is only applicable within the scope of current test suite package. The `--%beforeeach` annotations from parent suite package are ignored. + See [beforeall](#Beforeall) for more examples. ### Aftereach @@ -977,6 +984,9 @@ Finished in .018115 seconds 2 tests, 0 failed, 0 errored, 0 disabled, 0 warning(s) ``` +!!! note "Package scope" + Unlike `--%afterall`, the `--%aftereach` annotation is only applicable within the scope of current test suite package. The `--%aftereach` annotations from parent suite package are ignored. + See [beforeall](#Beforeall) for more examples. ### Beforetest @@ -1715,6 +1725,8 @@ When executing tests, `path` for executing tests can be provided in three ways: * [schema]:suite1[.suite2][.suite3]...[.procedure] - execute all tests by `suitepath` in all suites on path suite1[.suite2][.suite3]...[.procedure]. If schema is not provided, then the current schema is used. Example: `:all.rooms_tests` * [schema.]package[.procedure] - execute all tests in the specified test package. The whole hierarchy of suites in the schema is built before all before/after hooks or part suites for the provided suite package are executed as well. Example: `tests.test_contact.test_last_name_validator` or simply `test_contact.test_last_name_validator` if `tests` is the current schema. +!!! note + Only the `beforeall` and `afterall` hooks of the parent suite are executed for the suite package. The `beforeeach` and `aftereach` hooks of the suite package are not executed. ### Rollback @@ -1740,12 +1752,12 @@ Doing so allows your tests to use the framework's automatic transaction control When you are testing code that performs explicit or implicit commits, you may set the test procedure to run as an autonomous transaction with `pragma autonomous_transaction`. Keep in mind that when your test runs as autonomous transaction it will not see the data prepared in a setup procedure unless the setup procedure committed the changes. -**Note** -> The `--%suitepath` annotation, when used, must be provided with a value of path. -> The path in suitepath cannot contain spaces. Dot (.) identifies individual elements of the path. -> -> Example: `--%suitepath(org.utplsql.core.utils)` -> +!!! note + The `--%rollback(manual)` annotation is only relevant for suites that use shared setup/cleanup with beforeall, + The `--%suitepath` annotation, when used, must be provided with a value of path. + The path in suitepath cannot contain spaces. Dot (.) identifies individual elements of the path. + Example: `--%suitepath(org.utplsql.core.utils)` + ### Throws From 7b0cc19a994e32667f8c86972101b6475e89193f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 8 Jun 2026 17:09:31 +0300 Subject: [PATCH 693/887] `throws` can reference exception without schema or package name It is now possible to reference a variable name or exception name without providing fully qualified name. utPLSQL will resolve the name of variable based on current unit test package owner and current unit test package name. Resolves: #1223 --- docs/userguide/annotations.md | 12 ++- source/core/types/ut_executable_test.tpb | 40 +++++---- .../test_annot_throws_exception.pkb | 87 +++++++++++++++++-- .../test_annot_throws_exception.pks | 25 +++++- 4 files changed, 133 insertions(+), 31 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index dffd20d52..ea5952a7b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1753,11 +1753,11 @@ Keep in mind that when your test runs as autonomous transaction it will not see The `--%throws` annotation allows you to specify a list of exceptions as one of: - number literals - example `--%throws(-20134)` -- variables of type exception defined in a package specification - example `--%throws(exc_pkg.c_exception_No_variable)` -- variables of type number defined in a package specification - example `--%throws(exc_pkg.c_some_exception)` +- variables of type `exception` defined in a package specification - example `--%throws(exc_pkg.c_exception_No_variable)` +- variables of type `number` defined in a package specification - example `--%throws(exc_pkg.c_some_exception)` - [predefined oracle exceptions](https://docs.oracle.com/en//database/oracle/oracle-database/19/lnpls/predefined-exceptions.html) - example `--%throws(no_data_found)` -The annotation is ignored, when no valid arguments are provided. Examples of invalid annotations `--%throws()`,`--%throws`, `--%throws(abe, 723pf)`. +The annotation is ignored when no valid arguments are provided. Examples of invalid annotations `--%throws()`,`--%throws`, `--%throws(abe, 723pf)`. If `--%throws` annotation is specified with arguments and no exception is raised, the test is marked as failed. @@ -1768,7 +1768,11 @@ The framework will raise a warning, when `--%throws` annotation has invalid argu Annotation `--%throws(7894562, operaqk, -=1, -20496, pow74d, posdfk3)` will be interpreted as `--%throws(-20496)`. Please note that `NO_DATA_FOUND` exception is a special case in Oracle. To capture it use `NO_DATA_FOUND` named exception or `-1403` exception No. - + +Syntax: `--%throws( [[schema.]package.]exception [, ... ])` + +So the exception name can be provided with or without the schema and package name. The package name is required only when the exception variable is located in another package. The schema name is required only when the exception variable is located in a pacakge in a nother schema. + Example: ```sql linenums="1" create or replace package exc_pkg is diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index 5772cdbc4..fc699c08b 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -65,9 +65,11 @@ create or replace noneditionable type body ut_executable_test as return false; end; - function check_exception_type(a_exception_name in varchar2) return varchar2 is - l_exception_type varchar2(50); + function to_exception_number(a_exception_name in varchar2) return integer is + l_exception_type varchar2(100); + l_exc_no integer; begin + --check if it is a predefined exception begin execute immediate 'begin null; exception when '||a_exception_name||' then null; end;'; @@ -87,10 +89,21 @@ create or replace noneditionable type body ut_executable_test as end; end if; end; - return l_exception_type; + + execute immediate + case l_exception_type + when c_integer_exception then + 'declare l_exception number; begin :l_exception := '||a_exception_name||'; end;' + when c_named_exception then + 'begin raise '||a_exception_name||'; exception when others then :l_exception := sqlcode; end;' + else + 'begin :l_exception := null; end;' + end + using out l_exc_no; + return l_exc_no; end; - function get_exception_number (a_exception_var in varchar2) return integer is + function get_exception_number (a_exception_var in varchar2, a_item ut_suite_item) return integer is l_exc_no integer; l_exc_type varchar2(50); function remap_no_data_found (a_number integer) return integer is @@ -98,18 +111,11 @@ create or replace noneditionable type body ut_executable_test as return case a_number when 100 then -1403 else a_number end; end; begin - l_exc_type := check_exception_type(a_exception_var); - - execute immediate - case l_exc_type - when c_integer_exception then - 'declare l_exception number; begin :l_exception := '||a_exception_var||'; end;' - when c_named_exception then - 'begin raise '||a_exception_var||'; exception when others then :l_exception := sqlcode; end;' - else - 'begin :l_exception := null; end;' - end - using out l_exc_no; + l_exc_no := coalesce( + to_exception_number(a_exception_var), + to_exception_number(a_item.object_owner||'.'||a_exception_var), + to_exception_number(a_item.object_owner||'.'||a_item.object_name||'.'||a_exception_var) + ); return remap_no_data_found(l_exc_no); end; @@ -121,7 +127,7 @@ create or replace noneditionable type body ut_executable_test as * Check if its a valid qualified name and if so try to resolve name to an exception number */ if is_valid_qualified_name(a_expected_error_codes(i)) then - l_exception_number := get_exception_number(a_expected_error_codes(i)); + l_exception_number := get_exception_number(a_expected_error_codes(i), a_item); elsif regexp_like(a_expected_error_codes(i), c_regexp_for_exception_no) then l_exception_number := a_expected_error_codes(i); end if; diff --git a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb index ac51d3a49..6e690a8bd 100644 --- a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb +++ b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb @@ -1,6 +1,7 @@ create or replace package body test_annot_throws_exception is g_tests_results clob; + g_results_other_schema clob; procedure recollect_tests_results is pragma autonomous_transaction; @@ -25,10 +26,16 @@ is e_some_exception exception; pragma exception_init(e_some_exception, -20207); - end;]'; + end; + ]'; - l_package_spec := ' - create package annotated_package_with_throws is + l_package_spec := q'[ + create or replace package annotated_package_with_throws is + + c_local_error_no constant number := -20211; + e_some_local_exception exception; + pragma exception_init(e_some_local_exception, -20212); + --%suite(Dummy package to test annotation throws) --%test(Throws same annotated exception) @@ -95,6 +102,22 @@ is --%throws(exc_pkg.c_e_mix_missin,utter_rubbish) procedure mixed_list_notexi; + --%test(Success referencing an exception variable when running from another schema) + --%throws(exc_pkg.e_some_exception) + procedure named_exc_pragma_run_from_another_schema; + + --%test(Success referencing a numeric exception variable when running from another schema) + --%throws(exc_pkg.c_e_list_1) + procedure exc_number_var_run_from_another_schema; + + --%test(Success referencing an exception variable without package name when running from another schema) + --%throws(e_some_local_exception) + procedure named_exc_pragma_run_from_another_schema_no_package_name; + + --%test(Success referencing a numeric exception variable without package name when running from another schema) + --%throws(c_local_error_no) + procedure exc_number_var_run_from_another_schema_no_package_name; + --%test(Success resolve and match named exception defined in pragma exception init) --%throws(exc_pkg.e_some_exception) procedure named_exc_pragma; @@ -123,10 +146,10 @@ is --%throws(exc_pkg.c_e_dummy); procedure bad_exc_const; end; - '; + ]'; l_package_body := ' - create package body annotated_package_with_throws is + create or replace package body annotated_package_with_throws is procedure raised_same_exception is begin raise_application_error(-20145, ''Test error''); @@ -208,6 +231,26 @@ is raise_application_error(exc_pkg.c_e_mix_missin,''Test''); end; + procedure named_exc_pragma_run_from_another_schema is + begin + raise exc_pkg.e_some_exception; + end; + + procedure exc_number_var_run_from_another_schema is + begin + raise_application_error(exc_pkg.c_e_list_1,''Test''); + end; + + procedure named_exc_pragma_run_from_another_schema_no_package_name is + begin + raise e_some_local_exception; + end; + + procedure exc_number_var_run_from_another_schema_no_package_name is + begin + raise_application_error(c_local_error_no,''Test''); + end; + procedure named_exc_pragma is begin raise exc_pkg.e_some_exception; @@ -312,7 +355,7 @@ is procedure one_valid_exception_number is begin - ut.expect(g_tests_results).to_match('^\s*Detects a valid exception number within many invalid ones \[[\.0-9]+ sec\]\s*$','m'); + ut.expect(g_tests_results).to_match('^\s*Detects a valid exception number within many invalid ones \[[,\.0-9]+ sec\]\s*$','m'); ut.expect(g_tests_results).to_match('one_valid_exception_number\s*Invalid parameter value ".*" for "--%throws" annotation. Parameter ignored.','m'); end; @@ -357,7 +400,37 @@ is ut.expect(g_tests_results).to_match('^\s*Success resolve and match named exception defined in pragma exception init \[[,\.0-9]+ sec\]\s*$','m'); ut.expect(g_tests_results).not_to_match('named_exc_pragma'); end; - + + procedure run_from_another_schema is + begin + ut3_tester_helper.run_helper.run(('ut3_tester.annotated_package_with_throws')); + g_results_other_schema := ut3_tester_helper.main_helper.get_dbms_output_as_clob(); + end; + + procedure named_exc_pragma_run_from_another_schema is + begin + ut.expect(g_results_other_schema).to_match('^\s*Success referencing an exception variable when running from another schema \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect(g_results_other_schema).not_to_match('named_exc_pragma_run_from_another_schema'); + end; + + procedure named_exc_pragma_run_from_another_schema_no_package_name is + begin + ut.expect(g_results_other_schema).to_match('^\s*Success referencing an exception variable without package name when running from another schema \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect(g_results_other_schema).not_to_match('named_exc_pragma_run_from_another_schema_no_package_name'); + end; + + procedure exc_number_var_run_from_another_schema_no_package_name is + begin + ut.expect(g_results_other_schema).to_match('^\s*Success referencing a numeric exception variable without package name when running from another schema \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect(g_results_other_schema).not_to_match('exc_number_var_run_from_another_schema_no_package_name'); + end; + + procedure exc_number_var_run_from_another_schema is + begin + ut.expect(g_results_other_schema).to_match('^\s*Success referencing a numeric exception variable when running from another schema \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect(g_results_other_schema).not_to_match('exc_number_var_run_from_another_schema'); + end; + procedure named_exc_ora is begin ut.expect(g_tests_results).to_match('^\s*Success resolve and match oracle named exception \[[,\.0-9]+ sec\]\s*$','m'); diff --git a/test/ut3_tester/core/annotations/test_annot_throws_exception.pks b/test/ut3_tester/core/annotations/test_annot_throws_exception.pks index a9d20183d..75369615e 100644 --- a/test/ut3_tester/core/annotations/test_annot_throws_exception.pks +++ b/test/ut3_tester/core/annotations/test_annot_throws_exception.pks @@ -18,7 +18,7 @@ is --%test(Gives failure when the raised exception is different that the annotated one) procedure throws_diff_annotated_except; - --%test(Ignores when the annotation throws is empty) + --%test(Ignores the throws annotation when it is empty) procedure throws_empty; --%test(Ignores when only bad parameters are passed, the test raise a exception and it shows errored test) @@ -56,8 +56,8 @@ is --%test(Success resolve and match named exception defined in pragma exception init) procedure named_exc_pragma; - - --%test(Success resolve and match oracle named exception no data) + + --%test(Success resolve and match oracle named exception no data) procedure named_exc_ora; --%test(Success resolve and match oracle named exception dup val index) @@ -78,5 +78,24 @@ is --%afterall procedure drop_test_package; + --%context(referencing exceptions when running from another schema) + + --%beforeall + procedure run_from_another_schema; + + --%test(Success referencing an exception variable when running from another schema) + procedure named_exc_pragma_run_from_another_schema; + + --%test(Success referencing a numeric exception variable when running from another schema) + procedure exc_number_var_run_from_another_schema; + + --%test(Success referencing an exception variable without a package name when running from another schema) + procedure named_exc_pragma_run_from_another_schema_no_package_name; + + --%test(Success referencing a numeric exception variable without a package name when running from another schema) + procedure exc_number_var_run_from_another_schema_no_package_name; + + --%endcontext + end; / From 1ed93993d90d671f5b7bdc151dc8a58e401cfd77 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 8 Jun 2026 15:18:52 +0100 Subject: [PATCH 694/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index d5a8a7704..c1bdd6d8e 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4470 +4475 diff --git a/docs/about/authors.md b/docs/about/authors.md index 0a7e96e1a..be53e8fc1 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 3e20a7d99..1cb261d83 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index a3dd5ecc4..9ecc430ed 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index b80db02d0..9c5357086 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 6188cf063..0a288bc9d 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 4c949c4dd..9c5dc0a01 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e3a07c278..fed77d103 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 53a915b5b..0933e322b 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index d0874cef8..c09228803 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 3799ad53f..62ffb4ce1 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 34467066a..e265ee897 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8e5c148a6..9f75dcc42 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 64b6cbbff..f2625a9bb 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 61403752b..b5c82e343 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 00f083a6a..66444118c 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index b311351ff..cd4291b35 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 554c88606..7f16e19a1 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4470--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4e689d901..4ce9fee8c 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4470-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4475-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 34bedaeb71675cf692ce411c2ea95290ea5ad867 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 9 Jun 2026 14:37:26 +0300 Subject: [PATCH 695/887] `throws` works with uninitialized exception variables It is now possible to reference an uninitialized exception variable name. utPLSQL will handle the exception properly. Resolves: #1340 --- source/core/types/ut_executable.tpb | 54 +++-- source/core/types/ut_executable.tps | 29 ++- source/core/types/ut_executable_test.tpb | 184 ++++++++---------- source/core/types/ut_executable_test.tps | 4 +- .../test_annot_throws_exception.pkb | 51 +++-- .../test_annot_throws_exception.pks | 14 +- .../core/test_ut_suite_tag_filter.pkb | 2 +- 7 files changed, 192 insertions(+), 146 deletions(-) diff --git a/source/core/types/ut_executable.tpb b/source/core/types/ut_executable.tpb index 6a45caa99..2fa3c1b5d 100644 --- a/source/core/types/ut_executable.tpb +++ b/source/core/types/ut_executable.tpb @@ -38,20 +38,30 @@ create or replace noneditionable type body ut_executable is return ut_metadata.form_name(l_owner_name, object_name, procedure_name); end; - member procedure do_execute(self in out nocopy ut_executable, a_item in out nocopy ut_suite_item) is + member procedure do_execute( + self in out nocopy ut_executable, + a_item in out nocopy ut_suite_item, + a_ignored_exception_names in ut_varchar2_rows := null, + a_ignored_exception_numbers in ut_varchar2_rows :=null) + is l_completed_without_errors boolean; begin - l_completed_without_errors := self.do_execute(a_item); + l_completed_without_errors := self.do_execute(a_item, a_ignored_exception_names, a_ignored_exception_numbers); end do_execute; - member function do_execute(self in out nocopy ut_executable, a_item in out nocopy ut_suite_item) return boolean is - l_statement varchar2(4000); - l_status number; - l_cursor_number number; - l_completed_without_errors boolean := true; - l_failed_with_invalid_pck boolean := true; - l_start_transaction_id varchar2(250); - l_end_transaction_id varchar2(250); + member function do_execute( + self in out nocopy ut_executable, + a_item in out nocopy ut_suite_item, + a_ignored_exception_names in ut_varchar2_rows := null, + a_ignored_exception_numbers in ut_varchar2_rows :=null) + return boolean is + l_statement varchar2(4000); + l_status number; + l_cursor_number number; + l_completed_without_errors boolean := true; + l_failed_with_invalid_pck boolean := true; + l_start_transaction_id varchar2(250); + l_end_transaction_id varchar2(250); function is_defined return boolean is l_result boolean := false; @@ -111,19 +121,33 @@ create or replace noneditionable type body ut_executable is if l_completed_without_errors then l_statement := 'declare' || chr(10) || - ' l_error_stack varchar2(32767);' || chr(10) || - ' l_error_backtrace varchar2(32767);' || chr(10) || + ' l_error_stack varchar2(32767);' || chr(10) || + ' l_error_backtrace varchar2(32767);' || chr(10) || + ' l_ignored_exception_detected integer := 0;' || chr(10) || 'begin' || chr(10) || ' begin' || chr(10) || ' ' || self.form_name( a_skip_current_user_schema => true ) || ';' || chr(10) || ' exception' || chr(10) || + case when a_ignored_exception_names is not empty then + ' when ' || ut_utils.table_to_clob( a_ignored_exception_names, ' or ' ) || ' then ' || chr(10) || + ' l_ignored_exception_detected := 1;' + end || ' when others then ' || chr(10) || + case when a_ignored_exception_numbers is not empty then + ' if sqlcode in (' || ut_utils.table_to_clob( a_ignored_exception_numbers, ', ' ) || ') then ' || chr(10) || + ' l_ignored_exception_detected := 1; ' || chr(10) || + ' else ' || chr(10) || + ' l_error_stack := dbms_utility.format_error_stack;' || chr(10) || + ' l_error_backtrace := dbms_utility.format_error_backtrace;' || chr(10) || + ' end if;' + else ' l_error_stack := dbms_utility.format_error_stack;' || chr(10) || - ' l_error_backtrace := dbms_utility.format_error_backtrace;' || chr(10) || - ' --raise on ORA-04068, ORA-04061: existing state of packages has been discarded to avoid unrecoverable session exception' || chr(10) || + ' l_error_backtrace := dbms_utility.format_error_backtrace;' + end || chr(10) || ' end;' || chr(10) || ' :a_error_stack := l_error_stack;' || chr(10) || ' :a_error_backtrace := l_error_backtrace;' || chr(10) || + ' :a_ignored_exception_detected := l_ignored_exception_detected;' || chr(10) || 'end;'; ut_utils.debug_log('ut_executable.do_execute l_statement: ' || l_statement); @@ -139,9 +163,11 @@ create or replace noneditionable type body ut_executable is dbms_sql.parse(l_cursor_number, statement => l_statement, language_flag => dbms_sql.native); dbms_sql.bind_variable(l_cursor_number, 'a_error_stack', to_char(null), 32767); dbms_sql.bind_variable(l_cursor_number, 'a_error_backtrace', to_char(null), 32767); + dbms_sql.bind_variable(l_cursor_number, 'a_ignored_exception_detected', to_number(null)); l_status := dbms_sql.execute(l_cursor_number); dbms_sql.variable_value(l_cursor_number, 'a_error_stack', self.error_stack); dbms_sql.variable_value(l_cursor_number, 'a_error_backtrace', self.error_backtrace); + dbms_sql.variable_value(l_cursor_number, 'a_ignored_exception_detected', self.ignored_exception_detected); dbms_sql.close_cursor(l_cursor_number); exception when ut_utils.ex_invalid_package then diff --git a/source/core/types/ut_executable.tps b/source/core/types/ut_executable.tps index 6257e3e89..0945a8996 100644 --- a/source/core/types/ut_executable.tps +++ b/source/core/types/ut_executable.tps @@ -18,26 +18,37 @@ create or replace noneditionable type ut_executable under ut_event_item( /** * The name of the event to be executed before and after the executable is invoked */ - executable_type varchar2(250 char), - owner_name varchar2(250 char), - object_name varchar2(250 char), - procedure_name varchar2(250 char), - error_backtrace varchar2(4000), - error_stack varchar2(4000), - serveroutput clob, + executable_type varchar2(250 char), + owner_name varchar2(250 char), + object_name varchar2(250 char), + procedure_name varchar2(250 char), + error_backtrace varchar2(4000), + error_stack varchar2(4000), + ignored_exception_detected integer, + serveroutput clob, /** * Used for ordering of executables, as Oracle doesn not guarantee ordering of items in a nested table. */ seq_no integer, constructor function ut_executable( self in out nocopy ut_executable, a_owner varchar2, a_package varchar2, a_procedure_name varchar2, a_executable_type varchar2) return self as result, member function form_name(a_skip_current_user_schema boolean := false) return varchar2, - member procedure do_execute(self in out nocopy ut_executable, a_item in out nocopy ut_suite_item), + member procedure do_execute( + self in out nocopy ut_executable, + a_item in out nocopy ut_suite_item, + a_ignored_exception_names in ut_varchar2_rows := null, + a_ignored_exception_numbers in ut_varchar2_rows := null + ), /** * executes the defines executable * returns true if executed without exceptions * returns false if exceptions were raised */ - member function do_execute(self in out nocopy ut_executable, a_item in out nocopy ut_suite_item) return boolean, + member function do_execute( + self in out nocopy ut_executable, + a_item in out nocopy ut_suite_item, + a_ignored_exception_names in ut_varchar2_rows := null, + a_ignored_exception_numbers in ut_varchar2_rows :=null + ) return boolean, member function get_error_stack_trace return varchar2 ) not final / diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index fc699c08b..a16937e54 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -31,147 +31,127 @@ create or replace noneditionable type body ut_executable_test as member procedure do_execute( self in out nocopy ut_executable_test, a_item in out nocopy ut_suite_item, - a_expected_error_codes in ut_varchar2_rows + a_expected_errors in ut_varchar2_rows ) is l_completed_without_errors boolean; begin - l_completed_without_errors := self.do_execute(a_item, a_expected_error_codes); + l_completed_without_errors := self.do_execute(a_item, a_expected_errors); end do_execute; member function do_execute( self in out nocopy ut_executable_test, a_item in out nocopy ut_suite_item, - a_expected_error_codes in ut_varchar2_rows + a_expected_errors in ut_varchar2_rows ) return boolean is - l_expected_except_message varchar2(4000); - l_expected_error_numbers ut_integer_list; - - function build_exception_numbers_list( - a_item in out nocopy ut_suite_item, - a_expected_error_codes in ut_varchar2_rows - ) return ut_integer_list is + l_failure_message varchar2(32767); + l_expected_error_names ut_varchar2_rows; + l_expected_error_numbers ut_varchar2_rows; + l_all_expected_errors ut_varchar2_rows; + + procedure build_expected_exceptions( + a_item in out nocopy ut_suite_item, + a_exception_definitions in ut_varchar2_rows, + a_exception_names_list out ut_varchar2_rows, + a_exception_numbers_list out ut_varchar2_rows + ) is l_exception_number integer; - l_exception_number_list ut_integer_list := ut_integer_list(); - c_regexp_for_exception_no constant varchar2(30) := '^-?[[:digit:]]{1,5}$'; - - c_integer_exception constant varchar2(1) := 'I'; - c_named_exception constant varchar2(1) := 'N'; - - function is_valid_qualified_name (a_name varchar2) return boolean is - l_name varchar2(500); - begin - l_name := dbms_assert.qualified_sql_name(a_name); - return true; - exception when others then - return false; - end; - - function to_exception_number(a_exception_name in varchar2) return integer is - l_exception_type varchar2(100); - l_exc_no integer; - begin - - --check if it is a predefined exception + l_exception_name varchar2(128); + function to_exception_number (a_exception_var in varchar2, a_item ut_suite_item) return integer is + function get_exception_no(a_exception_var in varchar2) return integer is + l_exc_no integer; begin - execute immediate 'begin null; exception when '||a_exception_name||' then null; end;'; - l_exception_type := c_named_exception; + execute immediate 'declare l_exception integer; begin :l_exception := '||a_exception_var||'; end;' + using out l_exc_no; + return l_exc_no; exception when others then - if dbms_utility.format_error_stack() like '%PLS-00485%' then - declare - e_invalid_number exception; - pragma exception_init ( e_invalid_number, -6502 ); - begin - execute immediate 'declare x integer := '||a_exception_name||'; begin null; end;'; - l_exception_type := c_integer_exception; - exception - when others then - null; - end; - end if; + return null; end; - - execute immediate - case l_exception_type - when c_integer_exception then - 'declare l_exception number; begin :l_exception := '||a_exception_name||'; end;' - when c_named_exception then - 'begin raise '||a_exception_name||'; exception when others then :l_exception := sqlcode; end;' - else - 'begin :l_exception := null; end;' - end - using out l_exc_no; - return l_exc_no; - end; - - function get_exception_number (a_exception_var in varchar2, a_item ut_suite_item) return integer is - l_exc_no integer; - l_exc_type varchar2(50); function remap_no_data_found (a_number integer) return integer is begin return case a_number when 100 then -1403 else a_number end; end; begin - l_exc_no := coalesce( - to_exception_number(a_exception_var), - to_exception_number(a_item.object_owner||'.'||a_exception_var), - to_exception_number(a_item.object_owner||'.'||a_item.object_name||'.'||a_exception_var) + return remap_no_data_found( + coalesce( + get_exception_no(a_exception_var), + get_exception_no(a_item.object_owner||'.'||a_exception_var), + get_exception_no(a_item.object_owner||'.'||a_item.object_name||'.'||a_exception_var) + ) + ); + end; + + function to_exception_name (a_exception_var in varchar2, a_item ut_suite_item) return varchar2 is + function verify_name(a_exception_name in varchar2) return varchar2 is + begin + --check if it is an existing, named exception + execute immediate 'begin null; exception when '||a_exception_name||' then null; end;'; + return a_exception_name; + exception + when others then + return null; + end; + begin + return coalesce( + verify_name(a_exception_var), + verify_name(a_item.object_owner||'.'||a_exception_var), + verify_name(a_item.object_owner||'.'||a_item.object_name||'.'||a_exception_var) ); - return remap_no_data_found(l_exc_no); end; begin - if a_expected_error_codes is not empty then - for i in 1 .. a_expected_error_codes.count loop - /** - * Check if its a valid qualified name and if so try to resolve name to an exception number - */ - if is_valid_qualified_name(a_expected_error_codes(i)) then - l_exception_number := get_exception_number(a_expected_error_codes(i), a_item); - elsif regexp_like(a_expected_error_codes(i), c_regexp_for_exception_no) then - l_exception_number := a_expected_error_codes(i); - end if; - - if l_exception_number is null then + a_exception_names_list := ut_varchar2_rows(); + a_exception_numbers_list := ut_varchar2_rows(); + if a_exception_definitions is not empty then + for i in 1 .. a_exception_definitions.count loop + l_exception_number := + coalesce( + to_exception_number(a_exception_definitions(i), a_item), + to_number(a_exception_definitions(i) default null on conversion error ) + ); + l_exception_name := to_exception_name(a_exception_definitions(i), a_item); + + if l_exception_number is null and l_exception_name is null then a_item.put_warning( - 'Invalid parameter value "'||a_expected_error_codes(i)||'" for "--%throws" annotation. Parameter ignored.', + 'Invalid parameter value "'||a_exception_definitions(i)||'" for "--%throws" annotation. Parameter ignored.', self.procedure_name, a_item.line_no ); elsif l_exception_number >= 0 then a_item.put_warning( - 'Invalid parameter value "'||a_expected_error_codes(i)||'" for "--%throws" annotation. Exception value must be a negative integer. Parameter ignored.', + 'Invalid parameter value "'||a_exception_definitions(i)||'" for "--%throws" annotation. Exception value must be a negative integer. Parameter ignored.', self.procedure_name, a_item.line_no ); - else - l_exception_number_list.extend; - l_exception_number_list(l_exception_number_list.last) := l_exception_number; + elsif l_exception_number is not null then + a_exception_numbers_list.extend; + a_exception_numbers_list(a_exception_numbers_list.last) := l_exception_number; + elsif l_exception_name is not null then + a_exception_names_list.extend; + a_exception_names_list(a_exception_names_list.last) := l_exception_name; end if; - l_exception_number := null; end loop; end if; - - return l_exception_number_list; end; - function failed_expec_errnum_message(a_expected_error_codes in ut_integer_list) return varchar is + + function get_exception_failure_message(a_expected_errors_list ut_varchar2_rows) return varchar is l_actual_error_no integer; - l_expected_error_codes varchar2(4000); + l_expected_errors varchar2(4000); l_fail_message varchar2(4000); begin --Convert the ut_varchar2_list to string to can construct the message - l_expected_error_codes := ut_utils.table_to_clob(a_expected_error_codes, ', '); + l_expected_errors := ut_utils.table_to_clob(a_expected_errors_list, ', '); if self.error_stack is null then - l_fail_message := 'Expected one of exceptions ('||l_expected_error_codes||') but nothing was raised.'; + l_fail_message := 'Expected one of exceptions ('|| l_expected_errors|| ') but nothing was raised.'; else l_actual_error_no := regexp_substr(self.error_stack, '^[[:alpha:]]{3}(-[0-9]+)', subexpression=>1); - if not l_actual_error_no member of a_expected_error_codes or l_actual_error_no is null then + if not l_actual_error_no member of a_expected_errors_list or l_actual_error_no is null then l_fail_message := 'Actual: '||l_actual_error_no||' was expected to '; - if cardinality(a_expected_error_codes) > 1 then - l_fail_message := l_fail_message || 'be one of: ('||l_expected_error_codes||')'; + if cardinality(a_expected_errors_list) > 1 then + l_fail_message := l_fail_message || 'be one of: ('|| l_expected_errors|| ')'; else - l_fail_message := l_fail_message || 'equal: '||l_expected_error_codes; + l_fail_message := l_fail_message || 'equal: '||l_expected_errors; end if; l_fail_message := substr( l_fail_message||chr(10)||self.error_stack||chr(10)||self.error_backtrace, 1, 4000 ); end if; @@ -181,14 +161,16 @@ create or replace noneditionable type body ut_executable_test as end; begin --Create a ut_executable object and call do_execute after that get the data to know the test's execution result - self.do_execute(a_item); - l_expected_error_numbers := build_exception_numbers_list(a_item, a_expected_error_codes); - if l_expected_error_numbers is not null and l_expected_error_numbers is not empty then - l_expected_except_message := failed_expec_errnum_message( l_expected_error_numbers ); + build_expected_exceptions(a_item, a_expected_errors, l_expected_error_names, l_expected_error_numbers ); + + self.do_execute(a_item, l_expected_error_names, l_expected_error_numbers); + l_all_expected_errors := l_expected_error_names multiset union all l_expected_error_numbers; + if l_all_expected_errors is not empty and self.ignored_exception_detected = 0 then + l_failure_message := get_exception_failure_message( l_all_expected_errors); - if l_expected_except_message is not null then + if l_failure_message is not null then ut_expectation_processor.add_expectation_result( - ut_expectation_result(ut_utils.gc_failure, null, l_expected_except_message, false) + ut_expectation_result(ut_utils.gc_failure, null, l_failure_message, false) ); end if; self.error_stack := null; diff --git a/source/core/types/ut_executable_test.tps b/source/core/types/ut_executable_test.tps index 91a7c6be0..d477456f6 100644 --- a/source/core/types/ut_executable_test.tps +++ b/source/core/types/ut_executable_test.tps @@ -22,12 +22,12 @@ create or replace noneditionable type ut_executable_test authid current_user und member procedure do_execute( self in out nocopy ut_executable_test, a_item in out nocopy ut_suite_item, - a_expected_error_codes in ut_varchar2_rows + a_expected_errors in ut_varchar2_rows ), member function do_execute( self in out nocopy ut_executable_test, a_item in out nocopy ut_suite_item, - a_expected_error_codes in ut_varchar2_rows + a_expected_errors in ut_varchar2_rows ) return boolean ) final; diff --git a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb index 6e690a8bd..dfe06f00a 100644 --- a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb +++ b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb @@ -36,6 +36,8 @@ is e_some_local_exception exception; pragma exception_init(e_some_local_exception, -20212); + e_uninitialized_exception_variable exception; + --%suite(Dummy package to test annotation throws) --%test(Throws same annotated exception) @@ -145,6 +147,11 @@ is --%test(Bad exception constant) --%throws(exc_pkg.c_e_dummy); procedure bad_exc_const; + + --%test(Uninitialized exception variable can be used successfully in a test) + --%throws(e_uninitialized_exception_variable) + procedure referencing_uninitialized_exception; + end; ]'; @@ -286,6 +293,10 @@ is raise_application_error(-20143, ''Test error''); end; + procedure referencing_uninitialized_exception is + begin + raise e_uninitialized_exception_variable; + end; end; '; @@ -299,6 +310,14 @@ is g_tests_results := ut3_develop.ut_utils.table_to_clob(l_test_results); end; + procedure drop_test_package is + pragma autonomous_transaction; + begin + execute immediate 'drop package annotated_package_with_throws'; + execute immediate 'drop package exc_pkg'; + end; + + procedure throws_same_annotated_except is begin ut.expect(g_tests_results).to_match('^\s*Throws same annotated exception \[[,\.0-9]+ sec\]\s*$','m'); @@ -409,26 +428,26 @@ is procedure named_exc_pragma_run_from_another_schema is begin - ut.expect(g_results_other_schema).to_match('^\s*Success referencing an exception variable when running from another schema \[[,\.0-9]+ sec\]\s*$','m'); - ut.expect(g_results_other_schema).not_to_match('named_exc_pragma_run_from_another_schema'); + ut.expect(g_results_other_schema).to_match('^\s*Success referencing an exception variable when running from another schema \[[,\.0-9]+ sec\]\s*$', 'm'); + ut.expect(g_results_other_schema).not_to_match('named_exc_pragma_run_from_another_schema'); end; procedure named_exc_pragma_run_from_another_schema_no_package_name is begin - ut.expect(g_results_other_schema).to_match('^\s*Success referencing an exception variable without package name when running from another schema \[[,\.0-9]+ sec\]\s*$','m'); - ut.expect(g_results_other_schema).not_to_match('named_exc_pragma_run_from_another_schema_no_package_name'); + ut.expect(g_results_other_schema).to_match('^\s*Success referencing an exception variable without package name when running from another schema \[[,\.0-9]+ sec\]\s*$', 'm'); + ut.expect(g_results_other_schema).not_to_match('named_exc_pragma_run_from_another_schema_no_package_name'); end; procedure exc_number_var_run_from_another_schema_no_package_name is begin - ut.expect(g_results_other_schema).to_match('^\s*Success referencing a numeric exception variable without package name when running from another schema \[[,\.0-9]+ sec\]\s*$','m'); - ut.expect(g_results_other_schema).not_to_match('exc_number_var_run_from_another_schema_no_package_name'); + ut.expect(g_results_other_schema).to_match('^\s*Success referencing a numeric exception variable without package name when running from another schema \[[,\.0-9]+ sec\]\s*$', 'm'); + ut.expect(g_results_other_schema).not_to_match('exc_number_var_run_from_another_schema_no_package_name'); end; procedure exc_number_var_run_from_another_schema is begin - ut.expect(g_results_other_schema).to_match('^\s*Success referencing a numeric exception variable when running from another schema \[[,\.0-9]+ sec\]\s*$','m'); - ut.expect(g_results_other_schema).not_to_match('exc_number_var_run_from_another_schema'); + ut.expect(g_results_other_schema).to_match('^\s*Success referencing a numeric exception variable when running from another schema \[[,\.0-9]+ sec\]\s*$', 'm'); + ut.expect(g_results_other_schema).not_to_match('exc_number_var_run_from_another_schema'); end; procedure named_exc_ora is @@ -465,13 +484,17 @@ is begin ut.expect(g_tests_results).to_match('^\s*Bad exception constant \[[,\.0-9]+ sec\] \(FAILED - [0-9]+\)\s*$','m'); ut.expect(g_tests_results).to_match('bad_exc_const\s*ORA-20143: Test error\s*ORA-06512: at "UT3_TESTER.ANNOTATED_PACKAGE_WITH_THROWS"'); - end; - - procedure drop_test_package is - pragma autonomous_transaction; + end; + + procedure referencing_uninitialized_exception is + l_test_results ut3_develop.ut_varchar2_list; + l_actual clob; begin - execute immediate 'drop package annotated_package_with_throws'; - execute immediate 'drop package exc_pkg'; + select * bulk collect into l_test_results from table(ut3_develop.ut.run(('annotated_package_with_throws.referencing_uninitialized_exception'))); + + l_actual := ut3_develop.ut_utils.table_to_clob(l_test_results); + ut.expect(l_actual).to_match('^\s*Uninitialized exception variable can be used successfully in a test \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect(l_actual).not_to_match('referencing_uninitialized_exception'); end; end; diff --git a/test/ut3_tester/core/annotations/test_annot_throws_exception.pks b/test/ut3_tester/core/annotations/test_annot_throws_exception.pks index 75369615e..883ba79e1 100644 --- a/test/ut3_tester/core/annotations/test_annot_throws_exception.pks +++ b/test/ut3_tester/core/annotations/test_annot_throws_exception.pks @@ -5,7 +5,11 @@ is --%beforeall procedure recollect_tests_results; - + + --%afterall + procedure drop_test_package; + + --%test(Gives success when annotated number exception is thrown) procedure throws_same_annotated_except; @@ -73,11 +77,11 @@ is procedure non_existing_const; --%test(Bad exception constant) - procedure bad_exc_const; - - --%afterall - procedure drop_test_package; + procedure bad_exc_const; + --%test(Uninitialized exception variable can be used successfully in a test) + procedure referencing_uninitialized_exception; + --%context(referencing exceptions when running from another schema) --%beforeall diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index 7ce6a1c3e..32610edf6 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -101,7 +101,7 @@ create or replace package body test_ut_suite_tag_filter is ut3_develop.ut_varchar2_rows('context_tag'), null), ut3_develop.ut_suite_cache_row( 3, 'UT_TEST', 'some.path.test_tags.nested_context_#1.create_new_mapping', 'TEST_USER', 'TEST_TAGS', 'CREATE_NEW_MAPPING', 11, timestamp '2026-05-06 10:23:38.461299', NULL, NULL, 0, NULL, null, null, null, null, null, null, null, null, - ut3_develop.ut_varchar2_rows('test_tag'), ut3_develop.ut_executable_test('UT_EXECUTABLE_TEST', 'test', 'TEST_USER', 'test_tags', 'create_new_mapping', NULL, NULL, NULL, NULL)) + ut3_develop.ut_varchar2_rows('test_tag'), ut3_develop.ut_executable_test('UT_EXECUTABLE_TEST', 'test', 'TEST_USER', 'test_tags', 'create_new_mapping', NULL, NULL, NULL, NULL, NULL)) ); ut.expect(ut3_develop.ut_suite_tag_filter.apply( l_input_data, 'slow').count).to_equal(3 ); From 455602f750df949fad86e21d2f029f5de1183f8c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 9 Jun 2026 12:39:07 +0100 Subject: [PATCH 696/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index c1bdd6d8e..ddbeab24e 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4475 +4476 diff --git a/docs/about/authors.md b/docs/about/authors.md index be53e8fc1..86bfea6ba 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 1cb261d83..a091e0ce5 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 9ecc430ed..3d7a0477b 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 9c5357086..c1ebe77e9 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 0a288bc9d..288f2bb73 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 9c5dc0a01..efafb71c1 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index aaced671e..f3fe1b436 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0933e322b..fc3e7ece3 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index c09228803..4eec51ae4 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 62ffb4ce1..d10ebc006 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index e265ee897..0df4aecdc 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 9f75dcc42..21c44b8ae 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index f2625a9bb..a5f73e7fd 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index b5c82e343..1d7ceef95 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 66444118c..60d76eaaa 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index cd4291b35..60f783ee7 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 7f16e19a1..d34b80055 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4475--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4ce9fee8c..706fa73ea 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4475-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4476-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 71e7aba1e5eefae06f101cdfbbaaa37623db157f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 9 Jun 2026 14:48:00 +0300 Subject: [PATCH 697/887] `throws` works with uninitialized exception variables It is now possible to reference an uninitialized exception variable name. utPLSQL will handle the exception properly. Resolves: #1340 --- docs/userguide/annotations.md | 123 ++++++++++++++++++++++------------ 1 file changed, 82 insertions(+), 41 deletions(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index aaced671e..20b822fc3 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1765,8 +1765,8 @@ Keep in mind that when your test runs as autonomous transaction it will not see The `--%throws` annotation allows you to specify a list of exceptions as one of: - number literals - example `--%throws(-20134)` -- variables of type `exception` defined in a package specification - example `--%throws(exc_pkg.c_exception_No_variable)` -- variables of type `number` defined in a package specification - example `--%throws(exc_pkg.c_some_exception)` +- variables of type `exception` defined in a package specification - example `--%throws(exc_pkg.c_exception_no_variable)` +- variables or constants of containing a valid negative exception number defined in a package specification - example `--%throws(exc_pkg.c_some_exception)` - [predefined oracle exceptions](https://docs.oracle.com/en//database/oracle/oracle-database/19/lnpls/predefined-exceptions.html) - example `--%throws(no_data_found)` The annotation is ignored when no valid arguments are provided. Examples of invalid annotations `--%throws()`,`--%throws`, `--%throws(abe, 723pf)`. @@ -1783,23 +1783,27 @@ Please note that `NO_DATA_FOUND` exception is a special case in Oracle. To captu Syntax: `--%throws( [[schema.]package.]exception [, ... ])` -So the exception name can be provided with or without the schema and package name. The package name is required only when the exception variable is located in another package. The schema name is required only when the exception variable is located in a pacakge in a nother schema. +The exception name can be provided with or without the schema and package name. The package name is required only when the exception variable is located in another package than the unti test package. The schema name is required only when the exception variable is located in a package in another schema. Example: ```sql linenums="1" create or replace package exc_pkg is c_e_option1 constant number := -20200; c_e_option2 constant varchar2(10) := '-20201'; - c_e_option3 number := -20202; - - e_option4 exception; - pragma exception_init(e_option4, -20203); + c_e_option3 integer := -20202; + e_initialized_exception exception; + pragma exception_init(e_initialized_exception, -20203); + + e_uninitialized_exception exception; end; / create or replace package example_pgk as + e_local_exception exception; + e_local_exception_num constant integer := -20123; + --%suite(Example Throws Annotation) --%test(Throws one of the listed exceptions) @@ -1830,10 +1834,22 @@ create or replace package example_pgk as --%throws(exc_pkg.c_e_option3) procedure raised_option3_exception; - --%test(Throws package exception option4) - --%throws(exc_pkg.e_option4) - procedure raised_option4_exception; + --%test(Throws exception associated with exception number) + --%throws(exc_pkg.e_initialized_exception) + procedure raised_initialized_exception; + + --%test(Throws uninitialized exception) + --%throws(exc_pkg.e_uninitialized_exception) + procedure raised_uninitialized_exception; + --%test(Throws exception local to unit tests package) + --%throws(e_local_exception) + procedure raised_local_exception; + + --%test(Throws exception local to unit tests package with exception number) + --%throws(e_local_exception_num) + procedure raised_local_exception_num; + --%test(Raise name exception) --%throws(DUP_VAL_ON_INDEX) procedure raise_named_exc; @@ -1844,6 +1860,7 @@ create or replace package example_pgk as end; / + create or replace package body example_pgk is procedure raised_one_listed_exception is begin @@ -1880,11 +1897,28 @@ create or replace package body example_pgk is raise_application_error(exc_pkg.c_e_option3, 'Test error'); end; - procedure raised_option4_exception is + procedure raised_initialized_exception is + begin + raise exc_pkg.e_initialized_exception; + end; + + procedure raised_uninitialized_exception is begin - raise exc_pkg.e_option4; + raise exc_pkg.e_uninitialized_exception; end; + procedure raised_local_exception is + pragma autonomous_transaction; + begin + raise e_local_exception; + end; + + procedure raised_local_exception_num is + pragma autonomous_transaction; + begin + raise_application_error(e_local_exception_num, 'Test error'); + end; + procedure raise_named_exc is begin raise DUP_VAL_ON_INDEX; @@ -1903,48 +1937,55 @@ exec ut3.ut.run('example_pgk'); Running the test will give report: ``` Example Throws Annotation - Throws one of the listed exceptions [.002 sec] - Throws different exception than expected [.002 sec] (FAILED - 1) - Throws different exception than listed [.003 sec] (FAILED - 2) - Gives failure when an exception is expected and nothing is thrown [.002 sec] (FAILED - 3) - Throws package exception option1 [.003 sec] - Throws package exception option2 [.002 sec] - Throws package exception option3 [.002 sec] - Throws package exception option4 [.002 sec] - Raise name exception [.002 sec] - Invalid throws annotation [.002 sec] - + Throws one of the listed exceptions [,026 sec] + Throws different exception than expected [,009 sec] (FAILED - 1) + Throws different exception than listed [,014 sec] (FAILED - 2) + Gives failure when an exception is expected and nothing is thrown [,016 sec] (FAILED - 3) + SUCCESS + Actual: 1 (number) was expected to equal: 1 (number) + Throws package exception option1 [,007 sec] + Throws package exception option2 [,008 sec] + Throws package exception option3 [,007 sec] + Throws exception associated with exception number [,006 sec] + Throws uninitialized exception [,006 sec] + Throws exception local to unit tests package [,009 sec] + Throws exception local to unit tests package with exception number [,011 sec] + Raise name exception [,006 sec] + Invalid throws annotation [,004 sec] + Failures: - + 1) raised_different_exception Actual: -20143 was expected to equal: -20144 ORA-20143: Test error - ORA-06512: at "UT3.EXAMPLE_PGK", line 9 - ORA-06512: at "UT3.EXAMPLE_PGK", line 9 - ORA-06512: at line 6 - + ORA-06512: at "UT3_TESTER.EXAMPLE_PGK", line 9 + ORA-06512: at "UT3_TESTER.EXAMPLE_PGK", line 9 + ORA-06512: at line 7 + 2) raised_unlisted_exception Actual: -20143 was expected to be one of: (-20144, -1, -20145) ORA-20143: Test error - ORA-06512: at "UT3.EXAMPLE_PGK", line 14 - ORA-06512: at "UT3.EXAMPLE_PGK", line 14 - ORA-06512: at line 6 - + ORA-06512: at "UT3_TESTER.EXAMPLE_PGK", line 14 + ORA-06512: at "UT3_TESTER.EXAMPLE_PGK", line 14 + ORA-06512: at line 7 + 3) nothing_thrown Expected one of exceptions (-20459, -20136, -20145) but nothing was raised. - - + + Warnings: - - 1) example_pgk + + 1) example_pgk.raised_one_listed_exception Invalid parameter value "bad" for "--%throws" annotation. Parameter ignored. - at "UT3.EXAMPLE_PGK.RAISED_ONE_LISTED_EXCEPTION", line 6 + at package "UT3_TESTER.EXAMPLE_PGK.RAISED_ONE_LISTED_EXCEPTION", line 8 + 2) example_pgk "--%throws" annotation requires a parameter. Annotation ignored. - at "UT3.EXAMPLE_PGK.BAD_THROWS_ANNOTATION", line 42 - -Finished in .025784 seconds -10 tests, 3 failed, 0 errored, 0 disabled, 2 warning(s) + at package "UT3_TESTER.EXAMPLE_PGK.BAD_THROWS_ANNOTATION", line 57 + +Finished in ,138276 seconds +13 tests, 3 failed, 0 errored, 0 disabled, 2 warning(s) + ``` ## Order of execution From a37cb5edf43db128c72ae943e28acbd63d446f03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 9 Jun 2026 14:51:04 +0300 Subject: [PATCH 698/887] Fixing typo in documentation --- docs/userguide/annotations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 20b822fc3..ef91887bb 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1783,7 +1783,7 @@ Please note that `NO_DATA_FOUND` exception is a special case in Oracle. To captu Syntax: `--%throws( [[schema.]package.]exception [, ... ])` -The exception name can be provided with or without the schema and package name. The package name is required only when the exception variable is located in another package than the unti test package. The schema name is required only when the exception variable is located in a package in another schema. +The exception name can be provided with or without the schema and package name. The package name is required only when the exception variable is located in another package than the unit test package. The schema name is required only when the exception variable is located in a package in another schema. Example: ```sql linenums="1" From e6f768e82c867223cd41f4c86c22f887e3d49ea2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 9 Jun 2026 15:49:36 +0300 Subject: [PATCH 699/887] Update of failing tests --- test/ut3_user/api/test_ut_run.pkb | 2 +- test/ut3_user/reporters/test_documentation_reporter.pkb | 2 +- test/ut3_user/reporters/test_realtime_reporter.pkb | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index b4040bb43..8c99af7d7 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -551,7 +551,7 @@ Failures:% ORA-04068: existing state of packages (DB_LOOPBACK%) has been discarded ORA-04061: existing state of package body "%.STATEFUL_PACKAGE" has been invalidated ORA-04065: not executed, altered or dropped package body "%.STATEFUL_PACKAGE"% - ORA-06512: at line 6% + ORA-06512: at line 7% 1 tests, 0 failed, 1 errored, 0 disabled, 0 warning(s)%'; --Act diff --git a/test/ut3_user/reporters/test_documentation_reporter.pkb b/test/ut3_user/reporters/test_documentation_reporter.pkb index 016cec256..d9c5d48c8 100644 --- a/test/ut3_user/reporters/test_documentation_reporter.pkb +++ b/test/ut3_user/reporters/test_documentation_reporter.pkb @@ -38,7 +38,7 @@ Failures: 2) erroring_test ORA-06502: PL/SQL: %: character to number conversion error ORA-06512: at "UT3_USER.TEST_REPORTERS", line 44% - ORA-06512: at line 6 + ORA-06512: at line 7 Finished in % seconds 5 tests, 1 failed, 1 errored, 2 disabled, 0 warning(s)%]'; diff --git a/test/ut3_user/reporters/test_realtime_reporter.pkb b/test/ut3_user/reporters/test_realtime_reporter.pkb index 84053c3c9..d4d83f7a3 100644 --- a/test/ut3_user/reporters/test_realtime_reporter.pkb +++ b/test/ut3_user/reporters/test_realtime_reporter.pkb @@ -410,7 +410,7 @@ create or replace package body test_realtime_reporter as = 'realtime_reporting.check_realtime_reporting3.test_6_with_runtime_error'; ut3_tester_helper.main_helper.append_to_list(l_expected_list, ''); + ut3_tester_helper.main_helper.append_to_list(l_expected_list, '%ORA-06512: at line 7]]>'); l_expected := ut3_tester_helper.main_helper.table_to_clob(l_expected_list); ut.expect(l_actual).to_be_like(l_expected); end error_stack_of_test; @@ -427,7 +427,7 @@ create or replace package body test_realtime_reporter as = 'realtime_reporting.check_realtime_reporting3'; ut3_tester_helper.main_helper.append_to_list(l_expected_list, ''); + ut3_tester_helper.main_helper.append_to_list(l_expected_list, '%ORA-06512: at line 7]]>'); l_expected := ut3_tester_helper.main_helper.table_to_clob(l_expected_list); ut.expect(l_actual).to_be_like(l_expected); end error_stack_of_testsuite; From bfd1a9aac18d796347d30c48bd17f9022850f79e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 9 Jun 2026 17:00:10 +0300 Subject: [PATCH 700/887] Adding an extra test to extend coverage. --- source/core/types/ut_executable_test.tpb | 2 ++ .../annotations/test_annot_throws_exception.pkb | 15 +++++++++++++++ .../annotations/test_annot_throws_exception.pks | 11 +++++++---- 3 files changed, 24 insertions(+), 4 deletions(-) diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index a16937e54..047f88671 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -74,6 +74,7 @@ create or replace noneditionable type body ut_executable_test as return remap_no_data_found( coalesce( get_exception_no(a_exception_var), + get_exception_no(a_item.object_name||'.'||a_exception_var), get_exception_no(a_item.object_owner||'.'||a_exception_var), get_exception_no(a_item.object_owner||'.'||a_item.object_name||'.'||a_exception_var) ) @@ -93,6 +94,7 @@ create or replace noneditionable type body ut_executable_test as begin return coalesce( verify_name(a_exception_var), + verify_name(a_item.object_name||'.'||a_exception_var), verify_name(a_item.object_owner||'.'||a_exception_var), verify_name(a_item.object_owner||'.'||a_item.object_name||'.'||a_exception_var) ); diff --git a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb index dfe06f00a..761377765 100644 --- a/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb +++ b/test/ut3_tester/core/annotations/test_annot_throws_exception.pkb @@ -152,6 +152,10 @@ is --%throws(e_uninitialized_exception_variable) procedure referencing_uninitialized_exception; + --%test(Failure report shows all expected exceptions) + --%throws(c_local_error_no,e_some_local_exception,e_uninitialized_exception_variable) + procedure not_throwing_expected_exceptions; + end; ]'; @@ -297,6 +301,11 @@ is begin raise e_uninitialized_exception_variable; end; + + procedure not_throwing_expected_exceptions is + begin + raise_application_error(-20143, ''Test error''); + end; end; '; @@ -497,5 +506,11 @@ is ut.expect(l_actual).not_to_match('referencing_uninitialized_exception'); end; + procedure not_throwing_expected_exceptions is + begin + ut.expect(g_tests_results).to_match('not_throwing_expected_exceptions'); + ut.expect(g_tests_results).to_match('Actual: -20143 was expected to be one of: \(annotated_package_with_throws.e_some_local_exception, annotated_package_with_throws.e_uninitialized_exception_variable, -20211\)'); + end; + end; / diff --git a/test/ut3_tester/core/annotations/test_annot_throws_exception.pks b/test/ut3_tester/core/annotations/test_annot_throws_exception.pks index 883ba79e1..a41c18d2b 100644 --- a/test/ut3_tester/core/annotations/test_annot_throws_exception.pks +++ b/test/ut3_tester/core/annotations/test_annot_throws_exception.pks @@ -40,7 +40,7 @@ is --%test(Detects a valid exception number within many invalid ones) procedure one_valid_exception_number; - --%test(Gives failure when a exception is expected and nothing is thrown) + --%test(Gives failure when an exception is expected and nothing is thrown) procedure nothing_thrown; --%test(Single exception defined as a constant number in package) @@ -49,13 +49,13 @@ is --%test(Gives success when one of annotated exception using constant is thrown) procedure list_of_exc_constant; - --%test(Gives failure when the raised exception is different that the annotated one using variable) + --%test(Gives failure when the raised exception is different than the annotated one using variable) procedure fail_not_match_exc; - --%test(Success when one of exception from mixed list of number and constant is thrown) + --%test(Success when one of exception from a mixed list of number and constant is thrown) procedure mixed_exc_list; - --%test(Success when match exception even if other variable on list dont exists) + --%test(Success when match exception even if another variable on list doesn't exists) procedure mixed_list_notexi; --%test(Success resolve and match named exception defined in pragma exception init) @@ -81,6 +81,9 @@ is --%test(Uninitialized exception variable can be used successfully in a test) procedure referencing_uninitialized_exception; + + --%test(a Failure report shows all expected exceptions) + procedure not_throwing_expected_exceptions; --%context(referencing exceptions when running from another schema) From 797e401165a1215894e05c776916dc9a145b559f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 9 Jun 2026 17:16:25 +0300 Subject: [PATCH 701/887] Update datatype --- source/core/types/ut_executable_test.tpb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index 047f88671..8e48bd70a 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -136,7 +136,7 @@ create or replace noneditionable type body ut_executable_test as end if; end; - function get_exception_failure_message(a_expected_errors_list ut_varchar2_rows) return varchar is + function get_exception_failure_message(a_expected_errors_list ut_varchar2_rows) return varchar2 is l_actual_error_no integer; l_expected_errors varchar2(4000); l_fail_message varchar2(4000); From 917585053686989017aa052fd16beb52a0482cd8 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 9 Jun 2026 15:35:17 +0100 Subject: [PATCH 702/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index ddbeab24e..4a4c5f9fb 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4476 +4488 diff --git a/docs/about/authors.md b/docs/about/authors.md index 86bfea6ba..dca49827d 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index a091e0ce5..a786f3eee 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 3d7a0477b..ff840e728 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index c1ebe77e9..acc99e286 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 288f2bb73..71f9cdc83 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index efafb71c1..5d37731f4 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 03e895bb8..e075cd4cb 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index fc3e7ece3..5993c3824 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4eec51ae4..5e37f149e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index d10ebc006..cfe79069a 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0df4aecdc..6b26dd1c8 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 21c44b8ae..1fa394be5 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index a5f73e7fd..f1e36e625 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 1d7ceef95..e9d8d7ad7 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 60d76eaaa..36b7e8932 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 60f783ee7..324e97602 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index d34b80055..e69998a46 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4476--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 706fa73ea..559dde03d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4476-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4488-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 8b19e193faee277563ab438b18c6fdabbfa4292f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 13 Jun 2026 13:44:57 +0300 Subject: [PATCH 703/887] Update mkdocs navigation --- docs/overrides/main.html | 11 +++++++++++ mkdocs.yml | 1 + 2 files changed, 12 insertions(+) create mode 100644 docs/overrides/main.html diff --git a/docs/overrides/main.html b/docs/overrides/main.html new file mode 100644 index 000000000..7f0400ac3 --- /dev/null +++ b/docs/overrides/main.html @@ -0,0 +1,11 @@ +{% extends "base.html" %} +{# + Sub-repository template override. + Loads the shared utPLSQL.org top navigation bar from the central org site. + The topbar.js file is the single source of truth — update nav links there only. +#} + +{% block extrahead %} + {{ super() }} + +{% endblock %} diff --git a/mkdocs.yml b/mkdocs.yml index 49356fd4e..659fde4c2 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -14,6 +14,7 @@ extra_css: - stylesheets/extra.css theme: name: material + custom_dir: docs/overrides palette: # Palette toggle for light mode - media: "(prefers-color-scheme: light)" From 12cc0e51a60917d43cac7c097fa1e9448bde89f8 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 13 Jun 2026 12:12:02 +0100 Subject: [PATCH 704/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4a4c5f9fb..4ad7ae861 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4488 +4490 diff --git a/docs/about/authors.md b/docs/about/authors.md index dca49827d..c96f0e206 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index a786f3eee..6eb28e564 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index ff840e728..905f94d16 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index acc99e286..f6a1b8c10 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 71f9cdc83..70dde91c2 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 5d37731f4..8f7a39e3a 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e075cd4cb..3cad191b1 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 5993c3824..a5090a1cb 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 5e37f149e..4c326047c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index cfe79069a..8bbc81662 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 6b26dd1c8..b5ed501ca 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 1fa394be5..ee03d8daa 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index f1e36e625..411da2728 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index e9d8d7ad7..3b90ff3ad 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 36b7e8932..1688384d9 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 324e97602..e95165ed5 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e69998a46..ec0c2a197 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4488--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 559dde03d..55b6e7b1a 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4488-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4490-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From a070b8a901342f03aa5b1e93f5e9b75fcde55afb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 13 Jun 2026 14:39:23 +0300 Subject: [PATCH 705/887] Disable overrides in documentation navigation. --- mkdocs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mkdocs.yml b/mkdocs.yml index 659fde4c2..254ad3966 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -14,7 +14,7 @@ extra_css: - stylesheets/extra.css theme: name: material - custom_dir: docs/overrides +# custom_dir: docs/overrides palette: # Palette toggle for light mode - media: "(prefers-color-scheme: light)" From 8c655afc4292661e378b55085b6d665b7c4a4e50 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 13 Jun 2026 12:46:12 +0100 Subject: [PATCH 706/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4ad7ae861..5e94ad4d4 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4490 +4491 diff --git a/docs/about/authors.md b/docs/about/authors.md index c96f0e206..d9ee9be33 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 6eb28e564..a7fb3092b 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 905f94d16..289fd8c04 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index f6a1b8c10..d2a3a1d01 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 70dde91c2..681a975fe 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 8f7a39e3a..95af1fa70 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 3cad191b1..81056aecc 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index a5090a1cb..517748102 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4c326047c..dbb064ed4 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 8bbc81662..6b5453e38 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b5ed501ca..6326f05b3 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index ee03d8daa..e92c7988b 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 411da2728..f1661b7ec 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 3b90ff3ad..13d65f71b 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 1688384d9..96e993444 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index e95165ed5..8a78a637f 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index ec0c2a197..e39151cba 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4490--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 55b6e7b1a..1f92098e1 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4490-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4491-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 8b4d367031ed96c1402809284fbfb7e188faef57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 15 Jun 2026 12:00:54 +0300 Subject: [PATCH 707/887] Update of documentation shared navigation. --- docs/overrides/main.html | 15 +++++++++++++++ mkdocs.yml | 2 +- mkdocs_offline.yml | 2 +- 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/docs/overrides/main.html b/docs/overrides/main.html index 7f0400ac3..7276dfe5e 100644 --- a/docs/overrides/main.html +++ b/docs/overrides/main.html @@ -7,5 +7,20 @@ {% block extrahead %} {{ super() }} + {%- set palette = config.theme.palette %} + {%- if palette %} + {%- set entries = [palette] if palette is mapping else palette %} + {%- set ns = namespace(icons=[]) %} + {%- for entry in entries %} + {%- if entry.toggle is defined %} + {%- set svg %}{% include ".icons/" ~ entry.toggle.icon ~ ".svg" %}{%- endset %} + {%- set ns.icons = ns.icons + [{"scheme": entry.scheme | default("default"), "icon": svg, "name": entry.toggle.name}] %} + {%- endif %} + {%- endfor %} + {%- if ns.icons %} + + {%- endif %} + {%- endif %} + {% endblock %} diff --git a/mkdocs.yml b/mkdocs.yml index 254ad3966..659fde4c2 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -14,7 +14,7 @@ extra_css: - stylesheets/extra.css theme: name: material -# custom_dir: docs/overrides + custom_dir: docs/overrides palette: # Palette toggle for light mode - media: "(prefers-color-scheme: light)" diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index 9f0ef57af..24c58213b 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -8,7 +8,7 @@ edit_uri: "" site_url: http://utPLSQL.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL -copyright: Copyright © 2016 - 2022 utPLSQL Team +copyright: Copyright © 2016 - 2026 utPLSQL Team #repo_url: https://github.com/utPLSQL/utPLSQL # disable for offline docs extra_css: - stylesheets/extra.css From 6751b64ea5184793a028062e597f6d47a4783427 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 15 Jun 2026 10:08:06 +0100 Subject: [PATCH 708/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 5e94ad4d4..9ed668302 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4491 +4492 diff --git a/docs/about/authors.md b/docs/about/authors.md index d9ee9be33..def691755 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index a7fb3092b..143e9d9a7 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 289fd8c04..207a28d4f 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index d2a3a1d01..f4547fd01 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 681a975fe..a1d91a672 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 95af1fa70..e885a51a3 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 81056aecc..c340703a7 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 517748102..307b30ad7 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index dbb064ed4..fbbc79b99 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 6b5453e38..18365758d 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 6326f05b3..a0258eeee 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index e92c7988b..15b671004 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index f1661b7ec..b43d43ac3 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 13d65f71b..d7c66545a 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 96e993444..6b03c3166 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 8a78a637f..11114068f 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e39151cba..12389beaa 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4491--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 1f92098e1..4451f206c 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4491-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4492-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 959a7b8ec496fa30cf45bdbd546abd77dbc0cc80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 15 Jun 2026 17:12:19 +0300 Subject: [PATCH 709/887] Adding navigation.top to documentation --- mkdocs.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/mkdocs.yml b/mkdocs.yml index 659fde4c2..8a7a1f21a 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -35,6 +35,7 @@ theme: # - navigation.indexes - navigation.tabs - navigation.tracking + - navigation.top - toc.follow - toc.integrate - search.suggest From e6fd313765279619f4ea6c2ab7153ba70af846c4 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 15 Jun 2026 15:19:31 +0100 Subject: [PATCH 710/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 9ed668302..d59fc0270 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4492 +4493 diff --git a/docs/about/authors.md b/docs/about/authors.md index def691755..e9ffa3f1a 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 143e9d9a7..45189cc7f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 207a28d4f..121957552 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index f4547fd01..a9e26fb70 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index a1d91a672..b8bbf4e37 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index e885a51a3..0f62c07f8 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index c340703a7..bab271da7 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 307b30ad7..9ab7094ec 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index fbbc79b99..5d14a25dc 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 18365758d..dc02d292c 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index a0258eeee..2faabc090 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 15b671004..8d75ce0e0 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index b43d43ac3..3056129ec 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d7c66545a..55856e9c2 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 6b03c3166..505067165 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 11114068f..0ef77cf22 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 12389beaa..e54f92ac5 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4492--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4451f206c..927a035e9 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4492-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4493-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ee6754aadf652fb48ea6aa5d293fdb396b6458f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 16 Jun 2026 00:01:36 +0300 Subject: [PATCH 711/887] update site_utl to https --- mkdocs.yml | 2 +- mkdocs_offline.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index 8a7a1f21a..ca2d109b0 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -5,7 +5,7 @@ # https://squidfunk.github.io/mkdocs-material/setup/building-for-offline-usage/ edit_uri: "" -site_url: http://utPLSQL.org/ +site_url: https://utplsql.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL copyright: Copyright © 2016 - 2026 utPLSQL Team diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index 24c58213b..da631359e 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -5,7 +5,7 @@ # https://squidfunk.github.io/mkdocs-material/setup/building-for-offline-usage/ edit_uri: "" -site_url: http://utPLSQL.org/ +site_url: https://utplsql.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL copyright: Copyright © 2016 - 2026 utPLSQL Team From 49bd6c5b14f07b66b09e9c08c55c4bec96ea61aa Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 15 Jun 2026 22:08:33 +0100 Subject: [PATCH 712/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index d59fc0270..f60a0d593 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4493 +4494 diff --git a/docs/about/authors.md b/docs/about/authors.md index e9ffa3f1a..05026528c 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 45189cc7f..6e8068e1b 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 121957552..5fc788565 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index a9e26fb70..85e928633 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index b8bbf4e37..1769bcacc 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 0f62c07f8..aac1bb6b0 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index bab271da7..e7c16e3a0 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 9ab7094ec..5214aba16 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 5d14a25dc..1432319ba 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index dc02d292c..fa2f4b65d 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 2faabc090..6571f52d8 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8d75ce0e0..1c2f65a42 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 3056129ec..87f4ac24c 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 55856e9c2..07045953a 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 505067165..7556e8ad9 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 0ef77cf22..023750e13 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e54f92ac5..6a86c4831 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4493--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 927a035e9..b68682087 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4493-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4494-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ca2a5b50cf9133c9327b13acf075bcdc24410fa1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 16 Jun 2026 00:14:11 +0300 Subject: [PATCH 713/887] update site_utl and override main.html --- docs/overrides/main.html | 14 -------------- mkdocs.yml | 5 ++--- mkdocs_offline.yml | 5 ++--- 3 files changed, 4 insertions(+), 20 deletions(-) diff --git a/docs/overrides/main.html b/docs/overrides/main.html index 7276dfe5e..339e062c4 100644 --- a/docs/overrides/main.html +++ b/docs/overrides/main.html @@ -7,20 +7,6 @@ {% block extrahead %} {{ super() }} - {%- set palette = config.theme.palette %} - {%- if palette %} - {%- set entries = [palette] if palette is mapping else palette %} - {%- set ns = namespace(icons=[]) %} - {%- for entry in entries %} - {%- if entry.toggle is defined %} - {%- set svg %}{% include ".icons/" ~ entry.toggle.icon ~ ".svg" %}{%- endset %} - {%- set ns.icons = ns.icons + [{"scheme": entry.scheme | default("default"), "icon": svg, "name": entry.toggle.name}] %} - {%- endif %} - {%- endfor %} - {%- if ns.icons %} - - {%- endif %} - {%- endif %} {% endblock %} diff --git a/mkdocs.yml b/mkdocs.yml index ca2d109b0..a874a6161 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -5,7 +5,7 @@ # https://squidfunk.github.io/mkdocs-material/setup/building-for-offline-usage/ edit_uri: "" -site_url: https://utplsql.org/ +site_url: https://www.utplsql.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL copyright: Copyright © 2016 - 2026 utPLSQL Team @@ -41,8 +41,7 @@ theme: - search.suggest - search.highlight extra: -# homepage: http://jgebal.github.io/ -# homepage: http://utPLSQL.org/ +# homepage: https://www.utPLSQL.org/ social: - icon: fontawesome/brands/twitter link: https://twitter.com/utPLSQL diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index da631359e..4429d68f5 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -5,7 +5,7 @@ # https://squidfunk.github.io/mkdocs-material/setup/building-for-offline-usage/ edit_uri: "" -site_url: https://utplsql.org/ +site_url: https://www.utplsql.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL copyright: Copyright © 2016 - 2026 utPLSQL Team @@ -39,8 +39,7 @@ theme: - search.suggest - search.highlight extra: -# homepage: http://jgebal.github.io/ -# homepage: http://utPLSQL.org/ +# homepage: https://www.utPLSQL.org/ social: - icon: fontawesome/brands/twitter link: https://twitter.com/utPLSQL From 35703ac4f07f399e70a35fea9e124d24d6a99e1a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 15 Jun 2026 22:20:57 +0100 Subject: [PATCH 714/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index f60a0d593..a5bb21c73 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4494 +4495 diff --git a/docs/about/authors.md b/docs/about/authors.md index 05026528c..436f6e386 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 6e8068e1b..1af229715 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 5fc788565..d1b1db6b7 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 85e928633..b49ebb7c2 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 1769bcacc..83fa204c5 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index aac1bb6b0..5e6519f12 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e7c16e3a0..a4fdca3bc 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 5214aba16..025abb047 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 1432319ba..6d475b786 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index fa2f4b65d..1f7fbe4de 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 6571f52d8..fac8b7194 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 1c2f65a42..12e2646ed 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 87f4ac24c..9b8f0c12e 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 07045953a..f307bf9fe 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 7556e8ad9..f2c5fb9d6 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 023750e13..d0adf2d29 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 6a86c4831..e8cae8d1c 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4494--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index b68682087..e4e0f75dc 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4494-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4495-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ff7ecb0e9661cdc05a125dbd6725740a3aa63bc9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 16 Jun 2026 00:23:56 +0300 Subject: [PATCH 715/887] Removed cookies consent from project-level site --- mkdocs.yml | 7 ------- 1 file changed, 7 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index a874a6161..0b5bcb0cd 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -51,13 +51,6 @@ extra: link: https://github.com/utPLSQL - icon: fontawesome/solid/envelope link: mailto:utPLSQL@utPLSQL.org - consent: - title: Cookie consent - description: >- - We use cookies to recognize your repeated visits and preferences, as well - as to measure the effectiveness of our documentation and whether users - find what they're searching for. With your consent, you're helping us to - make our documentation better. version: # disable for offline docs provider: mike # disable for offline docs markdown_extensions: From 84051f8ec423b1fe4bb926868db913f7362aeddf Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 15 Jun 2026 22:30:48 +0100 Subject: [PATCH 716/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index a5bb21c73..eec95d2f4 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4495 +4496 diff --git a/docs/about/authors.md b/docs/about/authors.md index 436f6e386..d50da59be 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 1af229715..0881e3731 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index d1b1db6b7..1de6a1982 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index b49ebb7c2..fb36cfd5c 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 83fa204c5..82f76d1f0 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 5e6519f12..472749f14 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index a4fdca3bc..d2be54cc6 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 025abb047..77db24c14 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 6d475b786..df17dfc18 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 1f7fbe4de..c0e6369e7 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index fac8b7194..80196d078 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 12e2646ed..4b8706f12 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 9b8f0c12e..5d421ad28 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index f307bf9fe..13fcb51e1 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index f2c5fb9d6..ad4ee4c60 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index d0adf2d29..4edaf005f 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e8cae8d1c..e270f9e97 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4495--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index e4e0f75dc..c46886e74 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4495-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4496-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 1280a240f38eb6e1d5d65b6e2aa99514e1231aca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 16 Jun 2026 00:32:46 +0300 Subject: [PATCH 717/887] Updated urls for referencing the override topbar.js and css files. --- docs/overrides/main.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/overrides/main.html b/docs/overrides/main.html index 339e062c4..fdfe1a3be 100644 --- a/docs/overrides/main.html +++ b/docs/overrides/main.html @@ -7,6 +7,6 @@ {% block extrahead %} {{ super() }} - - + + {% endblock %} From 1d0ad230badc388d8ea27f6f24046e837b0b379e Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 15 Jun 2026 22:41:06 +0100 Subject: [PATCH 718/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index eec95d2f4..7a8caf9dc 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4496 +4497 diff --git a/docs/about/authors.md b/docs/about/authors.md index d50da59be..a98a65923 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 0881e3731..002da3907 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 1de6a1982..794aa1437 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index fb36cfd5c..2e9213a1d 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 82f76d1f0..79aa7331f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 472749f14..4def41334 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index d2be54cc6..e26b72a45 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 77db24c14..9ef3c262f 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index df17dfc18..15e4a8dbf 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index c0e6369e7..05de5a4ff 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 80196d078..2ecfdeb01 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 4b8706f12..00a198f95 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 5d421ad28..28bb66903 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 13fcb51e1..f921d35d8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index ad4ee4c60..d88c5b59f 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 4edaf005f..3c88fe6c5 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e270f9e97..2afca0aa9 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4496--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c46886e74..2ef25b2d5 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4496-develop'; + gc_version constant varchar2(50) := 'v3.2.01.4497-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 2cbf4fcee0cc26e875c4defbf0ca708857a988c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 16 Jun 2026 01:10:41 +0300 Subject: [PATCH 719/887] Update develop version --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 48e1527d1..134ab8769 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.2.01-develop +v3.2.3-develop From ef8ba95243c3f9ac3d91749e832efff27851d725 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 15 Jun 2026 23:17:35 +0100 Subject: [PATCH 720/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pks | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 7a8caf9dc..1a7f891d7 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4497 +4498 diff --git a/docs/about/authors.md b/docs/about/authors.md index a98a65923..caef6343a 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 002da3907..f2dc820c4 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 794aa1437..065896e24 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 2e9213a1d..e527af4d5 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 79aa7331f..175cc1553 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 4def41334..e832a1dc6 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index e26b72a45..daec67e7b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 9ef3c262f..1779a3bb6 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 15e4a8dbf..aea272e0e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 05de5a4ff..da9807059 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 2ecfdeb01..cb4b63621 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 00a198f95..b6df23b1a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 28bb66903..80dac8302 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index f921d35d8..873abadd9 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index d88c5b59f..4b86f939c 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 3c88fe6c5..c43fd025e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 2afca0aa9..ea8e4f9e6 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.01.4497--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index efcaeb5e6..11e499fca 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -3,7 +3,7 @@ sonar.organization=utplsql sonar.projectKey=utPLSQL_utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.2.01-develop +sonar.projectVersion=v3.2.3-develop # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 2ef25b2d5..722842641 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.01.4497-develop'; + gc_version constant varchar2(50) := 'v3.2.3.4498-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 12b0834418488122debf09d89ce7b5a967313beb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 24 Jun 2026 18:41:43 +0300 Subject: [PATCH 721/887] Adding google analytics and cookies consent --- mkdocs.yml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/mkdocs.yml b/mkdocs.yml index 0b5bcb0cd..71db3d01b 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -8,7 +8,9 @@ edit_uri: "" site_url: https://www.utplsql.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL -copyright: Copyright © 2016 - 2026 utPLSQL Team +copyright: > + Copyright © 2016 - 2026 utPLSQL Team + Change cookie settings repo_url: https://github.com/utPLSQL/utPLSQL extra_css: - stylesheets/extra.css @@ -42,6 +44,16 @@ theme: - search.highlight extra: # homepage: https://www.utPLSQL.org/ + analytics: + provider: google + property: G-WMFVR98J0Q + consent: + title: Cookie consent + description: >- + We use cookies to recognize your repeated visits and preferences, as well + as to measure the effectiveness of our documentation and whether users + find what they're searching for. With your consent, you're helping us to + make our documentation better. social: - icon: fontawesome/brands/twitter link: https://twitter.com/utPLSQL From 77b6f66e032e6ef0777edbb868372c05d55e98ed Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 24 Jun 2026 16:48:49 +0100 Subject: [PATCH 722/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 1a7f891d7..96ca98800 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4498 +4499 diff --git a/docs/about/authors.md b/docs/about/authors.md index caef6343a..c7ab0b8e7 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index f2dc820c4..83698e371 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 065896e24..c162cf5c6 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index e527af4d5..d6b690b62 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 175cc1553..bd277020e 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index e832a1dc6..363b8030b 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index daec67e7b..4a8a0218a 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 1779a3bb6..78d294799 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index aea272e0e..2f98b90f5 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index da9807059..2623dc67f 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index cb4b63621..be7266b4d 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index b6df23b1a..6f68b5f15 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 80dac8302..0a7d2599c 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 873abadd9..572ac9dd8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 4b86f939c..547681a0e 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c43fd025e..181a56e1e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index ea8e4f9e6..3e7e8c5a5 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4498--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 722842641..9e990456d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.3.4498-develop'; + gc_version constant varchar2(50) := 'v3.2.3.4499-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 2c6c1f9ce605e2b576501dd1d0700864c9b38a95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 24 Jun 2026 18:50:53 +0300 Subject: [PATCH 723/887] Update of the project site description --- mkdocs.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index 71db3d01b..eab0c5fef 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -6,8 +6,8 @@ edit_uri: "" site_url: https://www.utplsql.org/ -site_name: utPLSQL-framework -site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL +site_name: utPLSQL +site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL copyright: > Copyright © 2016 - 2026 utPLSQL Team Change cookie settings From 66e701984ff1cf5ec8c44c7b6b42b39c11bd4f68 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 24 Jun 2026 16:59:01 +0100 Subject: [PATCH 724/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 96ca98800..15c4c9a2c 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4499 +4500 diff --git a/docs/about/authors.md b/docs/about/authors.md index c7ab0b8e7..0dac0b90e 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 83698e371..737db2a64 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index c162cf5c6..40a489189 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index d6b690b62..156ba28e4 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index bd277020e..88b6de686 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 363b8030b..3848f6813 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 4a8a0218a..5d4f21a2e 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 78d294799..dd83de093 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 2f98b90f5..6deb2e630 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 2623dc67f..54b206ac6 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index be7266b4d..c1c65de61 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 6f68b5f15..2524015dc 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 0a7d2599c..83769c5c0 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 572ac9dd8..33151e6ed 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 547681a0e..015879b31 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 181a56e1e..7f3c6f1c0 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 3e7e8c5a5..aba6abc3d 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4499--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 9e990456d..f3e1297f4 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.3.4499-develop'; + gc_version constant varchar2(50) := 'v3.2.3.4500-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 0a6baeb821a6a6349629fe7188b677972c53cc47 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 24 Jun 2026 19:33:16 +0300 Subject: [PATCH 725/887] Adding feedback form. --- mkdocs.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/mkdocs.yml b/mkdocs.yml index eab0c5fef..7460a9c32 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -47,6 +47,20 @@ extra: analytics: provider: google property: G-WMFVR98J0Q + feedback: + title: Was this page helpful? + ratings: + - icon: material/emoticon-happy-outline + name: This page was helpful + data: 1 + note: >- + Thanks for your feedback! + - icon: material/emoticon-sad-outline + name: This page could be improved + data: 0 + note: >- + Thanks for your feedback! Help us improve this page by + using our GitHub Discussions. consent: title: Cookie consent description: >- From 9c8c4f0858f12e2a317285eb5cb20234208c1b41 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 24 Jun 2026 17:39:55 +0100 Subject: [PATCH 726/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 15c4c9a2c..8af91005b 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4500 +4501 diff --git a/docs/about/authors.md b/docs/about/authors.md index 0dac0b90e..a4fcd049a 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 737db2a64..c59a92737 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 40a489189..b214cdd41 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 156ba28e4..ece9c33c0 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 88b6de686..3938f131d 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 3848f6813..c71871c2b 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 5d4f21a2e..999e27a5b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index dd83de093..c713453c9 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 6deb2e630..398349149 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 54b206ac6..c49a7e5e0 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index c1c65de61..b1764a63f 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 2524015dc..8edd04887 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 83769c5c0..86621a062 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 33151e6ed..1abb1742d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 015879b31..44f4e4fbd 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 7f3c6f1c0..58e4a8d8b 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index aba6abc3d..485ef3dc7 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4500--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f3e1297f4..d8bb73cd2 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.3.4500-develop'; + gc_version constant varchar2(50) := 'v3.2.3.4501-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From e6e628199c3aa57dfe5e1e97d2040bcd88e5e407 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 24 Jun 2026 19:55:55 +0300 Subject: [PATCH 727/887] Added workflow for rebuilding documentation for older versions --- .github/workflows/rebuild_docs.yml | 54 ++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 .github/workflows/rebuild_docs.yml diff --git a/.github/workflows/rebuild_docs.yml b/.github/workflows/rebuild_docs.yml new file mode 100644 index 000000000..455740a4e --- /dev/null +++ b/.github/workflows/rebuild_docs.yml @@ -0,0 +1,54 @@ +name: Rebuild older docs versions +on: + workflow_dispatch: + inputs: + versions: + description: 'Space-separated list of versions to rebuild (e.g. "v3.1.14 v3.1.13")' + required: true + +defaults: + run: + shell: bash + +jobs: + rebuild: + name: Rebuild documentation for older versions + concurrency: publish + runs-on: ubuntu-latest + timeout-minutes: 30 + env: + API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} + + steps: + - name: 🔍 API_TOKEN_GITHUB + if: env.API_TOKEN_GITHUB == '' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: echo "API_TOKEN_GITHUB=${GITHUB_TOKEN}" >> $GITHUB_ENV + + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + token: ${{ env.API_TOKEN_GITHUB }} + + - uses: c-py/action-dotenv-to-setenv@v5 + with: + env-file: .github/variables/.env + + - uses: FranzDiebold/github-env-vars-action@v2.8.0 + + - name: Install mkdocs stack + run: | + pip install mkdocs + pip install mkdocs-git-revision-date-localized-plugin + pip install mkdocs-material + pip install git+https://github.com/jimporter/mike.git + + - name: Rebuild specified versions + run: | + for VERSION in ${{ inputs.versions }}; do + echo "=== Rebuilding $VERSION ===" + git checkout "tags/${VERSION}" -- docs/ + mike deploy -p "${VERSION}" + git checkout HEAD -- docs/ mkdocs.yml + done From aa115f041ee6bb70005e2357b7946a11af2c61ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 24 Jun 2026 20:46:41 +0300 Subject: [PATCH 728/887] Update of cookie settings. --- mkdocs.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mkdocs.yml b/mkdocs.yml index 7460a9c32..50b15d12b 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -68,6 +68,8 @@ extra: as to measure the effectiveness of our documentation and whether users find what they're searching for. With your consent, you're helping us to make our documentation better. + # the cookie: utplsql-consent allows for shred cookie across all documentation versions and the global site + cookie: utplsql-consent social: - icon: fontawesome/brands/twitter link: https://twitter.com/utPLSQL From bb6cd93d67fda10b4eec1bc07c5181db7e93291e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 25 Jun 2026 08:41:52 +0300 Subject: [PATCH 729/887] Update of cookie settings. --- docs/overrides/main.html | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/docs/overrides/main.html b/docs/overrides/main.html index fdfe1a3be..b93cf09de 100644 --- a/docs/overrides/main.html +++ b/docs/overrides/main.html @@ -7,6 +7,21 @@ {% block extrahead %} {{ super() }} + {% endblock %} From cfbcce405c9d94264179ea1b1a43ed249d0bafd9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 25 Jun 2026 08:56:49 +0300 Subject: [PATCH 730/887] Update of cookie settings. --- docs/overrides/main.html | 15 --------------- mkdocs.yml | 2 ++ 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/docs/overrides/main.html b/docs/overrides/main.html index b93cf09de..fdfe1a3be 100644 --- a/docs/overrides/main.html +++ b/docs/overrides/main.html @@ -7,21 +7,6 @@ {% block extrahead %} {{ super() }} - {% endblock %} diff --git a/mkdocs.yml b/mkdocs.yml index 50b15d12b..44b823cdf 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -44,6 +44,8 @@ theme: - search.highlight extra: # homepage: https://www.utPLSQL.org/ + # sets scope of cookies to use a common path (root) + scope: "/" analytics: provider: google property: G-WMFVR98J0Q From 713867d2a47964534756fb9ff09515a409609b7b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 25 Jun 2026 07:03:49 +0100 Subject: [PATCH 731/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 8af91005b..feb1f9f58 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4501 +4504 diff --git a/docs/about/authors.md b/docs/about/authors.md index a4fcd049a..ec34d79f6 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index c59a92737..fc699e0a9 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index b214cdd41..fedb1a2be 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index ece9c33c0..ec2192dc3 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 3938f131d..37c41038c 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index c71871c2b..e30b822e2 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 999e27a5b..7ca85ba9d 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index c713453c9..ea4c27ac6 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 398349149..09ff07b7b 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index c49a7e5e0..87dc4eec9 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b1764a63f..43cdfd2e1 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8edd04887..a72a88fa5 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 86621a062..b33ecc898 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 1abb1742d..c671b14d2 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 44f4e4fbd..9ef81b1e8 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 58e4a8d8b..b48629546 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 485ef3dc7..5b1c8a20b 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4501--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index d8bb73cd2..181b1d98a 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.3.4501-develop'; + gc_version constant varchar2(50) := 'v3.2.3.4504-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From f3936cd83582ee5f7789031850d95b0eaac7426c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 25 Jun 2026 09:17:23 +0300 Subject: [PATCH 732/887] Update rebuild docs to have all versions by default --- .github/workflows/rebuild_docs.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/rebuild_docs.yml b/.github/workflows/rebuild_docs.yml index 455740a4e..93e3fa6ed 100644 --- a/.github/workflows/rebuild_docs.yml +++ b/.github/workflows/rebuild_docs.yml @@ -5,6 +5,7 @@ on: versions: description: 'Space-separated list of versions to rebuild (e.g. "v3.1.14 v3.1.13")' required: true + default: 'v3.2.2 v3.2.01 v3.1.14 v3.1.13 v3.1.12 v3.1.11 v3.1.10 v3.1.9 v3.1.8 v3.1.6 v3.1.5 v3.1.4 v3.1.3 v3.1.2 v3.1.1 v3.1.0 v3.0.4 v3.0.3 v3.0.2 v3.0.1 v3.0.0 v3.0.0-beta' defaults: run: From 34710b886d5c6ceefca21fcb889aa263d52a281a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 25 Jun 2026 07:32:32 +0100 Subject: [PATCH 733/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index feb1f9f58..a420b3991 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4504 +4505 diff --git a/docs/about/authors.md b/docs/about/authors.md index ec34d79f6..58d723884 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index fc699e0a9..0434cb3f0 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index fedb1a2be..ea3868da7 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index ec2192dc3..7a60eff3b 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 37c41038c..bf6719701 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index e30b822e2..4864dfd68 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 7ca85ba9d..04b574e50 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index ea4c27ac6..21788e15d 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 09ff07b7b..c7baadf86 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 87dc4eec9..aed4875f3 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 43cdfd2e1..80b0d97b3 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index a72a88fa5..dc9e4e198 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index b33ecc898..374b65039 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c671b14d2..469326aae 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 9ef81b1e8..b2322fe5f 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index b48629546..9e31d6cd1 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 5b1c8a20b..2904fe7d8 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4504--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 181b1d98a..3ec758add 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.3.4504-develop'; + gc_version constant varchar2(50) := 'v3.2.3.4505-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From f04c54ec932abfe3e48841885334ed0ae8749ea1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 10 Jul 2026 08:51:48 +0300 Subject: [PATCH 734/887] Fixing release announcement script --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c4c76222c..58eb10ad4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -73,7 +73,7 @@ jobs: - name: Post release announcement to org discussions env: - GH_TOKEN: ${{ secrets.GITHUB_API_TOKEN }} + GH_TOKEN: ${{ secrets.API_TOKEN_GITHUB }} run: .github/scripts/post_release_announcement.sh - name: Publish release post to utplsql.github.io From 28a1b010ebcfee629f622dc10d691d07f2508b7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 10 Jul 2026 09:13:56 +0300 Subject: [PATCH 735/887] Fixing `publish_release_post.sh` script --- .github/scripts/publish_release_post.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/scripts/publish_release_post.sh b/.github/scripts/publish_release_post.sh index 89438738c..a1199cc0e 100755 --- a/.github/scripts/publish_release_post.sh +++ b/.github/scripts/publish_release_post.sh @@ -37,7 +37,7 @@ FORMATTED_BODY=$(echo "${RELEASE_BODY}" \ | sed -E 's@\*\*Full Changelog\*\*: (https://[^ ]+/compare/([^ ]+))@\*\*Full Changelog\*\*: [\2](\1)@g') # Create the post file -cat > "docs/_posts/${POST_FILENAME}" < "docs/announcements/posts/${POST_FILENAME}" < Date: Fri, 10 Jul 2026 07:22:00 +0100 Subject: [PATCH 736/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index a420b3991..7553ea5ef 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4505 +4508 diff --git a/docs/about/authors.md b/docs/about/authors.md index 58d723884..dc750b3ad 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 0434cb3f0..762635793 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index ea3868da7..820b59ba6 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 7a60eff3b..93e478fcc 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index bf6719701..6fc250013 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 4864dfd68..e8009ab8c 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 04b574e50..a357234f9 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 21788e15d..45ad41d1f 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index c7baadf86..823564111 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index aed4875f3..666906627 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 80b0d97b3..04d3fe58b 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index dc9e4e198..fddddfbfb 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 374b65039..8efa2c963 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 469326aae..ae049075c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index b2322fe5f..52ce49365 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 9e31d6cd1..79925cd32 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 2904fe7d8..63502cce6 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4505--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 3ec758add..6d5996ba4 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.3.4505-develop'; + gc_version constant varchar2(50) := 'v3.2.3.4508-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From c755a0e7881141a9550c8479981ff4dce1026ac2 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 10 Jul 2026 07:24:49 +0100 Subject: [PATCH 737/887] Add release notes for v.3.2.3 to CHANGELOG.md [skip ci] --- CHANGELOG.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index d304ab172..faf1f504a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,23 @@ Releases are available on the [GitHub Releases page](https://github.com/utPLSQL/ --- +## [v.3.2.3] - 2026-07-10 + +## What's Changed +* Fix issue with `UT_TAP_REPORTER` on Oracle 23.26 by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1359 +* Fixed support for camelCase in context `--%name` annotation. by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1361 +* utPLSQL can be installed in editioned schema. by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1362 +* Removed coveralls reporter by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1363 +* Clarify behavior of before/after procedures in suitepath by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1364 +* `throws` can reference exception without schema or package name by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1365 +* `throws` works with uninitialized exception variables by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1366 + + +**Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v.3.2.3 + +--- + + ## [v3.2.2] - 2026-05-24 ## What's Changed From 89e73b463b219e4805333e553190bdfb78f7809d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 10 Jul 2026 09:30:53 +0300 Subject: [PATCH 738/887] Fixing `publish_release_post.sh` script --- .github/scripts/publish_release_post.sh | 23 ++++------------------- 1 file changed, 4 insertions(+), 19 deletions(-) diff --git a/.github/scripts/publish_release_post.sh b/.github/scripts/publish_release_post.sh index a1199cc0e..09f92700a 100755 --- a/.github/scripts/publish_release_post.sh +++ b/.github/scripts/publish_release_post.sh @@ -20,6 +20,7 @@ POST_TIME=$(echo "${RELEASE_DATE}" | sed 's/T/ /' | sed 's/Z/ +0000/') POST_FILENAME="${POST_DATE}-version${VERSION}-released.md" POST_TITLE="utPLSQL ${RELEASE_TAG} released" POST_NAV_TITLE="utPLSQL ${VERSION} released" +POST_PATH='docs/announcements/posts' mkdir -p github_io cd github_io @@ -37,7 +38,7 @@ FORMATTED_BODY=$(echo "${RELEASE_BODY}" \ | sed -E 's@\*\*Full Changelog\*\*: (https://[^ ]+/compare/([^ ]+))@\*\*Full Changelog\*\*: [\2](\1)@g') # Create the post file -cat > "docs/announcements/posts/${POST_FILENAME}" < "${POST_PATH}/${POST_FILENAME}" < /tmp/index_new.md -mv /tmp/index_new.md docs/index.md - -# Insert new post into mkdocs.yml nav immediately after "- index.md" -sed -i "s| - index.md| - index.md\n - ${POST_NAV_TITLE}: _posts/${POST_FILENAME}|" mkdocs.yml - -git add "docs/_posts/${POST_FILENAME}" docs/index.md mkdocs.yml +git add "${POST_PATH}/${POST_FILENAME}" docs/index.md mkdocs.yml git commit -m "Release announcement for ${RELEASE_TAG}" git push origin "${GITHUB_IO_BRANCH}" -echo "Release post published: docs/_posts/${POST_FILENAME}" +echo "Release post published: ${POST_PATH}/${POST_FILENAME}" From 0e2847cc670dfef83cfc29a0af4b4eaa7be6504c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 10 Jul 2026 09:31:10 +0300 Subject: [PATCH 739/887] Update or test workflow --- .github/workflows/test_publishing.yml | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/.github/workflows/test_publishing.yml b/.github/workflows/test_publishing.yml index 0aac3805b..6f079ac54 100644 --- a/.github/workflows/test_publishing.yml +++ b/.github/workflows/test_publishing.yml @@ -15,18 +15,21 @@ jobs: timeout-minutes: 60 env: API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }} - RELEASE_TAG: "v3.2.2" + RELEASE_TAG: "v3.2.3" RELEASE_BODY: | ## What's Changed - * Filtering by tags fixed for schemas containing suite-paths and contexts by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1325 - * Fixed issue with reporter failing to initialize by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1354 - * Fixed issue with duplicate sources from dba_source by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1355 - * Allow HTML coverage on FIPS-enabled DB by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1356 + * Fix issue with `UT_TAP_REPORTER` on Oracle 23.26 by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1359 + * Fixed support for camelCase in context `--%name` annotation. by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1361 + * utPLSQL can be installed in editioned schema. by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1362 + * Removed coveralls reporter by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1363 + * Clarify behavior of before/after procedures in suitepath by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1364 + * `throws` can reference exception without schema or package name by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1365 + * `throws` works with uninitialized exception variables by @jgebal in https://github.com/utPLSQL/utPLSQL/pull/1366 - **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.01...v3.2.2 - RELEASE_DATE: "2026-05-24 10:48:22" - RELEASE_URL: "https://github.com/utPLSQL/utPLSQL/releases/tag/v3.2.2" + **Full Changelog**: https://github.com/utPLSQL/utPLSQL/compare/v3.2.2...v.3.2.3 + RELEASE_DATE: "2026-07-10 08:30:22" + RELEASE_URL: "https://github.com/utPLSQL/utPLSQL/releases/tag/v3.2.3" TARGET_BRANCH: "develop" steps: @@ -47,6 +50,6 @@ jobs: # GH_TOKEN: ${{ secrets.API_TOKEN_GITHUB }} # run: .github/scripts/post_release_announcement.sh -# - name: Publish release post to utplsql.github.io -# run: .github/scripts/publish_release_post.sh + - name: Publish release post to utplsql.github.io + run: .github/scripts/publish_release_post.sh From db5dba838a9bb03ff4f5d3dc0b1c487adc0054bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 10 Jul 2026 09:38:40 +0300 Subject: [PATCH 740/887] Fixing `publish_release_post.sh` --- .github/scripts/publish_release_post.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/scripts/publish_release_post.sh b/.github/scripts/publish_release_post.sh index 09f92700a..c9bade4f4 100755 --- a/.github/scripts/publish_release_post.sh +++ b/.github/scripts/publish_release_post.sh @@ -16,7 +16,6 @@ GITHUB_IO_BRANCH="main" VERSION="${RELEASE_TAG#v}" POST_DATE=$(echo "${RELEASE_DATE}" | cut -c1-10) -POST_TIME=$(echo "${RELEASE_DATE}" | sed 's/T/ /' | sed 's/Z/ +0000/') POST_FILENAME="${POST_DATE}-version${VERSION}-released.md" POST_TITLE="utPLSQL ${RELEASE_TAG} released" POST_NAV_TITLE="utPLSQL ${VERSION} released" @@ -42,8 +41,11 @@ cat > "${POST_PATH}/${POST_FILENAME}" < Date: Fri, 10 Jul 2026 07:45:16 +0100 Subject: [PATCH 741/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 7553ea5ef..e970fd97f 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4508 +4510 diff --git a/docs/about/authors.md b/docs/about/authors.md index dc750b3ad..704759cf7 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 762635793..6f4ac9131 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 820b59ba6..99fca6265 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 93e478fcc..fc9597cc6 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 6fc250013..906cec9f2 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index e8009ab8c..0c4753bc7 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index a357234f9..57c7bfd6b 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 45ad41d1f..547dc1338 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 823564111..4a97d25ee 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 666906627..3f5a6e8ed 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 04d3fe58b..1dc1ae28a 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index fddddfbfb..2736f3222 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 8efa2c963..3af53f5d3 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index ae049075c..051ba9a24 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 52ce49365..758acc059 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 79925cd32..c6097e6ab 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 63502cce6..24337c5d0 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4508--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6d5996ba4..4fb90f6aa 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.3.4508-develop'; + gc_version constant varchar2(50) := 'v3.2.3.4510-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From fa5aea8ed0c3ad5d3f7da4a286c2948e2347ad0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 13 Jul 2026 08:45:53 +0300 Subject: [PATCH 742/887] Update version number to 3.2.4-develop --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 134ab8769..19db2fb66 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -v3.2.3-develop +v3.2.4-develop From 78d1992676c3333cc532fb98a87a40f85f17e483 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 13 Jul 2026 06:52:28 +0100 Subject: [PATCH 743/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- sonar-project.properties | 2 +- source/core/ut_utils.pks | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index e970fd97f..702846d76 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4510 +4511 diff --git a/docs/about/authors.md b/docs/about/authors.md index 704759cf7..efcc92518 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 6f4ac9131..dcee071af 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 99fca6265..9728133c9 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index fc9597cc6..d69c275ad 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 906cec9f2..9a6e430e9 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 0c4753bc7..55c7a80fb 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 57c7bfd6b..678647bfc 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 547dc1338..330fc8735 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 4a97d25ee..93927b4f1 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 3f5a6e8ed..214337663 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 1dc1ae28a..323ad3436 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 2736f3222..e11ae36a0 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 3af53f5d3..b03bd9409 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 051ba9a24..47fae278b 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 758acc059..02b2e8240 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index c6097e6ab..0f8a45fa0 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 24337c5d0..4c8dc89b4 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.3.4510--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) # Upgrading from version 2 diff --git a/sonar-project.properties b/sonar-project.properties index 11e499fca..0a835a2f3 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -3,7 +3,7 @@ sonar.organization=utplsql sonar.projectKey=utPLSQL_utPLSQL # this is the name and version displayed in the SonarQube UI. Was mandatory prior to SonarQube 6.1. sonar.projectName=utPLSQL -sonar.projectVersion=v3.2.3-develop +sonar.projectVersion=v3.2.4-develop # Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows. # Since SonarQube 4.2, this property is optional if sonar.modules is set. diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4fb90f6aa..58d8fe428 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.3.4510-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4511-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 763abcf370998aa7fd35e66e877cafc95bd0ac26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 13 Jul 2026 16:33:47 +0300 Subject: [PATCH 744/887] Add a schedule run of the build workflow. --- .github/workflows/build.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8c77c486c..8e9a08506 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -4,6 +4,9 @@ on: branches-ignore: [ main ] pull_request: branches: [ develop ] + schedule: + - cron: '0 8 * * 5' # run scheduled at 8:00 AM every Friday + timezone: "Europe/Nicosia" workflow_dispatch: From 41a059f5c52338ec1f722ab00d54becf8b64d6d5 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 13 Jul 2026 16:11:39 +0100 Subject: [PATCH 745/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 702846d76..a6f7eb75d 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4511 +4512 diff --git a/docs/about/authors.md b/docs/about/authors.md index efcc92518..e4d72f7ab 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index dcee071af..0a63ab01d 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 9728133c9..5afa5c7ba 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index d69c275ad..be39fff34 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 9a6e430e9..c60c9e2b5 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 55c7a80fb..a74a08e34 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 678647bfc..813cf6601 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 330fc8735..e9f3dbcb8 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 93927b4f1..bd86455a6 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 214337663..cdebc1cb1 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 323ad3436..2c3472002 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index e11ae36a0..61939d994 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index b03bd9409..244b41e8b 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 47fae278b..098a3d59f 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 02b2e8240..d9309cc37 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 0f8a45fa0..1bdab653e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 4c8dc89b4..f93aae476 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4511--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 58d8fe428..6dd79147c 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4511-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4512-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 08fd82290c0068b496a70611c53664e1e8f2c6e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 17 Jul 2026 08:12:15 +0300 Subject: [PATCH 746/887] Update project readme to remove historical sponsors and include link to full contributors list --- readme.md | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/readme.md b/readme.md index bba640d17..f0c079566 100644 --- a/readme.md +++ b/readme.md @@ -136,19 +136,5 @@ We welcome contributions of all kinds. Please read the [contributing guide](CONT [GitHub Discussions](https://github.com/utPLSQL/utPLSQL/discussions) is the place to ask questions and connect with the team. -## Supporters +The list of **authors** and **significant contributors** is available [here](docs/about/authors.md). For a full list of contributors, see [contributors](https://github.com/utPLSQL/utPLSQL/graphs/contributors?all=1) on GitHub. -utPLSQL is community-driven and not commercially motivated. Donations and contributions are always welcome. - - - - - - - - -
    supported_by_redgateutPLSQL has been supported by Redgate in the form of sponsored stickers and t-shirts. Thank you for helping us spread the word!
    - ---- - -[Authors](docs/about/authors.md) From 7a6c464ab49854d8383db70a587a3dc20de68bc8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 17 Jul 2026 09:36:29 +0300 Subject: [PATCH 747/887] Fixing a flaky test that fails on 17th of June. --- test/ut3_user/expectations/binary/test_to_be_within.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_user/expectations/binary/test_to_be_within.pkb b/test/ut3_user/expectations/binary/test_to_be_within.pkb index 032b684a5..c9aae6ee2 100644 --- a/test/ut3_user/expectations/binary/test_to_be_within.pkb +++ b/test/ut3_user/expectations/binary/test_to_be_within.pkb @@ -199,7 +199,7 @@ create or replace package body test_to_be_within is begin --Arrange --Act - ut3_develop.ut.expect(sysdate).to_be_within(INTERVAL '1' MONTH).of_(sysdate+ 46); + ut3_develop.ut.expect(sysdate).to_be_within(INTERVAL '1' MONTH).of_(sysdate+ 47); --Assert l_expected_message := q'[Actual: % (date) was expected to be within 1 month of % (date)]'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); From b0b3ba0d0a2be055d3e1def171bc68b48ba7dc3f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 17 Jul 2026 07:43:15 +0100 Subject: [PATCH 748/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index a6f7eb75d..bc14fa04a 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4512 +4514 diff --git a/docs/about/authors.md b/docs/about/authors.md index e4d72f7ab..4c2d13cb4 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 0a63ab01d..ef6a8ee5f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 5afa5c7ba..b45647ecd 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index be39fff34..161f636cc 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index c60c9e2b5..2f932b678 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index a74a08e34..7e888036d 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 813cf6601..f707f852a 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index e9f3dbcb8..a43821aaf 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index bd86455a6..7871c1224 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index cdebc1cb1..eeb6ee01d 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 2c3472002..5f8cf1195 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 61939d994..9c320acbf 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 244b41e8b..3ab19b337 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 098a3d59f..f079d85a9 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index d9309cc37..0d7008f07 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 1bdab653e..a26cccad7 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index f93aae476..f104b173c 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4512--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 6dd79147c..e15fdf28c 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4512-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4514-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 35a799486163b1e11ea20c768bd1b373dfa05d69 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 17 Jul 2026 08:14:14 +0100 Subject: [PATCH 749/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index bc14fa04a..8c83c7141 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4514 +4515 diff --git a/docs/about/authors.md b/docs/about/authors.md index 4c2d13cb4..886818b8b 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index ef6a8ee5f..b73176d7f 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index b45647ecd..a8be1883d 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 161f636cc..a410cb65a 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 2f932b678..4c94f715a 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 7e888036d..551d711d5 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index f707f852a..a3faf9a00 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index a43821aaf..01f10ce57 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 7871c1224..0a009177e 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index eeb6ee01d..e8bdb0454 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 5f8cf1195..20c0ac564 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 9c320acbf..654f9ecae 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 3ab19b337..6b661e7b7 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index f079d85a9..70906e02c 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 0d7008f07..76a645f98 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a26cccad7..01d3bfb62 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index f104b173c..34403731c 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4514--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index e15fdf28c..398f501b4 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4514-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4515-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 1410b66794fb3a61106512ee378690d40f5c9496 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sat, 18 Jul 2026 12:33:36 +0700 Subject: [PATCH 750/887] Update a feature template --- .github/DISCUSSION_TEMPLATE/feature-requests.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/DISCUSSION_TEMPLATE/feature-requests.yml b/.github/DISCUSSION_TEMPLATE/feature-requests.yml index 130d30c28..b07a043b5 100644 --- a/.github/DISCUSSION_TEMPLATE/feature-requests.yml +++ b/.github/DISCUSSION_TEMPLATE/feature-requests.yml @@ -24,7 +24,6 @@ body: attributes: label: Proposed solution description: Describe the feature you have in mind. Include examples of how it would be used, ideally with PL/SQL annotation or API examples. - render: sql validations: required: true From 748e947b8d13bdf54103ad4a79a29a34a0d21399 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 18 Jul 2026 06:40:38 +0100 Subject: [PATCH 751/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 8c83c7141..b193f399e 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4515 +4516 diff --git a/docs/about/authors.md b/docs/about/authors.md index 886818b8b..c897cd536 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index b73176d7f..ef66340e6 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index a8be1883d..a24adbb12 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index a410cb65a..909d32793 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 4c94f715a..6bd63f2e8 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 551d711d5..bbd246bcd 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index a3faf9a00..ba0d182c7 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 01f10ce57..a6882dba5 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0a009177e..e55d9f509 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index e8bdb0454..ce1f3ee6b 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 20c0ac564..b5adfca4a 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 654f9ecae..ffb3d8015 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 6b661e7b7..e49c46028 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 70906e02c..500f65575 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 76a645f98..d8b4551bb 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 01d3bfb62..a20137ce0 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 34403731c..e38722d5f 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4515--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 398f501b4..ce80cfc36 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4515-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4516-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 122756aa8debe7cca80ed051cba14db41c0e5ee7 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 24 Jul 2026 08:30:44 +0100 Subject: [PATCH 752/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index b193f399e..4d4bc2f8d 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4516 +4517 diff --git a/docs/about/authors.md b/docs/about/authors.md index c897cd536..ff5b24f23 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index ef66340e6..6414276e5 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index a24adbb12..611448d6a 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 909d32793..3903b74fd 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 6bd63f2e8..fdf4e8649 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index bbd246bcd..03f8bd720 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index ba0d182c7..9cf89337e 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index a6882dba5..0b3b09da1 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index e55d9f509..85653f9e3 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index ce1f3ee6b..11d18882a 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index b5adfca4a..d67d1058e 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index ffb3d8015..2e3f7ee84 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index e49c46028..9bf2c7ca3 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 500f65575..c5d52a5f1 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index d8b4551bb..cb297734e 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a20137ce0..6f35174b6 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e38722d5f..543867e86 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4516--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index ce80cfc36..8c849d125 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4516-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4517-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ce2e66dc391b6a0ed55ea77420d78e63cba09018 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 31 Jul 2026 08:50:01 +0100 Subject: [PATCH 753/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4d4bc2f8d..d9cce5710 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4517 +4518 diff --git a/docs/about/authors.md b/docs/about/authors.md index ff5b24f23..d07dd68b9 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 6414276e5..7bfaeea29 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) # Version Information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 611448d6a..809f11a8d 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index 3903b74fd..b3fdc0493 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index fdf4e8649..118d7f7c8 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 03f8bd720..27d3b5b00 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 9cf89337e..956e67a67 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0b3b09da1..ba68d5a76 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 85653f9e3..5508c79d7 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 11d18882a..31024b258 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index d67d1058e..7bc0009f4 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 2e3f7ee84..63a5edf8e 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 9bf2c7ca3..6a270fb8d 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c5d52a5f1..72304acb2 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index cb297734e..406766b1b 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 6f35174b6..dae45be2b 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 543867e86..756461eed 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4517--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 8c849d125..accc8e685 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4517-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4518-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 3e3e3617035f83e706e1fd9fb23dbc4014fe240a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 3 Aug 2026 23:24:44 +0800 Subject: [PATCH 754/887] Update licensing document. --- docs/about/license.md | 16 +++++++++------- docs/about/project-details.md | 4 ++-- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/docs/about/license.md b/docs/about/license.md index 7bfaeea29..77f698699 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,13 +1,15 @@ ![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) -# Version Information +# Licensing information -**utPLSQL version 3** is licensed under -[Apache 2.0](https://www.apache.org/licenses/LICENSE-2.0) +## Framework licensing -External code used in the development of this project, but is not required for use. +**utPLSQL** framework is licensed under [Apache 2.0](https://www.apache.org/licenses/LICENSE-2.0) license. -| Tool | License | Purpose | -| ---- | --------| --------| -| [mkDocs](http://www.mkdocs.org/) | [BSD](http://www.mkdocs.org/about/license/) | Produce HTML version of documentation | +## Third party products + +| Tool | License | Purpose | +|--------------------------------------------------------------------|-------------------------------------------------------------|-----------------------------------| +| [mkDocs](http://www.mkdocs.org/) | [BSD](http://www.mkdocs.org/about/license/) | Project website and documentation | +| [material-for-mkdocs](https://squidfunk.github.io/mkdocs-material/)| [MIT](https://squidfunk.github.io/mkdocs-material/license/) | Project website and documentation | diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 809f11a8d..7c71e4518 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -2,11 +2,11 @@ # utPLSQL Project Details -[![chat](http://img.shields.io/badge/GitHub_Project-Active-blue.svg)](https://github.com/utPLSQL/utPLSQL) +[![lssues](http://img.shields.io/badge/GitHub_Project-Active-blue.svg)](https://github.com/utPLSQL/utPLSQL/issues) [![license](http://img.shields.io/badge/license-apache%202.0-blue.svg)](https://www.apache.org/licenses/LICENSE-2.0) [![GitHub Discussions](https://img.shields.io/github/discussions/utPLSQL/utPLSQL)](https://github.com/utPLSQL/utPLSQL/discussions) [![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) - +[![linkedIn](https://img.shields.io/badge/LinkedIn-Follow-blue?logo=linkedin)]([https://twitter.com/utPLSQL](https://www.linkedin.com/company/utplsql/)) utPLSQL is open source project [hosted on GitHub](https://github.com/utPLSQL/utPLSQL). From 3820472d5b12d1c66962f731870ac90452865d7f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 3 Aug 2026 16:31:47 +0100 Subject: [PATCH 755/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/about/authors.md | 2 +- docs/about/license.md | 2 +- docs/about/project-details.md | 2 +- docs/about/support.md | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 19 files changed, 19 insertions(+), 19 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index d9cce5710..d006b5a61 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4518 +4519 diff --git a/docs/about/authors.md b/docs/about/authors.md index d07dd68b9..3b384954a 100644 --- a/docs/about/authors.md +++ b/docs/about/authors.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) ### utPLSQL v3 Major Contributors diff --git a/docs/about/license.md b/docs/about/license.md index 77f698699..4c19b37bf 100644 --- a/docs/about/license.md +++ b/docs/about/license.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) # Licensing information diff --git a/docs/about/project-details.md b/docs/about/project-details.md index 7c71e4518..269c81c88 100644 --- a/docs/about/project-details.md +++ b/docs/about/project-details.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) # utPLSQL Project Details diff --git a/docs/about/support.md b/docs/about/support.md index b3fdc0493..6521292c7 100644 --- a/docs/about/support.md +++ b/docs/about/support.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) # How to get support diff --git a/docs/index.md b/docs/index.md index 118d7f7c8..f156785f4 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 27d3b5b00..515014d5f 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 956e67a67..ad9b16c59 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index ba68d5a76..0df56e0b7 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 5508c79d7..8fff76c9d 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 31024b258..939c7c794 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 7bc0009f4..47d9db4de 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 63a5edf8e..ad96c791d 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 6a270fb8d..16d0966d0 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 72304acb2..c0c266f5e 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 406766b1b..3cb3bd0fc 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index dae45be2b..0bda2f752 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 756461eed..eca079e92 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4518--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index accc8e685..89b21cf00 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4518-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4519-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From fc3c065bbb98d0ff26255f4a31764410980ec000 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 4 Aug 2026 00:27:43 +0800 Subject: [PATCH 756/887] Removing About from the project documentation pages as it is moved to the org page. --- docs/about/authors.md | 26 -------------------------- docs/about/license.md | 15 --------------- docs/about/project-details.md | 18 ------------------ docs/about/support.md | 7 ------- mkdocs.yml | 5 ----- mkdocs_offline.yml | 5 ----- readme.md | 2 +- 7 files changed, 1 insertion(+), 77 deletions(-) delete mode 100644 docs/about/authors.md delete mode 100644 docs/about/license.md delete mode 100644 docs/about/project-details.md delete mode 100644 docs/about/support.md diff --git a/docs/about/authors.md b/docs/about/authors.md deleted file mode 100644 index 3b384954a..000000000 --- a/docs/about/authors.md +++ /dev/null @@ -1,26 +0,0 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) - -### utPLSQL v3 Major Contributors - -**Listed Alphabetically** - -| Name | GitHub account -| ---------------- | -------------- -| David Pyke | [Shoelace](https://github.com/Shoelace) -| Jacek Gebal | [jgebal](https://github.com/jgebal) -| Lukasz Wasylow | [lwasylow](https://github.com/lwasylow/) -| Pavel Kaplya | [Pazus](https://github.com/Pazus) -| Robert Love | [rlove](https://github.com/rlove) -| Samuel Nitsche | [pesse](https://github.com/pesse/) -| Vinicius Avellar | [viniciusam](https://github.com/viniciusam/) - - - -Many thanks to all the [contributors](https://github.com/utPLSQL/utPLSQL/graphs/contributors) - -### Special thanks to prior major contributors - -- Steven Feuerstein - Original Author of utPLSQL v1 and v2 -- Chris Rimmer -- Patrick Barel -- Paul Walker diff --git a/docs/about/license.md b/docs/about/license.md deleted file mode 100644 index 4c19b37bf..000000000 --- a/docs/about/license.md +++ /dev/null @@ -1,15 +0,0 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) - -# Licensing information - -## Framework licensing - -**utPLSQL** framework is licensed under [Apache 2.0](https://www.apache.org/licenses/LICENSE-2.0) license. - -## Third party products - -| Tool | License | Purpose | -|--------------------------------------------------------------------|-------------------------------------------------------------|-----------------------------------| -| [mkDocs](http://www.mkdocs.org/) | [BSD](http://www.mkdocs.org/about/license/) | Project website and documentation | -| [material-for-mkdocs](https://squidfunk.github.io/mkdocs-material/)| [MIT](https://squidfunk.github.io/mkdocs-material/license/) | Project website and documentation | - diff --git a/docs/about/project-details.md b/docs/about/project-details.md deleted file mode 100644 index 269c81c88..000000000 --- a/docs/about/project-details.md +++ /dev/null @@ -1,18 +0,0 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) - -# utPLSQL Project Details - -[![lssues](http://img.shields.io/badge/GitHub_Project-Active-blue.svg)](https://github.com/utPLSQL/utPLSQL/issues) -[![license](http://img.shields.io/badge/license-apache%202.0-blue.svg)](https://www.apache.org/licenses/LICENSE-2.0) -[![GitHub Discussions](https://img.shields.io/github/discussions/utPLSQL/utPLSQL)](https://github.com/utPLSQL/utPLSQL/discussions) -[![twitter](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) -[![linkedIn](https://img.shields.io/badge/LinkedIn-Follow-blue?logo=linkedin)]([https://twitter.com/utPLSQL](https://www.linkedin.com/company/utplsql/)) - -utPLSQL is open source project [hosted on GitHub](https://github.com/utPLSQL/utPLSQL). - -Contributions, help and constructive feedback is always appreciated. - -If you are interested in helping please read our [contributing guide](https://github.com/utPLSQL/utPLSQL/blob/develop/CONTRIBUTING.md) - - - diff --git a/docs/about/support.md b/docs/about/support.md deleted file mode 100644 index 6521292c7..000000000 --- a/docs/about/support.md +++ /dev/null @@ -1,7 +0,0 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) - -# How to get support - -- Look into [utPLSQL github discussions](https://github.com/utPLSQL/utPLSQL/discussions) to find support, ask questions and share ideas -- If needed open a new [issue on github](https://github.com/utPLSQL/utPLSQL/issues) for bugs or feature requests - diff --git a/mkdocs.yml b/mkdocs.yml index 44b823cdf..96f0b8ca2 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -122,8 +122,3 @@ nav: - Using reporters: userguide/reporters.md - Code coverage: userguide/coverage.md - Error handling and reporting: userguide/exception-reporting.md - - About: - - Project Details: about/project-details.md - - License: about/license.md - - Support: about/support.md - - Authors: about/authors.md diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index 4429d68f5..82304041c 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -97,8 +97,3 @@ nav: - Using reporters: userguide/reporters.md - Code coverage: userguide/coverage.md - Error handling and reporting: userguide/exception-reporting.md - - About: - - Project Details: about/project-details.md - - License: about/license.md - - Support: about/support.md - - Authors: about/authors.md diff --git a/readme.md b/readme.md index f0c079566..e1533e607 100644 --- a/readme.md +++ b/readme.md @@ -136,5 +136,5 @@ We welcome contributions of all kinds. Please read the [contributing guide](CONT [GitHub Discussions](https://github.com/utPLSQL/utPLSQL/discussions) is the place to ask questions and connect with the team. -The list of **authors** and **significant contributors** is available [here](docs/about/authors.md). For a full list of contributors, see [contributors](https://github.com/utPLSQL/utPLSQL/graphs/contributors?all=1) on GitHub. +The list of **authors** and **significant contributors** is available on the [About](https://www.utplsql.org/about/) page. For a full list of contributors, see [contributors](https://github.com/utPLSQL/utPLSQL/graphs/contributors?all=1) on GitHub. From f7c7f397bfc51f96d56706367ff5fff959145ee9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 3 Aug 2026 17:35:27 +0100 Subject: [PATCH 757/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index d006b5a61..326ad9316 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4519 +4520 diff --git a/docs/index.md b/docs/index.md index f156785f4..e4b6b67b4 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 515014d5f..9d1a2dd2e 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index ad9b16c59..27098f8b4 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0df56e0b7..ca8aaddb8 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 8fff76c9d..8e64fbccc 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 939c7c794..466630809 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 47d9db4de..905e17123 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index ad96c791d..8025dc39d 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 16d0966d0..2fa4f8536 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c0c266f5e..9bab1eb94 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3cb3bd0fc..2312575cb 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 0bda2f752..db396dec6 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index eca079e92..45eb608b1 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4519--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 89b21cf00..19f0bba73 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4519-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4520-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 13dd185fd5ac935ffb61c4561e1c83dac091e4c5 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 7 Aug 2026 07:09:31 +0100 Subject: [PATCH 758/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 326ad9316..770443906 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4520 +4521 diff --git a/docs/index.md b/docs/index.md index e4b6b67b4..4a36ee7be 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 9d1a2dd2e..4c5e341f3 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 27098f8b4..1351dc11d 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index ca8aaddb8..b0615f3b7 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 8e64fbccc..56bf8f93f 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 466630809..321aad2ba 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 905e17123..ba2dd1e26 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 8025dc39d..50c23907a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 2fa4f8536..7dc528dc7 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 9bab1eb94..164ff50c0 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 2312575cb..9bb1c59f3 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index db396dec6..439ecd12d 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 45eb608b1..ddde10e30 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4520--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 19f0bba73..c03662d0f 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4520-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4521-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From d59629322a73d2887e34a15025c653d5cd607cc5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 13 Aug 2026 13:14:07 +0800 Subject: [PATCH 759/887] Adding git commiters plugin to mkdocs.yml --- .github/workflows/build.yml | 1 + .github/workflows/rebuild_docs.yml | 1 + .github/workflows/release.yml | 1 + mkdocs.yml | 4 ++++ 4 files changed, 7 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8e9a08506..3ca9f34d2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -273,6 +273,7 @@ jobs: pip install mkdocs-git-revision-date-localized-plugin pip install mkdocs-material pip install git+https://github.com/jimporter/mike.git + pip install mkdocs-git-committers-plugin-2 mike deploy -p develop dispatch: diff --git a/.github/workflows/rebuild_docs.yml b/.github/workflows/rebuild_docs.yml index 93e3fa6ed..b9f3e4c45 100644 --- a/.github/workflows/rebuild_docs.yml +++ b/.github/workflows/rebuild_docs.yml @@ -44,6 +44,7 @@ jobs: pip install mkdocs-git-revision-date-localized-plugin pip install mkdocs-material pip install git+https://github.com/jimporter/mike.git + pip install mkdocs-git-committers-plugin-2 - name: Rebuild specified versions run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 58eb10ad4..7df03680d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -48,6 +48,7 @@ jobs: pip install mkdocs-git-revision-date-localized-plugin pip install mkdocs-material pip install git+https://github.com/jimporter/mike.git + pip install mkdocs-git-committers-plugin-2 mike deploy -p -u ${UTPLSQL_VERSION} latest mkdocs build --clean -f mkdocs_offline.yml rm -rf docs/* diff --git a/mkdocs.yml b/mkdocs.yml index 96f0b8ca2..16fe0c526 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -101,6 +101,10 @@ strict: true plugins: - search + - git-committers: + repository: utPLSQL/utPLSQL + branch: main + token: !ENV ["API_TOKEN_GITHUB"] - mike - git-revision-date-localized: # disable for offline docs enable_creation_date: true # disable for offline docs From 7ed4c9897c669881259fb4a163361787a17ba56f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 13 Aug 2026 06:21:42 +0100 Subject: [PATCH 760/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 770443906..146f070cd 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4521 +4522 diff --git a/docs/index.md b/docs/index.md index 4a36ee7be..4a429aa1b 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 4c5e341f3..dabd613c8 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 1351dc11d..ccdb16e12 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index b0615f3b7..082cbbefd 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 56bf8f93f..6eb83c781 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 321aad2ba..18fa0132c 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index ba2dd1e26..e0c873040 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 50c23907a..c04e11c5f 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 7dc528dc7..ca1dd193c 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 164ff50c0..9a37a5c59 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 9bb1c59f3..734104d02 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 439ecd12d..33485f09f 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index ddde10e30..fee9e64ef 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4521--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index c03662d0f..9bde1c71d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4521-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4522-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 078a1cfe96f683c3a9a3662eca0181f66b492667 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 13 Aug 2026 13:28:43 +0800 Subject: [PATCH 761/887] Adding git commiters plugin to mkdocs.yml --- mkdocs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mkdocs.yml b/mkdocs.yml index 16fe0c526..c0756c703 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -103,7 +103,7 @@ plugins: - search - git-committers: repository: utPLSQL/utPLSQL - branch: main + branch: develop token: !ENV ["API_TOKEN_GITHUB"] - mike - git-revision-date-localized: # disable for offline docs From 303e5cf2abe1cc0f65424f0fda1abd421132d331 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 13 Aug 2026 06:35:41 +0100 Subject: [PATCH 762/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 146f070cd..1f440269b 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4522 +4523 diff --git a/docs/index.md b/docs/index.md index 4a429aa1b..27601d28f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index dabd613c8..37c80a486 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index ccdb16e12..dd64a08a3 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 082cbbefd..95a5339a1 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 6eb83c781..3fe0d1fd1 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 18fa0132c..36e99b8ea 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index e0c873040..3148ba3ae 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index c04e11c5f..d4a0fcfb7 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ca1dd193c..110e651a8 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 9a37a5c59..851cd9d21 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 734104d02..3ba76ab63 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 33485f09f..1b1d14f71 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index fee9e64ef..c68894129 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4522--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 9bde1c71d..2a7b932d7 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4522-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4523-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 2acb343eaabb419583d53d9fc93745d42d950eb7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 13 Aug 2026 13:37:34 +0800 Subject: [PATCH 763/887] Excludding bot commiters from documentation --- mkdocs.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mkdocs.yml b/mkdocs.yml index c0756c703..0c712ac1e 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -105,6 +105,9 @@ plugins: repository: utPLSQL/utPLSQL branch: develop token: !ENV ["API_TOKEN_GITHUB"] + exclude_committers: + - github-actions[bot] + - web-flow - mike - git-revision-date-localized: # disable for offline docs enable_creation_date: true # disable for offline docs From 0ff3f3925b79bd0e400268ca9c95d392e6191de6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 13 Aug 2026 06:44:54 +0100 Subject: [PATCH 764/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 1f440269b..b468192c9 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4523 +4524 diff --git a/docs/index.md b/docs/index.md index 27601d28f..863df1fcf 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 37c80a486..d728ee994 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index dd64a08a3..05239b77a 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 95a5339a1..367ae28fc 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 3fe0d1fd1..a7a3e6ff5 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 36e99b8ea..7daed9e9f 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3148ba3ae..244bfa2d3 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index d4a0fcfb7..27798bbda 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 110e651a8..79c210436 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 851cd9d21..c2f62af69 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 3ba76ab63..e9c953bde 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 1b1d14f71..0bd66e044 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index c68894129..4da8f62d8 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4523--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 2a7b932d7..2e42527a3 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4523-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4524-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 26fa09f4b02e138e95a01b0cd2781ef5ebe10b83 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 14 Aug 2026 07:13:12 +0100 Subject: [PATCH 765/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index b468192c9..de1a6219d 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4524 +4525 diff --git a/docs/index.md b/docs/index.md index 863df1fcf..126a24ba8 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index d728ee994..b2b6d87c0 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 05239b77a..7ae590e55 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 367ae28fc..85d36feb7 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index a7a3e6ff5..10b6a5c15 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 7daed9e9f..7f6d02ad5 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 244bfa2d3..87c66dc46 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 27798bbda..67dce732e 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 79c210436..76839abaf 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c2f62af69..644a13124 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index e9c953bde..d14fe6038 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 0bd66e044..73bc255f2 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 4da8f62d8..b57174e3e 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4524--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 2e42527a3..4aee80502 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4524-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4525-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 36df202cbb870c28e1330021c7a788edf670bd45 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 19 Aug 2026 11:39:31 +0800 Subject: [PATCH 766/887] Fixed dead links and reporters descriptions. --- source/reporters/ut_coverage_cobertura_reporter.tpb | 7 +++---- source/reporters/ut_coverage_sonar_reporter.tpb | 6 +++--- source/reporters/ut_documentation_reporter.tpb | 2 +- source/reporters/ut_realtime_reporter.tpb | 10 +++++----- source/reporters/ut_sonar_test_reporter.tpb | 6 +++--- source/reporters/ut_tfs_junit_reporter.tpb | 6 +++--- 6 files changed, 18 insertions(+), 19 deletions(-) diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index 45c1935b1..c2021974d 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -181,10 +181,9 @@ create or replace noneditionable type body ut_coverage_cobertura_reporter is overriding member function get_description return varchar2 as begin - return 'Generates a Cobertura coverage report providing information on code coverage with line numbers.' || chr(10) || - 'Designed for Jenkins and TFS to report coverage. ' || chr(10) || - 'Cobertura Document Type Definition can be found: http://cobertura.sourceforge.net/xml/coverage-04.dtd.'|| chr(10) || - 'Sample file: https://github.com/leobalter/testing-examples/blob/master/solutions/3/report/cobertura-coverage.xml.'; + return 'Generates Cobertura report on code coverage with line numbers. +Compatible with GitHub Actions, Jenkins, Azure Pipelines, GitLab CI, and any tool that reads the popular Cobertura format. +Cobertura Document Type Definition is located [here](https://github.com/cobertura/cobertura/blob/master/cobertura/src/site/htdocs/xml/coverage-04.dtd).'; end; end; diff --git a/source/reporters/ut_coverage_sonar_reporter.tpb b/source/reporters/ut_coverage_sonar_reporter.tpb index a070572b7..66c4aacf0 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tpb +++ b/source/reporters/ut_coverage_sonar_reporter.tpb @@ -103,9 +103,9 @@ create or replace noneditionable type body ut_coverage_sonar_reporter is overriding member function get_description return varchar2 as begin - return 'Generates a XML coverage report providing information on code coverage with line numbers.' || chr(10) || - 'Designed for [SonarQube](https://www.sonarqube.org/) to report coverage.' || chr(10) || - 'XML format returned conforms with the Sonar specification: https://docs.sonarqube.org/latest/analysis/generic-test/'; + return 'Generates an XML coverage report providing information on code coverage with line numbers. +Designed for [SonarQube](https://www.sonarsource.com/products/sonarqube/) to report coverage. +XML format returned conforms with the [Sonar specification](https://docs.sonarsource.com/sonarqube-server/analyzing-source-code/test-coverage/generic-test-data).'; end; end; diff --git a/source/reporters/ut_documentation_reporter.tpb b/source/reporters/ut_documentation_reporter.tpb index 83152ea1c..c13cc56ef 100644 --- a/source/reporters/ut_documentation_reporter.tpb +++ b/source/reporters/ut_documentation_reporter.tpb @@ -222,7 +222,7 @@ create or replace noneditionable type body ut_documentation_reporter is overriding member function get_description return varchar2 as begin - return 'A textual pretty-print of unit test results (usually use for console output)'; + return 'Creates a textual, pretty-print, human-readable report mirroring the suite hierarchy. Used for console runs, interactive development and log review.'; end; end; diff --git a/source/reporters/ut_realtime_reporter.tpb b/source/reporters/ut_realtime_reporter.tpb index a8b7c566e..da0f37077 100644 --- a/source/reporters/ut_realtime_reporter.tpb +++ b/source/reporters/ut_realtime_reporter.tpb @@ -204,11 +204,6 @@ create or replace noneditionable type body ut_realtime_reporter is self.flush_print_buffer('post-test'); end after_calling_test; - overriding member function get_description return varchar2 is - begin - return 'Provides test results in a XML format, for clients such as SQL Developer interested in showing progressing details.'; - end get_description; - member procedure print_start_node( self in out nocopy ut_realtime_reporter, a_node_name in varchar2, @@ -284,5 +279,10 @@ create or replace noneditionable type body ut_realtime_reporter is print_buffer.delete; end flush_print_buffer; + overriding member function get_description return varchar2 is + begin + return 'Provides live test execution progress that can be consumed from another session, enabling clients such as SQL Developer to show progress in real time as tests run.'; + end get_description; + end; / diff --git a/source/reporters/ut_sonar_test_reporter.tpb b/source/reporters/ut_sonar_test_reporter.tpb index da29b629d..8d232b87e 100644 --- a/source/reporters/ut_sonar_test_reporter.tpb +++ b/source/reporters/ut_sonar_test_reporter.tpb @@ -106,9 +106,9 @@ create or replace noneditionable type body ut_sonar_test_reporter is overriding member function get_description return varchar2 as begin - return 'Generates a XML report providing detailed information on test execution.' || chr(10) || - 'Designed for [SonarQube](https://www.sonarqube.org/) to report test execution.' || chr(10) || - 'XML format returned conforms with the Sonar specification: https://docs.sonarqube.org/latest/analysis/generic-test/'; + return 'Generates an XML report providing detailed information on test execution. +Designed for [SonarQube](https://www.sonarsource.com/products/sonarqube/) to report test execution. +XML format returned conforms with the [Sonar specification](https://docs.sonarsource.com/sonarqube-server/analyzing-source-code/test-coverage/generic-test-data).'; end; end; diff --git a/source/reporters/ut_tfs_junit_reporter.tpb b/source/reporters/ut_tfs_junit_reporter.tpb index 5e24b2dca..a4c8fb868 100644 --- a/source/reporters/ut_tfs_junit_reporter.tpb +++ b/source/reporters/ut_tfs_junit_reporter.tpb @@ -171,9 +171,9 @@ create or replace noneditionable type body ut_tfs_junit_reporter is overriding member function get_description return varchar2 as begin - return 'Provides outcomes in a format conforming with JUnit version for TFS / VSTS. - As defined by specs :https://docs.microsoft.com/en-us/vsts/build-release/tasks/test/publish-test-results?view=vsts - Version is based on windy road junit https://github.com/windyroad/JUnit-Schema/blob/master/JUnit.xsd.'; + return 'Provides outcomes in a format conforming with JUnit version for TFS / VSTS +as defined by [specification](https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/reference/publish-test-results-v2?view=azure-pipelines) +The implementation is based on [windyroad junit schema](https://github.com/windyroad/JUnit-Schema/blob/master/JUnit.xsd).'; end; end; From bf191227d4280d6038cec77a4998e887e6d98a63 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 21 Aug 2026 09:48:46 +0800 Subject: [PATCH 767/887] Update documentation page settings --- mkdocs.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/mkdocs.yml b/mkdocs.yml index 0c712ac1e..f18f74ce3 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -42,6 +42,10 @@ theme: - toc.integrate - search.suggest - search.highlight + - content.code.copy + - content.code.annotate + - content.code.select + extra: # homepage: https://www.utPLSQL.org/ # sets scope of cookies to use a common path (root) @@ -86,11 +90,13 @@ extra: markdown_extensions: - admonition - pymdownx.details - - pymdownx.superfences - pymdownx.highlight: anchor_linenums: true + line_spans: __span + pygments_lang_class: true - pymdownx.inlinehilite - pymdownx.snippets + - pymdownx.superfences - pymdownx.caret - pymdownx.mark - pymdownx.tilde From efe1d3b2b777319a19accda423b42cd721735bd3 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 21 Aug 2026 02:55:22 +0100 Subject: [PATCH 768/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index de1a6219d..992a491ef 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4525 +4527 diff --git a/docs/index.md b/docs/index.md index 126a24ba8..018b68f97 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index b2b6d87c0..493c3ee03 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 7ae590e55..ea9c78304 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 85d36feb7..32477e522 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 10b6a5c15..7b55490c7 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 7f6d02ad5..5764cb682 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 87c66dc46..3baed6b48 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 67dce732e..0d3348f43 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 76839abaf..e305cebb4 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 644a13124..8e6311e1b 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index d14fe6038..615af2e48 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 73bc255f2..2ebab0125 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index b57174e3e..a2cd4509d 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4525--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4aee80502..59423c3d6 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4525-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4527-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From eb2040021381497b39d4bbfb63f603e141997740 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 21 Aug 2026 06:28:11 +0100 Subject: [PATCH 769/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 992a491ef..14857d14c 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4527 +4528 diff --git a/docs/index.md b/docs/index.md index 018b68f97..e9b1c813c 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 493c3ee03..ec0ecfd5b 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index ea9c78304..5d039c825 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 32477e522..1526df27b 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 7b55490c7..6f7c480a0 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 5764cb682..1b1d0dd00 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 3baed6b48..e5d2a2374 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 0d3348f43..0d6fa8ce5 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index e305cebb4..faa972deb 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 8e6311e1b..db905b475 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 615af2e48..f14d28216 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 2ebab0125..a69b029b8 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index a2cd4509d..7c817c556 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4527--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 59423c3d6..963c57bf9 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4527-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4528-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 8d3b3c1d6dfdd56c7f2e793e8f07765594bd697c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 28 Aug 2026 18:04:05 +0100 Subject: [PATCH 770/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 14857d14c..e6bb77876 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4528 +4529 diff --git a/docs/index.md b/docs/index.md index e9b1c813c..22c33e14d 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index ec0ecfd5b..608e877fa 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 5d039c825..aad225f72 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 1526df27b..5fd2d22d5 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 6f7c480a0..3a2d5a5f6 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 1b1d0dd00..68e737ef3 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index e5d2a2374..0ba407d37 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 0d6fa8ce5..3ca954dcc 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index faa972deb..8490ee87b 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index db905b475..0eed4fdf7 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index f14d28216..132471e33 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a69b029b8..51a42b1e6 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 7c817c556..6764249a7 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4528--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 963c57bf9..e9a64c45d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4528-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4529-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From dc182cb85bca0d8db62e67eb5a57da89dd066aa6 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 4 Sep 2026 10:16:01 +0100 Subject: [PATCH 771/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index e6bb77876..c0ec9d83c 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4529 +4530 diff --git a/docs/index.md b/docs/index.md index 22c33e14d..49daf4b2f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 608e877fa..78056faaf 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index aad225f72..fac1ecdab 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 5fd2d22d5..8cadca5eb 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 3a2d5a5f6..53fdd4a48 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 68e737ef3..9a9231e64 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 0ba407d37..87ed81360 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 3ca954dcc..9144351a3 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 8490ee87b..dbeea04cc 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 0eed4fdf7..f02f38b63 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 132471e33..fbd2dc00e 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 51a42b1e6..1a4983fe6 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index 6764249a7..ccc6ab54c 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4529--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index e9a64c45d..4d86e5bb1 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4529-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4530-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 3c8a7161f7d5e262e89e0f1f04e90b2045ded3a1 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 11 Sep 2026 10:19:30 +0100 Subject: [PATCH 772/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index c0ec9d83c..2850d73c8 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4530 +4531 diff --git a/docs/index.md b/docs/index.md index 49daf4b2f..7db578910 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 78056faaf..a22cc4d17 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index fac1ecdab..b9cfb724c 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 8cadca5eb..cf45b2d88 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 53fdd4a48..42f8a2f69 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 9a9231e64..cdb2352c8 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 87ed81360..2a318204e 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 9144351a3..29c8cb028 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index dbeea04cc..70a4eaa2c 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index f02f38b63..8f011d057 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index fbd2dc00e..34d97201f 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 1a4983fe6..d946a47fe 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index ccc6ab54c..a01924827 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4530--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 4d86e5bb1..e469a207c 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4530-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4531-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From ee58003199f736d1395c9a328f26b3d921bde82f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 15 Sep 2026 12:20:50 +0300 Subject: [PATCH 773/887] Fix code of conduct link in contributing section Updated the code of conduct link to point to the correct URL. --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index e1533e607..ac4dc9815 100644 --- a/readme.md +++ b/readme.md @@ -132,7 +132,7 @@ Migrating from legacy utPLSQL v2? See the [version 2 to version 3 comparison](do ## Contributing -We welcome contributions of all kinds. Please read the [contributing guide](CONTRIBUTING.md) and the [code of conduct](CODE_OF_CONDUCT.md) before getting started. +We welcome contributions of all kinds. Please read the [contributing guide](CONTRIBUTING.md) and the [code of conduct](https://github.com/utPLSQL/utPLSQL?tab=coc-ov-file) before getting started. [GitHub Discussions](https://github.com/utPLSQL/utPLSQL/discussions) is the place to ask questions and connect with the team. From fa468a6153014084be9357927aba817f0e7be12f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 15 Sep 2026 10:29:35 +0100 Subject: [PATCH 774/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 2850d73c8..697eb0993 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4531 +4532 diff --git a/docs/index.md b/docs/index.md index 7db578910..a7255f8f8 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index a22cc4d17..413cf27b3 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index b9cfb724c..838fc0890 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index cf45b2d88..c3f026d6f 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 42f8a2f69..a069fb598 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index cdb2352c8..2a98ce0b4 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 2a318204e..8849a7f47 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 29c8cb028..059ff9223 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 70a4eaa2c..649d7a6ca 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 8f011d057..99ff5f044 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 34d97201f..92c62cf72 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index d946a47fe..79671247e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index a01924827..db02d6c50 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4531--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index e469a207c..46c28f0f0 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4531-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4532-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 48f56f7d11b865b9f64099b1d64f13f52560988c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 18 Sep 2026 10:22:31 +0100 Subject: [PATCH 775/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 697eb0993..4cdd5d805 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4532 +4533 diff --git a/docs/index.md b/docs/index.md index a7255f8f8..b5958e2db 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 413cf27b3..add061dc0 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 838fc0890..873f24c79 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index c3f026d6f..44fe585c0 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index a069fb598..19c5f8a26 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 2a98ce0b4..3cdf900a6 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 8849a7f47..1f2e51b44 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 059ff9223..255dc8486 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 649d7a6ca..fe3f73c53 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 99ff5f044..c139c67a8 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 92c62cf72..344ba2606 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 79671247e..f3b398927 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index db02d6c50..f7d8097b1 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4532--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 46c28f0f0..a062c8122 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4532-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4533-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 04163956054d4ad4568d64438c52b1c50cbe384d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 25 Sep 2026 10:59:56 +0100 Subject: [PATCH 776/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4cdd5d805..4f1c9aa7a 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4533 +4534 diff --git a/docs/index.md b/docs/index.md index b5958e2db..4ef0dcbd1 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index add061dc0..ff23ac60e 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 873f24c79..3c2750cd4 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 44fe585c0..3de74bfa1 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 19c5f8a26..0ec8ea7fc 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 3cdf900a6..a63d59b1a 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 1f2e51b44..2656b9204 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 255dc8486..62ea166e1 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index fe3f73c53..a4a7a20ff 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index c139c67a8..d326f1497 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 344ba2606..632d7333b 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index f3b398927..fa7ccc64d 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index f7d8097b1..e8d329825 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4533--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index a062c8122..019c052cb 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4533-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4534-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 78d036155e581207ae150bd513d6dd92c21a3da6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 28 Sep 2026 12:10:00 +0300 Subject: [PATCH 777/887] Update of release publishing script. --- .github/scripts/publish_release_post.sh | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/.github/scripts/publish_release_post.sh b/.github/scripts/publish_release_post.sh index c9bade4f4..0412a5877 100755 --- a/.github/scripts/publish_release_post.sh +++ b/.github/scripts/publish_release_post.sh @@ -1,11 +1,10 @@ #!/bin/bash # Publishes a release announcement post to utplsql.github.io. -# Creates the post file, prepends an entry to docs/index.md, -# and inserts the post into the mkdocs.yml nav. +# Creates a new post file in directory docs/announcements/posts/[year] # # Required environment variables: # API_TOKEN_GITHUB - GitHub token with write access to utPLSQL.github.io -# RELEASE_TAG - e.g. v3.2.01 +# RELEASE_TAG - e.g. v3.2.3 # RELEASE_BODY - markdown release notes (from github.event.release.body) # RELEASE_DATE - ISO-8601 publish timestamp (from github.event.release.published_at) @@ -19,12 +18,15 @@ POST_DATE=$(echo "${RELEASE_DATE}" | cut -c1-10) POST_FILENAME="${POST_DATE}-version${VERSION}-released.md" POST_TITLE="utPLSQL ${RELEASE_TAG} released" POST_NAV_TITLE="utPLSQL ${VERSION} released" -POST_PATH='docs/announcements/posts' +POST_PATH="docs/announcements/posts/${POST_DATE:0:4}" mkdir -p github_io cd github_io git clone --depth 1 "https://${API_TOKEN_GITHUB}@github.com/${GITHUB_IO_REPO}" -b "${GITHUB_IO_BRANCH}" . +# Make sure that the post directory exists +mkdir -p "${POST_PATH} + # Format the release body for the post: # 1. Convert bare GitHub issue/PR URLs to [#NUMBER](URL) # e.g. https://github.com/utPLSQL/utPLSQL/pull/1320 @@ -54,7 +56,7 @@ ${FORMATTED_BODY} [Download utPLSQL release ${RELEASE_TAG} here](https://github.com/utPLSQL/utPLSQL/releases/tag/${RELEASE_TAG}) POSTEOF -git add "${POST_PATH}/${POST_FILENAME}" docs/index.md mkdocs.yml +git add "${POST_PATH}/${POST_FILENAME}" git commit -m "Release announcement for ${RELEASE_TAG}" git push origin "${GITHUB_IO_BRANCH}" From a8e32c201a604248d75d60541e3a59283d725237 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 28 Sep 2026 10:17:05 +0100 Subject: [PATCH 778/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- source/core/ut_utils.pks | 2 +- 15 files changed, 15 insertions(+), 15 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4f1c9aa7a..75c5751d0 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4534 +4535 diff --git a/docs/index.md b/docs/index.md index 4ef0dcbd1..2aa6faabf 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index ff23ac60e..363a052ff 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 3c2750cd4..51e3d39e8 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 3de74bfa1..0663a6d64 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 0ec8ea7fc..78cdeabb4 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index a63d59b1a..91fadd126 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 2656b9204..4d787d113 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 62ea166e1..1e7705d2a 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index a4a7a20ff..39bc6ce54 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index d326f1497..87f42955d 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 632d7333b..7709e8fdf 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index fa7ccc64d..4e7faf618 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index e8d329825..bf59c1728 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4534--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) # Upgrading from version 2 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 019c052cb..b70abd64b 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4534-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4535-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 97ed573d3d8f3a59051df11bce3649f788d6ff99 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 28 Sep 2026 20:15:58 +0300 Subject: [PATCH 779/887] Skip version commit and docs deploy when nothing changed Scheduled (weekly) builds of unchanged code were creating a new "Updated project version after build" commit on develop and a new docs deployment on gh-pages each time. - Add detect_changes_since_last_publish.sh to detect new commits since the last version update and docs changes since the last develop docs deployment (based on mike's gh-pages commit message). - Run version update/commit only when there are new commits and docs deployment only when docs/ or mkdocs.yml changed. - Add force_docs_publish input to workflow_dispatch. - Exclude build number from docs version badge, so documentation only changes when the project version changes. --- .../detect_changes_since_last_publish.sh | 38 +++++++++++++++++++ .github/scripts/update_project_version.sh | 3 +- .github/workflows/build.yml | 16 +++++++- docs/index.md | 2 +- docs/userguide/advanced_data_comparison.md | 2 +- docs/userguide/annotations.md | 2 +- docs/userguide/best-practices.md | 2 +- docs/userguide/coverage.md | 2 +- docs/userguide/exception-reporting.md | 2 +- docs/userguide/expectations.md | 2 +- docs/userguide/getting-started.md | 2 +- docs/userguide/install.md | 2 +- docs/userguide/querying_suites.md | 2 +- docs/userguide/reporters.md | 2 +- docs/userguide/running-unit-tests.md | 2 +- docs/userguide/upgrade.md | 2 +- 16 files changed, 68 insertions(+), 15 deletions(-) create mode 100755 .github/scripts/detect_changes_since_last_publish.sh diff --git a/.github/scripts/detect_changes_since_last_publish.sh b/.github/scripts/detect_changes_since_last_publish.sh new file mode 100755 index 000000000..818ff89dc --- /dev/null +++ b/.github/scripts/detect_changes_since_last_publish.sh @@ -0,0 +1,38 @@ +#!/usr/bin/env bash + +# Detects what has changed since the last publish, so that builds of unchanged code +# (e.g. scheduled builds) do not produce new commits on develop and gh-pages branches. +# +# Outputs (written to $GITHUB_OUTPUT): +# project_changed - true when there are new commits since the last project version update commit +# docs_changed - true when documentation sources changed since the last deployment of documentation to gh-pages + +VERSION_COMMIT_MESSAGE='Updated project version after build [skip ci]' +DOCS_PATHS="docs mkdocs.yml" +DOCS_VERSION="develop" + +if [[ "$(git log -1 --format=%s HEAD)" == "${VERSION_COMMIT_MESSAGE}" ]]; then + echo "No new commits since last project version update." + project_changed=false +else + echo "New commits found since last project version update." + project_changed=true +fi + +# mike commits to gh-pages with message: "Deployed to with MkDocs and mike " +git fetch --quiet origin gh-pages +last_deployed_sha=$(git log -1 --format=%s --grep="^Deployed [0-9a-f]* to ${DOCS_VERSION} with MkDocs" origin/gh-pages | sed -nE "s/^Deployed ([0-9a-f]+) to .*/\1/p") + +if [[ -z "${last_deployed_sha}" ]] || ! git cat-file -e "${last_deployed_sha}^{commit}" 2>/dev/null; then + echo "Commit of last '${DOCS_VERSION}' documentation deployment not found." + docs_changed=true +elif git diff --quiet "${last_deployed_sha}" HEAD -- ${DOCS_PATHS}; then + echo "No documentation changes since last '${DOCS_VERSION}' documentation deployment from commit ${last_deployed_sha}." + docs_changed=false +else + echo "Documentation changed since last '${DOCS_VERSION}' documentation deployment from commit ${last_deployed_sha}." + docs_changed=true +fi + +echo "project_changed=${project_changed}" >> $GITHUB_OUTPUT +echo "docs_changed=${docs_changed}" >> $GITHUB_OUTPUT diff --git a/.github/scripts/update_project_version.sh b/.github/scripts/update_project_version.sh index 66e45125a..a4f27039a 100755 --- a/.github/scripts/update_project_version.sh +++ b/.github/scripts/update_project_version.sh @@ -9,7 +9,8 @@ find source -type f -name '*' -exec sed -i -r "s/${UTPLSQL_VERSION_PATTERN}/${UT echo Source files updated with version tag: ${UTPLSQL_BUILD_VERSION} echo Update version in documentation files -find docs -type f -name '*.md' -exec sed -i -r "s/(badge\/version-).*(-blue\.svg)/\1${UTPLSQL_BUILD_VERSION/-/--}\2/" {} \; +# Build number is not included in documentation, so that documentation only changes when the project version changes +find docs -type f -name '*.md' -exec sed -i -r "s/(badge\/version-).*(-blue\.svg)/\1${UTPLSQL_VERSION//-/--}\2/" {} \; echo Update of sonar-project.properties sonar.projectVersion sed -i -r "s/(sonar\.projectVersion=).*?/\1${UTPLSQL_VERSION}/" sonar-project.properties diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3ca9f34d2..011c14bf8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -9,6 +9,11 @@ on: timezone: "Europe/Nicosia" workflow_dispatch: + inputs: + force_docs_publish: + description: 'Publish develop documentation even if no documentation changes were detected' + type: boolean + default: false concurrency: ${{github.ref}} defaults: @@ -247,27 +252,36 @@ jobs: env-file: .github/variables/.env - uses: FranzDiebold/github-env-vars-action@v2.8.0 #https://github.com/marketplace/actions/github-environment-variables-action - - name: Set buid version number env variables + - name: Detect changes since last publish + id: detect-changes + run: .github/scripts/detect_changes_since_last_publish.sh + + - name: Set build version number env variables id: set-build-version-number-vars + if: steps.detect-changes.outputs.project_changed == 'true' run: .github/scripts/set_version_numbers_env.sh - name: Update project version & build number in source code and documentation id: update-project-version + if: steps.detect-changes.outputs.project_changed == 'true' run: .github/scripts/update_project_version.sh - name: Push version update to repository id: push-version-number-update + if: steps.detect-changes.outputs.project_changed == 'true' run: | git add sonar-project.properties VERSION BUILD_NO source/* docs/* git commit -m 'Updated project version after build [skip ci]' git push --quiet origin HEAD:${CI_ACTION_REF_NAME} - name: Setup git config + if: steps.detect-changes.outputs.docs_changed == 'true' || inputs.force_docs_publish run: | git config --global user.email "github-actions[bot]@users.noreply.github.com" git config --global user.name "github-actions[bot]" - name: Build and publish documentation + if: steps.detect-changes.outputs.docs_changed == 'true' || inputs.force_docs_publish run: | pip install mkdocs pip install mkdocs-git-revision-date-localized-plugin diff --git a/docs/index.md b/docs/index.md index 2aa6faabf..3f5dc6b25 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) ## What is utPLSQL diff --git a/docs/userguide/advanced_data_comparison.md b/docs/userguide/advanced_data_comparison.md index 363a052ff..50e2bbd0d 100644 --- a/docs/userguide/advanced_data_comparison.md +++ b/docs/userguide/advanced_data_comparison.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) # Advanced data comparison diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index 51e3d39e8..cb3ed8aac 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) Annotations are used to configure tests and suites in a declarative way similar to modern OOP languages. This way, test configuration is stored along with the test logic inside the test package. No additional configuration files or tables are needed for test cases. The annotation names are based on popular testing frameworks such as JUnit. diff --git a/docs/userguide/best-practices.md b/docs/userguide/best-practices.md index 0663a6d64..ff7e26fdb 100644 --- a/docs/userguide/best-practices.md +++ b/docs/userguide/best-practices.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) The following are best practices we at utPLSQL have learned about PL/SQL and Unit Testing. diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 78cdeabb4..55820e905 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) utPLSQL comes with a built-in coverage reporting engine. The code coverage reporting combines data from package DBMS_PROFILER and DBMS_PLSQL_CODE_COVERAGE. Code coverage is gathered for the following source types: diff --git a/docs/userguide/exception-reporting.md b/docs/userguide/exception-reporting.md index 91fadd126..f3faf2847 100644 --- a/docs/userguide/exception-reporting.md +++ b/docs/userguide/exception-reporting.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) utPLSQL is responsible for handling exceptions wherever they occur in the test run. The framework is trapping most of the exceptions so that the test execution is not affected by individual tests or test packages throwing an exception. The framework provides a full stacktrace for every exception that was thrown. The reported stacktrace does not include any utPLSQL library calls in it. diff --git a/docs/userguide/expectations.md b/docs/userguide/expectations.md index 4d787d113..31593e53d 100644 --- a/docs/userguide/expectations.md +++ b/docs/userguide/expectations.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) ## Expectation concepts diff --git a/docs/userguide/getting-started.md b/docs/userguide/getting-started.md index 1e7705d2a..4c2aa07f5 100644 --- a/docs/userguide/getting-started.md +++ b/docs/userguide/getting-started.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) # Getting started with TDD and utPLSQL diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 39bc6ce54..ecccbf100 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) ## Supported database versions diff --git a/docs/userguide/querying_suites.md b/docs/userguide/querying_suites.md index 87f42955d..1aededc4a 100644 --- a/docs/userguide/querying_suites.md +++ b/docs/userguide/querying_suites.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) ## Obtaining information about suites diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index 7709e8fdf..b0f26ca18 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) utPLSQL provides several reporting formats. The sections below describe most of them. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 4e7faf618..48d14281e 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) utPLSQL framework provides two main entry points to run unit tests from within the database: diff --git a/docs/userguide/upgrade.md b/docs/userguide/upgrade.md index bf59c1728..28421a1e9 100644 --- a/docs/userguide/upgrade.md +++ b/docs/userguide/upgrade.md @@ -1,4 +1,4 @@ -![version](https://img.shields.io/badge/version-v3.2.4.4535--develop-blue.svg) +![version](https://img.shields.io/badge/version-v3.2.4--develop-blue.svg) # Upgrading from version 2 From a33d815ecc097ea8e0a66681dd0146d86c1545cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 29 Sep 2026 13:11:15 +0300 Subject: [PATCH 780/887] - Release documentation badge shows released version with build number (e.g. v3.2.5.4600); develop documentation shows version only. Controlled by new UTPLSQL_DOCS_VERSION env variable. - Extract badge update into update_docs_version.sh. - rebuild_docs.yml restores the version badge as originally published for each release (read from its first gh-pages deployment, falling back to tag + BUILD_NO). Previously rebuilt docs got the badge committed at the tag, e.g. v3.2.2 docs showed v3.2.01.4414-develop. - Add v.3.2.3 to default list of versions to rebuild. --- .github/scripts/get_published_docs_version.sh | 29 +++++++++++++++++++ .../set_release_version_numbers_env.sh | 6 ++-- .github/scripts/set_version_numbers_env.sh | 2 ++ .github/scripts/update_docs_version.sh | 12 ++++++++ .github/scripts/update_project_version.sh | 3 +- .github/workflows/rebuild_docs.yml | 10 ++++++- 6 files changed, 57 insertions(+), 5 deletions(-) create mode 100755 .github/scripts/get_published_docs_version.sh create mode 100755 .github/scripts/update_docs_version.sh diff --git a/.github/scripts/get_published_docs_version.sh b/.github/scripts/get_published_docs_version.sh new file mode 100755 index 000000000..f0a78dcbc --- /dev/null +++ b/.github/scripts/get_published_docs_version.sh @@ -0,0 +1,29 @@ +#!/usr/bin/env bash + +# Returns the version shown on the badge of documentation, as originally published for a release. +# Used when rebuilding documentation of older releases, so that the rebuild does not alter version badges. +# Usage: .github/scripts/get_published_docs_version.sh +# +# Version is taken from the first deployment of the release documentation to gh-pages. +# If not found, it is derived from the release tag and BUILD_NO file, the same way as done by release process. +# Returns nothing if version cannot be determined. + +version=$1 +[[ -n "${version}" ]] || { echo "Release tag not provided" >&2; exit 1; } + +# mike commits to gh-pages with message: "Deployed to with MkDocs and mike " +first_deployment=$(git log origin/gh-pages --format=%H -F --grep=" to ${version} with MkDocs" | tail -1) +if [[ -n "${first_deployment}" ]]; then + docs_version=$(git show "${first_deployment}:${version}/index.html" 2>/dev/null | sed -nE 's/.*img\.shields\.io\/badge\/version-([^"]*)-blue\.svg.*/\1/p' | head -1) + # "-" is escaped as "--" in shields.io badge + docs_version=${docs_version//--/-} +fi + +if [[ -z "${docs_version}" ]]; then + build_no=$(git show "tags/${version}:BUILD_NO" 2>/dev/null | tr -d '[:space:]') + if [[ -n "${build_no}" ]]; then + docs_version=$(echo ${version} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${build_no}\4/") + fi +fi + +echo ${docs_version} diff --git a/.github/scripts/set_release_version_numbers_env.sh b/.github/scripts/set_release_version_numbers_env.sh index a43843508..a35b55a87 100755 --- a/.github/scripts/set_release_version_numbers_env.sh +++ b/.github/scripts/set_release_version_numbers_env.sh @@ -2,8 +2,10 @@ build_no=$(cat BUILD_NO) version=${CI_ACTION_REF_NAME} +build_version=$(echo ${version} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${build_no}\4/") echo "UTPLSQL_BUILD_NO=${build_no}" >> $GITHUB_ENV echo "UTPLSQL_VERSION=${version}" >> $GITHUB_ENV -echo UTPLSQL_BUILD_VERSION=$(echo ${version} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${build_no}\4/") >> $GITHUB_ENV - +echo "UTPLSQL_BUILD_VERSION=${build_version}" >> $GITHUB_ENV +# Documentation of released versions includes build number +echo "UTPLSQL_DOCS_VERSION=${build_version}" >> $GITHUB_ENV diff --git a/.github/scripts/set_version_numbers_env.sh b/.github/scripts/set_version_numbers_env.sh index c61639bf9..8fc31279d 100755 --- a/.github/scripts/set_version_numbers_env.sh +++ b/.github/scripts/set_version_numbers_env.sh @@ -6,3 +6,5 @@ version=$(.github/scripts/get_project_version.sh) echo "UTPLSQL_BUILD_NO=${build_no}" >> $GITHUB_ENV echo "UTPLSQL_VERSION=${version}" >> $GITHUB_ENV echo UTPLSQL_BUILD_VERSION=$(echo ${version} | sed -E "s/(v?[0-9]+\.)([0-9]+\.)([0-9]+)(-.*)?/\1\2\3\.${build_no}\4/") >> $GITHUB_ENV +# Documentation of development versions does not include build number, so that it only changes when version changes +echo "UTPLSQL_DOCS_VERSION=${version}" >> $GITHUB_ENV diff --git a/.github/scripts/update_docs_version.sh b/.github/scripts/update_docs_version.sh new file mode 100755 index 000000000..fa2e2c27a --- /dev/null +++ b/.github/scripts/update_docs_version.sh @@ -0,0 +1,12 @@ +#!/usr/bin/env bash + +# Updates version badge in documentation files. +# Usage: .github/scripts/update_docs_version.sh +# e.g. .github/scripts/update_docs_version.sh v3.2.4.4600 + +docs_version=$1 +[[ -n "${docs_version}" ]] || { echo "Documentation version not provided"; exit 1; } + +# "-" needs to be escaped as "--" in shields.io badge +find docs -type f -name '*.md' -exec sed -i -r "s/(badge\/version-).*(-blue\.svg)/\1${docs_version//-/--}\2/" {} \; +echo Documentation files updated with version: ${docs_version} diff --git a/.github/scripts/update_project_version.sh b/.github/scripts/update_project_version.sh index a4f27039a..bb59528cb 100755 --- a/.github/scripts/update_project_version.sh +++ b/.github/scripts/update_project_version.sh @@ -9,8 +9,7 @@ find source -type f -name '*' -exec sed -i -r "s/${UTPLSQL_VERSION_PATTERN}/${UT echo Source files updated with version tag: ${UTPLSQL_BUILD_VERSION} echo Update version in documentation files -# Build number is not included in documentation, so that documentation only changes when the project version changes -find docs -type f -name '*.md' -exec sed -i -r "s/(badge\/version-).*(-blue\.svg)/\1${UTPLSQL_VERSION//-/--}\2/" {} \; +.github/scripts/update_docs_version.sh "${UTPLSQL_DOCS_VERSION}" echo Update of sonar-project.properties sonar.projectVersion sed -i -r "s/(sonar\.projectVersion=).*?/\1${UTPLSQL_VERSION}/" sonar-project.properties diff --git a/.github/workflows/rebuild_docs.yml b/.github/workflows/rebuild_docs.yml index b9f3e4c45..a9774d9b2 100644 --- a/.github/workflows/rebuild_docs.yml +++ b/.github/workflows/rebuild_docs.yml @@ -5,7 +5,7 @@ on: versions: description: 'Space-separated list of versions to rebuild (e.g. "v3.1.14 v3.1.13")' required: true - default: 'v3.2.2 v3.2.01 v3.1.14 v3.1.13 v3.1.12 v3.1.11 v3.1.10 v3.1.9 v3.1.8 v3.1.6 v3.1.5 v3.1.4 v3.1.3 v3.1.2 v3.1.1 v3.1.0 v3.0.4 v3.0.3 v3.0.2 v3.0.1 v3.0.0 v3.0.0-beta' + default: 'v.3.2.3 v3.2.2 v3.2.01 v3.1.14 v3.1.13 v3.1.12 v3.1.11 v3.1.10 v3.1.9 v3.1.8 v3.1.6 v3.1.5 v3.1.4 v3.1.3 v3.1.2 v3.1.1 v3.1.0 v3.0.4 v3.0.3 v3.0.2 v3.0.1 v3.0.0 v3.0.0-beta' defaults: run: @@ -48,9 +48,17 @@ jobs: - name: Rebuild specified versions run: | + git fetch --quiet origin gh-pages for VERSION in ${{ inputs.versions }}; do echo "=== Rebuilding $VERSION ===" git checkout "tags/${VERSION}" -- docs/ + # Keep the version badge as originally published with the release + DOCS_VERSION=$(.github/scripts/get_published_docs_version.sh "${VERSION}") + if [[ -n "${DOCS_VERSION}" ]]; then + .github/scripts/update_docs_version.sh "${DOCS_VERSION}" + else + echo "Published documentation version for ${VERSION} not found, version badge left unchanged" + fi mike deploy -p "${VERSION}" git checkout HEAD -- docs/ mkdocs.yml done From b3ccc811ff7009b37ac0e2fe76dc4d765ef04fee Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 29 Sep 2026 11:27:40 +0100 Subject: [PATCH 781/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 75c5751d0..4556e8ea5 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4535 +4543 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index b70abd64b..45faba687 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4535-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4543-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From b061fb4eaa7d36b9b7e0107ac8433a312e5a64e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 2 Oct 2026 13:29:15 +0300 Subject: [PATCH 782/887] Reflect stewardship in docs and readme, fix typos - Footer: copyright to "utPLSQL contributors" plus stewardship line - Footer: X, LinkedIn and Bluesky icon links (online and offline docs) - Docs home: fix typos and broken Sonar link, link to About page - Readme: replace broken X follow badge with X, Bluesky and LinkedIn badges, fix About page URL, use https links, add License and Stewardship sections - Remove orphaned Redgate supporter logo --- docs/images/supported_by_redgate_100.png | Bin 7674 -> 0 bytes docs/index.md | 12 +++++++----- mkdocs.yml | 14 +++++++++++--- mkdocs_offline.yml | 13 ++++++++++--- readme.md | 17 ++++++++++++++--- 5 files changed, 42 insertions(+), 14 deletions(-) delete mode 100644 docs/images/supported_by_redgate_100.png diff --git a/docs/images/supported_by_redgate_100.png b/docs/images/supported_by_redgate_100.png deleted file mode 100644 index ea9f93ac5cc204e2afd93c1356f8e61e17512041..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 7674 zcmVPx#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D9gj&wK~#8N?Oh3g z6vesz`j~s?*x6n7fIZk#zT> zsxA~{2_~T2Id`ry2GGOXx4Z3$gklSYys5S}r>d$ByU#bsh(>M6aExLnt%v#m-Q$7b zav5qO(UgqG!^q1^C2h90xZR%gR8&MRn>Q~(g`(GI2SM33ID@oG_!%!4m_tR0MK*ckqguP`ZQ*yp1aa0x1 zGNZ=Q$SU$ zcbP;^`sY7|48{AWL|5qrR7I+qQZ+RKU2i9OZd5&UZd{m?jQIp}4| zE4SQIFnH^h$;JmCo|&w#pJ;T3N1BO5fNt98L4|Aipa~p<=vk4RZv%><=vq{DI=5+g zd2bq3!HL%ukNJ$0Ny>xj zi2fWH5pGY!K{5hRW!O~)Hey@Sb99QHab5O_8InbUu}cGTE+zB+GSgzqV&pVX-z z?k>q+xALmQu3cBB+C!y8l%2%s{|7sVfI$kHnrnxBXw|aNdtn*T z&gv@or(Fcq<)SNAEYGQ@!h6oyAPZm48GNT_S_h`rJNhJHT7Di1Z@&%Y_bx=)y$ewO zdEHgVM+)hRJpg=7GM|oTQpBF5SH*ye;xv#|C|&!9i=M1K|1e87RE@X4K7}kH&`{M$Y8Z;3zFcvZ)F7@-ieE_P{o@0?rY`kqU?5nS3h9 zT9zYcB-zpg&$#h$R9C}!!e}_Fs*tR!hmlA?&(B8=rSClPL>OINFhcEc({KCm;c$)| z1+5?-1=m~)|3zOwQf~3IUtt}s;<-XC%}996nU@fq?6G4+;cG6 z+9>x5a?bcPTqlmDd^E#eQGsM*Bb>vA!#1Q0sXYzQsVuH>Sr-_$cv_=A5(bmdBt!h0ptZVJI` zu14gow~;&jQmXkMLN6#n-nG|28&pVXtwZtcx0CdI9MUs!G+LVP6TJof~~xQu9_&GcPBzGE<NW6QbP;l>vW(U?)ZFk@G~TlS29ewo+*D&5D8298g4#Rh z!FSeKi0#@1h4fs`XQskE=@dlPtVXJ}HQk60j*lgb6L6H3A-;PTcFej`h;xq`g+Vue z8;Z?F?gQmU+CPUhh_DpZuF=wh*!CSzJswHOh=h@%CYRX0UETf+)EGC{7om@4t^^xD$;JK8V)E&!he2<%n+F2-n1k zaFfntr4Q*GdKTM+lXNY|$)V=Sm6>d8LTKqS%I5?kxfNaO-;*leuj&uL$LcVCSZba! zocpCK;63}ZNRgzpJn#_0t5zZBv`@i*?s-srKB?XC8*d=`fv+c9(ha% zba9|eJFBYE^xH)UzxpcGbO^b#uM|BKUbPy{)YNq9l~p3W^R?GV7>F!Qhwp+5V3L%y zJ@Y&2OeVumy(XIwvCUi1@%n325#y2j#fzyTeI!XC(oHW?2ht&BaM1f~q)u4BIY*2@ z%j1tDvSI}h9~S-D{^zCWeEs$GXz)Rh)?v!ivu95jv3SXAW+alEzO@h1^(>O04;n=F zjTp>5*Ds6{6@iB$^tfW5^+0R&e7@s3S8Z^5&ad%7emGRik6d z8Q<%Z(ic!O;VwMBZ7WhFN#v}{J=P2H9XmwKQ&eC!E21B45>mT%Y!`87pCZ0Vzx?Rj$NO@;Q+r*P>lkK8V0n zQ?o^)+@X6UnVg=yhjcOGG3jOVueu7Ie|-(n_tvLlemp)_!uk!87>!H-qbo`U=P5J` zY&5cDbW6?A2DJvAY&=#8DUwvip$16%EMffyk-^f|lPm@srTa+D(FV1UWPJmSXjF*m z>uBZ*nFe}Eu@%Ua;E@uQd|8ge z=0zs0{nH#M9Qj_d7i0>@YL%^ZJ(vqSk8Y5QWv{M=ot$hvFAth0N9-|;eNu{RCK6-< zB*;+iq~5HZOp_Wigg->rdm9k@Xe;9NwbHrtOux8)2EAVm2G5|Fp(50tY`9R@LzBt^guuy zW9uH>O-qyo{@wH3Lgoq+c;J0X#cqdt%xDC!oJD%ho^{=pb)_$(4&*?K_)wv_iS0|& z;e(T5iBuJh>Lo3O>3i8i)(K<2+LtXu?f1Tq#{2I>>x)YfUb7mpni?cYk;^z0S=}Z% z6vsg-oo=lr5Js)((ZUk)>D`GrRs1JX-c1)~yCfqBG%3ntg4 zv{cq^Mp>Z~nLPaBaYOU@#4)xF9!w+-g|n)XOb_Z+siUw3$^4*u97mo@|2<9!qry;$ z+^0{Gp_k;Y8ah|uoH!m@Zcs)Fq*;bLVRnYa5jK-aaf~w%%31%BWNL1gjD$EwkCBNM zd+88LkLemX!m`{;vOXfhCY^%v-#!dmWtF9uB2g6Ib{nde{t4B~U&gSPUqa;{|A?W_ zJdM(Y3s5+J9tv*!76LP8!h6nHaE>1bJ2hQ}yn;ks9XkK|S43B>k~a)Avaj^h%`#`| zRFpsTAoQU_(Y0w4YHq$6aVorH$PlvlMF{4X4f$WW9wl>b#gJeB3Kfq%imD}x zF^r_A`jzFVTJ|D}Z@rcDnog3KS@rD}(>+dG6O~S zmyLQpp5W!C$UUPOizCIoX?;DqHg863<3@mb(hT_njVw1wONzW_osFSSJb|IV{~aoy zeHK-V7o(bbMGoZ;|5g^XFatapT>kiDsCwxoQSenSaae|G{!QLO^^2tR=l=+*%VE9X zC?LxcmOk=mgwrW=gIZ1wG%s24E97^xI5B4FYvJj=|o`rNh7tZ0s;Tkbg zR^6~!!9zkhlTU^FgfTL)d$f?{Ua|*BPqCwH{Z1c9{MeB7efF~`d-y@J?2FMtwpi_) zIY_qh+$R~a)cm+va$tpTCfKMwS`CukJP@vt{|lc-!8g7k)Ba|dta&pZ959T^O~mV!_DK?d7n66jeTNMr(S8ip=fM1;*4aKf^#^tm)L zR>kB{fqCtzN{%!4g!Zyh(p4kjo-h#}>M?m8YT)88A~5|@*b58gSqB-c#dq9+Aqy6u z?9oLi{QmdE#ONk;fRSY#MiN6M3tV&&${%}77O4!S9kOQpr9$TF5G48H?OrQHkL6>F|Ay z?69ey5%=*kYpQOK)tgfAlV?zRKlPXaKN{xGNAshPA{7mj;To58 zt%f-8$g+en($-kId~)diL)Td+aZebD%0iVyZJk*1(Y0&E(&r^fsc00n-~T?jR#%|m z7r&HIT6xy0j{!y2l|Gj#|Lb2v@!UJ4w=+6J;FZw47K}rpt`>=U@)H{xk!ac@i}F(B ztb>#{_oBR1$>gO`Cdn1|2BZ&dMTMv!edZ-H*(_mcJ8pVOCQL6Xl4a_=#537JWUxII zW1EU3i+fG(5JX_;4+)+O3OdMlbh)AXsj24XLN6Qydr1lGLx+;NF+$ucjqh<>BJ;Q+ zjA1oECWPgI&d5yQ@p{%*ylh;Cq)P^q@k*rd&@@^8wo*DLqSQbT8hHs~n(*8s_qrJf zVaLswzC{$95xf+@HmCqPk>MyUgFb|g6nGNE#%m~uG+rve4!1=Lr@&8J5R%j9Y|ib2 z0VFKTO5c*Nz-5<`^Sl&8$#ke7^J4HXevYDBZb6Wgxc4(t<%l0lckQO0FKiLP?oBU+KP->{%cO5OOg?6TF|RoNxX^LZv#Ka10*? B)nRGJgu92klORTXm@-cZDZJ!=6-PAzj$mj;yXFOUF z-}VtA@2;1x+q%}RC)=%=j9+URe6}!PW<>@}+TH@uFCM|j$&ubuFBl{}s7h{-=FPEs zNfA$yCXyQYMyQDl-9|EO8=K_g1+n&Jv}6CYvx5OAtS_+Cw#cI}kQwI5_@vpV<=_|~ zv!cJSD3c%@@t>nlR!c#~N<+EqUh!M!WXc}CTCc#!xOuk`Mnh)0*7m8O_dp~=Qd|JahtSBzG z?7R|s{dKfH@`$Y9agIGf)?&C%odkOkr_qJ3EnCoZ{{!SxzDur_M~1b7*Iy6M8B@^u z>>uQFY43UGQaDfiSpN7vUb`FZ&pwB?CC^*)1^qyuc1Gz5-kGHIzJ)T^$RDknt*x?( zF#oEnWfv6kmaVO2h!j@n_VQAM{_+|Mzx!QTx5~~m&o%PgqHF9Js%@7n4`5j+yZ=5o zDy!)Edf8Wkr{MyZULs4OqHEs8;JfZZaQ2ljqfsjjx0^^lTXrM}Eq_I(@OWvJjmYG! zX=3khlm#!P3+|EK1d@C9$QljzDU&Gw)6li~1H?9NvZPQ-cL?-#XO#WH>$jZ4su6zs zEt&S({-s%ntbAMce~5kX0k+S&65B7IiLIATm%Si7r<^LI60R|0gos^VxgI;N{4zeG z`;B+sL;kh(k-Kx)FlsV+X!!Lnv5nKcVitB@dmYT?7WmFQOO~MX21#A(*I~!3+1T;r ztK=Q+Bt=e=9M|}9QfMZ#cFqs6b=t)UQAO~oA11BwS9fFEjLWg@lIf_s;|^*1In;#Z z8vw~c-_UQu?0E$;6qDS#UG}p`hCc=~xu%vRcx@xzF>M+-ya! z@dODMo!-YguSD0ZkzpTaWu>HV#G*2cq!$**aFMmBc<*ROU(s*EmpeU-z$B?8O@+7LifUe*N1=G$Jc?o>zN3cT-M^vj{+ks%Jx1mLD@z{vWMszMc`uv# zAI-;}dlsPa*Z+mx|Mnf!-FmxhtkF9g^gNNyl46a_9~@jPk)WQCH1}Rh=SGg*X;EH{ z&agDehF|^?jrZJ(x*z`-JFmMQZO=VR2D2q)eMSGx3L;4Y{mx|7BnjfdJT1qE@LO-8 z<>{x<{JY`8GraM7hJa-&yo>Wqevo4I04pO>eQ1gP) z$#kt*OA7u{47zm=c=NSXM<XuEE_36X#NBVDpXBQt>5Z?l4DXjmsj-+2eo&6`C;dGdi@%%Xi+~ z5y z{BeZ;=YO&DnrmbgkGz?EM%GQ#>+-&0vdJ4Gt&d~}0`@7n*G?wrUG!f527s?KX*{XI z6_cJ5V5CzxC=PpwTKHk5K`+aYC552C=e!P;Hyx6#@raC`ari_w4&wV%(+Y1W#MkJq zeOMLBh@1*?#!KeUqb58LMYr89&ARJ@O)}{raVaoSLWbmluJMrz&+nH!@C;MfG9Tpq z^oOVRsC97Oz-je^te)t9FWCbbqB7|1#eK;P$1y^kNbcMrn>wZhn4C4@ z^!M;+P_=zs=)l;Fu!pUjd&G)=#KO(@cqkgsXwA1c7=c%VQ?Ze1ZKlnlJi1q8I zs(=5-Y$Fo>v=L7PNy*8S;qgjch9EAVl#~B;ElulGY>w4>S?Npd<4^qKM!$bs=HEB! zm4`)h=Q=A^uN$Acde!I2aGYi&W5W?o+K)%lxJ)VbximelIbC}+uYaYPm-kftu*#Kh zo_J!z{{Q^gAvqw%l|SEbLuo}_-DG3!+H+EEZ6}if2RS!xtS+gk zIVE1Rdvq!pAFG;Xm69@Yjg+BLG|30!fYH&T2>u71G(}08irQl8dc9(|ePs9g*Mhb> zBBx;tPPT>0OkK^RES8v&uwoii?{<404AZU}DWrJFh?wOJ@qiC!jYZZPqoC`m236xO zNJ*uVsb;#CB%PBmQ_1ZVKWZC1B-#~?zHbZoLSeu6qp&}(Bb=Al+)+@_?g<1Uhx2bq z_J$)$*rCAxM&;;G$QFx6y=Z8Fo=hqUx7%+flQ!ANo5P`Cw@aX=Wya$1HhVOhL}4Mw oj_j;0F3vn`^yS}(JbVEE2S)hJuAGBhRR91007*qoM6N<$f=B%zmjD0& diff --git a/docs/index.md b/docs/index.md index 3f5dc6b25..c0b531359 100644 --- a/docs/index.md +++ b/docs/index.md @@ -3,7 +3,9 @@ ## What is utPLSQL utPLSQL is a Unit Testing framework for Oracle PL/SQL. -The framework follows industry standards and best patterns of modern Unit Testing frameworks like [JUnit](http://junit.org/junit4/) and [RSpec](http://rspec.info/) +The framework follows industry standards and best patterns of modern Unit Testing frameworks like [JUnit](https://junit.org/) and [RSpec](https://rspec.info/). + +See [About](https://www.utplsql.org/about.html) for project history, contributors and stewardship. ## Demo project @@ -11,18 +13,18 @@ Have a look at [utPLSQL demo project](https://github.com/utPLSQL/utPLSQL-demo-pr - sample code and tests - demo of deployment automation that leverages: - - Flyway / Liquidbase for scripting and deployment of DB changes + - Flyway / Liquibase for scripting and deployment of DB changes - Docker container with Oracle XE Database - GitHub Actions and Azure Pipelines to orchestrate the deployment and testing process - - utPLSQL framework for writhing, execution of tests as well as reporting test results and code coverage - - [Sonar]((https://sonarcloud.io/project/overview?id=utPLSQL:utPLSQL-demo-project).) for code quality gate, test results and code coverage reporting + - utPLSQL framework for writing and executing tests, as well as reporting test results and code coverage + - [Sonar](https://sonarcloud.io/project/overview?id=utPLSQL:utPLSQL-demo-project) for code quality gate, test results and code coverage reporting ## Three steps With just three simple steps you can define and run your unit tests for PLSQL code. 1. Install the utPLSQL framework -2. Create Unit Tests to for the code +2. Create unit tests for the code 3. Run the tests Here is how you can simply create tested code, unit tests and execute the tests using SQL Developer diff --git a/mkdocs.yml b/mkdocs.yml index f18f74ce3..72eebaa17 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -9,7 +9,8 @@ site_url: https://www.utplsql.org/ site_name: utPLSQL site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL copyright: > - Copyright © 2016 - 2026 utPLSQL Team + Copyright © 2016 - 2026 utPLSQL contributors. + utPLSQL is stewarded by utPLSQL Development Labs Ltd. Change cookie settings repo_url: https://github.com/utPLSQL/utPLSQL extra_css: @@ -77,8 +78,15 @@ extra: # the cookie: utplsql-consent allows for shred cookie across all documentation versions and the global site cookie: utplsql-consent social: - - icon: fontawesome/brands/twitter - link: https://twitter.com/utPLSQL + - icon: fontawesome/brands/x-twitter + link: https://x.com/utPLSQL + name: utPLSQL on X + - icon: fontawesome/brands/linkedin + link: https://www.linkedin.com/company/utplsql/ + name: utPLSQL on LinkedIn + - icon: fontawesome/brands/bluesky + link: https://bsky.app/profile/utplsql.org + name: utPLSQL on Bluesky - icon: fontawesome/regular/comment link: https://github.com/utPLSQL/utPLSQL/discussions - icon: fontawesome/brands/github diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index 82304041c..49e986c95 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -8,7 +8,7 @@ edit_uri: "" site_url: https://www.utplsql.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL -copyright: Copyright © 2016 - 2026 utPLSQL Team +copyright: Copyright © 2016 - 2026 utPLSQL contributors. utPLSQL is stewarded by utPLSQL Development Labs Ltd. #repo_url: https://github.com/utPLSQL/utPLSQL # disable for offline docs extra_css: - stylesheets/extra.css @@ -41,8 +41,15 @@ theme: extra: # homepage: https://www.utPLSQL.org/ social: - - icon: fontawesome/brands/twitter - link: https://twitter.com/utPLSQL + - icon: fontawesome/brands/x-twitter + link: https://x.com/utPLSQL + name: utPLSQL on X + - icon: fontawesome/brands/linkedin + link: https://www.linkedin.com/company/utplsql/ + name: utPLSQL on LinkedIn + - icon: fontawesome/brands/bluesky + link: https://bsky.app/profile/utplsql.org + name: utPLSQL on Bluesky - icon: fontawesome/regular/comment link: https://github.com/utPLSQL/utPLSQL/discussions - icon: fontawesome/brands/github diff --git a/readme.md b/readme.md index ac4dc9815..f2b16be37 100644 --- a/readme.md +++ b/readme.md @@ -3,12 +3,14 @@ [![latest-release](https://img.shields.io/github/release/utPLSQL/utPLSQL.svg)](https://github.com/utPLSQL/utPLSQL/releases) [![license](https://img.shields.io/github/license/utPLSQL/utPLSQL.svg)](https://www.apache.org/licenses/LICENSE-2.0) [![GitHub Discussions](https://img.shields.io/github/discussions/utPLSQL/utPLSQL)](https://github.com/utPLSQL/utPLSQL/discussions) -[![X](https://img.shields.io/twitter/follow/utPLSQL.svg?style=social&label=Follow)](https://twitter.com/utPLSQL) +[![X](https://img.shields.io/badge/X-utPLSQL-000000?logo=x)](https://x.com/utPLSQL) +[![Bluesky](https://img.shields.io/badge/Bluesky-utplsql.org-0285FF?logo=bluesky&logoColor=white)](https://bsky.app/profile/utplsql.org) +[![LinkedIn](https://img.shields.io/badge/in-utPLSQL-0A66C2)](https://www.linkedin.com/company/utplsql/) [![build](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml/badge.svg)](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml) [![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL_utPLSQL&metric=sqale_rating)](https://sonarcloud.io/summary/new_code?id=utPLSQL_utPLSQL) [![Coverage](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL_utPLSQL&metric=coverage)](https://sonarcloud.io/summary/new_code?id=utPLSQL_utPLSQL) -utPLSQL is a unit testing framework for Oracle PL/SQL and SQL, following industry standards and best practices of modern testing frameworks like [JUnit](http://junit.org/junit4/) and [RSpec](http://rspec.info/). +utPLSQL is a unit testing framework for Oracle PL/SQL and SQL, following industry standards and best practices of modern testing frameworks like [JUnit](https://junit.org/) and [RSpec](https://rspec.info/). ## Key Features @@ -136,5 +138,14 @@ We welcome contributions of all kinds. Please read the [contributing guide](CONT [GitHub Discussions](https://github.com/utPLSQL/utPLSQL/discussions) is the place to ask questions and connect with the team. -The list of **authors** and **significant contributors** is available on the [About](https://www.utplsql.org/about/) page. For a full list of contributors, see [contributors](https://github.com/utPLSQL/utPLSQL/graphs/contributors?all=1) on GitHub. +The list of **authors** and **significant contributors** is available on the [About](https://www.utplsql.org/about.html) page. For a full list of contributors, see [contributors](https://github.com/utPLSQL/utPLSQL/graphs/contributors?all=1) on GitHub. +## License + +utPLSQL is free and open source, licensed under the [Apache 2.0 license](LICENSE). + +## Stewardship + +utPLSQL is stewarded by utPLSQL Development Labs Ltd, which holds the utPLSQL name, branding and project assets, and manages sponsorships and funded development. +Contributors retain copyright of their contributions, which are licensed under the Apache 2.0 license. +See the [announcement](https://www.utplsql.org/announcements/incorporation-of-utplsql-development-labs-ltd.html) for details. From 32baa31637cc0e5a5ce9e712e0e1fc307dcdd969 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 2 Oct 2026 11:36:32 +0100 Subject: [PATCH 783/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4556e8ea5..021fa878a 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4543 +4544 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 45faba687..36cfb9316 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4543-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4544-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From beffc2f3541dd263361bdcdc436fa967272997e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 2 Oct 2026 16:57:25 +0300 Subject: [PATCH 784/887] Align license headers with Apache 2.0 wording - Source headers: '(the "License"). You may not use ...' - avoids a semicolon in comments, which breaks script execution - LICENSE appendix: standard '(the "License");' wording, copyright years 2016 - 2026 - Custom reporter examples: copyright years 2016 - 2026 - Fix corrupted license header in ut_run_info.tpb - Docs footer: copyright holder "utPLSQL Project" --- LICENSE | 4 ++-- examples/custom_reporters/ut_expectations_reporter.tpb | 6 +++--- examples/custom_reporters/ut_expectations_reporter.tps | 6 +++--- mkdocs.yml | 2 +- mkdocs_offline.yml | 2 +- source/api/ut.pkb | 4 ++-- source/api/ut.pks | 4 ++-- source/api/ut_runner.pkb | 4 ++-- source/api/ut_runner.pks | 4 ++-- source/api/ut_suite_item_info.tpb | 4 ++-- source/api/ut_suite_item_info.tps | 4 ++-- source/api/ut_suite_items_info.tps | 4 ++-- source/check_object_grants.sql | 4 ++-- source/check_sys_grants.sql | 4 ++-- source/core/annotations/ut_annotated_object.tps | 4 ++-- source/core/annotations/ut_annotated_objects.tps | 4 ++-- source/core/annotations/ut_annotation.tps | 4 ++-- source/core/annotations/ut_annotation_cache.sql | 4 ++-- source/core/annotations/ut_annotation_cache_info.sql | 4 ++-- source/core/annotations/ut_annotation_cache_manager.pkb | 4 ++-- source/core/annotations/ut_annotation_cache_manager.pks | 4 ++-- source/core/annotations/ut_annotation_cache_schema.sql | 4 ++-- source/core/annotations/ut_annotation_cache_seq.sql | 4 ++-- source/core/annotations/ut_annotation_manager.pkb | 4 ++-- source/core/annotations/ut_annotation_manager.pks | 4 ++-- source/core/annotations/ut_annotation_obj_cache_info.tps | 4 ++-- source/core/annotations/ut_annotation_objs_cache_info.tps | 4 ++-- source/core/annotations/ut_annotation_parser.pkb | 4 ++-- source/core/annotations/ut_annotation_parser.pks | 4 ++-- source/core/annotations/ut_annotations.tps | 4 ++-- source/core/annotations/ut_trigger_annotation_parsing.trg | 4 ++-- source/core/annotations/ut_trigger_check.pkb | 4 ++-- source/core/annotations/ut_trigger_check.pks | 4 ++-- source/core/coverage/ut_coverage.pkb | 4 ++-- source/core/coverage/ut_coverage.pks | 4 ++-- source/core/coverage/ut_coverage_block.pkb | 4 ++-- source/core/coverage/ut_coverage_block.pks | 4 ++-- source/core/coverage/ut_coverage_helper.pkb | 4 ++-- source/core/coverage/ut_coverage_helper.pks | 4 ++-- source/core/coverage/ut_coverage_helper_block.pkb | 4 ++-- source/core/coverage/ut_coverage_helper_block.pks | 4 ++-- source/core/coverage/ut_coverage_helper_profiler.pkb | 4 ++-- source/core/coverage/ut_coverage_helper_profiler.pks | 4 ++-- source/core/coverage/ut_coverage_profiler.pkb | 4 ++-- source/core/coverage/ut_coverage_profiler.pks | 4 ++-- source/core/coverage/ut_coverage_reporter_base.tpb | 4 ++-- source/core/coverage/ut_coverage_reporter_base.tps | 4 ++-- source/core/coverage/ut_coverage_sources_tmp.sql | 4 ++-- source/core/events/ut_event_item.tps | 4 ++-- source/core/events/ut_event_listener.tps | 4 ++-- source/core/events/ut_event_manager.pkb | 4 ++-- source/core/events/ut_event_manager.pks | 4 ++-- source/core/output_buffers/ut_output_buffer_base.tpb | 4 ++-- source/core/output_buffers/ut_output_buffer_base.tps | 4 ++-- source/core/output_buffers/ut_output_buffer_info_tmp.sql | 4 ++-- source/core/output_buffers/ut_output_buffer_tmp.sql | 4 ++-- source/core/output_buffers/ut_output_bulk_buffer.tpb | 4 ++-- source/core/output_buffers/ut_output_bulk_buffer.tps | 4 ++-- source/core/output_buffers/ut_output_clob_buffer_tmp.sql | 4 ++-- source/core/output_buffers/ut_output_clob_table_buffer.tpb | 4 ++-- source/core/output_buffers/ut_output_clob_table_buffer.tps | 4 ++-- source/core/output_buffers/ut_output_data_row.tps | 4 ++-- source/core/output_buffers/ut_output_data_rows.tps | 4 ++-- source/core/output_buffers/ut_output_table_buffer.tpb | 4 ++-- source/core/output_buffers/ut_output_table_buffer.tps | 4 ++-- source/core/session_context/ut_session_context.pkb | 4 ++-- source/core/session_context/ut_session_context.pks | 4 ++-- source/core/session_context/ut_session_info.tpb | 4 ++-- source/core/session_context/ut_session_info.tps | 4 ++-- source/core/types/ut_console_reporter_base.tpb | 4 ++-- source/core/types/ut_console_reporter_base.tps | 4 ++-- source/core/types/ut_coverage_options.tpb | 4 ++-- source/core/types/ut_coverage_options.tps | 4 ++-- source/core/types/ut_executable.tpb | 4 ++-- source/core/types/ut_executable.tps | 4 ++-- source/core/types/ut_executable_test.tpb | 4 ++-- source/core/types/ut_executable_test.tps | 4 ++-- source/core/types/ut_executables.tps | 4 ++-- source/core/types/ut_expectation_result.tpb | 4 ++-- source/core/types/ut_expectation_result.tps | 4 ++-- source/core/types/ut_expectation_results.tps | 4 ++-- source/core/types/ut_file_mapping.tpb | 4 ++-- source/core/types/ut_file_mapping.tps | 4 ++-- source/core/types/ut_file_mappings.tps | 4 ++-- source/core/types/ut_integer_list.tps | 4 ++-- source/core/types/ut_key_value_pair.tps | 4 ++-- source/core/types/ut_key_value_pairs.tps | 4 ++-- source/core/types/ut_logical_suite.tpb | 4 ++-- source/core/types/ut_logical_suite.tps | 4 ++-- source/core/types/ut_object_name.tpb | 4 ++-- source/core/types/ut_object_name.tps | 4 ++-- source/core/types/ut_object_names.tps | 4 ++-- source/core/types/ut_output_reporter_base.tpb | 4 ++-- source/core/types/ut_output_reporter_base.tps | 4 ++-- source/core/types/ut_path_item.tpb | 4 ++-- source/core/types/ut_path_item.tps | 4 ++-- source/core/types/ut_path_items.tps | 4 ++-- source/core/types/ut_reporter_base.tpb | 4 ++-- source/core/types/ut_reporter_base.tps | 4 ++-- source/core/types/ut_reporter_info.tps | 4 ++-- source/core/types/ut_reporters.tps | 4 ++-- source/core/types/ut_reporters_info.tps | 4 ++-- source/core/types/ut_results_counter.tpb | 4 ++-- source/core/types/ut_results_counter.tps | 4 ++-- source/core/types/ut_run.tpb | 4 ++-- source/core/types/ut_run.tps | 4 ++-- source/core/types/ut_run_info.tpb | 6 +++--- source/core/types/ut_run_info.tps | 4 ++-- source/core/types/ut_stack.tpb | 4 ++-- source/core/types/ut_stack.tps | 4 ++-- source/core/types/ut_suite.tpb | 4 ++-- source/core/types/ut_suite.tps | 4 ++-- source/core/types/ut_suite_cache_row.tps | 4 ++-- source/core/types/ut_suite_cache_rows.tps | 4 ++-- source/core/types/ut_suite_context.tpb | 4 ++-- source/core/types/ut_suite_context.tps | 4 ++-- source/core/types/ut_suite_item.tpb | 4 ++-- source/core/types/ut_suite_item.tps | 4 ++-- source/core/types/ut_suite_items.tps | 4 ++-- source/core/types/ut_test.tpb | 4 ++-- source/core/types/ut_test.tps | 4 ++-- source/core/types/ut_varchar2_list.tps | 4 ++-- source/core/types/ut_varchar2_rows.tps | 4 ++-- source/core/ut_dbms_output_cache.sql | 4 ++-- source/core/ut_expectation_processor.pkb | 4 ++-- source/core/ut_expectation_processor.pks | 4 ++-- source/core/ut_file_mapper.pkb | 4 ++-- source/core/ut_file_mapper.pks | 4 ++-- source/core/ut_metadata.pkb | 4 ++-- source/core/ut_metadata.pks | 4 ++-- source/core/ut_savepoint_seq.sql | 4 ++-- source/core/ut_suite_builder.pkb | 4 ++-- source/core/ut_suite_builder.pks | 4 ++-- source/core/ut_suite_cache.sql | 4 ++-- source/core/ut_suite_cache_manager.pkb | 4 ++-- source/core/ut_suite_cache_manager.pks | 4 ++-- source/core/ut_suite_cache_package.sql | 4 ++-- source/core/ut_suite_cache_schema.sql | 4 ++-- source/core/ut_suite_cache_seq.sql | 4 ++-- source/core/ut_suite_manager.pkb | 4 ++-- source/core/ut_suite_manager.pks | 4 ++-- source/core/ut_suite_tag_filter.pkb | 4 ++-- source/core/ut_suite_tag_filter.pks | 4 ++-- source/core/ut_utils.pkb | 4 ++-- source/core/ut_utils.pks | 4 ++-- source/create_grants.sql | 4 ++-- source/create_synonyms.sql | 4 ++-- source/create_synonyms_and_grants_for_public.sql | 4 ++-- source/create_user_grants.sql | 4 ++-- source/create_user_synonyms.sql | 4 ++-- source/create_utplsql_owner.sql | 4 ++-- source/define_ut3_owner_param.sql | 4 ++-- .../expectations/data_values/ut_compound_data_diff_tmp.sql | 4 ++-- source/expectations/data_values/ut_compound_data_helper.pkb | 4 ++-- source/expectations/data_values/ut_compound_data_helper.pks | 4 ++-- source/expectations/data_values/ut_compound_data_tmp.sql | 4 ++-- source/expectations/data_values/ut_compound_data_value.tpb | 4 ++-- source/expectations/data_values/ut_compound_data_value.tps | 4 ++-- source/expectations/data_values/ut_cursor_column.tpb | 4 ++-- source/expectations/data_values/ut_cursor_column.tps | 4 ++-- source/expectations/data_values/ut_cursor_column_tab.tps | 4 ++-- source/expectations/data_values/ut_cursor_details.tpb | 4 ++-- source/expectations/data_values/ut_cursor_details.tps | 4 ++-- source/expectations/data_values/ut_data_value.tpb | 4 ++-- source/expectations/data_values/ut_data_value.tps | 4 ++-- source/expectations/data_values/ut_data_value_anydata.tpb | 4 ++-- source/expectations/data_values/ut_data_value_anydata.tps | 4 ++-- source/expectations/data_values/ut_data_value_blob.tpb | 4 ++-- source/expectations/data_values/ut_data_value_blob.tps | 4 ++-- source/expectations/data_values/ut_data_value_boolean.tpb | 4 ++-- source/expectations/data_values/ut_data_value_boolean.tps | 4 ++-- source/expectations/data_values/ut_data_value_clob.tpb | 4 ++-- source/expectations/data_values/ut_data_value_clob.tps | 4 ++-- source/expectations/data_values/ut_data_value_date.tpb | 4 ++-- source/expectations/data_values/ut_data_value_date.tps | 4 ++-- .../expectations/data_values/ut_data_value_dsinterval.tpb | 4 ++-- .../expectations/data_values/ut_data_value_dsinterval.tps | 4 ++-- source/expectations/data_values/ut_data_value_json.tpb | 4 ++-- source/expectations/data_values/ut_data_value_json.tps | 4 ++-- source/expectations/data_values/ut_data_value_number.tpb | 4 ++-- source/expectations/data_values/ut_data_value_number.tps | 4 ++-- source/expectations/data_values/ut_data_value_refcursor.tpb | 4 ++-- source/expectations/data_values/ut_data_value_refcursor.tps | 4 ++-- source/expectations/data_values/ut_data_value_timestamp.tpb | 4 ++-- source/expectations/data_values/ut_data_value_timestamp.tps | 4 ++-- .../data_values/ut_data_value_timestamp_ltz.tpb | 4 ++-- .../data_values/ut_data_value_timestamp_ltz.tps | 4 ++-- .../expectations/data_values/ut_data_value_timestamp_tz.tpb | 4 ++-- .../expectations/data_values/ut_data_value_timestamp_tz.tps | 4 ++-- source/expectations/data_values/ut_data_value_varchar2.tpb | 4 ++-- source/expectations/data_values/ut_data_value_varchar2.tps | 4 ++-- source/expectations/data_values/ut_data_value_xmltype.tpb | 4 ++-- source/expectations/data_values/ut_data_value_xmltype.tps | 4 ++-- .../expectations/data_values/ut_data_value_yminterval.tpb | 4 ++-- .../expectations/data_values/ut_data_value_yminterval.tps | 4 ++-- source/expectations/data_values/ut_json_data_diff_tmp.sql | 4 ++-- source/expectations/data_values/ut_json_leaf.tpb | 4 ++-- source/expectations/data_values/ut_json_leaf.tps | 4 ++-- source/expectations/data_values/ut_json_leaf_tab.tps | 4 ++-- source/expectations/data_values/ut_json_tree_details.tpb | 4 ++-- source/expectations/data_values/ut_json_tree_details.tps | 4 ++-- source/expectations/data_values/ut_key_anyval_pair.tps | 4 ++-- source/expectations/data_values/ut_key_anyval_pairs.tps | 4 ++-- source/expectations/data_values/ut_key_anyvalues.tpb | 4 ++-- source/expectations/data_values/ut_key_anyvalues.tps | 4 ++-- source/expectations/matchers/ut_be_between.tpb | 4 ++-- source/expectations/matchers/ut_be_between.tps | 4 ++-- source/expectations/matchers/ut_be_empty.tpb | 4 ++-- source/expectations/matchers/ut_be_empty.tps | 4 ++-- source/expectations/matchers/ut_be_false.tpb | 4 ++-- source/expectations/matchers/ut_be_false.tps | 4 ++-- source/expectations/matchers/ut_be_greater_or_equal.tpb | 4 ++-- source/expectations/matchers/ut_be_greater_or_equal.tps | 4 ++-- source/expectations/matchers/ut_be_greater_than.tpb | 4 ++-- source/expectations/matchers/ut_be_greater_than.tps | 4 ++-- source/expectations/matchers/ut_be_less_or_equal.tpb | 4 ++-- source/expectations/matchers/ut_be_less_or_equal.tps | 4 ++-- source/expectations/matchers/ut_be_less_than.tpb | 4 ++-- source/expectations/matchers/ut_be_less_than.tps | 4 ++-- source/expectations/matchers/ut_be_like.tpb | 4 ++-- source/expectations/matchers/ut_be_like.tps | 4 ++-- source/expectations/matchers/ut_be_not_null.tpb | 4 ++-- source/expectations/matchers/ut_be_not_null.tps | 4 ++-- source/expectations/matchers/ut_be_null.tpb | 4 ++-- source/expectations/matchers/ut_be_null.tps | 4 ++-- source/expectations/matchers/ut_be_true.tpb | 4 ++-- source/expectations/matchers/ut_be_true.tps | 4 ++-- source/expectations/matchers/ut_be_within.tpb | 4 ++-- source/expectations/matchers/ut_be_within.tps | 4 ++-- source/expectations/matchers/ut_be_within_helper.pkb | 4 ++-- source/expectations/matchers/ut_be_within_helper.pks | 4 ++-- source/expectations/matchers/ut_be_within_pct.tpb | 4 ++-- source/expectations/matchers/ut_be_within_pct.tps | 4 ++-- source/expectations/matchers/ut_comparison_matcher.tpb | 4 ++-- source/expectations/matchers/ut_comparison_matcher.tps | 4 ++-- source/expectations/matchers/ut_contain.tpb | 4 ++-- source/expectations/matchers/ut_contain.tps | 4 ++-- source/expectations/matchers/ut_equal.tpb | 4 ++-- source/expectations/matchers/ut_equal.tps | 4 ++-- source/expectations/matchers/ut_have_count.tpb | 4 ++-- source/expectations/matchers/ut_have_count.tps | 4 ++-- source/expectations/matchers/ut_match.tpb | 4 ++-- source/expectations/matchers/ut_match.tps | 4 ++-- source/expectations/matchers/ut_matcher.tpb | 4 ++-- source/expectations/matchers/ut_matcher.tps | 4 ++-- source/expectations/matchers/ut_matcher_base.tps | 4 ++-- source/expectations/matchers/ut_matcher_options.tpb | 4 ++-- source/expectations/matchers/ut_matcher_options.tps | 4 ++-- source/expectations/matchers/ut_matcher_options_items.tpb | 4 ++-- source/expectations/matchers/ut_matcher_options_items.tps | 4 ++-- source/expectations/ut_expectation.tpb | 4 ++-- source/expectations/ut_expectation.tps | 4 ++-- source/expectations/ut_expectation_base.tpb | 4 ++-- source/expectations/ut_expectation_base.tps | 4 ++-- source/expectations/ut_expectation_compound.tpb | 4 ++-- source/expectations/ut_expectation_compound.tps | 4 ++-- source/expectations/ut_expectation_json.tpb | 4 ++-- source/expectations/ut_expectation_json.tps | 4 ++-- source/install.sql | 4 ++-- source/install_above_12_1.sql | 4 ++-- source/install_component.sql | 4 ++-- source/install_ddl_trigger.sql | 4 ++-- source/install_headless.sql | 4 ++-- source/install_headless_with_trigger.sql | 4 ++-- source/reporters/ut_ansiconsole_helper.pkb | 4 ++-- source/reporters/ut_ansiconsole_helper.pks | 4 ++-- source/reporters/ut_coverage_cobertura_reporter.tpb | 4 ++-- source/reporters/ut_coverage_cobertura_reporter.tps | 4 ++-- source/reporters/ut_coverage_html_reporter.tpb | 4 ++-- source/reporters/ut_coverage_html_reporter.tps | 4 ++-- source/reporters/ut_coverage_report_html_helper.pkb | 4 ++-- source/reporters/ut_coverage_report_html_helper.pks | 4 ++-- source/reporters/ut_coverage_sonar_reporter.tpb | 4 ++-- source/reporters/ut_coverage_sonar_reporter.tps | 4 ++-- source/reporters/ut_debug_reporter.tpb | 4 ++-- source/reporters/ut_debug_reporter.tps | 4 ++-- source/reporters/ut_documentation_reporter.tpb | 4 ++-- source/reporters/ut_documentation_reporter.tps | 4 ++-- source/reporters/ut_junit_reporter.tpb | 4 ++-- source/reporters/ut_junit_reporter.tps | 4 ++-- source/reporters/ut_realtime_reporter.tpb | 4 ++-- source/reporters/ut_realtime_reporter.tps | 4 ++-- source/reporters/ut_sonar_test_reporter.tpb | 4 ++-- source/reporters/ut_sonar_test_reporter.tps | 4 ++-- source/reporters/ut_tap_reporter.tpb | 4 ++-- source/reporters/ut_tap_reporter.tps | 4 ++-- source/reporters/ut_teamcity_reporter.tpb | 4 ++-- source/reporters/ut_teamcity_reporter.tps | 4 ++-- source/reporters/ut_teamcity_reporter_helper.pkb | 4 ++-- source/reporters/ut_teamcity_reporter_helper.pks | 4 ++-- source/reporters/ut_tfs_junit_reporter.tpb | 4 ++-- source/reporters/ut_tfs_junit_reporter.tps | 4 ++-- source/reporters/ut_xunit_reporter.tpb | 4 ++-- source/reporters/ut_xunit_reporter.tps | 4 ++-- source/set_install_params.sql | 4 ++-- source/uninstall.sql | 4 ++-- source/uninstall_all.sql | 4 ++-- source/uninstall_coverage_tables.sql | 4 ++-- source/uninstall_objects.sql | 4 ++-- source/uninstall_synonyms.sql | 4 ++-- 300 files changed, 601 insertions(+), 601 deletions(-) diff --git a/LICENSE b/LICENSE index 640d46628..0cc83a7bb 100644 --- a/LICENSE +++ b/LICENSE @@ -187,9 +187,9 @@ same "printed page" as the copyright notice for easier identification within third-party archives. - Copyright 2016 - 2019 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): + Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/examples/custom_reporters/ut_expectations_reporter.tpb b/examples/custom_reporters/ut_expectations_reporter.tpb index af9cceb28..6ea5f1cda 100644 --- a/examples/custom_reporters/ut_expectations_reporter.tpb +++ b/examples/custom_reporters/ut_expectations_reporter.tpb @@ -1,10 +1,10 @@ create or replace type body ut_expectations_reporter is /* utPLSQL - Version 3 - Copyright 2016 - 2020 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/examples/custom_reporters/ut_expectations_reporter.tps b/examples/custom_reporters/ut_expectations_reporter.tps index a4238c302..9095051cd 100644 --- a/examples/custom_reporters/ut_expectations_reporter.tps +++ b/examples/custom_reporters/ut_expectations_reporter.tps @@ -1,10 +1,10 @@ create or replace type ut_expectations_reporter under ut_documentation_reporter( /* utPLSQL - Version 3 - Copyright 2016 - 2020 utPLSQL Project + Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/mkdocs.yml b/mkdocs.yml index 72eebaa17..cb8b69e63 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -9,7 +9,7 @@ site_url: https://www.utplsql.org/ site_name: utPLSQL site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL copyright: > - Copyright © 2016 - 2026 utPLSQL contributors. + Copyright © 2016 - 2026 utPLSQL Project. utPLSQL is stewarded by utPLSQL Development Labs Ltd. Change cookie settings repo_url: https://github.com/utPLSQL/utPLSQL diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index 49e986c95..a279d851b 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -8,7 +8,7 @@ edit_uri: "" site_url: https://www.utplsql.org/ site_name: utPLSQL-framework site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL & SQL -copyright: Copyright © 2016 - 2026 utPLSQL contributors. utPLSQL is stewarded by utPLSQL Development Labs Ltd. +copyright: Copyright © 2016 - 2026 utPLSQL Project. utPLSQL is stewarded by utPLSQL Development Labs Ltd. #repo_url: https://github.com/utPLSQL/utPLSQL # disable for offline docs extra_css: - stylesheets/extra.css diff --git a/source/api/ut.pkb b/source/api/ut.pkb index 0a847cfaa..d2cd65f1d 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -4,8 +4,8 @@ create or replace noneditionable package body ut is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/api/ut.pks b/source/api/ut.pks index fdba6b019..2fb843f22 100644 --- a/source/api/ut.pks +++ b/source/api/ut.pks @@ -4,8 +4,8 @@ create or replace noneditionable package ut authid current_user as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 0db1d6e96..3366562af 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -4,8 +4,8 @@ create or replace noneditionable package body ut_runner is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/api/ut_runner.pks b/source/api/ut_runner.pks index 17bd0fa7a..6f73138ea 100644 --- a/source/api/ut_runner.pks +++ b/source/api/ut_runner.pks @@ -4,8 +4,8 @@ create or replace noneditionable package ut_runner authid current_user is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/api/ut_suite_item_info.tpb b/source/api/ut_suite_item_info.tpb index d18f078ee..7005ded37 100644 --- a/source/api/ut_suite_item_info.tpb +++ b/source/api/ut_suite_item_info.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_suite_item_info is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/api/ut_suite_item_info.tps b/source/api/ut_suite_item_info.tps index 4b4f9d52c..c6fdbeb72 100644 --- a/source/api/ut_suite_item_info.tps +++ b/source/api/ut_suite_item_info.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_suite_item_info as object ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/api/ut_suite_items_info.tps b/source/api/ut_suite_items_info.tps index 5a04c9a74..ac0d52a93 100644 --- a/source/api/ut_suite_items_info.tps +++ b/source/api/ut_suite_items_info.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_suite_items_info as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/check_object_grants.sql b/source/check_object_grants.sql index 0e7a9b4c9..ba9d20c6e 100644 --- a/source/check_object_grants.sql +++ b/source/check_object_grants.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/check_sys_grants.sql b/source/check_sys_grants.sql index f81157183..9e1a64e0b 100644 --- a/source/check_sys_grants.sql +++ b/source/check_sys_grants.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotated_object.tps b/source/core/annotations/ut_annotated_object.tps index ca327d7fc..a8b767212 100644 --- a/source/core/annotations/ut_annotated_object.tps +++ b/source/core/annotations/ut_annotated_object.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_annotated_object as object( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotated_objects.tps b/source/core/annotations/ut_annotated_objects.tps index 2b338e7d9..fe8fc62f7 100644 --- a/source/core/annotations/ut_annotated_objects.tps +++ b/source/core/annotations/ut_annotated_objects.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_annotated_objects as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotation.tps b/source/core/annotations/ut_annotation.tps index cc1f90e86..5b8208b8a 100644 --- a/source/core/annotations/ut_annotation.tps +++ b/source/core/annotations/ut_annotation.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_annotation as object( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotation_cache.sql b/source/core/annotations/ut_annotation_cache.sql index 7d69b1db6..2ebcb245f 100644 --- a/source/core/annotations/ut_annotation_cache.sql +++ b/source/core/annotations/ut_annotation_cache.sql @@ -2,8 +2,8 @@ create table ut_annotation_cache ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/annotations/ut_annotation_cache_info.sql b/source/core/annotations/ut_annotation_cache_info.sql index 6248f4fbc..d8d9ab663 100644 --- a/source/core/annotations/ut_annotation_cache_info.sql +++ b/source/core/annotations/ut_annotation_cache_info.sql @@ -2,8 +2,8 @@ create table ut_annotation_cache_info ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index afc473404..2917102c0 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_annotation_cache_manager as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotation_cache_manager.pks b/source/core/annotations/ut_annotation_cache_manager.pks index 1aa4cb501..cfd9a0280 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pks +++ b/source/core/annotations/ut_annotation_cache_manager.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_annotation_cache_manager authid defi utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotation_cache_schema.sql b/source/core/annotations/ut_annotation_cache_schema.sql index b8ebaa40b..46c49739d 100644 --- a/source/core/annotations/ut_annotation_cache_schema.sql +++ b/source/core/annotations/ut_annotation_cache_schema.sql @@ -2,8 +2,8 @@ create table ut_annotation_cache_schema ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/annotations/ut_annotation_cache_seq.sql b/source/core/annotations/ut_annotation_cache_seq.sql index f0f1f17d7..0313abde5 100644 --- a/source/core/annotations/ut_annotation_cache_seq.sql +++ b/source/core/annotations/ut_annotation_cache_seq.sql @@ -2,8 +2,8 @@ create sequence ut_annotation_cache_seq /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index b35f40075..4e1729beb 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_annotation_manager as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotation_manager.pks b/source/core/annotations/ut_annotation_manager.pks index eedef002a..37809e88c 100644 --- a/source/core/annotations/ut_annotation_manager.pks +++ b/source/core/annotations/ut_annotation_manager.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_annotation_manager authid current_us utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotation_obj_cache_info.tps b/source/core/annotations/ut_annotation_obj_cache_info.tps index 5436a11ed..1e2d9d265 100644 --- a/source/core/annotations/ut_annotation_obj_cache_info.tps +++ b/source/core/annotations/ut_annotation_obj_cache_info.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_annotation_obj_cache_info as object( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotation_objs_cache_info.tps b/source/core/annotations/ut_annotation_objs_cache_info.tps index c29b7d208..1e1d730b6 100644 --- a/source/core/annotations/ut_annotation_objs_cache_info.tps +++ b/source/core/annotations/ut_annotation_objs_cache_info.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_annotation_objs_cache_info as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotation_parser.pkb b/source/core/annotations/ut_annotation_parser.pkb index 5680d3cd2..f7314c2a0 100644 --- a/source/core/annotations/ut_annotation_parser.pkb +++ b/source/core/annotations/ut_annotation_parser.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_annotation_parser as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotation_parser.pks b/source/core/annotations/ut_annotation_parser.pks index 3e0eaf84c..84d54df81 100644 --- a/source/core/annotations/ut_annotation_parser.pks +++ b/source/core/annotations/ut_annotation_parser.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_annotation_parser authid current_use utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_annotations.tps b/source/core/annotations/ut_annotations.tps index 9e4adc5ae..2295dc797 100644 --- a/source/core/annotations/ut_annotations.tps +++ b/source/core/annotations/ut_annotations.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_annotations utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_trigger_annotation_parsing.trg b/source/core/annotations/ut_trigger_annotation_parsing.trg index 75caea5e8..60d1fec16 100644 --- a/source/core/annotations/ut_trigger_annotation_parsing.trg +++ b/source/core/annotations/ut_trigger_annotation_parsing.trg @@ -6,8 +6,8 @@ begin utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_trigger_check.pkb b/source/core/annotations/ut_trigger_check.pkb index 463243c5e..c9b5172f7 100644 --- a/source/core/annotations/ut_trigger_check.pkb +++ b/source/core/annotations/ut_trigger_check.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_trigger_check is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/annotations/ut_trigger_check.pks b/source/core/annotations/ut_trigger_check.pks index dae59f3aa..a473c859b 100644 --- a/source/core/annotations/ut_trigger_check.pks +++ b/source/core/annotations/ut_trigger_check.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_trigger_check authid definer is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index be9b4ad5d..9f5649ac1 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_coverage is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage.pks b/source/core/coverage/ut_coverage.pks index b8bc4e169..f777fde4e 100644 --- a/source/core/coverage/ut_coverage.pks +++ b/source/core/coverage/ut_coverage.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_coverage authid current_user is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_block.pkb b/source/core/coverage/ut_coverage_block.pkb index bfdf13274..9ca4caff4 100644 --- a/source/core/coverage/ut_coverage_block.pkb +++ b/source/core/coverage/ut_coverage_block.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_coverage_block is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_block.pks b/source/core/coverage/ut_coverage_block.pks index 9fccb3272..68451e1ed 100644 --- a/source/core/coverage/ut_coverage_block.pks +++ b/source/core/coverage/ut_coverage_block.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_coverage_block authid current_user i utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_helper.pkb b/source/core/coverage/ut_coverage_helper.pkb index ed1bea2ce..555c12fa4 100644 --- a/source/core/coverage/ut_coverage_helper.pkb +++ b/source/core/coverage/ut_coverage_helper.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_coverage_helper is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_helper.pks b/source/core/coverage/ut_coverage_helper.pks index 11988d935..3b51bddb3 100644 --- a/source/core/coverage/ut_coverage_helper.pks +++ b/source/core/coverage/ut_coverage_helper.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_coverage_helper authid definer is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index 3abbd54fc..ec4b9d04b 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_coverage_helper_block is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_helper_block.pks b/source/core/coverage/ut_coverage_helper_block.pks index dd8c451d7..0bef1ebce 100644 --- a/source/core/coverage/ut_coverage_helper_block.pks +++ b/source/core/coverage/ut_coverage_helper_block.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_coverage_helper_block authid current utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_helper_profiler.pkb b/source/core/coverage/ut_coverage_helper_profiler.pkb index f98631593..f1c9ab921 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pkb +++ b/source/core/coverage/ut_coverage_helper_profiler.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_coverage_helper_profiler is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_helper_profiler.pks b/source/core/coverage/ut_coverage_helper_profiler.pks index ca2a44a64..841235080 100644 --- a/source/core/coverage/ut_coverage_helper_profiler.pks +++ b/source/core/coverage/ut_coverage_helper_profiler.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_coverage_helper_profiler authid defi utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_profiler.pkb b/source/core/coverage/ut_coverage_profiler.pkb index 4e874dabf..1bd037083 100644 --- a/source/core/coverage/ut_coverage_profiler.pkb +++ b/source/core/coverage/ut_coverage_profiler.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_coverage_profiler is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_profiler.pks b/source/core/coverage/ut_coverage_profiler.pks index 788005e15..4cdab2ae1 100644 --- a/source/core/coverage/ut_coverage_profiler.pks +++ b/source/core/coverage/ut_coverage_profiler.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_coverage_profiler authid current_use utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_reporter_base.tpb b/source/core/coverage/ut_coverage_reporter_base.tpb index e86af3795..70d27afc3 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tpb +++ b/source/core/coverage/ut_coverage_reporter_base.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_coverage_reporter_base is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_reporter_base.tps b/source/core/coverage/ut_coverage_reporter_base.tps index c4afe389b..3de89e8bb 100644 --- a/source/core/coverage/ut_coverage_reporter_base.tps +++ b/source/core/coverage/ut_coverage_reporter_base.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_coverage_reporter_base under ut_output_ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/coverage/ut_coverage_sources_tmp.sql b/source/core/coverage/ut_coverage_sources_tmp.sql index 35eb05510..90fe38171 100644 --- a/source/core/coverage/ut_coverage_sources_tmp.sql +++ b/source/core/coverage/ut_coverage_sources_tmp.sql @@ -2,8 +2,8 @@ create global temporary table ut_coverage_sources_tmp( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/events/ut_event_item.tps b/source/core/events/ut_event_item.tps index d9e1b84fc..28391a8d2 100644 --- a/source/core/events/ut_event_item.tps +++ b/source/core/events/ut_event_item.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_event_item authid current_user as objec utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/events/ut_event_listener.tps b/source/core/events/ut_event_listener.tps index 7236fd512..c16d00065 100644 --- a/source/core/events/ut_event_listener.tps +++ b/source/core/events/ut_event_listener.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_event_listener authid current_user as o utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/events/ut_event_manager.pkb b/source/core/events/ut_event_manager.pkb index 50c500d13..bbc342a1f 100644 --- a/source/core/events/ut_event_manager.pkb +++ b/source/core/events/ut_event_manager.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_event_manager as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/events/ut_event_manager.pks b/source/core/events/ut_event_manager.pks index 08db7f5da..d6480b83f 100644 --- a/source/core/events/ut_event_manager.pks +++ b/source/core/events/ut_event_manager.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_event_manager authid current_user as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index 8b9c236ef..5ce32eb23 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_output_buffer_base is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_buffer_base.tps b/source/core/output_buffers/ut_output_buffer_base.tps index da2bc9143..e2d1c6731 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tps +++ b/source/core/output_buffers/ut_output_buffer_base.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_output_buffer_base force authid definer utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_buffer_info_tmp.sql b/source/core/output_buffers/ut_output_buffer_info_tmp.sql index 2aba5a55c..b8bb10095 100644 --- a/source/core/output_buffers/ut_output_buffer_info_tmp.sql +++ b/source/core/output_buffers/ut_output_buffer_info_tmp.sql @@ -2,8 +2,8 @@ create table ut_output_buffer_info_tmp( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/output_buffers/ut_output_buffer_tmp.sql b/source/core/output_buffers/ut_output_buffer_tmp.sql index 68b738d3f..535246bde 100644 --- a/source/core/output_buffers/ut_output_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_buffer_tmp.sql @@ -2,8 +2,8 @@ create table ut_output_buffer_tmp( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tpb b/source/core/output_buffers/ut_output_bulk_buffer.tpb index 4f6698eaf..bd5b66339 100644 --- a/source/core/output_buffers/ut_output_bulk_buffer.tpb +++ b/source/core/output_buffers/ut_output_bulk_buffer.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_output_bulk_buffer is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tps b/source/core/output_buffers/ut_output_bulk_buffer.tps index 538bc12a5..7534e8fa8 100644 --- a/source/core/output_buffers/ut_output_bulk_buffer.tps +++ b/source/core/output_buffers/ut_output_bulk_buffer.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_output_bulk_buffer under ut_output_buff utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql index fa61191ce..d8b3b8db9 100644 --- a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql @@ -7,8 +7,8 @@ begin /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index f6d7c9a66..91dd10e29 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_output_clob_table_buffer is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tps b/source/core/output_buffers/ut_output_clob_table_buffer.tps index b254c1f47..22d6ac227 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tps +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_output_clob_table_buffer under ut_outpu utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_data_row.tps b/source/core/output_buffers/ut_output_data_row.tps index 2eed2ee1f..a8f0743ee 100644 --- a/source/core/output_buffers/ut_output_data_row.tps +++ b/source/core/output_buffers/ut_output_data_row.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_output_data_row as object ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_data_rows.tps b/source/core/output_buffers/ut_output_data_rows.tps index a10440617..6067e0d3b 100644 --- a/source/core/output_buffers/ut_output_data_rows.tps +++ b/source/core/output_buffers/ut_output_data_rows.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_output_data_rows as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index d87362572..a4ea2be8d 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_output_table_buffer is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/output_buffers/ut_output_table_buffer.tps b/source/core/output_buffers/ut_output_table_buffer.tps index 3f13e736d..06e157d90 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tps +++ b/source/core/output_buffers/ut_output_table_buffer.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_output_table_buffer under ut_output_buf utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/session_context/ut_session_context.pkb b/source/core/session_context/ut_session_context.pkb index 12d104eed..2db83506e 100644 --- a/source/core/session_context/ut_session_context.pkb +++ b/source/core/session_context/ut_session_context.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_session_context as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/session_context/ut_session_context.pks b/source/core/session_context/ut_session_context.pks index a5e4038a0..1221bccda 100644 --- a/source/core/session_context/ut_session_context.pks +++ b/source/core/session_context/ut_session_context.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_session_context as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/session_context/ut_session_info.tpb b/source/core/session_context/ut_session_info.tpb index 14f52b003..fd1b80069 100644 --- a/source/core/session_context/ut_session_info.tpb +++ b/source/core/session_context/ut_session_info.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_session_info as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/session_context/ut_session_info.tps b/source/core/session_context/ut_session_info.tps index d682a6bad..741d6cb59 100644 --- a/source/core/session_context/ut_session_info.tps +++ b/source/core/session_context/ut_session_info.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_session_info under ut_event_listener ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_console_reporter_base.tpb b/source/core/types/ut_console_reporter_base.tpb index 0825b8ba2..635a4d456 100644 --- a/source/core/types/ut_console_reporter_base.tpb +++ b/source/core/types/ut_console_reporter_base.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_console_reporter_base is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_console_reporter_base.tps b/source/core/types/ut_console_reporter_base.tps index 46b344e6e..d23c6d9e4 100644 --- a/source/core/types/ut_console_reporter_base.tps +++ b/source/core/types/ut_console_reporter_base.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_console_reporter_base under ut_output_r utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_coverage_options.tpb b/source/core/types/ut_coverage_options.tpb index 2accd960a..f4e07bf9b 100644 --- a/source/core/types/ut_coverage_options.tpb +++ b/source/core/types/ut_coverage_options.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_coverage_options as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_coverage_options.tps b/source/core/types/ut_coverage_options.tps index f2db1dafe..81a04101f 100644 --- a/source/core/types/ut_coverage_options.tps +++ b/source/core/types/ut_coverage_options.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_coverage_options force as object ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_executable.tpb b/source/core/types/ut_executable.tpb index 2fa3c1b5d..5d454989d 100644 --- a/source/core/types/ut_executable.tpb +++ b/source/core/types/ut_executable.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_executable is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_executable.tps b/source/core/types/ut_executable.tps index 0945a8996..4e263402d 100644 --- a/source/core/types/ut_executable.tps +++ b/source/core/types/ut_executable.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_executable under ut_event_item( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_executable_test.tpb b/source/core/types/ut_executable_test.tpb index 8e48bd70a..06851a007 100644 --- a/source/core/types/ut_executable_test.tpb +++ b/source/core/types/ut_executable_test.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_executable_test as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_executable_test.tps b/source/core/types/ut_executable_test.tps index d477456f6..2f9a5f236 100644 --- a/source/core/types/ut_executable_test.tps +++ b/source/core/types/ut_executable_test.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_executable_test authid current_user und utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_executables.tps b/source/core/types/ut_executables.tps index 7718c44b8..fb08b287d 100644 --- a/source/core/types/ut_executables.tps +++ b/source/core/types/ut_executables.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_executables as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_expectation_result.tpb b/source/core/types/ut_expectation_result.tpb index 3ffd11789..b98853efc 100644 --- a/source/core/types/ut_expectation_result.tpb +++ b/source/core/types/ut_expectation_result.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_expectation_result is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_expectation_result.tps b/source/core/types/ut_expectation_result.tps index e7eedd5ce..5fc296bfe 100644 --- a/source/core/types/ut_expectation_result.tps +++ b/source/core/types/ut_expectation_result.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_expectation_result under ut_event_item( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_expectation_results.tps b/source/core/types/ut_expectation_results.tps index 168941112..361bb8669 100644 --- a/source/core/types/ut_expectation_results.tps +++ b/source/core/types/ut_expectation_results.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_expectation_results as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_file_mapping.tpb b/source/core/types/ut_file_mapping.tpb index d693ac633..4286bb171 100644 --- a/source/core/types/ut_file_mapping.tpb +++ b/source/core/types/ut_file_mapping.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_file_mapping as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_file_mapping.tps b/source/core/types/ut_file_mapping.tps index d28ef40ae..bd048a218 100644 --- a/source/core/types/ut_file_mapping.tps +++ b/source/core/types/ut_file_mapping.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_file_mapping as object( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_file_mappings.tps b/source/core/types/ut_file_mappings.tps index 715530ee0..8ad94d2ec 100644 --- a/source/core/types/ut_file_mappings.tps +++ b/source/core/types/ut_file_mappings.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_file_mappings as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_integer_list.tps b/source/core/types/ut_integer_list.tps index b15cf743c..86316e630 100644 --- a/source/core/types/ut_integer_list.tps +++ b/source/core/types/ut_integer_list.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_integer_list as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_key_value_pair.tps b/source/core/types/ut_key_value_pair.tps index e26fff031..0082affd3 100644 --- a/source/core/types/ut_key_value_pair.tps +++ b/source/core/types/ut_key_value_pair.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_key_value_pair force as object( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_key_value_pairs.tps b/source/core/types/ut_key_value_pairs.tps index d9e829dc9..4b76438d4 100644 --- a/source/core/types/ut_key_value_pairs.tps +++ b/source/core/types/ut_key_value_pairs.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_key_value_pairs as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_logical_suite.tpb b/source/core/types/ut_logical_suite.tpb index c91320d8a..47a154399 100644 --- a/source/core/types/ut_logical_suite.tpb +++ b/source/core/types/ut_logical_suite.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_logical_suite as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_logical_suite.tps b/source/core/types/ut_logical_suite.tps index 245c422a1..5993ee4f8 100644 --- a/source/core/types/ut_logical_suite.tps +++ b/source/core/types/ut_logical_suite.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_logical_suite force under ut_suite_item utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_object_name.tpb b/source/core/types/ut_object_name.tpb index 67834a9ed..ce5d3b052 100644 --- a/source/core/types/ut_object_name.tpb +++ b/source/core/types/ut_object_name.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_object_name as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_object_name.tps b/source/core/types/ut_object_name.tps index 7f6341a32..23ab1b161 100644 --- a/source/core/types/ut_object_name.tps +++ b/source/core/types/ut_object_name.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_object_name as object ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_object_names.tps b/source/core/types/ut_object_names.tps index 879493a63..10159fbbb 100644 --- a/source/core/types/ut_object_names.tps +++ b/source/core/types/ut_object_names.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_object_names as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_output_reporter_base.tpb b/source/core/types/ut_output_reporter_base.tpb index 4553f1780..4857036a6 100644 --- a/source/core/types/ut_output_reporter_base.tpb +++ b/source/core/types/ut_output_reporter_base.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_output_reporter_base is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_output_reporter_base.tps b/source/core/types/ut_output_reporter_base.tps index b9ec4f7cd..585069cf7 100644 --- a/source/core/types/ut_output_reporter_base.tps +++ b/source/core/types/ut_output_reporter_base.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_output_reporter_base under ut_reporter_ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_path_item.tpb b/source/core/types/ut_path_item.tpb index 486fde865..3d85c4e3e 100644 --- a/source/core/types/ut_path_item.tpb +++ b/source/core/types/ut_path_item.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_path_item as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_path_item.tps b/source/core/types/ut_path_item.tps index fdc1e8ac2..e90cf6099 100644 --- a/source/core/types/ut_path_item.tps +++ b/source/core/types/ut_path_item.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_path_item as object ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_path_items.tps b/source/core/types/ut_path_items.tps index 64f8dd5fe..0cf12fa1a 100644 --- a/source/core/types/ut_path_items.tps +++ b/source/core/types/ut_path_items.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_path_items as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_reporter_base.tpb b/source/core/types/ut_reporter_base.tpb index e457645f4..5dca1db44 100644 --- a/source/core/types/ut_reporter_base.tpb +++ b/source/core/types/ut_reporter_base.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_reporter_base is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_reporter_base.tps b/source/core/types/ut_reporter_base.tps index af0472dc5..f90162791 100644 --- a/source/core/types/ut_reporter_base.tps +++ b/source/core/types/ut_reporter_base.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_reporter_base under ut_event_listener ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_reporter_info.tps b/source/core/types/ut_reporter_info.tps index 29c7559f1..6f7219f7c 100644 --- a/source/core/types/ut_reporter_info.tps +++ b/source/core/types/ut_reporter_info.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_reporter_info as object ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_reporters.tps b/source/core/types/ut_reporters.tps index fba22480f..d47240e8b 100644 --- a/source/core/types/ut_reporters.tps +++ b/source/core/types/ut_reporters.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_reporters as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_reporters_info.tps b/source/core/types/ut_reporters_info.tps index 4f6f054a3..b100789df 100644 --- a/source/core/types/ut_reporters_info.tps +++ b/source/core/types/ut_reporters_info.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_reporters_info as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_results_counter.tpb b/source/core/types/ut_results_counter.tpb index 54f9e0b48..64be5d5a4 100644 --- a/source/core/types/ut_results_counter.tpb +++ b/source/core/types/ut_results_counter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_results_counter as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_results_counter.tps b/source/core/types/ut_results_counter.tps index 477d4b217..d53d37e21 100644 --- a/source/core/types/ut_results_counter.tps +++ b/source/core/types/ut_results_counter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_results_counter as object( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_run.tpb b/source/core/types/ut_run.tpb index 80621b5ad..1e70a2fc4 100644 --- a/source/core/types/ut_run.tpb +++ b/source/core/types/ut_run.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_run as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_run.tps b/source/core/types/ut_run.tps index 551e56ac4..f55a84dda 100644 --- a/source/core/types/ut_run.tps +++ b/source/core/types/ut_run.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_run under ut_suite_item ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_run_info.tpb b/source/core/types/ut_run_info.tpb index 3de74b2b4..509960b05 100644 --- a/source/core/types/ut_run_info.tpb +++ b/source/core/types/ut_run_info.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_run_info as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 @@ -12,7 +12,7 @@ create or replace noneditionable type body ut_run_info as Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions andTEST_GET_REPORTERS_LIST + See the License for the specific language governing permissions and limitations under the License. */ constructor function ut_run_info(self in out nocopy ut_run_info) return self as result is diff --git a/source/core/types/ut_run_info.tps b/source/core/types/ut_run_info.tps index 00919b172..b8ad8c55b 100644 --- a/source/core/types/ut_run_info.tps +++ b/source/core/types/ut_run_info.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_run_info under ut_event_item ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_stack.tpb b/source/core/types/ut_stack.tpb index 4298ae35c..40ba8982b 100644 --- a/source/core/types/ut_stack.tpb +++ b/source/core/types/ut_stack.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_stack as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_stack.tps b/source/core/types/ut_stack.tps index ed79bea55..9356c4eb2 100644 --- a/source/core/types/ut_stack.tps +++ b/source/core/types/ut_stack.tps @@ -5,8 +5,8 @@ create or replace noneditionable type ut_stack as object ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_suite.tpb b/source/core/types/ut_suite.tpb index b4e3eabf0..7012dee97 100644 --- a/source/core/types/ut_suite.tpb +++ b/source/core/types/ut_suite.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_suite as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_suite.tps b/source/core/types/ut_suite.tps index edce778f1..3ed0def80 100644 --- a/source/core/types/ut_suite.tps +++ b/source/core/types/ut_suite.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_suite under ut_logical_suite ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_suite_cache_row.tps b/source/core/types/ut_suite_cache_row.tps index 1ee371a88..2293f9273 100644 --- a/source/core/types/ut_suite_cache_row.tps +++ b/source/core/types/ut_suite_cache_row.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_suite_cache_row as object ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_suite_cache_rows.tps b/source/core/types/ut_suite_cache_rows.tps index 84bcc9f75..cb3b573eb 100644 --- a/source/core/types/ut_suite_cache_rows.tps +++ b/source/core/types/ut_suite_cache_rows.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_suite_cache_rows as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_suite_context.tpb b/source/core/types/ut_suite_context.tpb index dad24e42e..9221cb160 100644 --- a/source/core/types/ut_suite_context.tpb +++ b/source/core/types/ut_suite_context.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_suite_context as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_suite_context.tps b/source/core/types/ut_suite_context.tps index b890e2633..a60899f9b 100644 --- a/source/core/types/ut_suite_context.tps +++ b/source/core/types/ut_suite_context.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_suite_context under ut_suite ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_suite_item.tpb b/source/core/types/ut_suite_item.tpb index 8e8c6fd90..01b9b0ee0 100644 --- a/source/core/types/ut_suite_item.tpb +++ b/source/core/types/ut_suite_item.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_suite_item as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_suite_item.tps b/source/core/types/ut_suite_item.tps index 2e990353f..556ff7f0b 100644 --- a/source/core/types/ut_suite_item.tps +++ b/source/core/types/ut_suite_item.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_suite_item force under ut_event_item ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_suite_items.tps b/source/core/types/ut_suite_items.tps index b7ce9873c..fe11b732a 100644 --- a/source/core/types/ut_suite_items.tps +++ b/source/core/types/ut_suite_items.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_suite_items as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_test.tpb b/source/core/types/ut_test.tpb index 61a1e39f8..c3577274c 100644 --- a/source/core/types/ut_test.tpb +++ b/source/core/types/ut_test.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_test as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_test.tps b/source/core/types/ut_test.tps index cb50c2fd4..7590abc35 100644 --- a/source/core/types/ut_test.tps +++ b/source/core/types/ut_test.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_test force under ut_suite_item ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_varchar2_list.tps b/source/core/types/ut_varchar2_list.tps index 8203a4bab..86c26d4de 100644 --- a/source/core/types/ut_varchar2_list.tps +++ b/source/core/types/ut_varchar2_list.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_varchar2_list as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/types/ut_varchar2_rows.tps b/source/core/types/ut_varchar2_rows.tps index a2e25e9fb..f34f990e6 100644 --- a/source/core/types/ut_varchar2_rows.tps +++ b/source/core/types/ut_varchar2_rows.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_varchar2_rows as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_dbms_output_cache.sql b/source/core/ut_dbms_output_cache.sql index 802f30942..344afc7aa 100644 --- a/source/core/ut_dbms_output_cache.sql +++ b/source/core/ut_dbms_output_cache.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index 3fb39a5b9..ab8a5f3f5 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_expectation_processor as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_expectation_processor.pks b/source/core/ut_expectation_processor.pks index 5349ee70a..8d19becce 100644 --- a/source/core/ut_expectation_processor.pks +++ b/source/core/ut_expectation_processor.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_expectation_processor authid current utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_file_mapper.pkb b/source/core/ut_file_mapper.pkb index 40204a5da..8cb3f3911 100644 --- a/source/core/ut_file_mapper.pkb +++ b/source/core/ut_file_mapper.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_file_mapper is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_file_mapper.pks b/source/core/ut_file_mapper.pks index 1363e81ec..e1ce48a54 100644 --- a/source/core/ut_file_mapper.pks +++ b/source/core/ut_file_mapper.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_file_mapper authid current_user is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index d9939ad45..7c89dc5ef 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_metadata as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_metadata.pks b/source/core/ut_metadata.pks index 42f136504..f320e7bf8 100644 --- a/source/core/ut_metadata.pks +++ b/source/core/ut_metadata.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_metadata authid current_user as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_savepoint_seq.sql b/source/core/ut_savepoint_seq.sql index 2026ab0e3..393c2419a 100644 --- a/source/core/ut_savepoint_seq.sql +++ b/source/core/ut_savepoint_seq.sql @@ -2,8 +2,8 @@ create sequence ut_savepoint_seq /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/ut_suite_builder.pkb b/source/core/ut_suite_builder.pkb index 4f0e28606..0c9bbc982 100644 --- a/source/core/ut_suite_builder.pkb +++ b/source/core/ut_suite_builder.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_suite_builder is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_suite_builder.pks b/source/core/ut_suite_builder.pks index 35f207ea4..31b76e2c6 100644 --- a/source/core/ut_suite_builder.pks +++ b/source/core/ut_suite_builder.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_suite_builder authid current_user is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_suite_cache.sql b/source/core/ut_suite_cache.sql index 1d7389e9f..296851a10 100644 --- a/source/core/ut_suite_cache.sql +++ b/source/core/ut_suite_cache.sql @@ -2,8 +2,8 @@ create table ut_suite_cache /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 9aa3cf63d..efbd6e91e 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_suite_cache_manager is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 6ac1d7bd6..6253f391e 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_suite_cache_manager authid definer i utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_suite_cache_package.sql b/source/core/ut_suite_cache_package.sql index 40b7b8dec..1f05c633f 100644 --- a/source/core/ut_suite_cache_package.sql +++ b/source/core/ut_suite_cache_package.sql @@ -2,8 +2,8 @@ create table ut_suite_cache_package ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/ut_suite_cache_schema.sql b/source/core/ut_suite_cache_schema.sql index cace332e3..a49b92f7e 100644 --- a/source/core/ut_suite_cache_schema.sql +++ b/source/core/ut_suite_cache_schema.sql @@ -2,8 +2,8 @@ create table ut_suite_cache_schema ( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/ut_suite_cache_seq.sql b/source/core/ut_suite_cache_seq.sql index 020c25c4d..ce7b5d19a 100644 --- a/source/core/ut_suite_cache_seq.sql +++ b/source/core/ut_suite_cache_seq.sql @@ -2,8 +2,8 @@ create sequence ut_suite_cache_seq /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index fa60be59e..080c8d05c 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_suite_manager is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 60c3595bb..373ef1702 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_suite_manager authid current_user is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index 447ba47d5..870099ea4 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_suite_tag_filter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_suite_tag_filter.pks b/source/core/ut_suite_tag_filter.pks index bb3d4ad73..afb634014 100644 --- a/source/core/ut_suite_tag_filter.pks +++ b/source/core/ut_suite_tag_filter.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_suite_tag_filter authid definer is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_utils.pkb b/source/core/ut_utils.pkb index c8ced3bb9..865e9e17c 100644 --- a/source/core/ut_utils.pkb +++ b/source/core/ut_utils.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_utils is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 36cfb9316..d64bf3a7e 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_utils authid definer is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/create_grants.sql b/source/create_grants.sql index 9318a7220..6cc7f6b37 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/create_synonyms.sql b/source/create_synonyms.sql index ab338f4f7..c862a389c 100644 --- a/source/create_synonyms.sql +++ b/source/create_synonyms.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/create_synonyms_and_grants_for_public.sql b/source/create_synonyms_and_grants_for_public.sql index 25f14217e..572ed7d8f 100644 --- a/source/create_synonyms_and_grants_for_public.sql +++ b/source/create_synonyms_and_grants_for_public.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/create_user_grants.sql b/source/create_user_grants.sql index c1b81efa4..60b2725b5 100644 --- a/source/create_user_grants.sql +++ b/source/create_user_grants.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/create_user_synonyms.sql b/source/create_user_synonyms.sql index 7b0e49553..7fbc5b247 100644 --- a/source/create_user_synonyms.sql +++ b/source/create_user_synonyms.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/create_utplsql_owner.sql b/source/create_utplsql_owner.sql index a5b70ffda..0720a0d06 100644 --- a/source/create_utplsql_owner.sql +++ b/source/create_utplsql_owner.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/define_ut3_owner_param.sql b/source/define_ut3_owner_param.sql index 192e810b7..27fbfe705 100644 --- a/source/define_ut3_owner_param.sql +++ b/source/define_ut3_owner_param.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_compound_data_diff_tmp.sql b/source/expectations/data_values/ut_compound_data_diff_tmp.sql index edd27f766..cffa5fd26 100644 --- a/source/expectations/data_values/ut_compound_data_diff_tmp.sql +++ b/source/expectations/data_values/ut_compound_data_diff_tmp.sql @@ -2,8 +2,8 @@ create global temporary table ut_compound_data_diff_tmp( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/expectations/data_values/ut_compound_data_helper.pkb b/source/expectations/data_values/ut_compound_data_helper.pkb index 763c133d7..ac429e408 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pkb +++ b/source/expectations/data_values/ut_compound_data_helper.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_compound_data_helper is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_compound_data_helper.pks b/source/expectations/data_values/ut_compound_data_helper.pks index 6069920c9..3c13c85e8 100644 --- a/source/expectations/data_values/ut_compound_data_helper.pks +++ b/source/expectations/data_values/ut_compound_data_helper.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_compound_data_helper authid definer utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_compound_data_tmp.sql b/source/expectations/data_values/ut_compound_data_tmp.sql index 01cedd97b..902bf29fc 100644 --- a/source/expectations/data_values/ut_compound_data_tmp.sql +++ b/source/expectations/data_values/ut_compound_data_tmp.sql @@ -2,8 +2,8 @@ create global temporary table ut_compound_data_tmp( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/expectations/data_values/ut_compound_data_value.tpb b/source/expectations/data_values/ut_compound_data_value.tpb index 7db47827e..27c19455b 100644 --- a/source/expectations/data_values/ut_compound_data_value.tpb +++ b/source/expectations/data_values/ut_compound_data_value.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_compound_data_value as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_compound_data_value.tps b/source/expectations/data_values/ut_compound_data_value.tps index c84a59db6..6272e04a7 100644 --- a/source/expectations/data_values/ut_compound_data_value.tps +++ b/source/expectations/data_values/ut_compound_data_value.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_compound_data_value force under ut_data utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_cursor_column.tpb b/source/expectations/data_values/ut_cursor_column.tpb index 3513de23e..a3c5d9171 100644 --- a/source/expectations/data_values/ut_cursor_column.tpb +++ b/source/expectations/data_values/ut_cursor_column.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_cursor_column as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_cursor_column.tps b/source/expectations/data_values/ut_cursor_column.tps index fcf3fe002..45c14c154 100644 --- a/source/expectations/data_values/ut_cursor_column.tps +++ b/source/expectations/data_values/ut_cursor_column.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_cursor_column authid current_user as ob utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_cursor_column_tab.tps b/source/expectations/data_values/ut_cursor_column_tab.tps index 169ba3ce4..6dfe98824 100644 --- a/source/expectations/data_values/ut_cursor_column_tab.tps +++ b/source/expectations/data_values/ut_cursor_column_tab.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_cursor_column_tab as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_cursor_details.tpb b/source/expectations/data_values/ut_cursor_details.tpb index ff204e3bd..ae10cafff 100644 --- a/source/expectations/data_values/ut_cursor_details.tpb +++ b/source/expectations/data_values/ut_cursor_details.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_cursor_details as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_cursor_details.tps b/source/expectations/data_values/ut_cursor_details.tps index c50ed16d3..19f5b3f39 100644 --- a/source/expectations/data_values/ut_cursor_details.tps +++ b/source/expectations/data_values/ut_cursor_details.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_cursor_details authid current_user as o utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value.tpb b/source/expectations/data_values/ut_data_value.tpb index 05eb3022e..a94e88660 100644 --- a/source/expectations/data_values/ut_data_value.tpb +++ b/source/expectations/data_values/ut_data_value.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value.tps b/source/expectations/data_values/ut_data_value.tps index 6e362a56d..d5f00489e 100644 --- a/source/expectations/data_values/ut_data_value.tps +++ b/source/expectations/data_values/ut_data_value.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value force authid current_user as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_anydata.tpb b/source/expectations/data_values/ut_data_value_anydata.tpb index 9fccb7582..6794beaa9 100644 --- a/source/expectations/data_values/ut_data_value_anydata.tpb +++ b/source/expectations/data_values/ut_data_value_anydata.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_anydata as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_anydata.tps b/source/expectations/data_values/ut_data_value_anydata.tps index 6ad692d31..3c56ce178 100644 --- a/source/expectations/data_values/ut_data_value_anydata.tps +++ b/source/expectations/data_values/ut_data_value_anydata.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_anydata under ut_data_value_ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_blob.tpb b/source/expectations/data_values/ut_data_value_blob.tpb index c961ebaab..bf52d4056 100644 --- a/source/expectations/data_values/ut_data_value_blob.tpb +++ b/source/expectations/data_values/ut_data_value_blob.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_blob as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_blob.tps b/source/expectations/data_values/ut_data_value_blob.tps index 94124bfec..5c93a5fac 100644 --- a/source/expectations/data_values/ut_data_value_blob.tps +++ b/source/expectations/data_values/ut_data_value_blob.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_blob under ut_data_value( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_boolean.tpb b/source/expectations/data_values/ut_data_value_boolean.tpb index dd253442c..5a499afb6 100644 --- a/source/expectations/data_values/ut_data_value_boolean.tpb +++ b/source/expectations/data_values/ut_data_value_boolean.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_boolean as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_boolean.tps b/source/expectations/data_values/ut_data_value_boolean.tps index b6df4e0b4..35c05b384 100644 --- a/source/expectations/data_values/ut_data_value_boolean.tps +++ b/source/expectations/data_values/ut_data_value_boolean.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_boolean under ut_data_value( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_clob.tpb b/source/expectations/data_values/ut_data_value_clob.tpb index 76a55545e..6d5a9764d 100644 --- a/source/expectations/data_values/ut_data_value_clob.tpb +++ b/source/expectations/data_values/ut_data_value_clob.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_clob as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_clob.tps b/source/expectations/data_values/ut_data_value_clob.tps index 686757e85..8027e4481 100644 --- a/source/expectations/data_values/ut_data_value_clob.tps +++ b/source/expectations/data_values/ut_data_value_clob.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_clob under ut_data_value( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_date.tpb b/source/expectations/data_values/ut_data_value_date.tpb index 2a1232a1c..f6a588940 100644 --- a/source/expectations/data_values/ut_data_value_date.tpb +++ b/source/expectations/data_values/ut_data_value_date.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_date as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_date.tps b/source/expectations/data_values/ut_data_value_date.tps index 0bb9a17cf..7e3379f31 100644 --- a/source/expectations/data_values/ut_data_value_date.tps +++ b/source/expectations/data_values/ut_data_value_date.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_date under ut_data_value( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tpb b/source/expectations/data_values/ut_data_value_dsinterval.tpb index adad0ef6d..a01766425 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tpb +++ b/source/expectations/data_values/ut_data_value_dsinterval.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_dsinterval as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_dsinterval.tps b/source/expectations/data_values/ut_data_value_dsinterval.tps index 3d15e2e09..9fc81bb6a 100644 --- a/source/expectations/data_values/ut_data_value_dsinterval.tps +++ b/source/expectations/data_values/ut_data_value_dsinterval.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_dsinterval under ut_data_val utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_json.tpb b/source/expectations/data_values/ut_data_value_json.tpb index e1b5aa995..da4f3ac79 100644 --- a/source/expectations/data_values/ut_data_value_json.tpb +++ b/source/expectations/data_values/ut_data_value_json.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_json as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_json.tps b/source/expectations/data_values/ut_data_value_json.tps index c89088564..e8778051b 100644 --- a/source/expectations/data_values/ut_data_value_json.tps +++ b/source/expectations/data_values/ut_data_value_json.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_json under ut_compound_data_ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_number.tpb b/source/expectations/data_values/ut_data_value_number.tpb index 3ea08bbd4..da17e51c9 100644 --- a/source/expectations/data_values/ut_data_value_number.tpb +++ b/source/expectations/data_values/ut_data_value_number.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_number as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_number.tps b/source/expectations/data_values/ut_data_value_number.tps index e7031de72..8bd590515 100644 --- a/source/expectations/data_values/ut_data_value_number.tps +++ b/source/expectations/data_values/ut_data_value_number.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_number under ut_data_value( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_refcursor.tpb b/source/expectations/data_values/ut_data_value_refcursor.tpb index b7f79ac52..01a71d4dd 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tpb +++ b/source/expectations/data_values/ut_data_value_refcursor.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_refcursor as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_refcursor.tps b/source/expectations/data_values/ut_data_value_refcursor.tps index 90a305d32..a32b01d2b 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tps +++ b/source/expectations/data_values/ut_data_value_refcursor.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_refcursor under ut_compound_ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_timestamp.tpb b/source/expectations/data_values/ut_data_value_timestamp.tpb index c6aabf7a3..a7c289d2e 100644 --- a/source/expectations/data_values/ut_data_value_timestamp.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_timestamp as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_timestamp.tps b/source/expectations/data_values/ut_data_value_timestamp.tps index 938b0d63c..e73e85894 100644 --- a/source/expectations/data_values/ut_data_value_timestamp.tps +++ b/source/expectations/data_values/ut_data_value_timestamp.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_timestamp under ut_data_valu utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb index 025314f4b..16a8fd0c8 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_ltz.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_timestamp_ltz as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_timestamp_ltz.tps b/source/expectations/data_values/ut_data_value_timestamp_ltz.tps index e7c61a878..e2252efd4 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_ltz.tps +++ b/source/expectations/data_values/ut_data_value_timestamp_ltz.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_timestamp_ltz under ut_data_ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb index 6af5fea4d..d3375079e 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_tz.tpb +++ b/source/expectations/data_values/ut_data_value_timestamp_tz.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_timestamp_tz as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_timestamp_tz.tps b/source/expectations/data_values/ut_data_value_timestamp_tz.tps index ad190d197..e19b38ef4 100644 --- a/source/expectations/data_values/ut_data_value_timestamp_tz.tps +++ b/source/expectations/data_values/ut_data_value_timestamp_tz.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_timestamp_tz under ut_data_v utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_varchar2.tpb b/source/expectations/data_values/ut_data_value_varchar2.tpb index 7a26d7571..e54491401 100644 --- a/source/expectations/data_values/ut_data_value_varchar2.tpb +++ b/source/expectations/data_values/ut_data_value_varchar2.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_varchar2 as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_varchar2.tps b/source/expectations/data_values/ut_data_value_varchar2.tps index 56effd460..1de824e04 100644 --- a/source/expectations/data_values/ut_data_value_varchar2.tps +++ b/source/expectations/data_values/ut_data_value_varchar2.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_varchar2 under ut_data_value utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_xmltype.tpb b/source/expectations/data_values/ut_data_value_xmltype.tpb index f5ffcbc9a..fb7b5f6b8 100644 --- a/source/expectations/data_values/ut_data_value_xmltype.tpb +++ b/source/expectations/data_values/ut_data_value_xmltype.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_xmltype as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_xmltype.tps b/source/expectations/data_values/ut_data_value_xmltype.tps index 2d0257918..2a4b2a094 100644 --- a/source/expectations/data_values/ut_data_value_xmltype.tps +++ b/source/expectations/data_values/ut_data_value_xmltype.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_xmltype under ut_data_value( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_yminterval.tpb b/source/expectations/data_values/ut_data_value_yminterval.tpb index 8d12d3544..adf2cdff6 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tpb +++ b/source/expectations/data_values/ut_data_value_yminterval.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_data_value_yminterval as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_data_value_yminterval.tps b/source/expectations/data_values/ut_data_value_yminterval.tps index 8c3ad8079..36e3eced0 100644 --- a/source/expectations/data_values/ut_data_value_yminterval.tps +++ b/source/expectations/data_values/ut_data_value_yminterval.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_data_value_yminterval under ut_data_val utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_json_data_diff_tmp.sql b/source/expectations/data_values/ut_json_data_diff_tmp.sql index 4eda07d7c..db2638271 100644 --- a/source/expectations/data_values/ut_json_data_diff_tmp.sql +++ b/source/expectations/data_values/ut_json_data_diff_tmp.sql @@ -2,8 +2,8 @@ create global temporary table ut_json_data_diff_tmp( /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software diff --git a/source/expectations/data_values/ut_json_leaf.tpb b/source/expectations/data_values/ut_json_leaf.tpb index d6c862286..50ab9b545 100644 --- a/source/expectations/data_values/ut_json_leaf.tpb +++ b/source/expectations/data_values/ut_json_leaf.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_json_leaf as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_json_leaf.tps b/source/expectations/data_values/ut_json_leaf.tps index ac478e34e..31ed11539 100644 --- a/source/expectations/data_values/ut_json_leaf.tps +++ b/source/expectations/data_values/ut_json_leaf.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_json_leaf authid current_user as object utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_json_leaf_tab.tps b/source/expectations/data_values/ut_json_leaf_tab.tps index c00f2a3a1..b6195046a 100644 --- a/source/expectations/data_values/ut_json_leaf_tab.tps +++ b/source/expectations/data_values/ut_json_leaf_tab.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_json_leaf_tab as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_json_tree_details.tpb b/source/expectations/data_values/ut_json_tree_details.tpb index 0d457b2c5..4b529eee3 100644 --- a/source/expectations/data_values/ut_json_tree_details.tpb +++ b/source/expectations/data_values/ut_json_tree_details.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_json_tree_details as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_json_tree_details.tps b/source/expectations/data_values/ut_json_tree_details.tps index 4f7e891be..14c24e3ee 100644 --- a/source/expectations/data_values/ut_json_tree_details.tps +++ b/source/expectations/data_values/ut_json_tree_details.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_json_tree_details force as object ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_key_anyval_pair.tps b/source/expectations/data_values/ut_key_anyval_pair.tps index 6ed63ae7e..f2f79fe12 100644 --- a/source/expectations/data_values/ut_key_anyval_pair.tps +++ b/source/expectations/data_values/ut_key_anyval_pair.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_key_anyval_pair force as object( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_key_anyval_pairs.tps b/source/expectations/data_values/ut_key_anyval_pairs.tps index a75305f79..273e7b147 100644 --- a/source/expectations/data_values/ut_key_anyval_pairs.tps +++ b/source/expectations/data_values/ut_key_anyval_pairs.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_key_anyval_pairs as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_key_anyvalues.tpb b/source/expectations/data_values/ut_key_anyvalues.tpb index 4e6dd2c0f..ead307465 100644 --- a/source/expectations/data_values/ut_key_anyvalues.tpb +++ b/source/expectations/data_values/ut_key_anyvalues.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_key_anyvalues as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/data_values/ut_key_anyvalues.tps b/source/expectations/data_values/ut_key_anyvalues.tps index 21a9a5c72..19087af2c 100644 --- a/source/expectations/data_values/ut_key_anyvalues.tps +++ b/source/expectations/data_values/ut_key_anyvalues.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_key_anyvalues under ut_event_item ( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_between.tpb b/source/expectations/matchers/ut_be_between.tpb index 83dfc4c25..83511755c 100644 --- a/source/expectations/matchers/ut_be_between.tpb +++ b/source/expectations/matchers/ut_be_between.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_between is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_between.tps b/source/expectations/matchers/ut_be_between.tps index 7f1403847..e8f5f0d8e 100644 --- a/source/expectations/matchers/ut_be_between.tps +++ b/source/expectations/matchers/ut_be_between.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_between under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_empty.tpb b/source/expectations/matchers/ut_be_empty.tpb index af233aa8f..7f7a4190e 100644 --- a/source/expectations/matchers/ut_be_empty.tpb +++ b/source/expectations/matchers/ut_be_empty.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_empty as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_empty.tps b/source/expectations/matchers/ut_be_empty.tps index a5672ba78..833b8b10f 100644 --- a/source/expectations/matchers/ut_be_empty.tps +++ b/source/expectations/matchers/ut_be_empty.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_empty under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_false.tpb b/source/expectations/matchers/ut_be_false.tpb index a02ac58cb..1256972bb 100644 --- a/source/expectations/matchers/ut_be_false.tpb +++ b/source/expectations/matchers/ut_be_false.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_false as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_false.tps b/source/expectations/matchers/ut_be_false.tps index d793844c1..5c4401555 100644 --- a/source/expectations/matchers/ut_be_false.tps +++ b/source/expectations/matchers/ut_be_false.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_false under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_greater_or_equal.tpb b/source/expectations/matchers/ut_be_greater_or_equal.tpb index 6e564a90c..c7c13c8c3 100644 --- a/source/expectations/matchers/ut_be_greater_or_equal.tpb +++ b/source/expectations/matchers/ut_be_greater_or_equal.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_greater_or_equal AS utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_greater_or_equal.tps b/source/expectations/matchers/ut_be_greater_or_equal.tps index d3e651958..e0d28ae6c 100644 --- a/source/expectations/matchers/ut_be_greater_or_equal.tps +++ b/source/expectations/matchers/ut_be_greater_or_equal.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_greater_or_equal under ut_comparison utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_greater_than.tpb b/source/expectations/matchers/ut_be_greater_than.tpb index 08628ae3a..60d6f319a 100644 --- a/source/expectations/matchers/ut_be_greater_than.tpb +++ b/source/expectations/matchers/ut_be_greater_than.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_greater_than AS utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_greater_than.tps b/source/expectations/matchers/ut_be_greater_than.tps index 745b19f08..659274fb5 100644 --- a/source/expectations/matchers/ut_be_greater_than.tps +++ b/source/expectations/matchers/ut_be_greater_than.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_greater_than under ut_comparison_mat utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_less_or_equal.tpb b/source/expectations/matchers/ut_be_less_or_equal.tpb index 2df06a078..82e011024 100644 --- a/source/expectations/matchers/ut_be_less_or_equal.tpb +++ b/source/expectations/matchers/ut_be_less_or_equal.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_less_or_equal AS utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_less_or_equal.tps b/source/expectations/matchers/ut_be_less_or_equal.tps index f0e297ad1..ab058bd93 100644 --- a/source/expectations/matchers/ut_be_less_or_equal.tps +++ b/source/expectations/matchers/ut_be_less_or_equal.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_less_or_equal under ut_comparison_ma utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_less_than.tpb b/source/expectations/matchers/ut_be_less_than.tpb index c0b059231..9017c839f 100644 --- a/source/expectations/matchers/ut_be_less_than.tpb +++ b/source/expectations/matchers/ut_be_less_than.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_less_than as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_less_than.tps b/source/expectations/matchers/ut_be_less_than.tps index 594df9b71..6b9d78f44 100644 --- a/source/expectations/matchers/ut_be_less_than.tps +++ b/source/expectations/matchers/ut_be_less_than.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_less_than under ut_comparison_matche utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_like.tpb b/source/expectations/matchers/ut_be_like.tpb index b94c3fa91..841765290 100644 --- a/source/expectations/matchers/ut_be_like.tpb +++ b/source/expectations/matchers/ut_be_like.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_like as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_like.tps b/source/expectations/matchers/ut_be_like.tps index ca9ad45de..6d7db0705 100644 --- a/source/expectations/matchers/ut_be_like.tps +++ b/source/expectations/matchers/ut_be_like.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_like under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_not_null.tpb b/source/expectations/matchers/ut_be_not_null.tpb index d291d2e35..6c40ed608 100644 --- a/source/expectations/matchers/ut_be_not_null.tpb +++ b/source/expectations/matchers/ut_be_not_null.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_not_null as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_not_null.tps b/source/expectations/matchers/ut_be_not_null.tps index 61f6c871d..5688cab2b 100644 --- a/source/expectations/matchers/ut_be_not_null.tps +++ b/source/expectations/matchers/ut_be_not_null.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_not_null under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_null.tpb b/source/expectations/matchers/ut_be_null.tpb index 89fbaf563..629990d01 100644 --- a/source/expectations/matchers/ut_be_null.tpb +++ b/source/expectations/matchers/ut_be_null.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_null as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_null.tps b/source/expectations/matchers/ut_be_null.tps index 063c7db29..bee488427 100644 --- a/source/expectations/matchers/ut_be_null.tps +++ b/source/expectations/matchers/ut_be_null.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_null under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_true.tpb b/source/expectations/matchers/ut_be_true.tpb index 59368f342..2cb161a44 100644 --- a/source/expectations/matchers/ut_be_true.tpb +++ b/source/expectations/matchers/ut_be_true.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_true as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_true.tps b/source/expectations/matchers/ut_be_true.tps index 19d397371..35bf71011 100644 --- a/source/expectations/matchers/ut_be_true.tps +++ b/source/expectations/matchers/ut_be_true.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_true under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_within.tpb b/source/expectations/matchers/ut_be_within.tpb index f8f880ace..f34570673 100644 --- a/source/expectations/matchers/ut_be_within.tpb +++ b/source/expectations/matchers/ut_be_within.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_within as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_within.tps b/source/expectations/matchers/ut_be_within.tps index 276c529df..1cef0398c 100644 --- a/source/expectations/matchers/ut_be_within.tps +++ b/source/expectations/matchers/ut_be_within.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_within force under ut_be_within_pct( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_within_helper.pkb b/source/expectations/matchers/ut_be_within_helper.pkb index 635c1b111..9630e319f 100644 --- a/source/expectations/matchers/ut_be_within_helper.pkb +++ b/source/expectations/matchers/ut_be_within_helper.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_be_within_helper as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_within_helper.pks b/source/expectations/matchers/ut_be_within_helper.pks index 5a59eea9e..ca674d3bd 100644 --- a/source/expectations/matchers/ut_be_within_helper.pks +++ b/source/expectations/matchers/ut_be_within_helper.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_be_within_helper authid definer as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_within_pct.tpb b/source/expectations/matchers/ut_be_within_pct.tpb index 82ce8e84e..91364ddab 100644 --- a/source/expectations/matchers/ut_be_within_pct.tpb +++ b/source/expectations/matchers/ut_be_within_pct.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_be_within_pct as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_be_within_pct.tps b/source/expectations/matchers/ut_be_within_pct.tps index 810eaa5b3..048301817 100644 --- a/source/expectations/matchers/ut_be_within_pct.tps +++ b/source/expectations/matchers/ut_be_within_pct.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_be_within_pct force under ut_comparison utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_comparison_matcher.tpb b/source/expectations/matchers/ut_comparison_matcher.tpb index d6c47855d..92245d304 100644 --- a/source/expectations/matchers/ut_comparison_matcher.tpb +++ b/source/expectations/matchers/ut_comparison_matcher.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_comparison_matcher as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_comparison_matcher.tps b/source/expectations/matchers/ut_comparison_matcher.tps index b1ed08a84..4e698348c 100644 --- a/source/expectations/matchers/ut_comparison_matcher.tps +++ b/source/expectations/matchers/ut_comparison_matcher.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_comparison_matcher under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_contain.tpb b/source/expectations/matchers/ut_contain.tpb index bcc3806b7..3494a3d90 100644 --- a/source/expectations/matchers/ut_contain.tpb +++ b/source/expectations/matchers/ut_contain.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_contain as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_contain.tps b/source/expectations/matchers/ut_contain.tps index bd67113c9..9974d3a7c 100644 --- a/source/expectations/matchers/ut_contain.tps +++ b/source/expectations/matchers/ut_contain.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_contain under ut_equal( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_equal.tpb b/source/expectations/matchers/ut_equal.tpb index f999995d1..4bd847c1b 100644 --- a/source/expectations/matchers/ut_equal.tpb +++ b/source/expectations/matchers/ut_equal.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_equal as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_equal.tps b/source/expectations/matchers/ut_equal.tps index eeb715a58..b6665b784 100644 --- a/source/expectations/matchers/ut_equal.tps +++ b/source/expectations/matchers/ut_equal.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_equal force under ut_comparison_matcher utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_have_count.tpb b/source/expectations/matchers/ut_have_count.tpb index f6d3d2682..5abc7fd82 100644 --- a/source/expectations/matchers/ut_have_count.tpb +++ b/source/expectations/matchers/ut_have_count.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_have_count as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_have_count.tps b/source/expectations/matchers/ut_have_count.tps index 85cdf4393..5e979e35f 100644 --- a/source/expectations/matchers/ut_have_count.tps +++ b/source/expectations/matchers/ut_have_count.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_have_count under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_match.tpb b/source/expectations/matchers/ut_match.tpb index 1836298e7..067bd8100 100644 --- a/source/expectations/matchers/ut_match.tpb +++ b/source/expectations/matchers/ut_match.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_match as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_match.tps b/source/expectations/matchers/ut_match.tps index 3f840545f..682632efa 100644 --- a/source/expectations/matchers/ut_match.tps +++ b/source/expectations/matchers/ut_match.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_match under ut_matcher( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_matcher.tpb b/source/expectations/matchers/ut_matcher.tpb index 828e1ac51..0cbf5924d 100644 --- a/source/expectations/matchers/ut_matcher.tpb +++ b/source/expectations/matchers/ut_matcher.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_matcher as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_matcher.tps b/source/expectations/matchers/ut_matcher.tps index ee7f1b5dd..f991afe7d 100644 --- a/source/expectations/matchers/ut_matcher.tps +++ b/source/expectations/matchers/ut_matcher.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_matcher under ut_matcher_base( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_matcher_base.tps b/source/expectations/matchers/ut_matcher_base.tps index ba79a6aed..e425c8baf 100644 --- a/source/expectations/matchers/ut_matcher_base.tps +++ b/source/expectations/matchers/ut_matcher_base.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_matcher_base force authid current_user utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_matcher_options.tpb b/source/expectations/matchers/ut_matcher_options.tpb index 57aca2617..d391acc30 100644 --- a/source/expectations/matchers/ut_matcher_options.tpb +++ b/source/expectations/matchers/ut_matcher_options.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_matcher_options as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_matcher_options.tps b/source/expectations/matchers/ut_matcher_options.tps index db076fd99..92b4207c3 100644 --- a/source/expectations/matchers/ut_matcher_options.tps +++ b/source/expectations/matchers/ut_matcher_options.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_matcher_options authid current_user as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_matcher_options_items.tpb b/source/expectations/matchers/ut_matcher_options_items.tpb index 6e4841870..672acdcaf 100644 --- a/source/expectations/matchers/ut_matcher_options_items.tpb +++ b/source/expectations/matchers/ut_matcher_options_items.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_matcher_options_items is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/matchers/ut_matcher_options_items.tps b/source/expectations/matchers/ut_matcher_options_items.tps index 045a7ece7..bae87b5df 100644 --- a/source/expectations/matchers/ut_matcher_options_items.tps +++ b/source/expectations/matchers/ut_matcher_options_items.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_matcher_options_items authid current_us utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/ut_expectation.tpb b/source/expectations/ut_expectation.tpb index 5f7c9cce0..93bd0763f 100644 --- a/source/expectations/ut_expectation.tpb +++ b/source/expectations/ut_expectation.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_expectation as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/ut_expectation.tps b/source/expectations/ut_expectation.tps index a423c39a4..a04f00caf 100644 --- a/source/expectations/ut_expectation.tps +++ b/source/expectations/ut_expectation.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_expectation force under ut_expectation_ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/ut_expectation_base.tpb b/source/expectations/ut_expectation_base.tpb index 5ed630c63..802855b23 100644 --- a/source/expectations/ut_expectation_base.tpb +++ b/source/expectations/ut_expectation_base.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_expectation_base as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/ut_expectation_base.tps b/source/expectations/ut_expectation_base.tps index 86f274495..48e610054 100644 --- a/source/expectations/ut_expectation_base.tps +++ b/source/expectations/ut_expectation_base.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_expectation_base authid current_user as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/ut_expectation_compound.tpb b/source/expectations/ut_expectation_compound.tpb index d76010f80..067f7922c 100644 --- a/source/expectations/ut_expectation_compound.tpb +++ b/source/expectations/ut_expectation_compound.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_expectation_compound as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/ut_expectation_compound.tps b/source/expectations/ut_expectation_compound.tps index 54de48dd4..38d821266 100644 --- a/source/expectations/ut_expectation_compound.tps +++ b/source/expectations/ut_expectation_compound.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_expectation_compound under ut_expectati utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/ut_expectation_json.tpb b/source/expectations/ut_expectation_json.tpb index 68d4085ef..9f4204ea7 100644 --- a/source/expectations/ut_expectation_json.tpb +++ b/source/expectations/ut_expectation_json.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_expectation_json as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/expectations/ut_expectation_json.tps b/source/expectations/ut_expectation_json.tps index c75154bc8..fd60ccb21 100644 --- a/source/expectations/ut_expectation_json.tps +++ b/source/expectations/ut_expectation_json.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_expectation_json under ut_expectation( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/install.sql b/source/install.sql index 9af0a4f66..5bbb693be 100644 --- a/source/install.sql +++ b/source/install.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/install_above_12_1.sql b/source/install_above_12_1.sql index 5a1943358..162c3dd5f 100644 --- a/source/install_above_12_1.sql +++ b/source/install_above_12_1.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/install_component.sql b/source/install_component.sql index 1189df496..a7394fe9a 100644 --- a/source/install_component.sql +++ b/source/install_component.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/install_ddl_trigger.sql b/source/install_ddl_trigger.sql index b23b4bc63..a9ede374f 100644 --- a/source/install_ddl_trigger.sql +++ b/source/install_ddl_trigger.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/install_headless.sql b/source/install_headless.sql index be1e5becf..04c0109b0 100644 --- a/source/install_headless.sql +++ b/source/install_headless.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/install_headless_with_trigger.sql b/source/install_headless_with_trigger.sql index 2c05403c5..7953b0205 100644 --- a/source/install_headless_with_trigger.sql +++ b/source/install_headless_with_trigger.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_ansiconsole_helper.pkb b/source/reporters/ut_ansiconsole_helper.pkb index e8ee34531..b6610b778 100644 --- a/source/reporters/ut_ansiconsole_helper.pkb +++ b/source/reporters/ut_ansiconsole_helper.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_ansiconsole_helper as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_ansiconsole_helper.pks b/source/reporters/ut_ansiconsole_helper.pks index e882de293..f06f96a7e 100644 --- a/source/reporters/ut_ansiconsole_helper.pks +++ b/source/reporters/ut_ansiconsole_helper.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_ansiconsole_helper as utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_coverage_cobertura_reporter.tpb b/source/reporters/ut_coverage_cobertura_reporter.tpb index c2021974d..36c22c68b 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tpb +++ b/source/reporters/ut_coverage_cobertura_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_coverage_cobertura_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_coverage_cobertura_reporter.tps b/source/reporters/ut_coverage_cobertura_reporter.tps index 799840a55..8e4586c38 100644 --- a/source/reporters/ut_coverage_cobertura_reporter.tps +++ b/source/reporters/ut_coverage_cobertura_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_coverage_cobertura_reporter under ut_co utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_coverage_html_reporter.tpb b/source/reporters/ut_coverage_html_reporter.tpb index 90419371a..50b0fd57c 100644 --- a/source/reporters/ut_coverage_html_reporter.tpb +++ b/source/reporters/ut_coverage_html_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_coverage_html_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_coverage_html_reporter.tps b/source/reporters/ut_coverage_html_reporter.tps index 23cf45c0b..13365efe9 100644 --- a/source/reporters/ut_coverage_html_reporter.tps +++ b/source/reporters/ut_coverage_html_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_coverage_html_reporter under ut_coverag utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index 99c36ab73..7d19968a5 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_coverage_report_html_helper is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_coverage_report_html_helper.pks b/source/reporters/ut_coverage_report_html_helper.pks index 8463e3e89..4eddee9a7 100644 --- a/source/reporters/ut_coverage_report_html_helper.pks +++ b/source/reporters/ut_coverage_report_html_helper.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_coverage_report_html_helper authid c utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_coverage_sonar_reporter.tpb b/source/reporters/ut_coverage_sonar_reporter.tpb index 66c4aacf0..8eb4c57aa 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tpb +++ b/source/reporters/ut_coverage_sonar_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_coverage_sonar_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_coverage_sonar_reporter.tps b/source/reporters/ut_coverage_sonar_reporter.tps index fd160bdb5..0268fee64 100644 --- a/source/reporters/ut_coverage_sonar_reporter.tps +++ b/source/reporters/ut_coverage_sonar_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_coverage_sonar_reporter under ut_covera utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_debug_reporter.tpb b/source/reporters/ut_debug_reporter.tpb index 547437cde..a2b797021 100644 --- a/source/reporters/ut_debug_reporter.tpb +++ b/source/reporters/ut_debug_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_debug_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_debug_reporter.tps b/source/reporters/ut_debug_reporter.tps index edbf1cdc6..26e42cbc4 100644 --- a/source/reporters/ut_debug_reporter.tps +++ b/source/reporters/ut_debug_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_debug_reporter under ut_output_reporter utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_documentation_reporter.tpb b/source/reporters/ut_documentation_reporter.tpb index c13cc56ef..42e5c0fdf 100644 --- a/source/reporters/ut_documentation_reporter.tpb +++ b/source/reporters/ut_documentation_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_documentation_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_documentation_reporter.tps b/source/reporters/ut_documentation_reporter.tps index bab9082c6..52a7911ce 100644 --- a/source/reporters/ut_documentation_reporter.tps +++ b/source/reporters/ut_documentation_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_documentation_reporter under ut_console utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_junit_reporter.tpb b/source/reporters/ut_junit_reporter.tpb index bf62dc564..e7741926d 100644 --- a/source/reporters/ut_junit_reporter.tpb +++ b/source/reporters/ut_junit_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_junit_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_junit_reporter.tps b/source/reporters/ut_junit_reporter.tps index a20913980..88292acbb 100644 --- a/source/reporters/ut_junit_reporter.tps +++ b/source/reporters/ut_junit_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_junit_reporter force under ut_output_re utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_realtime_reporter.tpb b/source/reporters/ut_realtime_reporter.tpb index da0f37077..b0ec5d2e2 100644 --- a/source/reporters/ut_realtime_reporter.tpb +++ b/source/reporters/ut_realtime_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_realtime_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_realtime_reporter.tps b/source/reporters/ut_realtime_reporter.tps index b8686685b..7efdd1bb3 100644 --- a/source/reporters/ut_realtime_reporter.tps +++ b/source/reporters/ut_realtime_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_realtime_reporter force under ut_output utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_sonar_test_reporter.tpb b/source/reporters/ut_sonar_test_reporter.tpb index 8d232b87e..6b8003ecb 100644 --- a/source/reporters/ut_sonar_test_reporter.tpb +++ b/source/reporters/ut_sonar_test_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_sonar_test_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_sonar_test_reporter.tps b/source/reporters/ut_sonar_test_reporter.tps index 0884ad3d3..f7f5aeb39 100644 --- a/source/reporters/ut_sonar_test_reporter.tps +++ b/source/reporters/ut_sonar_test_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_sonar_test_reporter under ut_output_rep utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index c807ab3e1..468d9363c 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_tap_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_tap_reporter.tps b/source/reporters/ut_tap_reporter.tps index 150486648..127256cf8 100644 --- a/source/reporters/ut_tap_reporter.tps +++ b/source/reporters/ut_tap_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_tap_reporter under ut_documentation_rep utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_teamcity_reporter.tpb b/source/reporters/ut_teamcity_reporter.tpb index 94d5497d5..2e76e3e3f 100644 --- a/source/reporters/ut_teamcity_reporter.tpb +++ b/source/reporters/ut_teamcity_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_teamcity_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_teamcity_reporter.tps b/source/reporters/ut_teamcity_reporter.tps index 2def91c35..e70ad4a4b 100644 --- a/source/reporters/ut_teamcity_reporter.tps +++ b/source/reporters/ut_teamcity_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_teamcity_reporter under ut_output_repor utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_teamcity_reporter_helper.pkb b/source/reporters/ut_teamcity_reporter_helper.pkb index 1d33c43ae..ac9d4b567 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pkb +++ b/source/reporters/ut_teamcity_reporter_helper.pkb @@ -3,8 +3,8 @@ create or replace noneditionable package body ut_teamcity_reporter_helper is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_teamcity_reporter_helper.pks b/source/reporters/ut_teamcity_reporter_helper.pks index bb9acef35..03c655c33 100644 --- a/source/reporters/ut_teamcity_reporter_helper.pks +++ b/source/reporters/ut_teamcity_reporter_helper.pks @@ -3,8 +3,8 @@ create or replace noneditionable package ut_teamcity_reporter_helper is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_tfs_junit_reporter.tpb b/source/reporters/ut_tfs_junit_reporter.tpb index a4c8fb868..38aa41bfa 100644 --- a/source/reporters/ut_tfs_junit_reporter.tpb +++ b/source/reporters/ut_tfs_junit_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_tfs_junit_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_tfs_junit_reporter.tps b/source/reporters/ut_tfs_junit_reporter.tps index 560bb10dd..3212085ea 100644 --- a/source/reporters/ut_tfs_junit_reporter.tps +++ b/source/reporters/ut_tfs_junit_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_tfs_junit_reporter under ut_output_repo utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_xunit_reporter.tpb b/source/reporters/ut_xunit_reporter.tpb index 74fc57ac0..4b6007994 100644 --- a/source/reporters/ut_xunit_reporter.tpb +++ b/source/reporters/ut_xunit_reporter.tpb @@ -3,8 +3,8 @@ create or replace noneditionable type body ut_xunit_reporter is utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/reporters/ut_xunit_reporter.tps b/source/reporters/ut_xunit_reporter.tps index d701d8ab0..2e7a84f95 100644 --- a/source/reporters/ut_xunit_reporter.tps +++ b/source/reporters/ut_xunit_reporter.tps @@ -3,8 +3,8 @@ create or replace noneditionable type ut_xunit_reporter under ut_junit_reporter( utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/set_install_params.sql b/source/set_install_params.sql index b559b8023..1d58ab09a 100644 --- a/source/set_install_params.sql +++ b/source/set_install_params.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/uninstall.sql b/source/uninstall.sql index 712845fb7..ba1582844 100644 --- a/source/uninstall.sql +++ b/source/uninstall.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/uninstall_all.sql b/source/uninstall_all.sql index d3d3f3fbe..af94716c1 100644 --- a/source/uninstall_all.sql +++ b/source/uninstall_all.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/uninstall_coverage_tables.sql b/source/uninstall_coverage_tables.sql index df3c19627..6912330ae 100644 --- a/source/uninstall_coverage_tables.sql +++ b/source/uninstall_coverage_tables.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index fcc8dfa52..3e2c2f988 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/source/uninstall_synonyms.sql b/source/uninstall_synonyms.sql index 4a12340f6..58e24060b 100644 --- a/source/uninstall_synonyms.sql +++ b/source/uninstall_synonyms.sql @@ -2,8 +2,8 @@ utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project - Licensed under the Apache License, Version 2.0 (the "License"): - you may not use this file except in compliance with the License. + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 From a873e6b020baf04b033458724d48553f777f2013 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 2 Oct 2026 16:14:02 +0100 Subject: [PATCH 785/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 021fa878a..02759e113 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4544 +4547 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index d64bf3a7e..acc033f79 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4544-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4547-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From f5c781cac28c826b723abbc82a854265ef36dbaa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 2 Oct 2026 23:15:18 +0300 Subject: [PATCH 786/887] Use info@utplsql.org as the public contact address --- mkdocs.yml | 2 +- mkdocs_offline.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index cb8b69e63..096044073 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -92,7 +92,7 @@ extra: - icon: fontawesome/brands/github link: https://github.com/utPLSQL - icon: fontawesome/solid/envelope - link: mailto:utPLSQL@utPLSQL.org + link: mailto:info@utplsql.org version: # disable for offline docs provider: mike # disable for offline docs markdown_extensions: diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index a279d851b..75bab1e4c 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -55,7 +55,7 @@ extra: - icon: fontawesome/brands/github link: https://github.com/utPLSQL - icon: fontawesome/solid/envelope - link: mailto:utPLSQL@utPLSQL.org + link: mailto:info@utplsql.org consent: title: Cookie consent description: >- From 23ea4ee53158864d8a6f029057efcf7b75804b7a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 2 Oct 2026 21:22:51 +0100 Subject: [PATCH 787/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 02759e113..d2a522551 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4547 +4548 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index acc033f79..746561f2e 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4547-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4548-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 7c7cfa074e19c5d7f745848c2215ea497df9130f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Fri, 2 Oct 2026 23:26:51 +0300 Subject: [PATCH 788/887] Use info@utPLSQL.org as the public contact address --- mkdocs.yml | 2 +- mkdocs_offline.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index 096044073..2949f268f 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -92,7 +92,7 @@ extra: - icon: fontawesome/brands/github link: https://github.com/utPLSQL - icon: fontawesome/solid/envelope - link: mailto:info@utplsql.org + link: mailto:info@utPLSQL.org version: # disable for offline docs provider: mike # disable for offline docs markdown_extensions: diff --git a/mkdocs_offline.yml b/mkdocs_offline.yml index 75bab1e4c..8c0ab8fa5 100644 --- a/mkdocs_offline.yml +++ b/mkdocs_offline.yml @@ -55,7 +55,7 @@ extra: - icon: fontawesome/brands/github link: https://github.com/utPLSQL - icon: fontawesome/solid/envelope - link: mailto:info@utplsql.org + link: mailto:info@utPLSQL.org consent: title: Cookie consent description: >- From 67c5f5b5fa81ff7889109715c1dd52a7a73dc558 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 2 Oct 2026 21:34:57 +0100 Subject: [PATCH 789/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index d2a522551..4bd4a90bb 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4548 +4549 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 746561f2e..a10615235 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4548-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4549-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 741acbcb66b1001d348d122dffe9c0329fe7ec56 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 12 Oct 2026 21:25:36 +0300 Subject: [PATCH 790/887] Adding sponsorship page and updates to sponsorship sections. --- CONTRIBUTING.md | 3 ++- SPONSORS.md | 14 ++++++++++++++ development/releasing.md | 1 + readme.md | 9 +++++++++ 4 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 SPONSORS.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 3cac5c86f..964559260 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,7 +1,8 @@ # How to contribute The following are the guidelines everyone should use to contribute to utPLSQL. -Changes are welcome from all members of the Community. +Changes are welcome from all members of the Community. +Not able to contribute code? You can also support the project through [sponsorship](https://www.utplsql.org/sponsorship.html). # Getting Started diff --git a/SPONSORS.md b/SPONSORS.md new file mode 100644 index 000000000..ad75d347c --- /dev/null +++ b/SPONSORS.md @@ -0,0 +1,14 @@ +# Sponsors + +utPLSQL is free and open source under the Apache 2.0 license. Sponsorship funds its maintenance and development. +To become a sponsor, see [utplsql.org/sponsorship](https://www.utplsql.org/sponsorship.html). + +This file is the complete archive of current and past sponsors. The up-to-date recognition lists are on the [sponsors page](https://www.utplsql.org/sponsors.html). + +## Current sponsors + +None yet. + +## Past sponsors + +- [Redgate](https://www.red-gate.com/hub/events/open-source-projects) (2019) diff --git a/development/releasing.md b/development/releasing.md index 99c3f7114..57d353db6 100644 --- a/development/releasing.md +++ b/development/releasing.md @@ -6,6 +6,7 @@ To create a release, follow the below steps. - Create a **draft** of a Release with a new tag number `vX.Y.X` sourced from the `develop` branch on [github releases page](https://github.com/utPLSQL/utPLSQL/releases) - Populate release description using the `Generate release notes` button - Review the auto-generated release notes and update tem if needed + - Add this line at the end of the release notes: `This release was made possible by our sponsors: https://www.utplsql.org/sponsors.html` (a link, not a list of names, so it always shows who is current) - Optionally, split the default `## What's Changed` list into `## New features`, `## Enhancements`, `## Bug fixes`. See previous release notes for details ## Performing a release diff --git a/readme.md b/readme.md index f2b16be37..a0f74c8cc 100644 --- a/readme.md +++ b/readme.md @@ -6,6 +6,7 @@ [![X](https://img.shields.io/badge/X-utPLSQL-000000?logo=x)](https://x.com/utPLSQL) [![Bluesky](https://img.shields.io/badge/Bluesky-utplsql.org-0285FF?logo=bluesky&logoColor=white)](https://bsky.app/profile/utplsql.org) [![LinkedIn](https://img.shields.io/badge/in-utPLSQL-0A66C2)](https://www.linkedin.com/company/utplsql/) +[![Sponsor](https://img.shields.io/badge/Sponsor-utPLSQL-ea4aaa?logo=githubsponsors)](https://www.utplsql.org/sponsorship.html) [![build](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml/badge.svg)](https://github.com/utPLSQL/utPLSQL/actions/workflows/build.yml) [![QualityGate](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL_utPLSQL&metric=sqale_rating)](https://sonarcloud.io/summary/new_code?id=utPLSQL_utPLSQL) [![Coverage](https://sonarcloud.io/api/project_badges/measure?project=utPLSQL_utPLSQL&metric=coverage)](https://sonarcloud.io/summary/new_code?id=utPLSQL_utPLSQL) @@ -140,6 +141,14 @@ We welcome contributions of all kinds. Please read the [contributing guide](CONT The list of **authors** and **significant contributors** is available on the [About](https://www.utplsql.org/about.html) page. For a full list of contributors, see [contributors](https://github.com/utPLSQL/utPLSQL/graphs/contributors?all=1) on GitHub. +## Sponsorship + +utPLSQL is free and open source (Apache 2.0). Sponsorship funds development of new features and tools, maintaining compatibility with new Oracle versions and platforms, documentation. +See [Sponsorship](https://www.utplsql.org/sponsorship.html) for organization tiers, commercial support and individual sponsorship. All current and past sponsors are listed in [SPONSORS.md](SPONSORS.md). + + + + ## License utPLSQL is free and open source, licensed under the [Apache 2.0 license](LICENSE). From a22aebb689f11d908dcf5434a845b59cd7bc3aba Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 12 Oct 2026 19:36:51 +0100 Subject: [PATCH 791/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4bd4a90bb..d1393424b 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4549 +4553 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index a10615235..eed5dfe3c 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4549-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4553-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From c2934c1aec36e893a69b379a02d3ec3173482e4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 18 Oct 2026 00:41:22 +0300 Subject: [PATCH 792/887] Announce releases with the shared announce-release action Use utPLSQL/.github/actions/announce-release@v1 to post the release announcement to the org discussions and to utplsql.github.io. --- .github/scripts/post_release_announcement.sh | 63 -------------------- .github/scripts/publish_release_post.sh | 63 -------------------- .github/workflows/release.yml | 15 ++--- .github/workflows/test_publishing.yml | 12 ++-- development/releasing.md | 3 +- 5 files changed, 16 insertions(+), 140 deletions(-) delete mode 100755 .github/scripts/post_release_announcement.sh delete mode 100755 .github/scripts/publish_release_post.sh diff --git a/.github/scripts/post_release_announcement.sh b/.github/scripts/post_release_announcement.sh deleted file mode 100755 index c74394505..000000000 --- a/.github/scripts/post_release_announcement.sh +++ /dev/null @@ -1,63 +0,0 @@ -#!/bin/bash -# Posts a release announcement to the utPLSQL org .github repository's -# Announcements discussion category. -# -# Required environment variables: -# GH_TOKEN - GitHub token with write:discussion scope (ORG_DISCUSSION_TOKEN) -# RELEASE_TAG - e.g. v3.2.3 -# RELEASE_BODY - markdown release notes -# RELEASE_URL - URL of the GitHub release page - -set -euo pipefail - -ORG="utPLSQL" -REPO_NAME=".github" - -# Get org node ID -ORG_DATA=$(gh api graphql -f query='query($org: String!) { - organization(login: $org) { - id - } -}' -f org="$ORG") -ORG_ID=$(echo "$ORG_DATA" | jq -r '.data.organization.id') - -# Get repository node ID -REPO_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { - repository(owner: $owner, name: $name) { - id - } -}' -f owner="$ORG" -f name="$REPO_NAME") -REPO_ID=$(echo "$REPO_DATA" | jq -r '.data.repository.id') - -# Get Announcements category ID -CATEGORY_DATA=$(gh api graphql -f query='query($owner: String!, $name: String!) { - repository(owner: $owner, name: $name) { - discussionCategories(first: 20) { - nodes { id name } - } - } -}' -f owner="$ORG" -f name="$REPO_NAME") -CATEGORY_ID=$(echo "$CATEGORY_DATA" | jq -r \ - '.data.repository.discussionCategories.nodes[] | select(.name == "Announcements") | .id') - -BODY="${RELEASE_BODY} - -
    This discussion was created from the release ${RELEASE_TAG}." - -DISCUSSION_URL=$(gh api graphql -f query='mutation($repoId: ID!, $categoryId: ID!, $title: String!, $body: String!) { - createDiscussion(input: { - repositoryId: $repoId, - categoryId: $categoryId, - title: $title, - body: $body - }) { - discussion { url } - } -}' \ - -f repoId="$REPO_ID" \ - -f categoryId="$CATEGORY_ID" \ - -f title="utPLSQL ${RELEASE_TAG} released" \ - -f body="$BODY" \ - --jq '.data.createDiscussion.discussion.url') - -echo "Announcement posted: $DISCUSSION_URL" diff --git a/.github/scripts/publish_release_post.sh b/.github/scripts/publish_release_post.sh deleted file mode 100755 index 0412a5877..000000000 --- a/.github/scripts/publish_release_post.sh +++ /dev/null @@ -1,63 +0,0 @@ -#!/bin/bash -# Publishes a release announcement post to utplsql.github.io. -# Creates a new post file in directory docs/announcements/posts/[year] -# -# Required environment variables: -# API_TOKEN_GITHUB - GitHub token with write access to utPLSQL.github.io -# RELEASE_TAG - e.g. v3.2.3 -# RELEASE_BODY - markdown release notes (from github.event.release.body) -# RELEASE_DATE - ISO-8601 publish timestamp (from github.event.release.published_at) - -set -euo pipefail - -GITHUB_IO_REPO="utPLSQL/utPLSQL.github.io" -GITHUB_IO_BRANCH="main" - -VERSION="${RELEASE_TAG#v}" -POST_DATE=$(echo "${RELEASE_DATE}" | cut -c1-10) -POST_FILENAME="${POST_DATE}-version${VERSION}-released.md" -POST_TITLE="utPLSQL ${RELEASE_TAG} released" -POST_NAV_TITLE="utPLSQL ${VERSION} released" -POST_PATH="docs/announcements/posts/${POST_DATE:0:4}" - -mkdir -p github_io -cd github_io -git clone --depth 1 "https://${API_TOKEN_GITHUB}@github.com/${GITHUB_IO_REPO}" -b "${GITHUB_IO_BRANCH}" . - -# Make sure that the post directory exists -mkdir -p "${POST_PATH} - -# Format the release body for the post: -# 1. Convert bare GitHub issue/PR URLs to [#NUMBER](URL) -# e.g. https://github.com/utPLSQL/utPLSQL/pull/1320 -# -> [#1320](https://github.com/utPLSQL/utPLSQL/pull/1320) -# 2. Convert the auto-generated "Full Changelog" bare URL to a labelled link -# e.g. **Full Changelog**: https://.../compare/v3.2.01...v3.2.2 -# -> **Full Changelog**: [v3.2.01...v3.2.2](https://.../compare/v3.2.01...v3.2.2) -FORMATTED_BODY=$(echo "${RELEASE_BODY}" \ - | sed -E 's@https://github\.com/([^/]+)/([^/]+)/(pull|issues)/([0-9]+)@[#\4](https://github.com/\1/\2/\3/\4)@g' \ - | sed -E 's@\*\*Full Changelog\*\*: (https://[^ ]+/compare/([^ ]+))@\*\*Full Changelog\*\*: [\2](\1)@g') - -# Create the post file -cat > "${POST_PATH}/${POST_FILENAME}" < Date: Sat, 17 Oct 2026 23:01:43 +0100 Subject: [PATCH 793/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index d1393424b..8a2e00225 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4553 +4557 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index eed5dfe3c..631bcb182 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4553-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4557-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 3aff66b614f22cc4708530b1327932c825868366 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 19 Oct 2026 12:19:23 +0300 Subject: [PATCH 794/887] Improve link, hover and muted text contrast in light and dark themes --- docs/stylesheets/extra.css | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css index 7f05ab831..b59be3a47 100644 --- a/docs/stylesheets/extra.css +++ b/docs/stylesheets/extra.css @@ -1,12 +1,22 @@ [data-md-color-scheme="default"] { - --md-primary-fg-color: #2f8bff; - --md-accent-fg-color: #1f5db0; - --md-accent-fg-color--transparent: #1f5db0; + --md-primary-fg-color: #1565c0; /* link + header colour: 5.8:1 with white text */ + --md-typeset-a-color: #1565c0; /* link = header colour: 5.8:1 */ + --md-accent-fg-color: #1e88e5; /* hover: lighter than the link, 3.7:1 */ + --md-accent-fg-color--transparent: rgba(30, 136, 229, .1); + --md-default-fg-color--light: hsla(0, 0%, 0%, .64); /* muted text 6.7:1 */ } [data-md-color-scheme="slate"] { - --md-hue: 200; - --md-primary-fg-color: #2f8bff; - --md-accent-fg-color: #1f5db0; - --md-accent-fg-color--transparent: #1f5db0; + --md-hue: 215; + --md-primary-fg-color: #1565c0; /* header background keeps the brand blue */ + --md-accent-fg-color: #3578cc; /* hover: darker than the link, 3.6:1 */ + --md-accent-fg-color--transparent: rgba(53, 120, 204, .1); + --md-default-fg-color: hsla(var(--md-hue), 15%, 90%, .90); /* body ~10:1 */ + --md-default-fg-color--light: hsla(var(--md-hue), 15%, 90%, .68); /* muted 6.5:1 */ + --md-code-hl-keyword-color: hsl(219, 80%, 72%); +} + +/* Material sets the dark link colour per primary colour with higher specificity */ +[data-md-color-scheme="slate"][data-md-color-primary] { + --md-typeset-a-color: #4a90e2; /* link: header blue lightened just enough to read on dark, 4.8:1 */ } From 196ad4bc938b2b297b6cbad3428c09d9291a51b5 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 19 Oct 2026 10:29:35 +0100 Subject: [PATCH 795/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 8a2e00225..0eda9bfac 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4557 +4558 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 631bcb182..8f1153171 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4557-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4558-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 0cf8f1e5b727011b1f0cc3d7c424e5c0e295fa6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 19 Oct 2026 13:56:57 +0300 Subject: [PATCH 796/887] update docs footer to match main page. --- docs/stylesheets/extra.css | 42 ++++++++++++++++++++++++++++++++++++++ mkdocs.yml | 5 +++-- 2 files changed, 45 insertions(+), 2 deletions(-) diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css index b59be3a47..ff7721882 100644 --- a/docs/stylesheets/extra.css +++ b/docs/stylesheets/extra.css @@ -20,3 +20,45 @@ [data-md-color-scheme="slate"][data-md-color-primary] { --md-typeset-a-color: #4a90e2; /* link: header blue lightened just enough to read on dark, 4.8:1 */ } + +/* Footer: make the sponsor and cookie links stand out from the copyright text */ +.md-copyright a.footer-sponsor { + display: inline-flex; + overflow: hidden; + margin: 0 .4rem; + font-size: .65rem; + font-weight: 600; + line-height: 1; + color: #fff; + text-decoration: none; + vertical-align: middle; + border-radius: .2rem; +} + +.footer-sponsor__label, +.footer-sponsor__name { + padding: .3rem .5rem; +} + +.footer-sponsor__label { + background: #555; +} + +.footer-sponsor__name { + background: #ea4aaa; +} + +.md-copyright a.footer-sponsor:hover { + color: #fff; + opacity: .85; +} + +.md-copyright a.footer-cookies { + color: var(--md-footer-fg-color); + text-decoration: underline; + text-underline-offset: .15em; +} + +.md-copyright a.footer-cookies:hover { + color: var(--md-accent-fg-color); +} diff --git a/mkdocs.yml b/mkdocs.yml index 2949f268f..08e75ac97 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -10,8 +10,9 @@ site_name: utPLSQL site_description: utPLSQL Ultimate Testing Framework for Oracle PL/SQL copyright: > Copyright © 2016 - 2026 utPLSQL Project. - utPLSQL is stewarded by utPLSQL Development Labs Ltd. - Change cookie settings + Stewarded by utPLSQL Development Labs Ltd. + ♡ SponsorutPLSQL + Change cookie settings repo_url: https://github.com/utPLSQL/utPLSQL extra_css: - stylesheets/extra.css From cea80a3ddb88028b493ebf4c2f341c0c4186ab87 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 19 Oct 2026 12:03:45 +0100 Subject: [PATCH 797/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 0eda9bfac..a00e5fce3 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4558 +4559 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 8f1153171..2a8bf5f3b 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4558-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4559-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From f3465ae146837029779fbca41605e112022d91f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 19 Oct 2026 14:05:54 +0300 Subject: [PATCH 798/887] update docs footer and colors to always match the main page --- .github/workflows/rebuild_docs.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/rebuild_docs.yml b/.github/workflows/rebuild_docs.yml index a9774d9b2..835ae5947 100644 --- a/.github/workflows/rebuild_docs.yml +++ b/.github/workflows/rebuild_docs.yml @@ -52,6 +52,9 @@ jobs: for VERSION in ${{ inputs.versions }}; do echo "=== Rebuilding $VERSION ===" git checkout "tags/${VERSION}" -- docs/ + # Use the current look and feel (colors, footer, top bar) for every version; + # tags released since the restyling carry their own, older copies of these files + git checkout HEAD -- docs/stylesheets docs/overrides # Keep the version badge as originally published with the release DOCS_VERSION=$(.github/scripts/get_published_docs_version.sh "${VERSION}") if [[ -n "${DOCS_VERSION}" ]]; then From 77bc309f0193907ce9284fb3cc7ad230faecdce5 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 19 Oct 2026 12:12:46 +0100 Subject: [PATCH 799/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index a00e5fce3..cbd82cad4 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4559 +4560 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 2a8bf5f3b..3d816a129 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4559-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4560-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From c97642e3e3feda8197f1de87786eea357c5f4e12 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 19 Oct 2026 22:55:32 +0300 Subject: [PATCH 800/887] Document that exclude expressions override the exclude objects list The user guide stated that all exclude parameters are always applied. In the code (ut_coverage.get_coverage_cursor: "Regex exclusion override the standard exclusion objects") and in the tests (test_extended_coverage.coverage_regex_exclude_object) a_exclude_objects is ignored when a_exclude_schema_expr or a_exclude_object_expr is given. Verified on a 19c database with utPLSQL 3.2.3 through utPLSQL-cli. Fixed the description and the two examples that claimed the object would also be excluded. --- docs/userguide/coverage.md | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index 55820e905..c7016052a 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -166,7 +166,10 @@ You may specify both _include_ and _exclude_ options to gain more control over w - else if no coverage specific parameters are provided coverage is gathered on all schemas specified in paths passed to run procedure
    - else if no paths were specified, the coverage is gathered on current schema of the session running the tests -The exclude parameters are not mutually-exclusive and can be mixed together. All of exclude parameters are always applied. +The include and exclude parameters can be combined. An object is reported when it passes the include filters and does not match any of the exclude filters. + +The `a_exclude_schema_expr` and `a_exclude_object_expr` parameters are not mutually-exclusive and can be used together. +When any of them is specified, the `a_exclude_objects` parameter is ignored. Example: Limiting coverage by schema regex. ```sql linenums="1" @@ -218,7 +221,7 @@ end; ``` Will result in showing coverage for objects in all schema except schemas that are matching regular expression `er_1$` -Example: Limiting coverage by excluding schema with regex and excluding specific object. +Example: Limiting coverage by excluding schema with regex, with parameter `a_exclude_objects` ignored. ```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), @@ -226,8 +229,8 @@ begin ); end; ``` -Will result in showing coverage for objects in all schemas except schemas that are matching regular expression `er_1$` -Will also exclude object `user_2.utils_package` from coverage report +Will result in showing coverage for objects in all schemas except schemas that are matching regular expression `er_1$`. +The `a_exclude_objects` parameter is ignored when `a_exclude_schema_expr` is specified, so object `user_2.utils_package` is not excluded from the coverage report. Example: Limiting coverage by excluding objects with regex. ```sql linenums="1" @@ -248,7 +251,7 @@ begin end; ``` Will result in showing coverage for all objects that name is not matching regular expression `utl`. -Will also exclude object `user_2.utils_package` from coverage report +The `a_exclude_objects` parameter is ignored when `a_exclude_object_expr` is specified, so object `user_2.utils_package` is not excluded from the coverage report. Example: Limiting coverage by object name, for tested code located in the same schema as the unit tests. From c5a087d72d119b3b777aa1a6628de8ab6b45d73f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 20 Oct 2026 11:17:14 +0300 Subject: [PATCH 801/887] Rewrite coverage filtering section with clearer, consistent examples --- docs/userguide/coverage.md | 197 +++++++++++++++++++++---------------- 1 file changed, 112 insertions(+), 85 deletions(-) diff --git a/docs/userguide/coverage.md b/docs/userguide/coverage.md index c7016052a..6dd9a233c 100644 --- a/docs/userguide/coverage.md +++ b/docs/userguide/coverage.md @@ -140,19 +140,49 @@ end; #### Filtering objects in coverage reports -Multiple parameters can be used to define the scope of coverage report. - -- `a_source_file_mappings ( ut_file_mappings )` - map of filenames to database objects. It is used for file-based coverage - see below. -- `a_include_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be included in the coverage report. Case-insensitive. -- `a_include_object_expr ( varchar(4000) )` - string of regex expression of objects ( without schema name ) to be included in the coverage report. Case-insensitive. -- `a_exclude_schema_expr ( varchar(4000) )` - string of regex expression of schemas to be excluded from the coverage report. Case-insensitive. -- `a_exclude_object_expr ( varchar(4000) )` - string of regex expression of objects ( without schema name ) to be excluded from the coverage report. Case-insensitive. -- `a_coverage_schemes ( ut_varchar2_list )` - List of database schema names to gather coverage on. -- `a_include_objects ( ut_varchar2_list )` - list of `[object_owner.]object_name` to be included in the coverage report. -- `a_exclude_objects ( ut_varchar2_list )` - list of `[object_owner.]object_name` to be excluded from the coverage report. +By default, coverage is reported on all objects of the schema(s) described above. Several parameters narrow the scope of the coverage report. +You can describe the scope with lists of names, or with regular expressions that match names. + +| Parameter | Type | Meaning | +|-------------------------|----------------------|------------------------------------------------------------------------------------------------------| +| `a_coverage_schemes` | `ut_varchar2_list` | schemas to gather coverage on | +| `a_include_objects` | `ut_varchar2_list` | `[object_owner.]object_name` to be included in the coverage report | +| `a_exclude_objects` | `ut_varchar2_list` | `[object_owner.]object_name` to be excluded from the coverage report | +| `a_include_schema_expr` | `varchar2(4000)` | regular expression, schemas whose name matches are included in the coverage report | +| `a_include_object_expr` | `varchar2(4000)` | regular expression, objects whose name (without schema name) matches are included in the report | +| `a_exclude_schema_expr` | `varchar2(4000)` | regular expression, schemas whose name matches are excluded from the coverage report | +| `a_exclude_object_expr` | `varchar2(4000)` | regular expression, objects whose name (without schema name) matches are excluded from the report | +| `a_source_file_mappings`| `ut_file_mappings` | map of filenames to database objects, used for file-based coverage - see [Project based Coverage](#project-based-coverage) | + +Use lists when the scope is a handful of known objects. Use regular expressions when the scope follows a naming convention, +for example all schemas that start with `APP_`, or all objects that end with `_TMP`. +A rule written once as a regular expression also covers the objects and schemas that are created later. You may specify both _include_ and _exclude_ options to gain more control over what needs to be included / excluded from the coverage report. +An object is reported when it passes the include filters and does not match any of the exclude filters. + +##### Regular expressions + +- The expression is evaluated by Oracle `REGEXP_LIKE`. It is **case-insensitive**, so `app_` matches `APP_ORDERS`. +- A schema expression is matched against the schema name. An object expression is matched against the object name **without** the schema name. +- The expression is **not anchored**. `util` matches `UT_UTILS`, `UTIL_TRAINING` and `ERROR_UTIL_2`. + Use `^` to match from the beginning of the name and `$` to match up to the end, for example `^app_` or `_tmp$`. +- When both an include schema expression and an include object expression are specified, an object must match both. + +##### Which parameters are used when several are given + +| If you specify | utPLSQL ignores | +|-----------------------------------------------------------------|-----------------------------------------------------------| +| `a_source_file_mappings` | all other include/exclude parameters | +| `a_include_schema_expr` or `a_include_object_expr` | `a_include_objects` (and associated `a_coverage_schemes`) | +| `a_exclude_schema_expr` or `a_exclude_object_expr` | `a_exclude_objects` (and associated `a_coverage_schemes`) | +Everything else can be combined. In particular: + +- include expressions can be combined with exclude expressions and with `a_exclude_objects`, +- `a_exclude_schema_expr` and `a_exclude_object_expr` can be used together, +- without include parameters, coverage is gathered on the schemas described in [Setting coverage schema(s)](#setting-coverage-schemas) + and the exclude parameters remove objects from that scope. !!! warning "Important note" @@ -160,155 +190,152 @@ You may specify both _include_ and _exclude_ options to gain more control over w - if `a_source_file_mappings` is defined then all include/exclude parameters are ignored (see section below for usage of `a_source_file_mappings` parameter )
    - else if `a_include_schema_expr` or `a_include_object_expr` parameter is specified then parameters `a_coverage_schemes` and `a_include_objects` are ignored
    - else if `a_include_objects` is specified then the coverage is gathered only on specified database objects.
    - - if `a_coverage_schemes` is specified then those schemas are used for objects in `a_include_objects` without schema name
    - - if `a_coverage_schemes` is not specified then schema from paths (`a_paths`) parameter are used for objects in `a_include_objects` without schema name
    + - if `a_coverage_schemes` is specified then those schemas are used for objects without schema name in `a_include_objects` and `a_exclude_objects`
    + - if `a_coverage_schemes` is not specified then schema from paths (`a_paths`) parameter are used for objects without schema name in `a_include_objects` and `a_exclude_objects`
    - else if, only the `a_coverage_schemes` is specified then the coverage is gathered only on specified database schemas
    - else if no coverage specific parameters are provided coverage is gathered on all schemas specified in paths passed to run procedure
    - else if no paths were specified, the coverage is gathered on current schema of the session running the tests -The include and exclude parameters can be combined. An object is reported when it passes the include filters and does not match any of the exclude filters. +##### Examples + +The examples use a system split into schemas `app_orders` and `app_billing` that contain the application code, +and schemas `app_orders_test` and `app_billing_test` that contain the unit tests. -The `a_exclude_schema_expr` and `a_exclude_object_expr` parameters are not mutually-exclusive and can be used together. -When any of them is specified, the `a_exclude_objects` parameter is ignored. +###### Filtering by lists of names -Example: Limiting coverage by schema regex. +Example: Limiting coverage by object name, for tested code located in the same schema as the unit tests. ```sql linenums="1" begin ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_include_schema_expr => '^ut3_develop' + a_include_objects=>ut_varchar2_list('award_bonus') ); end; ``` -Will result in showing coverage for all schemas that match regular expression `^ut3_develop` +Executes all tests in schemas: `user_1` and `user_2`. Coverage will only be reported on objects `user_1.award_bonus`, `user_2.award_bonus` -Example: Limiting coverage by schema regex with parameter `a_include_objects` ignored. -```sql linenums="1" -begin - ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_include_schema_expr => '^ut3_develop', a_include_objects => ut_varchar2_list( 'ut3_tester_helper.regex_dummy_cov' ) - ); -end; -``` -Will result in showing coverage for all schemas that match regular expression `^ut3_develop`. -Example: Limiting coverage by object regex. +Example: Limiting coverage by object name, for tested code located in different schemas than the unit tests. ```sql linenums="1" begin - ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_include_object_expr => 'regex123' + ut.run( + 'unit_test_schema', ut_coverage_html_reporter(), + a_coverage_schemes => ut_varchar2_list('user_1','user_2'), + a_include_objects => ut_varchar2_list('award_bonus', 'betwnstr') ); end; ``` -Will result in showing coverage for all objects that name match regular expression `regex123`. +Executes all tests in schema `unit_test_schema`. Coverage will only be reported on objects `user_1.award_bonus`, `user_2.award_bonus`, `user_1.betwnstr`, `user_2.betwnstr`. +Objects that do not exist in the database but were specified in `a_include_objects` will be ignored. -Example: Limiting coverage by object regex with parameter `a_include_objects` ignored. +Example: Limiting coverage by object owner and name. ```sql linenums="1" begin - ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_include_object_expr => 'utl', a_include_objects => ut_varchar2_list( 'user_2.utils_package' ) + ut.run( + 'unit_test_schema', ut_coverage_html_reporter(), + a_include_objects => ut_varchar2_list('user_1.award_bonus','user_2.betwnstr') ); end; ``` -Will result in showing coverage for all objects that name match regular expression `utl`. +Executes all tests in schema `unit_test_schema`. Coverage will only be reported on objects `user_1.award_bonus`, `user_2.betwnstr` -Example: Limiting coverage by excluding schema with regex. -```sql linenums="1" -begin - ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_exclude_schema_expr => 'er_1$' - ); -end; -``` -Will result in showing coverage for objects in all schema except schemas that are matching regular expression `er_1$` +The `a_exclude_objects` can be used in the same way as `a_include_objects`. -Example: Limiting coverage by excluding schema with regex, with parameter `a_exclude_objects` ignored. +Example: Excluding objects from coverage report by providing a list of object owner/name to be excluded. ```sql linenums="1" begin - ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_exclude_schema_expr => 'er_1$', a_exclude_objects => ut_varchar2_list( 'user_2.utils_package' ) + ut.run( + 'unit_test_schema.test_award_bonus', ut_coverage_html_reporter(), + a_exclude_objects => ut_varchar2_list('ut3_user.betwnstr') ); end; ``` -Will result in showing coverage for objects in all schemas except schemas that are matching regular expression `er_1$`. -The `a_exclude_objects` parameter is ignored when `a_exclude_schema_expr` is specified, so object `user_2.utils_package` is not excluded from the coverage report. +Executes test `test_award_bonus` in schema `unit_test_schema`. Coverage will be reported on all objects in schema `ut3_user` except the `betwnstr` object. -Example: Limiting coverage by excluding objects with regex. -```sql linenums="1" -begin - ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_exclude_object_expr => 'utl' - ); -end; -``` -Will result in showing coverage for all objects that name is not matching regular expression `utl`. +###### Filtering by regular expressions -Example: Limiting coverage by excluding objects with regex with parameter `a_exclude_objects` ignored. +Example: Tests are located in other schemas than the application code. Report coverage on the application schemas, selected by a pattern. ```sql linenums="1" begin - ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_exclude_object_expr => 'utl', a_exclude_objects => ut_varchar2_list( 'user_2.utils_package' ) + ut.run( + ut_varchar2_list('app_orders_test','app_billing_test'), ut_coverage_html_reporter(), + a_include_schema_expr => '^app_(orders|billing)$' ); end; ``` -Will result in showing coverage for all objects that name is not matching regular expression `utl`. -The `a_exclude_objects` parameter is ignored when `a_exclude_object_expr` is specified, so object `user_2.utils_package` is not excluded from the coverage report. - +Executes all tests in schemas `app_orders_test` and `app_billing_test`. +Coverage will be reported on all objects in the schemas `app_orders` and `app_billing`, even though those schemas are not mentioned in the paths. +Any other schema whose name matches the expression is reported as well. -Example: Limiting coverage by object name, for tested code located in the same schema as the unit tests. +Example: Include all application schemas and exclude the test schemas, using one include and one exclude expression. ```sql linenums="1" begin - ut.run(ut_varchar2_list('user_1','user_2'), ut_coverage_html_reporter(), - a_include_objects=>ut_varchar2_list('award_bonus') + ut.run( + ut_varchar2_list('app_orders_test','app_billing_test'), ut_coverage_html_reporter(), + a_include_schema_expr => '^app_', + a_exclude_schema_expr => '_test$' ); end; ``` -Executes all tests in schemas: `user_1` and `user_2`. Coverage will only be reported on objects `user_1.award_bonus`, `user_2.award_bonus` - +Coverage will be reported on all schemas whose name starts with `app_` except the ones whose name ends with `_test`. +When a new schema `app_shipping` is created, it is included without any change to the call. -Example: Limiting coverage by object name, for tested code located in different schemas than the unit tests. +Example: Report coverage on one functional area of a schema, identified by a naming convention. ```sql linenums="1" begin ut.run( - 'unit_test_schema', ut_coverage_html_reporter(), - a_coverage_schemes => ut_varchar2_list('user_1','user_2'), - a_include_objects => ut_varchar2_list('award_bonus', 'betwnstr') + 'app_orders_test', ut_coverage_html_reporter(), + a_include_schema_expr => '^app_orders$', + a_include_object_expr => '^(ord|invoice)_' ); end; ``` -Executes all tests in schema `unit_test_schema`. Coverage will only be reported on objects `user_1.award_bonus`, `user_2.award_bonus`, `user_1.betwnstr`, `user_2.betwnstr`. -Objects that do not exist in the database but were specified in `a_include_objects` will be ignored. +Coverage will be reported only on objects in schema `app_orders` whose name starts with `ord_` or `invoice_`. -Example: Limiting coverage by object owner and name. +Example: Keep generated and temporary objects out of the coverage report. ```sql linenums="1" begin ut.run( - 'unit_test_schema', ut_coverage_html_reporter(), - a_include_objects => ut_varchar2_list('user_1.award_bonus','user_2.betwnstr') + 'app_orders_test', ut_coverage_html_reporter(), + a_coverage_schemes => ut_varchar2_list('app_orders'), + a_exclude_object_expr => '(_tmp|_gen)$' ); end; ``` -Executes all tests in schema `unit_test_schema`. Coverage will only be reported on objects `user_1.award_bonus`, `user_2.betwnstr` +There is no include expression, so coverage is gathered on the schema `app_orders` given in `a_coverage_schemes`. +Objects whose name ends with `_tmp` or `_gen` are left out. -The `a_exclude_objects` can be used in the same way as `a_include_objects`. - -Example: Excluding objects from coverage report by providing a list of object owner/name to be excluded. +Example: Use an expression for the bulk of the scope and a list for the exceptions. ```sql linenums="1" begin ut.run( - 'unit_test_schema.test_award_bonus', ut_coverage_html_reporter(), - a_exclude_objects => ut_varchar2_list('ut3_user.betwnstr') + 'app_orders_test', ut_coverage_html_reporter(), + a_include_schema_expr => '^app_orders$', + a_exclude_objects => ut_varchar2_list('app_orders.ord_legacy') ); end; ``` -Executes test `test_award_bonus` in schema `unit_test_schema`. Coverage will be reported on all objects in schema `ut3_user` except the `betwnstr` object. +Coverage will be reported on all objects in schema `app_orders` except for `ord_legacy`. +The list can be used with an include expression. It would be ignored if an exclude expression was given too. + +!!! note + An include object expression used **without** an include schema expression is not limited to the schemas of your tests. + It is applied to the objects of all schemas visible to the user running the tests, for example `a_include_object_expr => '^ord_'` + also reports objects named `ord_...` in other schemas. Add `a_include_schema_expr` to keep the scope where you want it. !!! note Filtering using `a_include_objects` and `a_exclude_objects` is only applicable when gathering coverage for a schema. Those filters are not applied when reporting coverage on project files. + The same is true for the expression parameters. !!! note When running coverage on schema objects, all source code of package bodies, functions, procedures, type bodies and triggers that were not executed will be reported as having 0% code coverage and all source code lines will show as uncovered. This is different from the behavior when gathering coverage on project files. +##### Using the filters from utPLSQL-cli and the Maven plugin + +The filter options described above are available in [utPLSQL-cli](https://www.utplsql.org/utPLSQL-cli.html) +and in the [utPLSQL-maven-plugin](https://www.utplsql.org/utPLSQL-maven-plugin.html), and the same rules apply +(which options are ignored when several are given, how expressions are matched, and that the filters are not applied when coverage is gathered on project files). +See the documentation of those tools for the list of supported options and their names. ### Project based Coverage From 028ea26ae95b49863f4ed552a1704f053b8d8236 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 20 Oct 2026 11:47:24 +0100 Subject: [PATCH 802/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index cbd82cad4..5986073ac 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4560 +4564 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 3d816a129..50386faaf 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4560-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4564-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 77e12a4d00aa50c3d3640a4fef89157de48619ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 1 Nov 2026 23:06:55 +0200 Subject: [PATCH 803/887] Fixes to CONTRIBUTING.md --- CONTRIBUTING.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 964559260..465b1e4ad 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -43,7 +43,7 @@ Not able to contribute code? You can also support the project through [sponsorsh Your local environment can be of any flavor (Unix/Linux/Windows/Mac). At minimum, you need to have Oracle database 19c accessible for the project and SYS account access to install and develop utPLSQL. -We use four different database accounts (users) for development process. +We use five different database accounts (users) for development process. * `ut3` - holds latest released version of utPLSQL. This schema holds the testing framework used for self-testing of utPLSQL development. * `ut3_develop` - holds the version of utPLSQL of your current branch. This is the schema you will be working on. * `ut3_tester` - holds unit test packages for development of utPLSQL. @@ -107,12 +107,12 @@ The below script is fetching latest release version from utPLSQL repository. Lat ### That's it You now have the following: -- sources from `develop` branch of your fork of utPLSQL repository in `utPLSQL/ut3_latest_release` directory -- sources from `main` branch of utPLSQL/utPLSQL repository in `utPLSQL/ut3_latest_release` directory +- sources from your fork of utPLSQL repository in `utPLSQL` directory +- sources from utPLSQL/utPLSQL repository (branch set by `SELFTESTING_BRANCH` in `development/env.sh`) in `utPLSQL/utPLSQL_latest_release` directory - binaries of `utplsql-cli` in `utPLSQL/utPLSQL-cli` directory - database users created -- your current branch of utPLSQL deployed into `ut3` schema -- utPLSQL released version deployed to `ut3_latest_release` +- your current branch of utPLSQL deployed into `ut3_develop` schema +- utPLSQL released version deployed into `ut3` schema At any time, if you need to refresh your database, the below scripts might be helpful. @@ -122,7 +122,7 @@ At any time, if you need to refresh your database, the below scripts might be he development/cleanup.sh ``` -## Reinstalling utPLSQL development in `ut3` schema +## Reinstalling utPLSQL development in `ut3_develop` schema ```bash development/refresh_ut3.sh From 6990e3c09b5b4a159ce3b22faeb9c27892d1b526 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 1 Nov 2026 23:25:29 +0200 Subject: [PATCH 804/887] Added info about local docker-container DB for development --- CONTRIBUTING.md | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 465b1e4ad..5b3ca6a35 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -50,7 +50,33 @@ We use five different database accounts (users) for development process. * `ut3_user` - used for testing accessibility to schema names with special characters. * `ut3_tester_helper` - elevated privileges user, used for creating and dropping objects in other schemas during test run. +## Local database in a disposable Docker container +We use, and recommend, a disposable Docker container with Oracle Database Free, built from [gvenzl/oci-oracle-free](https://github.com/gvenzl/oci-oracle-free/tree/main), using image `gvenzl/oracle-free:slim-faststart`. +The container needs no setup and can be thrown away and recreated whenever you need a clean database. +`ORACLE_PASSWORD` sets the SYS password. Use the same value for `ORACLE_PWD` in `development/env.sh`, and connect to `127.0.0.1:1521/FREEPDB1`. + +Run the container in background: +```bash +docker run -d --name utplsql-db -p 1521:1521 -e ORACLE_PASSWORD=oracle gvenzl/oracle-free:slim-faststart +``` + +Stop the container: +```bash +docker stop utplsql-db +``` + +Restart the container (database content is kept): +```bash +docker restart utplsql-db +``` + +Recreate the container (database content is lost): +```bash +docker rm -f utplsql-db && docker run -d --name utplsql-db -p 1521:1521 -e ORACLE_PASSWORD=oracle gvenzl/oracle-free:slim-faststart +``` + +The database is ready to use once `docker logs utplsql-db` shows `DATABASE IS READY TO USE!`. ## Get started with development @@ -87,7 +113,7 @@ You might have to adjust the following lines in `development/env.sh`: ```bash export SQLCLI=sql # For sqlcl client #export SQLCLI=sqlplus # For sqlplus client -export CONNECTION_STR=127.0.0.1:1521/xe # Adjust the connect string +export CONNECTION_STR=127.0.0.1:1521/FREEPDB1 # Adjust the connect string export ORACLE_PWD=oracle # Adjust your local SYS password ``` From aeb536b487e23636262f2a812f047338665fefdd Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 1 Nov 2026 21:32:28 +0000 Subject: [PATCH 805/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 5986073ac..0276a7e4b 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4564 +4567 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 50386faaf..8a146b6a6 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4564-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4567-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From db4baf4a1dfda74e6a578b3abe92373e7c1c9f0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 1 Nov 2026 23:54:46 +0200 Subject: [PATCH 806/887] Fixed the `refresh_ut3.sh` script to work correctly. --- .github/scripts/create_test_grants.sh | 40 +++++++++++++++++++++++++++ .github/scripts/create_test_users.sh | 31 ++------------------- development/refresh_ut3.sh | 12 +++++++- 3 files changed, 53 insertions(+), 30 deletions(-) create mode 100755 .github/scripts/create_test_grants.sh diff --git a/.github/scripts/create_test_grants.sh b/.github/scripts/create_test_grants.sh new file mode 100755 index 000000000..d92c02d99 --- /dev/null +++ b/.github/scripts/create_test_grants.sh @@ -0,0 +1,40 @@ +#!/bin/bash + +set -ev + +# Grants on $UT3_DEVELOP_SCHEMA needed for testing. Must be re-applied whenever $UT3_DEVELOP_SCHEMA is reinstalled. +time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL +set feedback off +whenever sqlerror exit failure rollback + +-------------------------------------------------------------------------------- +PROMPT Adding back create-trigger privilege to $UT3_DEVELOP_SCHEMA for testing +grant administer database trigger to $UT3_DEVELOP_SCHEMA; + +-------------------------------------------------------------------------------- +PROMPT Granting $UT3_DEVELOP_SCHEMA code to UT3_TESTER + +begin + for i in ( + select object_name from all_objects t + where t.object_type in ('PACKAGE','TYPE') + and owner = '$UT3_DEVELOP_SCHEMA' + and generated = 'N' + and object_name not like 'SYS%') + loop + execute immediate 'grant execute on $UT3_DEVELOP_SCHEMA."'||i.object_name||'" to UT3_TESTER'; + end loop; +end; +/ + +PROMPT Granting $UT3_DEVELOP_SCHEMA tables to UT3_TESTER + +begin + for i in ( select table_name from all_tables t where owner = '$UT3_DEVELOP_SCHEMA' and nested = 'NO' and iot_name is null) + loop + execute immediate 'grant select on $UT3_DEVELOP_SCHEMA.'||i.table_name||' to UT3_TESTER'; + end loop; +end; +/ +exit +SQL diff --git a/.github/scripts/create_test_users.sh b/.github/scripts/create_test_users.sh index 6c3030206..9708f4f7f 100755 --- a/.github/scripts/create_test_users.sh +++ b/.github/scripts/create_test_users.sh @@ -8,10 +8,6 @@ time "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <<-SQL set feedback off whenever sqlerror exit failure rollback --------------------------------------------------------------------------------- -PROMPT Adding back create-trigger privilege to $UT3_DEVELOP_SCHEMA for testing -grant administer database trigger to $UT3_DEVELOP_SCHEMA; - -------------------------------------------------------------------------------- PROMPT Creating UT3_TESTER - Power-user for testing internal framework code @@ -23,31 +19,6 @@ alter user UT3_TESTER enable editions; grant execute on dbms_lock to UT3_TESTER; -PROMPT Granting $UT3_DEVELOP_SCHEMA code to UT3_TESTER - -begin - for i in ( - select object_name from all_objects t - where t.object_type in ('PACKAGE','TYPE') - and owner = '$UT3_DEVELOP_SCHEMA' - and generated = 'N' - and object_name not like 'SYS%') - loop - execute immediate 'grant execute on $UT3_DEVELOP_SCHEMA."'||i.object_name||'" to UT3_TESTER'; - end loop; -end; -/ - -PROMPT Granting $UT3_DEVELOP_SCHEMA tables to UT3_TESTER - -begin - for i in ( select table_name from all_tables t where owner = '$UT3_DEVELOP_SCHEMA' and nested = 'NO' and iot_name is null) - loop - execute immediate 'grant select on $UT3_DEVELOP_SCHEMA.'||i.table_name||' to UT3_TESTER'; - end loop; -end; -/ - -------------------------------------------------------------------------------- PROMPT Creating UT3_USER - minimal privileges user for API testing @@ -119,3 +90,5 @@ create user ut3_execute_any_proc_user identified by ut3; grant create session, create procedure, execute any procedure to ut3_execute_any_proc_user; exit SQL + +"${SCRIPT_DIR}/create_test_grants.sh" diff --git a/development/refresh_ut3.sh b/development/refresh_ut3.sh index 827af827d..7685549ad 100755 --- a/development/refresh_ut3.sh +++ b/development/refresh_ut3.sh @@ -1,4 +1,5 @@ #!/bin/bash +set -e #goto git root directory git rev-parse && cd "$(git rev-parse --show-cdup)" @@ -7,8 +8,17 @@ git rev-parse && cd "$(git rev-parse --show-cdup)" cd source +"${SQLCLI}" sys/${ORACLE_PWD}@//${CONNECTION_STR} AS SYSDBA @uninstall ${UT3_DEVELOP_SCHEMA} + +# Same install steps as .github/scripts/install.sh, without recreating the user or public synonyms "${SQLCLI}" sys/${ORACLE_PWD}@//${CONNECTION_STR} AS SYSDBA <<-SQL -@uninstall ${UT3_DEVELOP_SCHEMA} +whenever sqlerror exit failure rollback +alter session set plsql_optimize_level=0; @install ${UT3_DEVELOP_SCHEMA} +@create_grants ${UT3_DEVELOP_SCHEMA} PUBLIC +@install_ddl_trigger ${UT3_DEVELOP_SCHEMA} exit SQL + +# Reinstall dropped the grants on ${UT3_DEVELOP_SCHEMA} objects +../.github/scripts/create_test_grants.sh From 24fd22d94fd464089a371c672ad1b18bddba3a4e Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 1 Nov 2026 22:01:49 +0000 Subject: [PATCH 807/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 0276a7e4b..23b21f1d1 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4567 +4568 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 8a146b6a6..805319fff 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4567-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4568-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 3ec48c0bbfbe4e514f077bd9cc9d0a1bc535365a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 2 Nov 2026 00:44:29 +0200 Subject: [PATCH 808/887] Remove compatibility for Oracle DB prior to 19c utPLSQL now supports only Oracle 19c and newer. This removes the conditional compilation and install logic that existed only for 11g, 12.1, 12.2 and 18c. --- .github/scripts/create_test_users.sh | 21 +++--- .github/scripts/install_utplsql_release.sh | 1 - .gitignore | 1 - source/check_object_grants.sql | 6 +- .../annotations/ut_annotation_manager.pkb | 11 +-- source/core/coverage/ut_coverage.pkb | 67 +++++++++---------- source/core/coverage/ut_coverage_block.pkb | 2 - .../coverage/ut_coverage_helper_block.pkb | 38 ++++------- source/core/ut_expectation_processor.pkb | 3 +- source/dummy.sql | 1 - .../data_values/ut_cursor_details.tpb | 4 -- .../data_values/ut_data_value_refcursor.tpb | 8 +-- source/expectations/json_objects_specs.sql | 63 ----------------- source/install_above_12_1.sql | 44 ------------ source/uninstall_objects.sql | 8 +-- source/uninstall_synonyms.sql | 2 +- test/install_above_12_1.sql | 28 -------- test/install_below_12_2.sql | 28 -------- test/install_ut3_user_tests.sql | 8 +-- test/ut3_tester/core/test_ut_utils.pkb | 2 +- test/ut3_tester/core/test_ut_utils.pks | 1 - test/ut3_tester_helper/coverage_helper.pkb | 15 +---- test/ut3_tester_helper/coverage_helper.pks | 2 - .../expectations/test_expectation_anydata.pkb | 2 - .../expectations/test_expectation_anydata.pks | 2 - .../expectations/test_expectations_cursor.pkb | 21 ++---- .../test_cov_cobertura_reporter.pkb | 6 +- .../test_coverage_sonar_reporter.pkb | 6 +- .../test_coverage_standalone.pkb | 6 +- .../test_coverage/test_extended_coverage.pkb | 11 +-- .../test_html_coverage_reporter.pkb | 4 +- 31 files changed, 79 insertions(+), 343 deletions(-) delete mode 100644 source/dummy.sql delete mode 100644 source/install_above_12_1.sql delete mode 100644 test/install_above_12_1.sql delete mode 100644 test/install_below_12_2.sql diff --git a/.github/scripts/create_test_users.sh b/.github/scripts/create_test_users.sh index 9708f4f7f..41051e33d 100755 --- a/.github/scripts/create_test_users.sh +++ b/.github/scripts/create_test_users.sh @@ -33,19 +33,14 @@ PROMPT Grants for starting a debugging session from UT3_USER grant debug connect session to UT3_USER; grant debug any procedure to UT3_USER; begin - \$if dbms_db_version.version <= 11 \$then - null; -- no addition action necessary - \$else - -- necessary on 12c or higher - dbms_network_acl_admin.append_host_ace ( - host =>'*', - ace => sys.xs\$ace_type( - privilege_list => sys.xs\$name_list('JDWP') , - principal_name => 'UT3_USER', - principal_type => sys.xs_acl.ptype_db - ) - ); - \$end + dbms_network_acl_admin.append_host_ace ( + host =>'*', + ace => sys.xs\$ace_type( + privilege_list => sys.xs\$name_list('JDWP') , + principal_name => 'UT3_USER', + principal_type => sys.xs_acl.ptype_db + ) + ); end; / diff --git a/.github/scripts/install_utplsql_release.sh b/.github/scripts/install_utplsql_release.sh index e50718c7b..b9e23d214 100755 --- a/.github/scripts/install_utplsql_release.sh +++ b/.github/scripts/install_utplsql_release.sh @@ -43,7 +43,6 @@ fi "$SQLCLI" sys/$ORACLE_PWD@//$CONNECTION_STR AS SYSDBA <= 18 $then - c_expected_grants constant dbmsoutput_linesarray := dbmsoutput_linesarray('DBMS_CRYPTO'); - $else - c_expected_grants constant dbmsoutput_linesarray := dbmsoutput_linesarray('DBMS_LOCK','DBMS_CRYPTO'); - $end + c_expected_grants constant dbmsoutput_linesarray := dbmsoutput_linesarray('DBMS_CRYPTO'); l_missing_grants varchar2(4000); l_target_table varchar2(128); l_owner_column varchar2(128); diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 4e1729beb..c10b99708 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -277,15 +277,8 @@ create or replace noneditionable package body ut_annotation_manager as begin if ora_dict_obj_type in ('PACKAGE','PROCEDURE','FUNCTION','TYPE') then - $if dbms_db_version.version < 12 $then - l_restricted_users := ora_name_list_t( - 'ANONYMOUS','APPQOSSYS','AUDSYS','DBSFWUSER','DBSNMP','DIP','GGSYS','GSMADMIN_INTERNAL', - 'GSMCATUSER','GSMUSER','ORACLE_OCM','OUTLN','REMOTE_SCHEDULER_AGENT','SYS','SYS$UMF', - 'SYSBACKUP','SYSDG','SYSKM','SYSRAC','SYSTEM','WMSYS','XDB','XS$NULL'); - $else - select /*+ no_parallel */ username bulk collect into l_restricted_users - from all_users where oracle_maintained = 'Y'; - $end + select /*+ no_parallel */ username bulk collect into l_restricted_users + from all_users where oracle_maintained = 'Y'; if ora_dict_obj_owner member of l_restricted_users then return; end if; diff --git a/source/core/coverage/ut_coverage.pkb b/source/core/coverage/ut_coverage.pkb index 9f5649ac1..257d809ed 100644 --- a/source/core/coverage/ut_coverage.pkb +++ b/source/core/coverage/ut_coverage.pkb @@ -277,41 +277,38 @@ create or replace noneditionable package body ut_coverage is l_result_profiler_enrich := ut_coverage_profiler.get_coverage_data( l_coverage_options ); ut_event_manager.trigger_event('profiler coverage data retrieved'); - -- If block coverage available we will use it. - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - l_result_block := ut_coverage_block.get_coverage_data( l_coverage_options ); - ut_event_manager.trigger_event('block coverage data retrieved'); - - -- Enrich profiler results with some of the block results - l_object := l_result_profiler_enrich.objects.first; - while (l_object is not null) loop - - l_line_no := l_result_profiler_enrich.objects(l_object).lines.first; - - -- to avoid no data found check if we got object in profiler - if l_result_block.objects.exists(l_object) then - while (l_line_no is not null) loop - -- To avoid no data check for object line - if l_result_block.objects(l_object).lines.exists(l_line_no) then - -- enrich line level stats - l_result_profiler_enrich.objects(l_object).lines(l_line_no).partcove := l_result_block.objects(l_object).lines(l_line_no).partcove; - l_result_profiler_enrich.objects(l_object).lines(l_line_no).covered_blocks := l_result_block.objects(l_object).lines(l_line_no).covered_blocks; - l_result_profiler_enrich.objects(l_object).lines(l_line_no).no_blocks := l_result_block.objects(l_object).lines(l_line_no).no_blocks; - -- enrich object level stats - l_result_profiler_enrich.objects(l_object).partcovered_lines := nvl(l_result_profiler_enrich.objects(l_object).partcovered_lines,0) + l_result_block.objects(l_object).lines(l_line_no).partcove; - end if; - --At the end go to next line - l_line_no := l_result_profiler_enrich.objects(l_object).lines.next(l_line_no); - end loop; - --total level stats enrich - l_result_profiler_enrich.partcovered_lines := nvl(l_result_profiler_enrich.partcovered_lines,0) + l_result_profiler_enrich.objects(l_object).partcovered_lines; - -- At the end go to next object - end if; - - l_object := l_result_profiler_enrich.objects.next(l_object); - end loop; - ut_event_manager.trigger_event('coverage data combined'); - $end + l_result_block := ut_coverage_block.get_coverage_data( l_coverage_options ); + ut_event_manager.trigger_event('block coverage data retrieved'); + + -- Enrich profiler results with some of the block results + l_object := l_result_profiler_enrich.objects.first; + while (l_object is not null) loop + + l_line_no := l_result_profiler_enrich.objects(l_object).lines.first; + + -- to avoid no data found check if we got object in profiler + if l_result_block.objects.exists(l_object) then + while (l_line_no is not null) loop + -- To avoid no data check for object line + if l_result_block.objects(l_object).lines.exists(l_line_no) then + -- enrich line level stats + l_result_profiler_enrich.objects(l_object).lines(l_line_no).partcove := l_result_block.objects(l_object).lines(l_line_no).partcove; + l_result_profiler_enrich.objects(l_object).lines(l_line_no).covered_blocks := l_result_block.objects(l_object).lines(l_line_no).covered_blocks; + l_result_profiler_enrich.objects(l_object).lines(l_line_no).no_blocks := l_result_block.objects(l_object).lines(l_line_no).no_blocks; + -- enrich object level stats + l_result_profiler_enrich.objects(l_object).partcovered_lines := nvl(l_result_profiler_enrich.objects(l_object).partcovered_lines,0) + l_result_block.objects(l_object).lines(l_line_no).partcove; + end if; + --At the end go to next line + l_line_no := l_result_profiler_enrich.objects(l_object).lines.next(l_line_no); + end loop; + --total level stats enrich + l_result_profiler_enrich.partcovered_lines := nvl(l_result_profiler_enrich.partcovered_lines,0) + l_result_profiler_enrich.objects(l_object).partcovered_lines; + -- At the end go to next object + end if; + + l_object := l_result_profiler_enrich.objects.next(l_object); + end loop; + ut_event_manager.trigger_event('coverage data combined'); return l_result_profiler_enrich; end get_coverage_data; diff --git a/source/core/coverage/ut_coverage_block.pkb b/source/core/coverage/ut_coverage_block.pkb index 9ca4caff4..d6f52d9db 100644 --- a/source/core/coverage/ut_coverage_block.pkb +++ b/source/core/coverage/ut_coverage_block.pkb @@ -32,7 +32,6 @@ create or replace noneditionable package body ut_coverage_block is l_source_object ut_coverage_helper.t_tmp_table_object; begin - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then l_source_objects_crsr := ut_coverage_helper.get_tmp_table_objects_cursor(); loop fetch l_source_objects_crsr @@ -151,7 +150,6 @@ create or replace noneditionable package body ut_coverage_block is end loop; close l_source_objects_crsr; - $end return l_result; end get_coverage_data; diff --git a/source/core/coverage/ut_coverage_helper_block.pkb b/source/core/coverage/ut_coverage_helper_block.pkb index ec4b9d04b..6aa9f6912 100644 --- a/source/core/coverage/ut_coverage_helper_block.pkb +++ b/source/core/coverage/ut_coverage_helper_block.pkb @@ -25,20 +25,12 @@ create or replace noneditionable package body ut_coverage_helper_block is function coverage_start(a_run_comment varchar2) return integer is begin - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - return dbms_plsql_code_coverage.start_coverage(run_comment => a_run_comment); - $else - return null; - $end + return dbms_plsql_code_coverage.start_coverage(run_comment => a_run_comment); end; procedure coverage_stop is begin - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - dbms_plsql_code_coverage.stop_coverage(); - $else - null; - $end + dbms_plsql_code_coverage.stop_coverage(); exception when others then if sqlcode = -08402 then @@ -89,21 +81,19 @@ create or replace noneditionable package body ut_coverage_helper_block is l_results ut_coverage_helper.t_unit_line_calls; begin - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - l_tmp_data := block_results(a_object, a_coverage_run_id); + l_tmp_data := block_results(a_object, a_coverage_run_id); - for i in 1 .. l_tmp_data.count loop - l_results(l_tmp_data(i).line).blocks := l_tmp_data(i).blocks; - l_results(l_tmp_data(i).line).covered_blocks := l_tmp_data(i).covered_blocks; - l_results(l_tmp_data(i).line).partcovered := - case - when (l_tmp_data(i).covered_blocks > 0) - and (l_tmp_data(i).blocks > l_tmp_data(i).covered_blocks) - then 1 - else 0 - end; - end loop; - $end + for i in 1 .. l_tmp_data.count loop + l_results(l_tmp_data(i).line).blocks := l_tmp_data(i).blocks; + l_results(l_tmp_data(i).line).covered_blocks := l_tmp_data(i).covered_blocks; + l_results(l_tmp_data(i).line).partcovered := + case + when (l_tmp_data(i).covered_blocks > 0) + and (l_tmp_data(i).blocks > l_tmp_data(i).covered_blocks) + then 1 + else 0 + end; + end loop; return l_results; end; end; diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index ab8a5f3f5..8876cbb30 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -155,8 +155,7 @@ create or replace noneditionable package body ut_expectation_processor as l_owner varchar2(1000); l_object_name varchar2(1000); l_result varchar2(4000); - -- in 12.2 format_call_stack reportes not only package name, but also the procedure name - -- when 11g and 12c reports only package name + -- format_call_stack reports not only package name, but also the procedure name function cut_header_and_expectations( a_stack varchar2 ) return varchar2 is begin return regexp_substr( a_stack, '(.*\.(UT_EQUAL|UT_BE_WITHIN[[:alnum:]$#_]*|UT_EXPECTATION[[:alnum:]$#_]*|UT|UTASSERT2?)(\.[[:alnum:]$#_]+)?\s+)+((.|\s)*)', 1, 1, 'm', 4); diff --git a/source/dummy.sql b/source/dummy.sql deleted file mode 100644 index 36d9f8778..000000000 --- a/source/dummy.sql +++ /dev/null @@ -1 +0,0 @@ -whenever sqlerror exit failure rollback diff --git a/source/expectations/data_values/ut_cursor_details.tpb b/source/expectations/data_values/ut_cursor_details.tpb index ae10cafff..bfbe435e5 100644 --- a/source/expectations/data_values/ut_cursor_details.tpb +++ b/source/expectations/data_values/ut_cursor_details.tpb @@ -108,11 +108,7 @@ create or replace noneditionable type body ut_cursor_details as a_cursor_number in number ) return self as result is l_columns_count pls_integer; - $if dbms_db_version.version = 12 and dbms_db_version.release = 1 or dbms_db_version.version < 12 $then - l_columns_desc dbms_sql.desc_tab3; - $else l_columns_desc dbms_sql.desc_tab4; - $end l_is_collection boolean; l_hierarchy_level integer := 1; begin diff --git a/source/expectations/data_values/ut_data_value_refcursor.tpb b/source/expectations/data_values/ut_data_value_refcursor.tpb index 01a71d4dd..af6d1791b 100644 --- a/source/expectations/data_values/ut_data_value_refcursor.tpb +++ b/source/expectations/data_values/ut_data_value_refcursor.tpb @@ -51,12 +51,8 @@ create or replace noneditionable type body ut_data_value_refcursor as loop l_xml := dbms_xmlgen.getxmltype(l_ctx); exit when dbms_xmlgen.getNumRowsProcessed(l_ctx) = 0; - --Bug in oracle 12.2+ where XML binary storage trimming insignificant whitespaces. - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - l_xml := xmltype( replace(l_xml.getClobVal(),'= 2 - or dbms_db_version.version > 12 - then - :V_FILE_NAME := '&&FILE_NAME'; - else - :V_FILE_NAME := 'dummy.sql'; - end if; -end; -/ - -set verify off -select :V_FILE_NAME as SCRIPT_NAME from dual; -set termout on - -set heading off -set feedback off -exec dbms_output.put_line('Installing component '||upper(regexp_substr('&&1','\/(\w*)\.',1,1,'i',1))); -@@&&SCRIPT_NAME -exec dbms_output.put_line('&&line_separator'); - - - diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 3e2c2f988..6cdde8db4 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -273,12 +273,6 @@ begin $if dbms_db_version.version < 21 $then begin execute immediate 'drop type json force'; exception when others then null; end; $end - $if dbms_db_version.version = 12 and dbms_db_version.release = 1 or dbms_db_version.version < 12 $then - begin execute immediate 'drop type json_element_t force'; exception when others then null; end; - begin execute immediate 'drop type json_object_t force'; exception when others then null; end; - begin execute immediate 'drop type json_array_t force'; exception when others then null; end; - begin execute immediate 'drop type json_key_list force'; exception when others then null; end; - $end end; / @@ -417,7 +411,7 @@ set feedback off declare i integer := 0; begin - dbms_output.put_line('Dropping packages created for 12.2+ ' || upper('&&ut3_owner')); + dbms_output.put_line('Dropping block coverage packages ' || upper('&&ut3_owner')); for pkg in ( select object_name, owner from all_objects diff --git a/source/uninstall_synonyms.sql b/source/uninstall_synonyms.sql index 58e24060b..783ac51e8 100644 --- a/source/uninstall_synonyms.sql +++ b/source/uninstall_synonyms.sql @@ -49,7 +49,7 @@ end; declare i integer := 0; begin - dbms_output.put_line('Dropping synonyms pointing to PL/SQL code coverage objects on 12.2 ' || upper('&&ut3_owner')); + dbms_output.put_line('Dropping synonyms pointing to PL/SQL code coverage objects ' || upper('&&ut3_owner')); for syn in ( select case when owner = 'PUBLIC' then 'public synonym ' diff --git a/test/install_above_12_1.sql b/test/install_above_12_1.sql deleted file mode 100644 index fe20cf816..000000000 --- a/test/install_above_12_1.sql +++ /dev/null @@ -1,28 +0,0 @@ -set termout off -set echo off -spool dummy.sql -prompt whenever sqlerror exit failure rollback -spool off - - -def FILE_NAME = '&&1' -column SCRIPT_NAME new_value SCRIPT_NAME noprint - -VAR V_FILE_NAME VARCHAR2(1000); -begin - if dbms_db_version.version = 12 and dbms_db_version.release >= 2 - or dbms_db_version.version > 12 - then - :V_FILE_NAME := '&&FILE_NAME'; - else - :V_FILE_NAME := 'dummy.sql'; - end if; -end; -/ -set verify off -select :V_FILE_NAME as SCRIPT_NAME from dual; -set termout on - - -@@&&SCRIPT_NAME - diff --git a/test/install_below_12_2.sql b/test/install_below_12_2.sql deleted file mode 100644 index 669ae75fc..000000000 --- a/test/install_below_12_2.sql +++ /dev/null @@ -1,28 +0,0 @@ -set termout off -set echo off -spool dummy.sql -prompt whenever sqlerror exit failure rollback -spool off - - -def FILE_NAME = '&&1' -column SCRIPT_NAME new_value SCRIPT_NAME noprint - -VAR V_FILE_NAME VARCHAR2(1000); -begin - if dbms_db_version.version = 12 and dbms_db_version.release < 2 - or dbms_db_version.version < 12 - then - :V_FILE_NAME := '&&FILE_NAME'; - else - :V_FILE_NAME := 'dummy.sql'; - end if; -end; -/ -set verify off -select :V_FILE_NAME as SCRIPT_NAME from dual; -set termout on - - -@@&&SCRIPT_NAME - diff --git a/test/install_ut3_user_tests.sql b/test/install_ut3_user_tests.sql index b74c5d7ae..36966b3f6 100644 --- a/test/install_ut3_user_tests.sql +++ b/test/install_ut3_user_tests.sql @@ -30,9 +30,7 @@ prompt Install user tests @@ut3_user/expectations/test_matchers.pks @@ut3_user/expectations/test_expectation_anydata.pks @@ut3_user/expectations/test_expectations_cursor.pks -set define on -@@install_above_12_1.sql 'ut3_user/expectations/test_expectations_json.pks' -set define off +@@ut3_user/expectations/test_expectations_json.pks @@ut3_user/api/test_ut_runner.pks @@ut3_user/api/test_ut_run.pks @@ut3_user/reporters.pks @@ -73,9 +71,7 @@ set define off @@ut3_user/expectations/test_matchers.pkb @@ut3_user/expectations/test_expectation_anydata.pkb @@ut3_user/expectations/test_expectations_cursor.pkb -set define on -@@install_above_12_1.sql 'ut3_user/expectations/test_expectations_json.pkb' -set define off +@@ut3_user/expectations/test_expectations_json.pkb @@ut3_user/api/test_ut_runner.pkb @@ut3_user/api/test_ut_run.pkb @@ut3_user/reporters.pkb diff --git a/test/ut3_tester/core/test_ut_utils.pkb b/test/ut3_tester/core/test_ut_utils.pkb index 4dc10492b..d46835f66 100644 --- a/test/ut3_tester/core/test_ut_utils.pkb +++ b/test/ut3_tester/core/test_ut_utils.pkb @@ -287,7 +287,7 @@ end;'; l_varchar2_byte_limit integer := 32767; l_workaround_byte_limit integer := 8191; l_singlebyte_string_max_size varchar2(32767 char) := rpad('x',l_varchar2_byte_limit,'x'); - l_twobyte_character char(1 char) := '�?'; + l_twobyte_character char(1 char) := unistr('\00E4'); l_clob_multibyte clob := l_twobyte_character||l_singlebyte_string_max_size; --here we have 32769(2+32767) bytes and 32768 chars l_expected ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list(); l_result ut3_develop.ut_varchar2_list; diff --git a/test/ut3_tester/core/test_ut_utils.pks b/test/ut3_tester/core/test_ut_utils.pks index ca2e7b304..82145f908 100644 --- a/test/ut3_tester/core/test_ut_utils.pks +++ b/test/ut3_tester/core/test_ut_utils.pks @@ -93,7 +93,6 @@ create or replace package test_ut_utils is procedure clean_append_with_multibyte; --%test(clob_to_table - converts multibyte CLOB to ut_varchar2_list) - --%disabled(We cannot run this test successfully on 12.1 until we change NLSCHARACTERSET from US7ASCII to AL32UTF8) procedure test_clob_to_table_multibyte; --%test(to_version - splits version string into individual version components) diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index ef14c586f..cf072ce3c 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -2,22 +2,9 @@ create or replace package body coverage_helper is g_job_no integer := 0; - function block_coverage_available return boolean is - begin - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - return true; - $else - return false; - $end - end; - function covered_package_name return varchar2 is begin - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - return 'dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long'; - $else - return 'dummy_coverage'; - $end + return 'dummy_coverage_package_with_an_amazingly_long_name_that_you_would_not_think_of_in_real_life_project_because_its_simply_too_long'; end; function substitute_covered_package( a_text varchar2, a_substitution varchar2 ) return varchar2 is diff --git a/test/ut3_tester_helper/coverage_helper.pks b/test/ut3_tester_helper/coverage_helper.pks index 8d2c1c150..d6a57a143 100644 --- a/test/ut3_tester_helper/coverage_helper.pks +++ b/test/ut3_tester_helper/coverage_helper.pks @@ -1,7 +1,5 @@ create or replace package coverage_helper is - function block_coverage_available return boolean; - function covered_package_name return varchar2; function substitute_covered_package( a_text varchar2, a_substitution varchar2 := '{p}' ) return varchar2; diff --git a/test/ut3_user/expectations/test_expectation_anydata.pkb b/test/ut3_user/expectations/test_expectation_anydata.pkb index c70d41f9e..5f76e6715 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pkb +++ b/test/ut3_user/expectations/test_expectation_anydata.pkb @@ -1229,7 +1229,6 @@ Rows: [ 60 differences, showing first 20 ] end; - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then procedure long_names_object_types is pragma autonomous_transaction; begin @@ -1253,7 +1252,6 @@ Rows: [ 60 differences, showing first 20 ] execute immediate 'drop type very_long_type_name_valid_for_oracle_12_so_utPLSQL_should_allow_it_definitely_well_still_not_reached_128_but_wait_we_did_it'; raise; end; - $end end; / \ No newline at end of file diff --git a/test/ut3_user/expectations/test_expectation_anydata.pks b/test/ut3_user/expectations/test_expectation_anydata.pks index 54c246bd3..557eb58db 100644 --- a/test/ut3_user/expectations/test_expectation_anydata.pks +++ b/test/ut3_user/expectations/test_expectation_anydata.pks @@ -237,10 +237,8 @@ create or replace package test_expectation_anydata is --%test ( Reports success when comparing complex nested objects ) procedure complex_nested_object_success; - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then --%test ( Compares object types with long names - Issue #1235 ) procedure long_names_object_types; - $end end; / diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index a4ef4e8f2..fcd474226 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -2843,8 +2843,6 @@ Check the query and data for errors.'; l_expected_data(1).col4 := 2016; l_expected_data(1).col5 := -1; - --Select on package level nested table types supported only since Oracle 12 - $if dbms_db_version.version >= 12 $then open l_expected for select * from table (l_expected_data); @@ -2869,7 +2867,6 @@ Check the query and data for errors.'; l_actual_message := ut3_tester_helper.main_helper.get_failed_expectations(1); ut.expect(l_actual_message).to_be_like(l_expected_message); - $end end; procedure uc_columns_exclude is @@ -2890,19 +2887,15 @@ Check the query and data for errors.'; l_expected sys_refcursor; begin -- populate actual - $if dbms_db_version.version = 12 and dbms_db_version.release >= 2 or dbms_db_version.version > 12 $then - open l_actual for - select rownum as id, '1' some_column_with_a_pretty_long_enough_name from dual; + open l_actual for + select rownum as id, '1' some_column_with_a_pretty_long_enough_name from dual; - open l_expected for - select rownum as id, '1' some_column_with_a_pretty_long_enough_name from dual; + open l_expected for + select rownum as id, '1' some_column_with_a_pretty_long_enough_name from dual; - ut3_develop.ut.expect(l_actual).to_equal(l_expected).include('ID,SOME_COLUMN_WITH_A_PRETTY_LONG_ENOUGH_NAME').join_by('ID'); - --Assert - ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); - $else - null; - $end + ut3_develop.ut.expect(l_actual).to_equal(l_expected).include('ID,SOME_COLUMN_WITH_A_PRETTY_LONG_ENOUGH_NAME').join_by('ID'); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; procedure compare_specific_column_names is diff --git a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb index ad6c9dbb4..49e0410ba 100644 --- a/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_cov_cobertura_reporter.pkb @@ -12,11 +12,7 @@ create or replace package body test_cov_cobertura_reporter is --Arrange l_name := ut3_tester_helper.coverage_helper.covered_package_name; l_file_path := 'test/ut3_develop.'||ut3_tester_helper.coverage_helper.covered_package_name||'.pkb'; - if ut3_tester_helper.coverage_helper.block_coverage_available then - l_block_cov := ''; - else - l_block_cov := ''; - end if; + l_block_cov := ''; l_expected := q'[ diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb index 50d7bfe4c..9f2409637 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_sonar_reporter.pkb @@ -6,11 +6,7 @@ create or replace package body test_coverage_sonar_reporter is l_block_cov clob; begin --Arrange - if ut3_tester_helper.coverage_helper.block_coverage_available then - l_block_cov := ''; - else - l_block_cov := ''; - end if; + l_block_cov := ''; l_expected := ' diff --git a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb index 90cfb484e..adf7b51d1 100644 --- a/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb +++ b/test/ut3_user/reporters/test_coverage/test_coverage_standalone.pkb @@ -7,11 +7,7 @@ create or replace package body test_coverage_standalone is begin l_file_path := 'package body ut3_develop.'||a_object_name; --Arrange - if ut3_tester_helper.coverage_helper.block_coverage_available then - l_block_cov := ''; - else - l_block_cov := ''; - end if; + l_block_cov := ''; l_expected := q'[ diff --git a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb index d7f1b61d7..f6f76b62f 100644 --- a/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb +++ b/test/ut3_user/reporters/test_coverage/test_extended_coverage.pkb @@ -2,13 +2,7 @@ create or replace package body test_extended_coverage is function get_block_coverage_line return clob is begin - return - case - when ut3_tester_helper.coverage_helper.block_coverage_available then - '%' - else - '%' - end; + return '%'; end; procedure coverage_for_object is l_expected clob; @@ -130,8 +124,7 @@ create or replace package body test_extended_coverage is ); --Assert - --The below is a workaround for problem with large CLOB like comparison on 11g XE db. - ut.expect(to_char(substr(l_actual,instr(l_actual,''),2000))).to_be_like(l_expected); + ut.expect(l_actual).to_be_like(l_expected); ut.expect(l_actual).not_to_be_like(l_not_expected); ut.expect(l_actual).not_to_be_like('%ut3_tester_helper.test_regex_dummy_cov%'); end; diff --git a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb index 2f2200116..e88a94131 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb @@ -9,9 +9,7 @@ create or replace package body test_html_coverage_reporter is begin --Arrange l_name := ut3_tester_helper.coverage_helper.covered_package_name; - if ut3_tester_helper.coverage_helper.block_coverage_available then - l_block_cov := '(including 1 lines partially covered ) '; - end if; + l_block_cov := '(including 1 lines partially covered ) '; l_expected := '%%

    UT3_DEVELOP.'||upper(l_name)||'

    ' || '%2 relevant lines. 1 lines covered ' || l_block_cov || 'and 1 lines missed%'; From bbcedf130f42bc6648b425c82258121e36afdbf5 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 1 Nov 2026 23:16:30 +0000 Subject: [PATCH 809/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 23b21f1d1..3f04bd87e 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4568 +4571 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 805319fff..f32bc4afe 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4568-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4571-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 7b050ce7cab46e5f610c03587abfe79da760f365 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Nov 2026 14:03:24 +0200 Subject: [PATCH 810/887] Replace dbms_lock.sleep with dbms_session.sleep utPLSQL will now only call dbms_session.sleep as this does not require access to privileged package dbms_lock. --- source/core/output_buffers/ut_output_bulk_buffer.tpb | 2 +- source/core/output_buffers/ut_output_clob_table_buffer.tpb | 2 +- source/core/output_buffers/ut_output_table_buffer.tpb | 2 +- test/ut3_tester_helper/coverage_helper.pkb | 6 +++--- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/source/core/output_buffers/ut_output_bulk_buffer.tpb b/source/core/output_buffers/ut_output_bulk_buffer.tpb index bd5b66339..60efda708 100644 --- a/source/core/output_buffers/ut_output_bulk_buffer.tpb +++ b/source/core/output_buffers/ut_output_bulk_buffer.tpb @@ -118,7 +118,7 @@ create or replace noneditionable type body ut_output_bulk_buffer is or self.timeout_producer_not_started(l_producer_started, l_already_waited_sec, lc_init_wait_sec) or l_producer_finished; - dbms_lock.sleep(l_sleep_time); + dbms_session.sleep(l_sleep_time); l_already_waited_sec := l_already_waited_sec + l_sleep_time; end loop; diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index 91dd10e29..d92fadd4e 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -111,7 +111,7 @@ create or replace noneditionable type body ut_output_clob_table_buffer is remove_read_data(l_buffer_rowids); else --nothing fetched from output, wait. - dbms_lock.sleep(l_sleep_time); + dbms_session.sleep(l_sleep_time); l_already_waited_sec := l_already_waited_sec + l_sleep_time; end if; diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index a4ea2be8d..22e09795d 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -141,7 +141,7 @@ create or replace noneditionable type body ut_output_table_buffer is end loop; else --nothing fetched from output, wait. - dbms_lock.sleep(l_sleep_time); + dbms_session.sleep(l_sleep_time); l_already_waited_sec := l_already_waited_sec + l_sleep_time; end if; diff --git a/test/ut3_tester_helper/coverage_helper.pkb b/test/ut3_tester_helper/coverage_helper.pkb index cf072ce3c..8c978d046 100644 --- a/test/ut3_tester_helper/coverage_helper.pkb +++ b/test/ut3_tester_helper/coverage_helper.pkb @@ -301,7 +301,7 @@ create or replace package body coverage_helper is begin g_job_no := g_job_no + 1; l_job_name := 'utPLSQL_selftest_job_'||g_job_no; - dbms_lock.sleep(0.15); + dbms_session.sleep(0.15); dbms_scheduler.create_job( job_name => l_job_name, job_type => 'PLSQL_BLOCK', @@ -313,7 +313,7 @@ create or replace package body coverage_helper is ); while (l_job_run_info.status is null or l_job_run_info.status not in ('SUCCEEDED','FAILED')) and i < 6000 loop l_job_run_info := get_job_status( l_job_name, l_timestamp ); - dbms_lock.sleep(0.1); + dbms_session.sleep(0.1); i := i + 1; end loop; commit; @@ -356,7 +356,7 @@ create or replace package body coverage_helper is pragma autonomous_transaction; begin run_job_and_wait_for_finish( a_plsql_block ); - dbms_lock.sleep(0.1); + dbms_session.sleep(0.1); execute immediate q'[ declare l_results ut3_develop.ut_varchar2_list; From a7d2f0255f562336699bce5dbea8f56a240c6644 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Nov 2026 16:40:13 +0200 Subject: [PATCH 811/887] Output buffer improvements. Reduced lock-wait when allocating new output buffer. The timeout for new output buffer is now reduced to 0.1 second making the testing slow. Set of missing tests for output buffer is now implemented. The `is_finished` flag is now removed. It was a leftover from previous output-buffer solution. --- .../output_buffers/ut_output_buffer_base.tpb | 2 +- .../output_buffers/ut_output_buffer_tmp.sql | 5 +- .../ut_output_clob_buffer_tmp.sql | 5 +- .../ut_output_clob_table_buffer.tpb | 16 +- .../output_buffers/ut_output_table_buffer.tpb | 16 +- test/ut3_tester/core/test_output_buffer.pkb | 153 ++++++++++++++++++ test/ut3_tester/core/test_output_buffer.pks | 95 ++++++----- 7 files changed, 218 insertions(+), 74 deletions(-) diff --git a/source/core/output_buffers/ut_output_buffer_base.tpb b/source/core/output_buffers/ut_output_buffer_base.tpb index 5ce32eb23..6bbb00b4b 100644 --- a/source/core/output_buffers/ut_output_buffer_base.tpb +++ b/source/core/output_buffers/ut_output_buffer_base.tpb @@ -40,7 +40,7 @@ create or replace noneditionable type body ut_output_buffer_base is member procedure lock_buffer(a_timeout_sec number := null) is l_status integer; begin - l_status := dbms_lock.request( self.lock_handle, dbms_lock.x_mode, 5, false ); + l_status := dbms_lock.request( self.lock_handle, dbms_lock.x_mode, coalesce(a_timeout_sec, 0.1), false ); if l_status != 0 then raise_application_error(-20000, 'Cannot allocate lock for output buffer of reporter. lock request status = '||l_status||', lock handle = '||self.lock_handle||', self.output_id ='||self.output_id); end if; diff --git a/source/core/output_buffers/ut_output_buffer_tmp.sql b/source/core/output_buffers/ut_output_buffer_tmp.sql index 535246bde..dc4c5043c 100644 --- a/source/core/output_buffers/ut_output_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_buffer_tmp.sql @@ -21,11 +21,8 @@ create table ut_output_buffer_tmp( message_id number(38,0) not null, text varchar2(4000), item_type varchar2(1000), - is_finished number(1,0) default 0 not null, constraint ut_output_buffer_tmp_pk primary key(output_id, message_id), - constraint ut_output_buffer_tmp_ck check( - is_finished = 0 and (text is not null or item_type is not null ) - or is_finished = 1 and text is null and item_type is null ), + constraint ut_output_buffer_tmp_ck check( text is not null or item_type is not null ), constraint ut_output_buffer_fk foreign key (output_id) references ut_output_buffer_info_tmp(output_id) on delete cascade ) organization index nologging initrans 100 overflow nologging initrans 100; diff --git a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql index d8b3b8db9..b832e68c7 100644 --- a/source/core/output_buffers/ut_output_clob_buffer_tmp.sql +++ b/source/core/output_buffers/ut_output_clob_buffer_tmp.sql @@ -26,11 +26,8 @@ begin message_id number(38,0) not null, text clob, item_type varchar2(1000), - is_finished number(1,0) default 0 not null, constraint ut_output_clob_buffer_tmp_pk primary key(output_id, message_id), - constraint ut_output_clob_buffer_tmp_ck check( - is_finished = 0 and (text is not null or item_type is not null ) - or is_finished = 1 and text is null and item_type is null ), + constraint ut_output_clob_buffer_tmp_ck check( text is not null or item_type is not null ), constraint ut_output_clob_buffer_tmp_fk foreign key (output_id) references ut_output_buffer_info_tmp(output_id) on delete cascade ) nologging initrans 100 '; diff --git a/source/core/output_buffers/ut_output_clob_table_buffer.tpb b/source/core/output_buffers/ut_output_clob_table_buffer.tpb index 91dd10e29..073bd073f 100644 --- a/source/core/output_buffers/ut_output_clob_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_clob_table_buffer.tpb @@ -56,7 +56,6 @@ create or replace noneditionable type body ut_output_clob_table_buffer is lc_init_wait_sec constant number := coalesce(a_initial_timeout, 10 ); l_buffer_rowids ut_varchar2_rows; l_buffer_data ut_output_data_rows; - l_finished_flags ut_integer_list; l_already_waited_sec number(10,2) := 0; l_finished boolean := false; l_sleep_time number(2,1); @@ -65,20 +64,19 @@ create or replace noneditionable type body ut_output_clob_table_buffer is l_producer_finished boolean := false; procedure get_data_from_buffer_table( a_buffer_data out nocopy ut_output_data_rows, - a_buffer_rowids out nocopy ut_varchar2_rows, - a_finished_flags out nocopy ut_integer_list + a_buffer_rowids out nocopy ut_varchar2_rows ) is lc_bulk_limit constant integer := 5000; begin with ordered_buffer as ( - select /*+ no_parallel index(a) */ ut_output_data_row(a.text, a.item_type), rowidtochar(a.rowid), is_finished + select /*+ no_parallel index(a) */ ut_output_data_row(a.text, a.item_type), rowidtochar(a.rowid) from ut_output_clob_buffer_tmp a where a.output_id = self.output_id and a.message_id <= (select min(message_id) from ut_output_clob_buffer_tmp o where o.output_id = self.output_id) + lc_bulk_limit order by a.message_id ) select /*+ no_parallel */ b.* - bulk collect into a_buffer_data, a_buffer_rowids, a_finished_flags + bulk collect into a_buffer_data, a_buffer_rowids from ordered_buffer b; end; @@ -96,16 +94,13 @@ create or replace noneditionable type body ut_output_clob_table_buffer is l_sleep_time := case when l_already_waited_sec >= 1 then 0.5 else 0.1 end; l_lock_status := self.get_lock_status(); - get_data_from_buffer_table( l_buffer_data, l_buffer_rowids, l_finished_flags ); + get_data_from_buffer_table( l_buffer_data, l_buffer_rowids ); if l_buffer_data.count > 0 then l_already_waited_sec := 0; for i in 1 .. l_buffer_data.count loop if l_buffer_data(i).text is not null then pipe row( l_buffer_data(i) ); - elsif l_finished_flags(i) = 1 then - l_finished := true; - exit; end if; end loop; remove_read_data(l_buffer_rowids); @@ -121,8 +116,7 @@ create or replace noneditionable type body ut_output_clob_table_buffer is l_finished := self.timeout_producer_not_finished(l_producer_finished, l_already_waited_sec, a_timeout_sec) or self.timeout_producer_not_started(l_producer_started, l_already_waited_sec, lc_init_wait_sec) - or l_producer_finished - or l_finished; + or l_producer_finished; end loop; diff --git a/source/core/output_buffers/ut_output_table_buffer.tpb b/source/core/output_buffers/ut_output_table_buffer.tpb index a4ea2be8d..9df367c8b 100644 --- a/source/core/output_buffers/ut_output_table_buffer.tpb +++ b/source/core/output_buffers/ut_output_table_buffer.tpb @@ -95,7 +95,6 @@ create or replace noneditionable type body ut_output_table_buffer is lc_init_wait_sec constant number := coalesce(a_initial_timeout, 10 ); l_buffer_texts ut_varchar2_rows; l_buffer_item_types ut_varchar2_rows; - l_finished_flags ut_integer_list; l_already_waited_sec number(10,2) := 0; l_finished boolean := false; l_sleep_time number(2,1); @@ -105,8 +104,7 @@ create or replace noneditionable type body ut_output_table_buffer is procedure get_data_from_buffer_table( a_buffer_texts out nocopy ut_varchar2_rows, - a_buffer_item_types out nocopy ut_varchar2_rows, - a_finished_flags out nocopy ut_integer_list + a_buffer_item_types out nocopy ut_varchar2_rows ) is lc_bulk_limit constant integer := 20000; pragma autonomous_transaction; @@ -118,8 +116,8 @@ create or replace noneditionable type body ut_output_table_buffer is and a.message_id <= (select min(message_id) from ut_output_buffer_tmp o where o.output_id = self.output_id) + lc_bulk_limit order by a.message_id ) d - returning d.text, d.item_type, d.is_finished - bulk collect into a_buffer_texts, a_buffer_item_types, a_finished_flags; + returning d.text, d.item_type + bulk collect into a_buffer_texts, a_buffer_item_types; commit; end; begin @@ -127,16 +125,13 @@ create or replace noneditionable type body ut_output_table_buffer is l_sleep_time := case when l_already_waited_sec >= 1 then 0.5 else 0.1 end; l_lock_status := self.get_lock_status(); - get_data_from_buffer_table( l_buffer_texts, l_buffer_item_types, l_finished_flags ); + get_data_from_buffer_table( l_buffer_texts, l_buffer_item_types ); if l_buffer_texts.count > 0 then l_already_waited_sec := 0; for i in 1 .. l_buffer_texts.count loop if l_buffer_texts(i) is not null then pipe row( ut_output_data_row(l_buffer_texts(i), l_buffer_item_types(i)) ); - elsif l_finished_flags(i) = 1 then - l_finished := true; - exit; end if; end loop; else @@ -151,8 +146,7 @@ create or replace noneditionable type body ut_output_table_buffer is l_finished := self.timeout_producer_not_finished(l_producer_finished, l_already_waited_sec, a_timeout_sec) or self.timeout_producer_not_started(l_producer_started, l_already_waited_sec, lc_init_wait_sec) - or l_producer_finished - or l_finished; + or l_producer_finished; end loop; diff --git a/test/ut3_tester/core/test_output_buffer.pkb b/test/ut3_tester/core/test_output_buffer.pkb index 55670b8b8..de53b957a 100644 --- a/test/ut3_tester/core/test_output_buffer.pkb +++ b/test/ut3_tester/core/test_output_buffer.pkb @@ -1,5 +1,14 @@ create or replace package body test_output_buffer is + -- Writer action that waits (up to 30 seconds) until the reader removes the buffer info. + -- It keeps the writer only as long as the test needs it, so it does not delay jobs of the following tests. + gc_wait_for_reader_to_finish constant varchar2(4000) := q'[ + for i in 1 .. 300 loop + select count(1) into l_info_count from ut3_develop.ut_output_buffer_info_tmp b where b.output_id = l_buffer.output_id; + exit when l_info_count = 0; + dbms_session.sleep(0.1); + end loop;]'; + function long_text return varchar2 is l_txt varchar2(32767); begin @@ -8,6 +17,56 @@ create or replace package body test_output_buffer is end loop; return l_txt; end; + + -- Runs a_writer_actions in a separate session (scheduler job) on a buffer sharing output_id with a_reader. + -- The writer buffer is available to the actions as l_buffer. + procedure start_writer(a_reader ut3_develop.ut_output_buffer_base, a_writer_actions varchar2) is + begin + ut3_tester_helper.run_helper.run_as_job( + 'declare + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.'||a_reader.self_type||'(a_output_id => '''||a_reader.output_id||'''); + l_info_count integer; + begin + '||a_writer_actions||' + end;' + ); + end; + + procedure wait_for_writer_lock(a_reader ut3_develop.ut_output_buffer_base) is + c_max_wait_sec constant number := 30; + l_waited_sec number := 0; + begin + while a_reader.get_lock_status() = 0 and l_waited_sec < c_max_wait_sec loop + dbms_session.sleep(0.1); + l_waited_sec := l_waited_sec + 0.1; + end loop; + ut.expect(a_reader.get_lock_status(), 'Writer session holds the buffer lock').not_to_equal(0); + end; + + procedure reads_lines_from_writer(a_reader ut3_develop.ut_output_buffer_base) is + l_actual sys_refcursor; + l_expected sys_refcursor; + begin + --Arrange - writer stays silent for 1 second longer than reader's initial timeout + start_writer( + a_reader, + q'[l_buffer.lock_buffer(); + dbms_session.sleep(1.2); + l_buffer.send_line('line 1'); + l_buffer.send_line('line 2'); + l_buffer.close();]' + ); + wait_for_writer_lock(a_reader); + --Act + open l_actual for + select to_char(text) as text from table(a_reader.get_lines(a_initial_timeout => 0.2, a_timeout_sec => 30)); + --Assert + open l_expected for + select 'line 1' as text from dual union all + select 'line 2' as text from dual; + ut.expect(l_actual).to_equal(l_expected); + end; + procedure test_receive is l_actual_text clob; l_actual_item_type varchar2(1000); @@ -213,5 +272,99 @@ create or replace package body test_output_buffer is l_consumer_buffer_instance := ut3_develop.ut_output_table_buffer(a_output_id => l_shared_output_id); end; + procedure table_buffer_reads_from_writer is + begin + reads_lines_from_writer(ut3_develop.ut_output_table_buffer()); + end; + + procedure clob_buffer_reads_from_writer is + begin + reads_lines_from_writer(ut3_develop.ut_output_clob_table_buffer()); + end; + + procedure bulk_buffer_reads_from_writer is + begin + reads_lines_from_writer(ut3_develop.ut_output_bulk_buffer()); + end; + + procedure reader_stops_when_writer_ends is + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); + l_lines ut3_develop.ut_varchar2_rows; + l_start timestamp; + l_duration interval day to second; + begin + --Arrange - writer keeps the lock for a while after sending and its session ends without calling close() + start_writer( + l_buffer, + q'[l_buffer.lock_buffer(); + l_buffer.send_line('line 1'); + dbms_session.sleep(0.5);]' + ); + wait_for_writer_lock(l_buffer); + l_start := localtimestamp; + --Act + begin + select to_char(text) bulk collect into l_lines + from table(l_buffer.get_lines(a_initial_timeout => 1, a_timeout_sec => 2)); + exception + when others then + ut.fail('Reader did not stop after writer session ended: '||sqlerrm); + end; + l_duration := localtimestamp - l_start; + --Assert + ut.expect(anydata.convertCollection(l_lines)).to_equal(anydata.convertCollection(ut3_develop.ut_varchar2_rows('line 1'))); + ut.expect(l_buffer.get_lock_status(), 'Writer lock released by session end').to_equal(0); + ut.expect(l_duration, 'Reader waited for writer session to end').to_be_greater_or_equal(interval '0.3' second); + end; + + procedure reader_times_out_on_idle_writer is + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); + l_count integer; + begin + --Arrange - writer holds the lock without sending data until the reader gives up + start_writer( + l_buffer, + q'[l_buffer.lock_buffer(); + l_buffer.send_line('line 1');]' + ||gc_wait_for_reader_to_finish||q'[ + l_buffer.close();]' + ); + wait_for_writer_lock(l_buffer); + --Act + begin + select count(1) into l_count from table(l_buffer.get_lines(a_initial_timeout => 1, a_timeout_sec => 1)); + ut.fail('Expected a timeout exception but nothing was raised'); + exception + when others then + --Assert + ut.expect(dbms_utility.format_error_stack()).to_match('ORA'||ut3_develop.ut_utils.gc_out_buffer_timeout); + end; + end; + + procedure second_writer_cannot_lock is + l_buffer ut3_develop.ut_output_buffer_base := ut3_develop.ut_output_table_buffer(); + begin + --Arrange - writer holds the lock until the test is done + start_writer( + l_buffer, + q'[l_buffer.lock_buffer();]' + ||gc_wait_for_reader_to_finish||q'[ + l_buffer.close();]' + ); + wait_for_writer_lock(l_buffer); + --Act + begin + l_buffer.lock_buffer(); + l_buffer.close(); + ut.fail('Expected lock_buffer to fail but it succeeded'); + exception + when others then + --Assert + ut.expect(sqlerrm).to_be_like('%Cannot allocate lock for output buffer of reporter%'); + end; + --Cleanup - let the writer finish + l_buffer.remove_buffer_info(); + end; + end test_output_buffer; / diff --git a/test/ut3_tester/core/test_output_buffer.pks b/test/ut3_tester/core/test_output_buffer.pks index aa5c830d3..1b5a04762 100644 --- a/test/ut3_tester/core/test_output_buffer.pks +++ b/test/ut3_tester/core/test_output_buffer.pks @@ -4,59 +4,68 @@ create or replace package test_output_buffer is --%suitepath(utplsql.ut3_tester.core) - --%context(Read and write within the same session) + --%context(Buffer is read in a different session than buffer write) + + --%test(Text buffer reader waits beyond initial timeout for writer holding the lock and reads all lines) + procedure table_buffer_reads_from_writer; + + --%test(Clob buffer reader waits beyond initial timeout for writer holding the lock and reads all lines) + procedure clob_buffer_reads_from_writer; + + --%test(Bulk buffer reader waits beyond initial timeout for writer holding the lock and reads all lines) + procedure bulk_buffer_reads_from_writer; + --%test(Reader stops when writer session ends without closing the buffer) + procedure reader_stops_when_writer_ends; + + --%test(Reader times out when writer holds the lock and sends no data) + procedure reader_times_out_on_idle_writer; + + --%test(Writer cannot lock buffer that is locked by another session) + procedure second_writer_cannot_lock; --%endcontext - - --%context(Buffer is read in a different session than buffer write) - --reader will wait for a_initial_timeout seconds for the writer process to start and then it will finish with error + --%context(Read and write within the same session) + - --reader will wait forever (beyond a_initial_timeout) if the writer process is started and end of data row was not received from the buffer + --%test(Receives a line from buffer table and deletes) + procedure test_receive; - --reader stops after reading the end of data signal from the buffer + --%test(Waits specified time for producer to lock the buffer ) + --%throws(-20218) + procedure test_wait_for_producer; - --reader stops when writer process ends and all data was read from the buffer + --%test(Does not send line if null text given) + procedure test_doesnt_send_on_null_text; + --%test(Does not send line if null text given for multiline case) + procedure test_doesnt_send_on_null_elem; - --%endcontext + --%test(Sends a line into buffer table) + procedure test_send_line; + + --%test(Waits For The Data To Appear For Specified Time) + procedure test_waiting_for_data; + + --%test(Purges text buffer data older than one day and leaves the rest) + procedure test_purge_text_buffer; + + --%test(Purges clob buffer data older than one day and leaves the rest) + procedure test_purge_clob_buffer; - --%test(Receives a line from buffer table and deletes) - procedure test_receive; - - --%test(Waits specified time for producer to lock the buffer ) - --%throws(-20218) - procedure test_wait_for_producer; - - --%test(Does not send line if null text given) - procedure test_doesnt_send_on_null_text; - - --%test(Does not send line if null text given for multiline case) - procedure test_doesnt_send_on_null_elem; - - --%test(Sends a line into buffer table) - procedure test_send_line; - - --%test(Waits For The Data To Appear For Specified Time) - procedure test_waiting_for_data; - - --%test(Purges text buffer data older than one day and leaves the rest) - procedure test_purge_text_buffer; - - --%test(Purges clob buffer data older than one day and leaves the rest) - procedure test_purge_clob_buffer; - - --%test(Successfully sends multibyte long line into text buffer) - procedure text_buffer_send_multibyte; - - --%test(Successfully sends multibyte long clob line into text buffer) - procedure text_buffer_send_clob_multib; - - --%beforetest(ut3_tester_helper.run_helper.slow_down_insert_into_table_buffer) - --%aftertest(ut3_tester_helper.run_helper.cleanup_slow_down_insert_into_table_buffer) - --%test(concurrent calls to init() procedure do not cause errors - Issue #985) - procedure concurrent_calls_do_not_cause_exception; + --%test(Successfully sends multibyte long line into text buffer) + procedure text_buffer_send_multibyte; + + --%test(Successfully sends multibyte long clob line into text buffer) + procedure text_buffer_send_clob_multib; + + --%beforetest(ut3_tester_helper.run_helper.slow_down_insert_into_table_buffer) + --%aftertest(ut3_tester_helper.run_helper.cleanup_slow_down_insert_into_table_buffer) + --%test(concurrent calls to init() procedure do not cause errors - Issue #985) + procedure concurrent_calls_do_not_cause_exception; + + --%endcontext end test_output_buffer; / From b336ebd58bfe5baeb03b863e5d517f661af73375 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 8 Nov 2026 14:48:13 +0000 Subject: [PATCH 812/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 3f04bd87e..65f1d65a6 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4571 +4577 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index f32bc4afe..7338befd9 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4571-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4577-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 3362224cf7aad9c05693c7ca705fd243d651908b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 8 Nov 2026 14:54:51 +0000 Subject: [PATCH 813/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 65f1d65a6..8831f9f13 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4577 +4578 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 7338befd9..b71dac98d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4577-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4578-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From aee3bbc9ee64cf37b5b8331753ff918f0b91f7d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Nov 2026 17:11:31 +0200 Subject: [PATCH 814/887] Improved cursor compare logic. Column names of up to 128 are now handled without hashing. Added two new tests to verify the logic. --- .../data_values/ut_cursor_column.tpb | 17 ++++---- .../expectations/test_expectations_cursor.pkb | 42 +++++++++++++++++++ .../expectations/test_expectations_cursor.pks | 6 +++ 3 files changed, 57 insertions(+), 8 deletions(-) diff --git a/source/expectations/data_values/ut_cursor_column.tpb b/source/expectations/data_values/ut_cursor_column.tpb index a3c5d9171..01ec72f41 100644 --- a/source/expectations/data_values/ut_cursor_column.tpb +++ b/source/expectations/data_values/ut_cursor_column.tpb @@ -47,21 +47,22 @@ create or replace noneditionable type body ut_cursor_column as a_access_path||'/'||self.xml_valid_name end; --Access path used for XMLTABLE query self.filter_path := '/'||self.access_path; --Filter path will differ from access path in anydata type - --Transformed name needs to be build on full access path to avoid ambiguity when there is 3 or more levels of nesting. - self.transformed_name := case when length(self.xml_valid_name) > 30 then - '"'||ut_compound_data_helper.get_fixed_size_hash(self.access_path)||'"' - when self.parent_name is null then + --Transformed name is used as a column alias in generated SQL. + --Nested columns and names longer than the maximum identifier length are replaced by a hash of the full access path, + -- to avoid ambiguity when there is 3 or more levels of nesting. + self.transformed_name := case when self.parent_name is null and lengthb(self.xml_valid_name) <= ora_max_name_len_supported then '"'||self.xml_valid_name||'"' - else + else '"'||ut_compound_data_helper.get_fixed_size_hash(self.access_path)||'"' - end; --when is nestd we need to hash name to make sure we dont exceed 30 char + end; self.column_type := a_col_type; --column type e.g. user_defined , varchar2 self.column_schema := a_col_schema_name; -- schema name self.is_sql_diffable := case when lower(self.column_type) = 'user_defined_type' then 0 - -- Due to bug in 11g/12.1 collection fails on varchar 4000+ - when (lower(self.column_type) in ('varchar2','char')) and (self.column_len > 4000) then + -- Columns can be described as longer than SQL varchar2 allows (e.g. a dynamic bind over 4000 chars), + -- XMLTABLE rejects such a length (ORA-00910), so these values are compared by hash. + when (lower(self.column_type) in ('varchar2','char')) and (self.column_len > ut_utils.gc_max_storage_varchar2_len) then 0 else ut_utils.boolean_to_int(ut_compound_data_helper.is_sql_compare_allowed(self.column_type)) diff --git a/test/ut3_user/expectations/test_expectations_cursor.pkb b/test/ut3_user/expectations/test_expectations_cursor.pkb index fcd474226..aa5375500 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pkb +++ b/test/ut3_user/expectations/test_expectations_cursor.pkb @@ -2898,6 +2898,48 @@ Check the query and data for errors.'; ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); end; + procedure compare_column_names_over_max_identifier is + l_actual sys_refcursor; + l_expected sys_refcursor; + --An unaliased literal gets a column name longer than an identifier can be + l_sql varchar2(4000) := 'select '''||rpad('a',ora_max_name_len_supported + 10,'a')||''' from dual'; + begin + --Act + open l_actual for l_sql; + open l_expected for l_sql; + ut3_develop.ut.expect(l_actual).to_equal(l_expected); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + + --Act + open l_actual for l_sql; + open l_expected for l_sql||' connect by level <= 2'; + ut3_develop.ut.expect(l_actual).to_equal(l_expected); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(1); + end; + + procedure compare_varchar2_described_over_4000 is + l_actual sys_refcursor; + l_expected sys_refcursor; + --A dynamic bind longer than 4000 chars is described as a varchar2 longer than 4000, even with max_string_size=standard + c_sql constant varchar2(100) := 'select :some_text as some_text from dual'; + begin + --Act + open l_actual for c_sql using rpad('x',4001,'x'); + open l_expected for c_sql using rpad('x',4001,'x'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(0); + + --Act + open l_actual for c_sql using rpad('x',4001,'x'); + open l_expected for c_sql using rpad('y',4001,'y'); + ut3_develop.ut.expect(l_actual).to_equal(l_expected); + --Assert + ut.expect(ut3_tester_helper.main_helper.get_failed_expectations_num).to_equal(1); + end; + procedure compare_specific_column_names is function get_cursor return sys_refcursor is l_result sys_refcursor; diff --git a/test/ut3_user/expectations/test_expectations_cursor.pks b/test/ut3_user/expectations/test_expectations_cursor.pks index 8cceb5e01..d7ff823de 100644 --- a/test/ut3_user/expectations/test_expectations_cursor.pks +++ b/test/ut3_user/expectations/test_expectations_cursor.pks @@ -479,6 +479,12 @@ create or replace package test_expectations_cursor is --%test( Compares cursors with long column names - Issue #952 ) procedure compare_long_column_names; + --%test( Compares cursors with column names longer than the maximum identifier length ) + procedure compare_column_names_over_max_identifier; + + --%test( Compares cursors with varchar2 columns described as longer than 4000 ) + procedure compare_varchar2_described_over_4000; + --%test( Compares cursors with specific column names - Issue #997 ) procedure compare_specific_column_names; From e7b868b25a0f4ae8e94482da7b5d2c40ff257b6f Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sun, 8 Nov 2026 15:32:31 +0000 Subject: [PATCH 815/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 8831f9f13..5b9e54fbb 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4578 +4581 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index b71dac98d..3602a5447 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4578-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4581-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 20f2894e26a6c7ec26680cff761f4c8a28947b11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Nov 2026 20:42:21 +0200 Subject: [PATCH 816/887] Introduction of Code Based Access Control (CBAC). - Added new role `&&ut3_owner._cbac_modify_objects_role` to hold private utPLSQL objects privileges that are to be available for sources compiled with invoker-rights. - Changed `ut_annotation_cache_manager` to be invoker rights. --- development/cleanup.sh | 1 + docs/userguide/install.md | 5 ++ .../ut_annotation_cache_manager.pkb | 67 ++++++++++--------- .../ut_annotation_cache_manager.pks | 9 ++- .../ut_annotation_cache_manager_grants.sql | 34 ++++++++++ source/create_cbac_role.sql | 38 +++++++++++ source/install.sql | 3 + source/uninstall_objects.sql | 12 ++++ 8 files changed, 136 insertions(+), 33 deletions(-) create mode 100644 source/core/annotations/ut_annotation_cache_manager_grants.sql create mode 100644 source/create_cbac_role.sql diff --git a/development/cleanup.sh b/development/cleanup.sh index d36f21540..560395150 100755 --- a/development/cleanup.sh +++ b/development/cleanup.sh @@ -28,6 +28,7 @@ drop user ut3_no_extra_priv_user cascade; drop user ut3_select_catalog_user cascade; drop user ut3_select_any_table_user cascade; drop user ut3_execute_any_proc_user cascade; +drop role ${UT3_DEVELOP_SCHEMA}_cbac_modify_objects_role; set serveroutput on begin diff --git a/docs/userguide/install.md b/docs/userguide/install.md index ecccbf100..7f1d9cf82 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -163,6 +163,7 @@ If the installing user and utPLSQL owner is one and the same, the user must have - CREATE SYNONYM - ALTER SESSION - CREATE TRIGGER + - CREATE ROLE In addition, the user must be granted the execute privilege on `DBMS_LOCK` and `DBMS_CRYPTO` packages. @@ -190,6 +191,10 @@ To install the utPLSQL framework into your database, go to `source` directory, r Schema must be created prior to calling the `install` script. You may install utPLSQL from any account that has sufficient privileges to create objects in other users schema. +The installation uses code based access control (CBAC) to give utPLSQL packages access to internal utPLSQL tables without granting those tables to users. +It creates the role `_cbac_modify_objects_role` (for example `ut3_cbac_modify_objects_role`), unless it already exists, and grants it to the utPLSQL schema and to utPLSQL packages. +The installing user therefore needs the `CREATE ROLE` privilege. Each utPLSQL schema gets its own role. The role is dropped when utPLSQL is uninstalled. + Example invocation: ```bash cd source diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index 2917102c0..1518128a2 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -21,12 +21,12 @@ create or replace noneditionable package body ut_annotation_cache_manager as l_timestamp timestamp := systimestamp; pragma autonomous_transaction; begin - update /*+ no_parallel */ ut_annotation_cache_schema s + update /*+ no_parallel */ &&ut3_owner..ut_annotation_cache_schema s set s.max_parse_time = l_timestamp where s.object_type = a_object.object_type and s.object_owner = a_object.object_owner; if sql%rowcount = 0 then - insert /*+ no_parallel */ into ut_annotation_cache_schema s + insert /*+ no_parallel */ into &&ut3_owner..ut_annotation_cache_schema s (object_owner, object_type, max_parse_time) values (a_object.object_owner, a_object.object_type, l_timestamp); end if; @@ -34,7 +34,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as -- if not in trigger, or object has annotations if a_object.annotations is not null and a_object.annotations.count > 0 then - update /*+ no_parallel */ ut_annotation_cache_info i + update /*+ no_parallel */ &&ut3_owner..ut_annotation_cache_info i set i.parse_time = l_timestamp where (i.object_owner, i.object_name, i.object_type) in ((a_object.object_owner, a_object.object_name, a_object.object_type)) @@ -42,15 +42,15 @@ create or replace noneditionable package body ut_annotation_cache_manager as if sql%rowcount = 0 then - insert /*+ no_parallel */ into ut_annotation_cache_info + insert /*+ no_parallel */ into &&ut3_owner..ut_annotation_cache_info (cache_id, object_owner, object_name, object_type, parse_time) - values (ut_annotation_cache_seq.nextval, a_object.object_owner, a_object.object_name, a_object.object_type, l_timestamp) + values (&&ut3_owner..ut_annotation_cache_seq.nextval, a_object.object_owner, a_object.object_name, a_object.object_type, l_timestamp) returning cache_id into l_cache_id; end if; - - delete /*+ no_parallel */ from ut_annotation_cache c where cache_id = l_cache_id; - insert /*+ no_parallel */ into ut_annotation_cache + delete /*+ no_parallel */ from &&ut3_owner..ut_annotation_cache c where cache_id = l_cache_id; + + insert /*+ no_parallel */ into &&ut3_owner..ut_annotation_cache (cache_id, annotation_position, annotation_name, annotation_text, subobject_name) select /*+ no_parallel */ l_cache_id, a.position, a.name, a.text, a.subobject_name from table(a_object.annotations) a; @@ -70,10 +70,10 @@ create or replace noneditionable package body ut_annotation_cache_manager as pragma autonomous_transaction; begin - delete /*+ no_parallel */ from ut_annotation_cache c + delete /*+ no_parallel */ from &&ut3_owner..ut_annotation_cache c where c.cache_id in (select /*+ no_parallel */ i.cache_id - from ut_annotation_cache_info i + from &&ut3_owner..ut_annotation_cache_info i join table (a_objects) o on o.object_name = i.object_name and o.object_type = i.object_type @@ -81,7 +81,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as and o.needs_refresh = 'Y' ); - update /*+ no_parallel */ ut_annotation_cache_schema s + update /*+ no_parallel */ &&ut3_owner..ut_annotation_cache_schema s set s.max_parse_time = l_timestamp where (s.object_owner, s.object_type) in ( @@ -91,7 +91,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as ); if sql%rowcount = 0 then - insert /*+ no_parallel */ into ut_annotation_cache_schema s + insert /*+ no_parallel */ into &&ut3_owner..ut_annotation_cache_schema s (object_owner, object_type, max_parse_time) select /*+ no_parallel */ distinct o.object_owner, o.object_type, l_timestamp from table(a_objects) o @@ -99,7 +99,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as end if; merge /*+ no_parallel */ - into ut_annotation_cache_info i + into &&ut3_owner..ut_annotation_cache_info i using (select /*+ no_parallel */ o.object_name, o.object_type, o.object_owner from table(a_objects) o where o.needs_refresh = 'Y' @@ -112,7 +112,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as set parse_time = l_timestamp when not matched then insert (cache_id, object_owner, object_name, object_type, parse_time) - values (ut_annotation_cache_seq.nextval, o.object_owner, o.object_name, o.object_type, l_timestamp); + values (&&ut3_owner..ut_annotation_cache_seq.nextval, o.object_owner, o.object_name, o.object_type, l_timestamp); commit; end; @@ -120,7 +120,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as function get_cached_objects_list(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return ut_annotation_objs_cache_info is l_result ut_annotation_objs_cache_info; begin - select /*+ no_parallel */ ut_annotation_obj_cache_info( + select /*+ no_parallel */ &&ut3_owner..ut_annotation_obj_cache_info( object_owner => i.object_owner, object_name => i.object_name, object_type => i.object_type, @@ -128,7 +128,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as parse_time => i.parse_time ) bulk collect into l_result - from ut_annotation_cache_info i + from &&ut3_owner..ut_annotation_cache_info i where i.object_owner = a_object_owner and i.object_type = a_object_type and (i.parse_time > a_parsed_after or a_parsed_after is null); @@ -141,7 +141,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as begin select /*+ no_parallel */ * into l_result - from ut_annotation_cache_schema s + from &&ut3_owner..ut_annotation_cache_schema s where s.object_type = a_object_type and s.object_owner = a_object_owner; exception when no_data_found then @@ -153,7 +153,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as procedure set_fully_refreshed(a_object_owner varchar2, a_object_type varchar2) is pragma autonomous_transaction; begin - update /*+ no_parallel */ ut_annotation_cache_schema s + update /*+ no_parallel */ &&ut3_owner..ut_annotation_cache_schema s set s.full_refresh_time = s.max_parse_time where s.object_owner = a_object_owner and s.object_type = a_object_type; @@ -164,7 +164,7 @@ create or replace noneditionable package body ut_annotation_cache_manager as pragma autonomous_transaction; begin - delete /*+ no_parallel */ from ut_annotation_cache_info i + delete /*+ no_parallel */ from &&ut3_owner..ut_annotation_cache_info i where exists ( select /*+ no_parallel */ 1 from table (a_objects) o where o.object_name = i.object_name @@ -178,22 +178,25 @@ create or replace noneditionable package body ut_annotation_cache_manager as function get_annotations_parsed_since(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp) return sys_refcursor is l_results sys_refcursor; begin + --cast(collect(...)) does not use privileges of code based access control roles (ORA-00902), cast(multiset(...)) does open l_results for - select /*+ no_parallel */ ut_annotated_object( + select /*+ no_parallel */ &&ut3_owner..ut_annotated_object( i.object_owner, i.object_name, i.object_type, i.parse_time, cast( - collect( - ut_annotation( - c.annotation_position, c.annotation_name, c.annotation_text, c.subobject_name - ) order by c.annotation_position - ) as ut_annotations + multiset( + select /*+ no_parallel */ &&ut3_owner..ut_annotation( + c.annotation_position, c.annotation_name, c.annotation_text, c.subobject_name + ) + from &&ut3_owner..ut_annotation_cache c + where c.cache_id = i.cache_id + order by c.annotation_position + ) as &&ut3_owner..ut_annotations ) ) as annotated_object - from ut_annotation_cache_info i - join ut_annotation_cache c on i.cache_id = c.cache_id + from &&ut3_owner..ut_annotation_cache_info i where i.object_owner = a_object_owner and i.object_type = a_object_type and (i.parse_time > a_parsed_after or a_parsed_after is null) - group by i.object_owner, i.object_type, i.object_name, i.parse_time; + and exists (select /*+ no_parallel */ 1 from &&ut3_owner..ut_annotation_cache c where c.cache_id = i.cache_id); return l_results; end; @@ -208,15 +211,15 @@ create or replace noneditionable package body ut_annotation_cache_manager as else l_filter := case when a_object_owner is null then ':a_object_owner is null' else 'object_owner = :a_object_owner' end; l_filter := l_filter || ' and ' || case when a_object_type is null then ':a_object_type is null' else 'object_type = :a_object_type' end; - l_cache_filter := ' c.cache_id in (select /*+ no_parallel */ i.cache_id from ut_annotation_cache_info i where ' || l_filter || ' )'; + l_cache_filter := ' c.cache_id in (select /*+ no_parallel */ i.cache_id from &&ut3_owner..ut_annotation_cache_info i where ' || l_filter || ' )'; end if; - execute immediate 'delete /*+ no_parallel */ from ut_annotation_cache c where ' || l_cache_filter + execute immediate 'delete /*+ no_parallel */ from &&ut3_owner..ut_annotation_cache c where ' || l_cache_filter using a_object_owner, a_object_type; - execute immediate ' delete /*+ no_parallel */ from ut_annotation_cache_info i where ' || l_filter + execute immediate ' delete /*+ no_parallel */ from &&ut3_owner..ut_annotation_cache_info i where ' || l_filter using a_object_owner, a_object_type; - execute immediate ' delete /*+ no_parallel */ from ut_annotation_cache_schema s where ' || l_filter + execute immediate ' delete /*+ no_parallel */ from &&ut3_owner..ut_annotation_cache_schema s where ' || l_filter using a_object_owner, a_object_type; commit; diff --git a/source/core/annotations/ut_annotation_cache_manager.pks b/source/core/annotations/ut_annotation_cache_manager.pks index cfd9a0280..ea13e0c27 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pks +++ b/source/core/annotations/ut_annotation_cache_manager.pks @@ -1,4 +1,4 @@ -create or replace noneditionable package ut_annotation_cache_manager authid definer as +create or replace noneditionable package ut_annotation_cache_manager authid current_user as /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project @@ -15,6 +15,13 @@ create or replace noneditionable package ut_annotation_cache_manager authid defi See the License for the specific language governing permissions and limitations under the License. */ + + /* + * The package runs with invoker rights. It accesses the annotation cache tables of the framework owner + * through the code based access control role _cbac_modify_objects_role granted to the package, + * so all references to those tables in SQL statements are qualified with the framework owner. + * The owner is filled in by the SQL*Plus substitution variable ut3_owner when the package body is installed by install.sql. + */ subtype t_cache_schema_info is ut_annotation_cache_schema%rowtype; /** diff --git a/source/core/annotations/ut_annotation_cache_manager_grants.sql b/source/core/annotations/ut_annotation_cache_manager_grants.sql new file mode 100644 index 000000000..fe80faf73 --- /dev/null +++ b/source/core/annotations/ut_annotation_cache_manager_grants.sql @@ -0,0 +1,34 @@ +/* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Code based access control for the invoker rights package ut_annotation_cache_manager. + The package accesses the annotation cache tables through the role _cbac_modify_objects_role, + so the users calling the framework do not need any privileges on those tables. + The types are constructed in SQL statements of the package, so the role needs to be able to execute them too. + This way the types do not need to be granted to the users calling the framework. +*/ +grant select, insert, update, delete on &&ut3_owner..ut_annotation_cache to &&ut3_owner._cbac_modify_objects_role; +grant select, insert, update, delete on &&ut3_owner..ut_annotation_cache_info to &&ut3_owner._cbac_modify_objects_role; +grant select, insert, update, delete on &&ut3_owner..ut_annotation_cache_schema to &&ut3_owner._cbac_modify_objects_role; +grant select on &&ut3_owner..ut_annotation_cache_seq to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_annotation_obj_cache_info to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_annotated_object to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_annotation to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_annotations to &&ut3_owner._cbac_modify_objects_role; + +grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_cache_manager; +--granting a role to a package invalidates the package +alter package &&ut3_owner..ut_annotation_cache_manager compile; diff --git a/source/create_cbac_role.sql b/source/create_cbac_role.sql new file mode 100644 index 000000000..23082e34b --- /dev/null +++ b/source/create_cbac_role.sql @@ -0,0 +1,38 @@ +/* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Creates the code based access control (CBAC) role that gives invoker rights framework packages + access to framework tables, which are not granted to the users calling the framework. + The role is granted to the framework owner, as Oracle only allows granting a role to a program unit + when the role is granted to the owner of that program unit. + Each framework owner gets its own role, so packages of one utPLSQL installation cannot access tables of another one. + The role is created only if it does not exist yet, so the installation can be repeated without uninstalling first. +*/ + +prompt Creating role &&ut3_owner._cbac_modify_objects_role and granting it to &&ut3_owner + +declare + e_role_exists exception; + pragma exception_init(e_role_exists, -1921); +begin + execute immediate 'create role &&ut3_owner._cbac_modify_objects_role'; +exception + when e_role_exists then + null; +end; +/ + +grant &&ut3_owner._cbac_modify_objects_role to &&ut3_owner; diff --git a/source/install.sql b/source/install.sql index 5bbb693be..347ed458f 100644 --- a/source/install.sql +++ b/source/install.sql @@ -36,6 +36,8 @@ alter session set current_schema = &&ut3_owner; create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_context; +@@create_cbac_role.sql + --dbms_output buffer cache table @@install_component.sql 'core/ut_dbms_output_cache.sql' @@ -142,6 +144,7 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/annotations/ut_annotation_cache.sql' @@install_component.sql 'core/annotations/ut_annotation_cache_manager.pks' @@install_component.sql 'core/annotations/ut_annotation_cache_manager.pkb' +@@install_component.sql 'core/annotations/ut_annotation_cache_manager_grants.sql' @@install_component.sql 'core/annotations/ut_annotation_parser.pks' @@install_component.sql 'core/annotations/ut_annotation_parser.pkb' @@install_component.sql 'core/annotations/ut_annotation_manager.pks' diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 6cdde8db4..79efe9ca9 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -438,3 +438,15 @@ begin dbms_output.put_line(i || ' packages dropped'); end; / + +declare + e_role_not_exists exception; + pragma exception_init(e_role_not_exists, -1919); +begin + execute immediate 'drop role &&ut3_owner._cbac_modify_objects_role'; + dbms_output.put_line('Role ' || upper('&&ut3_owner._cbac_modify_objects_role') || ' dropped'); +exception + when e_role_not_exists then + dbms_output.put_line('Role ' || upper('&&ut3_owner._cbac_modify_objects_role') || ' does not exist'); +end; +/ From 8052c58e0f942b700fd9ae007d69aa370bb51d96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Nov 2026 22:51:31 +0200 Subject: [PATCH 817/887] Introduction of Code Based Access Control (CBAC). - Changed `ut_suite_cache_manager` to use Code Based Access Control and use invoker rights. --- .../ut_annotation_cache_manager_grants.sql | 34 --------- source/core/ut_suite_cache_manager.pkb | 70 +++++++++---------- source/core/ut_suite_cache_manager.pks | 7 +- source/install.sql | 3 +- .../ut3_cbac_modify_objects_role_grants.sql | 56 +++++++++++++++ 5 files changed, 99 insertions(+), 71 deletions(-) delete mode 100644 source/core/annotations/ut_annotation_cache_manager_grants.sql create mode 100644 source/ut3_cbac_modify_objects_role_grants.sql diff --git a/source/core/annotations/ut_annotation_cache_manager_grants.sql b/source/core/annotations/ut_annotation_cache_manager_grants.sql deleted file mode 100644 index fe80faf73..000000000 --- a/source/core/annotations/ut_annotation_cache_manager_grants.sql +++ /dev/null @@ -1,34 +0,0 @@ -/* - utPLSQL - Version 3 - Copyright 2016 - 2026 utPLSQL Project - - Licensed under the Apache License, Version 2.0 (the "License"). - You may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - - Code based access control for the invoker rights package ut_annotation_cache_manager. - The package accesses the annotation cache tables through the role _cbac_modify_objects_role, - so the users calling the framework do not need any privileges on those tables. - The types are constructed in SQL statements of the package, so the role needs to be able to execute them too. - This way the types do not need to be granted to the users calling the framework. -*/ -grant select, insert, update, delete on &&ut3_owner..ut_annotation_cache to &&ut3_owner._cbac_modify_objects_role; -grant select, insert, update, delete on &&ut3_owner..ut_annotation_cache_info to &&ut3_owner._cbac_modify_objects_role; -grant select, insert, update, delete on &&ut3_owner..ut_annotation_cache_schema to &&ut3_owner._cbac_modify_objects_role; -grant select on &&ut3_owner..ut_annotation_cache_seq to &&ut3_owner._cbac_modify_objects_role; -grant execute on &&ut3_owner..ut_annotation_obj_cache_info to &&ut3_owner._cbac_modify_objects_role; -grant execute on &&ut3_owner..ut_annotated_object to &&ut3_owner._cbac_modify_objects_role; -grant execute on &&ut3_owner..ut_annotation to &&ut3_owner._cbac_modify_objects_role; -grant execute on &&ut3_owner..ut_annotations to &&ut3_owner._cbac_modify_objects_role; - -grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_cache_manager; ---granting a role to a package invalidates the package -alter package &&ut3_owner..ut_annotation_cache_manager compile; diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index efbd6e91e..66eda77c5 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -46,19 +46,19 @@ create or replace noneditionable package body ut_suite_cache_manager is logical_suite_data as ( select 'UT_LOGICAL_SUITE' as self_type, p.path, p.object_owner, upper( substr(p.path, instr( p.path, '.', -1 ) + 1 ) ) as object_name, - cast(null as ut_executables) as x, - cast(null as ut_varchar2_rows) as y, - cast(null as ut_executable_test) as z + cast(null as &&ut3_owner..ut_executables) as x, + cast(null as &&ut3_owner..ut_varchar2_rows) as y, + cast(null as &&ut3_owner..ut_executable_test) as z from suitepath_part p where p.path not in (select s.path from suitepaths s) ), logical_suites as ( - select ut_suite_cache_row( + select &&ut3_owner..ut_suite_cache_row( null, s.self_type, s.path, s.object_owner, s.object_name, s.object_name, null, null, null, null, 0,null, - ut_varchar2_rows(), + &&ut3_owner..ut_varchar2_rows(), s.x, s.x, s.x, s.x, s.x, s.x, s.y, null, s.z ) as obj @@ -76,7 +76,7 @@ create or replace noneditionable package body ut_suite_cache_manager is select /*+ no_parallel */ i.object_name bulk collect into l_result - from ut_suite_cache_package i + from &&ut3_owner..ut_suite_cache_package i where not exists ( select 1 from table(l_data) o where o.object_owner = i.object_owner @@ -135,7 +135,7 @@ create or replace noneditionable package body ut_suite_cache_manager is paths_for_object as ( select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, null as procedure_name - from schema_paths sp left outer join ut_suite_cache c + from schema_paths sp left outer join &&ut3_owner..ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) and c.object_name like replace(upper(sp.object_name),'*','%')) where sp.suite_path is null and sp.object_name is not null @@ -145,7 +145,7 @@ create or replace noneditionable package body ut_suite_cache_manager is paths_for_procedures as ( select /*+ no_parallel */ path as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, nvl(c.name,sp.procedure_name) as procedure_name - from schema_paths sp left outer join ut_suite_cache c + from schema_paths sp left outer join &&ut3_owner..ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) and c.object_name like replace(upper(sp.object_name),'*','%') and c.name like nvl(replace(upper(sp.procedure_name),'*','%'), c.name)) @@ -154,7 +154,7 @@ create or replace noneditionable package body ut_suite_cache_manager is ), paths_for_suite_path_with_ast as ( select /*+ no_parallel */ nvl(c.path,sp.suite_path) as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name - from schema_paths sp left outer join ut_suite_cache c on + from schema_paths sp left outer join &&ut3_owner..ut_suite_cache c on ( c.object_owner = upper(sp.schema_name) --and c.path like replace(sp.suite_path,'*','%')) and regexp_like(c.path,'^'||replace(sp.suite_path,'*','[[:alnum:]$#_]*'))) @@ -177,7 +177,7 @@ create or replace noneditionable package body ut_suite_cache_manager is union all select * from straigth_suite_paths ) - select ut_path_item(schema_name,object_name,procedure_name,suite_path) + select &&ut3_owner..ut_path_item(schema_name,object_name,procedure_name,suite_path) bulk collect into l_schema_paths from (select schema_name,object_name,procedure_name,suite_path, @@ -204,7 +204,7 @@ create or replace noneditionable package body ut_suite_cache_manager is select obj bulk collect into l_suite_items from ( select /*+ cardinality(c 500) */ value(c) as obj,row_number() over ( partition by path,object_owner order by path,object_owner asc) as r_num - from ut_suite_cache c, + from &&ut3_owner..ut_suite_cache c, table(a_schema_paths) sp where c.object_owner = upper(sp.schema_name) and ((sp.suite_path is not null and sp.suite_path||'.' like c.path||'.%' /*all parents and self*/ @@ -240,7 +240,7 @@ create or replace noneditionable package body ut_suite_cache_manager is extract_parent_child as ( select s.path, substr(s.path,1,instr(s.path,'.',-1,1)-1) as parent_path,s.object_owner, case when a_random_seed is null then s.line_no end line_no, - case when a_random_seed is not null then ut_utils.hash_suite_path(s.path, a_random_seed) end random_seed + case when a_random_seed is not null then &&ut3_owner..ut_utils.hash_suite_path(s.path, a_random_seed) end random_seed from table(a_suite_rows) s), t1(path,parent_path,object_owner,line_no,random_seed) as ( --Anchor member @@ -290,7 +290,7 @@ create or replace noneditionable package body ut_suite_cache_manager is begin select /*+ no_parallel */ min(t.parse_time) into l_cache_parse_time - from ut_suite_cache_schema t + from &&ut3_owner..ut_suite_cache_schema t where object_owner = upper(a_schema_name); return l_cache_parse_time; end; @@ -308,11 +308,11 @@ create or replace noneditionable package body ut_suite_cache_manager is begin if a_suite_items is null or a_suite_items.count = 0 then - delete from ut_suite_cache t + delete from &&ut3_owner..ut_suite_cache t where t.object_owner = l_object_owner and t.object_name = l_object_name; - delete from ut_suite_cache_package t + delete from &&ut3_owner..ut_suite_cache_package t where t.object_owner = l_object_owner and t.object_name = l_object_name; @@ -320,38 +320,38 @@ create or replace noneditionable package body ut_suite_cache_manager is select /*+ no_parallel */ min(parse_time) into l_cached_parse_time - from ut_suite_cache_package t + from &&ut3_owner..ut_suite_cache_package t where t.object_name = l_object_name and t.object_owner = l_object_owner; if a_parse_time > l_cached_parse_time or l_cached_parse_time is null then - update /*+ no_parallel */ ut_suite_cache_schema t + update /*+ no_parallel */ &&ut3_owner..ut_suite_cache_schema t set t.parse_time = greatest(t.parse_time,a_parse_time) where object_owner = l_object_owner; if sql%rowcount = 0 then - insert /*+ no_parallel */ into ut_suite_cache_schema + insert /*+ no_parallel */ into &&ut3_owner..ut_suite_cache_schema (object_owner, parse_time) values (l_object_owner, a_parse_time); end if; - update /*+ no_parallel */ ut_suite_cache_package t + update /*+ no_parallel */ &&ut3_owner..ut_suite_cache_package t set t.parse_time = a_parse_time where t.object_owner = l_object_owner and t.object_name = l_object_name; if sql%rowcount = 0 then - insert /*+ no_parallel */ into ut_suite_cache_package + insert /*+ no_parallel */ into &&ut3_owner..ut_suite_cache_package (object_owner, object_name, parse_time) values (l_object_owner, l_object_name, a_parse_time ); end if; - delete from ut_suite_cache t + delete from &&ut3_owner..ut_suite_cache t where t.object_owner = l_object_owner and t.object_name = l_object_name; - insert /*+ no_parallel */ into ut_suite_cache t + insert /*+ no_parallel */ into &&ut3_owner..ut_suite_cache t ( id, self_type, path, object_owner, object_name, name, line_no, parse_time, description, @@ -363,10 +363,10 @@ create or replace noneditionable package body ut_suite_cache_manager is item ) with suites as ( - select treat(value(x) as ut_suite) i + select treat(value(x) as &&ut3_owner..ut_suite) i from table(a_suite_items) x where x.self_type in( 'UT_SUITE', 'UT_SUITE_CONTEXT' ) ) - select /*+ no_parallel */ ut_suite_cache_seq.nextval, s.i.self_type as self_type, s.i.path as path, + select /*+ no_parallel */ &&ut3_owner..ut_suite_cache_seq.nextval, s.i.self_type as self_type, s.i.path as path, upper(s.i.object_owner) as object_owner, upper(s.i.object_name) as object_name, upper(s.i.name) as name, s.i.line_no as line_no, s.i.parse_time as parse_time, s.i.description as description, s.i.rollback_type as rollback_type, s.i.disabled_flag as disabled_flag,s.i.disabled_reason as disabled_reason, s.i.warnings as warnings, @@ -377,7 +377,7 @@ create or replace noneditionable package body ut_suite_cache_manager is null item from suites s; - insert /*+ no_parallel */ into ut_suite_cache t + insert /*+ no_parallel */ into &&ut3_owner..ut_suite_cache t ( id, self_type, path, object_owner, object_name, name, line_no, parse_time, description, @@ -389,10 +389,10 @@ create or replace noneditionable package body ut_suite_cache_manager is item ) with tests as ( - select treat(value(x) as ut_test) t + select treat(value(x) as &&ut3_owner..ut_test) t from table ( a_suite_items ) x where x.self_type in ( 'UT_TEST' ) ) - select /*+ no_parallel */ ut_suite_cache_seq.nextval, s.t.self_type as self_type, s.t.path as path, + select /*+ no_parallel */ &&ut3_owner..ut_suite_cache_seq.nextval, s.t.self_type as self_type, s.t.path as path, upper(s.t.object_owner) as object_owner, upper(s.t.object_name) as object_name, upper(s.t.name) as name, s.t.line_no as line_no, s.t.parse_time as parse_time, s.t.description as description, s.t.rollback_type as rollback_type, s.t.disabled_flag as disabled_flag, s.t.disabled_reason as disabled_reason, s.t.warnings as warnings, @@ -415,11 +415,11 @@ create or replace noneditionable package body ut_suite_cache_manager is l_objects := get_missing_cache_objects(a_schema_name); if l_objects is not empty then - delete /*+ no_parallel */ from ut_suite_cache i + delete /*+ no_parallel */ from &&ut3_owner..ut_suite_cache i where i.object_owner = a_schema_name and i.object_name in ( select /*+ no_parallel */ column_value from table (l_objects) ); - delete /*+ no_parallel */ from ut_suite_cache_package i + delete /*+ no_parallel */ from &&ut3_owner..ut_suite_cache_package i where i.object_owner = a_schema_name and i.object_name in ( select /*+ no_parallel */ column_value from table (l_objects) ); end if; @@ -439,7 +439,7 @@ create or replace noneditionable package body ut_suite_cache_manager is ) return ut_suite_items_info is l_results ut_suite_items_info; begin - select /*+ no_parallel */ ut_suite_item_info( + select /*+ no_parallel */ &&ut3_owner..ut_suite_item_info( c.object_owner, c.object_name, c.name, c.description, c.self_type, c.line_no, c.path, c.disabled_flag, c.disabled_reason, c.tags @@ -454,9 +454,9 @@ create or replace noneditionable package body ut_suite_cache_manager is ) return ut_object_names is l_results ut_object_names; begin - select /*+ no_parallel */ ut_object_name( c.object_owner, c.object_name ) + select /*+ no_parallel */ &&ut3_owner..ut_object_name( c.object_owner, c.object_name ) bulk collect into l_results - from ut_suite_cache_package c + from &&ut3_owner..ut_suite_cache_package c join table ( a_schema_names ) s on c.object_owner = upper(s.column_value); return l_results; @@ -473,7 +473,7 @@ create or replace noneditionable package body ut_suite_cache_manager is select /*+ no_parallel */ count( 1 ) into l_count from dual where exists( select 1 - from ut_suite_cache c + from &&ut3_owner..ut_suite_cache c where c.object_owner = a_owner_name and c.object_name = a_package_name and c.name = a_procedure_name @@ -482,7 +482,7 @@ create or replace noneditionable package body ut_suite_cache_manager is select /*+ no_parallel */ count( 1 ) into l_count from dual where exists( select 1 - from ut_suite_cache c + from &&ut3_owner..ut_suite_cache c where c.object_owner = a_owner_name and c.object_name = a_package_name ); @@ -490,7 +490,7 @@ create or replace noneditionable package body ut_suite_cache_manager is select /*+ no_parallel */ count( 1 ) into l_count from dual where exists( select 1 - from ut_suite_cache c + from &&ut3_owner..ut_suite_cache c where c.object_owner = a_owner_name ); end if; diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 6253f391e..3852a1d34 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -1,4 +1,4 @@ -create or replace noneditionable package ut_suite_cache_manager authid definer is +create or replace noneditionable package ut_suite_cache_manager authid current_user is /* utPLSQL - Version 3 Copyright 2016 - 2026 utPLSQL Project @@ -18,6 +18,11 @@ create or replace noneditionable package ut_suite_cache_manager authid definer i /** * Responsible for storing and retrieving suite data from cache + * + * The package runs with invoker rights. It accesses the suite cache tables of the framework owner + * through the code based access control role _cbac_modify_objects_role granted to the package, + * so all references to framework objects in SQL statements are qualified with the framework owner. + * The owner is filled in by the SQL*Plus substitution variable ut3_owner when the package body is installed by install.sql. */ /* diff --git a/source/install.sql b/source/install.sql index 347ed458f..519de9725 100644 --- a/source/install.sql +++ b/source/install.sql @@ -144,7 +144,6 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/annotations/ut_annotation_cache.sql' @@install_component.sql 'core/annotations/ut_annotation_cache_manager.pks' @@install_component.sql 'core/annotations/ut_annotation_cache_manager.pkb' -@@install_component.sql 'core/annotations/ut_annotation_cache_manager_grants.sql' @@install_component.sql 'core/annotations/ut_annotation_parser.pks' @@install_component.sql 'core/annotations/ut_annotation_parser.pkb' @@install_component.sql 'core/annotations/ut_annotation_manager.pks' @@ -381,6 +380,8 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'api/match.syn' @@install_component.sql 'api/contain.syn' +@@ut3_cbac_modify_objects_role_grants.sql + set linesize 200 set define on column text format a100 diff --git a/source/ut3_cbac_modify_objects_role_grants.sql b/source/ut3_cbac_modify_objects_role_grants.sql new file mode 100644 index 000000000..58e151080 --- /dev/null +++ b/source/ut3_cbac_modify_objects_role_grants.sql @@ -0,0 +1,56 @@ +/* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Code based access control for the invoker rights packages ut_annotation_cache_manager and ut_suite_cache_manager. + The packages access the annotation and suite cache tables through the role _cbac_modify_objects_role, + so the users calling the framework do not need any privileges on those tables. + The types and packages used in SQL statements of those packages are granted to the role too, + so they do not need to be granted to the users calling the framework. +*/ + +prompt Granting privileges to role &&ut3_owner._cbac_modify_objects_role + +--annotation cache +grant select, insert, update, delete on &&ut3_owner..ut_annotation_cache to &&ut3_owner._cbac_modify_objects_role; +grant select, insert, update, delete on &&ut3_owner..ut_annotation_cache_info to &&ut3_owner._cbac_modify_objects_role; +grant select, insert, update, delete on &&ut3_owner..ut_annotation_cache_schema to &&ut3_owner._cbac_modify_objects_role; +grant select on &&ut3_owner..ut_annotation_cache_seq to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_annotation_obj_cache_info to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_annotated_object to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_annotation to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_annotations to &&ut3_owner._cbac_modify_objects_role; + +--suite cache +grant select, insert, update, delete on &&ut3_owner..ut_suite_cache to &&ut3_owner._cbac_modify_objects_role; +grant select, insert, update, delete on &&ut3_owner..ut_suite_cache_package to &&ut3_owner._cbac_modify_objects_role; +grant select, insert, update, delete on &&ut3_owner..ut_suite_cache_schema to &&ut3_owner._cbac_modify_objects_role; +grant select on &&ut3_owner..ut_suite_cache_seq to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_suite_cache_row to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_suite_item_info to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_suite to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_test to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_executables to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_executable_test to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_varchar2_rows to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_path_item to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_object_name to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_utils to &&ut3_owner._cbac_modify_objects_role; + +grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_cache_manager; +grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_suite_cache_manager; + +--granting a role to a package invalidates the package and the objects depending on it +exec dbms_utility.compile_schema(schema => upper('&&ut3_owner'), compile_all => false); From c72d8d39d1bf1bc6a20e58dfc9941116bc9de0d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 8 Nov 2026 23:48:49 +0200 Subject: [PATCH 818/887] Refactoring `ut_suite_cache_manager`, `ut_suite_manager`, `ut_annotation_cache_manager` and `ut_annotation_manager` and reorganizing code --- source/core/ut_suite_cache_manager.pkb | 46 +++++---------------- test/ut3_tester/core/test_suite_manager.pkb | 1 + 2 files changed, 12 insertions(+), 35 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 66eda77c5..0316face8 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -68,25 +68,6 @@ create or replace noneditionable package body ut_suite_cache_manager is union all select /*+ no_parallel */ obj from logical_suites; - function get_missing_cache_objects(a_object_owner varchar2) return ut_varchar2_rows is - l_result ut_varchar2_rows; - l_data ut_annotation_objs_cache_info; - begin - l_data := ut_annotation_cache_manager.get_cached_objects_list(a_object_owner, 'PACKAGE'); - - select /*+ no_parallel */ i.object_name - bulk collect into l_result - from &&ut3_owner..ut_suite_cache_package i - where not exists ( - select 1 from table(l_data) o - where o.object_owner = i.object_owner - and o.object_name = i.object_name - and o.object_type = 'PACKAGE' - ) - and i.object_owner = a_object_owner; - return l_result; - end; - function group_paths_by_schema(a_paths ut_varchar2_list) return ut_path_items is c_package_path_regex constant varchar2(100) := '^([[:alnum:]$#_]+)(\.([[:alnum:]$#_\*]+))?(\.([[:alnum:]$#_\*]+))?$'; l_results ut_path_items := ut_path_items(); @@ -308,10 +289,7 @@ create or replace noneditionable package body ut_suite_cache_manager is begin if a_suite_items is null or a_suite_items.count = 0 then - delete from &&ut3_owner..ut_suite_cache t - where t.object_owner = l_object_owner - and t.object_name = l_object_name; - + --rows of ut_suite_cache are removed by the "on delete cascade" foreign key delete from &&ut3_owner..ut_suite_cache_package t where t.object_owner = l_object_owner and t.object_name = l_object_name; @@ -409,20 +387,18 @@ create or replace noneditionable package body ut_suite_cache_manager is end; procedure remove_missing_objs_from_cache(a_schema_name varchar2) is - l_objects ut_varchar2_rows; + l_cached_objects ut_annotation_objs_cache_info; pragma autonomous_transaction; begin - l_objects := get_missing_cache_objects(a_schema_name); - - if l_objects is not empty then - delete /*+ no_parallel */ from &&ut3_owner..ut_suite_cache i - where i.object_owner = a_schema_name - and i.object_name in ( select /*+ no_parallel */ column_value from table (l_objects) ); - - delete /*+ no_parallel */ from &&ut3_owner..ut_suite_cache_package i - where i.object_owner = a_schema_name - and i.object_name in ( select /*+ no_parallel */ column_value from table (l_objects) ); - end if; + l_cached_objects := ut_annotation_cache_manager.get_cached_objects_list(a_schema_name, 'PACKAGE'); + + --rows of ut_suite_cache are removed by the "on delete cascade" foreign key + delete /*+ no_parallel */ from &&ut3_owner..ut_suite_cache_package i + where i.object_owner = a_schema_name + and not exists ( + select 1 from table(l_cached_objects) o + where o.object_name = i.object_name + ); commit; end; diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index c818ad212..77b0f61b1 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -1732,6 +1732,7 @@ end;]'; begin select * bulk collect into l_test_report from table(ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER') || '.test_removing_annotation')); + ut.fail('Expected exception ORA-20204 was not raised'); exception when others then ut.expect(sqlerrm).to_be_like('%ORA-20204: Suite package ut3_tester.test_removing_annotation does not exist%'); From 3e731b9471117c30e883eac8d0d089b865376e8c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 00:35:28 +0200 Subject: [PATCH 819/887] Introducing SQL_MACRO for managing complex queries. Refactoring `ut_suite_cache_manager`, `ut_suite_manager`, `ut_annotation_cache_manager` and `ut_annotation_manager` and reorganizing code. --- .../ut_annotation_cache_macros.pkb | 30 +++++++++++ .../ut_annotation_cache_macros.pks | 40 ++++++++++++++ .../ut_annotation_cache_manager.pkb | 18 ------- .../ut_annotation_cache_manager.pks | 5 -- .../annotations/ut_annotation_manager.pkb | 50 ++++++++--------- source/core/ut_suite_cache_manager.pkb | 6 +-- source/install.sql | 54 ++++++++++++------- source/uninstall_objects.sql | 2 + .../ut3_cbac_modify_objects_role_grants.sql | 7 +-- 9 files changed, 137 insertions(+), 75 deletions(-) create mode 100644 source/core/annotations/ut_annotation_cache_macros.pkb create mode 100644 source/core/annotations/ut_annotation_cache_macros.pks diff --git a/source/core/annotations/ut_annotation_cache_macros.pkb b/source/core/annotations/ut_annotation_cache_macros.pkb new file mode 100644 index 000000000..38e59b9ab --- /dev/null +++ b/source/core/annotations/ut_annotation_cache_macros.pkb @@ -0,0 +1,30 @@ +create or replace noneditionable package body ut_annotation_cache_macros as + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + function get_cached_objects(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return varchar2 sql_macro is + begin + return q'[ + select i.object_owner, i.object_name, i.object_type, i.parse_time + from &&ut3_owner..ut_annotation_cache_info i + where i.object_owner = a_object_owner + and i.object_type = a_object_type + and (i.parse_time > a_parsed_after or a_parsed_after is null)]'; + end; + +end; +/ diff --git a/source/core/annotations/ut_annotation_cache_macros.pks b/source/core/annotations/ut_annotation_cache_macros.pks new file mode 100644 index 000000000..13aa4f6d5 --- /dev/null +++ b/source/core/annotations/ut_annotation_cache_macros.pks @@ -0,0 +1,40 @@ +create or replace noneditionable package ut_annotation_cache_macros authid definer as + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + /* + * SQL macros over the annotation cache tables. + * + * A package containing SQL macros cannot be an invoker rights package, so the macros are kept apart from ut_annotation_cache_manager. + * A macro only returns SQL text. The text is expanded into the calling SQL statement and runs with the privileges of the caller, + * so the macros can only be used by framework code that has the _cbac_modify_objects_role. + * Callers reference the macros qualified with the framework owner, as unqualified names in invoker rights SQL resolve in the invoker's schema. + * The owner is filled in by the SQL*Plus substitution variable ut3_owner when the package body is installed by install.sql. + */ + + /** + * Table SQL macro returning objects stored in annotation cache + * Columns: object_owner, object_name, object_type, parse_time + * + * @param a_object_owner owner of cached objects + * @param a_object_type type of cached objects + * @param a_parsed_after limit results to objects parsed after specified time only, if null - all cached objects are returned + */ + function get_cached_objects(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return varchar2 sql_macro; + +end; +/ diff --git a/source/core/annotations/ut_annotation_cache_manager.pkb b/source/core/annotations/ut_annotation_cache_manager.pkb index 1518128a2..10be118f5 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pkb +++ b/source/core/annotations/ut_annotation_cache_manager.pkb @@ -117,24 +117,6 @@ create or replace noneditionable package body ut_annotation_cache_manager as commit; end; - function get_cached_objects_list(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return ut_annotation_objs_cache_info is - l_result ut_annotation_objs_cache_info; - begin - select /*+ no_parallel */ &&ut3_owner..ut_annotation_obj_cache_info( - object_owner => i.object_owner, - object_name => i.object_name, - object_type => i.object_type, - needs_refresh => 'N', - parse_time => i.parse_time - ) - bulk collect into l_result - from &&ut3_owner..ut_annotation_cache_info i - where i.object_owner = a_object_owner - and i.object_type = a_object_type - and (i.parse_time > a_parsed_after or a_parsed_after is null); - return l_result; - end; - function get_cache_schema_info(a_object_owner varchar2, a_object_type varchar2) return t_cache_schema_info is l_result t_cache_schema_info; begin diff --git a/source/core/annotations/ut_annotation_cache_manager.pks b/source/core/annotations/ut_annotation_cache_manager.pks index ea13e0c27..a07f56e66 100644 --- a/source/core/annotations/ut_annotation_cache_manager.pks +++ b/source/core/annotations/ut_annotation_cache_manager.pks @@ -48,11 +48,6 @@ create or replace noneditionable package ut_annotation_cache_manager authid curr function get_cache_schema_info(a_object_owner varchar2, a_object_type varchar2) return t_cache_schema_info; - /** - * Returns information about all objects stored in annotation cache - */ - function get_cached_objects_list(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return ut_annotation_objs_cache_info; - /** * Resets cached information about annotations for objects on the list and updates parse_time in cache info table. * diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index c10b99708..ba1925f91 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -27,28 +27,30 @@ create or replace noneditionable package body ut_annotation_manager as end; function get_non_existing_objects( a_object_owner varchar2, a_object_type varchar2 ) return ut_annotation_objs_cache_info is + l_ut_owner varchar2(250) := ut_utils.ut_owner; l_objects_view varchar2(200) := ut_metadata.get_objects_view_name(); - l_object_to_delete ut_annotation_objs_cache_info := ut_annotation_objs_cache_info(); - l_cached_objects ut_annotation_objs_cache_info; + l_object_to_delete ut_annotation_objs_cache_info; begin - l_cached_objects := ut_annotation_cache_manager.get_cached_objects_list( a_object_owner, a_object_type ); - - if l_cached_objects is not empty then - execute immediate 'select /*+ no_parallel cardinality(i '||ut_utils.scale_cardinality(cardinality(l_cached_objects))||') */ - value(i) - from table( :l_data ) i - where - not exists ( - select 1 from '||l_objects_view||q'[ o - where o.owner = i.object_owner - and o.object_name = i.object_name - and o.object_type = i.object_type - and o.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' - and o.object_type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' - )]' - bulk collect into l_object_to_delete - using l_cached_objects; - end if; + execute immediate + 'select /*+ no_parallel */ + '||l_ut_owner||q'[.ut_annotation_obj_cache_info( + object_owner => i.object_owner, + object_name => i.object_name, + object_type => i.object_type, + needs_refresh => 'N', + parse_time => i.parse_time + ) + from ]'||l_ut_owner||q'[.ut_annotation_cache_macros.get_cached_objects( :a_object_owner, :a_object_type ) i + where not exists ( + select 1 from ]'||l_objects_view||q'[ o + where o.owner = i.object_owner + and o.object_name = i.object_name + and o.object_type = i.object_type + and o.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' + and o.object_type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' + )]' + bulk collect into l_object_to_delete + using a_object_owner, a_object_type; return l_object_to_delete; end; @@ -60,7 +62,6 @@ create or replace noneditionable package body ut_annotation_manager as l_ut_owner varchar2(250) := ut_utils.ut_owner; l_refresh_needed boolean; l_objects_view varchar2(200) := ut_metadata.get_objects_view_name(); - l_cached_objects ut_annotation_objs_cache_info; l_result ut_annotation_objs_cache_info := ut_annotation_objs_cache_info(); begin ut_event_manager.trigger_event( 'get_objects_to_refresh - start', ut_key_anyvalues().put('ut_trigger_check.is_alive()',ut_trigger_check.is_alive()) ); @@ -69,9 +70,8 @@ create or replace noneditionable package body ut_annotation_manager as if l_refresh_needed then --limit the list to objects that exist and are visible to the invoking user --enrich the list by info about cache validity - l_cached_objects := ut_annotation_cache_manager.get_cached_objects_list( a_object_owner, a_object_type, a_modified_after ); execute immediate - 'select /*+ no_parallel cardinality(i '||ut_utils.scale_cardinality(cardinality(l_cached_objects))||') */ + 'select /*+ no_parallel */ '||l_ut_owner||q'[.ut_annotation_obj_cache_info( object_owner => o.owner, object_name => o.object_name, @@ -80,7 +80,7 @@ create or replace noneditionable package body ut_annotation_manager as parse_time => c.parse_time ) from ]'||l_objects_view||' o - left join table( cast(:l_cached_objects as '||l_ut_owner||q'[.ut_annotation_objs_cache_info ) ) c + left join '||l_ut_owner||q'[.ut_annotation_cache_macros.get_cached_objects( :a_object_owner, :a_object_type, :a_parsed_after ) c on o.owner = c.object_owner and o.object_name = c.object_name and o.object_type = c.object_type @@ -93,7 +93,7 @@ create or replace noneditionable package body ut_annotation_manager as then ':a_modified_after is null' else 'o.last_ddl_time >= cast(:a_modified_after as date)' end - bulk collect into l_result using l_cached_objects, a_modified_after; + bulk collect into l_result using a_object_owner, a_object_type, a_modified_after, a_modified_after; end if; ut_event_manager.trigger_event('get_objects_to_refresh - end (count='||l_result.count||')'); return l_result; diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 0316face8..e814ad846 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -387,16 +387,14 @@ create or replace noneditionable package body ut_suite_cache_manager is end; procedure remove_missing_objs_from_cache(a_schema_name varchar2) is - l_cached_objects ut_annotation_objs_cache_info; pragma autonomous_transaction; begin - l_cached_objects := ut_annotation_cache_manager.get_cached_objects_list(a_schema_name, 'PACKAGE'); - --rows of ut_suite_cache are removed by the "on delete cascade" foreign key delete /*+ no_parallel */ from &&ut3_owner..ut_suite_cache_package i where i.object_owner = a_schema_name and not exists ( - select 1 from table(l_cached_objects) o + select 1 + from &&ut3_owner..ut_annotation_cache_macros.get_cached_objects(a_schema_name, 'PACKAGE') o where o.object_name = i.object_name ); diff --git a/source/install.sql b/source/install.sql index 519de9725..4b8c14492 100644 --- a/source/install.sql +++ b/source/install.sql @@ -42,29 +42,31 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/ut_dbms_output_cache.sql' --common utilities +-- spec @@install_component.sql 'core/types/ut_varchar2_list.tps' @@install_component.sql 'core/types/ut_varchar2_rows.tps' @@install_component.sql 'core/types/ut_integer_list.tps' @@install_component.sql 'core/types/ut_object_name.tps' -@@install_component.sql 'core/types/ut_object_name.tpb' @@install_component.sql 'core/types/ut_object_names.tps' @@install_component.sql 'core/types/ut_key_value_pair.tps' @@install_component.sql 'core/types/ut_key_value_pairs.tps' @@install_component.sql 'core/types/ut_reporter_info.tps' @@install_component.sql 'core/types/ut_reporters_info.tps' @@install_component.sql 'core/types/ut_stack.tps' -@@install_component.sql 'core/types/ut_stack.tpb' @@install_component.sql 'core/ut_utils.pks' @@install_component.sql 'core/ut_metadata.pks' @@install_component.sql 'core/ut_savepoint_seq.sql' +@@install_component.sql 'reporters/ut_ansiconsole_helper.pks' +@@install_component.sql 'api/ut_suite_item_info.tps' +@@install_component.sql 'api/ut_suite_items_info.tps' +-- body +@@install_component.sql 'core/types/ut_object_name.tpb' +@@install_component.sql 'core/types/ut_stack.tpb' @@install_component.sql 'core/ut_utils.pkb' @@install_component.sql 'core/ut_metadata.pkb' -@@install_component.sql 'reporters/ut_ansiconsole_helper.pks' @@install_component.sql 'reporters/ut_ansiconsole_helper.pkb' - -@@install_component.sql 'api/ut_suite_item_info.tps' @@install_component.sql 'api/ut_suite_item_info.tpb' -@@install_component.sql 'api/ut_suite_items_info.tps' + --event manager objects @@install_component.sql 'core/events/ut_event_item.tps' @@ -73,8 +75,8 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/events/ut_event_manager.pkb' --core types +-- spec @@install_component.sql 'core/types/ut_run_info.tps' -@@install_component.sql 'core/types/ut_run_info.tpb' @@install_component.sql 'core/types/ut_expectation_result.tps' @@install_component.sql 'core/types/ut_expectation_results.tps' @@install_component.sql 'core/types/ut_results_counter.tps' @@ -95,7 +97,6 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/types/ut_reporters.tps' @@install_component.sql 'core/types/ut_path_item.tps' @@install_component.sql 'core/types/ut_path_items.tps' - @@install_component.sql 'expectations/json_objects_specs.sql' @@install_component.sql 'expectations/matchers/ut_matcher_options_items.tps' @@install_component.sql 'expectations/matchers/ut_matcher_options.tps' @@ -103,18 +104,24 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'expectations/data_values/ut_key_anyval_pair.tps' @@install_component.sql 'expectations/data_values/ut_key_anyval_pairs.tps' @@install_component.sql 'expectations/data_values/ut_key_anyvalues.tps' +-- body +@@install_component.sql 'core/types/ut_run_info.tpb' + --session_context +-- spec @@install_component.sql 'core/session_context/ut_session_context.pks' -@@install_component.sql 'core/session_context/ut_session_context.pkb' @@install_component.sql 'core/session_context/ut_session_info.tps' +-- body +@@install_component.sql 'core/session_context/ut_session_context.pkb' @@install_component.sql 'core/session_context/ut_session_info.tpb' ---output buffer table +--output buffer +-- tables @@install_component.sql 'core/output_buffers/ut_output_buffer_info_tmp.sql' @@install_component.sql 'core/output_buffers/ut_output_buffer_tmp.sql' @@install_component.sql 'core/output_buffers/ut_output_clob_buffer_tmp.sql' ---output buffer base api +-- base api @@install_component.sql 'core/output_buffers/ut_output_data_row.tps' @@install_component.sql 'core/output_buffers/ut_output_data_rows.tps' @@install_component.sql 'core/output_buffers/ut_output_buffer_base.tps' @@ -131,7 +138,6 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex --annotations @@install_component.sql 'core/annotations/ut_trigger_check.pks' -@@install_component.sql 'core/annotations/ut_trigger_check.pkb' @@install_component.sql 'core/annotations/ut_annotation.tps' @@install_component.sql 'core/annotations/ut_annotations.tps' @@install_component.sql 'core/annotations/ut_annotated_object.tps' @@ -142,12 +148,11 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/annotations/ut_annotation_cache_schema.sql' @@install_component.sql 'core/annotations/ut_annotation_cache_info.sql' @@install_component.sql 'core/annotations/ut_annotation_cache.sql' +@@install_component.sql 'core/annotations/ut_annotation_cache_macros.pks' @@install_component.sql 'core/annotations/ut_annotation_cache_manager.pks' -@@install_component.sql 'core/annotations/ut_annotation_cache_manager.pkb' @@install_component.sql 'core/annotations/ut_annotation_parser.pks' -@@install_component.sql 'core/annotations/ut_annotation_parser.pkb' @@install_component.sql 'core/annotations/ut_annotation_manager.pks' -@@install_component.sql 'core/annotations/ut_annotation_manager.pkb' + --suite builder @@install_component.sql 'core/types/ut_suite_cache_row.tps' @@ -158,15 +163,26 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/ut_suite_cache.sql' @@install_component.sql 'core/ut_suite_tag_filter.pks' -@@install_component.sql 'core/ut_suite_tag_filter.pkb' @@install_component.sql 'core/ut_suite_cache_manager.pks' -@@install_component.sql 'core/ut_suite_cache_manager.pkb' @@install_component.sql 'core/ut_suite_builder.pks' -@@install_component.sql 'core/ut_suite_builder.pkb' --suite manager @@install_component.sql 'core/ut_suite_manager.pks' + +--code based access control +@@ut3_cbac_modify_objects_role_grants.sql + +--bodies +@@install_component.sql 'core/annotations/ut_trigger_check.pkb' +@@install_component.sql 'core/annotations/ut_annotation_cache_macros.pkb' +@@install_component.sql 'core/annotations/ut_annotation_cache_manager.pkb' +@@install_component.sql 'core/annotations/ut_annotation_parser.pkb' +@@install_component.sql 'core/annotations/ut_annotation_manager.pkb' +@@install_component.sql 'core/ut_suite_tag_filter.pkb' +@@install_component.sql 'core/ut_suite_cache_manager.pkb' +@@install_component.sql 'core/ut_suite_builder.pkb' @@install_component.sql 'core/ut_suite_manager.pkb' + --expectations execution state interface @@install_component.sql 'core/ut_expectation_processor.pks' @@install_component.sql 'core/ut_expectation_processor.pkb' @@ -380,8 +396,6 @@ prompt Installing DBMSPLSQL Tables objects into &&ut3_owner schema @@install_component.sql 'api/match.syn' @@install_component.sql 'api/contain.syn' -@@ut3_cbac_modify_objects_role_grants.sql - set linesize 200 set define on column text format a100 diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 79efe9ca9..13125dc13 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -240,6 +240,8 @@ drop package ut_annotation_parser; drop package ut_annotation_cache_manager; +drop package ut_annotation_cache_macros; + drop table ut_annotation_cache cascade constraints purge; drop table ut_annotation_cache_info cascade constraints purge; diff --git a/source/ut3_cbac_modify_objects_role_grants.sql b/source/ut3_cbac_modify_objects_role_grants.sql index 58e151080..0447f9e8e 100644 --- a/source/ut3_cbac_modify_objects_role_grants.sql +++ b/source/ut3_cbac_modify_objects_role_grants.sql @@ -14,8 +14,9 @@ See the License for the specific language governing permissions and limitations under the License. - Code based access control for the invoker rights packages ut_annotation_cache_manager and ut_suite_cache_manager. + Code based access control for the invoker rights packages ut_annotation_cache_manager, ut_annotation_manager and ut_suite_cache_manager. The packages access the annotation and suite cache tables through the role _cbac_modify_objects_role, + directly or through the SQL macros of ut_annotation_cache_macros, so the users calling the framework do not need any privileges on those tables. The types and packages used in SQL statements of those packages are granted to the role too, so they do not need to be granted to the users calling the framework. @@ -32,6 +33,7 @@ grant execute on &&ut3_owner..ut_annotation_obj_cache_info to &&ut3_owner._cbac_ grant execute on &&ut3_owner..ut_annotated_object to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_annotation to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_annotations to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_annotation_cache_macros to &&ut3_owner._cbac_modify_objects_role; --suite cache grant select, insert, update, delete on &&ut3_owner..ut_suite_cache to &&ut3_owner._cbac_modify_objects_role; @@ -50,7 +52,6 @@ grant execute on &&ut3_owner..ut_object_name to &&ut3_owner._cbac_modify_ob grant execute on &&ut3_owner..ut_utils to &&ut3_owner._cbac_modify_objects_role; grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_cache_manager; +grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_manager; grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_suite_cache_manager; ---granting a role to a package invalidates the package and the objects depending on it -exec dbms_utility.compile_schema(schema => upper('&&ut3_owner'), compile_all => false); From 1d2ae2c0dc5bc90cd023a25382bc554b06480b17 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 00:51:59 +0200 Subject: [PATCH 820/887] Attempting to fix compilation issues on 19c and 21c --- source/core/annotations/ut_annotation_manager.pkb | 2 +- source/core/ut_suite_cache_manager.pkb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index ba1925f91..27c4c9c8b 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -40,7 +40,7 @@ create or replace noneditionable package body ut_annotation_manager as needs_refresh => 'N', parse_time => i.parse_time ) - from ]'||l_ut_owner||q'[.ut_annotation_cache_macros.get_cached_objects( :a_object_owner, :a_object_type ) i + from (]'||l_ut_owner||q'[.ut_annotation_cache_macros.get_cached_objects( :a_object_owner, :a_object_type, null )) i where not exists ( select 1 from ]'||l_objects_view||q'[ o where o.owner = i.object_owner diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index e814ad846..503fd92fe 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -394,7 +394,7 @@ create or replace noneditionable package body ut_suite_cache_manager is where i.object_owner = a_schema_name and not exists ( select 1 - from &&ut3_owner..ut_annotation_cache_macros.get_cached_objects(a_schema_name, 'PACKAGE') o + from (&&ut3_owner..ut_annotation_cache_macros.get_cached_objects(a_schema_name, 'PACKAGE', null)) o where o.object_name = i.object_name ); From a917cf7e6ae6ba10c39fd883428996bffd493f96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 01:17:22 +0200 Subject: [PATCH 821/887] Update build to use docker image 19.20 Update of documentation. --- .github/workflows/build.yml | 2 +- CONTRIBUTING.md | 2 +- docs/userguide/install.md | 4 +++- readme.md | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 011c14bf8..48da176ae 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -39,7 +39,7 @@ jobs: - id: 1 db_version_name: '19se' oracle-sid: 'ORCLCDB' - oracle-version: "utplsqlv3/oracledb:19c-se2-small" + oracle-version: "utplsqlv3/oracledb:19.20-small" check-coding-style: true validate-utplsql-uninstall: true - id: 2 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 5b3ca6a35..0c7de58c9 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -41,7 +41,7 @@ Not able to contribute code? You can also support the project through [sponsorsh # Configuring local environment Your local environment can be of any flavor (Unix/Linux/Windows/Mac). -At minimum, you need to have Oracle database 19c accessible for the project and SYS account access to install and develop utPLSQL. +At minimum, you need to have Oracle database 19c (we use Release Update 19.20 or later) accessible for the project and SYS account access to install and develop utPLSQL. We use five different database accounts (users) for development process. * `ut3` - holds latest released version of utPLSQL. This schema holds the testing framework used for self-testing of utPLSQL development. diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 7f1d9cf82..1de35c0d3 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -2,7 +2,9 @@ ## Supported database versions -- Oracle Database 19c or newer (SE/EE/Cloud/Free) +- Oracle Database 19c with Release Update 19.20 or later, or any newer version (SE/EE/Cloud/Free) + +utPLSQL uses SQL macros. Earlier 19c Release Updates are not verified and supported. We do our best to assure full compatibility with **actively supported** versions of Oracle databases. See [this page](https://www.oracle.com/us/support/library/lifetime-support-technology-069183.pdf#page=6) for Oracle Database Releases and their Support Lifetime by Oracle. diff --git a/readme.md b/readme.md index a0f74c8cc..f0843b511 100644 --- a/readme.md +++ b/readme.md @@ -29,7 +29,7 @@ utPLSQL is a unit testing framework for Oracle PL/SQL and SQL, following industr ## Requirements -- Oracle Database 19c or newer +- Oracle Database 19c with Release Update 19.20 or later, or any newer version (we are testing on 19.20, 21 XE and 23 free ) ## Installation From ab35529bde79696c5e812552fe6eae4811ab9578 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 01:42:16 +0200 Subject: [PATCH 822/887] Fixing 21XE access for SQL MACROS --- source/create_grants.sql | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/source/create_grants.sql b/source/create_grants.sql index 6cc7f6b37..010bbe322 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -64,6 +64,11 @@ grant execute on &&ut3_owner..ut_suite_cache_rows to &ut3_user; grant execute on &&ut3_owner..ut_run_info to &ut3_user; grant execute on &&ut3_owner..ut_coverage_options to &ut3_user; +--SQL macros used in SQL statements of the framework. +--On Oracle 21c XE, expanding a macro requires the calling user to have execute privilege on it. +--The macros only return SQL text; the tables they reference stay accessible only through the code based access control role. +grant execute on &&ut3_owner..ut_annotation_cache_macros to &ut3_user; + --generic types grant execute on &&ut3_owner..ut_varchar2_list to &ut3_user; grant execute on &&ut3_owner..ut_varchar2_rows to &ut3_user; From 134c7f0031515149b204a8687a6cc3e366fc14d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 08:51:07 +0200 Subject: [PATCH 823/887] Changed 19.20 image --- .github/workflows/build.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 48da176ae..046d9f964 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -37,9 +37,9 @@ jobs: matrix: include: - id: 1 - db_version_name: '19se' - oracle-sid: 'ORCLCDB' - oracle-version: "utplsqlv3/oracledb:19.20-small" + db_version_name: '19.20-ee' + oracle-sid: 'UTPLSQL' + oracle-version: "utplsqlv3/oracledb:19.20-utplsql" check-coding-style: true validate-utplsql-uninstall: true - id: 2 From 4d6be442a200527b7c727b6c9c712ebdcab9331d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 09:32:16 +0200 Subject: [PATCH 824/887] Update of ut_annotation_cache_info structure and get_cached_objects for performance. --- source/core/annotations/ut_annotation_cache_info.sql | 4 ++-- source/core/annotations/ut_annotation_cache_macros.pkb | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/source/core/annotations/ut_annotation_cache_info.sql b/source/core/annotations/ut_annotation_cache_info.sql index d8d9ab663..4600af793 100644 --- a/source/core/annotations/ut_annotation_cache_info.sql +++ b/source/core/annotations/ut_annotation_cache_info.sql @@ -17,8 +17,8 @@ create table ut_annotation_cache_info ( object_name varchar2(250) not null, object_type varchar2(250) not null, parse_time timestamp not null, - constraint ut_annotation_cache_info_pk primary key(cache_id) using index, - constraint ut_annotation_cache_info_uk unique (object_owner, object_type, object_name) using index, + constraint ut_annotation_cache_info_pk primary key(object_owner, object_type, object_name) using index, + constraint ut_annotation_cache_info_uk unique (cache_id) using index, constraint ut_annotation_cache_info_fk foreign key(object_owner, object_type) references ut_annotation_cache_schema(object_owner, object_type) on delete cascade ) organization index; diff --git a/source/core/annotations/ut_annotation_cache_macros.pkb b/source/core/annotations/ut_annotation_cache_macros.pkb index 38e59b9ab..bbd2422f3 100644 --- a/source/core/annotations/ut_annotation_cache_macros.pkb +++ b/source/core/annotations/ut_annotation_cache_macros.pkb @@ -19,11 +19,11 @@ create or replace noneditionable package body ut_annotation_cache_macros as function get_cached_objects(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return varchar2 sql_macro is begin return q'[ - select i.object_owner, i.object_name, i.object_type, i.parse_time + (select /*+ NO_UNNEST */ i.object_owner, i.object_name, i.object_type, i.parse_time from &&ut3_owner..ut_annotation_cache_info i where i.object_owner = a_object_owner and i.object_type = a_object_type - and (i.parse_time > a_parsed_after or a_parsed_after is null)]'; + and (i.parse_time > a_parsed_after or a_parsed_after is null))]'; end; end; From 05ab74237c3876469003804ca1c8558c32a4106e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 09:41:51 +0200 Subject: [PATCH 825/887] Update of get_cached_objects for performance. --- source/core/annotations/ut_annotation_cache_macros.pkb | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/source/core/annotations/ut_annotation_cache_macros.pkb b/source/core/annotations/ut_annotation_cache_macros.pkb index bbd2422f3..f12b62da6 100644 --- a/source/core/annotations/ut_annotation_cache_macros.pkb +++ b/source/core/annotations/ut_annotation_cache_macros.pkb @@ -19,11 +19,13 @@ create or replace noneditionable package body ut_annotation_cache_macros as function get_cached_objects(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return varchar2 sql_macro is begin return q'[ - (select /*+ NO_UNNEST */ i.object_owner, i.object_name, i.object_type, i.parse_time + select /*+ NO_UNNEST NO_EXPAND */ i.object_owner, i.object_name, i.object_type, i.parse_time from &&ut3_owner..ut_annotation_cache_info i where i.object_owner = a_object_owner - and i.object_type = a_object_type - and (i.parse_time > a_parsed_after or a_parsed_after is null))]'; + and i.object_type = a_object_type]' + ||case when a_parsed_after is not null then q'[ + and i.parse_time > a_parsed_after]' + end; end; end; From 106a75a8e953c8ab01f615ea95f0e26a82785c26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 10:12:12 +0200 Subject: [PATCH 826/887] Update 19c image to version 19.20-ee --- .github/workflows/build.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 011c14bf8..046d9f964 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -37,9 +37,9 @@ jobs: matrix: include: - id: 1 - db_version_name: '19se' - oracle-sid: 'ORCLCDB' - oracle-version: "utplsqlv3/oracledb:19c-se2-small" + db_version_name: '19.20-ee' + oracle-sid: 'UTPLSQL' + oracle-version: "utplsqlv3/oracledb:19.20-utplsql" check-coding-style: true validate-utplsql-uninstall: true - id: 2 From 880b692838890e947ae2cf16ca23057da8d3b867 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 9 Nov 2026 08:22:09 +0000 Subject: [PATCH 827/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 5b9e54fbb..9bcafcbd6 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4581 +4600 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 3602a5447..e7c01e72d 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4581-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4600-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 22a2c233f2a1950cc628fffa8eb835e9b1017207 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 23:09:54 +0200 Subject: [PATCH 828/887] Remove a_parsed_after from the get_cached_objects SQL macro The freshness check in get_objects_to_refresh is simplified to (c.parse_time is null or o.last_ddl_time >= cast(c.parse_time as date)). --- .../suite_cache_collection_patterns.md | 355 ++++++++++++++++++ .../ut_annotation_cache_macros.pkb | 7 +- .../ut_annotation_cache_macros.pks | 3 +- .../annotations/ut_annotation_manager.pkb | 8 +- source/core/ut_suite_cache_manager.pkb | 2 +- 5 files changed, 363 insertions(+), 12 deletions(-) create mode 100644 development/suite_cache_collection_patterns.md diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md new file mode 100644 index 000000000..aa76e361e --- /dev/null +++ b/development/suite_cache_collection_patterns.md @@ -0,0 +1,355 @@ +# Suite cache: collection hand-off patterns + +How `ut_suite_cache_manager` and its callers move suite data between SQL statements through PL/SQL collections instead of joining tables directly, why that happens, and how to simplify it with the two tools now on the branch: code based access control (CBAC) and table SQL macros. + +Revised on 2026-11-09 for the CBAC + SQL macro strategy, against branch `feature/code_based_access_control` at commit `05ab7423`. Line references point to that commit. Apart from the macro checks under [Rules for SQL macros](#rules-for-sql-macros-verified), nothing was measured on a live database. Statements marked **verify** need a test or a trace before anyone acts on them. + +## Status at a glance + +| Pattern | What it is | Status | Approach | +|---|---|---|---| +| P1 | access filter applied to a collection by the caller | open | access predicate in the `ut_suite_cache` query, plain SQL in `ut_suite_cache_manager` (CBAC) | +| P2 | chain of collection → collection functions | open | one statement with named CTEs | +| P3 | logical suites appended to a collection | open | CTE of the main statement | +| P4 | sort by self-join of a collection | open | last CTE of the main statement | +| P5 | paths reconciled against a collection | open | keep, over the single final result | +| P6 | collection → ref cursor → collection | open | pass the collection, no cursor | +| P7 | two scans of `ut_suite_cache` for path matching | open | one path-matching CTE | +| P8 | list handed between the two cache modules | **done** | table SQL macro `ut_annotation_cache_macros.get_cached_objects` | +| P9 | full rows loaded only to project scalars | open | Flow B reuses the main statement and projects | +| P10 | PL/SQL objects inserted through `table()` | keep | legitimate | +| P11 | short scalar lists joined in SQL | keep | legitimate | +| new | `get_cached_objects` branched on an argument's value | **done** | parameter removed (step 0) | + +## Strategy: what CBAC and SQL macros are for + +Until the CBAC commits, `ut_suite_cache_manager` and `ut_annotation_cache_manager` were `authid definer`. They could read the private cache tables, but `all_objects` inside them showed what the **framework owner** sees, not the **invoking user**. So the access checks ran in invoker-rights code (`ut_suite_manager`, `ut_annotation_manager`), which couldn't read the cache tables. The definer package selected cache rows into a collection, and the invoker package filtered that collection with `table(:coll)`. Most patterns below come from that split, or from code built around its output. + +| Package | Before CBAC | Now | +|---|---|---| +| `ut_suite_cache_manager` | `authid definer` | `authid current_user` + CBAC role | +| `ut_annotation_cache_manager` | `authid definer` | `authid current_user` + CBAC role | +| `ut_annotation_manager` | `authid current_user` | unchanged + CBAC role (for the macro) | +| `ut_annotation_cache_macros` | did not exist | `authid definer` (macros can't be in invoker-rights packages) | +| `ut_suite_manager` | `authid current_user` | unchanged, no role | +| `ut_suite_tag_filter` | `authid definer` | unchanged, touches no tables | + +The two tools solve different problems: + +- **CBAC removes the reason for the split.** A cache manager now runs as the invoker and still reads its own tables. So one SQL statement inside it can join `ut_suite_cache` with `all_objects` as the invoking user sees it. **Within the module that owns the tables, use plain SQL.** It is compile-checked, needs no extra grants, and the optimizer sees real tables. +- **A table SQL macro is a cache module's read API for SQL owned by another module.** Use one only when a statement that belongs to another package must read the cache tables in the same statement. On the branch that is two places, both reading the annotation cache: + - the `delete` in `ut_suite_cache_manager.remove_missing_objs_from_cache`; + - the dynamic SQL in `ut_annotation_manager`, which joins the cache with `all_objects` / `dba_objects`. + + A macro costs: + - a definer-rights package; + - EXECUTE grants to the role and to the framework users; + - the CBAC role on every caller; + - the specs → grants → bodies install order. + + Add one only when such a cross-module read is needed (YAGNI). + +**What this means for the suite read path.** Every cache read in Flows A and B already sits in `ut_suite_cache_manager`, so P1–P7 and P9 need no new macro. Only CBAC is needed, and it is already in place. `ut_suite_manager` keeps no role and names no cache table. + +Rejected alternative: a `ut_suite_cache_macros` package that `ut_suite_manager` composes into its own statement. It would spread the role to `ut_suite_manager` and move knowledge of the cache's structure out of the module that owns it. It would also add a third macro grant, for no gain over a statement inside `ut_suite_cache_manager`. + +## Rules for SQL macros (verified) + +Consolidated from the checks on 19.20 EE, 21.3 XE and 23ai Free (2026-11-09). + +1. **Table macros only.** The project requires 19c RU 19.20 or later. Table macros exist from 19.7, so they are available everywhere the framework runs. Scalar macros are not used. +2. **A macro can't live in an invoker-rights package.** Compiling one there fails with `PLS-00782`. Put macros in a separate `authid definer` package, such as `ut_annotation_cache_macros`. +3. **Callers need the CBAC role at compile time and at run time.** The macro is executed while the calling body compiles. `install.sql` therefore installs the specs, then runs [ut3_cbac_modify_objects_role_grants.sql](../source/ut3_cbac_modify_objects_role_grants.sql), then installs the bodies. With the old order, the bodies failed with `ORA-62565` / `PLS-00201`. The exact compile-time rule Oracle applies is an inference: one manual SYS compile succeeded without the role. The install order is the verified fix. +4. **Users need EXECUTE on the macro package.** On 21c XE, expanding a macro checks the calling user's own EXECUTE privilege. Without it the call fails with `ORA-62565` / `PLS-00904`. The role held by the calling package doesn't count there; on 19.20 and 23ai it was enough. + - [create_grants.sql](../source/create_grants.sql) therefore grants `execute on ut_annotation_cache_macros`. + - The grant exposes no data. A user with it still gets `ORA-01031` from the macro and from the table directly. + - Every new macro package needs this grant, in addition to the role grant. +5. **The macro body sees an argument's value only when it is a literal.** For a PL/SQL variable or a bind variable, the body sees NULL; the value is bound only into the returned SQL text. Verified on 19.20 with a probe macro: + + | Call | Value seen in the macro body | + |---|---| + | literal `timestamp '2026-01-01 00:00:00'` | the value | + | PL/SQL variable in static SQL | NULL | + | bind in `execute immediate ... using` | NULL | + + So the body must not branch on argument values. Conditions go into the returned SQL text, for example `(a_x is null or col > a_x)`. This also matters for cursor sharing: the text is built once per call site, at hard parse. +6. **Collections can be arguments.** `from macro(sys.odcivarchar2list('a','b','c'))`, with `table(a_list)` in the macro text, returned 3 rows on 19.20. Not checked with framework types such as `ut_path_items`. The suite plan below doesn't need it. +7. **Qualify framework objects in the macro text** with `&&ut3_owner.`. The text is expanded into the caller's statement, and the caller is invoker rights. +8. **SYS can't call the macro directly.** It fails with `ORA-06598: insufficient INHERIT PRIVILEGES privilege`. This doesn't affect normal use. + +## New finding: `get_cached_objects` branches on an argument's value + +Commit `05ab7423` changed [ut_annotation_cache_macros.pkb:19](../source/core/annotations/ut_annotation_cache_macros.pkb:19) from the predicate `(i.parse_time > a_parsed_after or a_parsed_after is null)` to adding `and i.parse_time > a_parsed_after` only when `a_parsed_after is not null`. By rule 5, the effect depends on the caller: + +- `remove_missing_objs_from_cache` passes the literal `null`. There is no filter, which is correct. +- `ut_annotation_manager.get_objects_to_refresh` passes the bind `:a_parsed_after`. The body sees NULL, so **the filter is never added**, even when `a_modified_after` has a value. + +The results don't change. The outer query keeps a row when `o.last_ddl_time >= a_modified_after` and not `o.last_ddl_time < c.parse_time`. A cache row with `parse_time <= a_modified_after` can't fail the second test for an object that passes the first. With or without the filter, the same objects come back. Only the `parse_time` attribute of the returned list differs: it is now filled where the filter used to leave it null. No caller reads that attribute: `reset_objects_cache` and `get_sources_to_annotate` use only the names and `needs_refresh`. So the filter only trims the join input, and the commit's performance intent is not reached. + +Resolved in step 0: `a_parsed_after` is removed from the macro, which keeps today's behaviour and simplifies the code. If a measurement later shows that the filter helps, restore it in the bind-safe form `(a_parsed_after is null or i.parse_time > a_parsed_after)`, which works for binds and literals. Rule 5 is now in the spec comment of `ut_annotation_cache_macros`. + +## Data types involved + +| Type | Shape | Notes | +|---|---|---| +| `ut_path_items` / `ut_path_item` | `schema_name, object_name, procedure_name, suite_path` | parsed run paths | +| `ut_suite_cache_rows` / `ut_suite_cache_row` | 22 attributes, the row type of table `ut_suite_cache` | **heavy**: 6 × `ut_executables`, 3 × `ut_varchar2_rows`, 1 × `ut_executable_test` | +| `ut_suite_items_info` | 10 scalars + `tags` | public output of `get_suites_info` | +| `ut_suite_items` | PL/SQL object tree (`ut_suite`, `ut_test`, ...) | built by `ut_suite_builder`, written by `save_object_cache` | +| `ut_annotation_objs_cache_info` | owner, name, type, `needs_refresh`, `parse_time` | lists of objects to refresh or remove | + +Every `select value(c) ... bulk collect into ... from table(:coll) c` deep-copies each `ut_suite_cache_row`, nested tables included. Steps that only filter or reorder rows still copy all of their data. + +## Flows + +### Flow A: run (`ut_runner.run` → `ut_suite_manager.configure_execution_by_path`) + +``` +a_paths (ut_varchar2_list) + │ resolve_schema_names PL/SQL loop, normalises paths [suite_manager:52] + │ refresh_cache per schema see Flow C + ▼ + get_schema_paths [cache_manager:251] + │ group_paths_by_schema PL/SQL loop → ut_path_items [cache_manager:71] + │ expand_paths SQL: table(paths) ⟕ ut_suite_cache → ut_path_items [cache_manager:109] ① scan of ut_suite_cache + ▼ + get_cached_suite_data [suite_manager:352] + │ get_suite_items SQL: ut_suite_cache ⋈ table(paths) → rows [cache_manager:180] ② scan of ut_suite_cache, copy #1 + │ ut_suite_tag_filter.apply dynamic SQL over table(rows) → rows [tag_filter:268] copy #2 (only with tags) + │ get_cached_suite_rows SQL over table(rows) + generated logical suites [cache_manager:256] copy #3 + │ get_filtered_cursor SQL over table(rows) ⋈ all_objects → rows [suite_manager:299] copy #4 (unless EXECUTE ANY) + │ reconcile_paths_and_suites SQL: table(paths) ⟕ table(rows) → raise errors [suite_manager:328] + │ sort_and_randomize_tests recursive SQL over table(rows) ⋈ table(rows) → rows [cache_manager:214] copy #5 + │ open cursor for select * from table(rows) [suite_manager:371] copy #6 (fetch) + ▼ + reconstruct_from_cache bulk fetch limit 1000 → tt_cached_suites → object tree [suite_manager:253] +``` + +The cache table is read twice with nearly the same matching rules. The result set is then copied 4 to 6 times, through 5 SQL statements over `table()` collections, before it becomes the object tree. Unchanged since the CBAC commits. + +### Flow B: suite info (`ut_runner.get_suites_info`, `ut_runner.has_suites`, ...) + +``` +a_paths → resolve_schema_names → refresh_cache per schema → get_schema_paths (①) [suite_manager:566] + │ get_cached_suite_info = get_cached_suite_rows(get_suite_items(paths)) (②, copies #1, #2) [cache_manager:404] + │ get_filtered_cursor (copy #3) + │ get_suite_items_info SQL over table(rows) → ut_suite_items_info (copy #4, projection) [cache_manager:411] + ▼ + open cursor select value(c) from table(info) order by owner, name, line_no +``` + +Full rows, with all six executable lists, are loaded and copied three times, only to be projected to 10 scalar columns at the end. Tags are not applied here and the rows are not sorted. + +### Flow C: cache refresh (`ut_suite_manager.refresh_cache`, [suite_manager:426](../source/core/ut_suite_manager.pkb:426)) + +``` +get_schema_parse_time(owner) scalar +ut_annotation_manager.get_annotated_objects(...) sys_refcursor of ut_annotated_object +build_and_cache_suites [suite_manager:383] + │ fetch limit 10 → ut_annotated_objects + │ per object: ut_suite_builder.create_suite_item_list → ut_suite_items (PL/SQL) + │ per object: save_object_cache(ut_suite_items) [cache_manager:279] + │ autonomous tx: 2 × insert ... select from table(a_suite_items) with treat() +remove_missing_objs_from_cache(owner) one delete, macro (P8, done) [cache_manager:389] +``` + +### Flow D: smaller lookups + +- `get_schema_ut_packages` → `get_cached_packages(ut_varchar2_rows)`: joins a short list of schema names with `ut_suite_cache_package` (P11). +- `suite_item_exists`: a scalar lookup in the cache manager, plus a separate `all_objects` check in [suite_manager:612](../source/core/ut_suite_manager.pkb:612). After step 3, the access predicate can move into the cache manager's query here too. Optional. + +### The annotation flow (out of scope, checked) + +After P8, `ut_annotation_manager` still passes `ut_annotation_objs_cache_info` lists: + +- `get_non_existing_objects` → `remove_from_cache`; +- `get_objects_to_refresh` → `reset_objects_cache` and `get_sources_to_annotate`. + +These are legitimate: + +- The first list holds only dropped objects, so it is short. +- The second is used three times (count, reset, source query), so one materialisation is the cheaper form. + +No change is planned. + +## Pattern catalogue + +### P1: select into a collection, filter by access in the caller + +- **Where:** `get_suite_items` / `get_cached_suite_rows` (cache manager) → `get_filtered_cursor` ([ut_suite_manager.pkb:299](../source/core/ut_suite_manager.pkb:299)). +- **What:** cache rows are returned unfiltered ("Returned data is not filtered by user access rights" in the spec). The caller filters the collection against `all_objects`. +- **Why it exists:** the definer/invoker split. CBAC removed it. +- **Cost:** + - A full copy of the result set, plus a union of two scans of the same collection. + - Logical suites are exempted (`or c.self_type = 'UT_LOGICAL_SUITE'`) because they are generated before the filter runs. **Verify:** this can leave logical suites with no accessible children in the tree. +- **Name:** `get_filtered_cursor` is misleading: it returns a collection, not a cursor. +- **Approach:** put the access predicate into the `ut_suite_cache` query inside `ut_suite_cache_manager`. That is plain SQL; no macro is needed. The EXECUTE ANY / `a_skip_all_objects` decision comes in as a bind flag in the SQL text (rule 5 doesn't apply here, but the same style keeps one cursor): + ```sql + where ( :skip_access_check = 'Y' + or c.object_owner = sys_context('userenv','current_user') + or exists (select 1 from all_objects a + where a.owner = c.object_owner and a.object_name = c.object_name + and a.object_type = 'PACKAGE') ) + ``` + Logical suites are then generated from accessible suites only, and the exemption goes away. + +### P2: chain of collection-to-collection transforms + +- **Where:** Flow A, copies #1 → #5. Each step is a function `f(ut_suite_cache_rows) return ut_suite_cache_rows` with one `select ... from table(:coll)`. +- **Cost:** + - Repeated deep copies of heavy objects. + - No predicate pushing across steps. + - Unknown `table()` cardinality: only two statements carry a fixed `cardinality(c 500)` hint. + - `value(c)` is moved around instead of columns. +- **Approach:** one statement in `ut_suite_cache_manager`, with each step as a named CTE. It carries columns, not objects, and builds `ut_suite_cache_row` only in the final select. It is dynamic SQL because of the tag predicate (see the target design). `ut_suite_tag_filter` keeps only the predicate builder. + +### P3: enrich a collection with generated rows + +- **Where:** cursor `c_get_bulk_cache_suite` ([ut_suite_cache_manager.pkb:22](../source/core/ut_suite_cache_manager.pkb:22)), used by `get_cached_suite_rows`. +- **What:** logical suites (path prefixes with no package behind them) are derived from the selected suites and appended with `union all`, through a full object constructor with null-cast executables. +- **Notes:** + - Path depth is capped by `xmltable('1 to 20')`. **Verify** what happens beyond 20 levels: logical parents above level 20 would be missing. + - Levels are counted with `regexp_count(path, '\w+')`, which does not count `$` and `#`, both allowed in path parts. +- **Approach:** a CTE of the main statement, placed after the access and tag filters. + +### P4: in/out collection reorder with a self-join + +- **Where:** `sort_and_randomize_tests` ([ut_suite_cache_manager.pkb:214](../source/core/ut_suite_cache_manager.pkb:214)). +- **What:** a recursive CTE walks the hierarchy over `table(a_suite_rows)`, then joins back to `table(a_suite_rows)` to recover the objects. The result is copied and assigned back to the in/out parameter. +- **Cost:** two scans of the collection plus one copy. `ut_utils.hash_suite_path` is called from SQL for each row (`ut_utils` is granted to the role). +- **Approach:** the last CTE of the main statement, with `order by order1 desc` as the final `order by`. + +### P5: validate by joining two collections + +- **Where:** `reconcile_paths_and_suites` ([ut_suite_manager.pkb:328](../source/core/ut_suite_manager.pkb:328)). +- **What:** expanded paths are left-joined to the final rows to find paths that matched nothing. The first one raises an error. +- **Note:** this runs **after** the tag and access filters. As the code reads, a package path whose tests are all excluded by tags raises "Suite package ... does not exist". **Verify** whether this is intended and covered by tests (open question 1). Any reordering must keep this behaviour. +- **Approach:** keep it as one small check over the single final collection. It is cheap once P2 is done. + +### P6: collection → ref cursor → collection + +- **Where:** `get_cached_suite_data` opens `select * from table(l_filtered_rows)` ([ut_suite_manager.pkb:371](../source/core/ut_suite_manager.pkb:371)). `reconstruct_from_cache` fetches it back in batches of 1000. +- **What:** a fully materialised collection is wrapped in a cursor and unwrapped again. `limit 1000` saves no memory. +- **Approach:** pass the collection straight to `reconstruct_from_cache`. This also removes the `c_cached_suites_cursor` / `tt_cached_suites` / `t_cached_suites_cursor` plumbing. Pure PL/SQL, no privilege change. + +### P7: two passes over `ut_suite_cache` for path resolution + +- **Where:** `expand_paths` ([ut_suite_cache_manager.pkb:109](../source/core/ut_suite_cache_manager.pkb:109)) and `get_suite_items` ([ut_suite_cache_manager.pkb:180](../source/core/ut_suite_cache_manager.pkb:180)). +- **What:** `expand_paths` resolves wildcards into concrete paths (4 CTEs, `union all`, `row_number` dedup), back into a collection. `get_suite_items` then joins that with `ut_suite_cache` again, with similar `like`/`nvl` matching and another dedup. +- **Cost:** two scans, and three places that encode "how a path matches a cache row" (`expand_paths`, `get_suite_items`, `reconcile_paths_and_suites`), each slightly differently. This is the hardest part of the code to reason about. +- **Note:** the `where` clause of `get_suite_items` mixes `and`/`or` without full parentheses. It works because `null || '.%'` can't match a real path, not because of the structure. +- **Approach:** one "path → matching cache rows" CTE in the main statement, with one definition of the matching rules. `group_paths_by_schema` stays a PL/SQL parser, and its `ut_path_items` stays a bind (P11). `reconcile` uses the same CTE (paths with no match). + +### P8: list handed over between two cache modules (done) + +- **Before:** `ut_annotation_cache_manager.get_cached_objects_list` returned a collection. The not-cached package names went into a second collection, which drove two `delete ... in (table())`. +- **Now:** one `delete` from `ut_suite_cache_package` ([ut_suite_cache_manager.pkb:389](../source/core/ut_suite_cache_manager.pkb:389)). It reads the annotation cache through `ut_annotation_cache_macros.get_cached_objects` and relies on the `on delete cascade` FK for `ut_suite_cache`. `get_missing_cache_objects` and `get_cached_objects_list` are gone. +- **Follow-up, also done:** `ut_annotation_manager.get_non_existing_objects` and `get_objects_to_refresh` select from the same macro in their dynamic SQL, joined directly with `all_objects` / `dba_objects`. No collection is bound, and the `cardinality` hints are gone. `ut_annotation_cache_info` became an index-organised table keyed by `(object_owner, object_type, object_name)` (commit `4d6be442`), which matches the macro's predicate. +- **Step 0, done:** the macro takes only `(a_object_owner, a_object_type)`; the `a_parsed_after` branch is gone (see the new finding). + +### P9: full rows loaded only to project scalars + +- **Where:** Flow B: `get_cached_suite_info` → `get_filtered_cursor` → `get_suite_items_info`. +- **What:** `ut_suite_cache_row` objects, with all executable lists, are built and copied only to produce `ut_suite_item_info`. +- **Approach:** after P1/P2/P7, Flow B runs the same statement text as Flow A, without tags or randomisation. It differs only in the final select (`ut_suite_item_info(...)`, ordered by owner, name and line). The statement is built in one private function, and the two flows add their own final select (DRY). `get_cached_suite_info` and `get_suite_items_info` then leave the spec (Interface Segregation). + +### P10: PL/SQL-built objects written through `table()` (legitimate) + +- **Where:** `save_object_cache` ([ut_suite_cache_manager.pkb:279](../source/core/ut_suite_cache_manager.pkb:279)). +- `ut_suite_builder` builds object trees in PL/SQL, and inserting them through `table(a_suite_items)` with `treat()` is the natural way to persist them. **Keep it.** +- Optional: the two `insert ... select` statements (suites and contexts, then tests) could become one, at some cost to readability. +- The `delete` before the inserts must stay. The package row is updated, not re-created, so the FK cascade doesn't fire there. + +### P11: short scalar lists joined in SQL (legitimate) + +`get_cached_packages(table(a_schema_names))` and the path list are small lists of user input, joined in SQL. **Keep them.** + +## Smaller findings seen along the way + +1. **Rollback type is set twice.** `reconstruct_from_cache` calls `set_rollback_type` on top-level suites ([ut_suite_manager.pkb:293](../source/core/ut_suite_manager.pkb:293)), then `configure_execution_by_path` does it again ([ut_suite_manager.pkb:559](../source/core/ut_suite_manager.pkb:559)). +2. **Duplicated prologue.** `configure_execution_by_path` and `get_suites_info` both do "resolve schema names → refresh cache per schema → `get_schema_paths`". This could be one private procedure. +3. **Two near-identical checks.** `can_skip_all_objects_scan` ([ut_suite_manager.pkb:376](../source/core/ut_suite_manager.pkb:376)) and the `user_has_execute_any_proc() or a_skip_all_objects` test in `get_filtered_cursor` cover almost the same check. After step 3, one function computes the skip flag. +4. **`get_logical_suite` repeats constructor calls.** It holds 7 constructor calls that differ only in `items =>`. Choosing `items` first would cut it to 4. +5. **Possible stale items on a bad suitepath (verify).** In `build_and_cache_suites` ([ut_suite_manager.pkb:398](../source/core/ut_suite_manager.pkb:398)), when `create_suite_item_list` raises `ex_string_too_small`, `save_object_cache` still runs with `l_suite_items`. That parameter is `out nocopy`, so it may hold partial or previous-object items. +6. **Arbitrary `row_number` order.** `get_suite_items` deduplicates with `order by path, object_owner` inside a partition by the same columns. That is fine only because the duplicates are identical rows. + +## Target design + +``` +ut_suite_manager (invoker, no role) ut_suite_cache_manager (invoker + CBAC) +----------------------------------- -------------------------------------- +resolve paths, refresh cache ──paths, tags──▶ get_suite_rows(a_paths, a_tags, a_random_seed, a_skip_access_check) + one dynamic statement (tag predicate or 1 = 1), CTEs: + path_items table(:paths), wildcards expanded ← P7 + matched_rows ut_suite_cache ⋈ path_items + + access predicate (all_objects) ← P1 + tagged_rows tag predicate from the tag filter ← P2 + with_logical generated logical suites ← P3 + ordered recursive sort / randomise ← P4 + ◀──rows────── ut_suite_cache_rows, built once in the final select +reconcile(paths, rows) ← P5 +reconstruct_from_cache(rows) no ref cursor ← P6 + +get_suites_info ──paths──────▶ get_suite_info(a_paths, a_skip_access_check) + the same statement text, no tags, no sort, + ◀──cursor──── final select ut_suite_item_info, ordered ← P9 + +ut_suite_tag_filter: only create_where_filter (tag expression → SQL predicate). apply / get_tags_suites go. +ut_annotation_cache_macros: unchanged; the only macro package. +``` + +Notes: + +- **The tag filter is the only reason for dynamic SQL.** The statement is built once, with the tag predicate or `1 = 1`, and executed with binds. Its framework names are qualified with `&&ut3_owner.`: SQL*Plus substitutes them in string literals at install time too. Today's tag SQL uses an unqualified `ut_varchar2_rows`, which must be qualified when it moves. All types it uses are already granted to the role (`ut_varchar2_rows`, `ut_suite_cache_row`, `ut_suite_item_info`, `ut_utils`). +- **Tag propagation** (`propagate_tags_from_ancestors`) is already a self-join over the matched rows, and it moves as a CTE. +- **Readability:** name each CTE after the function it replaces. +- **No new privileges.** `ut_suite_cache_manager` already holds the role. `ut_suite_manager` and `ut_suite_tag_filter` need none, and no new grant lines are needed. + +## Suggested steps (each can ship and be tested separately) + +0. **Remove the `a_parsed_after` branch from `get_cached_objects`. Done.** + - The parameter is gone from the macro and from its three call sites: `remove_missing_objs_from_cache`, `get_non_existing_objects` and `get_objects_to_refresh`. The last one now binds three values instead of four. Its freshness check `case when o.last_ddl_time < cast(c.parse_time as date) then 'N' else 'Y' end = 'Y'` is now written as `(c.parse_time is null or o.last_ddl_time >= cast(c.parse_time as date))`, with the same meaning. It stays in the `where` clause: moved into the `on` clause of the left join, it would no longer drop any row, and every object would be re-parsed on each refresh. + - Rule 5 is documented in the spec of `ut_annotation_cache_macros`. + - **Verified on 2026-11-09:** + - Setup: a fresh container of `utplsqlv3/oracledb:19.20-utplsql`, then `development/install.sh` and `test/install_tests.sh`. + - Install: no invalid objects; the three packages hold the role. + - Full run: 1136 tests, 0 failed, 0 errored, 3 disabled. + - The result doesn't change by design, so the tests are a safety net, not a proof of the effect. +1. **P8, done.** Single `delete` through the macro, plus the follow-up in `ut_annotation_manager`. + - Verified on 19.20 EE (1136 tests), 21.3 XE (1143) and 23ai, all with 0 failed and 3 disabled. + - The 19.20 and 23ai runs are from before the 21c `create_grants.sql` fix, and were not rerun locally after it. + - **Not checked:** which tests make the difference between 1136 and 1143. +2. **P6 + finding 1.** Pass the collection to `reconstruct_from_cache`, drop the cursor plumbing, and set the rollback type once. Pure PL/SQL. +3. **P1: access predicate into `get_suite_items`** (plain SQL in `ut_suite_cache_manager`). + - Remove `get_filtered_cursor` and the logical-suite exemption, and merge finding 3. + - Check the `build_suites_from_annotations(a_skip_all_objects)` path used by `test_suite_builder`. + - Answer open question 2 first with a test, because this step changes that behaviour by construction. +4. **P2/P3/P4: one statement.** Merge `get_suite_items` → tags → logical suites → sort into one dynamic statement, and reduce `ut_suite_tag_filter` to `create_where_filter`. Rewrite the `apply` tests in `test_ut_suite_tag_filter` against the new entry point; don't keep `apply` as a test-only wrapper (YAGNI). +5. **P7: merge `expand_paths` into the path CTE.** This is the riskiest step. Wildcard semantics and error messages are covered by `test_ut_run` / `test_ut_runner` in `ut3_user`. Do it last among the merges, with those suites as the safety net. +6. **P9: Flow B on the same statement text.** Remove `get_cached_suite_info` and `get_suite_items_info` from the spec, and merge finding 2. + +## Bigger options to consider separately + +- **Materialise logical suites in the cache.** Insert `UT_LOGICAL_SUITE` rows into `ut_suite_cache`, per schema, at the end of `refresh_cache`. Run-time queries then become plain table reads, and P3 leaves the read path. + - Cost: logical rows depend on every package in the schema, so they need a rebuild whenever any package's suitepath changes. + - The unique keys on `(object_owner, path)` and `(object_owner, object_name, line_no)` must accommodate them. + - With P1 applied at read time, logical rows would also need an access rule of their own. +- **Stream instead of materialise.** If reconciliation (P5) can be answered from the path CTE alone, the main statement can be returned as a real cursor, and `reconstruct_from_cache` can fetch in batches. That depends on open question 1. + +## How to check that nothing regressed + +- **Behaviour:** the full `ut3_tester` and `ut3_user` suites, especially: + - `test_suite_builder`; + - `test_ut_suite_tag_filter`; + - `test_ut_run` (paths, wildcards, tags, random order); + - `test_ut_runner` (`get_suites_info`, `has_suites`, `is_suite`, `is_test`); + - `test_annotation_cache`, which runs as users without elevated privileges. +- **Platforms:** 19.20, 21.3 XE and 23ai, because macro privilege checks differ between versions (rules 3 and 4). +- **Performance:** compare before and after on a schema with many suites, using the `ut_event_manager` events `configure_execution_by_path - start/end` and `development/mystats`. + +## Open questions + +1. Should a package path whose tests are all excluded by tags raise "does not exist" (P5)? +2. Can logical suites currently remain in the tree with no accessible children (P1)? If so, is that intended? Step 3 removes them by construction. +3. Is the 20-level limit on suitepath depth (P3) documented anywhere, or is it accidental? +4. Would a `parse_time` filter in `get_objects_to_refresh` pay off (removed in step 0)? Only a measurement on a schema with many cached objects can tell. If it would, use the bind-safe form. diff --git a/source/core/annotations/ut_annotation_cache_macros.pkb b/source/core/annotations/ut_annotation_cache_macros.pkb index f12b62da6..b03b7529f 100644 --- a/source/core/annotations/ut_annotation_cache_macros.pkb +++ b/source/core/annotations/ut_annotation_cache_macros.pkb @@ -16,16 +16,13 @@ create or replace noneditionable package body ut_annotation_cache_macros as limitations under the License. */ - function get_cached_objects(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return varchar2 sql_macro is + function get_cached_objects(a_object_owner varchar2, a_object_type varchar2) return varchar2 sql_macro is begin return q'[ select /*+ NO_UNNEST NO_EXPAND */ i.object_owner, i.object_name, i.object_type, i.parse_time from &&ut3_owner..ut_annotation_cache_info i where i.object_owner = a_object_owner - and i.object_type = a_object_type]' - ||case when a_parsed_after is not null then q'[ - and i.parse_time > a_parsed_after]' - end; + and i.object_type = a_object_type]'; end; end; diff --git a/source/core/annotations/ut_annotation_cache_macros.pks b/source/core/annotations/ut_annotation_cache_macros.pks index 13aa4f6d5..fa3f43765 100644 --- a/source/core/annotations/ut_annotation_cache_macros.pks +++ b/source/core/annotations/ut_annotation_cache_macros.pks @@ -32,9 +32,8 @@ create or replace noneditionable package ut_annotation_cache_macros authid defin * * @param a_object_owner owner of cached objects * @param a_object_type type of cached objects - * @param a_parsed_after limit results to objects parsed after specified time only, if null - all cached objects are returned */ - function get_cached_objects(a_object_owner varchar2, a_object_type varchar2, a_parsed_after timestamp := null) return varchar2 sql_macro; + function get_cached_objects(a_object_owner varchar2, a_object_type varchar2) return varchar2 sql_macro; end; / diff --git a/source/core/annotations/ut_annotation_manager.pkb b/source/core/annotations/ut_annotation_manager.pkb index 27c4c9c8b..59bc54530 100644 --- a/source/core/annotations/ut_annotation_manager.pkb +++ b/source/core/annotations/ut_annotation_manager.pkb @@ -40,7 +40,7 @@ create or replace noneditionable package body ut_annotation_manager as needs_refresh => 'N', parse_time => i.parse_time ) - from (]'||l_ut_owner||q'[.ut_annotation_cache_macros.get_cached_objects( :a_object_owner, :a_object_type, null )) i + from (]'||l_ut_owner||q'[.ut_annotation_cache_macros.get_cached_objects( :a_object_owner, :a_object_type )) i where not exists ( select 1 from ]'||l_objects_view||q'[ o where o.owner = i.object_owner @@ -80,20 +80,20 @@ create or replace noneditionable package body ut_annotation_manager as parse_time => c.parse_time ) from ]'||l_objects_view||' o - left join '||l_ut_owner||q'[.ut_annotation_cache_macros.get_cached_objects( :a_object_owner, :a_object_type, :a_parsed_after ) c + left join '||l_ut_owner||q'[.ut_annotation_cache_macros.get_cached_objects( :a_object_owner, :a_object_type ) c on o.owner = c.object_owner and o.object_name = c.object_name and o.object_type = c.object_type where o.owner = ']'||ut_utils.qualified_sql_name(a_object_owner)||q'[' and o.object_type = ']'||ut_utils.qualified_sql_name(a_object_type)||q'[' - and case when o.last_ddl_time < cast(c.parse_time as date) then 'N' else 'Y' end = 'Y' + and (c.parse_time is null or o.last_ddl_time >= cast(c.parse_time as date)) and ]' || case when a_modified_after is null then ':a_modified_after is null' else 'o.last_ddl_time >= cast(:a_modified_after as date)' end - bulk collect into l_result using a_object_owner, a_object_type, a_modified_after, a_modified_after; + bulk collect into l_result using a_object_owner, a_object_type, a_modified_after; end if; ut_event_manager.trigger_event('get_objects_to_refresh - end (count='||l_result.count||')'); return l_result; diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 503fd92fe..2fe28ad73 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -394,7 +394,7 @@ create or replace noneditionable package body ut_suite_cache_manager is where i.object_owner = a_schema_name and not exists ( select 1 - from (&&ut3_owner..ut_annotation_cache_macros.get_cached_objects(a_schema_name, 'PACKAGE', null)) o + from (&&ut3_owner..ut_annotation_cache_macros.get_cached_objects(a_schema_name, 'PACKAGE')) o where o.object_name = i.object_name ); From b0083f112c7822948e6db22c80d71a5b216f5872 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Mon, 9 Nov 2026 23:40:53 +0200 Subject: [PATCH 829/887] Pass suite cache rows to reconstruct_from_cache without a ref cursor The rollback type is now set only in reconstruct_from_cache. --- .../suite_cache_collection_patterns.md | 36 ++++++++-- source/core/ut_suite_manager.pkb | 70 +++++++++---------- 2 files changed, 62 insertions(+), 44 deletions(-) diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md index aa76e361e..3fea085c9 100644 --- a/development/suite_cache_collection_patterns.md +++ b/development/suite_cache_collection_patterns.md @@ -13,7 +13,7 @@ Revised on 2026-11-09 for the CBAC + SQL macro strategy, against branch `feature | P3 | logical suites appended to a collection | open | CTE of the main statement | | P4 | sort by self-join of a collection | open | last CTE of the main statement | | P5 | paths reconciled against a collection | open | keep, over the single final result | -| P6 | collection → ref cursor → collection | open | pass the collection, no cursor | +| P6 | collection → ref cursor → collection | **done, partly** | collection passed, no cursor; rows still converted to records (ORA-00600) | | P7 | two scans of `ut_suite_cache` for path matching | open | one path-matching CTE | | P8 | list handed between the two cache modules | **done** | table SQL macro `ut_annotation_cache_macros.get_cached_objects` | | P9 | full rows loaded only to project scalars | open | Flow B reuses the main statement and projects | @@ -201,7 +201,7 @@ No change is planned. - No predicate pushing across steps. - Unknown `table()` cardinality: only two statements carry a fixed `cardinality(c 500)` hint. - `value(c)` is moved around instead of columns. -- **Approach:** one statement in `ut_suite_cache_manager`, with each step as a named CTE. It carries columns, not objects, and builds `ut_suite_cache_row` only in the final select. It is dynamic SQL because of the tag predicate (see the target design). `ut_suite_tag_filter` keeps only the predicate builder. +- **Approach:** one statement in `ut_suite_cache_manager`, with each step as a named CTE. It carries columns, not objects, and the final select returns columns that the caller fetches into records for `reconstruct_from_cache`. Don't use `ut_suite_cache_row` objects here; see the `ORA-00600` under P6. It is dynamic SQL because of the tag predicate (see the target design). `ut_suite_tag_filter` keeps only the predicate builder. ### P3: enrich a collection with generated rows @@ -230,7 +230,28 @@ No change is planned. - **Where:** `get_cached_suite_data` opens `select * from table(l_filtered_rows)` ([ut_suite_manager.pkb:371](../source/core/ut_suite_manager.pkb:371)). `reconstruct_from_cache` fetches it back in batches of 1000. - **What:** a fully materialised collection is wrapped in a cursor and unwrapped again. `limit 1000` saves no memory. -- **Approach:** pass the collection straight to `reconstruct_from_cache`. This also removes the `c_cached_suites_cursor` / `tt_cached_suites` / `t_cached_suites_cursor` plumbing. Pure PL/SQL, no privilege change. +- **Done in step 2, partly.** + - `get_cached_suite_data` returns the collection. + - `reconstruct_from_cache` takes it and converts it to records with one `select * bulk collect into` from `table()`. + - The ref cursor type `t_cached_suites_cursor` and the `limit 1000` batch loop are gone. +- **Why the record conversion stays:** building the `ut_test` objects straight from the `ut_suite_cache_row` objects makes nested runs fail on 19.20. See [Records, not objects, for building the tree](#records-not-objects-for-building-the-tree). So the copy from the collection into `tt_cached_suites` records remains, and so do `c_cached_suites_cursor` and `tt_cached_suites`. + +#### Records, not objects, for building the tree + +Found in step 2, on 19.20 EE, 2026-11-09: + +- **Symptom:** `reconstruct_from_cache` read the rows straight from the `ut_suite_cache_rows` collection, and `get_logical_suite` built `ut_test(item => .item, ...)` from `ut_suite_cache_row` objects. A nested run then failed with `ORA-00600: [pfrobj.c: invalid RTTI for Object]`. + - The run was `test_ut_test.application_info_on_execution`, which calls `ut3_develop.ut.run`. + - The error was raised in `UT3_DEVELOP.UT_EXECUTABLE.DO_EXECUTE` line 49, the call on the test's `item` (`ut_executable_test`, `authid current_user`). The location comes from the incident trace's PL/SQL call stack. + - It reproduced every time, and killed the whole test run. +- **Variants that still failed:** + - the rows assigned to a local variable before the call; + - `pragma inline` removed; + - each row copied into a local `ut_suite_cache_row` variable; + - the collection kept in a package variable, so it is never freed; + - an extra `select value(c) bulk collect` round trip in `ut_suite_manager`, which has no CBAC role. +- **Variant that worked:** the same rows, converted with `select * bulk collect into` a collection of `c_cached_suites_cursor%rowtype` records. With that, `test_ut_test` (27 tests) and the full run (1136 tests) passed. +- **Rule for later steps:** build the suite tree from records whose columns SQL filled, not from attributes of `ut_suite_cache_row` objects. The cause looks like an Oracle defect; it was not narrowed down further. ### P7: two passes over `ut_suite_cache` for path resolution @@ -266,7 +287,7 @@ No change is planned. ## Smaller findings seen along the way -1. **Rollback type is set twice.** `reconstruct_from_cache` calls `set_rollback_type` on top-level suites ([ut_suite_manager.pkb:293](../source/core/ut_suite_manager.pkb:293)), then `configure_execution_by_path` does it again ([ut_suite_manager.pkb:559](../source/core/ut_suite_manager.pkb:559)). +1. **Rollback type is set twice. Fixed in step 2:** only `reconstruct_from_cache` sets it now. That covers `configure_execution_by_path` and `build_suites_from_annotations`. 2. **Duplicated prologue.** `configure_execution_by_path` and `get_suites_info` both do "resolve schema names → refresh cache per schema → `get_schema_paths`". This could be one private procedure. 3. **Two near-identical checks.** `can_skip_all_objects_scan` ([ut_suite_manager.pkb:376](../source/core/ut_suite_manager.pkb:376)) and the `user_has_execute_any_proc() or a_skip_all_objects` test in `get_filtered_cursor` cover almost the same check. After step 3, one function computes the skip flag. 4. **`get_logical_suite` repeats constructor calls.** It holds 7 constructor calls that differ only in `items =>`. Choosing `items` first would cut it to 4. @@ -286,7 +307,7 @@ resolve paths, refresh cache ──paths, tags──▶ get_suite_rows(a_pa tagged_rows tag predicate from the tag filter ← P2 with_logical generated logical suites ← P3 ordered recursive sort / randomise ← P4 - ◀──rows────── ut_suite_cache_rows, built once in the final select + ◀──rows────── rows fetched as records (tt_cached_suites), not objects reconcile(paths, rows) ← P5 reconstruct_from_cache(rows) no ref cursor ← P6 @@ -319,7 +340,10 @@ Notes: - Verified on 19.20 EE (1136 tests), 21.3 XE (1143) and 23ai, all with 0 failed and 3 disabled. - The 19.20 and 23ai runs are from before the 21c `create_grants.sql` fix, and were not rerun locally after it. - **Not checked:** which tests make the difference between 1136 and 1143. -2. **P6 + finding 1.** Pass the collection to `reconstruct_from_cache`, drop the cursor plumbing, and set the rollback type once. Pure PL/SQL. +2. **P6 + finding 1. Done, partly.** `reconstruct_from_cache` takes the collection instead of a ref cursor, and the rollback type is set once. + - The rows are still converted to records, because of the `ORA-00600` described under P6. + - Verified on 2026-11-09 on 19.20 EE: install with no invalid objects, and the full run passed (1136 tests, 0 failed, 0 errored, 3 disabled). + - Consequence for step 4: the main statement should return columns that are fetched into records, not `ut_suite_cache_row` objects. That also removes the last copy, the conversion in `reconstruct_from_cache`. 3. **P1: access predicate into `get_suite_items`** (plain SQL in `ut_suite_cache_manager`). - Remove `get_filtered_cursor` and the logical-suite exemption, and merge finding 3. - Check the `build_suites_from_annotations(a_skip_all_objects)` path used by `test_suite_builder`. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 080c8d05c..80b1fcb70 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -19,7 +19,6 @@ create or replace noneditionable package body ut_suite_manager is gc_suitpath_error_message constant varchar2(100) := 'Suitepath exceeds 1000 CHAR on: '; cursor c_cached_suites_cursor is select * from table(ut_suite_cache_rows()); type tt_cached_suites is table of c_cached_suites_cursor%rowtype; - type t_cached_suites_cursor is ref cursor return c_cached_suites_cursor%rowtype; type t_item_levels is table of ut_suite_items index by binary_integer; ------------------ @@ -250,42 +249,46 @@ create or replace noneditionable package body ut_suite_manager is return l_result; end; + /* + Builds the suite hierarchy from cache rows sorted bottom-up (see ut_suite_cache_manager.sort_and_randomize_tests) + and propagates the rollback type of top level suites to their items. + + The rows are converted to records with SQL before use. Building ut_test objects from the item attribute + of ut_suite_cache_row objects directly makes the test execution fail on Oracle 19.20 with + ORA-00600: [pfrobj.c: invalid RTTI for Object] in ut_executable.do_execute (seen in nested runs, test_ut_test). + */ procedure reconstruct_from_cache( a_suites in out nocopy ut_suite_items, - a_suite_data_cursor sys_refcursor + a_suite_rows ut_suite_cache_rows ) is - c_bulk_limit constant pls_integer := 1000; l_items_at_level t_item_levels; l_rows tt_cached_suites; l_level pls_integer; l_prev_level pls_integer; l_idx integer; begin - loop - fetch a_suite_data_cursor bulk collect into l_rows limit c_bulk_limit; - - l_idx := l_rows.first; - while l_idx is not null loop - l_level := length(l_rows(l_idx).path) - length( replace(l_rows(l_idx).path, '.') ) + 1; - if l_level > 1 then - if not l_items_at_level.exists(l_level) then - l_items_at_level(l_level) := ut_suite_items(); - end if; - l_items_at_level(l_level).extend; - pragma inline(get_logical_suite, 'YES'); - l_items_at_level(l_level)(l_items_at_level(l_level).last) := get_logical_suite(l_rows, l_idx, l_level,l_prev_level, l_items_at_level ); - else - a_suites.extend; - pragma inline(get_logical_suite, 'YES'); - a_suites(a_suites.last) := get_logical_suite(l_rows, l_idx, l_level,l_prev_level, l_items_at_level ); - end if; - if l_prev_level > l_level then - l_items_at_level(l_prev_level).delete; + select * bulk collect into l_rows from table(a_suite_rows); + + l_idx := l_rows.first; + while l_idx is not null loop + l_level := length(l_rows(l_idx).path) - length( replace(l_rows(l_idx).path, '.') ) + 1; + if l_level > 1 then + if not l_items_at_level.exists(l_level) then + l_items_at_level(l_level) := ut_suite_items(); end if; - l_prev_level := l_level; - l_idx := l_rows.next(l_idx); - end loop; - exit when a_suite_data_cursor%NOTFOUND; + l_items_at_level(l_level).extend; + pragma inline(get_logical_suite, 'YES'); + l_items_at_level(l_level)(l_items_at_level(l_level).last) := get_logical_suite(l_rows, l_idx, l_level,l_prev_level, l_items_at_level ); + else + a_suites.extend; + pragma inline(get_logical_suite, 'YES'); + a_suites(a_suites.last) := get_logical_suite(l_rows, l_idx, l_level,l_prev_level, l_items_at_level ); + end if; + if l_prev_level > l_level then + l_items_at_level(l_prev_level).delete; + end if; + l_prev_level := l_level; + l_idx := l_rows.next(l_idx); end loop; reverse_list_order( a_suites ); @@ -293,7 +296,6 @@ create or replace noneditionable package body ut_suite_manager is for i in 1 .. a_suites.count loop a_suites( i ).set_rollback_type( a_suites( i ).get_rollback_type ); end loop; - close a_suite_data_cursor; end reconstruct_from_cache; function get_filtered_cursor( @@ -354,11 +356,10 @@ create or replace noneditionable package body ut_suite_manager is a_random_seed positive, a_tags varchar2 := null, a_skip_all_objects boolean := false - ) return t_cached_suites_cursor is + ) return ut_suite_cache_rows is l_unfiltered_rows ut_suite_cache_rows; l_tag_filter_applied ut_suite_cache_rows; l_filtered_rows ut_suite_cache_rows; - l_result t_cached_suites_cursor; begin l_unfiltered_rows := ut_suite_cache_manager.get_suite_items(a_schema_paths); @@ -368,9 +369,7 @@ create or replace noneditionable package body ut_suite_manager is ut_suite_cache_manager.sort_and_randomize_tests(l_filtered_rows,a_random_seed); - open l_result for - select * from table(l_filtered_rows); - return l_result; + return l_filtered_rows; end; function can_skip_all_objects_scan( @@ -555,11 +554,6 @@ create or replace noneditionable package body ut_suite_manager is a_tags ); - --propagate rollback type to suite items after organizing suites into hierarchy - for i in 1 .. a_suites.count loop - a_suites(i).set_rollback_type( a_suites(i).get_rollback_type() ); - end loop; - ut_event_manager.trigger_event('configure_execution_by_path - end'); end configure_execution_by_path; From 6f70675ac09ee695022932cdd0cef0deb1c27e26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 00:10:54 +0200 Subject: [PATCH 830/887] Check suite access before generating logical suites. Added tests for a user with partial access to test_annotation_cache. The access check now runs in the query of ut_suite_cache_manager.get_suite_items. Logical suites are generated from accessible rows only. A suitepath with no accessible package below it now raises "No suite packages found for path". --- .../suite_cache_collection_patterns.md | 40 +++++++-- source/core/ut_suite_cache_manager.pkb | 44 ++++++---- source/core/ut_suite_cache_manager.pks | 16 ++-- source/core/ut_suite_manager.pkb | 55 ++++-------- .../annotations/test_annotation_cache.pkb | 50 +++++++++++ .../annotations/test_annotation_cache.pks | 20 +++++ .../annotation_cache_helper.pkb | 88 ++++++++++++++++++- .../annotation_cache_helper.pks | 6 +- 8 files changed, 247 insertions(+), 72 deletions(-) diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md index 3fea085c9..2ef4338ad 100644 --- a/development/suite_cache_collection_patterns.md +++ b/development/suite_cache_collection_patterns.md @@ -8,7 +8,7 @@ Revised on 2026-11-09 for the CBAC + SQL macro strategy, against branch `feature | Pattern | What it is | Status | Approach | |---|---|---|---| -| P1 | access filter applied to a collection by the caller | open | access predicate in the `ut_suite_cache` query, plain SQL in `ut_suite_cache_manager` (CBAC) | +| P1 | access filter applied to a collection by the caller | **done** | access predicate in `get_suite_items`, plain SQL in `ut_suite_cache_manager` (step 3) | | P2 | chain of collection → collection functions | open | one statement with named CTEs | | P3 | logical suites appended to a collection | open | CTE of the main statement | | P4 | sort by self-join of a collection | open | last CTE of the main statement | @@ -76,6 +76,10 @@ Consolidated from the checks on 19.20 EE, 21.3 XE and 23ai Free (2026-11-09). 6. **Collections can be arguments.** `from macro(sys.odcivarchar2list('a','b','c'))`, with `table(a_list)` in the macro text, returned 3 rows on 19.20. Not checked with framework types such as `ut_path_items`. The suite plan below doesn't need it. 7. **Qualify framework objects in the macro text** with `&&ut3_owner.`. The text is expanded into the caller's statement, and the caller is invoker rights. 8. **SYS can't call the macro directly.** It fails with `ORA-06598: insufficient INHERIT PRIVILEGES privilege`. This doesn't affect normal use. +9. **Recreating a package spec drops its CBAC role grant.** Seen on 19.20, 2026-11-09: + - `create or replace package ut_suite_cache_manager` removed the package from `dba_code_role_privs`. Its SQL then failed with `ORA-00942`. + - `create or replace package body` keeps the grant. + - After changing the spec of a package with the role by hand, rerun [ut3_cbac_modify_objects_role_grants.sql](../source/ut3_cbac_modify_objects_role_grants.sql), or use `development/refresh_ut3.sh`. ## New finding: `get_cached_objects` branches on an argument's value @@ -186,12 +190,27 @@ No change is planned. - **Approach:** put the access predicate into the `ut_suite_cache` query inside `ut_suite_cache_manager`. That is plain SQL; no macro is needed. The EXECUTE ANY / `a_skip_all_objects` decision comes in as a bind flag in the SQL text (rule 5 doesn't apply here, but the same style keeps one cursor): ```sql where ( :skip_access_check = 'Y' - or c.object_owner = sys_context('userenv','current_user') or exists (select 1 from all_objects a where a.owner = c.object_owner and a.object_name = c.object_name and a.object_type = 'PACKAGE') ) ``` Logical suites are then generated from accessible suites only, and the exemption goes away. +- **Done in step 3.** `get_suite_items` and `get_cached_suite_info` take `a_skip_access_check`, and `get_filtered_cursor` is gone. `ut_suite_manager.skip_access_check` computes the flag: EXECUTE ANY PROCEDURE or `a_skip_all_objects`. Tags are now applied to accessible rows only, and logical suites are generated from those. + +#### Behaviour for users with partial access (open question 2, answered) + +The setup: `probe_user` has EXECUTE on `child_suite`, but not on `parent_suite`, its parent suite, nor on `lone_suite` (suitepath `logical.sub`). Measured on 19.20 on 2026-11-09, before and after step 3: + +| Case | Before step 3 | After step 3 | +|---|---|---| +| `get_suites_info` | listed logical suites `logical` and `logical.sub` with nothing accessible below them, and `parent_suite.child_suite` without a parent | no empty logical suites; `child_suite` under a generated logical suite `parent_suite` | +| run `probe_owner.child_suite` | **0 tests, silently**: the accessible test was lost, because its parent suite was removed after the tree's logical suites were generated | runs `child_test` | +| run `:parent_suite` | error "No suite packages found" | runs `child_test` | +| run the whole schema | the accessible `child_test` was not run; empty `logical`/`sub` suites were printed | runs all accessible tests | +| run `:logical` (nothing accessible below it) | empty run, 0 tests, no error | error "No suite packages found for path …", the same as for a path with no packages at all | +| tag on the inaccessible parent only | 0 tests | 0 tests: tags of an inaccessible parent are not inherited | + +The new behaviour was accepted on 2026-11-09. It is covered by the context "Suites spread across packages, user without elevated privileges" in `test_annotation_cache`. Its 4 tests fail on the code before step 3 and pass after it. ### P2: chain of collection-to-collection transforms @@ -289,7 +308,7 @@ Found in step 2, on 19.20 EE, 2026-11-09: 1. **Rollback type is set twice. Fixed in step 2:** only `reconstruct_from_cache` sets it now. That covers `configure_execution_by_path` and `build_suites_from_annotations`. 2. **Duplicated prologue.** `configure_execution_by_path` and `get_suites_info` both do "resolve schema names → refresh cache per schema → `get_schema_paths`". This could be one private procedure. -3. **Two near-identical checks.** `can_skip_all_objects_scan` ([ut_suite_manager.pkb:376](../source/core/ut_suite_manager.pkb:376)) and the `user_has_execute_any_proc() or a_skip_all_objects` test in `get_filtered_cursor` cover almost the same check. After step 3, one function computes the skip flag. +3. **Two near-identical checks. Partly fixed in step 3:** `skip_access_check` replaces the test in `get_filtered_cursor`. The owner needs no special case in the SQL predicate: `all_objects` always includes the user's own packages. `can_skip_all_objects_scan` stays, for `refresh_cache` and `suite_item_exists`. 4. **`get_logical_suite` repeats constructor calls.** It holds 7 constructor calls that differ only in `items =>`. Choosing `items` first would cut it to 4. 5. **Possible stale items on a bad suitepath (verify).** In `build_and_cache_suites` ([ut_suite_manager.pkb:398](../source/core/ut_suite_manager.pkb:398)), when `create_suite_item_list` raises `ex_string_too_small`, `save_object_cache` still runs with `l_suite_items`. That parameter is `out nocopy`, so it may hold partial or previous-object items. 6. **Arbitrary `row_number` order.** `get_suite_items` deduplicates with `order by path, object_owner` inside a partition by the same columns. That is fine only because the duplicates are identical rows. @@ -344,10 +363,15 @@ Notes: - The rows are still converted to records, because of the `ORA-00600` described under P6. - Verified on 2026-11-09 on 19.20 EE: install with no invalid objects, and the full run passed (1136 tests, 0 failed, 0 errored, 3 disabled). - Consequence for step 4: the main statement should return columns that are fetched into records, not `ut_suite_cache_row` objects. That also removes the last copy, the conversion in `reconstruct_from_cache`. -3. **P1: access predicate into `get_suite_items`** (plain SQL in `ut_suite_cache_manager`). - - Remove `get_filtered_cursor` and the logical-suite exemption, and merge finding 3. - - Check the `build_suites_from_annotations(a_skip_all_objects)` path used by `test_suite_builder`. - - Answer open question 2 first with a test, because this step changes that behaviour by construction. +3. **P1: access predicate into `get_suite_items`. Done.** + - The access check is plain SQL in `ut_suite_cache_manager`. `get_filtered_cursor` and the logical-suite exemption are gone. + - `build_suites_from_annotations(a_skip_all_objects)` passes its flag through `skip_access_check`. + - The behaviour change is described under P1. + - New tests: 4, in `test_annotation_cache`, with helpers in `annotation_cache_helper`. + - **Verified on 2026-11-09:** + - Setup: a fresh 19.20 container, then `development/install.sh` and `test/install_tests.sh`. + - Install: no invalid objects. + - Full run: 1140 tests, 0 failed, 0 errored, 3 disabled. 4. **P2/P3/P4: one statement.** Merge `get_suite_items` → tags → logical suites → sort into one dynamic statement, and reduce `ut_suite_tag_filter` to `create_where_filter`. Rewrite the `apply` tests in `test_ut_suite_tag_filter` against the new entry point; don't keep `apply` as a test-only wrapper (YAGNI). 5. **P7: merge `expand_paths` into the path CTE.** This is the riskiest step. Wildcard semantics and error messages are covered by `test_ut_run` / `test_ut_runner` in `ut3_user`. Do it last among the merges, with those suites as the safety net. 6. **P9: Flow B on the same statement text.** Remove `get_cached_suite_info` and `get_suite_items_info` from the spec, and merge finding 2. @@ -374,6 +398,6 @@ Notes: ## Open questions 1. Should a package path whose tests are all excluded by tags raise "does not exist" (P5)? -2. Can logical suites currently remain in the tree with no accessible children (P1)? If so, is that intended? Step 3 removes them by construction. +2. ~~Can logical suites remain in the tree with no accessible children (P1)?~~ Answered: yes, they could. Accessible packages under an inaccessible parent suite were also lost. Both are fixed in step 3; see the table under P1. 3. Is the 20-level limit on suitepath depth (P3) documented anywhere, or is it accidental? 4. Would a `parse_time` filter in `get_objects_to_refresh` pay off (removed in step 0)? Only a measurement on a schema with many cached objects can tell. If it would, use the bind-safe form. diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 2fe28ad73..c8dc09f09 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -174,31 +174,44 @@ create or replace noneditionable package body ut_suite_cache_manager is We need to consider also an wildcard character on our procedures and object names. Were the path is populated we need to make sure we dont return duplicates - as the wildcard can produce multiple results from same path and - parents and child for each can be same resulting in duplicates - */ + as the wildcard can produce multiple results from same path and + parents and child for each can be same resulting in duplicates + Only items of packages the invoking user can access are returned, unless a_skip_access_check is true. + */ function get_suite_items ( - a_schema_paths ut_path_items + a_schema_paths ut_path_items, + a_skip_access_check boolean ) return ut_suite_cache_rows is - l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); + l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); + l_skip_access_check varchar2(1) := case when a_skip_access_check then 'Y' else 'N' end; begin select obj bulk collect into l_suite_items from ( - select /*+ cardinality(c 500) */ value(c) as obj,row_number() over ( partition by path,object_owner order by path,object_owner asc) as r_num + select /*+ cardinality(c 500) no_expand */ value(c) as obj,row_number() over ( partition by path,object_owner order by path,object_owner asc) as r_num from &&ut3_owner..ut_suite_cache c, table(a_schema_paths) sp where c.object_owner = upper(sp.schema_name) - and ((sp.suite_path is not null and sp.suite_path||'.' like c.path||'.%' /*all parents and self*/ + and ((sp.suite_path is not null and sp.suite_path||'.' like c.path||'.%' /*all parents and self*/ or - ( + ( c.path||'.' like sp.suite_path||'.%' /*all children and self*/ - and c.object_name like nvl(upper(sp.object_name),c.object_name) - and c.name like nvl(upper(sp.procedure_name),c.name) - )) + and c.object_name like nvl(upper(sp.object_name),c.object_name) + and c.name like nvl(upper(sp.procedure_name),c.name) + )) or ( sp.suite_path is null - and c.object_name = nvl(upper(sp.object_name),c.object_name) - and c.name = nvl(upper(sp.procedure_name),c.name)))) where r_num =1; + and c.object_name = nvl(upper(sp.object_name),c.object_name) + and c.name = nvl(upper(sp.procedure_name),c.name))) + and ( l_skip_access_check = 'Y' + or exists ( + select 1 + from all_objects a + where a.owner = c.object_owner + and a.object_name = c.object_name + and a.object_type = 'PACKAGE' + ) + ) + ) where r_num =1; return l_suite_items; end; @@ -402,10 +415,11 @@ create or replace noneditionable package body ut_suite_cache_manager is end; function get_cached_suite_info( - a_schema_paths ut_path_items + a_schema_paths ut_path_items, + a_skip_access_check boolean ) return ut_suite_cache_rows is begin - return get_cached_suite_rows(get_suite_items(a_schema_paths)); + return get_cached_suite_rows(get_suite_items(a_schema_paths, a_skip_access_check)); end; function get_suite_items_info( diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 3852a1d34..03af41ca8 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -66,20 +66,26 @@ create or replace noneditionable package ut_suite_cache_manager authid current_u function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items; /* - * Retrieves suite item info rows from cache. - * Returned data is not filtered by user access rights. + * Retrieves suite item rows from cache, with logical suites added. + * Returns only items of packages the invoking user can access, unless a_skip_access_check is true. * Not to be used publicly. Used internally for building suites info. */ function get_cached_suite_info( - a_schema_paths ut_path_items + a_schema_paths ut_path_items, + a_skip_access_check boolean ) return ut_suite_cache_rows; - + function get_suite_items_info( a_suite_cache_items ut_suite_cache_rows ) return ut_suite_items_info; + /* + * Retrieves suite item rows matching the paths from cache. + * Returns only items of packages the invoking user can access, unless a_skip_access_check is true. + */ function get_suite_items ( - a_schema_paths ut_path_items + a_schema_paths ut_path_items, + a_skip_access_check boolean ) return ut_suite_cache_rows; /* diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 80b1fcb70..397f4062e 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -298,33 +298,12 @@ create or replace noneditionable package body ut_suite_manager is end loop; end reconstruct_from_cache; - function get_filtered_cursor( - a_unfiltered_rows in ut_suite_cache_rows, - a_skip_all_objects boolean := false - ) - return ut_suite_cache_rows is - l_result ut_suite_cache_rows := ut_suite_cache_rows(); + /* + Users with EXECUTE ANY PROCEDURE can run all packages, so their access does not need checking. + */ + function skip_access_check(a_skip_all_objects boolean := false) return boolean is begin - if ut_metadata.user_has_execute_any_proc() or a_skip_all_objects then - l_result := a_unfiltered_rows; - else - select obj bulk collect into l_result - from ( - select /*+ no_parallel */ value(c) as obj from table(a_unfiltered_rows) c - where sys_context( 'userenv', 'current_user' ) = upper(c.object_owner) - union all - select /*+ no_parallel */ value(c) as obj from table(a_unfiltered_rows) c - where sys_context( 'userenv', 'current_user' ) != upper(c.object_owner) - and ( exists - ( select 1 - from all_objects a - where a.object_name = c.object_name - and a.owner = c.object_owner - and a.object_type = 'PACKAGE' - ) - or c.self_type = 'UT_LOGICAL_SUITE')); - end if; - return l_result; + return ut_metadata.user_has_execute_any_proc() or a_skip_all_objects; end; procedure reconcile_paths_and_suites( @@ -357,19 +336,19 @@ create or replace noneditionable package body ut_suite_manager is a_tags varchar2 := null, a_skip_all_objects boolean := false ) return ut_suite_cache_rows is - l_unfiltered_rows ut_suite_cache_rows; + l_accessible_rows ut_suite_cache_rows; l_tag_filter_applied ut_suite_cache_rows; - l_filtered_rows ut_suite_cache_rows; + l_suite_rows ut_suite_cache_rows; begin - l_unfiltered_rows := ut_suite_cache_manager.get_suite_items(a_schema_paths); + l_accessible_rows := ut_suite_cache_manager.get_suite_items(a_schema_paths, skip_access_check(a_skip_all_objects)); - l_tag_filter_applied := ut_suite_tag_filter.apply(l_unfiltered_rows,a_tags); - l_filtered_rows := get_filtered_cursor(ut_suite_cache_manager.get_cached_suite_rows(l_tag_filter_applied),a_skip_all_objects); - reconcile_paths_and_suites(a_schema_paths,l_filtered_rows); + l_tag_filter_applied := ut_suite_tag_filter.apply(l_accessible_rows,a_tags); + l_suite_rows := ut_suite_cache_manager.get_cached_suite_rows(l_tag_filter_applied); + reconcile_paths_and_suites(a_schema_paths,l_suite_rows); - ut_suite_cache_manager.sort_and_randomize_tests(l_filtered_rows,a_random_seed); + ut_suite_cache_manager.sort_and_randomize_tests(l_suite_rows,a_random_seed); - return l_filtered_rows; + return l_suite_rows; end; function can_skip_all_objects_scan( @@ -566,8 +545,7 @@ create or replace noneditionable package body ut_suite_manager is l_schema_paths ut_path_items; l_paths ut_varchar2_list := a_paths; l_schema varchar2(4000); - l_unfiltered_rows ut_suite_cache_rows; - l_filtered_rows ut_suite_cache_rows; + l_suite_rows ut_suite_cache_rows; begin l_schema_names := resolve_schema_names(l_paths); @@ -578,9 +556,8 @@ create or replace noneditionable package body ut_suite_manager is l_schema := l_schema_names.next(l_schema); end loop; l_schema_paths := ut_suite_cache_manager.get_schema_paths(l_paths); - l_unfiltered_rows := ut_suite_cache_manager.get_cached_suite_info(l_schema_paths); - l_filtered_rows := get_filtered_cursor(l_unfiltered_rows); - l_all_suite_info := ut_suite_cache_manager.get_suite_items_info(l_filtered_rows); + l_suite_rows := ut_suite_cache_manager.get_cached_suite_info(l_schema_paths, skip_access_check()); + l_all_suite_info := ut_suite_cache_manager.get_suite_items_info(l_suite_rows); open l_result for select /*+ no_parallel */ value(c) from table(l_all_suite_info) c diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pkb b/test/ut3_tester/core/annotations/test_annotation_cache.pkb index eefaf8800..648683ec4 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pkb @@ -517,5 +517,55 @@ create or replace package body test_annotation_cache is cache_populated_for_packages( ut_varchar2_rows( 'GRANTED_TEST_SUITE', 'NOT_GRANTED_TEST_SUITE' ) ); end; + procedure user_runs_child_of_hidden_suite is + l_actual clob; + pragma autonomous_transaction; + begin + --Act + l_actual := annotation_cache_helper.run_tests_as( 'ut3_no_extra_priv_user', 'ut3_cache_test_owner.child_suite' ); + --Assert + ut.expect( l_actual ).to_be_like( '%parent_suite%child_test%1 tests, 0 failed%' ); + ut.expect( l_actual ).not_to_be_like( '%parent_test%' ); + rollback; + end; + + procedure user_runs_hidden_suite_path is + l_actual clob; + pragma autonomous_transaction; + begin + --Act + l_actual := annotation_cache_helper.run_tests_as( 'ut3_no_extra_priv_user', 'ut3_cache_test_owner:parent_suite' ); + --Assert + ut.expect( l_actual ).to_be_like( '%child_test%1 tests, 0 failed%' ); + ut.expect( l_actual ).not_to_be_like( '%parent_test%' ); + rollback; + end; + + procedure user_no_empty_logical_suites is + l_actual clob; + pragma autonomous_transaction; + begin + --Act + l_actual := annotation_cache_helper.get_suites_info_as( 'ut3_no_extra_priv_user' ); + --Assert + ut.expect( l_actual ).to_be_like( '%UT_TEST parent_suite.child_suite.child_test%' ); + ut.expect( l_actual ).not_to_be_like( '%hidden_path%' ); + ut.expect( l_actual ).not_to_be_like( '%parent_test%' ); + rollback; + end; + + procedure user_hidden_path_not_found is + l_actual clob; + pragma autonomous_transaction; + begin + --Act + l_actual := annotation_cache_helper.run_tests_as( 'ut3_no_extra_priv_user', 'ut3_cache_test_owner:hidden_path' ); + rollback; + exception + when others then + rollback; + raise; + end; + end; / diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pks b/test/ut3_tester/core/annotations/test_annotation_cache.pks index 5a3fdd8ca..da2216444 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pks +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pks @@ -276,5 +276,25 @@ create or replace package test_annotation_cache is --%endcontext + --%context(Suites spread across packages, user without elevated privileges) + --%beforeall(annotation_cache_helper.enable_ddl_trigger) + --%beforeall(annotation_cache_helper.setup_suite_hierarchy) + --%afterall(annotation_cache_helper.cleanup_suite_hierarchy) + + --%test(Runs a granted package whose parent suite is in a package that is not granted) + procedure user_runs_child_of_hidden_suite; + + --%test(Runs a granted package when its parent suitepath is given) + procedure user_runs_hidden_suite_path; + + --%test(Lists no logical suites without granted packages below them) + procedure user_no_empty_logical_suites; + + --%test(Raises an error for a suitepath without granted packages below it) + --%throws(-20204) + procedure user_hidden_path_not_found; + + --%endcontext + end; / diff --git a/test/ut3_tester_helper/annotation_cache_helper.pkb b/test/ut3_tester_helper/annotation_cache_helper.pkb index 0715b6af1..730689786 100644 --- a/test/ut3_tester_helper/annotation_cache_helper.pkb +++ b/test/ut3_tester_helper/annotation_cache_helper.pkb @@ -90,6 +90,66 @@ create or replace package body annotation_cache_helper as end; end; + /* + Suites spread across packages, only child_suite is granted: + parent_suite package parent_suite, not granted + parent_suite.child_suite package child_suite, granted + hidden_path.sub.lone_suite package lone_suite, not granted, below logical suites hidden_path and hidden_path.sub + */ + procedure setup_suite_hierarchy is + pragma autonomous_transaction; + begin + execute immediate + 'create or replace package ut3_cache_test_owner.parent_suite authid definer is + --%suite + + --%test + procedure parent_test; + end;'; + execute immediate + 'create or replace package body ut3_cache_test_owner.parent_suite is + procedure parent_test is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; + end;'; + execute immediate + 'create or replace package ut3_cache_test_owner.child_suite authid definer is + --%suite + --%suitepath(parent_suite) + + --%test + procedure child_test; + end;'; + execute immediate + 'create or replace package body ut3_cache_test_owner.child_suite is + procedure child_test is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; + end;'; + execute immediate + 'create or replace package ut3_cache_test_owner.lone_suite authid definer is + --%suite + --%suitepath(hidden_path.sub) + + --%test + procedure lone_test; + end;'; + execute immediate + 'create or replace package body ut3_cache_test_owner.lone_suite is + procedure lone_test is begin ut3_develop.ut.expect( 1 ).to_equal( 1 ); end; + end;'; + execute immediate 'grant execute on ut3_cache_test_owner.child_suite to ut3_no_extra_priv_user'; + end; + + procedure cleanup_suite_hierarchy is + pragma autonomous_transaction; + begin + for i in ( select column_value as package_name from table(ut3_develop.ut_varchar2_list('parent_suite','child_suite','lone_suite')) ) loop + begin + execute immediate 'drop package ut3_cache_test_owner.'||i.package_name; + exception + when others then + null; + end; + end loop; + end; + procedure cleanup_new_suite is pragma autonomous_transaction; begin @@ -122,21 +182,34 @@ create or replace package body annotation_cache_helper as pragma autonomous_transaction; begin execute immediate - 'create or replace function ' || a_user || '.call_ut_run return clob is + 'create or replace function ' || a_user || '.call_ut_run(a_path varchar2 := ''ut3_cache_test_owner'') return clob is l_data ut3_develop.ut_varchar2_list; l_results clob; begin - select * bulk collect into l_data from table (ut3_develop.ut.run( ''ut3_cache_test_owner'' )); + select * bulk collect into l_data from table (ut3_develop.ut.run( a_path )); return ut3_tester_helper.main_helper.table_to_clob( l_data ); end; '; execute immediate 'grant execute on ' || a_user || '.call_ut_run to public '; + execute immediate + 'create or replace function ' || a_user || '.call_suites_info return clob is + l_data ut3_develop.ut_varchar2_list; + begin + select i.item_type || '' '' || i.path + bulk collect into l_data + from table (ut3_develop.ut_runner.get_suites_info( ''UT3_CACHE_TEST_OWNER'' )) i + order by i.path; + return ut3_tester_helper.main_helper.table_to_clob( l_data ); + end; + '; + execute immediate 'grant execute on ' || a_user || '.call_suites_info to public '; end; procedure drop_run_function_for_user(a_user varchar2) is pragma autonomous_transaction; begin execute immediate 'drop function ' || a_user || '.call_ut_run'; + execute immediate 'drop function ' || a_user || '.call_suites_info'; end; procedure create_run_function_for_users is @@ -159,10 +232,17 @@ create or replace package body annotation_cache_helper as drop_run_function_for_user( 'ut3_develop' ); end; - function run_tests_as(a_user varchar2) return clob is + function run_tests_as(a_user varchar2, a_path varchar2 := 'ut3_cache_test_owner') return clob is + l_results clob; + begin + execute immediate 'begin :x := '||a_user||'.call_ut_run(:a_path); end;' using out l_results, a_path; + return l_results; + end; + + function get_suites_info_as(a_user varchar2) return clob is l_results clob; begin - execute immediate 'begin :x := '||a_user||'.call_ut_run; end;' using out l_results; + execute immediate 'begin :x := '||a_user||'.call_suites_info; end;' using out l_results; return l_results; end; end; diff --git a/test/ut3_tester_helper/annotation_cache_helper.pks b/test/ut3_tester_helper/annotation_cache_helper.pks index d6ab1f8e2..9c00ae9aa 100644 --- a/test/ut3_tester_helper/annotation_cache_helper.pks +++ b/test/ut3_tester_helper/annotation_cache_helper.pks @@ -12,10 +12,14 @@ create or replace package annotation_cache_helper as procedure disable_ddl_trigger; procedure enable_ddl_trigger; + procedure setup_suite_hierarchy; + procedure cleanup_suite_hierarchy; + procedure create_run_function_for_users; procedure drop_run_function_for_users; - function run_tests_as(a_user varchar2) return clob; + function run_tests_as(a_user varchar2, a_path varchar2 := 'ut3_cache_test_owner') return clob; + function get_suites_info_as(a_user varchar2) return clob; end; / \ No newline at end of file From 99c3acb9db9eebdc7540438407138f0b9843909f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 01:51:06 +0200 Subject: [PATCH 831/887] Build the suite list in one static SQL statement ut_suite_manager built the list of suites to run through five SQL statements over PL/SQL collections: path matching, tag filter, logical suites, access check and sort, copying all rows each time. ut_suite_cache_manager.get_suite_rows now does it in one static SQL statement with named CTEs. It replaces get_suite_items, get_cached_suite_rows, sort_and_randomize_tests, get_cached_suite_info and ut_suite_tag_filter.apply. Both the run and get_suites_info use it. Tags are filtered with ut_suite_tag_filter.is_matching, called from SQL. It takes the tags as a comma-separated text, because Oracle caches a deterministic function only when all arguments are scalars; each distinct set of tags is then evaluated once per statement. --- .../suite_cache_collection_patterns.md | 73 ++++- source/core/ut_suite_cache_manager.pkb | 296 +++++++++--------- source/core/ut_suite_cache_manager.pks | 41 +-- source/core/ut_suite_manager.pkb | 15 +- source/core/ut_suite_tag_filter.pkb | 82 ++--- source/core/ut_suite_tag_filter.pks | 20 +- .../ut3_cbac_modify_objects_role_grants.sql | 1 + .../core/test_ut_suite_tag_filter.pkb | 162 +++++++--- .../core/test_ut_suite_tag_filter.pks | 22 +- test/ut3_tester_helper/main_helper.pkb | 9 + test/ut3_tester_helper/main_helper.pks | 3 + 11 files changed, 406 insertions(+), 318 deletions(-) diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md index 2ef4338ad..b87ce6027 100644 --- a/development/suite_cache_collection_patterns.md +++ b/development/suite_cache_collection_patterns.md @@ -9,9 +9,9 @@ Revised on 2026-11-09 for the CBAC + SQL macro strategy, against branch `feature | Pattern | What it is | Status | Approach | |---|---|---|---| | P1 | access filter applied to a collection by the caller | **done** | access predicate in `get_suite_items`, plain SQL in `ut_suite_cache_manager` (step 3) | -| P2 | chain of collection → collection functions | open | one statement with named CTEs | -| P3 | logical suites appended to a collection | open | CTE of the main statement | -| P4 | sort by self-join of a collection | open | last CTE of the main statement | +| P2 | chain of collection → collection functions | **done** | one statement with named CTEs: `get_suite_rows` (step 4) | +| P3 | logical suites appended to a collection | **done** | CTE of the main statement (step 4) | +| P4 | sort by self-join of a collection | **done** | recursive CTE of the main statement (step 4) | | P5 | paths reconciled against a collection | open | keep, over the single final result | | P6 | collection → ref cursor → collection | **done, partly** | collection passed, no cursor; rows still converted to records (ORA-00600) | | P7 | two scans of `ut_suite_cache` for path matching | open | one path-matching CTE | @@ -80,6 +80,30 @@ Consolidated from the checks on 19.20 EE, 21.3 XE and 23ai Free (2026-11-09). - `create or replace package ut_suite_cache_manager` removed the package from `dba_code_role_privs`. Its SQL then failed with `ORA-00942`. - `create or replace package body` keeps the grant. - After changing the spec of a package with the role by hand, rerun [ut3_cbac_modify_objects_role_grants.sql](../source/ut3_cbac_modify_objects_role_grants.sql), or use `development/refresh_ut3.sh`. +10. **A SQL macro can't build SQL from a variable's value.** Tested on 19.20, 2026-11-10, for the tag filter in `get_suite_rows`: + - The setup: a table macro `filter_by(a_rows dbms_tf.table_t, a_filter varchar2)` returning `'select * from a_rows where ' || a_filter`. + - A CTE name is accepted as the `TABLE_T` argument. + - The macro body received `a_filter` as NULL whether it was passed as a literal, a PL/SQL variable or a function call, so the condition was never added. + - A macro is therefore no way to run a predicate computed at run time in static SQL. +11. **Serially reusable packages can't be called from SQL.** `pragma serially_reusable` makes any call during a SQL statement fail with `ORA-06534` (19.20, 2026-11-10). So `ut_suite_tag_filter`, whose `is_matching` runs inside `get_suite_rows`, keeps normal package state for its cache. + +12. **`dbms_utility.compile_schema` can't recompile a body that expands a macro in static SQL.** Seen on 19.20, 2026-11-10: + - Changing the spec of `ut_suite_tag_filter` invalidated the `ut_suite_cache_manager` body. + - `compile_schema`, run as SYS or as `UT3_DEVELOP`, left that body invalid: `ORA-62565` / `PLS-00201: identifier 'UT_ANNOTATION_CACHE_MACROS.GET_CACHED_OBJECTS' must be declared`. + - `alter package ut_suite_cache_manager compile body` (as SYS or `UT3_DEVELOP`) compiled it. + - So recompile such bodies with `alter package ... compile body`. + +#### Other statement-level findings (step 4, 19.20, 2026-11-10) + +- **No `xmltable` row generator next to a recursive CTE.** + - The logical-suite CTEs used `xmltable('1 to 20')` to generate level numbers. Together with the recursive sort CTE in the same statement, its hard parse never finished: `latch: shared pool`, killed after more than 5 minutes. + - A cut-down variant crashed the server process with `ORA-07445 [qmxtrProcCorrOpn]`, in the XML query rewrite. + - `select level from dual connect by level <= 20` parses in 0.3 s. + - Killed sessions stayed stuck in the parse and held a library cache pin on the package; only a database restart cleared them. +- **Make the sibling order explicit.** + - `search depth first by line_no desc, ...` leaves siblings with equal `line_no` (packages without a suitepath, logical suites) in input order. + - The old code's input was sorted by path, as a side effect of `row_number() over (partition by path, ...)`, and tests depend on that order (`test_annotation_cache`). + - The search clause now ends with `path, object_owner`. ## New finding: `get_cached_objects` branches on an argument's value @@ -220,7 +244,22 @@ The new behaviour was accepted on 2026-11-09. It is covered by the context "Suit - No predicate pushing across steps. - Unknown `table()` cardinality: only two statements carry a fixed `cardinality(c 500)` hint. - `value(c)` is moved around instead of columns. -- **Approach:** one statement in `ut_suite_cache_manager`, with each step as a named CTE. It carries columns, not objects, and the final select returns columns that the caller fetches into records for `reconstruct_from_cache`. Don't use `ut_suite_cache_row` objects here; see the `ORA-00600` under P6. It is dynamic SQL because of the tag predicate (see the target design). `ut_suite_tag_filter` keeps only the predicate builder. +- **Approach:** one static statement in `ut_suite_cache_manager`, with each step as a named CTE. `ut_suite_tag_filter.is_matching` evaluates the tag expression per test. +- **Done in step 4:** `ut_suite_cache_manager.get_suite_rows(a_schema_paths, a_skip_access_check, a_tags, a_random_seed)`. + - **CTEs:** `matched_rows` (paths and access, columns only) → `propagate_tags_from_ancestors` (tests only) → `filter_by_tags` → `tagged_rows` (all matched rows when no tags are given) → `suitepaths` / `suitepath_part` / `logical_suites` → `all_items` → `items_for_sort` → `ordered` (recursive). + - **Static SQL.** The first version was dynamic SQL, because the tag expression was compiled into a SQL predicate and concatenated into the statement. Now it is static: `ut_suite_tag_filter.is_matching(tags, tag_expression)` returns 1 or 0 per test. + - `is_matching` takes the condition from `create_where_filter` and evaluates it in an anonymous PL/SQL block on a collection named `tags`. PL/SQL supports the same `member of`, `is empty` and `is null` conditions. + - Both functions are `deterministic`. That caches only calls from SQL, so `create_where_filter` also keeps the last expression and its condition in package variables. Repeated calls from `is_matching` then skip parsing the expression. + - **Tags are passed as text, not as a collection.** Oracle caches a `deterministic` function called from SQL only when every argument is a scalar. Measured on 19.20: with 1000 rows and 3 distinct values, the function ran 3 times with scalar arguments and 1000 times with a nested-table argument, whether built by a constructor, read from a column, or built by `cast(collect())`, even inside a scalar subquery. + - `propagate_tags_from_ancestors` therefore builds `listagg(distinct tag, ',') within group (order by tag)`, and `is_matching(a_tags varchar2, ...)` splits it back with `ut_utils.string_to_table`. Tags can't contain commas, because `--%tags` splits on them. `is_matching` then runs once per distinct set of tags. + - The test `is_matching_is_cached_in_sql` checks this. It counts how often the anonymous block inside `is_matching` runs (via `v$sqlarea`, through `ut3_tester_helper.main_helper.get_sql_executions`) while 1000 rows with 3 distinct tag sets are filtered. Compiled without `deterministic`, the block ran 1000 times and the test failed; with it, the test passes. + - An invalid tag expression raises `gc_invalid_tag_expression` from `is_matching`, so only when a test is evaluated. On a path without tests, the run reports "not found" instead. + - `create_where_filter` is private to `ut_suite_tag_filter`. Its tests now check `is_matching` results instead of the generated condition text. + - `ut_suite_tag_filter` is granted to the CBAC role, because `is_matching` is called from SQL in an invoker-rights package. + - **Final select:** reads the full rows of real items by `id` and builds the logical suites. It returns `ut_suite_cache_rows`, because `reconcile_paths_and_suites` (P5) joins a collection; `reconstruct_from_cache` converts that to records (P6). + - **Path matching:** `exists` against the paths replaces the join plus `row_number` deduplication. `(object_owner, path)` is unique in `ut_suite_cache`. + - **Removed:** `get_suite_items`, `get_cached_suite_rows` (and cursor `c_get_bulk_cache_suite`), `sort_and_randomize_tests`, `get_cached_suite_info`, and `ut_suite_tag_filter.apply` / `get_tags_suites`. + - **Both flows** call `get_suite_rows`; the suite-info flow passes no tags and no seed. ### P3: enrich a collection with generated rows @@ -229,14 +268,14 @@ The new behaviour was accepted on 2026-11-09. It is covered by the context "Suit - **Notes:** - Path depth is capped by `xmltable('1 to 20')`. **Verify** what happens beyond 20 levels: logical parents above level 20 would be missing. - Levels are counted with `regexp_count(path, '\w+')`, which does not count `$` and `#`, both allowed in path parts. -- **Approach:** a CTE of the main statement, placed after the access and tag filters. +- **Approach:** a CTE of the main statement, placed after the access and tag filters. **Done in step 4.** The level generator is now `connect by level <= 20` instead of `xmltable` (see "Other statement-level findings"). The 20-level limit and the `\w+` counting are unchanged. ### P4: in/out collection reorder with a self-join - **Where:** `sort_and_randomize_tests` ([ut_suite_cache_manager.pkb:214](../source/core/ut_suite_cache_manager.pkb:214)). - **What:** a recursive CTE walks the hierarchy over `table(a_suite_rows)`, then joins back to `table(a_suite_rows)` to recover the objects. The result is copied and assigned back to the in/out parameter. - **Cost:** two scans of the collection plus one copy. `ut_utils.hash_suite_path` is called from SQL for each row (`ut_utils` is granted to the role). -- **Approach:** the last CTE of the main statement, with `order by order1 desc` as the final `order by`. +- **Approach:** the last CTE of the main statement, with `order by order1 desc` as the final `order by`. **Done in step 4**, with `path, object_owner` added as the last sort keys (see "Other statement-level findings"). ### P5: validate by joining two collections @@ -326,7 +365,7 @@ resolve paths, refresh cache ──paths, tags──▶ get_suite_rows(a_pa tagged_rows tag predicate from the tag filter ← P2 with_logical generated logical suites ← P3 ordered recursive sort / randomise ← P4 - ◀──rows────── rows fetched as records (tt_cached_suites), not objects + ◀──rows────── ut_suite_cache_rows; reconstruct_from_cache converts them to records reconcile(paths, rows) ← P5 reconstruct_from_cache(rows) no ref cursor ← P6 @@ -334,7 +373,7 @@ get_suites_info ──paths──────▶ get_suite_i the same statement text, no tags, no sort, ◀──cursor──── final select ut_suite_item_info, ordered ← P9 -ut_suite_tag_filter: only create_where_filter (tag expression → SQL predicate). apply / get_tags_suites go. +ut_suite_tag_filter: only create_where_filter (tag expression → SQL predicate). apply / get_tags_suites are gone (step 4). ut_annotation_cache_macros: unchanged; the only macro package. ``` @@ -372,7 +411,23 @@ Notes: - Setup: a fresh 19.20 container, then `development/install.sh` and `test/install_tests.sh`. - Install: no invalid objects. - Full run: 1140 tests, 0 failed, 0 errored, 3 disabled. -4. **P2/P3/P4: one statement.** Merge `get_suite_items` → tags → logical suites → sort into one dynamic statement, and reduce `ut_suite_tag_filter` to `create_where_filter`. Rewrite the `apply` tests in `test_ut_suite_tag_filter` against the new entry point; don't keep `apply` as a test-only wrapper (YAGNI). +4. **P2/P3/P4: one statement. Done.** + - `get_suite_rows` replaces four functions and the tag filter's `apply`; see P2. + - The #1324 regression test in `test_ut_suite_tag_filter` now creates a real package (suitepath, suite, context and test tags). It checks `get_suite_rows` with the same 8 tag expressions as before. + - Two Oracle-level problems came up and are fixed: the `xmltable` parse hang and crash, and the sibling order. See "Other statement-level findings". + - **Verified on 2026-11-10:** + - Setup: a fresh 19.20 container with install and test install. + - Install: no invalid objects. + - First full run: 11 failures, all from the sibling order. + - Final full run, on the same database with only the cache manager body recompiled: 1144 tests, 0 failed, 0 errored, 3 disabled. + - **Static SQL version, verified on 2026-11-10:** + - Setup: a fresh 19.20 container with install and test install. + - Install: no invalid objects. + - Full run: 1143 tests, 0 failed, 0 errored, 3 disabled. That is 1140 plus 3 new `is_matching` tests in `test_ut_suite_tag_filter`. + - **Text tags version, verified on 2026-11-10:** + - The same database after a full run, with only the `ut_suite_cache_manager` and test bodies recompiled. + - Full run: 1148 tests, 0 failed, 0 errored, 3 disabled. That is 1144 (1140 plus 4 `is_matching` tests) plus the 4 tests `test_tfs_junit_reporter` leaves behind. + - **Why 1144:** 1140 tests, plus 4 from packages that `test_tfs_junit_reporter` leaves behind when run twice on one database. Its `remove_test_package` doesn't drop `check_junit_in_context`, `check_junit_out_context` and `check_junit_inout_context`. That test bug predates this work. 5. **P7: merge `expand_paths` into the path CTE.** This is the riskiest step. Wildcard semantics and error messages are covered by `test_ut_run` / `test_ut_runner` in `ut3_user`. Do it last among the merges, with those suites as the safety net. 6. **P9: Flow B on the same statement text.** Remove `get_cached_suite_info` and `get_suite_items_info` from the spec, and merge finding 2. diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index c8dc09f09..218bab758 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -19,55 +19,6 @@ create or replace noneditionable package body ut_suite_cache_manager is /* * Private code */ - cursor c_get_bulk_cache_suite(cp_suite_items in ut_suite_cache_rows) is - with - suite_items as ( - select /*+ cardinality(c 500) */ value(c) as obj - from table(cp_suite_items) c), - suitepaths as ( - select distinct substr(c.obj.path,1,instr(c.obj.path,'.',-1)-1) as suitepath, - c.obj.path as path, - c.obj.object_owner as object_owner - from suite_items c - where c.obj.self_type = 'UT_SUITE' - ), - gen as ( - select rownum as pos - from xmltable('1 to 20') - ), - suitepath_part AS ( - select distinct - substr(b.suitepath, 1, instr(b.suitepath || '.', '.', 1, g.pos) -1) as path, - object_owner - from suitepaths b - join gen g - on g.pos <= regexp_count(b.suitepath, '\w+') - ), - logical_suite_data as ( - select 'UT_LOGICAL_SUITE' as self_type, p.path, p.object_owner, - upper( substr(p.path, instr( p.path, '.', -1 ) + 1 ) ) as object_name, - cast(null as &&ut3_owner..ut_executables) as x, - cast(null as &&ut3_owner..ut_varchar2_rows) as y, - cast(null as &&ut3_owner..ut_executable_test) as z - from suitepath_part p - where p.path - not in (select s.path from suitepaths s) - ), - logical_suites as ( - select &&ut3_owner..ut_suite_cache_row( - null, - s.self_type, s.path, s.object_owner, s.object_name, - s.object_name, null, null, null, null, 0,null, - &&ut3_owner..ut_varchar2_rows(), - s.x, s.x, s.x, s.x, s.x, s.x, - s.y, null, s.z - ) as obj - from logical_suite_data s - ) - select /*+ no_parallel */ obj from suite_items - union all - select /*+ no_parallel */ obj from logical_suites; - function group_paths_by_schema(a_paths ut_varchar2_list) return ut_path_items is c_package_path_regex constant varchar2(100) := '^([[:alnum:]$#_]+)(\.([[:alnum:]$#_\*]+))?(\.([[:alnum:]$#_\*]+))?$'; l_results ut_path_items := ut_path_items(); @@ -168,95 +119,6 @@ create or replace noneditionable package body ut_suite_cache_manager is return l_schema_paths; end; - /* - Get a suite items rows that matching our criteria like - path,object_name etc. - We need to consider also an wildcard character on our procedures and object - names. - Were the path is populated we need to make sure we dont return duplicates - as the wildcard can produce multiple results from same path and - parents and child for each can be same resulting in duplicates - Only items of packages the invoking user can access are returned, unless a_skip_access_check is true. - */ - function get_suite_items ( - a_schema_paths ut_path_items, - a_skip_access_check boolean - ) return ut_suite_cache_rows is - l_suite_items ut_suite_cache_rows := ut_suite_cache_rows(); - l_skip_access_check varchar2(1) := case when a_skip_access_check then 'Y' else 'N' end; - begin - select obj bulk collect into l_suite_items - from ( - select /*+ cardinality(c 500) no_expand */ value(c) as obj,row_number() over ( partition by path,object_owner order by path,object_owner asc) as r_num - from &&ut3_owner..ut_suite_cache c, - table(a_schema_paths) sp - where c.object_owner = upper(sp.schema_name) - and ((sp.suite_path is not null and sp.suite_path||'.' like c.path||'.%' /*all parents and self*/ - or - ( - c.path||'.' like sp.suite_path||'.%' /*all children and self*/ - and c.object_name like nvl(upper(sp.object_name),c.object_name) - and c.name like nvl(upper(sp.procedure_name),c.name) - )) - or - ( sp.suite_path is null - and c.object_name = nvl(upper(sp.object_name),c.object_name) - and c.name = nvl(upper(sp.procedure_name),c.name))) - and ( l_skip_access_check = 'Y' - or exists ( - select 1 - from all_objects a - where a.owner = c.object_owner - and a.object_name = c.object_name - and a.object_type = 'PACKAGE' - ) - ) - ) where r_num =1; - return l_suite_items; - end; - - /* - We will sort a suites in hierarchical structure. - Sorting from bottom to top so when we consolidate - we will go in proper order. - For random seed we will add an extra sort that can be null. - The object owner is irrelevant on joing via path as we already - resolved a list of test we want to use so as long they share a suitepath - they are correct. - */ - procedure sort_and_randomize_tests( - a_suite_rows in out ut_suite_cache_rows, - a_random_seed positive := null) - is - l_suite_rows ut_suite_cache_rows; - begin - with - extract_parent_child as ( - select s.path, substr(s.path,1,instr(s.path,'.',-1,1)-1) as parent_path,s.object_owner, - case when a_random_seed is null then s.line_no end line_no, - case when a_random_seed is not null then &&ut3_owner..ut_utils.hash_suite_path(s.path, a_random_seed) end random_seed - from table(a_suite_rows) s), - t1(path,parent_path,object_owner,line_no,random_seed) as ( - --Anchor member - select s.path, parent_path,s.object_owner,s.line_no,random_seed - from extract_parent_child s - where parent_path is null - union all - --Recursive member - select t2.path, t2.parent_path,t2.object_owner,t2.line_no,t2.random_seed - from t1,extract_parent_child t2 - where t2.parent_path = t1.path - and t2.object_owner = t1.object_owner) - search depth first by line_no desc,random_seed desc nulls last set order1 - select value(i) as obj - bulk collect into l_suite_rows - from t1 c - join table(a_suite_rows) i on i.object_owner = c.object_owner and i.path = c.path - order by order1 desc; - - a_suite_rows := l_suite_rows; - end; - /* * Public code */ @@ -266,19 +128,151 @@ create or replace noneditionable package body ut_suite_cache_manager is return expand_paths(group_paths_by_schema(a_paths)); end; - function get_cached_suite_rows( - a_suites_filtered ut_suite_cache_rows + /* + Returns suite items for the paths in one statement, sorted bottom up, so that reconstruct_from_cache in ut_suite_manager + can build the suite hierarchy in a single pass. The statement: + - matched_rows: cache rows matching the paths (all parents and children of a suite path, or the package / procedure), + only for packages the invoking user can access, unless a_skip_access_check is true + - tagged_rows: when tags are given, the rows having a test matching the tag expression below them (or being one); + a test inherits the tags of the suites and contexts above it + - logical_suites: suites for the parts of the suitepaths that have no package behind them + - ordered: the hierarchy sorted depth first by line number, or by a hash of the path when a_random_seed is given + The tag expression is evaluated per test by ut_suite_tag_filter.is_matching, so the statement is static SQL. + */ + function get_suite_rows( + a_schema_paths ut_path_items, + a_skip_access_check boolean, + a_tags varchar2 := null, + a_random_seed positive := null ) return ut_suite_cache_rows is - l_results ut_suite_cache_rows := ut_suite_cache_rows(); - begin + l_results ut_suite_cache_rows; + l_skip_access_check varchar2(1) := case when a_skip_access_check then 'Y' else 'N' end; + begin + with + matched_rows as ( + select /*+ no_parallel */ c.id, c.self_type, c.path, c.object_owner, c.object_name, c.line_no, c.tags + from &&ut3_owner..ut_suite_cache c + where exists ( + select /*+ no_expand */ 1 + from table(a_schema_paths) sp + where c.object_owner = upper(sp.schema_name) + and ( ( sp.suite_path is not null + and ( sp.suite_path||'.' like c.path||'.%' /* all parents and self */ + or ( c.path||'.' like sp.suite_path||'.%' /* all children and self */ + and c.object_name like nvl(upper(sp.object_name),c.object_name) + and c.name like nvl(upper(sp.procedure_name),c.name) + ) + ) + ) + or ( sp.suite_path is null + and c.object_name = nvl(upper(sp.object_name),c.object_name) + and c.name = nvl(upper(sp.procedure_name),c.name) + ) + ) + ) + and ( l_skip_access_check = 'Y' + or exists ( + select 1 + from all_objects a + where a.owner = c.object_owner + and a.object_name = c.object_name + and a.object_type = 'PACKAGE' + ) + ) + ), + propagate_tags_from_ancestors as ( + select c.id, c.self_type, c.path, c.object_owner, listagg(distinct c_tags.tag, ',') within group (order by c_tags.tag) as tags + from matched_rows c + left join matched_rows t + on t.self_type in ('UT_SUITE','UT_SUITE_CONTEXT') + and c.path like t.path||'.%' /* all descendants */ + and c.object_owner = t.object_owner + outer apply (select column_value tag from table(c.tags) union select column_value tag from table(t.tags) ) c_tags + where c.self_type = 'UT_TEST' + group by c.id, c.self_type, c.path, c.object_owner + ), + filter_by_tags as ( + select x.path, x.object_owner + from propagate_tags_from_ancestors x + where &&ut3_owner..ut_suite_tag_filter.is_matching(x.tags, a_tags) = 1 + ), + tagged_rows as ( + select /*+ no_expand */ item.* + from matched_rows item + where a_tags is null + or exists ( + select 1 + from filter_by_tags tst + where tst.path||'.' like item.path || '.%' /* all descendants and self */ + and tst.object_owner = item.object_owner + ) + ), + suitepaths as ( + select distinct substr(c.path,1,instr(c.path,'.',-1)-1) as suitepath, c.path, c.object_owner + from tagged_rows c + where c.self_type = 'UT_SUITE' + ), + gen as ( + --not xmltable('1 to 20'): together with the recursive "ordered" below it makes the parse hang or fail with ORA-07445 [qmxtrProcCorrOpn] on 19.20 + select level as pos from dual connect by level <= 20 + ), + suitepath_part as ( + select distinct substr(b.suitepath, 1, instr(b.suitepath || '.', '.', 1, g.pos) -1) as path, b.object_owner + from suitepaths b + join gen g + on g.pos <= regexp_count(b.suitepath, '\w+') + ), + logical_suites as ( + select p.path, p.object_owner, upper( substr(p.path, instr( p.path, '.', -1 ) + 1 ) ) as object_name + from suitepath_part p + where p.path not in (select s.path from suitepaths s) + ), + all_items as ( + select t.id, t.path, t.object_owner, t.object_name, t.line_no + from tagged_rows t + union all + select null as id, l.path, l.object_owner, l.object_name, null as line_no + from logical_suites l + ), + items_for_sort as ( + select a.id, a.path, substr(a.path,1,instr(a.path,'.',-1,1)-1) as parent_path, a.object_owner, a.object_name, + case when a_random_seed is null then a.line_no end as line_no, + case when a_random_seed is not null then &&ut3_owner..ut_utils.hash_suite_path(a.path, a_random_seed) end as random_seed + from all_items a + ), + ordered(id, path, parent_path, object_owner, object_name, line_no, random_seed) as ( + select s.id, s.path, s.parent_path, s.object_owner, s.object_name, s.line_no, s.random_seed + from items_for_sort s + where s.parent_path is null + union all + select s.id, s.path, s.parent_path, s.object_owner, s.object_name, s.line_no, s.random_seed + from ordered o + join items_for_sort s + on s.parent_path = o.path + and s.object_owner = o.object_owner + ) + --path, object_owner: siblings with the same line number (packages, logical suites) keep the order of their paths + search depth first by line_no desc, random_seed desc nulls last, path, object_owner set order1 + select /*+ no_parallel */ + case + when o.id is not null then value(c) + else &&ut3_owner..ut_suite_cache_row( + null, 'UT_LOGICAL_SUITE', o.path, o.object_owner, o.object_name, o.object_name, + null, null, null, null, 0, null, + &&ut3_owner..ut_varchar2_rows(), + null, null, null, null, null, null, + null, null, null + ) + end + bulk collect into l_results + from ordered o + left join &&ut3_owner..ut_suite_cache c + on c.id = o.id + order by o.order1 desc; - open c_get_bulk_cache_suite(a_suites_filtered); - fetch c_get_bulk_cache_suite bulk collect into l_results; - close c_get_bulk_cache_suite; - return l_results; end; - + function get_schema_parse_time(a_schema_name varchar2) return timestamp result_cache is l_cache_parse_time timestamp; begin @@ -414,14 +408,6 @@ create or replace noneditionable package body ut_suite_cache_manager is commit; end; - function get_cached_suite_info( - a_schema_paths ut_path_items, - a_skip_access_check boolean - ) return ut_suite_cache_rows is - begin - return get_cached_suite_rows(get_suite_items(a_schema_paths, a_skip_access_check)); - end; - function get_suite_items_info( a_suite_cache_items ut_suite_cache_rows ) return ut_suite_items_info is diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index 03af41ca8..ad7d3762a 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -45,48 +45,25 @@ create or replace noneditionable package ut_suite_cache_manager authid current_u */ procedure remove_missing_objs_from_cache(a_schema_name varchar2); - /* - * We will sort a suites in hierarchical structure. - * Sorting from bottom to top so when we consolidate - * we will go in proper order. - */ - procedure sort_and_randomize_tests( - a_suite_rows in out ut_suite_cache_rows, - a_random_seed positive := null); - - /* - * Retrieves suite items data from cache. - * Returned data is not filtered by user access rights. - * Not to be used publicly. Used internally for building suites at runtime. - */ - function get_cached_suite_rows( - a_suites_filtered ut_suite_cache_rows - ) return ut_suite_cache_rows; - function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items; - + /* - * Retrieves suite item rows from cache, with logical suites added. + * Retrieves suite items matching the paths from cache, with logical suites added for suitepaths without a package. * Returns only items of packages the invoking user can access, unless a_skip_access_check is true. - * Not to be used publicly. Used internally for building suites info. + * When a_tags is given, returns only items with a test matching the tag expression below them (or being one). + * The rows are sorted bottom up: children before parents, by line number or, when a_random_seed is given, randomly. + * Not to be used publicly. Used internally for building suites at runtime and suites info. */ - function get_cached_suite_info( + function get_suite_rows( a_schema_paths ut_path_items, - a_skip_access_check boolean + a_skip_access_check boolean, + a_tags varchar2 := null, + a_random_seed positive := null ) return ut_suite_cache_rows; function get_suite_items_info( a_suite_cache_items ut_suite_cache_rows ) return ut_suite_items_info; - - /* - * Retrieves suite item rows matching the paths from cache. - * Returns only items of packages the invoking user can access, unless a_skip_access_check is true. - */ - function get_suite_items ( - a_schema_paths ut_path_items, - a_skip_access_check boolean - ) return ut_suite_cache_rows; /* * Retrieves list of cached suite packages. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 397f4062e..ae2cff4d6 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -250,7 +250,7 @@ create or replace noneditionable package body ut_suite_manager is end; /* - Builds the suite hierarchy from cache rows sorted bottom-up (see ut_suite_cache_manager.sort_and_randomize_tests) + Builds the suite hierarchy from cache rows sorted bottom-up (see ut_suite_cache_manager.get_suite_rows) and propagates the rollback type of top level suites to their items. The rows are converted to records with SQL before use. Building ut_test objects from the item attribute @@ -336,18 +336,13 @@ create or replace noneditionable package body ut_suite_manager is a_tags varchar2 := null, a_skip_all_objects boolean := false ) return ut_suite_cache_rows is - l_accessible_rows ut_suite_cache_rows; - l_tag_filter_applied ut_suite_cache_rows; l_suite_rows ut_suite_cache_rows; begin - l_accessible_rows := ut_suite_cache_manager.get_suite_items(a_schema_paths, skip_access_check(a_skip_all_objects)); - - l_tag_filter_applied := ut_suite_tag_filter.apply(l_accessible_rows,a_tags); - l_suite_rows := ut_suite_cache_manager.get_cached_suite_rows(l_tag_filter_applied); + l_suite_rows := ut_suite_cache_manager.get_suite_rows( + a_schema_paths, skip_access_check(a_skip_all_objects), a_tags, a_random_seed + ); reconcile_paths_and_suites(a_schema_paths,l_suite_rows); - ut_suite_cache_manager.sort_and_randomize_tests(l_suite_rows,a_random_seed); - return l_suite_rows; end; @@ -556,7 +551,7 @@ create or replace noneditionable package body ut_suite_manager is l_schema := l_schema_names.next(l_schema); end loop; l_schema_paths := ut_suite_cache_manager.get_schema_paths(l_paths); - l_suite_rows := ut_suite_cache_manager.get_cached_suite_info(l_schema_paths, skip_access_check()); + l_suite_rows := ut_suite_cache_manager.get_suite_rows(l_schema_paths, skip_access_check()); l_all_suite_info := ut_suite_cache_manager.get_suite_items_info(l_suite_rows); open l_result for select /*+ no_parallel */ value(c) diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index 870099ea4..f6c5f7e05 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -28,6 +28,10 @@ create or replace noneditionable package body ut_suite_tag_filter is type t_precedence_table is table of number index by varchar2(1); g_precedence t_precedence_table; + --last tag expression and its condition, see create_where_filter + g_last_tag_expression varchar2(4000); + g_last_where_filter varchar2(32767); + function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list is l_tags_tokens ut_varchar2_list := ut_varchar2_list(); begin @@ -202,81 +206,37 @@ create or replace noneditionable package body ut_suite_tag_filter is return l_infix_stack.pop; end conv_postfix_to_infix_sql; + /* + Generates a condition on a collection named "tags" from a tag expression. + Raises ut_utils.gc_invalid_tag_expression for an invalid expression. + */ function create_where_filter(a_tags varchar2 - ) return varchar2 is + ) return varchar2 deterministic is l_tags varchar2(4000); begin + --deterministic caches results only for calls from SQL, so the last result is also kept for repeated calls from is_matching + if g_last_tag_expression = a_tags then + return g_last_where_filter; + end if; l_tags := replace(replace_legacy_tag_notation(a_tags),' '); l_tags := conv_postfix_to_infix_sql(shunt_logical_expression(tokenize_tags_string(l_tags)),'tags'); l_tags := replace(l_tags, '|',' or '); l_tags := replace(l_tags ,'&',' and '); l_tags := replace(l_tags ,'!','not'); + g_last_tag_expression := a_tags; + g_last_where_filter := l_tags; return l_tags; end; - - /* - Having a base set of suites we will do a further filter down if there are - any tags defined. - */ - function get_tags_suites ( - a_suite_items ut_suite_cache_rows, - a_tags varchar2 - ) return ut_suite_cache_rows is - l_results ut_suite_cache_rows; - l_sql varchar2(32000); - l_tags_filter_clause varchar2(4000):= create_where_filter(a_tags); + function is_matching(a_tags varchar2, a_tag_expression varchar2) return integer deterministic is + l_result integer; begin - l_sql := - q'[ - with - suites_mv as ( - select c.id,value(c) as obj,c.path as path,c.self_type,c.object_owner,c.tags as tags - from table(:suite_items) c - ), - propagate_tags_from_ancestors as ( - select c.id, c.self_type, c.path, c.object_owner, cast(collect(c_tags.tag) as ut_varchar2_rows) as tags - from suites_mv c - left join suites_mv t - on t.self_type in ('UT_SUITE','UT_SUITE_CONTEXT') - and c.path like t.path||'.%' /* all descendants */ - and c.object_owner = t.object_owner - outer apply (select column_value tag from table(c.tags) union select column_value tag from table(t.tags) ) c_tags - group by c.id, c.self_type, c.path, c.object_owner - ), - filter_by_tags as ( - select * - from propagate_tags_from_ancestors x - where ( ]'||l_tags_filter_clause||q'[ ) - ), - only_items_with_tests as ( - select item.obj - from suites_mv item - where exists ( - select 1 - from filter_by_tags tst - where tst.self_type in ('UT_TEST') - and (tst.path||'.' like item.path || '.%' /*all descendants and self*/ and item.object_owner = tst.object_owner) - ) - ) - select obj from only_items_with_tests]'; - execute immediate l_sql bulk collect into l_results using a_suite_items; - - return l_results; + execute immediate + 'declare tags ut_varchar2_list := :a_tags; begin :a_result := case when '||create_where_filter(a_tag_expression)||' then 1 else 0 end; end;' + using in ut_utils.string_to_table(a_tags, ','), out l_result; + return l_result; end; - function apply( - a_unfiltered_rows ut_suite_cache_rows, - a_tags varchar2 := null - ) return ut_suite_cache_rows is - l_suite_items ut_suite_cache_rows := a_unfiltered_rows; - begin - if length(a_tags) > 0 then - l_suite_items := get_tags_suites(l_suite_items,a_tags); - end if; - - return l_suite_items; - end; begin --Define operators precedence diff --git a/source/core/ut_suite_tag_filter.pks b/source/core/ut_suite_tag_filter.pks index afb634014..ab49768e9 100644 --- a/source/core/ut_suite_tag_filter.pks +++ b/source/core/ut_suite_tag_filter.pks @@ -17,7 +17,8 @@ create or replace noneditionable package ut_suite_tag_filter authid definer is */ /** - * Package that will filter suites by tags + * Package that evaluates tag expressions against the tags of suite items. + * is_matching is called from SQL by ut_suite_cache_manager.get_suite_rows to filter suites by tags. * */ @@ -41,15 +42,14 @@ create or replace noneditionable package ut_suite_tag_filter authid definer is return varchar2; /* - * Generates a part where clause sql - */ - function create_where_filter(a_tags varchar2) - return varchar2; - - function apply( - a_unfiltered_rows ut_suite_cache_rows, - a_tags varchar2 := null - ) return ut_suite_cache_rows; + * Returns 1 when the tags match the tag expression, 0 otherwise. + * a_tags is a comma-separated list of tags (tags cannot contain commas), null for no tags. + * Takes text, not a collection: Oracle caches results of a deterministic function called from SQL + * only when all arguments are scalars, so items with the same tags are evaluated once per statement. + * Raises ut_utils.gc_invalid_tag_expression for an invalid expression. + */ + function is_matching(a_tags varchar2, a_tag_expression varchar2) + return integer deterministic; end ut_suite_tag_filter; / diff --git a/source/ut3_cbac_modify_objects_role_grants.sql b/source/ut3_cbac_modify_objects_role_grants.sql index 0447f9e8e..e62b0e178 100644 --- a/source/ut3_cbac_modify_objects_role_grants.sql +++ b/source/ut3_cbac_modify_objects_role_grants.sql @@ -50,6 +50,7 @@ grant execute on &&ut3_owner..ut_varchar2_rows to &&ut3_owner._cbac_modify_ob grant execute on &&ut3_owner..ut_path_item to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_object_name to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_utils to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_suite_tag_filter to &&ut3_owner._cbac_modify_objects_role; grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_cache_manager; grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_manager; diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index 32610edf6..c638aab46 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -71,52 +71,136 @@ create or replace package body test_ut_suite_tag_filter is ut.fail('Expected exception but nothing was raised'); end; - procedure conv_from_tag_to_sql_filter is - l_sql_filter varchar2(4000); + procedure is_matching_or_and_not is begin - l_sql_filter := ut3_develop.ut_suite_tag_filter.create_where_filter('test1'); - ut.expect(l_sql_filter).to_equal(q'['test1' member of tags]'); - - l_sql_filter := ut3_develop.ut_suite_tag_filter.create_where_filter('test1|test2'); - ut.expect(l_sql_filter).to_equal(q'[('test1' member of tags or 'test2' member of tags)]'); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test1', 'test1') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test2', 'test1') ).to_equal(0); - l_sql_filter := ut3_develop.ut_suite_tag_filter.create_where_filter('test1|!test2'); - ut.expect(l_sql_filter).to_equal(q'[('test1' member of tags or not('test2' member of tags))]'); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test2', 'test1|test2') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test3', 'test1|test2') ).to_equal(0); - l_sql_filter := ut3_develop.ut_suite_tag_filter.create_where_filter('test1&!test2'); - ut.expect(l_sql_filter).to_equal(q'[('test1' member of tags and not('test2' member of tags))]'); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test3', 'test1|!test2') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test2', 'test1|!test2') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test1,test2', 'test1|!test2') ).to_equal(1); + + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test1', 'test1&!test2') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test1,test2', 'test1&!test2') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test3', 'test1&!test2') ).to_equal(0); + end; + + procedure is_matching_evaluates_tags is + l_tags varchar2(100) := 'db,slow'; + begin + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, 'slow') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, 'fast') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, 'slow&db') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, 'slow&!db') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, 'fast|db') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, '!fast') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, '(fast|slow)&!(db&fast)') ).to_equal(1); + --legacy notation: "," is or, "-" is not + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, 'fast,slow') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, 'fast,-slow') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, 'none') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(l_tags, 'any') ).to_equal(1); + end; + + procedure is_matching_without_tags is + begin + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, 'none') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, 'any') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, '!slow') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, 'slow') ).to_equal(0); + end; + + procedure is_matching_is_cached_in_sql is + c_block constant varchar2(100) := 'declare tags ut_varchar2_list := :a_tags;%''cache_probe'' member of tags%'; + l_before number; + l_after number; + l_count integer; + begin + l_before := ut3_tester_helper.main_helper.get_sql_executions(c_block); + --1000 rows with 3 distinct sets of tags + select count(*) into l_count + from (select mod(level,3) k from dual connect by level <= 1000) + where ut3_develop.ut_suite_tag_filter.is_matching('t'||k||',x', 'cache_probe') = 0; + l_after := ut3_tester_helper.main_helper.get_sql_executions(c_block); + ut.expect( l_count ).to_equal(1000); + ut.expect( l_after - l_before ).to_be_less_or_equal(3); + end; + + procedure is_matching_invalid_expression is + l_result integer; + begin + l_result := ut3_develop.ut_suite_tag_filter.is_matching('slow', 'slow&|db'); + end; + + procedure create_tags_suite is + pragma autonomous_transaction; + begin + execute immediate q'[create or replace package test_tags_1324 as + --%suite + --%suitepath(some.path) + --%tags(slow) + + --%context(tags_are_applied_in_contexts) + --%tags(context_tag) + + --%test + --%tags(test_tag) + procedure create_new_mapping; + + --%endcontext + end;]'; + execute immediate q'[create or replace package body test_tags_1324 as + procedure create_new_mapping is begin null; end; + end;]'; + end; + + procedure drop_tags_suite is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_tags_1324'; end; procedure filtering_is_correctly_applied_to_all_items is - l_input_data ut3_develop.ut_suite_cache_rows; - l_expected sys_refcursor; - l_actual sys_refcursor; + l_paths ut3_develop.ut_path_items; + l_suites ut3_develop.ut_suite_items; + l_items ut3_develop.ut_suite_cache_rows; + l_expected sys_refcursor; + l_actual sys_refcursor; + + --suite items selected by the tag expression, without the logical suites "some" and "some.path" + function get_items(a_tags varchar2) return ut3_develop.ut_suite_cache_rows is + l_rows ut3_develop.ut_suite_cache_rows; + l_result ut3_develop.ut_suite_cache_rows; + begin + l_rows := ut3_develop.ut_suite_cache_manager.get_suite_rows( l_paths, true, a_tags ); + select value(r) bulk collect into l_result from table(l_rows) r where r.self_type != 'UT_LOGICAL_SUITE'; + return l_result; + end; begin - l_input_data := ut3_develop.ut_suite_cache_rows( - ut3_develop.ut_suite_cache_row( - 1, 'UT_SUITE', 'some.path.test_tags', 'TEST_USER', 'TEST_TAGS', 'TEST_TAGS', 3, timestamp '2026-05-06 10:23:38.461299', NULL, NULL, 0, NULL, null, null, null, null, null, null, null, null, - ut3_develop.ut_varchar2_rows('slow'), null), - ut3_develop.ut_suite_cache_row( - 2, 'UT_SUITE_CONTEXT', 'some.path.test_tags.nested_context_#1', 'TEST_USER', 'TEST_TAGS', 'NESTED_CONTEXT_#1', 9, timestamp '2026-05-06 10:23:38.461299', 'tags_are_applied_in_contexts', NULL, 0, NULL, null, null, null, null, null, null, null, null, - ut3_develop.ut_varchar2_rows('context_tag'), null), - ut3_develop.ut_suite_cache_row( - 3, 'UT_TEST', 'some.path.test_tags.nested_context_#1.create_new_mapping', 'TEST_USER', 'TEST_TAGS', 'CREATE_NEW_MAPPING', 11, timestamp '2026-05-06 10:23:38.461299', NULL, NULL, 0, NULL, null, null, null, null, null, null, null, null, - ut3_develop.ut_varchar2_rows('test_tag'), ut3_develop.ut_executable_test('UT_EXECUTABLE_TEST', 'test', 'TEST_USER', 'test_tags', 'create_new_mapping', NULL, NULL, NULL, NULL, NULL)) - ); - - ut.expect(ut3_develop.ut_suite_tag_filter.apply( l_input_data, 'slow').count).to_equal(3 ); - - open l_expected for select * from table( l_input_data ); - open l_actual for select * from table( ut3_develop.ut_suite_tag_filter.apply( l_input_data, 'slow') ); - ut.expect(l_actual).to_equal(l_expected).join_by('ID'); - - ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, '!slow').count ).to_equal(0); - ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, 'bad').count ).to_equal(0); - ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, '!bad').count ).to_equal(3); - ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, '!context_tag').count ).to_equal(0); - ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, 'context_tag').count ).to_equal(3); - ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, '!test_tag').count ).to_equal(0); - ut.expect( ut3_develop.ut_suite_tag_filter.apply(l_input_data, 'test_tag').count ).to_equal(3); + --refresh the suite cache of the schema + l_suites := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list('ut3_tester.test_tags_1324')); + l_paths := ut3_develop.ut_suite_cache_manager.get_schema_paths(ut3_develop.ut_varchar2_list('ut3_tester.test_tags_1324')); + + l_items := get_items('slow'); + ut.expect( l_items.count ).to_equal(3); + + open l_expected for + select 'some.path.test_tags_1324' as path from dual union all + select 'some.path.test_tags_1324.nested_context_#1' from dual union all + select 'some.path.test_tags_1324.nested_context_#1.create_new_mapping' from dual; + open l_actual for select r.path from table( l_items ) r; + ut.expect(l_actual).to_equal(l_expected).unordered(); + + ut.expect( get_items('!slow').count ).to_equal(0); + ut.expect( get_items('bad').count ).to_equal(0); + ut.expect( get_items('!bad').count ).to_equal(3); + ut.expect( get_items('!context_tag').count ).to_equal(0); + ut.expect( get_items('context_tag').count ).to_equal(3); + ut.expect( get_items('!test_tag').count ).to_equal(0); + ut.expect( get_items('test_tag').count ).to_equal(3); end; end test_ut_suite_tag_filter; diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pks b/test/ut3_tester/core/test_ut_suite_tag_filter.pks index e7b255d4b..eb38d0a59 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pks +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pks @@ -30,10 +30,28 @@ create or replace package test_ut_suite_tag_filter is --%endcontext - --%test( Test conversion of expression from tag into custom where filter for SQL) - procedure conv_from_tag_to_sql_filter; + --%test( Evaluates or, and and not in tag expressions) + procedure is_matching_or_and_not; + + --%test( Evaluates tag expressions against a list of tags) + procedure is_matching_evaluates_tags; + + --%test( Evaluates none and any for items without tags) + procedure is_matching_without_tags; + + --%test( Evaluates each distinct set of tags once per SQL statement) + procedure is_matching_is_cached_in_sql; + + --%test( Raises exception for an invalid tag expression) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure is_matching_invalid_expression; + + procedure create_tags_suite; + procedure drop_tags_suite; --%test( Regression for issue #1324 - corect filtering by tags with suitepath and contexts) + --%beforetest(create_tags_suite) + --%aftertest(drop_tags_suite) procedure filtering_is_correctly_applied_to_all_items; end test_ut_suite_tag_filter; diff --git a/test/ut3_tester_helper/main_helper.pkb b/test/ut3_tester_helper/main_helper.pkb index f60ce796c..44cce346f 100644 --- a/test/ut3_tester_helper/main_helper.pkb +++ b/test/ut3_tester_helper/main_helper.pkb @@ -174,5 +174,14 @@ create or replace package body main_helper is return l_result; end; + function get_sql_executions(a_sql_text_like varchar2) return number is + l_result number; + begin + select nvl(sum(s.executions), 0) into l_result + from v$sqlarea s + where s.sql_text like a_sql_text_like; + return l_result; + end; + end; / diff --git a/test/ut3_tester_helper/main_helper.pks b/test/ut3_tester_helper/main_helper.pks index 71575e145..da7643b13 100644 --- a/test/ut3_tester_helper/main_helper.pks +++ b/test/ut3_tester_helper/main_helper.pks @@ -51,5 +51,8 @@ create or replace package main_helper is function make_source(a_lines ut3_develop.ut_varchar2_list) return dbms_preprocessor.source_lines_t; + --number of executions of SQL statements and PL/SQL blocks whose text is like a_sql_text_like + function get_sql_executions(a_sql_text_like varchar2) return number; + end; / From 3076caeca3a9477cc5ac83b4cf098796e0d84ffb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 11:22:16 +0200 Subject: [PATCH 832/887] Refactoring `ut_suite_tag_filter.pkb` --- source/core/ut_suite_tag_filter.pkb | 38 ++++++++++++++++------------- 1 file changed, 21 insertions(+), 17 deletions(-) diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index f6c5f7e05..76f68f467 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -30,7 +30,7 @@ create or replace noneditionable package body ut_suite_tag_filter is --last tag expression and its condition, see create_where_filter g_last_tag_expression varchar2(4000); - g_last_where_filter varchar2(32767); + g_last_tags_filter varchar2(32767); function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list is l_tags_tokens ut_varchar2_list := ut_varchar2_list(); @@ -210,29 +210,33 @@ create or replace noneditionable package body ut_suite_tag_filter is Generates a condition on a collection named "tags" from a tag expression. Raises ut_utils.gc_invalid_tag_expression for an invalid expression. */ - function create_where_filter(a_tags varchar2 - ) return varchar2 deterministic is - l_tags varchar2(4000); + function create_where_filter(a_tag_expression varchar2, a_tags_var_name varchar2) return varchar2 is + l_tags_filter varchar2(4000); begin - --deterministic caches results only for calls from SQL, so the last result is also kept for repeated calls from is_matching - if g_last_tag_expression = a_tags then - return g_last_where_filter; + -- if calculated already, return previously calculated value. Cache of input tag filter expression evaluation + if g_last_tag_expression = a_tag_expression then + return g_last_tags_filter; end if; - l_tags := replace(replace_legacy_tag_notation(a_tags),' '); - l_tags := conv_postfix_to_infix_sql(shunt_logical_expression(tokenize_tags_string(l_tags)),'tags'); - l_tags := replace(l_tags, '|',' or '); - l_tags := replace(l_tags ,'&',' and '); - l_tags := replace(l_tags ,'!','not'); - g_last_tag_expression := a_tags; - g_last_where_filter := l_tags; - return l_tags; + l_tags_filter := replace(replace_legacy_tag_notation(a_tag_expression),' '); + l_tags_filter := conv_postfix_to_infix_sql(shunt_logical_expression(tokenize_tags_string(l_tags_filter)),a_tags_var_name); + l_tags_filter := replace(l_tags_filter, '|',' or '); + l_tags_filter := replace(l_tags_filter ,'&',' and '); + l_tags_filter := replace(l_tags_filter ,'!','not'); + g_last_tag_expression := a_tag_expression; + g_last_tags_filter := l_tags_filter; + return l_tags_filter; end; function is_matching(a_tags varchar2, a_tag_expression varchar2) return integer deterministic is - l_result integer; + l_result integer; + c_tags_col_name varchar2(10) := 'l_tags'; begin execute immediate - 'declare tags ut_varchar2_list := :a_tags; begin :a_result := case when '||create_where_filter(a_tag_expression)||' then 1 else 0 end; end;' + 'declare ' || + ' '||c_tags_col_name||' ut_varchar2_list := :a_tags; ' || + 'begin ' || + ' :a_result := case when '||create_where_filter(a_tag_expression, c_tags_col_name)||' then 1 else 0 end; ' || + 'end;' using in ut_utils.string_to_table(a_tags, ','), out l_result; return l_result; end; From 9176f77e970c64ffc58b69300bc592411eb16c77 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 14:32:22 +0200 Subject: [PATCH 833/887] Fixed test for is_matching --- test/ut3_tester/core/test_ut_suite_tag_filter.pkb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index c638aab46..7accab849 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -114,7 +114,8 @@ create or replace package body test_ut_suite_tag_filter is end; procedure is_matching_is_cached_in_sql is - c_block constant varchar2(100) := 'declare tags ut_varchar2_list := :a_tags;%''cache_probe'' member of tags%'; + --the anonymous block run by is_matching for the expression 'cache_probe' + c_block constant varchar2(100) := 'declare %ut_varchar2_list := :a_tags;%''cache_probe'' member of %'; l_before number; l_after number; l_count integer; @@ -126,7 +127,8 @@ create or replace package body test_ut_suite_tag_filter is where ut3_develop.ut_suite_tag_filter.is_matching('t'||k||',x', 'cache_probe') = 0; l_after := ut3_tester_helper.main_helper.get_sql_executions(c_block); ut.expect( l_count ).to_equal(1000); - ut.expect( l_after - l_before ).to_be_less_or_equal(3); + --at least one execution, so the pattern above still matches the block + ut.expect( l_after - l_before ).to_be_between(1, 3); end; procedure is_matching_invalid_expression is From ab61557ba8e08a74c39cd876597dccd3a3b285d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 14:47:36 +0200 Subject: [PATCH 834/887] Added a test for deduplication of overlapping run paths --- test/ut3_tester/core/test_suite_manager.pkb | 30 +++++++++++++++++++++ test/ut3_tester/core/test_suite_manager.pks | 11 +++++--- 2 files changed, 37 insertions(+), 4 deletions(-) diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index 77b0f61b1..b296ca3cb 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -502,6 +502,36 @@ end test2_multi_wildcard;]'; end; + function count_tests(a_items ut3_develop.ut_suite_items) return integer is + l_count integer := 0; + begin + for i in 1 .. a_items.count loop + if a_items(i) is of (ut3_develop.ut_test) then + l_count := l_count + 1; + else + l_count := l_count + count_tests(treat(a_items(i) as ut3_develop.ut_logical_suite).items); + end if; + end loop; + return l_count; + end; + + procedure test_overlapping_paths is + c_owner varchar2(128) := sys_context('USERENV', 'CURRENT_USER'); + l_expected_items ut3_develop.ut_suite_items; + l_objects_to_run ut3_develop.ut_suite_items; + begin + --Arrange + l_expected_items := ut3_develop.ut_suite_manager.configure_execution_by_path(ut3_develop.ut_varchar2_list(c_owner||':tests')); + --Act - the packages are part of the suitepath + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path( + ut3_develop.ut_varchar2_list(c_owner||':tests', c_owner||'.test_package_1', c_owner||'.test_package_2') + ); + --Assert + ut.expect(count_tests(l_expected_items)).to_be_greater_than(0); + ut.expect(l_objects_to_run.count).to_equal(1); + ut.expect(count_tests(l_objects_to_run)).to_equal(count_tests(l_expected_items)); + end; + procedure test_top2_by_name is c_path varchar2(100) := sys_context('USERENV', 'CURRENT_USER')||'.test_package_2'; l_objects_to_run ut3_develop.ut_suite_items; diff --git a/test/ut3_tester/core/test_suite_manager.pks b/test/ut3_tester/core/test_suite_manager.pks index 44f102716..4854bd8eb 100644 --- a/test/ut3_tester/core/test_suite_manager.pks +++ b/test/ut3_tester/core/test_suite_manager.pks @@ -15,6 +15,9 @@ create or replace package test_suite_manager is --%test(Prepare runner for the top 2 package by package user.package_name) procedure test_top2_by_name; + --%test(Prepare runner includes each suite item once when given paths overlap) + procedure test_overlapping_paths; + --%test(Prepare runner for the top2 package by name cur user) procedure test_top2_bt_name_cur_user; @@ -211,7 +214,7 @@ create or replace package test_suite_manager is --%test(Execute test_packages using a procedure name with wildcard in the front) procedure test_wild_card_front_prc_name; - -- %test(Execute test_packages using a path name with wildcard in the front) + --%test(Execute test_packages using a path name with wildcard in the front) procedure test_wild_card_front_path_name; --%test(Execute test_packages using a object_name with wildcard in the middle) @@ -220,7 +223,7 @@ create or replace package test_suite_manager is --%test(Execute test_packages using a procedure name with wildcard in the middle) procedure test_wild_card_mid_prc_name; - -- %test(Execute test_packages using a path name with wildcard in the middle) + --%test(Execute test_packages using a path name with wildcard in the middle) procedure test_wild_card_mid_path_name; --%test(Execute test_packages using a object_name with multiple wildcards) @@ -229,10 +232,10 @@ create or replace package test_suite_manager is --%test(Execute test_packages using a procedure name with multiple wildcards) procedure test_wild_card_mul_prc_name; - -- %test(Execute test_packages using a path name with multiple wildcards) + --%test(Execute test_packages using a path name with multiple wildcards) procedure test_wild_card_mul_path_name; - -- %test(Execute test_packages using a path name with multiple wildcards on different level) + --%test(Execute test_packages using a path name with multiple wildcards on different level) procedure tst_wild_card_mul_lv_path_name; --%endcontext From caba6de00b9ba231529a1e0b044c5b1f76d6a16c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 15:02:42 +0200 Subject: [PATCH 835/887] Resolve run paths with a single matching rule in a SQL macro The table SQL macro ut_suite_cache_macros.match_paths is now the only definition of which suite items a path selects. Access is checked before parents are added, so a wildcard selects only packages the user can access. Added tests for wildcards run by a user with partial access. --- .../suite_cache_collection_patterns.md | 37 +++- source/core/ut_suite_cache_macros.pkb | 46 +++++ source/core/ut_suite_cache_macros.pks | 43 ++++ source/core/ut_suite_cache_manager.pkb | 190 +++++++----------- source/core/ut_suite_cache_manager.pks | 13 ++ source/core/ut_suite_manager.pkb | 26 +-- source/create_grants.sql | 1 + source/install.sql | 2 + source/uninstall_objects.sql | 2 + .../ut3_cbac_modify_objects_role_grants.sql | 2 + .../annotations/test_annotation_cache.pkb | 49 +++++ .../annotations/test_annotation_cache.pks | 13 ++ 12 files changed, 282 insertions(+), 142 deletions(-) create mode 100644 source/core/ut_suite_cache_macros.pkb create mode 100644 source/core/ut_suite_cache_macros.pks diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md index b87ce6027..97bb39ec0 100644 --- a/development/suite_cache_collection_patterns.md +++ b/development/suite_cache_collection_patterns.md @@ -12,9 +12,9 @@ Revised on 2026-11-09 for the CBAC + SQL macro strategy, against branch `feature | P2 | chain of collection → collection functions | **done** | one statement with named CTEs: `get_suite_rows` (step 4) | | P3 | logical suites appended to a collection | **done** | CTE of the main statement (step 4) | | P4 | sort by self-join of a collection | **done** | recursive CTE of the main statement (step 4) | -| P5 | paths reconciled against a collection | open | keep, over the single final result | +| P5 | paths reconciled against a collection | **done** | `ut_suite_cache_manager.reconcile_paths_and_suites`, same matching rule as P7 | | P6 | collection → ref cursor → collection | **done, partly** | collection passed, no cursor; rows still converted to records (ORA-00600) | -| P7 | two scans of `ut_suite_cache` for path matching | open | one path-matching CTE | +| P7 | two scans of `ut_suite_cache` for path matching | **done** | table SQL macro `ut_suite_cache_macros.match_paths` (step 5) | | P8 | list handed between the two cache modules | **done** | table SQL macro `ut_annotation_cache_macros.get_cached_objects` | | P9 | full rows loaded only to project scalars | open | Flow B reuses the main statement and projects | | P10 | PL/SQL objects inserted through `table()` | keep | legitimate | @@ -92,6 +92,10 @@ Consolidated from the checks on 19.20 EE, 21.3 XE and 23ai Free (2026-11-09). - `compile_schema`, run as SYS or as `UT3_DEVELOP`, left that body invalid: `ORA-62565` / `PLS-00201: identifier 'UT_ANNOTATION_CACHE_MACROS.GET_CACHED_OBJECTS' must be declared`. - `alter package ut_suite_cache_manager compile body` (as SYS or `UT3_DEVELOP`) compiled it. - So recompile such bodies with `alter package ... compile body`. +13. **Restrictions on table SQL macros with `dbms_tf.table_t` arguments.** Seen on 19.20, 2026-11-10, in step 5: + - **No macro inside a `WITH` clause:** `ORA-64630: use of SQL macro inside WITH clause is not supported`. CTEs can be macro arguments, and the macro can be called from the main query or a subquery of it. + - **No collection columns in a table argument:** `ORA-62558: Unsupported data types (TABLE) for polymorphic table function`. Pass a CTE with the scalar columns only. + - **No `all_objects` in a CTE of the statement:** with `all_objects` (or `sys.all_objects`) in any CTE of a statement that calls the macro, the statement compiles but fails at run time with `ORA-00942`. That happened even for the owner, and in a definer-rights package. The same predicate in the main query's `where` works. #### Other statement-level findings (step 4, 19.20, 2026-11-10) @@ -279,8 +283,9 @@ The new behaviour was accepted on 2026-11-09. It is covered by the context "Suit ### P5: validate by joining two collections -- **Where:** `reconcile_paths_and_suites` ([ut_suite_manager.pkb:328](../source/core/ut_suite_manager.pkb:328)). +- **Where (before step 5):** `reconcile_paths_and_suites` in `ut_suite_manager`. - **What:** expanded paths are left-joined to the final rows to find paths that matched nothing. The first one raises an error. +- **Done in step 5:** `ut_suite_cache_manager.reconcile_paths_and_suites(a_schema_paths, a_suite_rows)` checks the raw paths, wildcards included, against the final rows with `ut_suite_cache_macros.match_paths`, the same rule `get_suite_rows` uses. The error messages are unchanged. - **Note:** this runs **after** the tag and access filters. As the code reads, a package path whose tests are all excluded by tags raises "Suite package ... does not exist". **Verify** whether this is intended and covered by tests (open question 1). Any reordering must keep this behaviour. - **Approach:** keep it as one small check over the single final collection. It is cheap once P2 is done. @@ -318,6 +323,27 @@ Found in step 2, on 19.20 EE, 2026-11-09: - **Cost:** two scans, and three places that encode "how a path matches a cache row" (`expand_paths`, `get_suite_items`, `reconcile_paths_and_suites`), each slightly differently. This is the hardest part of the code to reason about. - **Note:** the `where` clause of `get_suite_items` mixes `and`/`or` without full parentheses. It works because `null || '.%'` can't match a real path, not because of the structure. - **Approach:** one "path → matching cache rows" CTE in the main statement, with one definition of the matching rules. `group_paths_by_schema` stays a PL/SQL parser, and its `ut_path_items` stays a bind (P11). `reconcile` uses the same CTE (paths with no match). +- **Done in step 5.** + - `expand_paths` is gone, and `get_schema_paths` only splits paths into schema, package, procedure and suitepath; it no longer reads the cache. + - **One rule:** the table SQL macro `ut_suite_cache_macros.match_paths(a_items, a_paths)` is the only definition of which items a path selects: + - a schema: all its items; + - a package or `package.*`: the package's items; + - `package.procedure`: the items with that name; + - `:suitepath`: that item and everything below it; + - `:suite*path`: items whose path starts with a match of the pattern. + - **Two users of the rule:** `get_suite_rows`, through the new private `get_matched_ids`, and `reconcile_paths_and_suites`. + - **`get_matched_ids`** is a separate statement, because a macro cannot be used inside a `WITH` clause (rule 13). It returns the ids of the selected rows and their parents. The statement of `get_suite_rows` then starts from those ids. + - **The access check comes before parents are added.** A wildcard selects only packages the user can access, and only accessible parents are added. + - **Behaviour changes:** + - **Wildcards for users with partial access work.** Before, `owner.*_suite`, `owner.*_suite.*_test` or `owner:parent*` raised "does not exist" as soon as the wildcard also matched a package the user can't access, or one dropped but still in the cache. `expand_paths` didn't check access and returned one path per match. + - **`_` in package and procedure names is no longer a `LIKE` wildcard.** + - **`.` and `$` in suitepath patterns are literal.** + - **A suitepath without `*` is compared exactly**, not with `LIKE`. + - **New macro package:** `ut_suite_cache_macros` is definer rights (rule 2). It is in `install.sql` and `uninstall_objects.sql`, and is granted to the CBAC role and, in `create_grants.sql`, to the framework users (rule 4). `ut_integer_list` is also granted to the role. + - **Tests:** + - before the change (commit `a7ba8c8a`): overlapping paths in one call; + - with it: four tests in `test_annotation_cache` for wildcards run by a user with partial access. They fail on the code before step 5. + - The path wildcard tests of `test_suite_manager` (`-- %test`) were already active: the parser accepts `-- %`. ### P8: list handed over between two cache modules (done) @@ -428,7 +454,10 @@ Notes: - The same database after a full run, with only the `ut_suite_cache_manager` and test bodies recompiled. - Full run: 1148 tests, 0 failed, 0 errored, 3 disabled. That is 1144 (1140 plus 4 `is_matching` tests) plus the 4 tests `test_tfs_junit_reporter` leaves behind. - **Why 1144:** 1140 tests, plus 4 from packages that `test_tfs_junit_reporter` leaves behind when run twice on one database. Its `remove_test_package` doesn't drop `check_junit_in_context`, `check_junit_out_context` and `check_junit_inout_context`. That test bug predates this work. -5. **P7: merge `expand_paths` into the path CTE.** This is the riskiest step. Wildcard semantics and error messages are covered by `test_ut_run` / `test_ut_runner` in `ut3_user`. Do it last among the merges, with those suites as the safety net. +5. **P7: path resolution in one place. Done.** See P7 and P5. The tests were reviewed first: + - **Already covered:** paths by schema, package, procedure and suitepath; procedures inside contexts; `$` and `#` in names; wildcards at the end, front, middle and multiple, for package, procedure and suitepath; paths that match nothing. + - **Added before the change:** overlapping paths in one call. + - **Added with the change:** wildcards for a user with partial access. 6. **P9: Flow B on the same statement text.** Remove `get_cached_suite_info` and `get_suite_items_info` from the spec, and merge finding 2. ## Bigger options to consider separately diff --git a/source/core/ut_suite_cache_macros.pkb b/source/core/ut_suite_cache_macros.pkb new file mode 100644 index 000000000..735b81830 --- /dev/null +++ b/source/core/ut_suite_cache_macros.pkb @@ -0,0 +1,46 @@ +create or replace noneditionable package body ut_suite_cache_macros as + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + function match_paths(a_items dbms_tf.table_t, a_paths dbms_tf.table_t) return varchar2 sql_macro is + begin + --names: "_" is not a wildcard, "*" is; suitepath patterns: "." and "$" are literal, "*" matches part of a path element + return q'[ + select p.path_id, i.object_owner, i.path + from a_items i + join a_paths p + on i.object_owner = upper(p.schema_name) + where ( p.suite_path is null and p.object_name is null ) + or ( p.suite_path is null + and i.object_name like replace(replace(upper(p.object_name), '_', '\_'), '*', '%') escape '\' + and ( p.procedure_name is null or p.procedure_name = '*' + or i.name like replace(replace(upper(p.procedure_name), '_', '\_'), '*', '%') escape '\' + ) + ) + or ( instr(p.suite_path, '*') = 0 + and ( i.path = p.suite_path or substr(i.path, 1, length(p.suite_path) + 1) = p.suite_path || '.' ) + ) + or ( instr(p.suite_path, '*') > 0 + and regexp_like( + i.path, + '^' || replace(replace(replace(p.suite_path, '.', '\.'), '$', '\$'), '*', '[[:alnum:]$#_]*') + ) + )]'; + end; + +end; +/ diff --git a/source/core/ut_suite_cache_macros.pks b/source/core/ut_suite_cache_macros.pks new file mode 100644 index 000000000..2554ccba2 --- /dev/null +++ b/source/core/ut_suite_cache_macros.pks @@ -0,0 +1,43 @@ +create or replace noneditionable package ut_suite_cache_macros authid definer as + /* + utPLSQL - Version 3 + Copyright 2016 - 2026 utPLSQL Project + + Licensed under the Apache License, Version 2.0 (the "License"). + You may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + */ + + /* + * SQL macros for ut_suite_cache_manager. + * + * A package containing SQL macros cannot be an invoker rights package, so the macros are kept apart from ut_suite_cache_manager. + * A macro only returns SQL text, which is expanded into the calling SQL statement. + * A macro body sees the values of literal arguments only, so the returned text does not depend on argument values. + */ + + /** + * Table SQL macro matching suite items with run paths: the single definition of which items a run path selects. + * Returns one row (path_id, object_owner, path) for every pair of a path and an item it selects: + * - schema: all items of the schema + * - schema.package[.*]: all items of the package + * - schema.package.procedure: the items named like the procedure + * - schema:suite.path: the item at the suitepath and all items below it + * - schema:suite*.path: the items whose path starts with a match of the suitepath pattern + * Package and procedure names may contain wildcards (*). Parents of the selected items are not returned. + * + * @param a_items table or query with columns object_owner, object_name, name, path (as in ut_suite_cache), without collection columns + * @param a_paths table or query with columns path_id and the columns of ut_path_item + */ + function match_paths(a_items dbms_tf.table_t, a_paths dbms_tf.table_t) return varchar2 sql_macro; + +end; +/ diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 218bab758..97bd33da6 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -17,9 +17,10 @@ create or replace noneditionable package body ut_suite_cache_manager is */ /* - * Private code + * Public code */ - function group_paths_by_schema(a_paths ut_varchar2_list) return ut_path_items is + + function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items is c_package_path_regex constant varchar2(100) := '^([[:alnum:]$#_]+)(\.([[:alnum:]$#_\*]+))?(\.([[:alnum:]$#_\*]+))?$'; l_results ut_path_items := ut_path_items(); l_path_item ut_path_item; @@ -45,94 +46,49 @@ create or replace noneditionable package body ut_suite_cache_manager is end; /* - First SQL queries for objects where procedure is null or its only wildcard. - We split that due to fact that we can use func min to combine rows. - - Second union is responsible expanding paths where the procedure filter is given - We cannot select min here as filter can cover only half of tests within - package. Even if the filter doesnt return anything we still capture a proc filter - name for error reporting later on. - - Third SQL cover scenario where a suitapath only is populated and wildcard is given - - Fourth SQL cover scenario where suitepath is populated with no filters - */ - function expand_paths(a_schema_paths ut_path_items) return ut_path_items is - l_schema_paths ut_path_items:= ut_path_items(); - begin - with - schema_paths as ( - select * from table(a_schema_paths) - ), - paths_for_object as ( - select /*+ no_parallel */ min(path) as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, - null as procedure_name - from schema_paths sp left outer join &&ut3_owner..ut_suite_cache c - on ( c.object_owner = upper(sp.schema_name) - and c.object_name like replace(upper(sp.object_name),'*','%')) - where sp.suite_path is null and sp.object_name is not null - and ( sp.procedure_name is null or sp.procedure_name = '*') - group by sp.schema_name,nvl(c.object_name,sp.object_name) - ), - paths_for_procedures as ( - select /*+ no_parallel */ path as suite_path,sp.schema_name as schema_name,nvl(c.object_name,sp.object_name) as object_name, - nvl(c.name,sp.procedure_name) as procedure_name - from schema_paths sp left outer join &&ut3_owner..ut_suite_cache c - on ( c.object_owner = upper(sp.schema_name) - and c.object_name like replace(upper(sp.object_name),'*','%') - and c.name like nvl(replace(upper(sp.procedure_name),'*','%'), c.name)) - where sp.suite_path is null and sp.object_name is not null - and (sp.procedure_name is not null and sp.procedure_name != '*') - ), - paths_for_suite_path_with_ast as ( - select /*+ no_parallel */ nvl(c.path,sp.suite_path) as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name - from schema_paths sp left outer join &&ut3_owner..ut_suite_cache c on - ( c.object_owner = upper(sp.schema_name) - --and c.path like replace(sp.suite_path,'*','%')) - and regexp_like(c.path,'^'||replace(sp.suite_path,'*','[[:alnum:]$#_]*'))) - where sp.suite_path is not null and instr(sp.suite_path,'*') > 0 - ), - straigth_suite_paths as ( - select /*+ no_parallel */ sp.suite_path as suite_path,sp.schema_name,sp.object_name,sp.procedure_name as procedure_name - from schema_paths sp - where - (sp.suite_path is not null and instr(sp.suite_path,'*') = 0) - or - (sp.suite_path is null and sp.object_name is null) - ), - all_suitepaths_together as ( - select * from paths_for_object - union all - select * from paths_for_procedures - union all - select * from paths_for_suite_path_with_ast - union all - select * from straigth_suite_paths - ) - select &&ut3_owner..ut_path_item(schema_name,object_name,procedure_name,suite_path) - bulk collect into l_schema_paths - from - (select schema_name,object_name,procedure_name,suite_path, - row_number() over ( partition by schema_name,object_name,procedure_name,suite_path order by 1) as r_num - from all_suitepaths_together) - where r_num = 1 ; - return l_schema_paths; - end; - - /* - * Public code + Returns ids of the cache rows the paths select (wildcards included, see ut_suite_cache_macros.match_paths) + and of their parents, only for packages the invoking user can access, unless a_skip_access_check is true. + A separate statement, as a SQL macro cannot be used inside a WITH clause (ORA-64630). */ - - function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items is + function get_matched_ids( + a_schema_paths ut_path_items, + a_skip_access_check boolean + ) return ut_integer_list is + l_results ut_integer_list; + l_skip_access_check varchar2(1) := case when a_skip_access_check then 'Y' else 'N' end; begin - return expand_paths(group_paths_by_schema(a_paths)); + --all_objects is used only in the main query: in a WITH clause of a statement with a SQL macro it raises ORA-00942 + with + path_items as ( + select rownum as path_id, sp.schema_name, sp.object_name, sp.procedure_name, sp.suite_path + from table(a_schema_paths) sp + ), + schema_items as ( + --only scalar columns: a table argument of a SQL macro cannot have collection columns (ORA-62558) + select /*+ no_parallel */ c.id, c.object_owner, c.object_name, c.name, c.path + from &&ut3_owner..ut_suite_cache c + where c.object_owner in (select upper(p.schema_name) from path_items p) + ) + select /*+ no_parallel */ distinct r.id + bulk collect into l_results + from (&&ut3_owner..ut_suite_cache_macros.match_paths(schema_items, path_items)) m + join schema_items s + on s.object_owner = m.object_owner + and s.path = m.path + join schema_items r + on r.object_owner = s.object_owner + and ( r.path = s.path or substr(s.path, 1, length(r.path) + 1) = r.path || '.' /* the selected row or its parent */ ) + where l_skip_access_check = 'Y' + or ( exists ( select 1 from all_objects a where a.owner = s.object_owner and a.object_name = s.object_name and a.object_type = 'PACKAGE' ) + and exists ( select 1 from all_objects a where a.owner = r.object_owner and a.object_name = r.object_name and a.object_type = 'PACKAGE' ) + ); + return l_results; end; - + /* - Returns suite items for the paths in one statement, sorted bottom up, so that reconstruct_from_cache in ut_suite_manager + Returns suite items for the paths, sorted bottom up, so that reconstruct_from_cache in ut_suite_manager can build the suite hierarchy in a single pass. The statement: - - matched_rows: cache rows matching the paths (all parents and children of a suite path, or the package / procedure), - only for packages the invoking user can access, unless a_skip_access_check is true + - matched_rows: the rows from get_matched_ids - tagged_rows: when tags are given, the rows having a test matching the tag expression below them (or being one); a test inherits the tags of the suites and contexts above it - logical_suites: suites for the parts of the suitepaths that have no package behind them @@ -146,39 +102,13 @@ create or replace noneditionable package body ut_suite_cache_manager is a_random_seed positive := null ) return ut_suite_cache_rows is l_results ut_suite_cache_rows; - l_skip_access_check varchar2(1) := case when a_skip_access_check then 'Y' else 'N' end; + l_matched_ids ut_integer_list := get_matched_ids(a_schema_paths, a_skip_access_check); begin with matched_rows as ( select /*+ no_parallel */ c.id, c.self_type, c.path, c.object_owner, c.object_name, c.line_no, c.tags from &&ut3_owner..ut_suite_cache c - where exists ( - select /*+ no_expand */ 1 - from table(a_schema_paths) sp - where c.object_owner = upper(sp.schema_name) - and ( ( sp.suite_path is not null - and ( sp.suite_path||'.' like c.path||'.%' /* all parents and self */ - or ( c.path||'.' like sp.suite_path||'.%' /* all children and self */ - and c.object_name like nvl(upper(sp.object_name),c.object_name) - and c.name like nvl(upper(sp.procedure_name),c.name) - ) - ) - ) - or ( sp.suite_path is null - and c.object_name = nvl(upper(sp.object_name),c.object_name) - and c.name = nvl(upper(sp.procedure_name),c.name) - ) - ) - ) - and ( l_skip_access_check = 'Y' - or exists ( - select 1 - from all_objects a - where a.owner = c.object_owner - and a.object_name = c.object_name - and a.object_type = 'PACKAGE' - ) - ) + where c.id in (select m.column_value from table(l_matched_ids) m) ), propagate_tags_from_ancestors as ( select c.id, c.self_type, c.path, c.object_owner, listagg(distinct c_tags.tag, ',') within group (order by c_tags.tag) as tags @@ -273,6 +203,40 @@ create or replace noneditionable package body ut_suite_cache_manager is return l_results; end; + procedure reconcile_paths_and_suites( + a_schema_paths ut_path_items, + a_suite_rows ut_suite_cache_rows + ) is + begin + for i in ( + with + path_items as ( + select /*+ materialize */ rownum as path_id, sp.schema_name, sp.object_name, sp.procedure_name, sp.suite_path + from table(a_schema_paths) sp + ), + suite_items as ( + select r.object_owner, r.object_name, r.name, r.path + from table(a_suite_rows) r + ) + select /*+ no_parallel */ p.schema_name, p.object_name, p.procedure_name, p.suite_path + from path_items p + where not exists ( + select 1 + from (&&ut3_owner..ut_suite_cache_macros.match_paths(suite_items, path_items)) m + where m.path_id = p.path_id + ) + order by p.path_id + ) loop + if i.suite_path is not null then + raise_application_error(ut_utils.gc_suite_package_not_found,'No suite packages found for path '||i.schema_name||':'||i.suite_path|| '.'); + elsif i.procedure_name is not null then + raise_application_error(ut_utils.gc_suite_package_not_found,'Suite test '||i.schema_name||'.'||i.object_name|| '.'||i.procedure_name||' does not exist'); + elsif i.object_name is not null then + raise_application_error(ut_utils.gc_suite_package_not_found,'Suite package '||i.schema_name||'.'||i.object_name|| ' does not exist'); + end if; + end loop; + end; + function get_schema_parse_time(a_schema_name varchar2) return timestamp result_cache is l_cache_parse_time timestamp; begin diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index ad7d3762a..bcb696721 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -45,6 +45,10 @@ create or replace noneditionable package ut_suite_cache_manager authid current_u */ procedure remove_missing_objs_from_cache(a_schema_name varchar2); + /* + * Splits run paths (schema[.package[.procedure]] or schema:suitepath, wildcards allowed) into their parts. + * Wildcards are resolved by get_suite_rows. + */ function get_schema_paths(a_paths in ut_varchar2_list) return ut_path_items; /* @@ -61,6 +65,15 @@ create or replace noneditionable package ut_suite_cache_manager authid current_u a_random_seed positive := null ) return ut_suite_cache_rows; + /* + * Raises ut_utils.gc_suite_package_not_found for the first path that selects none of the suite rows + * (as returned by get_suite_rows), with the same matching rules as get_suite_rows. + */ + procedure reconcile_paths_and_suites( + a_schema_paths ut_path_items, + a_suite_rows ut_suite_cache_rows + ); + function get_suite_items_info( a_suite_cache_items ut_suite_cache_rows ) return ut_suite_items_info; diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index ae2cff4d6..96f45b714 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -306,30 +306,6 @@ create or replace noneditionable package body ut_suite_manager is return ut_metadata.user_has_execute_any_proc() or a_skip_all_objects; end; - procedure reconcile_paths_and_suites( - a_schema_paths ut_path_items, - a_filtered_rows ut_suite_cache_rows - ) is - begin - for i in ( select /*+ no_parallel */ sp.schema_name,sp.object_name,sp.procedure_name, - sp.suite_path,sc.path - from table(a_schema_paths) sp left outer join - table(a_filtered_rows) sc on - (( upper(sp.schema_name) = upper(sc.object_owner) and upper(sp.object_name) = upper(sc.object_name) - and nvl(upper(sp.procedure_name),sc.name) = sc.name ) - or (sc.path = sp.suite_path)) - where sc.path is null) - loop - if i.suite_path is not null then - raise_application_error(ut_utils.gc_suite_package_not_found,'No suite packages found for path '||i.schema_name||':'||i.suite_path|| '.'); - elsif i.procedure_name is not null then - raise_application_error(ut_utils.gc_suite_package_not_found,'Suite test '||i.schema_name||'.'||i.object_name|| '.'||i.procedure_name||' does not exist'); - elsif i.object_name is not null then - raise_application_error(ut_utils.gc_suite_package_not_found,'Suite package '||i.schema_name||'.'||i.object_name|| ' does not exist'); - end if; - end loop; - end; - function get_cached_suite_data( a_schema_paths ut_path_items, a_random_seed positive, @@ -341,7 +317,7 @@ create or replace noneditionable package body ut_suite_manager is l_suite_rows := ut_suite_cache_manager.get_suite_rows( a_schema_paths, skip_access_check(a_skip_all_objects), a_tags, a_random_seed ); - reconcile_paths_and_suites(a_schema_paths,l_suite_rows); + ut_suite_cache_manager.reconcile_paths_and_suites(a_schema_paths,l_suite_rows); return l_suite_rows; end; diff --git a/source/create_grants.sql b/source/create_grants.sql index 010bbe322..5cf7cfaaa 100644 --- a/source/create_grants.sql +++ b/source/create_grants.sql @@ -68,6 +68,7 @@ grant execute on &&ut3_owner..ut_coverage_options to &ut3_user; --On Oracle 21c XE, expanding a macro requires the calling user to have execute privilege on it. --The macros only return SQL text; the tables they reference stay accessible only through the code based access control role. grant execute on &&ut3_owner..ut_annotation_cache_macros to &ut3_user; +grant execute on &&ut3_owner..ut_suite_cache_macros to &ut3_user; --generic types grant execute on &&ut3_owner..ut_varchar2_list to &ut3_user; diff --git a/source/install.sql b/source/install.sql index 4b8c14492..3feca3a7d 100644 --- a/source/install.sql +++ b/source/install.sql @@ -163,6 +163,7 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/ut_suite_cache.sql' @@install_component.sql 'core/ut_suite_tag_filter.pks' +@@install_component.sql 'core/ut_suite_cache_macros.pks' @@install_component.sql 'core/ut_suite_cache_manager.pks' @@install_component.sql 'core/ut_suite_builder.pks' --suite manager @@ -178,6 +179,7 @@ create or replace context &&ut3_owner._info using &&ut3_owner..ut_session_contex @@install_component.sql 'core/annotations/ut_annotation_parser.pkb' @@install_component.sql 'core/annotations/ut_annotation_manager.pkb' @@install_component.sql 'core/ut_suite_tag_filter.pkb' +@@install_component.sql 'core/ut_suite_cache_macros.pkb' @@install_component.sql 'core/ut_suite_cache_manager.pkb' @@install_component.sql 'core/ut_suite_builder.pkb' @@install_component.sql 'core/ut_suite_manager.pkb' diff --git a/source/uninstall_objects.sql b/source/uninstall_objects.sql index 13125dc13..5c6e41dc3 100644 --- a/source/uninstall_objects.sql +++ b/source/uninstall_objects.sql @@ -114,6 +114,8 @@ drop package ut_suite_tag_filter; drop package ut_suite_cache_manager; +drop package ut_suite_cache_macros; + drop table ut_suite_cache purge; drop type ut_suite_cache_rows force; diff --git a/source/ut3_cbac_modify_objects_role_grants.sql b/source/ut3_cbac_modify_objects_role_grants.sql index e62b0e178..063e29221 100644 --- a/source/ut3_cbac_modify_objects_role_grants.sql +++ b/source/ut3_cbac_modify_objects_role_grants.sql @@ -47,10 +47,12 @@ grant execute on &&ut3_owner..ut_test to &&ut3_owner._cbac_modify_ob grant execute on &&ut3_owner..ut_executables to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_executable_test to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_varchar2_rows to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_integer_list to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_path_item to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_object_name to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_utils to &&ut3_owner._cbac_modify_objects_role; grant execute on &&ut3_owner..ut_suite_tag_filter to &&ut3_owner._cbac_modify_objects_role; +grant execute on &&ut3_owner..ut_suite_cache_macros to &&ut3_owner._cbac_modify_objects_role; grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_cache_manager; grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_manager; diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pkb b/test/ut3_tester/core/annotations/test_annotation_cache.pkb index 648683ec4..1f7c83617 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pkb @@ -554,6 +554,55 @@ create or replace package body test_annotation_cache is rollback; end; + procedure user_runs_granted_by_wildcard is + l_actual clob; + pragma autonomous_transaction; + begin + --Act - matches child_suite (granted) and lone_suite (not granted) + l_actual := annotation_cache_helper.run_tests_as( 'ut3_no_extra_priv_user', 'ut3_cache_test_owner.*l*_suite' ); + --Assert + ut.expect( l_actual ).to_be_like( '%child_test%1 tests, 0 failed%' ); + ut.expect( l_actual ).not_to_be_like( '%lone_test%' ); + rollback; + end; + + procedure user_runs_granted_tests_by_wildcard is + l_actual clob; + pragma autonomous_transaction; + begin + --Act - matches child_suite.child_test (granted) and lone_suite.lone_test (not granted) + l_actual := annotation_cache_helper.run_tests_as( 'ut3_no_extra_priv_user', 'ut3_cache_test_owner.*l*_suite.*_test' ); + --Assert + ut.expect( l_actual ).to_be_like( '%child_test%1 tests, 0 failed%' ); + ut.expect( l_actual ).not_to_be_like( '%lone_test%' ); + rollback; + end; + + procedure user_runs_granted_by_path_wildcard is + l_actual clob; + pragma autonomous_transaction; + begin + --Act - matches parent_suite (not granted) and parent_suite.child_suite (granted) + l_actual := annotation_cache_helper.run_tests_as( 'ut3_no_extra_priv_user', 'ut3_cache_test_owner:parent*' ); + --Assert + ut.expect( l_actual ).to_be_like( '%child_test%1 tests, 0 failed%' ); + ut.expect( l_actual ).not_to_be_like( '%parent_test%' ); + rollback; + end; + + procedure user_hidden_path_wildcard_not_found is + l_actual clob; + pragma autonomous_transaction; + begin + --Act - matches only hidden_path.sub.lone_suite (not granted) + l_actual := annotation_cache_helper.run_tests_as( 'ut3_no_extra_priv_user', 'ut3_cache_test_owner:hidden*' ); + rollback; + exception + when others then + rollback; + raise; + end; + procedure user_hidden_path_not_found is l_actual clob; pragma autonomous_transaction; diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pks b/test/ut3_tester/core/annotations/test_annotation_cache.pks index da2216444..da733952a 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pks +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pks @@ -294,6 +294,19 @@ create or replace package test_annotation_cache is --%throws(-20204) procedure user_hidden_path_not_found; + --%test(Runs only granted packages matched by a package name with wildcards) + procedure user_runs_granted_by_wildcard; + + --%test(Runs only tests of granted packages matched by procedure name with wildcards) + procedure user_runs_granted_tests_by_wildcard; + + --%test(Runs granted packages below a suitepath with wildcards) + procedure user_runs_granted_by_path_wildcard; + + --%test(Raises an error for a suitepath with wildcards without granted packages below it) + --%throws(-20204) + procedure user_hidden_path_wildcard_not_found; + --%endcontext end; From 6f618ad5fee865942089ae7678204f7bfcfa56fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 15:06:47 +0200 Subject: [PATCH 836/887] Add get_suites_info tests for contexts, disabled tests and procedure paths --- test/ut3_tester_helper/run_helper.pkb | 22 ++++++++ test/ut3_tester_helper/run_helper.pks | 1 + test/ut3_user/api/test_ut_runner.pkb | 79 +++++++++++++++++++++++++++ test/ut3_user/api/test_ut_runner.pks | 12 ++++ 4 files changed, 114 insertions(+) diff --git a/test/ut3_tester_helper/run_helper.pkb b/test/ut3_tester_helper/run_helper.pkb index c56f31dc0..6bd88bfa8 100644 --- a/test/ut3_tester_helper/run_helper.pkb +++ b/test/ut3_tester_helper/run_helper.pkb @@ -146,6 +146,28 @@ create or replace package body run_helper is ut3_develop.ut_annotation_manager.rebuild_annotation_cache('UT3_TESTER_HELPER','PROCEDURE'); end; + procedure setup_cache_context_disabled is + pragma autonomous_transaction; + begin + --the procedures that cleanup_cache drops + setup_cache_objects(); + execute immediate q'[create or replace package ut3_user.dummy_test_package as + --%suite(dummy_test_suite) + --%suitepath(some.path) + + --%test(dummy_test) + procedure some_dummy_test_procedure; + + --%context(dummy_context) + + --%test(disabled_test) + --%disabled(not ready) + procedure disabled_test_procedure; + + --%endcontext + end;]'; + end; + procedure cleanup_cache is pragma autonomous_transaction; begin diff --git a/test/ut3_tester_helper/run_helper.pks b/test/ut3_tester_helper/run_helper.pks index 6c5dd4a3b..c46b99a3f 100644 --- a/test/ut3_tester_helper/run_helper.pks +++ b/test/ut3_tester_helper/run_helper.pks @@ -7,6 +7,7 @@ create or replace package run_helper is procedure setup_cache_objects; procedure setup_cache_objectstag; procedure setup_cache_twotags; + procedure setup_cache_context_disabled; procedure setup_cache; procedure cleanup_cache; procedure create_db_link; diff --git a/test/ut3_user/api/test_ut_runner.pkb b/test/ut3_user/api/test_ut_runner.pkb index d35495c70..9ef709e91 100644 --- a/test/ut3_user/api/test_ut_runner.pkb +++ b/test/ut3_user/api/test_ut_runner.pkb @@ -25,6 +25,11 @@ create or replace package body test_ut_runner is ut3_tester_helper.run_helper.cleanup_cache(); end; + procedure setup_cache_context_disabled is + begin + ut3_tester_helper.run_helper.setup_cache_context_disabled(); + end; + procedure create_test_spec as pragma autonomous_transaction; @@ -376,6 +381,80 @@ end;'; ut.expect(l_actual).to_equal(l_expected); end; + procedure test_get_suites_info_context is + l_expected sys_refcursor; + l_actual sys_refcursor; + begin + --Arrange + open l_expected for + select + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, + 'dummy_test_suite' item_description, 'UT_SUITE' item_type, 2 item_line_no, + 'some.path.dummy_test_package' path, 0 disabled_flag, null disabled_reason, null tags + from dual union all + select + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, + 'dummy_test' item_description, 'UT_TEST' item_type, 5 item_line_no, + 'some.path.dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason, null tags + from dual union all + select + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'NESTED_CONTEXT_#1' item_name, + 'dummy_context' item_description, 'UT_SUITE_CONTEXT' item_type, 8 item_line_no, + 'some.path.dummy_test_package.nested_context_#1' path, 0 disabled_flag, null disabled_reason, null tags + from dual union all + select + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DISABLED_TEST_PROCEDURE' item_name, + 'disabled_test' item_description, 'UT_TEST' item_type, 10 item_line_no, + 'some.path.dummy_test_package.nested_context_#1.disabled_test_procedure' path, 1 disabled_flag, 'not ready' disabled_reason, null tags + from dual union all + select + 'UT3_USER' object_owner, 'PATH' object_name, 'PATH' item_name, + null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, + 'some.path' path, 0 disabled_flag, null disabled_reason, null tags + from dual union all + select + 'UT3_USER' object_owner, 'SOME' object_name, 'SOME' item_name, + null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, + 'some' path, 0 disabled_flag, null disabled_reason, null tags + from dual; + --Act + open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('UT3_USER','DUMMY_TEST_PACKAGE')); + --Assert + ut.expect(l_actual).to_equal(l_expected); + end; + + procedure test_get_suites_info_by_proc is + l_expected sys_refcursor; + l_actual sys_refcursor; + begin + --Arrange + open l_expected for + select + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'DUMMY_TEST_PACKAGE' item_name, + 'dummy_test_suite' item_description, 'UT_SUITE' item_type, 2 item_line_no, + 'some.path.dummy_test_package' path, 0 disabled_flag, null disabled_reason, null tags + from dual union all + select + 'UT3_USER' object_owner, 'DUMMY_TEST_PACKAGE' object_name, 'SOME_DUMMY_TEST_PROCEDURE' item_name, + 'dummy_test' item_description, 'UT_TEST' item_type, 6 item_line_no, + 'some.path.dummy_test_package.some_dummy_test_procedure' path, 0 disabled_flag, null disabled_reason, null tags + from dual union all + select + 'UT3_USER' object_owner, 'PATH' object_name, 'PATH' item_name, + null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, + 'some.path' path, 0 disabled_flag, null disabled_reason, null tags + from dual union all + select + 'UT3_USER' object_owner, 'SOME' object_name, 'SOME' item_name, + null item_description, 'UT_LOGICAL_SUITE' item_type, null item_line_no, + 'some' path, 0 disabled_flag, null disabled_reason, null tags + from dual; + --Act + open l_actual for select * from table(ut3_develop.ut_runner.get_suites_info('ut3_user.dummy_test_package.some_dummy_test_procedure')); + --Assert + ut.expect(l_actual).to_equal(l_expected); + end; + procedure test_get_reporters_list is l_expected sys_refcursor; l_actual sys_refcursor; diff --git a/test/ut3_user/api/test_ut_runner.pks b/test/ut3_user/api/test_ut_runner.pks index e003ba852..742d4ad1c 100644 --- a/test/ut3_user/api/test_ut_runner.pks +++ b/test/ut3_user/api/test_ut_runner.pks @@ -70,6 +70,18 @@ create or replace package test_ut_runner is --%aftertest(cleanup_cache) procedure test_get_suites_info_by_path; + procedure setup_cache_context_disabled; + + --%test(get_suites_info returns contexts and disabled tests) + --%beforetest(setup_cache_context_disabled) + --%aftertest(cleanup_cache) + procedure test_get_suites_info_context; + + --%test(get_suites_info returns a test and its parents for a procedure path) + --%beforetest(setup_cache_objects) + --%aftertest(cleanup_cache) + procedure test_get_suites_info_by_proc; + --%test(get_reporters_list returns a cursor containing all built-in reporters and information about output-reporter) --%beforetest(setup_cache_objects) --%aftertest(cleanup_cache) From c5f0951d478aec63020dcf1cd02f5be140a8f06e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 15:12:15 +0200 Subject: [PATCH 837/887] Build suite info from the run statement without executables configure_execution_by_path and get_suites_info share the private refresh_cache_for_paths instead of repeating the schema resolution and cache refresh. --- .../suite_cache_collection_patterns.md | 18 ++++- source/core/ut_suite_cache_manager.pkb | 70 ++++++++++++++----- source/core/ut_suite_cache_manager.pks | 9 ++- source/core/ut_suite_manager.pkb | 55 ++++++--------- 4 files changed, 95 insertions(+), 57 deletions(-) diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md index 97bb39ec0..794eee8f4 100644 --- a/development/suite_cache_collection_patterns.md +++ b/development/suite_cache_collection_patterns.md @@ -16,7 +16,7 @@ Revised on 2026-11-09 for the CBAC + SQL macro strategy, against branch `feature | P6 | collection → ref cursor → collection | **done, partly** | collection passed, no cursor; rows still converted to records (ORA-00600) | | P7 | two scans of `ut_suite_cache` for path matching | **done** | table SQL macro `ut_suite_cache_macros.match_paths` (step 5) | | P8 | list handed between the two cache modules | **done** | table SQL macro `ut_annotation_cache_macros.get_cached_objects` | -| P9 | full rows loaded only to project scalars | open | Flow B reuses the main statement and projects | +| P9 | full rows loaded only to project scalars | **done** | `get_suites_info` on the same statement, rows without executables (step 6) | | P10 | PL/SQL objects inserted through `table()` | keep | legitimate | | P11 | short scalar lists joined in SQL | keep | legitimate | | new | `get_cached_objects` branched on an argument's value | **done** | parameter removed (step 0) | @@ -357,6 +357,18 @@ Found in step 2, on 19.20 EE, 2026-11-09: - **Where:** Flow B: `get_cached_suite_info` → `get_filtered_cursor` → `get_suite_items_info`. - **What:** `ut_suite_cache_row` objects, with all executable lists, are built and copied only to produce `ut_suite_item_info`. - **Approach:** after P1/P2/P7, Flow B runs the same statement text as Flow A, without tags or randomisation. It differs only in the final select (`ut_suite_item_info(...)`, ordered by owner, name and line). The statement is built in one private function, and the two flows add their own final select (DRY). `get_cached_suite_info` and `get_suite_items_info` then leave the spec (Interface Segregation). +- **Done in step 6.** + - The statement is the private `select_suite_rows(..., a_with_executables)`. `get_suite_rows` calls it with the executables. The new public `get_suites_info(a_schema_paths, a_skip_access_check)` calls it without them: real rows are then built from scalar columns and tags, without `value(c)` and the executable lists. + - `get_suite_items_info` (the projection to `ut_suite_item_info`) is private. `ut_suite_manager.get_suites_info` calls `ut_suite_cache_manager.get_suites_info` and only adds the ordering. + - **Tests first** (commit `a373b85b`): `get_suites_info` for a package with a context and a disabled test, and for a procedure path. The existing tests already covered packages without and with tags, and suitepaths. + - **Measured on 19.20, whole schemas, 5 runs each after one warm-up run:** + + | Call | Before (ms) | After (ms) | + |---|---|---| + | `get_suites_info` UT3_TESTER (470 items) | 300–320 | 250 | + | `get_suites_info` UT3_USER (818 items) | 780–990 | 700–740 | + | `configure_execution_by_path` UT3_TESTER | 490–500 | 450–480 | + | `configure_execution_by_path` UT3_USER | 1150–1320 | 1060–1080 | ### P10: PL/SQL-built objects written through `table()` (legitimate) @@ -372,7 +384,7 @@ Found in step 2, on 19.20 EE, 2026-11-09: ## Smaller findings seen along the way 1. **Rollback type is set twice. Fixed in step 2:** only `reconstruct_from_cache` sets it now. That covers `configure_execution_by_path` and `build_suites_from_annotations`. -2. **Duplicated prologue.** `configure_execution_by_path` and `get_suites_info` both do "resolve schema names → refresh cache per schema → `get_schema_paths`". This could be one private procedure. +2. **Duplicated prologue. Fixed in step 6:** `configure_execution_by_path` and `get_suites_info` both call the private `refresh_cache_for_paths`. 3. **Two near-identical checks. Partly fixed in step 3:** `skip_access_check` replaces the test in `get_filtered_cursor`. The owner needs no special case in the SQL predicate: `all_objects` always includes the user's own packages. `can_skip_all_objects_scan` stays, for `refresh_cache` and `suite_item_exists`. 4. **`get_logical_suite` repeats constructor calls.** It holds 7 constructor calls that differ only in `items =>`. Choosing `items` first would cut it to 4. 5. **Possible stale items on a bad suitepath (verify).** In `build_and_cache_suites` ([ut_suite_manager.pkb:398](../source/core/ut_suite_manager.pkb:398)), when `create_suite_item_list` raises `ex_string_too_small`, `save_object_cache` still runs with `l_suite_items`. That parameter is `out nocopy`, so it may hold partial or previous-object items. @@ -458,7 +470,7 @@ Notes: - **Already covered:** paths by schema, package, procedure and suitepath; procedures inside contexts; `$` and `#` in names; wildcards at the end, front, middle and multiple, for package, procedure and suitepath; paths that match nothing. - **Added before the change:** overlapping paths in one call. - **Added with the change:** wildcards for a user with partial access. -6. **P9: Flow B on the same statement text.** Remove `get_cached_suite_info` and `get_suite_items_info` from the spec, and merge finding 2. +6. **P9: Flow B on the same statement text. Done.** See P9. Finding 2 is merged too. ## Bigger options to consider separately diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 97bd33da6..4bf26a0db 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -94,15 +94,18 @@ create or replace noneditionable package body ut_suite_cache_manager is - logical_suites: suites for the parts of the suitepaths that have no package behind them - ordered: the hierarchy sorted depth first by line number, or by a hash of the path when a_random_seed is given The tag expression is evaluated per test by ut_suite_tag_filter.is_matching, so the statement is static SQL. + Without a_with_executables, the rows have no executables (before/after lists, test item), which only a run needs. */ - function get_suite_rows( + function select_suite_rows( a_schema_paths ut_path_items, a_skip_access_check boolean, - a_tags varchar2 := null, - a_random_seed positive := null + a_tags varchar2, + a_random_seed positive, + a_with_executables boolean ) return ut_suite_cache_rows is l_results ut_suite_cache_rows; l_matched_ids ut_integer_list := get_matched_ids(a_schema_paths, a_skip_access_check); + l_with_executables varchar2(1) := case when a_with_executables then 'Y' else 'N' end; begin with matched_rows as ( @@ -185,7 +188,16 @@ create or replace noneditionable package body ut_suite_cache_manager is search depth first by line_no desc, random_seed desc nulls last, path, object_owner set order1 select /*+ no_parallel */ case - when o.id is not null then value(c) + when o.id is not null and l_with_executables = 'Y' then value(c) + when o.id is not null then + --without the executables, which only a run needs + &&ut3_owner..ut_suite_cache_row( + c.id, c.self_type, c.path, c.object_owner, c.object_name, c.name, + c.line_no, c.parse_time, c.description, c.rollback_type, c.disabled_flag, c.disabled_reason, + null, + null, null, null, null, null, null, + null, c.tags, null + ) else &&ut3_owner..ut_suite_cache_row( null, 'UT_LOGICAL_SUITE', o.path, o.object_owner, o.object_name, o.object_name, null, null, null, null, 0, null, @@ -203,6 +215,41 @@ create or replace noneditionable package body ut_suite_cache_manager is return l_results; end; + function get_suite_rows( + a_schema_paths ut_path_items, + a_skip_access_check boolean, + a_tags varchar2 := null, + a_random_seed positive := null + ) return ut_suite_cache_rows is + begin + return select_suite_rows(a_schema_paths, a_skip_access_check, a_tags, a_random_seed, a_with_executables => true); + end; + + function get_suite_items_info( + a_suite_cache_items ut_suite_cache_rows + ) return ut_suite_items_info is + l_results ut_suite_items_info; + begin + select /*+ no_parallel */ &&ut3_owner..ut_suite_item_info( + c.object_owner, c.object_name, c.name, + c.description, c.self_type, c.line_no, + c.path, c.disabled_flag, c.disabled_reason, c.tags + ) + bulk collect into l_results + from table(a_suite_cache_items) c; + return l_results; + end; + + function get_suites_info( + a_schema_paths ut_path_items, + a_skip_access_check boolean + ) return ut_suite_items_info is + begin + return get_suite_items_info( + select_suite_rows(a_schema_paths, a_skip_access_check, a_tags => null, a_random_seed => null, a_with_executables => false) + ); + end; + procedure reconcile_paths_and_suites( a_schema_paths ut_path_items, a_suite_rows ut_suite_cache_rows @@ -372,21 +419,6 @@ create or replace noneditionable package body ut_suite_cache_manager is commit; end; - function get_suite_items_info( - a_suite_cache_items ut_suite_cache_rows - ) return ut_suite_items_info is - l_results ut_suite_items_info; - begin - select /*+ no_parallel */ &&ut3_owner..ut_suite_item_info( - c.object_owner, c.object_name, c.name, - c.description, c.self_type, c.line_no, - c.path, c.disabled_flag, c.disabled_reason, c.tags - ) - bulk collect into l_results - from table(a_suite_cache_items) c; - return l_results; - end; - function get_cached_packages( a_schema_names ut_varchar2_rows ) return ut_object_names is diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index bcb696721..cc078625f 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -74,8 +74,13 @@ create or replace noneditionable package ut_suite_cache_manager authid current_u a_suite_rows ut_suite_cache_rows ); - function get_suite_items_info( - a_suite_cache_items ut_suite_cache_rows + /* + * Retrieves information about the suite items matching the paths, as get_suite_rows does without tags. + * Not to be used publicly. Used internally for ut_runner.get_suites_info. + */ + function get_suites_info( + a_schema_paths ut_path_items, + a_skip_access_check boolean ) return ut_suite_items_info; /* diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 96f45b714..f4e6ceeef 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -394,6 +394,26 @@ create or replace noneditionable package body ut_suite_manager is ut_event_manager.trigger_event('refresh_cache - end'); end; + /* + Resolves the schema names of the paths, refreshes the suite cache of those schemas + and returns the paths split into their parts. + */ + function refresh_cache_for_paths( + a_paths ut_varchar2_list + ) return ut_path_items is + l_paths ut_varchar2_list := a_paths; + l_schema_names ut_varchar2_rows; + l_schema varchar2(4000); + begin + l_schema_names := resolve_schema_names(l_paths); + l_schema := l_schema_names.first; + while l_schema is not null loop + refresh_cache(upper(l_schema_names(l_schema))); + l_schema := l_schema_names.next(l_schema); + end loop; + return ut_suite_cache_manager.get_schema_paths(l_paths); + end; + procedure add_suites_for_paths( a_schema_paths ut_path_items, a_suites in out nocopy ut_suite_items, @@ -477,28 +497,12 @@ create or replace noneditionable package body ut_suite_manager is a_random_seed positive := null, a_tags varchar2 := null ) is - l_paths ut_varchar2_list := a_paths; - l_schema_names ut_varchar2_rows; - l_schema_paths ut_path_items; - l_schema varchar2(4000); begin ut_event_manager.trigger_event('configure_execution_by_path - start'); a_suites := ut_suite_items(); - --resolve schema names from paths and group paths by schema name - l_schema_names := resolve_schema_names(l_paths); - --refresh cache - l_schema := l_schema_names.first; - while l_schema is not null loop - refresh_cache(upper(l_schema_names(l_schema))); - l_schema := l_schema_names.next(l_schema); - end loop; - - l_schema_paths := ut_suite_cache_manager.get_schema_paths(l_paths); - - --We will get a single list of paths rather than loop by loop. add_suites_for_paths( - l_schema_paths, + refresh_cache_for_paths(a_paths), a_suites, a_random_seed, a_tags @@ -512,23 +516,8 @@ create or replace noneditionable package body ut_suite_manager is ) return sys_refcursor is l_result sys_refcursor; l_all_suite_info ut_suite_items_info; - l_schema_names ut_varchar2_rows; - l_schema_paths ut_path_items; - l_paths ut_varchar2_list := a_paths; - l_schema varchar2(4000); - l_suite_rows ut_suite_cache_rows; - begin - l_schema_names := resolve_schema_names(l_paths); - --refresh cache - l_schema := l_schema_names.first; - while l_schema is not null loop - refresh_cache(upper(l_schema_names(l_schema))); - l_schema := l_schema_names.next(l_schema); - end loop; - l_schema_paths := ut_suite_cache_manager.get_schema_paths(l_paths); - l_suite_rows := ut_suite_cache_manager.get_suite_rows(l_schema_paths, skip_access_check()); - l_all_suite_info := ut_suite_cache_manager.get_suite_items_info(l_suite_rows); + l_all_suite_info := ut_suite_cache_manager.get_suites_info(refresh_cache_for_paths(a_paths), skip_access_check()); open l_result for select /*+ no_parallel */ value(c) from table(l_all_suite_info) c From 2114ee863f7aea3b5b70ac397491e8cf6c376634 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 15:16:18 +0200 Subject: [PATCH 838/887] Build each suite item with one constructor call in get_logical_suite get_logical_suite repeated the constructor of ut_suite, ut_suite_context and ut_logical_suite twice, once with the items collected one level below and once with an empty list. It now chooses the items list first. --- .../suite_cache_collection_patterns.md | 2 +- source/core/ut_suite_manager.pkb | 114 ++++++------------ 2 files changed, 38 insertions(+), 78 deletions(-) diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md index 794eee8f4..e64cc6e58 100644 --- a/development/suite_cache_collection_patterns.md +++ b/development/suite_cache_collection_patterns.md @@ -386,7 +386,7 @@ Found in step 2, on 19.20 EE, 2026-11-09: 1. **Rollback type is set twice. Fixed in step 2:** only `reconstruct_from_cache` sets it now. That covers `configure_execution_by_path` and `build_suites_from_annotations`. 2. **Duplicated prologue. Fixed in step 6:** `configure_execution_by_path` and `get_suites_info` both call the private `refresh_cache_for_paths`. 3. **Two near-identical checks. Partly fixed in step 3:** `skip_access_check` replaces the test in `get_filtered_cursor`. The owner needs no special case in the SQL predicate: `all_objects` always includes the user's own packages. `can_skip_all_objects_scan` stays, for `refresh_cache` and `suite_item_exists`. -4. **`get_logical_suite` repeats constructor calls.** It holds 7 constructor calls that differ only in `items =>`. Choosing `items` first would cut it to 4. +4. **`get_logical_suite` repeated constructor calls. Fixed:** it chooses `items` first and has one constructor call per type (4 instead of 7). Measured on 19.20: `configure_execution_by_path` on a whole schema took 420–460 ms (before: 450–480) for UT3_TESTER and 1030–1050 ms (before: 1060–1080) for UT3_USER. 5. **Possible stale items on a bad suitepath (verify).** In `build_and_cache_suites` ([ut_suite_manager.pkb:398](../source/core/ut_suite_manager.pkb:398)), when `create_suite_item_list` raises `ex_string_too_small`, `save_object_cache` still runs with `l_suite_items`. That parameter is `out nocopy`, so it may hold partial or previous-object items. 6. **Arbitrary `row_number` order.** `get_suite_items` deduplicates with `order by path, object_owner` inside a partition by the same columns. That is fine only because the duplicates are identical rows. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index f4e6ceeef..a0432411f 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -142,91 +142,51 @@ create or replace noneditionable package body ut_suite_manager is a_items_at_level t_item_levels ) return ut_suite_item is l_result ut_suite_item; + l_items ut_suite_items; begin + --the items one level below, collected before the parent (rows are sorted bottom up) + l_items := case when a_prev_level > a_level then a_items_at_level(a_prev_level) else ut_suite_items() end; case a_rows( a_idx ).self_type when 'UT_SUITE' then l_result := - case when a_prev_level > a_level then - ut_suite( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => a_items_at_level(a_prev_level), - before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( - a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags - ) - else - ut_suite( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => ut_suite_items(), - before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( - a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags - ) - end; + ut_suite( + self_type => a_rows( a_idx ).self_type, + object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), + name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + items => l_items, + before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( + a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags + ); when 'UT_SUITE_CONTEXT' then l_result := - case when a_prev_level > a_level then - ut_suite_context( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => a_items_at_level(a_prev_level), - before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( - a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags - ) - else - ut_suite_context( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => ut_suite_items(), - before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( - a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags - ) - end; + ut_suite_context( + self_type => a_rows( a_idx ).self_type, + object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), + name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + items => l_items, + before_all_list => sort_by_seq_no( a_rows( a_idx ).before_all_list), after_all_list => sort_by_seq_no( + a_rows( a_idx ).after_all_list), tags => a_rows(a_idx).tags + ); when 'UT_LOGICAL_SUITE' then l_result := - case when a_prev_level > a_level then - ut_logical_suite( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => a_items_at_level(a_prev_level), tags => null - ) - else - ut_logical_suite( - self_type => a_rows( a_idx ).self_type, - object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), - name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, - rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, - line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, - start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, - results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), - items => ut_suite_items(), tags => null - ) - end; + ut_logical_suite( + self_type => a_rows( a_idx ).self_type, + object_owner => a_rows( a_idx ).object_owner, object_name => lower( a_rows( a_idx ).object_name), + name => lower( a_rows( a_idx ).name), description => a_rows( a_idx ).description, path => a_rows( a_idx ).path, + rollback_type => a_rows( a_idx ).rollback_type, disabled_flag => a_rows( a_idx ).disabled_flag, disabled_reason => a_rows(a_idx).disabled_reason, + line_no => a_rows( a_idx ).line_no, parse_time => a_rows( a_idx ).parse_time, + start_time => null, end_time => null, result => null, warnings => a_rows( a_idx ).warnings, + results_count => ut_results_counter(), transaction_invalidators => ut_varchar2_list(), + items => l_items, tags => null + ); when 'UT_TEST' then l_result := ut_test( From f871809b90989f4f8767e177451bde644de4aac2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 15:20:35 +0200 Subject: [PATCH 839/887] Use one rule for skipping the package access check `can_skip_all_objects_scan` and `skip_access_check` are replaced by `can_skip_access_check` --- .../suite_cache_collection_patterns.md | 6 ++- source/core/ut_suite_manager.pkb | 42 ++++++++++--------- source/core/ut_suite_manager.pks | 3 +- test/ut3_tester/core/test_suite_builder.pkb | 3 +- 4 files changed, 29 insertions(+), 25 deletions(-) diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md index e64cc6e58..620c04dc9 100644 --- a/development/suite_cache_collection_patterns.md +++ b/development/suite_cache_collection_patterns.md @@ -385,7 +385,11 @@ Found in step 2, on 19.20 EE, 2026-11-09: 1. **Rollback type is set twice. Fixed in step 2:** only `reconstruct_from_cache` sets it now. That covers `configure_execution_by_path` and `build_suites_from_annotations`. 2. **Duplicated prologue. Fixed in step 6:** `configure_execution_by_path` and `get_suites_info` both call the private `refresh_cache_for_paths`. -3. **Two near-identical checks. Partly fixed in step 3:** `skip_access_check` replaces the test in `get_filtered_cursor`. The owner needs no special case in the SQL predicate: `all_objects` always includes the user's own packages. `can_skip_all_objects_scan` stays, for `refresh_cache` and `suite_item_exists`. +3. **Two near-identical checks. Fixed:** + - `can_skip_all_objects_scan` and `skip_access_check` are replaced by `can_skip_access_check`, in two forms: for one owner, and for a list of paths, where every path's schema must pass. The rule: the user is the owner, or has EXECUTE ANY PROCEDURE. + - `build_suites_from_annotations` loses `a_skip_all_objects`, which only `test_suite_builder` used. Its tests run as the owner, so the access check is skipped as before. + - Owners running their own schema skip the `all_objects` lookup again, as before step 3. + - `test_suite_builder` took 1.24 s (before: 1.50 s); the flows took the same time or less. 4. **`get_logical_suite` repeated constructor calls. Fixed:** it chooses `items` first and has one constructor call per type (4 instead of 7). Measured on 19.20: `configure_execution_by_path` on a whole schema took 420–460 ms (before: 450–480) for UT3_TESTER and 1030–1050 ms (before: 1060–1080) for UT3_USER. 5. **Possible stale items on a bad suitepath (verify).** In `build_and_cache_suites` ([ut_suite_manager.pkb:398](../source/core/ut_suite_manager.pkb:398)), when `create_suite_item_list` raises `ex_string_too_small`, `save_object_cache` still runs with `l_suite_items`. That parameter is `out nocopy`, so it may hold partial or previous-object items. 6. **Arbitrary `row_number` order.** `get_suite_items` deduplicates with `order by path, object_owner` inside a partition by the same columns. That is fine only because the duplicates are identical rows. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index a0432411f..42a6f4da4 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -259,36 +259,39 @@ create or replace noneditionable package body ut_suite_manager is end reconstruct_from_cache; /* - Users with EXECUTE ANY PROCEDURE can run all packages, so their access does not need checking. + A user can run all packages of a schema they own, and of any schema with EXECUTE ANY PROCEDURE, + so the access to those packages does not need checking. */ - function skip_access_check(a_skip_all_objects boolean := false) return boolean is + function can_skip_access_check(a_owner_name varchar2) return boolean is begin - return ut_metadata.user_has_execute_any_proc() or a_skip_all_objects; + return sys_context( 'userenv', 'current_user' ) = upper(a_owner_name) or ut_metadata.user_has_execute_any_proc(); + end; + + function can_skip_access_check(a_schema_paths ut_path_items) return boolean is + begin + for i in 1 .. a_schema_paths.count loop + if not can_skip_access_check(a_schema_paths(i).schema_name) then + return false; + end if; + end loop; + return true; end; function get_cached_suite_data( a_schema_paths ut_path_items, a_random_seed positive, - a_tags varchar2 := null, - a_skip_all_objects boolean := false + a_tags varchar2 := null ) return ut_suite_cache_rows is l_suite_rows ut_suite_cache_rows; begin l_suite_rows := ut_suite_cache_manager.get_suite_rows( - a_schema_paths, skip_access_check(a_skip_all_objects), a_tags, a_random_seed + a_schema_paths, can_skip_access_check(a_schema_paths), a_tags, a_random_seed ); ut_suite_cache_manager.reconcile_paths_and_suites(a_schema_paths,l_suite_rows); return l_suite_rows; end; - function can_skip_all_objects_scan( - a_owner_name varchar2 - ) return boolean is - begin - return sys_context( 'userenv', 'current_user' ) = upper(a_owner_name) or ut_metadata.user_has_execute_any_proc(); - end; - procedure build_and_cache_suites( a_owner_name varchar2, a_annotated_objects sys_refcursor @@ -347,7 +350,7 @@ create or replace noneditionable package body ut_suite_manager is build_and_cache_suites(l_owner_name, l_annotations_cursor); - if can_skip_all_objects_scan(l_owner_name) or ut_metadata.is_object_visible( 'dba_objects') then + if can_skip_access_check(l_owner_name) or ut_metadata.is_object_visible( 'dba_objects') then ut_suite_cache_manager.remove_missing_objs_from_cache( l_owner_name ); end if; @@ -400,8 +403,7 @@ create or replace noneditionable package body ut_suite_manager is a_annotated_objects sys_refcursor, a_path varchar2 := null, a_object_name varchar2 := null, - a_procedure_name varchar2 := null, - a_skip_all_objects boolean := false + a_procedure_name varchar2 := null ) return ut_suite_items is l_suites ut_suite_items := ut_suite_items(); l_schema_paths ut_path_items; @@ -413,8 +415,7 @@ create or replace noneditionable package body ut_suite_manager is get_cached_suite_data( l_schema_paths, null, - null, - a_skip_all_objects + null ) ); return l_suites; @@ -476,8 +477,9 @@ create or replace noneditionable package body ut_suite_manager is ) return sys_refcursor is l_result sys_refcursor; l_all_suite_info ut_suite_items_info; + l_schema_paths ut_path_items := refresh_cache_for_paths(a_paths); begin - l_all_suite_info := ut_suite_cache_manager.get_suites_info(refresh_cache_for_paths(a_paths), skip_access_check()); + l_all_suite_info := ut_suite_cache_manager.get_suites_info(l_schema_paths, can_skip_access_check(l_schema_paths)); open l_result for select /*+ no_parallel */ value(c) from table(l_all_suite_info) c @@ -500,7 +502,7 @@ create or replace noneditionable package body ut_suite_manager is refresh_cache(l_owner_name); l_item_exists := ut_suite_cache_manager.suite_item_exists( l_owner_name, l_package_name, l_procedure_name ); - if not can_skip_all_objects_scan( l_owner_name ) and l_package_name is not null then + if not can_skip_access_check( l_owner_name ) and l_package_name is not null then select /*+ no_parallel */ count(1) into l_count from dual c diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index 373ef1702..f31c6ade7 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -72,8 +72,7 @@ create or replace noneditionable package ut_suite_manager authid current_user is a_annotated_objects sys_refcursor, a_path varchar2 := null, a_object_name varchar2 := null, - a_procedure_name varchar2 := null, - a_skip_all_objects boolean := false + a_procedure_name varchar2 := null ) return ut_suite_items; diff --git a/test/ut3_tester/core/test_suite_builder.pkb b/test/ut3_tester/core/test_suite_builder.pkb index 9a86772c7..15aac2d01 100644 --- a/test/ut3_tester/core/test_suite_builder.pkb +++ b/test/ut3_tester/core/test_suite_builder.pkb @@ -20,8 +20,7 @@ create or replace package body test_suite_builder is a_owner_name => 'UT3_TESTER', a_annotated_objects => l_cursor, a_path => null, - a_object_name => a_package_name, - a_skip_all_objects => true + a_object_name => a_package_name ); l_suite := treat( l_suites(l_suites.first) as ut3_develop.ut_logical_suite); From 270c7415e11ca995c6f7b8a1135a1a7d3a2331ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 15:30:10 +0200 Subject: [PATCH 840/887] Drop all test packages created by test_tfs_junit_reporter --- test/ut3_user/reporters/test_tfs_junit_reporter.pkb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/ut3_user/reporters/test_tfs_junit_reporter.pkb b/test/ut3_user/reporters/test_tfs_junit_reporter.pkb index 105517763..d24406395 100644 --- a/test/ut3_user/reporters/test_tfs_junit_reporter.pkb +++ b/test/ut3_user/reporters/test_tfs_junit_reporter.pkb @@ -233,6 +233,9 @@ create or replace package body test_tfs_junit_reporter as execute immediate 'drop package check_junit_reporting'; execute immediate 'drop package check_junit_rep_suitepath'; execute immediate 'drop package check_junit_flat_suitepath'; + execute immediate 'drop package check_junit_in_context'; + execute immediate 'drop package check_junit_out_context'; + execute immediate 'drop package check_junit_inout_context'; end; procedure check_encoding_included is From 84a3da26a8969d899548213201985e8229afec9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 15:30:10 +0200 Subject: [PATCH 841/887] Document the suitepath limits. --- .../suite_cache_collection_patterns.md | 80 +++++++++++-------- docs/userguide/annotations.md | 4 + 2 files changed, 52 insertions(+), 32 deletions(-) diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md index 620c04dc9..12737c8a7 100644 --- a/development/suite_cache_collection_patterns.md +++ b/development/suite_cache_collection_patterns.md @@ -2,7 +2,15 @@ How `ut_suite_cache_manager` and its callers move suite data between SQL statements through PL/SQL collections instead of joining tables directly, why that happens, and how to simplify it with the two tools now on the branch: code based access control (CBAC) and table SQL macros. -Revised on 2026-11-09 for the CBAC + SQL macro strategy, against branch `feature/code_based_access_control` at commit `05ab7423`. Line references point to that commit. Apart from the macro checks under [Rules for SQL macros](#rules-for-sql-macros-verified), nothing was measured on a live database. Statements marked **verify** need a test or a trace before anyone acts on them. +Revised on 2026-11-09 for the CBAC + SQL macro strategy, against branch `feature/code_based_access_control` at commit `05ab7423`. Line references in the pattern catalogue point to that commit. + +**Status, 2026-11-10:** +- Steps 0 to 6 and findings 2 to 4 are done. +- The branch is pushed, with a PR open, so CI tests 19c, 21 XE and 23 Free. +- Each local commit was checked with a full test run on 19.20. +- Commits after the PR was opened are local and not pushed. +- Finding 5 is verified and reported; it is not fixed. +- Open question 1 is waiting for review. ## Status at a glance @@ -134,55 +142,51 @@ Every `select value(c) ... bulk collect into ... from table(:coll) c` deep-copie ## Flows +The flows below show the code after steps 0 to 6. Before the refactoring, Flow A read the cache twice, through `expand_paths` and `get_suite_items`. It then copied the rows 4 to 6 times, through 5 SQL statements over `table()` collections, before building the object tree. Flow B loaded full rows only to project them to 10 columns. + ### Flow A: run (`ut_runner.run` → `ut_suite_manager.configure_execution_by_path`) ``` a_paths (ut_varchar2_list) - │ resolve_schema_names PL/SQL loop, normalises paths [suite_manager:52] - │ refresh_cache per schema see Flow C + │ refresh_cache_for_paths ut_suite_manager + │ resolve_schema_names PL/SQL, normalises paths + │ refresh_cache per schema see Flow C + │ get_schema_paths PL/SQL: splits paths into ut_path_items (wildcards kept) ut_suite_cache_manager ▼ - get_schema_paths [cache_manager:251] - │ group_paths_by_schema PL/SQL loop → ut_path_items [cache_manager:71] - │ expand_paths SQL: table(paths) ⟕ ut_suite_cache → ut_path_items [cache_manager:109] ① scan of ut_suite_cache + get_cached_suite_data ut_suite_manager + │ can_skip_access_check(paths) owner of every schema, or EXECUTE ANY PROCEDURE + │ get_suite_rows ut_suite_cache_manager + │ get_matched_ids SQL: ut_suite_cache, match_paths macro, all_objects → ids (selected rows and parents) + │ select_suite_rows SQL: tags (is_matching), logical suites, recursive sort → ut_suite_cache_rows + │ reconcile_paths_and_suites SQL: paths × final rows with match_paths → raise errors ut_suite_cache_manager ▼ - get_cached_suite_data [suite_manager:352] - │ get_suite_items SQL: ut_suite_cache ⋈ table(paths) → rows [cache_manager:180] ② scan of ut_suite_cache, copy #1 - │ ut_suite_tag_filter.apply dynamic SQL over table(rows) → rows [tag_filter:268] copy #2 (only with tags) - │ get_cached_suite_rows SQL over table(rows) + generated logical suites [cache_manager:256] copy #3 - │ get_filtered_cursor SQL over table(rows) ⋈ all_objects → rows [suite_manager:299] copy #4 (unless EXECUTE ANY) - │ reconcile_paths_and_suites SQL: table(paths) ⟕ table(rows) → raise errors [suite_manager:328] - │ sort_and_randomize_tests recursive SQL over table(rows) ⋈ table(rows) → rows [cache_manager:214] copy #5 - │ open cursor for select * from table(rows) [suite_manager:371] copy #6 (fetch) - ▼ - reconstruct_from_cache bulk fetch limit 1000 → tt_cached_suites → object tree [suite_manager:253] + reconstruct_from_cache select * bulk collect into records → object tree (ORA-00600 workaround, P6) ``` -The cache table is read twice with nearly the same matching rules. The result set is then copied 4 to 6 times, through 5 SQL statements over `table()` collections, before it becomes the object tree. Unchanged since the CBAC commits. +Three SQL statements read the cache (one scan for the paths, one for the rows by id), and the rows are copied once into records. -### Flow B: suite info (`ut_runner.get_suites_info`, `ut_runner.has_suites`, ...) +### Flow B: suite info (`ut_runner.get_suites_info`) ``` -a_paths → resolve_schema_names → refresh_cache per schema → get_schema_paths (①) [suite_manager:566] - │ get_cached_suite_info = get_cached_suite_rows(get_suite_items(paths)) (②, copies #1, #2) [cache_manager:404] - │ get_filtered_cursor (copy #3) - │ get_suite_items_info SQL over table(rows) → ut_suite_items_info (copy #4, projection) [cache_manager:411] +a_paths → refresh_cache_for_paths → can_skip_access_check(paths) ut_suite_manager + │ ut_suite_cache_manager.get_suites_info + │ select_suite_rows without executables (no tags, no seed) → light ut_suite_cache_rows + │ get_suite_items_info SQL projection → ut_suite_items_info ▼ open cursor select value(c) from table(info) order by owner, name, line_no ``` -Full rows, with all six executable lists, are loaded and copied three times, only to be projected to 10 scalar columns at the end. Tags are not applied here and the rows are not sorted. - -### Flow C: cache refresh (`ut_suite_manager.refresh_cache`, [suite_manager:426](../source/core/ut_suite_manager.pkb:426)) +### Flow C: cache refresh (`ut_suite_manager.refresh_cache`) ``` get_schema_parse_time(owner) scalar ut_annotation_manager.get_annotated_objects(...) sys_refcursor of ut_annotated_object -build_and_cache_suites [suite_manager:383] +build_and_cache_suites │ fetch limit 10 → ut_annotated_objects │ per object: ut_suite_builder.create_suite_item_list → ut_suite_items (PL/SQL) - │ per object: save_object_cache(ut_suite_items) [cache_manager:279] + │ per object: save_object_cache(ut_suite_items) │ autonomous tx: 2 × insert ... select from table(a_suite_items) with treat() -remove_missing_objs_from_cache(owner) one delete, macro (P8, done) [cache_manager:389] +remove_missing_objs_from_cache(owner) one delete, with the get_cached_objects macro (P8) ``` ### Flow D: smaller lookups @@ -391,7 +395,19 @@ Found in step 2, on 19.20 EE, 2026-11-09: - Owners running their own schema skip the `all_objects` lookup again, as before step 3. - `test_suite_builder` took 1.24 s (before: 1.50 s); the flows took the same time or less. 4. **`get_logical_suite` repeated constructor calls. Fixed:** it chooses `items` first and has one constructor call per type (4 instead of 7). Measured on 19.20: `configure_execution_by_path` on a whole schema took 420–460 ms (before: 450–480) for UT3_TESTER and 1030–1050 ms (before: 1060–1080) for UT3_USER. -5. **Possible stale items on a bad suitepath (verify).** In `build_and_cache_suites` ([ut_suite_manager.pkb:398](../source/core/ut_suite_manager.pkb:398)), when `create_suite_item_list` raises `ex_string_too_small`, `save_object_cache` still runs with `l_suite_items`. That parameter is `out nocopy`, so it may hold partial or previous-object items. +5. **Partial items cached on a too long path. Verified on 19.20, 2026-11-10; not fixed.** + - **The code:** in `build_and_cache_suites`, when `create_suite_item_list` raises `ex_string_too_small` (a path over 1000 characters), `save_object_cache` still runs with `l_suite_items`. + - **No stale items from the previous package:** Oracle resets the `out nocopy` collection when the procedure is called. + - Probed with a package whose suitepath has 1199 characters, between two valid packages. + - The error happens in `build_suitepath` before any item is added, so nothing is cached for that package. + - **Partial items are cached when the error comes later:** + - Probed with a package whose suitepath fits (983 characters with the package name), with a context `c` and a test inside it, and a top-level test whose path has 1004 characters. + - The context and its test were cached, without the package's suite row and without the long test, together with a package row and a parse time. + - **Consequence:** + 1. The first run raises "Suitepath exceeds 1000 CHAR on: …". + 2. Later runs treat the package as cached and raise nothing. + 3. The context has no parent suite, so the package is missing from `get_suites_info`, and running it fails with "Suite package … does not exist", until the package is changed. + - **Possible fix:** save an empty item list when `create_suite_item_list` fails, so the package is not cached and the error is raised on every run. 6. **Arbitrary `row_number` order.** `get_suite_items` deduplicates with `order by path, object_owner` inside a partition by the same columns. That is fine only because the duplicates are identical rows. ## Target design @@ -497,7 +513,7 @@ Notes: ## Open questions -1. Should a package path whose tests are all excluded by tags raise "does not exist" (P5)? +1. Should a package path whose tests are all excluded by tags raise "does not exist" (P5)? That's the behaviour today; review it after the other work is done. 2. ~~Can logical suites remain in the tree with no accessible children (P1)?~~ Answered: yes, they could. Accessible packages under an inaccessible parent suite were also lost. Both are fixed in step 3; see the table under P1. -3. Is the 20-level limit on suitepath depth (P3) documented anywhere, or is it accidental? -4. Would a `parse_time` filter in `get_objects_to_refresh` pay off (removed in step 0)? Only a measurement on a schema with many cached objects can tell. If it would, use the bind-safe form. +3. ~~Is the 20-level limit on suitepath depth (P3) documented?~~ It is intended and is now documented in the user guide (annotations, "Suitepath limits"), together with the 1000-character limit on full paths. Verified on 19.20: a suite with a 21-level suitepath is not run in a schema run and not listed by `get_suites_info`. +4. ~~Would a `parse_time` filter in `get_objects_to_refresh` pay off?~~ Not pursued (decided 2026-11-10). diff --git a/docs/userguide/annotations.md b/docs/userguide/annotations.md index cb3ed8aac..13ed97a23 100644 --- a/docs/userguide/annotations.md +++ b/docs/userguide/annotations.md @@ -1704,6 +1704,10 @@ end test_payment_set_off; When you execute tests for your application, the framework constructs a test suite for each test package. Then it combines suites into grouping suites by the `--%suitepath` annotation value so that the fully qualified path to the `recognize_by_num` procedure is `USER:payments.test_payment_recognition.test_recognize_by_num`. If any of its expectations fails then the test is marked as failed, also the `test_payment_recognition` suite, the parent suite `payments` and the whole run is marked as failed. The test report indicates which expectation has failed on the payments module. The payments recognition submodule is causing the failure as `recognize_by_num` has not met the expectations of the test. Grouping tests into modules and submodules using the `--%suitepath` annotation allows you to logically organize your project's flat structure of packages into functional groups. +!!! note "Suitepath limits" + - A suitepath can have at most 20 levels (elements separated by dots), for example `org.utplsql.example` has 3. Suites with a deeper suitepath are not run and not listed. + - The full path of every suite item (suitepath, package, contexts and test name) can be at most 1000 characters long. Longer paths raise an error when the suites are built. + An additional advantage of such grouping is the fact that every element level of the grouping can be an actual unit test package containing a common module level setup for all of the submodules. So in addition to the packages mentioned above you could have the following package. ```sql linenums="1" create or replace package payments as From 6e7597b7f6adebc3d4b0b12e200014988e87ac7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 21:19:56 +0200 Subject: [PATCH 842/887] Document and test wildcard paths combined with tags --- docs/userguide/running-unit-tests.md | 2 + test/ut3_user/api/test_ut_run.pkb | 58 +++++++++++++++++++++++++++- test/ut3_user/api/test_ut_run.pks | 12 ++++++ 3 files changed, 70 insertions(+), 2 deletions(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 48d14281e..5fc6689e1 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -46,6 +46,8 @@ The examples below illustrate different ways and options to invoke `ut.run` proc You can use a wildcard character `*` to call tests by part of their name or to call tests that are located on paths matched by part of path string. Wildcard character can be placed anywhere on the path and can occur mutliple times. Schema name cannot contain a wildcard character whether is in a suitepath call or call by object name. +A path with a wildcard selects every matching suite or test that you can run and that matches the tags (see [Run by Tags](#run-by-tags)). +Matches that you can't run, or that the tags exclude, are skipped. The run fails with a "does not exist" error only when nothing is left. ```sql linenums="1" alter session set current_schema=hr; diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 8c99af7d7..e6b49dec8 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1296,9 +1296,63 @@ procedure tag_exclude_run_fun_pth_lst_lg is ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); l_results := ut3_tester_helper.run_helper.run(a_tags => '(development|end_to_end))'); - ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); - ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_match('^\s*invalid_tag_expression \[[,\.0-9]+ sec\]\s*$','m'); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like('%(FAILED -%'); + + end; + + procedure tag_run_pkg_wildcard is + l_results clob; + begin + --test_tag_pkg_3 has no test tagged fast + l_results := ut3_tester_helper.main_helper.table_to_clob( + ut3_tester_helper.run_helper.run('ut3_tester_helper.test_tag_pkg_*', a_tags => 'fast') + ); + --Assert + ut.expect( l_results ).to_be_like( '%test_tag_pkg_1.test1 executed%' ); + ut.expect( l_results ).to_be_like( '%test_tag_pkg_2.test3 executed%' ); + ut.expect( l_results ).not_to_be_like( '%test_tag_pkg_1.test2 executed%' ); + ut.expect( l_results ).not_to_be_like( '%test_tag_pkg_2.test4 executed%' ); + ut.expect( l_results ).not_to_be_like( '%test_tag_pkg_3%' ); + end; + + procedure tag_run_proc_wildcard is + l_results clob; + begin + --test_tag_pkg_1.test2 is not tagged fast + l_results := ut3_tester_helper.main_helper.table_to_clob( + ut3_tester_helper.run_helper.run('ut3_tester_helper.test_tag_pkg_1.test*', a_tags => 'fast') + ); + --Assert + ut.expect( l_results ).to_be_like( '%test_tag_pkg_1.test1 executed%' ); + ut.expect( l_results ).not_to_be_like( '%test_tag_pkg_1.test2 executed%' ); + ut.expect( l_results ).not_to_be_like( '%test_tag_pkg_2%' ); + ut.expect( l_results ).not_to_be_like( '%test_tag_pkg_3%' ); + end; + procedure tag_run_suitepath_wildcard is + l_results clob; + begin + --suitepath suite3 (test_tag_pkg_3) has no test tagged fast + l_results := ut3_tester_helper.main_helper.table_to_clob( + ut3_tester_helper.run_helper.run('ut3_tester_helper:suite*', a_tags => 'fast') + ); + --Assert + ut.expect( l_results ).to_be_like( '%test_tag_pkg_1.test1 executed%' ); + ut.expect( l_results ).to_be_like( '%test_tag_pkg_2.test3 executed%' ); + ut.expect( l_results ).not_to_be_like( '%test_tag_pkg_1.test2 executed%' ); + ut.expect( l_results ).not_to_be_like( '%test_tag_pkg_2.test4 executed%' ); + ut.expect( l_results ).not_to_be_like( '%test_tag_pkg_3%' ); + end; + + procedure tag_run_wildcard_none_left is + l_results ut3_develop.ut_varchar2_list; + begin + l_results := ut3_tester_helper.run_helper.run('ut3_tester_helper.test_tag_pkg_*', a_tags => 'nonexisting'); + ut.fail('Expected exception ORA-20204 was not raised'); + exception + when others then + ut.expect(sqlerrm).to_be_like('%ORA-20204: Suite package ut3_tester_helper.test_tag_pkg_* does not exist%'); end; procedure set_application_info is diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index c57788bff..980f6cebb 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -266,6 +266,18 @@ create or replace package test_ut_run is --%throws(-20219) procedure invalid_tag_expression; + --%test(Runs tests matching the tags from packages selected by a wildcard, skipping packages without such tests) + procedure tag_run_pkg_wildcard; + + --%test(Runs tests matching the tags from tests selected by a wildcard, skipping the other tests) + procedure tag_run_proc_wildcard; + + --%test(Runs tests matching the tags from suitepaths selected by a wildcard, skipping suites without such tests) + procedure tag_run_suitepath_wildcard; + + --%test(Raises an error naming the wildcard path when the tags exclude all tests it selects) + procedure tag_run_wildcard_none_left; + --%endcontext --%context(ut3_info context) From c6a160135968db7518ef6543eb54e2fd751f8142 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 21:33:49 +0200 Subject: [PATCH 843/887] Document and test that only * is a wildcard in run paths --- docs/userguide/running-unit-tests.md | 1 + test/ut3_tester/core/test_suite_manager.pkb | 109 ++++++++++++++++++++ test/ut3_tester/core/test_suite_manager.pks | 22 ++++ 3 files changed, 132 insertions(+) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 5fc6689e1..2c8b6065b 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -46,6 +46,7 @@ The examples below illustrate different ways and options to invoke `ut.run` proc You can use a wildcard character `*` to call tests by part of their name or to call tests that are located on paths matched by part of path string. Wildcard character can be placed anywhere on the path and can occur mutliple times. Schema name cannot contain a wildcard character whether is in a suitepath call or call by object name. +Only `*` is a wildcard. All other characters, including `_`, `.` and `$`, match only themselves. A path with a wildcard selects every matching suite or test that you can run and that matches the tags (see [Run by Tags](#run-by-tags)). Matches that you can't run, or that the tags exclude, are skipped. The run fails with a "does not exist" error only when nothing is left. diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index b296ca3cb..d3afae3aa 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -2249,6 +2249,115 @@ end;]'; end; --%test(Path validation does not fail on Estonian NLS_SORT - fix #1252) + /* + Names that differ only where a "_" or "." is: + tst_char_a / tstxchar_a, test_a / testxa, chars.sub_a / chars.subxa, chars.sub / chars_sub + */ + procedure create_char_test_packages is + pragma autonomous_transaction; + begin + execute immediate q'[create or replace package tst_char_a is + --%suite + --%suitepath(chars.sub_a) + + --%test + procedure test_a; + + --%test + procedure testxa; + end;]'; + execute immediate q'[create or replace package tstxchar_a is + --%suite + --%suitepath(chars.subxa) + + --%test + procedure test_a; + end;]'; + execute immediate q'[create or replace package tst_char_b is + --%suite + --%suitepath(chars_sub) + + --%test + procedure test_b; + end;]'; + end; + + procedure drop_char_test_packages is + pragma autonomous_transaction; + begin + execute immediate 'drop package tst_char_a'; + execute immediate 'drop package tstxchar_a'; + execute immediate 'drop package tst_char_b'; + end; + + --returns the paths of all tests, sorted and separated by commas + function get_test_paths(a_items ut3_develop.ut_suite_items) return varchar2 is + l_paths ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list(); + l_result varchar2(32767); + + procedure add_test_paths(a_suite_items ut3_develop.ut_suite_items) is + begin + for i in 1 .. a_suite_items.count loop + if a_suite_items(i) is of (ut3_develop.ut_test) then + l_paths.extend; + l_paths(l_paths.last) := a_suite_items(i).path; + else + add_test_paths(treat(a_suite_items(i) as ut3_develop.ut_logical_suite).items); + end if; + end loop; + end; + begin + add_test_paths(a_items); + select listagg(column_value, ',') within group (order by column_value) into l_result from table(l_paths); + return l_result; + end; + + procedure underscore_in_package_name is + l_objects_to_run ut3_develop.ut_suite_items; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path( + ut3_develop.ut_varchar2_list(sys_context('USERENV', 'CURRENT_USER')||'.tst_char_a') + ); + --Assert + ut.expect(get_test_paths(l_objects_to_run)).to_equal('chars.sub_a.tst_char_a.test_a,chars.sub_a.tst_char_a.testxa'); + end; + + procedure underscore_in_procedure_name is + l_objects_to_run ut3_develop.ut_suite_items; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path( + ut3_develop.ut_varchar2_list(sys_context('USERENV', 'CURRENT_USER')||'.tst_char_a.test_a') + ); + --Assert + ut.expect(get_test_paths(l_objects_to_run)).to_equal('chars.sub_a.tst_char_a.test_a'); + end; + + procedure underscore_in_suitepath is + l_objects_to_run ut3_develop.ut_suite_items; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path( + ut3_develop.ut_varchar2_list(sys_context('USERENV', 'CURRENT_USER')||':chars.sub_a') + ); + --Assert + ut.expect(get_test_paths(l_objects_to_run)).to_equal('chars.sub_a.tst_char_a.test_a,chars.sub_a.tst_char_a.testxa'); + end; + + procedure dot_in_suitepath_wildcard is + l_objects_to_run ut3_develop.ut_suite_items; + begin + --Act + l_objects_to_run := ut3_develop.ut_suite_manager.configure_execution_by_path( + ut3_develop.ut_varchar2_list(sys_context('USERENV', 'CURRENT_USER')||':chars.sub*') + ); + --Assert + ut.expect(get_test_paths(l_objects_to_run)).to_equal( + 'chars.sub_a.tst_char_a.test_a,chars.sub_a.tst_char_a.testxa,chars.subxa.tstxchar_a.test_a' + ); + end; + procedure path_validate_nls_sort is l_schema_names ut3_develop.ut_varchar2_rows; begin diff --git a/test/ut3_tester/core/test_suite_manager.pks b/test/ut3_tester/core/test_suite_manager.pks index 4854bd8eb..a7d3bcc20 100644 --- a/test/ut3_tester/core/test_suite_manager.pks +++ b/test/ut3_tester/core/test_suite_manager.pks @@ -240,6 +240,28 @@ create or replace package test_suite_manager is --%endcontext + --%context(literal_characters) + --%displayname(Characters other than * in a path match only themselves) + + --%beforeall + procedure create_char_test_packages; + --%afterall + procedure drop_char_test_packages; + + --%test(Underscore in a package name is not a wildcard) + procedure underscore_in_package_name; + + --%test(Underscore in a procedure name is not a wildcard) + procedure underscore_in_procedure_name; + + --%test(Underscore in a suitepath is not a wildcard) + procedure underscore_in_suitepath; + + --%test(Dot in a suitepath with a wildcard is not a wildcard) + procedure dot_in_suitepath_wildcard; + + --%endcontext + --%context(paths validation) --%test(Path validation does not fail on Estonian NLS_SORT - fix #1252) From 095508e257904e99c528a1dc77d044c438434a31 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 22:07:36 +0200 Subject: [PATCH 844/887] Warn when a parent suite of a runnable package is not accessible --- .../suite_cache_collection_patterns.md | 2 ++ docs/userguide/running-unit-tests.md | 10 +++++++ source/core/ut_suite_cache_manager.pkb | 18 +++++++++-- .../annotations/test_annotation_cache.pkb | 30 +++++++++++++++++++ .../annotations/test_annotation_cache.pks | 6 ++++ .../annotation_cache_helper.pkb | 11 +++---- .../annotation_cache_helper.pks | 2 +- 7 files changed, 71 insertions(+), 8 deletions(-) diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md index 12737c8a7..3bdb498f8 100644 --- a/development/suite_cache_collection_patterns.md +++ b/development/suite_cache_collection_patterns.md @@ -244,6 +244,8 @@ The setup: `probe_user` has EXECUTE on `child_suite`, but not on `parent_suite`, The new behaviour was accepted on 2026-11-09. It is covered by the context "Suites spread across packages, user without elevated privileges" in `test_annotation_cache`. Its 4 tests fail on the code before step 3 and pass after it. +Reviewed again on 2026-11-10 (option D of four: drop the child, run it without the parent, skip it, or run it with a warning). The child still runs, and the logical suite that takes the place of the inaccessible parent now carries a run warning naming that parent: its beforeall/afterall, rollback setting and tags don't apply. `select_suite_rows` finds the parent by joining the logical suites back to `ut_suite_cache`. Documented in the user guide ("Running tests owned by other users"); tested by `user_warned_about_hidden_parent` and `user_runs_child_without_parent_tags`. + ### P2: chain of collection-to-collection transforms - **Where:** Flow A, copies #1 → #5. Each step is a function `f(ut_suite_cache_rows) return ut_suite_cache_rows` with one `select ... from table(:coll)`. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 2c8b6065b..ba18f85fa 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -263,6 +263,16 @@ select from dual; ``` +## Running tests owned by other users + +To run tests in another schema, you need the EXECUTE privilege on its test packages, or the EXECUTE ANY PROCEDURE privilege. +Packages that you can't execute are skipped. + +If such a package is a parent suite (by `--%suitepath`) of a package that you can execute, the child package still runs. +A logical suite with the same name takes the parent's place, so the parent's `--%beforeall`/`--%afterall`, `--%rollback` and `--%tags` don't apply to the child. +The run reports a warning that names the skipped parent suite. + +A path that selects only packages you can't execute fails with a "does not exist" error. ## Order of test execution diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 4bf26a0db..f7e3e2657 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -91,7 +91,8 @@ create or replace noneditionable package body ut_suite_cache_manager is - matched_rows: the rows from get_matched_ids - tagged_rows: when tags are given, the rows having a test matching the tag expression below them (or being one); a test inherits the tags of the suites and contexts above it - - logical_suites: suites for the parts of the suitepaths that have no package behind them + - logical_suites: suites for the parts of the suitepaths that have no package behind them, + or whose package the user can't access (with a warning in that case) - ordered: the hierarchy sorted depth first by line number, or by a hash of the path when a_random_seed is given The tag expression is evaluated per test by ut_suite_tag_filter.is_matching, so the statement is static SQL. Without a_with_executables, the rows have no executables (before/after lists, test item), which only a run needs. @@ -201,7 +202,14 @@ create or replace noneditionable package body ut_suite_cache_manager is else &&ut3_owner..ut_suite_cache_row( null, 'UT_LOGICAL_SUITE', o.path, o.object_owner, o.object_name, o.object_name, null, null, null, null, 0, null, - &&ut3_owner..ut_varchar2_rows(), + case + when h.id is null then &&ut3_owner..ut_varchar2_rows() + else &&ut3_owner..ut_varchar2_rows( + 'Suite ' || lower(h.object_owner || '.' || h.object_name) + || ' is not run, as it does not exist or you have no EXECUTE privilege on it.' + || ' Its beforeall/afterall, rollback setting and tags are not applied to the suites below it.' + ) + end, null, null, null, null, null, null, null, null, null ) @@ -210,6 +218,12 @@ create or replace noneditionable package body ut_suite_cache_manager is from ordered o left join &&ut3_owner..ut_suite_cache c on c.id = o.id + --a package suite that get_matched_ids left out as not accessible, replaced by a logical suite + left join &&ut3_owner..ut_suite_cache h + on o.id is null + and h.object_owner = o.object_owner + and h.path = o.path + and h.self_type = 'UT_SUITE' order by o.order1 desc; return l_results; diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pkb b/test/ut3_tester/core/annotations/test_annotation_cache.pkb index 1f7c83617..36f8f983d 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pkb +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pkb @@ -529,6 +529,36 @@ create or replace package body test_annotation_cache is rollback; end; + procedure user_warned_about_hidden_parent is + l_actual clob; + pragma autonomous_transaction; + begin + --Act + l_actual := annotation_cache_helper.run_tests_as( 'ut3_no_extra_priv_user', 'ut3_cache_test_owner.child_suite' ); + --Assert + ut.expect( l_actual ).to_be_like( + '%Warnings:%parent_suite%Suite ut3_cache_test_owner.parent_suite is not run, as it does not exist or you have no EXECUTE privilege on it.%' + ); + ut.expect( l_actual ).to_be_like( '%1 tests, 0 failed, 0 errored, 0 disabled, 1 warning(s)%' ); + rollback; + end; + + procedure user_runs_child_without_parent_tags is + l_actual clob; + pragma autonomous_transaction; + begin + --Act - child_suite inherits parent_tag only when parent_suite is accessible + l_actual := annotation_cache_helper.run_tests_as( 'ut3_no_extra_priv_user', 'ut3_cache_test_owner', '!parent_tag' ); + --Assert + ut.expect( l_actual ).to_be_like( '%child_test%1 tests, 0 failed%' ); + --Act + l_actual := annotation_cache_helper.run_tests_as( 'ut3_cache_test_owner', 'ut3_cache_test_owner', '!parent_tag' ); + --Assert + ut.expect( l_actual ).not_to_be_like( '%child_test%' ); + ut.expect( l_actual ).not_to_be_like( '%parent_test%' ); + rollback; + end; + procedure user_runs_hidden_suite_path is l_actual clob; pragma autonomous_transaction; diff --git a/test/ut3_tester/core/annotations/test_annotation_cache.pks b/test/ut3_tester/core/annotations/test_annotation_cache.pks index da733952a..fec89cf3b 100644 --- a/test/ut3_tester/core/annotations/test_annotation_cache.pks +++ b/test/ut3_tester/core/annotations/test_annotation_cache.pks @@ -284,6 +284,12 @@ create or replace package test_annotation_cache is --%test(Runs a granted package whose parent suite is in a package that is not granted) procedure user_runs_child_of_hidden_suite; + --%test(Warns that the parent suite in a package that is not granted is not run) + procedure user_warned_about_hidden_parent; + + --%test(Does not apply tags of the parent suite in a package that is not granted) + procedure user_runs_child_without_parent_tags; + --%test(Runs a granted package when its parent suitepath is given) procedure user_runs_hidden_suite_path; diff --git a/test/ut3_tester_helper/annotation_cache_helper.pkb b/test/ut3_tester_helper/annotation_cache_helper.pkb index 730689786..63e20159d 100644 --- a/test/ut3_tester_helper/annotation_cache_helper.pkb +++ b/test/ut3_tester_helper/annotation_cache_helper.pkb @@ -92,7 +92,7 @@ create or replace package body annotation_cache_helper as /* Suites spread across packages, only child_suite is granted: - parent_suite package parent_suite, not granted + parent_suite package parent_suite, not granted, tagged parent_tag parent_suite.child_suite package child_suite, granted hidden_path.sub.lone_suite package lone_suite, not granted, below logical suites hidden_path and hidden_path.sub */ @@ -102,6 +102,7 @@ create or replace package body annotation_cache_helper as execute immediate 'create or replace package ut3_cache_test_owner.parent_suite authid definer is --%suite + --%tags(parent_tag) --%test procedure parent_test; @@ -182,11 +183,11 @@ create or replace package body annotation_cache_helper as pragma autonomous_transaction; begin execute immediate - 'create or replace function ' || a_user || '.call_ut_run(a_path varchar2 := ''ut3_cache_test_owner'') return clob is + 'create or replace function ' || a_user || '.call_ut_run(a_path varchar2 := ''ut3_cache_test_owner'', a_tags varchar2 := null) return clob is l_data ut3_develop.ut_varchar2_list; l_results clob; begin - select * bulk collect into l_data from table (ut3_develop.ut.run( a_path )); + select * bulk collect into l_data from table (ut3_develop.ut.run( a_path, a_tags => a_tags )); return ut3_tester_helper.main_helper.table_to_clob( l_data ); end; '; @@ -232,10 +233,10 @@ create or replace package body annotation_cache_helper as drop_run_function_for_user( 'ut3_develop' ); end; - function run_tests_as(a_user varchar2, a_path varchar2 := 'ut3_cache_test_owner') return clob is + function run_tests_as(a_user varchar2, a_path varchar2 := 'ut3_cache_test_owner', a_tags varchar2 := null) return clob is l_results clob; begin - execute immediate 'begin :x := '||a_user||'.call_ut_run(:a_path); end;' using out l_results, a_path; + execute immediate 'begin :x := '||a_user||'.call_ut_run(:a_path, :a_tags); end;' using out l_results, a_path, a_tags; return l_results; end; diff --git a/test/ut3_tester_helper/annotation_cache_helper.pks b/test/ut3_tester_helper/annotation_cache_helper.pks index 9c00ae9aa..88b82d872 100644 --- a/test/ut3_tester_helper/annotation_cache_helper.pks +++ b/test/ut3_tester_helper/annotation_cache_helper.pks @@ -18,7 +18,7 @@ create or replace package annotation_cache_helper as procedure create_run_function_for_users; procedure drop_run_function_for_users; - function run_tests_as(a_user varchar2, a_path varchar2 := 'ut3_cache_test_owner') return clob; + function run_tests_as(a_user varchar2, a_path varchar2 := 'ut3_cache_test_owner', a_tags varchar2 := null) return clob; function get_suites_info_as(a_user varchar2) return clob; end; From 01f6b091f7bae25cde03a2ba83aae103807e740f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 22:10:55 +0200 Subject: [PATCH 845/887] Check the tag expression before selecting suites --- docs/userguide/running-unit-tests.md | 1 + source/core/ut_suite_manager.pkb | 5 +++++ test/ut3_user/api/test_ut_run.pkb | 7 +++++++ test/ut3_user/api/test_ut_run.pks | 4 ++++ 4 files changed, 17 insertions(+) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index ba18f85fa..d3bf04bff 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -338,6 +338,7 @@ Multiple tags are separated by comma. ### Tag Expressions Tag expressions are boolean expressions created by combining tags with the `!`, `&`, `|` operators. Tag expressions can be grouped using `(` and `)` braces. Grouping tag expressions affects operator precedence. +An invalid tag expression raises an error (ORA-20219) before any test runs. Two reserved keywords, `any` and `none`, can be used when creating a tag expression to run tests. - `any` keyword represents tests and suites with any tags diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index 42a6f4da4..aa059309c 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -458,8 +458,13 @@ create or replace noneditionable package body ut_suite_manager is a_random_seed positive := null, a_tags varchar2 := null ) is + l_tags_match integer; begin ut_event_manager.trigger_event('configure_execution_by_path - start'); + --raise an error for an invalid tag expression even when the paths select no tests to evaluate it on + if a_tags is not null then + l_tags_match := ut_suite_tag_filter.is_matching(null, a_tags); + end if; a_suites := ut_suite_items(); add_suites_for_paths( diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index e6b49dec8..7f4ee84ab 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1301,6 +1301,13 @@ procedure tag_exclude_run_fun_pth_lst_lg is end; + procedure invalid_tag_expression_no_tests is + l_results ut3_develop.ut_varchar2_list; + begin + --the package does not exist, so no test is there to evaluate the tag expression on + l_results := ut3_tester_helper.run_helper.run('ut3_tester_helper.no_such_test_package', a_tags => '(development|end_to_end))'); + end; + procedure tag_run_pkg_wildcard is l_results clob; begin diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index 980f6cebb..067ae2c6f 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -266,6 +266,10 @@ create or replace package test_ut_run is --%throws(-20219) procedure invalid_tag_expression; + --%test(Raises an error for an invalid tag expression when the path selects no tests) + --%throws(-20219) + procedure invalid_tag_expression_no_tests; + --%test(Runs tests matching the tags from packages selected by a wildcard, skipping packages without such tests) procedure tag_run_pkg_wildcard; From 21ab1f7b1dcfb07ed6c75e8a2f364859b345b6f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 22:30:37 +0200 Subject: [PATCH 846/887] Group the suites of a run by schema A run can include paths in several schemas, and their suites are siblings at the top level of the run. They were ordered by line number and path, so suites of different schemas could interleave. --- docs/userguide/running-unit-tests.md | 2 +- source/core/ut_suite_cache_manager.pkb | 8 ++++-- test/ut3_user/api/test_ut_run.pkb | 39 ++++++++++++++++++++++++++ test/ut3_user/api/test_ut_run.pks | 13 +++++++++ 4 files changed, 58 insertions(+), 4 deletions(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index d3bf04bff..961eb5001 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -279,7 +279,7 @@ A path that selects only packages you can't execute fails with a "does not exist ### Default order When unit tests are executed without random order, they are ordered by: -- schema name +- schema name: when a run includes several schemas, the suites of each schema run together, in order of schema names - suite path or test package name if `--%suitepath` was not specified for that package - `--%test` line number in package diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index f7e3e2657..3a99226b6 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -93,7 +93,7 @@ create or replace noneditionable package body ut_suite_cache_manager is a test inherits the tags of the suites and contexts above it - logical_suites: suites for the parts of the suitepaths that have no package behind them, or whose package the user can't access (with a warning in that case) - - ordered: the hierarchy sorted depth first by line number, or by a hash of the path when a_random_seed is given + - ordered: the hierarchy sorted depth first by schema, then by line number, or by a hash of the path when a_random_seed is given The tag expression is evaluated per test by ut_suite_tag_filter.is_matching, so the statement is static SQL. Without a_with_executables, the rows have no executables (before/after lists, test item), which only a run needs. */ @@ -185,8 +185,10 @@ create or replace noneditionable package body ut_suite_cache_manager is on s.parent_path = o.path and s.object_owner = o.object_owner ) - --path, object_owner: siblings with the same line number (packages, logical suites) keep the order of their paths - search depth first by line_no desc, random_seed desc nulls last, path, object_owner set order1 + --object_owner first: a run can span several schemas, so top level items are grouped by schema + --(below the top level all items of a subtree have the same owner) + --path: siblings with the same line number (packages, logical suites) keep the order of their paths + search depth first by object_owner, line_no desc, random_seed desc nulls last, path set order1 select /*+ no_parallel */ case when o.id is not null and l_with_executables = 'Y' then value(c) diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 7f4ee84ab..3733f0623 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -23,6 +23,45 @@ create or replace package body test_ut_run is ut3_tester_helper.run_helper.drop_ut3_user_tests(); end; + --a suite on suitepath "tests", as test_package_1 in ut3_tester_helper (see run_helper.create_ut3_user_tests) + procedure create_test_suite_in_ut3_user is + pragma autonomous_transaction; + begin + execute immediate q'[create or replace package test_suite_in_ut3_user is + --%suite + --%suitepath(tests) + + --%test + procedure test1; + end;]'; + execute immediate q'[create or replace package body test_suite_in_ut3_user is + procedure test1 is + begin + dbms_output.put_line('test_suite_in_ut3_user.test1 executed'); + end; + end;]'; + end; + + procedure drop_test_suite_in_ut3_user is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_suite_in_ut3_user'; + end; + + procedure run_groups_suites_by_schema is + l_results clob; + begin + --Act - ut3_user:tests sorts between ut3_tester_helper:tests and ut3_tester_helper:tests2 by path + l_results := ut3_tester_helper.main_helper.table_to_clob( + ut3_tester_helper.run_helper.run( + ut3_develop.ut_varchar2_list('ut3_user:tests', 'ut3_tester_helper:tests', 'ut3_tester_helper:tests2'), + a_tags => null + ) + ); + --Assert - UT3_TESTER_HELPER comes before UT3_USER + ut.expect( l_results ).to_be_like( '%test_package_2.test1 executed%test_package_3.test1 executed%test_suite_in_ut3_user.test1 executed%' ); + end; + procedure ut_version is begin ut.expect(ut3_develop.ut.version()).to_match('^v\d+\.\d+\.\d+\.\d+(-\w+)?$'); diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index 067ae2c6f..d7da98871 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -181,6 +181,19 @@ create or replace package test_ut_run is --%endcontext + --%context(run with paths in several schemas) + + --%beforeall(create_ut3_user_tests, create_test_suite_in_ut3_user) + --%afterall(drop_test_suite_in_ut3_user, drop_ut3_user_tests) + + --%test(Runs the suites of each schema together, in order of schema names) + procedure run_groups_suites_by_schema; + + --%endcontext + + procedure create_test_suite_in_ut3_user; + procedure drop_test_suite_in_ut3_user; + --%context(run with tags) --%displayname(Call ut.run with #tags) From d4f53eb8d2261e418e7829ec9637860ac6663247 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 22:45:53 +0200 Subject: [PATCH 847/887] Raise invalid tag expression error for an unmatched right bracket --- source/core/ut_suite_tag_filter.pkb | 4 ++++ test/ut3_tester/core/test_ut_suite_tag_filter.pkb | 9 +++++++++ test/ut3_tester/core/test_ut_suite_tag_filter.pks | 4 ++++ 3 files changed, 17 insertions(+) diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index 76f68f467..4f0ebf754 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -138,6 +138,10 @@ create or replace noneditionable package body ut_suite_tag_filter is l_rnp_tokens.extend; l_rnp_tokens(l_rnp_tokens.last) := l_operator_stack.pop; end loop; + --no open bracket left on the stack: unmatched right bracket + if l_operator_stack.peek is null then + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); + end if; l_operator_stack.pop; --Pop the open bracket and discard it l_expect_operand := false; l_expect_operator:= true; diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index 7accab849..9b7951cb9 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -71,6 +71,15 @@ create or replace package body test_ut_suite_tag_filter is ut.fail('Expected exception but nothing was raised'); end; + procedure conversion_throws_when_unmatched_rb is + l_postfix ut3_develop.ut_varchar2_list; + l_input_token ut3_develop.ut_varchar2_list; + begin + l_input_token := ut3_develop.ut_varchar2_list('(','a',')',')'); + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(l_input_token); + ut.fail('Expected exception but nothing was raised'); + end; + procedure is_matching_or_and_not is begin ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test1', 'test1') ).to_equal(1); diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pks b/test/ut3_tester/core/test_ut_suite_tag_filter.pks index eb38d0a59..11d58de7e 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pks +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pks @@ -28,6 +28,10 @@ create or replace package test_ut_suite_tag_filter is --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) procedure conversion_throws_when_lb_rb; + --%test(Conversion raises exception when a right bracket has no left bracket) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure conversion_throws_when_unmatched_rb; + --%endcontext --%test( Evaluates or, and and not in tag expressions) From 1fe4357ed118d291433741a22da49c9a903d8b8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 23:09:31 +0200 Subject: [PATCH 848/887] Move reconcile_paths_and_suites to ut_suite_manager --- source/core/ut_suite_cache_manager.pkb | 34 --------------- source/core/ut_suite_cache_manager.pks | 9 ---- source/core/ut_suite_manager.pkb | 41 ++++++++++++++++++- source/core/ut_suite_manager.pks | 7 ++++ .../ut3_cbac_modify_objects_role_grants.sql | 6 ++- 5 files changed, 51 insertions(+), 46 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 3a99226b6..9733470dc 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -266,40 +266,6 @@ create or replace noneditionable package body ut_suite_cache_manager is ); end; - procedure reconcile_paths_and_suites( - a_schema_paths ut_path_items, - a_suite_rows ut_suite_cache_rows - ) is - begin - for i in ( - with - path_items as ( - select /*+ materialize */ rownum as path_id, sp.schema_name, sp.object_name, sp.procedure_name, sp.suite_path - from table(a_schema_paths) sp - ), - suite_items as ( - select r.object_owner, r.object_name, r.name, r.path - from table(a_suite_rows) r - ) - select /*+ no_parallel */ p.schema_name, p.object_name, p.procedure_name, p.suite_path - from path_items p - where not exists ( - select 1 - from (&&ut3_owner..ut_suite_cache_macros.match_paths(suite_items, path_items)) m - where m.path_id = p.path_id - ) - order by p.path_id - ) loop - if i.suite_path is not null then - raise_application_error(ut_utils.gc_suite_package_not_found,'No suite packages found for path '||i.schema_name||':'||i.suite_path|| '.'); - elsif i.procedure_name is not null then - raise_application_error(ut_utils.gc_suite_package_not_found,'Suite test '||i.schema_name||'.'||i.object_name|| '.'||i.procedure_name||' does not exist'); - elsif i.object_name is not null then - raise_application_error(ut_utils.gc_suite_package_not_found,'Suite package '||i.schema_name||'.'||i.object_name|| ' does not exist'); - end if; - end loop; - end; - function get_schema_parse_time(a_schema_name varchar2) return timestamp result_cache is l_cache_parse_time timestamp; begin diff --git a/source/core/ut_suite_cache_manager.pks b/source/core/ut_suite_cache_manager.pks index cc078625f..1ff9552cc 100644 --- a/source/core/ut_suite_cache_manager.pks +++ b/source/core/ut_suite_cache_manager.pks @@ -65,15 +65,6 @@ create or replace noneditionable package ut_suite_cache_manager authid current_u a_random_seed positive := null ) return ut_suite_cache_rows; - /* - * Raises ut_utils.gc_suite_package_not_found for the first path that selects none of the suite rows - * (as returned by get_suite_rows), with the same matching rules as get_suite_rows. - */ - procedure reconcile_paths_and_suites( - a_schema_paths ut_path_items, - a_suite_rows ut_suite_cache_rows - ); - /* * Retrieves information about the suite items matching the paths, as get_suite_rows does without tags. * Not to be used publicly. Used internally for ut_runner.get_suites_info. diff --git a/source/core/ut_suite_manager.pkb b/source/core/ut_suite_manager.pkb index aa059309c..3689d991e 100644 --- a/source/core/ut_suite_manager.pkb +++ b/source/core/ut_suite_manager.pkb @@ -277,6 +277,45 @@ create or replace noneditionable package body ut_suite_manager is return true; end; + /* + Raises ut_utils.gc_suite_package_not_found for the first path that selects none of the suite rows + (as returned by ut_suite_cache_manager.get_suite_rows), with the same matching rule: + the SQL macro ut_suite_cache_macros.match_paths. + */ + procedure reconcile_paths_and_suites( + a_schema_paths ut_path_items, + a_suite_rows ut_suite_cache_rows + ) is + begin + for i in ( + with + path_items as ( + select /*+ materialize */ rownum as path_id, sp.schema_name, sp.object_name, sp.procedure_name, sp.suite_path + from table(a_schema_paths) sp + ), + suite_items as ( + select r.object_owner, r.object_name, r.name, r.path + from table(a_suite_rows) r + ) + select /*+ no_parallel */ p.schema_name, p.object_name, p.procedure_name, p.suite_path + from path_items p + where not exists ( + select 1 + from (&&ut3_owner..ut_suite_cache_macros.match_paths(suite_items, path_items)) m + where m.path_id = p.path_id + ) + order by p.path_id + ) loop + if i.suite_path is not null then + raise_application_error(ut_utils.gc_suite_package_not_found,'No suite packages found for path '||i.schema_name||':'||i.suite_path|| '.'); + elsif i.procedure_name is not null then + raise_application_error(ut_utils.gc_suite_package_not_found,'Suite test '||i.schema_name||'.'||i.object_name|| '.'||i.procedure_name||' does not exist'); + elsif i.object_name is not null then + raise_application_error(ut_utils.gc_suite_package_not_found,'Suite package '||i.schema_name||'.'||i.object_name|| ' does not exist'); + end if; + end loop; + end; + function get_cached_suite_data( a_schema_paths ut_path_items, a_random_seed positive, @@ -287,7 +326,7 @@ create or replace noneditionable package body ut_suite_manager is l_suite_rows := ut_suite_cache_manager.get_suite_rows( a_schema_paths, can_skip_access_check(a_schema_paths), a_tags, a_random_seed ); - ut_suite_cache_manager.reconcile_paths_and_suites(a_schema_paths,l_suite_rows); + reconcile_paths_and_suites(a_schema_paths, l_suite_rows); return l_suite_rows; end; diff --git a/source/core/ut_suite_manager.pks b/source/core/ut_suite_manager.pks index f31c6ade7..b381ecc63 100644 --- a/source/core/ut_suite_manager.pks +++ b/source/core/ut_suite_manager.pks @@ -20,6 +20,13 @@ create or replace noneditionable package ut_suite_manager authid current_user is * Resposible for building hierarhy of sutes from individual suites created by suite_builder */ + /* + * The package runs with invoker rights. It calls the SQL macros of ut_suite_cache_macros in SQL statements + * through the code based access control role _cbac_modify_objects_role granted to the package, + * so the references to framework objects in those statements are qualified with the framework owner. + * The owner is filled in by the SQL*Plus substitution variable ut3_owner when the package body is installed by install.sql. + */ + /** * @private * diff --git a/source/ut3_cbac_modify_objects_role_grants.sql b/source/ut3_cbac_modify_objects_role_grants.sql index 063e29221..b8748c46a 100644 --- a/source/ut3_cbac_modify_objects_role_grants.sql +++ b/source/ut3_cbac_modify_objects_role_grants.sql @@ -14,9 +14,10 @@ See the License for the specific language governing permissions and limitations under the License. - Code based access control for the invoker rights packages ut_annotation_cache_manager, ut_annotation_manager and ut_suite_cache_manager. + Code based access control for the invoker rights packages ut_annotation_cache_manager, ut_annotation_manager, + ut_suite_cache_manager and ut_suite_manager. The packages access the annotation and suite cache tables through the role _cbac_modify_objects_role, - directly or through the SQL macros of ut_annotation_cache_macros, + directly or through the SQL macros of ut_annotation_cache_macros and ut_suite_cache_macros, so the users calling the framework do not need any privileges on those tables. The types and packages used in SQL statements of those packages are granted to the role too, so they do not need to be granted to the users calling the framework. @@ -57,4 +58,5 @@ grant execute on &&ut3_owner..ut_suite_cache_macros to &&ut3_owner._cbac_modify_ grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_cache_manager; grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_annotation_manager; grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_suite_cache_manager; +grant &&ut3_owner._cbac_modify_objects_role to package &&ut3_owner..ut_suite_manager; From b060c84c4732004a1f7de2bc3e08a071879d8585 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 23:09:31 +0200 Subject: [PATCH 849/887] Move contributor rules into CONTRIBUTING.md Add the engineering principles, the refactoring rules and the rules for code based access control and SQL macros to CONTRIBUTING.md, together with the local constant prefix, the license header and the version string conventions. Remove the suite cache refactoring plan, which is done. --- CONTRIBUTING.md | 53 ++ .../suite_cache_collection_patterns.md | 521 ------------------ 2 files changed, 53 insertions(+), 521 deletions(-) delete mode 100644 development/suite_cache_collection_patterns.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0c7de58c9..1b6f9abd1 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -31,11 +31,64 @@ Not able to contribute code? You can also support the project through [sponsorsh * Arguments to procedures and functions will start with `a_`, an Example would be procedure `is_valid(a_owner_name varchar2)` * Object types and packages will start with `ut_` * Local variables `l_` + * Local constants `c_` * Global variables `g_` * Global Constants start with `gc_` * Types in packages, objects start with `t_` * Nested Tables start with `tt_` * varchar2 lengths are set in characters not bytes +* Every source file carries the Apache license header. +* Don't edit version strings (`v3.x.x.xxxx`) in `source/`, `VERSION` or `BUILD_NO` by hand. CI rewrites them (`.github/scripts/update_project_version.sh`). + +# Engineering principles + +Every change (PL/SQL, SQL, install scripts, GitHub workflows, tooling) should follow these principles of Extreme Programming (XP): + +- **KISS – Keep It Simple, Stupid**: choose the simplest solution that works and is easy to read; no clever constructs where a plain one will do. +- **DRY – Don't Repeat Yourself**: every piece of knowledge has one authoritative place. Reuse existing packages, types and helpers (`ut_utils` first) instead of copying logic. In GitHub workflows, define a value once and reference it. +- **YAGNI – You Aren't Gonna Need It**: implement only what the task needs now. No speculative parameters, options, columns, abstractions or "future" code paths. + +Where they apply to PL/SQL and SQL, also follow the **SOLID** principles. Apply only the ones that fit; don't force them onto plain SQL scripts: + +- **S – Single Responsibility Principle**: a package, procedure or type has one cohesive purpose and one reason to change. Split packages that mix unrelated concerns; keep procedures short and focused. +- **O – Open/Closed Principle**: extend behavior without modifying working code, for example by adding a new reporter as a subtype of `ut_reporter_base`, or a new matcher as a subtype of `ut_matcher`, instead of adding another branch to a big `if`/`case`. +- **L – Liskov Substitution Principle**: object type subtypes (`under`) must be usable wherever their base type is expected, without changing the expected behavior of the base type's methods. +- **I – Interface Segregation Principle**: keep package specifications small and focused, so callers depend only on what they use. Expose a function in a package spec only if something needs it, and prefer a thin facade over a large catch-all package. +- **D – Dependency Inversion Principle**: depend on package specifications and abstract base types, not on implementation details (package bodies, concrete subtypes, table structures of other modules). Call other modules through their public spec. + +Every new functionality should be covered with tests, following the testing pyramid or the testing diamond. + +## Refactoring + +Before each refactoring step: +- **Check test coverage first.** Make sure existing tests cover the logic being refactored, including its edge cases and error paths. If they don't, add the missing tests and see them pass against the current code before changing it. +- **Find tests that the change would break.** Look for tests that call the procedures, functions or types being moved, merged or removed. Where you can, rewrite those tests to call a higher-level procedure or function that keeps its contract. The tests then check behaviour rather than internal structure, and still pass after the refactoring. + +# Code based access control and SQL macros + +Some framework packages run with invoker rights (`authid current_user`) and still read and change the framework's cache tables. +They do it through the code based access control (CBAC) role `_cbac_modify_objects_role`, which [ut3_cbac_modify_objects_role_grants.sql](source/ut3_cbac_modify_objects_role_grants.sql) grants to those packages. +Users calling the framework get no privileges on the tables. The rules below were verified on Oracle 19.20, 21 XE and 23 Free. + +## Packages with the CBAC role + +- **Grants:** a package that needs the role gets a `grant ... to package` line in the grants script. The objects its SQL uses (tables, types, other packages) are granted to the role in the same script. +- **Qualify framework objects:** in the SQL of these packages, qualify framework objects with the SQL*Plus substitution variable `&&ut3_owner.`, which `install.sql` sets. The code runs as the invoking user, so unqualified names would resolve in that user's schema. When you compile such a body by hand, run `define ut3_owner=ut3_develop` first. +- **Install order:** `install.sql` installs the package specs, then runs the grants script, then installs the bodies. A body that expands a SQL macro needs the role when it compiles; in the other order it fails with `ORA-62565` / `PLS-00201`. +- **Recreating a spec drops the grant:** `create or replace package` removes the package's CBAC role grant, while `create or replace package body` keeps it. After changing such a spec by hand, rerun the grants script as SYS, or run `development/refresh_ut3.sh`. + +## SQL macros + +- **Table macros only.** utPLSQL is compatible with Oracle 19c (RU 19.20) or later, so table macros are available everywhere it runs. +- **Separate definer rights package:** a macro doesn't compile in an invoker rights package (`PLS-00782`). Macros live in their own `authid definer` packages, such as `ut_annotation_cache_macros` and `ut_suite_cache_macros`. +- **Two grants needed for macro package:** one to the CBAC role in the grants script, and one to the framework users in [create_grants.sql](source/create_grants.sql). +- **Qualify framework objects in the macro text** with `&&ut3_owner.`. The text is expanded into the caller's statement, which runs with invoker rights. +- **Don't use argument values in the macro body.** The body sees an argument's value only when the caller passes a literal; binds and PL/SQL variables arrive as NULL. So the body can't branch on an argument or build SQL from it. Put conditions into the returned text instead, for example `(a_value is null or col > a_value)`. +- **No macro inside a `WITH` clause** (`ORA-64630`). Call the macro from the main query or one of its subqueries. A CTE can be passed as a table argument. +- **No collection columns in a table argument** (`ORA-62558`). Pass a CTE that selects only scalar columns. +- **No `all_objects` in a CTE of a statement that calls a macro.** The statement compiles but fails at run time with `ORA-00942`. Use `all_objects` in the main query instead. +- **Recompile with `alter package ... compile body`.** `dbms_utility.compile_schema` can't recompile a body that expands a macro in static SQL (`ORA-62565`). +- **Test on 19c, 21 XE and 23 Free.** The privilege checks for macros differ between versions. # Configuring local environment diff --git a/development/suite_cache_collection_patterns.md b/development/suite_cache_collection_patterns.md deleted file mode 100644 index 3bdb498f8..000000000 --- a/development/suite_cache_collection_patterns.md +++ /dev/null @@ -1,521 +0,0 @@ -# Suite cache: collection hand-off patterns - -How `ut_suite_cache_manager` and its callers move suite data between SQL statements through PL/SQL collections instead of joining tables directly, why that happens, and how to simplify it with the two tools now on the branch: code based access control (CBAC) and table SQL macros. - -Revised on 2026-11-09 for the CBAC + SQL macro strategy, against branch `feature/code_based_access_control` at commit `05ab7423`. Line references in the pattern catalogue point to that commit. - -**Status, 2026-11-10:** -- Steps 0 to 6 and findings 2 to 4 are done. -- The branch is pushed, with a PR open, so CI tests 19c, 21 XE and 23 Free. -- Each local commit was checked with a full test run on 19.20. -- Commits after the PR was opened are local and not pushed. -- Finding 5 is verified and reported; it is not fixed. -- Open question 1 is waiting for review. - -## Status at a glance - -| Pattern | What it is | Status | Approach | -|---|---|---|---| -| P1 | access filter applied to a collection by the caller | **done** | access predicate in `get_suite_items`, plain SQL in `ut_suite_cache_manager` (step 3) | -| P2 | chain of collection → collection functions | **done** | one statement with named CTEs: `get_suite_rows` (step 4) | -| P3 | logical suites appended to a collection | **done** | CTE of the main statement (step 4) | -| P4 | sort by self-join of a collection | **done** | recursive CTE of the main statement (step 4) | -| P5 | paths reconciled against a collection | **done** | `ut_suite_cache_manager.reconcile_paths_and_suites`, same matching rule as P7 | -| P6 | collection → ref cursor → collection | **done, partly** | collection passed, no cursor; rows still converted to records (ORA-00600) | -| P7 | two scans of `ut_suite_cache` for path matching | **done** | table SQL macro `ut_suite_cache_macros.match_paths` (step 5) | -| P8 | list handed between the two cache modules | **done** | table SQL macro `ut_annotation_cache_macros.get_cached_objects` | -| P9 | full rows loaded only to project scalars | **done** | `get_suites_info` on the same statement, rows without executables (step 6) | -| P10 | PL/SQL objects inserted through `table()` | keep | legitimate | -| P11 | short scalar lists joined in SQL | keep | legitimate | -| new | `get_cached_objects` branched on an argument's value | **done** | parameter removed (step 0) | - -## Strategy: what CBAC and SQL macros are for - -Until the CBAC commits, `ut_suite_cache_manager` and `ut_annotation_cache_manager` were `authid definer`. They could read the private cache tables, but `all_objects` inside them showed what the **framework owner** sees, not the **invoking user**. So the access checks ran in invoker-rights code (`ut_suite_manager`, `ut_annotation_manager`), which couldn't read the cache tables. The definer package selected cache rows into a collection, and the invoker package filtered that collection with `table(:coll)`. Most patterns below come from that split, or from code built around its output. - -| Package | Before CBAC | Now | -|---|---|---| -| `ut_suite_cache_manager` | `authid definer` | `authid current_user` + CBAC role | -| `ut_annotation_cache_manager` | `authid definer` | `authid current_user` + CBAC role | -| `ut_annotation_manager` | `authid current_user` | unchanged + CBAC role (for the macro) | -| `ut_annotation_cache_macros` | did not exist | `authid definer` (macros can't be in invoker-rights packages) | -| `ut_suite_manager` | `authid current_user` | unchanged, no role | -| `ut_suite_tag_filter` | `authid definer` | unchanged, touches no tables | - -The two tools solve different problems: - -- **CBAC removes the reason for the split.** A cache manager now runs as the invoker and still reads its own tables. So one SQL statement inside it can join `ut_suite_cache` with `all_objects` as the invoking user sees it. **Within the module that owns the tables, use plain SQL.** It is compile-checked, needs no extra grants, and the optimizer sees real tables. -- **A table SQL macro is a cache module's read API for SQL owned by another module.** Use one only when a statement that belongs to another package must read the cache tables in the same statement. On the branch that is two places, both reading the annotation cache: - - the `delete` in `ut_suite_cache_manager.remove_missing_objs_from_cache`; - - the dynamic SQL in `ut_annotation_manager`, which joins the cache with `all_objects` / `dba_objects`. - - A macro costs: - - a definer-rights package; - - EXECUTE grants to the role and to the framework users; - - the CBAC role on every caller; - - the specs → grants → bodies install order. - - Add one only when such a cross-module read is needed (YAGNI). - -**What this means for the suite read path.** Every cache read in Flows A and B already sits in `ut_suite_cache_manager`, so P1–P7 and P9 need no new macro. Only CBAC is needed, and it is already in place. `ut_suite_manager` keeps no role and names no cache table. - -Rejected alternative: a `ut_suite_cache_macros` package that `ut_suite_manager` composes into its own statement. It would spread the role to `ut_suite_manager` and move knowledge of the cache's structure out of the module that owns it. It would also add a third macro grant, for no gain over a statement inside `ut_suite_cache_manager`. - -## Rules for SQL macros (verified) - -Consolidated from the checks on 19.20 EE, 21.3 XE and 23ai Free (2026-11-09). - -1. **Table macros only.** The project requires 19c RU 19.20 or later. Table macros exist from 19.7, so they are available everywhere the framework runs. Scalar macros are not used. -2. **A macro can't live in an invoker-rights package.** Compiling one there fails with `PLS-00782`. Put macros in a separate `authid definer` package, such as `ut_annotation_cache_macros`. -3. **Callers need the CBAC role at compile time and at run time.** The macro is executed while the calling body compiles. `install.sql` therefore installs the specs, then runs [ut3_cbac_modify_objects_role_grants.sql](../source/ut3_cbac_modify_objects_role_grants.sql), then installs the bodies. With the old order, the bodies failed with `ORA-62565` / `PLS-00201`. The exact compile-time rule Oracle applies is an inference: one manual SYS compile succeeded without the role. The install order is the verified fix. -4. **Users need EXECUTE on the macro package.** On 21c XE, expanding a macro checks the calling user's own EXECUTE privilege. Without it the call fails with `ORA-62565` / `PLS-00904`. The role held by the calling package doesn't count there; on 19.20 and 23ai it was enough. - - [create_grants.sql](../source/create_grants.sql) therefore grants `execute on ut_annotation_cache_macros`. - - The grant exposes no data. A user with it still gets `ORA-01031` from the macro and from the table directly. - - Every new macro package needs this grant, in addition to the role grant. -5. **The macro body sees an argument's value only when it is a literal.** For a PL/SQL variable or a bind variable, the body sees NULL; the value is bound only into the returned SQL text. Verified on 19.20 with a probe macro: - - | Call | Value seen in the macro body | - |---|---| - | literal `timestamp '2026-01-01 00:00:00'` | the value | - | PL/SQL variable in static SQL | NULL | - | bind in `execute immediate ... using` | NULL | - - So the body must not branch on argument values. Conditions go into the returned SQL text, for example `(a_x is null or col > a_x)`. This also matters for cursor sharing: the text is built once per call site, at hard parse. -6. **Collections can be arguments.** `from macro(sys.odcivarchar2list('a','b','c'))`, with `table(a_list)` in the macro text, returned 3 rows on 19.20. Not checked with framework types such as `ut_path_items`. The suite plan below doesn't need it. -7. **Qualify framework objects in the macro text** with `&&ut3_owner.`. The text is expanded into the caller's statement, and the caller is invoker rights. -8. **SYS can't call the macro directly.** It fails with `ORA-06598: insufficient INHERIT PRIVILEGES privilege`. This doesn't affect normal use. -9. **Recreating a package spec drops its CBAC role grant.** Seen on 19.20, 2026-11-09: - - `create or replace package ut_suite_cache_manager` removed the package from `dba_code_role_privs`. Its SQL then failed with `ORA-00942`. - - `create or replace package body` keeps the grant. - - After changing the spec of a package with the role by hand, rerun [ut3_cbac_modify_objects_role_grants.sql](../source/ut3_cbac_modify_objects_role_grants.sql), or use `development/refresh_ut3.sh`. -10. **A SQL macro can't build SQL from a variable's value.** Tested on 19.20, 2026-11-10, for the tag filter in `get_suite_rows`: - - The setup: a table macro `filter_by(a_rows dbms_tf.table_t, a_filter varchar2)` returning `'select * from a_rows where ' || a_filter`. - - A CTE name is accepted as the `TABLE_T` argument. - - The macro body received `a_filter` as NULL whether it was passed as a literal, a PL/SQL variable or a function call, so the condition was never added. - - A macro is therefore no way to run a predicate computed at run time in static SQL. -11. **Serially reusable packages can't be called from SQL.** `pragma serially_reusable` makes any call during a SQL statement fail with `ORA-06534` (19.20, 2026-11-10). So `ut_suite_tag_filter`, whose `is_matching` runs inside `get_suite_rows`, keeps normal package state for its cache. - -12. **`dbms_utility.compile_schema` can't recompile a body that expands a macro in static SQL.** Seen on 19.20, 2026-11-10: - - Changing the spec of `ut_suite_tag_filter` invalidated the `ut_suite_cache_manager` body. - - `compile_schema`, run as SYS or as `UT3_DEVELOP`, left that body invalid: `ORA-62565` / `PLS-00201: identifier 'UT_ANNOTATION_CACHE_MACROS.GET_CACHED_OBJECTS' must be declared`. - - `alter package ut_suite_cache_manager compile body` (as SYS or `UT3_DEVELOP`) compiled it. - - So recompile such bodies with `alter package ... compile body`. -13. **Restrictions on table SQL macros with `dbms_tf.table_t` arguments.** Seen on 19.20, 2026-11-10, in step 5: - - **No macro inside a `WITH` clause:** `ORA-64630: use of SQL macro inside WITH clause is not supported`. CTEs can be macro arguments, and the macro can be called from the main query or a subquery of it. - - **No collection columns in a table argument:** `ORA-62558: Unsupported data types (TABLE) for polymorphic table function`. Pass a CTE with the scalar columns only. - - **No `all_objects` in a CTE of the statement:** with `all_objects` (or `sys.all_objects`) in any CTE of a statement that calls the macro, the statement compiles but fails at run time with `ORA-00942`. That happened even for the owner, and in a definer-rights package. The same predicate in the main query's `where` works. - -#### Other statement-level findings (step 4, 19.20, 2026-11-10) - -- **No `xmltable` row generator next to a recursive CTE.** - - The logical-suite CTEs used `xmltable('1 to 20')` to generate level numbers. Together with the recursive sort CTE in the same statement, its hard parse never finished: `latch: shared pool`, killed after more than 5 minutes. - - A cut-down variant crashed the server process with `ORA-07445 [qmxtrProcCorrOpn]`, in the XML query rewrite. - - `select level from dual connect by level <= 20` parses in 0.3 s. - - Killed sessions stayed stuck in the parse and held a library cache pin on the package; only a database restart cleared them. -- **Make the sibling order explicit.** - - `search depth first by line_no desc, ...` leaves siblings with equal `line_no` (packages without a suitepath, logical suites) in input order. - - The old code's input was sorted by path, as a side effect of `row_number() over (partition by path, ...)`, and tests depend on that order (`test_annotation_cache`). - - The search clause now ends with `path, object_owner`. - -## New finding: `get_cached_objects` branches on an argument's value - -Commit `05ab7423` changed [ut_annotation_cache_macros.pkb:19](../source/core/annotations/ut_annotation_cache_macros.pkb:19) from the predicate `(i.parse_time > a_parsed_after or a_parsed_after is null)` to adding `and i.parse_time > a_parsed_after` only when `a_parsed_after is not null`. By rule 5, the effect depends on the caller: - -- `remove_missing_objs_from_cache` passes the literal `null`. There is no filter, which is correct. -- `ut_annotation_manager.get_objects_to_refresh` passes the bind `:a_parsed_after`. The body sees NULL, so **the filter is never added**, even when `a_modified_after` has a value. - -The results don't change. The outer query keeps a row when `o.last_ddl_time >= a_modified_after` and not `o.last_ddl_time < c.parse_time`. A cache row with `parse_time <= a_modified_after` can't fail the second test for an object that passes the first. With or without the filter, the same objects come back. Only the `parse_time` attribute of the returned list differs: it is now filled where the filter used to leave it null. No caller reads that attribute: `reset_objects_cache` and `get_sources_to_annotate` use only the names and `needs_refresh`. So the filter only trims the join input, and the commit's performance intent is not reached. - -Resolved in step 0: `a_parsed_after` is removed from the macro, which keeps today's behaviour and simplifies the code. If a measurement later shows that the filter helps, restore it in the bind-safe form `(a_parsed_after is null or i.parse_time > a_parsed_after)`, which works for binds and literals. Rule 5 is now in the spec comment of `ut_annotation_cache_macros`. - -## Data types involved - -| Type | Shape | Notes | -|---|---|---| -| `ut_path_items` / `ut_path_item` | `schema_name, object_name, procedure_name, suite_path` | parsed run paths | -| `ut_suite_cache_rows` / `ut_suite_cache_row` | 22 attributes, the row type of table `ut_suite_cache` | **heavy**: 6 × `ut_executables`, 3 × `ut_varchar2_rows`, 1 × `ut_executable_test` | -| `ut_suite_items_info` | 10 scalars + `tags` | public output of `get_suites_info` | -| `ut_suite_items` | PL/SQL object tree (`ut_suite`, `ut_test`, ...) | built by `ut_suite_builder`, written by `save_object_cache` | -| `ut_annotation_objs_cache_info` | owner, name, type, `needs_refresh`, `parse_time` | lists of objects to refresh or remove | - -Every `select value(c) ... bulk collect into ... from table(:coll) c` deep-copies each `ut_suite_cache_row`, nested tables included. Steps that only filter or reorder rows still copy all of their data. - -## Flows - -The flows below show the code after steps 0 to 6. Before the refactoring, Flow A read the cache twice, through `expand_paths` and `get_suite_items`. It then copied the rows 4 to 6 times, through 5 SQL statements over `table()` collections, before building the object tree. Flow B loaded full rows only to project them to 10 columns. - -### Flow A: run (`ut_runner.run` → `ut_suite_manager.configure_execution_by_path`) - -``` -a_paths (ut_varchar2_list) - │ refresh_cache_for_paths ut_suite_manager - │ resolve_schema_names PL/SQL, normalises paths - │ refresh_cache per schema see Flow C - │ get_schema_paths PL/SQL: splits paths into ut_path_items (wildcards kept) ut_suite_cache_manager - ▼ - get_cached_suite_data ut_suite_manager - │ can_skip_access_check(paths) owner of every schema, or EXECUTE ANY PROCEDURE - │ get_suite_rows ut_suite_cache_manager - │ get_matched_ids SQL: ut_suite_cache, match_paths macro, all_objects → ids (selected rows and parents) - │ select_suite_rows SQL: tags (is_matching), logical suites, recursive sort → ut_suite_cache_rows - │ reconcile_paths_and_suites SQL: paths × final rows with match_paths → raise errors ut_suite_cache_manager - ▼ - reconstruct_from_cache select * bulk collect into records → object tree (ORA-00600 workaround, P6) -``` - -Three SQL statements read the cache (one scan for the paths, one for the rows by id), and the rows are copied once into records. - -### Flow B: suite info (`ut_runner.get_suites_info`) - -``` -a_paths → refresh_cache_for_paths → can_skip_access_check(paths) ut_suite_manager - │ ut_suite_cache_manager.get_suites_info - │ select_suite_rows without executables (no tags, no seed) → light ut_suite_cache_rows - │ get_suite_items_info SQL projection → ut_suite_items_info - ▼ - open cursor select value(c) from table(info) order by owner, name, line_no -``` - -### Flow C: cache refresh (`ut_suite_manager.refresh_cache`) - -``` -get_schema_parse_time(owner) scalar -ut_annotation_manager.get_annotated_objects(...) sys_refcursor of ut_annotated_object -build_and_cache_suites - │ fetch limit 10 → ut_annotated_objects - │ per object: ut_suite_builder.create_suite_item_list → ut_suite_items (PL/SQL) - │ per object: save_object_cache(ut_suite_items) - │ autonomous tx: 2 × insert ... select from table(a_suite_items) with treat() -remove_missing_objs_from_cache(owner) one delete, with the get_cached_objects macro (P8) -``` - -### Flow D: smaller lookups - -- `get_schema_ut_packages` → `get_cached_packages(ut_varchar2_rows)`: joins a short list of schema names with `ut_suite_cache_package` (P11). -- `suite_item_exists`: a scalar lookup in the cache manager, plus a separate `all_objects` check in [suite_manager:612](../source/core/ut_suite_manager.pkb:612). After step 3, the access predicate can move into the cache manager's query here too. Optional. - -### The annotation flow (out of scope, checked) - -After P8, `ut_annotation_manager` still passes `ut_annotation_objs_cache_info` lists: - -- `get_non_existing_objects` → `remove_from_cache`; -- `get_objects_to_refresh` → `reset_objects_cache` and `get_sources_to_annotate`. - -These are legitimate: - -- The first list holds only dropped objects, so it is short. -- The second is used three times (count, reset, source query), so one materialisation is the cheaper form. - -No change is planned. - -## Pattern catalogue - -### P1: select into a collection, filter by access in the caller - -- **Where:** `get_suite_items` / `get_cached_suite_rows` (cache manager) → `get_filtered_cursor` ([ut_suite_manager.pkb:299](../source/core/ut_suite_manager.pkb:299)). -- **What:** cache rows are returned unfiltered ("Returned data is not filtered by user access rights" in the spec). The caller filters the collection against `all_objects`. -- **Why it exists:** the definer/invoker split. CBAC removed it. -- **Cost:** - - A full copy of the result set, plus a union of two scans of the same collection. - - Logical suites are exempted (`or c.self_type = 'UT_LOGICAL_SUITE'`) because they are generated before the filter runs. **Verify:** this can leave logical suites with no accessible children in the tree. -- **Name:** `get_filtered_cursor` is misleading: it returns a collection, not a cursor. -- **Approach:** put the access predicate into the `ut_suite_cache` query inside `ut_suite_cache_manager`. That is plain SQL; no macro is needed. The EXECUTE ANY / `a_skip_all_objects` decision comes in as a bind flag in the SQL text (rule 5 doesn't apply here, but the same style keeps one cursor): - ```sql - where ( :skip_access_check = 'Y' - or exists (select 1 from all_objects a - where a.owner = c.object_owner and a.object_name = c.object_name - and a.object_type = 'PACKAGE') ) - ``` - Logical suites are then generated from accessible suites only, and the exemption goes away. -- **Done in step 3.** `get_suite_items` and `get_cached_suite_info` take `a_skip_access_check`, and `get_filtered_cursor` is gone. `ut_suite_manager.skip_access_check` computes the flag: EXECUTE ANY PROCEDURE or `a_skip_all_objects`. Tags are now applied to accessible rows only, and logical suites are generated from those. - -#### Behaviour for users with partial access (open question 2, answered) - -The setup: `probe_user` has EXECUTE on `child_suite`, but not on `parent_suite`, its parent suite, nor on `lone_suite` (suitepath `logical.sub`). Measured on 19.20 on 2026-11-09, before and after step 3: - -| Case | Before step 3 | After step 3 | -|---|---|---| -| `get_suites_info` | listed logical suites `logical` and `logical.sub` with nothing accessible below them, and `parent_suite.child_suite` without a parent | no empty logical suites; `child_suite` under a generated logical suite `parent_suite` | -| run `probe_owner.child_suite` | **0 tests, silently**: the accessible test was lost, because its parent suite was removed after the tree's logical suites were generated | runs `child_test` | -| run `:parent_suite` | error "No suite packages found" | runs `child_test` | -| run the whole schema | the accessible `child_test` was not run; empty `logical`/`sub` suites were printed | runs all accessible tests | -| run `:logical` (nothing accessible below it) | empty run, 0 tests, no error | error "No suite packages found for path …", the same as for a path with no packages at all | -| tag on the inaccessible parent only | 0 tests | 0 tests: tags of an inaccessible parent are not inherited | - -The new behaviour was accepted on 2026-11-09. It is covered by the context "Suites spread across packages, user without elevated privileges" in `test_annotation_cache`. Its 4 tests fail on the code before step 3 and pass after it. - -Reviewed again on 2026-11-10 (option D of four: drop the child, run it without the parent, skip it, or run it with a warning). The child still runs, and the logical suite that takes the place of the inaccessible parent now carries a run warning naming that parent: its beforeall/afterall, rollback setting and tags don't apply. `select_suite_rows` finds the parent by joining the logical suites back to `ut_suite_cache`. Documented in the user guide ("Running tests owned by other users"); tested by `user_warned_about_hidden_parent` and `user_runs_child_without_parent_tags`. - -### P2: chain of collection-to-collection transforms - -- **Where:** Flow A, copies #1 → #5. Each step is a function `f(ut_suite_cache_rows) return ut_suite_cache_rows` with one `select ... from table(:coll)`. -- **Cost:** - - Repeated deep copies of heavy objects. - - No predicate pushing across steps. - - Unknown `table()` cardinality: only two statements carry a fixed `cardinality(c 500)` hint. - - `value(c)` is moved around instead of columns. -- **Approach:** one static statement in `ut_suite_cache_manager`, with each step as a named CTE. `ut_suite_tag_filter.is_matching` evaluates the tag expression per test. -- **Done in step 4:** `ut_suite_cache_manager.get_suite_rows(a_schema_paths, a_skip_access_check, a_tags, a_random_seed)`. - - **CTEs:** `matched_rows` (paths and access, columns only) → `propagate_tags_from_ancestors` (tests only) → `filter_by_tags` → `tagged_rows` (all matched rows when no tags are given) → `suitepaths` / `suitepath_part` / `logical_suites` → `all_items` → `items_for_sort` → `ordered` (recursive). - - **Static SQL.** The first version was dynamic SQL, because the tag expression was compiled into a SQL predicate and concatenated into the statement. Now it is static: `ut_suite_tag_filter.is_matching(tags, tag_expression)` returns 1 or 0 per test. - - `is_matching` takes the condition from `create_where_filter` and evaluates it in an anonymous PL/SQL block on a collection named `tags`. PL/SQL supports the same `member of`, `is empty` and `is null` conditions. - - Both functions are `deterministic`. That caches only calls from SQL, so `create_where_filter` also keeps the last expression and its condition in package variables. Repeated calls from `is_matching` then skip parsing the expression. - - **Tags are passed as text, not as a collection.** Oracle caches a `deterministic` function called from SQL only when every argument is a scalar. Measured on 19.20: with 1000 rows and 3 distinct values, the function ran 3 times with scalar arguments and 1000 times with a nested-table argument, whether built by a constructor, read from a column, or built by `cast(collect())`, even inside a scalar subquery. - - `propagate_tags_from_ancestors` therefore builds `listagg(distinct tag, ',') within group (order by tag)`, and `is_matching(a_tags varchar2, ...)` splits it back with `ut_utils.string_to_table`. Tags can't contain commas, because `--%tags` splits on them. `is_matching` then runs once per distinct set of tags. - - The test `is_matching_is_cached_in_sql` checks this. It counts how often the anonymous block inside `is_matching` runs (via `v$sqlarea`, through `ut3_tester_helper.main_helper.get_sql_executions`) while 1000 rows with 3 distinct tag sets are filtered. Compiled without `deterministic`, the block ran 1000 times and the test failed; with it, the test passes. - - An invalid tag expression raises `gc_invalid_tag_expression` from `is_matching`, so only when a test is evaluated. On a path without tests, the run reports "not found" instead. - - `create_where_filter` is private to `ut_suite_tag_filter`. Its tests now check `is_matching` results instead of the generated condition text. - - `ut_suite_tag_filter` is granted to the CBAC role, because `is_matching` is called from SQL in an invoker-rights package. - - **Final select:** reads the full rows of real items by `id` and builds the logical suites. It returns `ut_suite_cache_rows`, because `reconcile_paths_and_suites` (P5) joins a collection; `reconstruct_from_cache` converts that to records (P6). - - **Path matching:** `exists` against the paths replaces the join plus `row_number` deduplication. `(object_owner, path)` is unique in `ut_suite_cache`. - - **Removed:** `get_suite_items`, `get_cached_suite_rows` (and cursor `c_get_bulk_cache_suite`), `sort_and_randomize_tests`, `get_cached_suite_info`, and `ut_suite_tag_filter.apply` / `get_tags_suites`. - - **Both flows** call `get_suite_rows`; the suite-info flow passes no tags and no seed. - -### P3: enrich a collection with generated rows - -- **Where:** cursor `c_get_bulk_cache_suite` ([ut_suite_cache_manager.pkb:22](../source/core/ut_suite_cache_manager.pkb:22)), used by `get_cached_suite_rows`. -- **What:** logical suites (path prefixes with no package behind them) are derived from the selected suites and appended with `union all`, through a full object constructor with null-cast executables. -- **Notes:** - - Path depth is capped by `xmltable('1 to 20')`. **Verify** what happens beyond 20 levels: logical parents above level 20 would be missing. - - Levels are counted with `regexp_count(path, '\w+')`, which does not count `$` and `#`, both allowed in path parts. -- **Approach:** a CTE of the main statement, placed after the access and tag filters. **Done in step 4.** The level generator is now `connect by level <= 20` instead of `xmltable` (see "Other statement-level findings"). The 20-level limit and the `\w+` counting are unchanged. - -### P4: in/out collection reorder with a self-join - -- **Where:** `sort_and_randomize_tests` ([ut_suite_cache_manager.pkb:214](../source/core/ut_suite_cache_manager.pkb:214)). -- **What:** a recursive CTE walks the hierarchy over `table(a_suite_rows)`, then joins back to `table(a_suite_rows)` to recover the objects. The result is copied and assigned back to the in/out parameter. -- **Cost:** two scans of the collection plus one copy. `ut_utils.hash_suite_path` is called from SQL for each row (`ut_utils` is granted to the role). -- **Approach:** the last CTE of the main statement, with `order by order1 desc` as the final `order by`. **Done in step 4**, with `path, object_owner` added as the last sort keys (see "Other statement-level findings"). - -### P5: validate by joining two collections - -- **Where (before step 5):** `reconcile_paths_and_suites` in `ut_suite_manager`. -- **What:** expanded paths are left-joined to the final rows to find paths that matched nothing. The first one raises an error. -- **Done in step 5:** `ut_suite_cache_manager.reconcile_paths_and_suites(a_schema_paths, a_suite_rows)` checks the raw paths, wildcards included, against the final rows with `ut_suite_cache_macros.match_paths`, the same rule `get_suite_rows` uses. The error messages are unchanged. -- **Note:** this runs **after** the tag and access filters. As the code reads, a package path whose tests are all excluded by tags raises "Suite package ... does not exist". **Verify** whether this is intended and covered by tests (open question 1). Any reordering must keep this behaviour. -- **Approach:** keep it as one small check over the single final collection. It is cheap once P2 is done. - -### P6: collection → ref cursor → collection - -- **Where:** `get_cached_suite_data` opens `select * from table(l_filtered_rows)` ([ut_suite_manager.pkb:371](../source/core/ut_suite_manager.pkb:371)). `reconstruct_from_cache` fetches it back in batches of 1000. -- **What:** a fully materialised collection is wrapped in a cursor and unwrapped again. `limit 1000` saves no memory. -- **Done in step 2, partly.** - - `get_cached_suite_data` returns the collection. - - `reconstruct_from_cache` takes it and converts it to records with one `select * bulk collect into` from `table()`. - - The ref cursor type `t_cached_suites_cursor` and the `limit 1000` batch loop are gone. -- **Why the record conversion stays:** building the `ut_test` objects straight from the `ut_suite_cache_row` objects makes nested runs fail on 19.20. See [Records, not objects, for building the tree](#records-not-objects-for-building-the-tree). So the copy from the collection into `tt_cached_suites` records remains, and so do `c_cached_suites_cursor` and `tt_cached_suites`. - -#### Records, not objects, for building the tree - -Found in step 2, on 19.20 EE, 2026-11-09: - -- **Symptom:** `reconstruct_from_cache` read the rows straight from the `ut_suite_cache_rows` collection, and `get_logical_suite` built `ut_test(item => .item, ...)` from `ut_suite_cache_row` objects. A nested run then failed with `ORA-00600: [pfrobj.c: invalid RTTI for Object]`. - - The run was `test_ut_test.application_info_on_execution`, which calls `ut3_develop.ut.run`. - - The error was raised in `UT3_DEVELOP.UT_EXECUTABLE.DO_EXECUTE` line 49, the call on the test's `item` (`ut_executable_test`, `authid current_user`). The location comes from the incident trace's PL/SQL call stack. - - It reproduced every time, and killed the whole test run. -- **Variants that still failed:** - - the rows assigned to a local variable before the call; - - `pragma inline` removed; - - each row copied into a local `ut_suite_cache_row` variable; - - the collection kept in a package variable, so it is never freed; - - an extra `select value(c) bulk collect` round trip in `ut_suite_manager`, which has no CBAC role. -- **Variant that worked:** the same rows, converted with `select * bulk collect into` a collection of `c_cached_suites_cursor%rowtype` records. With that, `test_ut_test` (27 tests) and the full run (1136 tests) passed. -- **Rule for later steps:** build the suite tree from records whose columns SQL filled, not from attributes of `ut_suite_cache_row` objects. The cause looks like an Oracle defect; it was not narrowed down further. - -### P7: two passes over `ut_suite_cache` for path resolution - -- **Where:** `expand_paths` ([ut_suite_cache_manager.pkb:109](../source/core/ut_suite_cache_manager.pkb:109)) and `get_suite_items` ([ut_suite_cache_manager.pkb:180](../source/core/ut_suite_cache_manager.pkb:180)). -- **What:** `expand_paths` resolves wildcards into concrete paths (4 CTEs, `union all`, `row_number` dedup), back into a collection. `get_suite_items` then joins that with `ut_suite_cache` again, with similar `like`/`nvl` matching and another dedup. -- **Cost:** two scans, and three places that encode "how a path matches a cache row" (`expand_paths`, `get_suite_items`, `reconcile_paths_and_suites`), each slightly differently. This is the hardest part of the code to reason about. -- **Note:** the `where` clause of `get_suite_items` mixes `and`/`or` without full parentheses. It works because `null || '.%'` can't match a real path, not because of the structure. -- **Approach:** one "path → matching cache rows" CTE in the main statement, with one definition of the matching rules. `group_paths_by_schema` stays a PL/SQL parser, and its `ut_path_items` stays a bind (P11). `reconcile` uses the same CTE (paths with no match). -- **Done in step 5.** - - `expand_paths` is gone, and `get_schema_paths` only splits paths into schema, package, procedure and suitepath; it no longer reads the cache. - - **One rule:** the table SQL macro `ut_suite_cache_macros.match_paths(a_items, a_paths)` is the only definition of which items a path selects: - - a schema: all its items; - - a package or `package.*`: the package's items; - - `package.procedure`: the items with that name; - - `:suitepath`: that item and everything below it; - - `:suite*path`: items whose path starts with a match of the pattern. - - **Two users of the rule:** `get_suite_rows`, through the new private `get_matched_ids`, and `reconcile_paths_and_suites`. - - **`get_matched_ids`** is a separate statement, because a macro cannot be used inside a `WITH` clause (rule 13). It returns the ids of the selected rows and their parents. The statement of `get_suite_rows` then starts from those ids. - - **The access check comes before parents are added.** A wildcard selects only packages the user can access, and only accessible parents are added. - - **Behaviour changes:** - - **Wildcards for users with partial access work.** Before, `owner.*_suite`, `owner.*_suite.*_test` or `owner:parent*` raised "does not exist" as soon as the wildcard also matched a package the user can't access, or one dropped but still in the cache. `expand_paths` didn't check access and returned one path per match. - - **`_` in package and procedure names is no longer a `LIKE` wildcard.** - - **`.` and `$` in suitepath patterns are literal.** - - **A suitepath without `*` is compared exactly**, not with `LIKE`. - - **New macro package:** `ut_suite_cache_macros` is definer rights (rule 2). It is in `install.sql` and `uninstall_objects.sql`, and is granted to the CBAC role and, in `create_grants.sql`, to the framework users (rule 4). `ut_integer_list` is also granted to the role. - - **Tests:** - - before the change (commit `a7ba8c8a`): overlapping paths in one call; - - with it: four tests in `test_annotation_cache` for wildcards run by a user with partial access. They fail on the code before step 5. - - The path wildcard tests of `test_suite_manager` (`-- %test`) were already active: the parser accepts `-- %`. - -### P8: list handed over between two cache modules (done) - -- **Before:** `ut_annotation_cache_manager.get_cached_objects_list` returned a collection. The not-cached package names went into a second collection, which drove two `delete ... in (table())`. -- **Now:** one `delete` from `ut_suite_cache_package` ([ut_suite_cache_manager.pkb:389](../source/core/ut_suite_cache_manager.pkb:389)). It reads the annotation cache through `ut_annotation_cache_macros.get_cached_objects` and relies on the `on delete cascade` FK for `ut_suite_cache`. `get_missing_cache_objects` and `get_cached_objects_list` are gone. -- **Follow-up, also done:** `ut_annotation_manager.get_non_existing_objects` and `get_objects_to_refresh` select from the same macro in their dynamic SQL, joined directly with `all_objects` / `dba_objects`. No collection is bound, and the `cardinality` hints are gone. `ut_annotation_cache_info` became an index-organised table keyed by `(object_owner, object_type, object_name)` (commit `4d6be442`), which matches the macro's predicate. -- **Step 0, done:** the macro takes only `(a_object_owner, a_object_type)`; the `a_parsed_after` branch is gone (see the new finding). - -### P9: full rows loaded only to project scalars - -- **Where:** Flow B: `get_cached_suite_info` → `get_filtered_cursor` → `get_suite_items_info`. -- **What:** `ut_suite_cache_row` objects, with all executable lists, are built and copied only to produce `ut_suite_item_info`. -- **Approach:** after P1/P2/P7, Flow B runs the same statement text as Flow A, without tags or randomisation. It differs only in the final select (`ut_suite_item_info(...)`, ordered by owner, name and line). The statement is built in one private function, and the two flows add their own final select (DRY). `get_cached_suite_info` and `get_suite_items_info` then leave the spec (Interface Segregation). -- **Done in step 6.** - - The statement is the private `select_suite_rows(..., a_with_executables)`. `get_suite_rows` calls it with the executables. The new public `get_suites_info(a_schema_paths, a_skip_access_check)` calls it without them: real rows are then built from scalar columns and tags, without `value(c)` and the executable lists. - - `get_suite_items_info` (the projection to `ut_suite_item_info`) is private. `ut_suite_manager.get_suites_info` calls `ut_suite_cache_manager.get_suites_info` and only adds the ordering. - - **Tests first** (commit `a373b85b`): `get_suites_info` for a package with a context and a disabled test, and for a procedure path. The existing tests already covered packages without and with tags, and suitepaths. - - **Measured on 19.20, whole schemas, 5 runs each after one warm-up run:** - - | Call | Before (ms) | After (ms) | - |---|---|---| - | `get_suites_info` UT3_TESTER (470 items) | 300–320 | 250 | - | `get_suites_info` UT3_USER (818 items) | 780–990 | 700–740 | - | `configure_execution_by_path` UT3_TESTER | 490–500 | 450–480 | - | `configure_execution_by_path` UT3_USER | 1150–1320 | 1060–1080 | - -### P10: PL/SQL-built objects written through `table()` (legitimate) - -- **Where:** `save_object_cache` ([ut_suite_cache_manager.pkb:279](../source/core/ut_suite_cache_manager.pkb:279)). -- `ut_suite_builder` builds object trees in PL/SQL, and inserting them through `table(a_suite_items)` with `treat()` is the natural way to persist them. **Keep it.** -- Optional: the two `insert ... select` statements (suites and contexts, then tests) could become one, at some cost to readability. -- The `delete` before the inserts must stay. The package row is updated, not re-created, so the FK cascade doesn't fire there. - -### P11: short scalar lists joined in SQL (legitimate) - -`get_cached_packages(table(a_schema_names))` and the path list are small lists of user input, joined in SQL. **Keep them.** - -## Smaller findings seen along the way - -1. **Rollback type is set twice. Fixed in step 2:** only `reconstruct_from_cache` sets it now. That covers `configure_execution_by_path` and `build_suites_from_annotations`. -2. **Duplicated prologue. Fixed in step 6:** `configure_execution_by_path` and `get_suites_info` both call the private `refresh_cache_for_paths`. -3. **Two near-identical checks. Fixed:** - - `can_skip_all_objects_scan` and `skip_access_check` are replaced by `can_skip_access_check`, in two forms: for one owner, and for a list of paths, where every path's schema must pass. The rule: the user is the owner, or has EXECUTE ANY PROCEDURE. - - `build_suites_from_annotations` loses `a_skip_all_objects`, which only `test_suite_builder` used. Its tests run as the owner, so the access check is skipped as before. - - Owners running their own schema skip the `all_objects` lookup again, as before step 3. - - `test_suite_builder` took 1.24 s (before: 1.50 s); the flows took the same time or less. -4. **`get_logical_suite` repeated constructor calls. Fixed:** it chooses `items` first and has one constructor call per type (4 instead of 7). Measured on 19.20: `configure_execution_by_path` on a whole schema took 420–460 ms (before: 450–480) for UT3_TESTER and 1030–1050 ms (before: 1060–1080) for UT3_USER. -5. **Partial items cached on a too long path. Verified on 19.20, 2026-11-10; not fixed.** - - **The code:** in `build_and_cache_suites`, when `create_suite_item_list` raises `ex_string_too_small` (a path over 1000 characters), `save_object_cache` still runs with `l_suite_items`. - - **No stale items from the previous package:** Oracle resets the `out nocopy` collection when the procedure is called. - - Probed with a package whose suitepath has 1199 characters, between two valid packages. - - The error happens in `build_suitepath` before any item is added, so nothing is cached for that package. - - **Partial items are cached when the error comes later:** - - Probed with a package whose suitepath fits (983 characters with the package name), with a context `c` and a test inside it, and a top-level test whose path has 1004 characters. - - The context and its test were cached, without the package's suite row and without the long test, together with a package row and a parse time. - - **Consequence:** - 1. The first run raises "Suitepath exceeds 1000 CHAR on: …". - 2. Later runs treat the package as cached and raise nothing. - 3. The context has no parent suite, so the package is missing from `get_suites_info`, and running it fails with "Suite package … does not exist", until the package is changed. - - **Possible fix:** save an empty item list when `create_suite_item_list` fails, so the package is not cached and the error is raised on every run. -6. **Arbitrary `row_number` order.** `get_suite_items` deduplicates with `order by path, object_owner` inside a partition by the same columns. That is fine only because the duplicates are identical rows. - -## Target design - -``` -ut_suite_manager (invoker, no role) ut_suite_cache_manager (invoker + CBAC) ------------------------------------ -------------------------------------- -resolve paths, refresh cache ──paths, tags──▶ get_suite_rows(a_paths, a_tags, a_random_seed, a_skip_access_check) - one dynamic statement (tag predicate or 1 = 1), CTEs: - path_items table(:paths), wildcards expanded ← P7 - matched_rows ut_suite_cache ⋈ path_items - + access predicate (all_objects) ← P1 - tagged_rows tag predicate from the tag filter ← P2 - with_logical generated logical suites ← P3 - ordered recursive sort / randomise ← P4 - ◀──rows────── ut_suite_cache_rows; reconstruct_from_cache converts them to records -reconcile(paths, rows) ← P5 -reconstruct_from_cache(rows) no ref cursor ← P6 - -get_suites_info ──paths──────▶ get_suite_info(a_paths, a_skip_access_check) - the same statement text, no tags, no sort, - ◀──cursor──── final select ut_suite_item_info, ordered ← P9 - -ut_suite_tag_filter: only create_where_filter (tag expression → SQL predicate). apply / get_tags_suites are gone (step 4). -ut_annotation_cache_macros: unchanged; the only macro package. -``` - -Notes: - -- **The tag filter is the only reason for dynamic SQL.** The statement is built once, with the tag predicate or `1 = 1`, and executed with binds. Its framework names are qualified with `&&ut3_owner.`: SQL*Plus substitutes them in string literals at install time too. Today's tag SQL uses an unqualified `ut_varchar2_rows`, which must be qualified when it moves. All types it uses are already granted to the role (`ut_varchar2_rows`, `ut_suite_cache_row`, `ut_suite_item_info`, `ut_utils`). -- **Tag propagation** (`propagate_tags_from_ancestors`) is already a self-join over the matched rows, and it moves as a CTE. -- **Readability:** name each CTE after the function it replaces. -- **No new privileges.** `ut_suite_cache_manager` already holds the role. `ut_suite_manager` and `ut_suite_tag_filter` need none, and no new grant lines are needed. - -## Suggested steps (each can ship and be tested separately) - -0. **Remove the `a_parsed_after` branch from `get_cached_objects`. Done.** - - The parameter is gone from the macro and from its three call sites: `remove_missing_objs_from_cache`, `get_non_existing_objects` and `get_objects_to_refresh`. The last one now binds three values instead of four. Its freshness check `case when o.last_ddl_time < cast(c.parse_time as date) then 'N' else 'Y' end = 'Y'` is now written as `(c.parse_time is null or o.last_ddl_time >= cast(c.parse_time as date))`, with the same meaning. It stays in the `where` clause: moved into the `on` clause of the left join, it would no longer drop any row, and every object would be re-parsed on each refresh. - - Rule 5 is documented in the spec of `ut_annotation_cache_macros`. - - **Verified on 2026-11-09:** - - Setup: a fresh container of `utplsqlv3/oracledb:19.20-utplsql`, then `development/install.sh` and `test/install_tests.sh`. - - Install: no invalid objects; the three packages hold the role. - - Full run: 1136 tests, 0 failed, 0 errored, 3 disabled. - - The result doesn't change by design, so the tests are a safety net, not a proof of the effect. -1. **P8, done.** Single `delete` through the macro, plus the follow-up in `ut_annotation_manager`. - - Verified on 19.20 EE (1136 tests), 21.3 XE (1143) and 23ai, all with 0 failed and 3 disabled. - - The 19.20 and 23ai runs are from before the 21c `create_grants.sql` fix, and were not rerun locally after it. - - **Not checked:** which tests make the difference between 1136 and 1143. -2. **P6 + finding 1. Done, partly.** `reconstruct_from_cache` takes the collection instead of a ref cursor, and the rollback type is set once. - - The rows are still converted to records, because of the `ORA-00600` described under P6. - - Verified on 2026-11-09 on 19.20 EE: install with no invalid objects, and the full run passed (1136 tests, 0 failed, 0 errored, 3 disabled). - - Consequence for step 4: the main statement should return columns that are fetched into records, not `ut_suite_cache_row` objects. That also removes the last copy, the conversion in `reconstruct_from_cache`. -3. **P1: access predicate into `get_suite_items`. Done.** - - The access check is plain SQL in `ut_suite_cache_manager`. `get_filtered_cursor` and the logical-suite exemption are gone. - - `build_suites_from_annotations(a_skip_all_objects)` passes its flag through `skip_access_check`. - - The behaviour change is described under P1. - - New tests: 4, in `test_annotation_cache`, with helpers in `annotation_cache_helper`. - - **Verified on 2026-11-09:** - - Setup: a fresh 19.20 container, then `development/install.sh` and `test/install_tests.sh`. - - Install: no invalid objects. - - Full run: 1140 tests, 0 failed, 0 errored, 3 disabled. -4. **P2/P3/P4: one statement. Done.** - - `get_suite_rows` replaces four functions and the tag filter's `apply`; see P2. - - The #1324 regression test in `test_ut_suite_tag_filter` now creates a real package (suitepath, suite, context and test tags). It checks `get_suite_rows` with the same 8 tag expressions as before. - - Two Oracle-level problems came up and are fixed: the `xmltable` parse hang and crash, and the sibling order. See "Other statement-level findings". - - **Verified on 2026-11-10:** - - Setup: a fresh 19.20 container with install and test install. - - Install: no invalid objects. - - First full run: 11 failures, all from the sibling order. - - Final full run, on the same database with only the cache manager body recompiled: 1144 tests, 0 failed, 0 errored, 3 disabled. - - **Static SQL version, verified on 2026-11-10:** - - Setup: a fresh 19.20 container with install and test install. - - Install: no invalid objects. - - Full run: 1143 tests, 0 failed, 0 errored, 3 disabled. That is 1140 plus 3 new `is_matching` tests in `test_ut_suite_tag_filter`. - - **Text tags version, verified on 2026-11-10:** - - The same database after a full run, with only the `ut_suite_cache_manager` and test bodies recompiled. - - Full run: 1148 tests, 0 failed, 0 errored, 3 disabled. That is 1144 (1140 plus 4 `is_matching` tests) plus the 4 tests `test_tfs_junit_reporter` leaves behind. - - **Why 1144:** 1140 tests, plus 4 from packages that `test_tfs_junit_reporter` leaves behind when run twice on one database. Its `remove_test_package` doesn't drop `check_junit_in_context`, `check_junit_out_context` and `check_junit_inout_context`. That test bug predates this work. -5. **P7: path resolution in one place. Done.** See P7 and P5. The tests were reviewed first: - - **Already covered:** paths by schema, package, procedure and suitepath; procedures inside contexts; `$` and `#` in names; wildcards at the end, front, middle and multiple, for package, procedure and suitepath; paths that match nothing. - - **Added before the change:** overlapping paths in one call. - - **Added with the change:** wildcards for a user with partial access. -6. **P9: Flow B on the same statement text. Done.** See P9. Finding 2 is merged too. - -## Bigger options to consider separately - -- **Materialise logical suites in the cache.** Insert `UT_LOGICAL_SUITE` rows into `ut_suite_cache`, per schema, at the end of `refresh_cache`. Run-time queries then become plain table reads, and P3 leaves the read path. - - Cost: logical rows depend on every package in the schema, so they need a rebuild whenever any package's suitepath changes. - - The unique keys on `(object_owner, path)` and `(object_owner, object_name, line_no)` must accommodate them. - - With P1 applied at read time, logical rows would also need an access rule of their own. -- **Stream instead of materialise.** If reconciliation (P5) can be answered from the path CTE alone, the main statement can be returned as a real cursor, and `reconstruct_from_cache` can fetch in batches. That depends on open question 1. - -## How to check that nothing regressed - -- **Behaviour:** the full `ut3_tester` and `ut3_user` suites, especially: - - `test_suite_builder`; - - `test_ut_suite_tag_filter`; - - `test_ut_run` (paths, wildcards, tags, random order); - - `test_ut_runner` (`get_suites_info`, `has_suites`, `is_suite`, `is_test`); - - `test_annotation_cache`, which runs as users without elevated privileges. -- **Platforms:** 19.20, 21.3 XE and 23ai, because macro privilege checks differ between versions (rules 3 and 4). -- **Performance:** compare before and after on a schema with many suites, using the `ut_event_manager` events `configure_execution_by_path - start/end` and `development/mystats`. - -## Open questions - -1. Should a package path whose tests are all excluded by tags raise "does not exist" (P5)? That's the behaviour today; review it after the other work is done. -2. ~~Can logical suites remain in the tree with no accessible children (P1)?~~ Answered: yes, they could. Accessible packages under an inaccessible parent suite were also lost. Both are fixed in step 3; see the table under P1. -3. ~~Is the 20-level limit on suitepath depth (P3) documented?~~ It is intended and is now documented in the user guide (annotations, "Suitepath limits"), together with the 1000-character limit on full paths. Verified on 19.20: a suite with a 21-level suitepath is not run in a schema run and not listed by `get_suites_info`. -4. ~~Would a `parse_time` filter in `get_objects_to_refresh` pay off?~~ Not pursued (decided 2026-11-10). From deb73367e88c8c92c375118a0268b812896a458d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 10 Nov 2026 23:37:20 +0200 Subject: [PATCH 850/887] Fixing build scripts. --- development/cleanup.sh | 2 +- development/install.sh | 2 +- development/refresh_sources.sh | 2 +- development/refresh_ut3.sh | 2 +- test/install_and_run_tests.sh | 2 +- test/run_tests.sh | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/development/cleanup.sh b/development/cleanup.sh index 560395150..54c23b408 100755 --- a/development/cleanup.sh +++ b/development/cleanup.sh @@ -1,7 +1,7 @@ #!/bin/bash #goto git root directory -git rev-parse && cd "$(git rev-parse --show-cdup)" +git rev-parse && cd "$(git rev-parse --show-toplevel)" . ./development/env.sh diff --git a/development/install.sh b/development/install.sh index 468bafd38..22a3166b2 100755 --- a/development/install.sh +++ b/development/install.sh @@ -1,7 +1,7 @@ #!/bin/bash #goto git root directory -git rev-parse && cd "$(git rev-parse --show-cdup)" +git rev-parse && cd "$(git rev-parse --show-toplevel)" . ./development/env.sh diff --git a/development/refresh_sources.sh b/development/refresh_sources.sh index 87869d581..36dd20b47 100755 --- a/development/refresh_sources.sh +++ b/development/refresh_sources.sh @@ -1,7 +1,7 @@ #!/bin/bash #goto git root directory -git rev-parse && cd "$(git rev-parse --show-cdup)" +git rev-parse && cd "$(git rev-parse --show-toplevel)" . ./development/env.sh diff --git a/development/refresh_ut3.sh b/development/refresh_ut3.sh index 7685549ad..5fff37e81 100755 --- a/development/refresh_ut3.sh +++ b/development/refresh_ut3.sh @@ -2,7 +2,7 @@ set -e #goto git root directory -git rev-parse && cd "$(git rev-parse --show-cdup)" +git rev-parse && cd "$(git rev-parse --show-toplevel)" . development/env.sh diff --git a/test/install_and_run_tests.sh b/test/install_and_run_tests.sh index 0c17b08b7..4f0c1978f 100755 --- a/test/install_and_run_tests.sh +++ b/test/install_and_run_tests.sh @@ -2,7 +2,7 @@ set -ev #goto git root directory -git rev-parse && cd "$(git rev-parse --show-cdup)" +git rev-parse && cd "$(git rev-parse --show-toplevel)" . ./development/env.sh cd test diff --git a/test/run_tests.sh b/test/run_tests.sh index 078d011d6..1a6970283 100755 --- a/test/run_tests.sh +++ b/test/run_tests.sh @@ -2,7 +2,7 @@ set -ev #goto git root directory -git rev-parse && cd "$(git rev-parse --show-cdup)" +git rev-parse && cd "$(git rev-parse --show-toplevel)" export NLS_LANG=AMERICAN_AMERICA.AL32UTF8 From 343eecb06533d41f50051adf21568e79e90208da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 11 Nov 2026 19:18:50 +0200 Subject: [PATCH 851/887] Evaluate tag expressions without dynamic SQL ut_suite_tag_filter.is_matching evaluates the postfix form of the tag expression with a stack of booleans, instead of generating a PL/SQL block and running it with execute immediate. The postfix form of the last expression is cached. conv_postfix_to_infix_sql is removed. - A tag expression made only of spaces and tabs is no tag filter, the same as null. Tabs are ignored like spaces. - An empty expression, or one ending with an operator, raises the invalid tag expression error instead of ORA-06502. - Tags with quotes and long expressions no longer break the generated block. - Document that none and any are lowercase only. - Add tests for precedence, keywords, case sensitivity, whitespace, quotes, many tags and three-valued logic; remove the v$sqlarea based cache test. --- docs/userguide/running-unit-tests.md | 2 + source/core/ut_suite_cache_manager.pkb | 6 +- source/core/ut_suite_tag_filter.pkb | 150 ++++++++-------- source/core/ut_suite_tag_filter.pks | 14 +- .../core/test_ut_suite_tag_filter.pkb | 169 ++++++++++++++++-- .../core/test_ut_suite_tag_filter.pks | 45 ++++- test/ut3_tester_helper/main_helper.pkb | 9 - test/ut3_tester_helper/main_helper.pks | 3 - test/ut3_user/api/test_ut_run.pkb | 13 ++ test/ut3_user/api/test_ut_run.pks | 3 + 10 files changed, 305 insertions(+), 109 deletions(-) diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index 961eb5001..a4797b735 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -339,12 +339,14 @@ Multiple tags are separated by comma. Tag expressions are boolean expressions created by combining tags with the `!`, `&`, `|` operators. Tag expressions can be grouped using `(` and `)` braces. Grouping tag expressions affects operator precedence. An invalid tag expression raises an error (ORA-20219) before any test runs. +Spaces and tabs in a tag expression are ignored. A tag expression made only of spaces and tabs doesn't filter the tests, the same as no tag expression. Two reserved keywords, `any` and `none`, can be used when creating a tag expression to run tests. - `any` keyword represents tests and suites with any tags - `none` keyword represents tests and suites without tags These keywords may be combined with other expressions just like normal tags. +The keywords are lowercase only. Like tags, they are case sensitive, so `NONE` or `Any` in a tag expression is an ordinary tag name, not a keyword. !!! note When specifying `none`, be aware that it will exclude any tests/suites/contexts contained within a tagged suite. diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index 9733470dc..f43ea88a8 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -107,6 +107,8 @@ create or replace noneditionable package body ut_suite_cache_manager is l_results ut_suite_cache_rows; l_matched_ids ut_integer_list := get_matched_ids(a_schema_paths, a_skip_access_check); l_with_executables varchar2(1) := case when a_with_executables then 'Y' else 'N' end; + --an expression of spaces and tabs only is no tag filter + l_tags varchar2(32767) := ut_suite_tag_filter.empty_to_null(a_tags); begin with matched_rows as ( @@ -128,12 +130,12 @@ create or replace noneditionable package body ut_suite_cache_manager is filter_by_tags as ( select x.path, x.object_owner from propagate_tags_from_ancestors x - where &&ut3_owner..ut_suite_tag_filter.is_matching(x.tags, a_tags) = 1 + where &&ut3_owner..ut_suite_tag_filter.is_matching(x.tags, l_tags) = 1 ), tagged_rows as ( select /*+ no_expand */ item.* from matched_rows item - where a_tags is null + where l_tags is null or exists ( select 1 from filter_by_tags tst diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index 4f0ebf754..256ef2027 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -17,32 +17,44 @@ create or replace noneditionable package body ut_suite_tag_filter is */ /** - * Constants use in postfix and infix transformations + * Constants used in the conversion to postfix notation */ gc_operators constant ut_varchar2_list := ut_varchar2_list('|','&','!'); gc_unary_operators constant ut_varchar2_list := ut_varchar2_list('!'); -- right side associative operator gc_binary_operators constant ut_varchar2_list := ut_varchar2_list('|','&'); -- left side associative operator - gc_reserved_tag_words constant ut_varchar2_list := ut_varchar2_list('none','any'); gc_exception_msg constant varchar2(200) := 'Invalid tag expression'; type t_precedence_table is table of number index by varchar2(1); g_precedence t_precedence_table; - --last tag expression and its condition, see create_where_filter - g_last_tag_expression varchar2(4000); - g_last_tags_filter varchar2(32767); + --last tag expression and its postfix notation, see get_postfix_expression + g_last_tag_expression varchar2(32767); + g_last_postfix ut_varchar2_list; function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list is l_tags_tokens ut_varchar2_list := ut_varchar2_list(); begin --Tokenize a string into operators and tags - select regexp_substr(a_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts - bulk collect into l_tags_tokens - from dual connect by regexp_substr (a_tags, '([^!()|&]+)|([!()|&])', 1, level) is not null; + if a_tags is not null then + select regexp_substr(a_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts + bulk collect into l_tags_tokens + from dual connect by regexp_substr (a_tags, '([^!()|&]+)|([!()|&])', 1, level) is not null; + end if; return l_tags_tokens; end; + --tags cannot contain whitespace, so spaces and tabs in a tag expression only separate its tokens + function remove_whitespace(a_tag_expression varchar2) return varchar2 is + begin + return replace(replace(a_tag_expression, ' '), chr(9)); + end; + + function empty_to_null(a_tag_expression varchar2) return varchar2 is + begin + return case when remove_whitespace(a_tag_expression) is not null then a_tag_expression end; + end; + /* To support a legact tag notation , = OR @@ -158,6 +170,11 @@ create or replace noneditionable package body ut_suite_tag_filter is l_idx := a_tags.next(l_idx); end loop; + --an empty expression, or one ending with an operator or a left bracket, is incomplete + if not(l_expect_operator) then + raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); + end if; + while l_operator_stack.peek is not null loop if l_operator_stack.peek in ('(',')') then raise_application_error(ut_utils.gc_invalid_tag_expression, gc_exception_msg); @@ -169,80 +186,71 @@ create or replace noneditionable package body ut_suite_tag_filter is return l_rnp_tokens; end shunt_logical_expression; - function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list,a_tags_column_name in varchar2) - return varchar2 is - l_infix_stack ut_stack := ut_stack(); - l_right_side varchar2(32767); - l_left_side varchar2(32767); - l_infix_exp varchar2(32767); - l_member_token varchar2(20) := ' member of '||a_tags_column_name; - l_idx pls_integer; - begin - l_idx := a_postfix_exp.first; - while ( l_idx is not null) loop - --If the token we got is a none or any keyword - if a_postfix_exp(l_idx) member of gc_reserved_tag_words then - - l_infix_stack.push( - case - when a_postfix_exp(l_idx) = 'none' then '('||a_tags_column_name||' is empty or '||a_tags_column_name||' is null)' - else a_tags_column_name||' is not empty' - end - ); - --If token is operand but also single tag - elsif regexp_count(a_postfix_exp(l_idx),'[!()|&]') = 0 then - l_infix_stack.push(q'[']'||a_postfix_exp(l_idx)||q'[']'||l_member_token); - --If token is unary operator not - elsif a_postfix_exp(l_idx) member of gc_unary_operators then - l_right_side := l_infix_stack.pop; - l_infix_exp := a_postfix_exp(l_idx)||'('||l_right_side||')'; - l_infix_stack.push(l_infix_exp); - --If token is binary operator - elsif a_postfix_exp(l_idx) member of gc_binary_operators then - l_right_side := l_infix_stack.pop; - l_left_side := l_infix_stack.pop; - l_infix_exp := '('||l_left_side||a_postfix_exp(l_idx)||l_right_side||')'; - l_infix_stack.push(l_infix_exp); - end if; - l_idx := a_postfix_exp.next(l_idx); - end loop; - - return l_infix_stack.pop; - end conv_postfix_to_infix_sql; - /* - Generates a condition on a collection named "tags" from a tag expression. + Returns a tag expression in postfix notation (Reverse Polish Notation). + is_matching is called for each test with the same expression, so the result for the last expression is cached. Raises ut_utils.gc_invalid_tag_expression for an invalid expression. */ - function create_where_filter(a_tag_expression varchar2, a_tags_var_name varchar2) return varchar2 is - l_tags_filter varchar2(4000); + function get_postfix_expression(a_tag_expression varchar2) return ut_varchar2_list is + l_postfix ut_varchar2_list; begin - -- if calculated already, return previously calculated value. Cache of input tag filter expression evaluation if g_last_tag_expression = a_tag_expression then - return g_last_tags_filter; + return g_last_postfix; end if; - l_tags_filter := replace(replace_legacy_tag_notation(a_tag_expression),' '); - l_tags_filter := conv_postfix_to_infix_sql(shunt_logical_expression(tokenize_tags_string(l_tags_filter)),a_tags_var_name); - l_tags_filter := replace(l_tags_filter, '|',' or '); - l_tags_filter := replace(l_tags_filter ,'&',' and '); - l_tags_filter := replace(l_tags_filter ,'!','not'); + l_postfix := shunt_logical_expression( + tokenize_tags_string( remove_whitespace( replace_legacy_tag_notation(a_tag_expression) ) ) + ); g_last_tag_expression := a_tag_expression; - g_last_tags_filter := l_tags_filter; - return l_tags_filter; + g_last_postfix := l_postfix; + return l_postfix; + end; + + /* + Evaluates a valid postfix expression against a list of tags, using a stack of operand values. + The values follow the three-valued logic of SQL: "x member of a_tags" is null when a_tags has a null element + and no element x, and "not null" is null, as in a SQL condition. + */ + function evaluate_postfix(a_postfix ut_varchar2_list, a_tags ut_varchar2_list) return boolean is + type t_boolean_stack is table of boolean index by pls_integer; + l_stack t_boolean_stack; + l_top pls_integer := 0; + l_token varchar2(32767); + begin + for i in 1 .. a_postfix.count loop + l_token := a_postfix(i); + case l_token + when '!' then + l_stack(l_top) := not l_stack(l_top); + when '&' then + l_top := l_top - 1; + l_stack(l_top) := l_stack(l_top) and l_stack(l_top + 1); + when '|' then + l_top := l_top - 1; + l_stack(l_top) := l_stack(l_top) or l_stack(l_top + 1); + else + l_top := l_top + 1; + l_stack(l_top) := + case l_token + when 'none' then a_tags is empty + when 'any' then a_tags is not empty + else l_token member of a_tags + end; + end case; + end loop; + return l_stack(1); end; function is_matching(a_tags varchar2, a_tag_expression varchar2) return integer deterministic is - l_result integer; - c_tags_col_name varchar2(10) := 'l_tags'; begin - execute immediate - 'declare ' || - ' '||c_tags_col_name||' ut_varchar2_list := :a_tags; ' || - 'begin ' || - ' :a_result := case when '||create_where_filter(a_tag_expression, c_tags_col_name)||' then 1 else 0 end; ' || - 'end;' - using in ut_utils.string_to_table(a_tags, ','), out l_result; - return l_result; + if empty_to_null(a_tag_expression) is null then + return 1; + end if; + return + case + when evaluate_postfix( get_postfix_expression(a_tag_expression), ut_utils.string_to_table(a_tags, ',') ) + then 1 + else 0 + end; end; diff --git a/source/core/ut_suite_tag_filter.pks b/source/core/ut_suite_tag_filter.pks index ab49768e9..4d9c55b7d 100644 --- a/source/core/ut_suite_tag_filter.pks +++ b/source/core/ut_suite_tag_filter.pks @@ -24,7 +24,7 @@ create or replace noneditionable package ut_suite_tag_filter authid definer is /* * Return table of tokens character by character - */ + */ function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list; /* @@ -35,14 +35,14 @@ create or replace noneditionable package ut_suite_tag_filter authid definer is function shunt_logical_expression(a_tags in ut_varchar2_list) return ut_varchar2_list; /* - * Function that converts postfix notation into infix and creating a string of sql filter - * that checking a tags collections for tags according to posted logic. - */ - function conv_postfix_to_infix_sql(a_postfix_exp in ut_varchar2_list,a_tags_column_name in varchar2) - return varchar2; - + * Returns null for a tag expression made only of spaces and tabs, as such an expression is no tag filter. + * Returns any other tag expression unchanged. + */ + function empty_to_null(a_tag_expression varchar2) return varchar2; + /* * Returns 1 when the tags match the tag expression, 0 otherwise. + * An empty tag expression (see empty_to_null) matches any tags. * a_tags is a comma-separated list of tags (tags cannot contain commas), null for no tags. * Takes text, not a collection: Oracle caches results of a deterministic function called from SQL * only when all arguments are scalars, so items with the same tags are evaluated once per statement. diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index 9b7951cb9..59c453470 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -80,6 +80,25 @@ create or replace package body test_ut_suite_tag_filter is ut.fail('Expected exception but nothing was raised'); end; + procedure conversion_throws_when_empty is + l_postfix ut3_develop.ut_varchar2_list; + begin + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(ut3_develop.ut_varchar2_list()); + ut.fail('Expected exception but nothing was raised'); + end; + + procedure conversion_throws_when_trailing_opr is + l_postfix ut3_develop.ut_varchar2_list; + begin + l_postfix := ut3_develop.ut_suite_tag_filter.shunt_logical_expression(ut3_develop.ut_varchar2_list('a','|')); + ut.fail('Expected exception but nothing was raised'); + end; + + procedure tokenize_empty_string is + begin + ut.expect( ut3_develop.ut_suite_tag_filter.tokenize_tags_string(null).count ).to_equal(0); + end; + procedure is_matching_or_and_not is begin ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('test1', 'test1') ).to_equal(1); @@ -122,22 +141,126 @@ create or replace package body test_ut_suite_tag_filter is ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, 'slow') ).to_equal(0); end; - procedure is_matching_is_cached_in_sql is - --the anonymous block run by is_matching for the expression 'cache_probe' - c_block constant varchar2(100) := 'declare %ut_varchar2_list := :a_tags;%''cache_probe'' member of %'; - l_before number; - l_after number; - l_count integer; + procedure is_matching_operator_precedence is + begin + --"&" binds stronger than "|" + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a', 'a|b&c') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('b', 'a|b&c') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('b,c', 'a|b&c') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('c', 'b&c|a') ).to_equal(0); + --brackets + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a', '(a|b)&c') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a,c', '(a|b)&c') ).to_equal(1); + --"!" binds stronger than "&" + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('b', '!a&b') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a,b', '!a&b') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a', '!(a&b)') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a,b', '!(a&b)') ).to_equal(0); + --double negation + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a', '!!a') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('b', '!!a') ).to_equal(0); + end; + + procedure is_matching_none_and_any_combined is + begin + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', 'none|slow') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, 'none|slow') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('db', 'none|slow') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', '!none') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, '!none') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, '!any') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', 'any&!slow') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('db', 'any&!slow') ).to_equal(1); + end; + + procedure is_matching_is_case_sensitive is + begin + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('Slow', 'slow') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', 'SLOW') ).to_equal(0); + --upper case keywords are tags, not the none and any keywords + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, 'NONE') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', 'ANY') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('ANY', 'ANY') ).to_equal(1); + end; + + procedure is_matching_ignores_whitespace is + c_tab constant varchar2(1) := chr(9); + begin + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('db,slow', ' slow & db ') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('db,slow', ' ( fast | slow ) & ! db ') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('db,slow', c_tab||'slow'||c_tab||'&'||c_tab||'db'||c_tab) ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('db,slow', 'slow'||c_tab||'&'||c_tab||'!'||c_tab||'db') ).to_equal(0); + --legacy notation + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('db,slow', 'fast, slow') ).to_equal(1); + end; + + procedure is_matching_empty_expression is + c_tab constant varchar2(1) := chr(9); + begin + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', null) ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, null) ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', ' ') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, ' ') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', c_tab) ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, ' '||c_tab||' ') ).to_equal(1); + end; + + procedure empty_to_null_for_blank_expression is + c_tab constant varchar2(1) := chr(9); + begin + ut.expect( ut3_develop.ut_suite_tag_filter.empty_to_null(null) ).to_be_null(); + ut.expect( ut3_develop.ut_suite_tag_filter.empty_to_null(' ') ).to_be_null(); + ut.expect( ut3_develop.ut_suite_tag_filter.empty_to_null(' '||c_tab||c_tab||' ') ).to_be_null(); + --a non-empty expression is returned unchanged + ut.expect( ut3_develop.ut_suite_tag_filter.empty_to_null(' slow & db ') ).to_equal(' slow & db '); + end; + + procedure is_matching_tag_with_quote is + begin + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(q'[it's]', q'[it's]') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', q'[slow&!it's]') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', q'[it's]') ).to_equal(0); + end; + + procedure is_matching_many_tags is + c_tag_prefix constant varchar2(30) := 'a_long_tag_name_for_testing_'; + l_expression varchar2(32767); begin - l_before := ut3_tester_helper.main_helper.get_sql_executions(c_block); - --1000 rows with 3 distinct sets of tags - select count(*) into l_count - from (select mod(level,3) k from dual connect by level <= 1000) - where ut3_develop.ut_suite_tag_filter.is_matching('t'||k||',x', 'cache_probe') = 0; - l_after := ut3_tester_helper.main_helper.get_sql_executions(c_block); - ut.expect( l_count ).to_equal(1000); - --at least one execution, so the pattern above still matches the block - ut.expect( l_after - l_before ).to_be_between(1, 3); + --80 tags of 31 characters, joined with "|": a condition with "member of" for each tag would be over 4000 characters + for i in 1 .. 80 loop + l_expression := l_expression || case when i > 1 then '|' end || c_tag_prefix || lpad(i, 3, '0'); + end loop; + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(c_tag_prefix||'080', l_expression) ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow,'||c_tag_prefix||'001', l_expression) ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('slow', l_expression) ).to_equal(0); + end; + + procedure is_matching_null_tag_element is + begin + --'a,,b' has a null element, so "x member of" it is unknown (null) instead of false when x is not in the list + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a,,b', 'a') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a,,b', 'x') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a,,b', '!x') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a,,b', 'a|!x') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a,,b', 'a&!x') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a,,b', '!a&!x') ).to_equal(0); + end; + + procedure is_matching_follows_expression_change is + l_result integer; + begin + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a', 'a') ).to_equal(1); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a', 'b') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a', 'a') ).to_equal(1); + begin + l_result := ut3_develop.ut_suite_tag_filter.is_matching('a', 'a&'); + ut.fail('Expected exception but nothing was raised'); + exception + when others then + ut.expect( sqlcode ).to_equal( ut3_develop.ut_utils.gc_invalid_tag_expression ); + end; + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a', 'b') ).to_equal(0); + ut.expect( ut3_develop.ut_suite_tag_filter.is_matching('a', 'a') ).to_equal(1); end; procedure is_matching_invalid_expression is @@ -146,6 +269,22 @@ create or replace package body test_ut_suite_tag_filter is l_result := ut3_develop.ut_suite_tag_filter.is_matching('slow', 'slow&|db'); end; + procedure is_matching_incomplete_expression is + --legacy notation turns ',' into an empty expression + l_expressions ut3_develop.ut_varchar2_list := ut3_develop.ut_varchar2_list('slow|', 'slow&!', '!', '(slow', ','); + l_result integer; + begin + for i in 1 .. l_expressions.count loop + begin + l_result := ut3_develop.ut_suite_tag_filter.is_matching('slow', l_expressions(i)); + ut.fail('Expected exception for tag expression "'||l_expressions(i)||'" but nothing was raised'); + exception + when others then + ut.expect( sqlcode, 'Tag expression "'||l_expressions(i)||'"' ).to_equal( ut3_develop.ut_utils.gc_invalid_tag_expression ); + end; + end loop; + end; + procedure create_tags_suite is pragma autonomous_transaction; begin diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pks b/test/ut3_tester/core/test_ut_suite_tag_filter.pks index 11d58de7e..d19168bc1 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pks +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pks @@ -32,6 +32,17 @@ create or replace package test_ut_suite_tag_filter is --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) procedure conversion_throws_when_unmatched_rb; + --%test(Conversion raises exception for an empty list of tokens) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure conversion_throws_when_empty; + + --%test(Conversion raises exception when the expression ends with an operator) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure conversion_throws_when_trailing_opr; + + --%test(Tokenizing an empty string returns no tokens) + procedure tokenize_empty_string; + --%endcontext --%test( Evaluates or, and and not in tag expressions) @@ -43,13 +54,43 @@ create or replace package test_ut_suite_tag_filter is --%test( Evaluates none and any for items without tags) procedure is_matching_without_tags; - --%test( Evaluates each distinct set of tags once per SQL statement) - procedure is_matching_is_cached_in_sql; + --%test( Applies operator precedence, brackets and double negation) + procedure is_matching_operator_precedence; + + --%test( Combines none and any with other tags) + procedure is_matching_none_and_any_combined; + + --%test( Compares tags and the none and any keywords case sensitively) + procedure is_matching_is_case_sensitive; + + --%test( Ignores spaces and tabs in the tag expression) + procedure is_matching_ignores_whitespace; + + --%test( Matches any tags when the tag expression is empty or made of spaces and tabs) + procedure is_matching_empty_expression; + + --%test( Returns null for an empty tag expression made of spaces and tabs) + procedure empty_to_null_for_blank_expression; + + --%test( Evaluates a tag containing a quote) + procedure is_matching_tag_with_quote; + + --%test( Evaluates an expression with many tags) + procedure is_matching_many_tags; + + --%test( Follows three-valued logic for an empty element in the list of tags) + procedure is_matching_null_tag_element; + + --%test( Evaluates the current expression after the expression changes or an invalid expression is given) + procedure is_matching_follows_expression_change; --%test( Raises exception for an invalid tag expression) --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) procedure is_matching_invalid_expression; + --%test( Raises exception for an incomplete tag expression) + procedure is_matching_incomplete_expression; + procedure create_tags_suite; procedure drop_tags_suite; diff --git a/test/ut3_tester_helper/main_helper.pkb b/test/ut3_tester_helper/main_helper.pkb index 44cce346f..f60ce796c 100644 --- a/test/ut3_tester_helper/main_helper.pkb +++ b/test/ut3_tester_helper/main_helper.pkb @@ -174,14 +174,5 @@ create or replace package body main_helper is return l_result; end; - function get_sql_executions(a_sql_text_like varchar2) return number is - l_result number; - begin - select nvl(sum(s.executions), 0) into l_result - from v$sqlarea s - where s.sql_text like a_sql_text_like; - return l_result; - end; - end; / diff --git a/test/ut3_tester_helper/main_helper.pks b/test/ut3_tester_helper/main_helper.pks index da7643b13..71575e145 100644 --- a/test/ut3_tester_helper/main_helper.pks +++ b/test/ut3_tester_helper/main_helper.pks @@ -51,8 +51,5 @@ create or replace package main_helper is function make_source(a_lines ut3_develop.ut_varchar2_list) return dbms_preprocessor.source_lines_t; - --number of executions of SQL statements and PL/SQL blocks whose text is like a_sql_text_like - function get_sql_executions(a_sql_text_like varchar2) return number; - end; / diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 3733f0623..87a048904 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -1401,6 +1401,19 @@ procedure tag_exclude_run_fun_pth_lst_lg is ut.expect(sqlerrm).to_be_like('%ORA-20204: Suite package ut3_tester_helper.test_tag_pkg_* does not exist%'); end; + procedure blank_tags_run_all_tests is + l_expected ut3_develop.ut_varchar2_list; + l_actual ut3_develop.ut_varchar2_list; + begin + l_expected := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests,:tests2')); + l_actual := ut3_tester_helper.run_helper.run(ut3_develop.ut_varchar2_list(':tests,:tests2'), a_tags => ' '||chr(9)||' '); + + remove_time_from_results(l_expected); + remove_time_from_results(l_actual); + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_actual) ).to_be_like( '%test_package_1.test1%executed%' ); + ut.expect( anydata.convertCollection(l_actual) ).to_equal( anydata.convertCollection(l_expected) ); + end; + procedure set_application_info is begin dbms_application_info.set_module( gc_module, gc_action ); diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index d7da98871..97c2a2b16 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -295,6 +295,9 @@ create or replace package test_ut_run is --%test(Raises an error naming the wildcard path when the tags exclude all tests it selects) procedure tag_run_wildcard_none_left; + --%test(Runs the same tests as without tags when the tag expression is made of spaces and tabs) + procedure blank_tags_run_all_tests; + --%endcontext --%context(ut3_info context) From d087f48419a8cfe883ffdae7dab6aa91dd34d904 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 11 Nov 2026 23:13:56 +0200 Subject: [PATCH 852/887] Adding note on comments in code into CONTRIBUTING.md --- CONTRIBUTING.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 1b6f9abd1..c5df712aa 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -37,6 +37,7 @@ Not able to contribute code? You can also support the project through [sponsorsh * Types in packages, objects start with `t_` * Nested Tables start with `tt_` * varchar2 lengths are set in characters not bytes +* Comments should not be added to explain what the code does; the code itself should make that clear. Use a comment to give the reason for the code, or background that isn't obvious from the code or easy to find with an internet search, and only where it adds real value. * Every source file carries the Apache license header. * Don't edit version strings (`v3.x.x.xxxx`) in `source/`, `VERSION` or `BUILD_NO` by hand. CI rewrites them (`.github/scripts/update_project_version.sh`). From c78c579ca37e450ffb17e48c9c00a055d34af938 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Wed, 11 Nov 2026 23:56:12 +0200 Subject: [PATCH 853/887] Strip whitespace from tag expressions with one public function --- source/core/ut_suite_cache_manager.pkb | 2 +- source/core/ut_suite_tag_filter.pkb | 31 ++++------ source/core/ut_suite_tag_filter.pks | 9 +-- .../core/test_ut_suite_tag_filter.pkb | 11 ++-- .../core/test_ut_suite_tag_filter.pks | 60 +++++++++---------- 5 files changed, 52 insertions(+), 61 deletions(-) diff --git a/source/core/ut_suite_cache_manager.pkb b/source/core/ut_suite_cache_manager.pkb index f43ea88a8..a3ff6edfd 100644 --- a/source/core/ut_suite_cache_manager.pkb +++ b/source/core/ut_suite_cache_manager.pkb @@ -108,7 +108,7 @@ create or replace noneditionable package body ut_suite_cache_manager is l_matched_ids ut_integer_list := get_matched_ids(a_schema_paths, a_skip_access_check); l_with_executables varchar2(1) := case when a_with_executables then 'Y' else 'N' end; --an expression of spaces and tabs only is no tag filter - l_tags varchar2(32767) := ut_suite_tag_filter.empty_to_null(a_tags); + l_tags varchar2(32767) := ut_suite_tag_filter.remove_whitespace(a_tags); begin with matched_rows as ( diff --git a/source/core/ut_suite_tag_filter.pkb b/source/core/ut_suite_tag_filter.pkb index 256ef2027..1ff204a5e 100644 --- a/source/core/ut_suite_tag_filter.pkb +++ b/source/core/ut_suite_tag_filter.pkb @@ -27,14 +27,12 @@ create or replace noneditionable package body ut_suite_tag_filter is type t_precedence_table is table of number index by varchar2(1); g_precedence t_precedence_table; - --last tag expression and its postfix notation, see get_postfix_expression g_last_tag_expression varchar2(32767); g_last_postfix ut_varchar2_list; function tokenize_tags_string(a_tags in varchar2) return ut_varchar2_list is l_tags_tokens ut_varchar2_list := ut_varchar2_list(); begin - --Tokenize a string into operators and tags if a_tags is not null then select regexp_substr(a_tags,'([^!()|&]+)|([!()|&])', 1, level) as string_parts bulk collect into l_tags_tokens @@ -44,29 +42,22 @@ create or replace noneditionable package body ut_suite_tag_filter is return l_tags_tokens; end; - --tags cannot contain whitespace, so spaces and tabs in a tag expression only separate its tokens function remove_whitespace(a_tag_expression varchar2) return varchar2 is begin return replace(replace(a_tag_expression, ' '), chr(9)); end; - function empty_to_null(a_tag_expression varchar2) return varchar2 is - begin - return case when remove_whitespace(a_tag_expression) is not null then a_tag_expression end; - end; - /* - To support a legact tag notation + To support a legacy tag notation , = OR - = NOT - we will perform a replace of that characters into + we replace those characters into new notation. | = OR & = AND ! = NOT */ - function replace_legacy_tag_notation(a_tags varchar2 - ) return varchar2 is + function replace_legacy_tag_notation(a_tags varchar2) return varchar2 is l_tags ut_varchar2_list := ut_utils.string_to_table(a_tags,','); l_tags_include varchar2(4000); l_tags_exclude varchar2(4000); @@ -80,7 +71,7 @@ create or replace noneditionable package body ut_suite_tag_filter is from table(l_tags) t where t.column_value not like '-%'; - select '('||listagg( replace(t.column_value,'-','!'),' & ') + select '('||listagg( replace(t.column_value,'-','!'),'&') within group( order by column_value)||')' into l_tags_exclude from table(l_tags) t @@ -90,7 +81,7 @@ create or replace noneditionable package body ut_suite_tag_filter is l_return_tag:= case when l_tags_include <> '()' and l_tags_exclude <> '()' - then l_tags_include || ' & ' || l_tags_exclude + then l_tags_include || '&' || l_tags_exclude when l_tags_include <> '()' then l_tags_include when l_tags_exclude <> '()' @@ -114,7 +105,7 @@ create or replace noneditionable package body ut_suite_tag_filter is l_idx pls_integer; begin l_idx := a_tags.first; - --Exuecute modified shunting algorithm + --Execute modified shunting algorithm WHILE (l_idx is not null) loop l_token := a_tags(l_idx); if (l_token member of gc_operators and l_token member of gc_binary_operators) then @@ -198,7 +189,7 @@ create or replace noneditionable package body ut_suite_tag_filter is return g_last_postfix; end if; l_postfix := shunt_logical_expression( - tokenize_tags_string( remove_whitespace( replace_legacy_tag_notation(a_tag_expression) ) ) + tokenize_tags_string( replace_legacy_tag_notation( a_tag_expression ) ) ); g_last_tag_expression := a_tag_expression; g_last_postfix := l_postfix; @@ -241,13 +232,13 @@ create or replace noneditionable package body ut_suite_tag_filter is end; function is_matching(a_tags varchar2, a_tag_expression varchar2) return integer deterministic is + l_tag_expression varchar2(32767) := remove_whitespace(a_tag_expression); begin - if empty_to_null(a_tag_expression) is null then - return 1; - end if; return case - when evaluate_postfix( get_postfix_expression(a_tag_expression), ut_utils.string_to_table(a_tags, ',') ) + when l_tag_expression is null + then 1 + when evaluate_postfix( get_postfix_expression(l_tag_expression), ut_utils.string_to_table(a_tags, ',') ) then 1 else 0 end; diff --git a/source/core/ut_suite_tag_filter.pks b/source/core/ut_suite_tag_filter.pks index 4d9c55b7d..3520c33c6 100644 --- a/source/core/ut_suite_tag_filter.pks +++ b/source/core/ut_suite_tag_filter.pks @@ -35,14 +35,15 @@ create or replace noneditionable package ut_suite_tag_filter authid definer is function shunt_logical_expression(a_tags in ut_varchar2_list) return ut_varchar2_list; /* - * Returns null for a tag expression made only of spaces and tabs, as such an expression is no tag filter. - * Returns any other tag expression unchanged. + * Returns the tag expression without spaces and tabs. + * Tags cannot contain whitespace, so it only separates the tokens of an expression. + * An expression made only of spaces and tabs becomes null, which is no tag filter. */ - function empty_to_null(a_tag_expression varchar2) return varchar2; + function remove_whitespace(a_tag_expression varchar2) return varchar2; /* * Returns 1 when the tags match the tag expression, 0 otherwise. - * An empty tag expression (see empty_to_null) matches any tags. + * An empty tag expression (see remove_whitespace) matches any tags. * a_tags is a comma-separated list of tags (tags cannot contain commas), null for no tags. * Takes text, not a collection: Oracle caches results of a deterministic function called from SQL * only when all arguments are scalars, so items with the same tags are evaluated once per statement. diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb index 59c453470..34af60549 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pkb +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pkb @@ -205,14 +205,13 @@ create or replace package body test_ut_suite_tag_filter is ut.expect( ut3_develop.ut_suite_tag_filter.is_matching(null, ' '||c_tab||' ') ).to_equal(1); end; - procedure empty_to_null_for_blank_expression is + procedure remove_whitespace_from_expression is c_tab constant varchar2(1) := chr(9); begin - ut.expect( ut3_develop.ut_suite_tag_filter.empty_to_null(null) ).to_be_null(); - ut.expect( ut3_develop.ut_suite_tag_filter.empty_to_null(' ') ).to_be_null(); - ut.expect( ut3_develop.ut_suite_tag_filter.empty_to_null(' '||c_tab||c_tab||' ') ).to_be_null(); - --a non-empty expression is returned unchanged - ut.expect( ut3_develop.ut_suite_tag_filter.empty_to_null(' slow & db ') ).to_equal(' slow & db '); + ut.expect( ut3_develop.ut_suite_tag_filter.remove_whitespace(null) ).to_be_null(); + ut.expect( ut3_develop.ut_suite_tag_filter.remove_whitespace(' ') ).to_be_null(); + ut.expect( ut3_develop.ut_suite_tag_filter.remove_whitespace(' '||c_tab||c_tab||' ') ).to_be_null(); + ut.expect( ut3_develop.ut_suite_tag_filter.remove_whitespace(' slow &'||c_tab||'db ') ).to_equal('slow&db'); end; procedure is_matching_tag_with_quote is diff --git a/test/ut3_tester/core/test_ut_suite_tag_filter.pks b/test/ut3_tester/core/test_ut_suite_tag_filter.pks index d19168bc1..92c8cc744 100644 --- a/test/ut3_tester/core/test_ut_suite_tag_filter.pks +++ b/test/ut3_tester/core/test_ut_suite_tag_filter.pks @@ -5,43 +5,43 @@ create or replace package test_ut_suite_tag_filter is --%context( Conversion to Reverse Polish Notation) - --%test( Test conversion of expression into Reverse Polish Notation) - procedure test_conversion_to_rpn; + --%test( Test conversion of expression into Reverse Polish Notation) + procedure test_conversion_to_rpn; - --%test( Operator is followed by operator) - --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) - procedure test_conversion_opr_by_opr; + --%test( Operator is followed by operator) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure test_conversion_opr_by_opr; - --%test( Operand is followed by operand) - --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) - procedure test_conversion_oprd_by_opd; + --%test( Operand is followed by operand) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure test_conversion_oprd_by_opd; - --%test( Left Bracket is followed by operator) - --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) - procedure test_conversion_lb_by_oper; + --%test( Left Bracket is followed by operator) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure test_conversion_lb_by_oper; - --%test( Right Bracket is followed by operand) - --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) - procedure test_conversion_rb_by_oprd; + --%test( Right Bracket is followed by operand) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure test_conversion_rb_by_oprd; - --%test(Conversion raises exception when empty brackets) - --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) - procedure conversion_throws_when_lb_rb; + --%test(Conversion raises exception when empty brackets) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure conversion_throws_when_lb_rb; - --%test(Conversion raises exception when a right bracket has no left bracket) - --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) - procedure conversion_throws_when_unmatched_rb; + --%test(Conversion raises exception when a right bracket has no left bracket) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure conversion_throws_when_unmatched_rb; - --%test(Conversion raises exception for an empty list of tokens) - --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) - procedure conversion_throws_when_empty; + --%test(Conversion raises exception for an empty list of tokens) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure conversion_throws_when_empty; - --%test(Conversion raises exception when the expression ends with an operator) - --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) - procedure conversion_throws_when_trailing_opr; + --%test(Conversion raises exception when the expression ends with an operator) + --%throws(ut3_develop.ut_utils.gc_invalid_tag_expression) + procedure conversion_throws_when_trailing_opr; - --%test(Tokenizing an empty string returns no tokens) - procedure tokenize_empty_string; + --%test(Tokenizing an empty string returns no tokens) + procedure tokenize_empty_string; --%endcontext @@ -69,8 +69,8 @@ create or replace package test_ut_suite_tag_filter is --%test( Matches any tags when the tag expression is empty or made of spaces and tabs) procedure is_matching_empty_expression; - --%test( Returns null for an empty tag expression made of spaces and tabs) - procedure empty_to_null_for_blank_expression; + --%test( Removes spaces and tabs from a tag expression, returning null for one made only of them) + procedure remove_whitespace_from_expression; --%test( Evaluates a tag containing a quote) procedure is_matching_tag_with_quote; From 4369cb528ae8382c4a499c2764c40d394ebe4d7c Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 13 Nov 2026 14:14:24 +0000 Subject: [PATCH 854/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 9bcafcbd6..a28d2964e 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4600 +4620 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index e7c01e72d..13e11bca7 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4600-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4620-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 74c0231b892ec8544860cef85fb4662365ff59b4 Mon Sep 17 00:00:00 2001 From: vasipallyn <207942208+vasipallyn@users.noreply.github.com> Date: Fri, 13 Nov 2026 19:34:58 +0000 Subject: [PATCH 855/887] Document the CREATE ANY CONTEXT privilege needed for installation install.sql creates the _info application context, and check_sys_grants.sql stops the installation when the installing user lacks CREATE ANY CONTEXT, but the installation guide did not mention the privilege. Add it to the privileges needed when the installing user is the utPLSQL owner, and explain in "Installing utPLSQL" that it is needed only during installation and is deliberately not granted by create_utplsql_owner.sql. Fixes #1147 --- docs/userguide/install.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/userguide/install.md b/docs/userguide/install.md index 1de35c0d3..04b47b97b 100644 --- a/docs/userguide/install.md +++ b/docs/userguide/install.md @@ -166,6 +166,7 @@ If the installing user and utPLSQL owner is one and the same, the user must have - ALTER SESSION - CREATE TRIGGER - CREATE ROLE + - CREATE ANY CONTEXT (needed only for the installation, see [Installing utPLSQL](#installing-utplsql)) In addition, the user must be granted the execute privilege on `DBMS_LOCK` and `DBMS_CRYPTO` packages. @@ -197,6 +198,13 @@ The installation uses code based access control (CBAC) to give utPLSQL packages It creates the role `_cbac_modify_objects_role` (for example `ut3_cbac_modify_objects_role`), unless it already exists, and grants it to the utPLSQL schema and to utPLSQL packages. The installing user therefore needs the `CREATE ROLE` privilege. Each utPLSQL schema gets its own role. The role is dropped when utPLSQL is uninstalled. +The installation also creates the application context `_info` (for example `ut3_info`), which makes information about the running test available through [`sys_context`](annotations.md#sys_context). +The installing user therefore needs the `CREATE ANY CONTEXT` privilege. +This privilege is needed only while installing, not when running tests. +Because it is a powerful `ANY` privilege, `create_utplsql_owner.sql` deliberately does not grant it to the utPLSQL schema. +If you install utPLSQL as the utPLSQL schema owner, grant `CREATE ANY CONTEXT` to that user before the installation and revoke it afterwards. +The headless installation runs as `SYSDBA` and needs no additional grant. + Example invocation: ```bash cd source From 47f7397f087a7b0280c555ba434f1fdb6be7ddaf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Mon, 16 Nov 2026 01:08:28 +0900 Subject: [PATCH 856/887] When source line over varchar2 limit, line is divided on all_source view. And then, returns unexpected line. --- source/core/ut_metadata.pkb | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index 7c89dc5ef..105a19387 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -86,6 +86,25 @@ create or replace noneditionable package body ut_metadata as order by line]' bulk collect into g_source_cache using a_owner, a_object_name; + + declare + l_text all_source.text%type; + l_source t_cache; + begin + l_source := t_cache(); + for i in 1..g_source_cache.count loop + if l_text is null then + l_text := g_source_cache(i); + end if; + if instr(g_source_cache(i), chr(10)) > 0 then + l_source.extend; + l_source(l_source.count) := l_text; + l_text := null; + end if; + end loop; + + g_source_cache := l_source; + end; end if; if g_source_cache.exists(a_line_no) then From 5179c0d5be796d2d46528706ebbc429dcde075fa Mon Sep 17 00:00:00 2001 From: Hiroaki Ishibashi <66629597+monookenai@users.noreply.github.com> Date: Mon, 16 Nov 2026 14:11:10 +0900 Subject: [PATCH 857/887] add test --- test/ut3_tester/core/test_ut_metadata.pkb | 44 +++++++++++++++++++++++ test/ut3_tester/core/test_ut_metadata.pks | 14 ++++++++ 2 files changed, 58 insertions(+) create mode 100644 test/ut3_tester/core/test_ut_metadata.pkb create mode 100644 test/ut3_tester/core/test_ut_metadata.pks diff --git a/test/ut3_tester/core/test_ut_metadata.pkb b/test/ut3_tester/core/test_ut_metadata.pkb new file mode 100644 index 000000000..9be3cb4ba --- /dev/null +++ b/test/ut3_tester/core/test_ut_metadata.pkb @@ -0,0 +1,44 @@ +create or replace package body test_ut_metadata +is + + procedure test_over_varchar2_limit + is + l_actual all_source.text%type; + l_expect all_source.text%type; + begin + l_expect := '/* [varcahr2 limit]*****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************[varcahr2 limit]'; + ut.expect(length(l_expect)).to_equal(4000); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('ut3_tester', 'TEST_PACKAGE1', 5); + ut.expect(l_actual).to_equal(l_actual); + + l_expect := 'null;/* expect line */'; + l_actual := ut3_develop.ut_metadata.get_source_definition_line('ut3_tester', 'TEST_PACKAGE1', 6); + ut.expect(l_actual).to_equal(l_actual); + end; + + procedure create_test_package is + pragma autonomous_transaction; + begin + execute immediate + 'create or replace package test_package1 is + procedure sp_test; + end;'; + + execute immediate + 'create or replace package body test_package1 is + procedure sp_test + is + begin +/* [varcahr2 limit]*****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************[varcahr2 limit][over] */ + null;/* expect line */ + end; + end;'; + end; + + procedure drop_test_package is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_package1'; + end; +end; +/ \ No newline at end of file diff --git a/test/ut3_tester/core/test_ut_metadata.pks b/test/ut3_tester/core/test_ut_metadata.pks new file mode 100644 index 000000000..9061a2208 --- /dev/null +++ b/test/ut3_tester/core/test_ut_metadata.pks @@ -0,0 +1,14 @@ +create or replace package test_ut_metadata +is + --%suite(ut_metadata) + --%suitepath(utplsql.ut3_tester.core) + + --%test(source line is over varchar2 limit) + procedure test_over_varchar2_limit; + + --%beforeall + procedure create_test_package; + --%afterall + procedure drop_test_package; +end; +/ \ No newline at end of file From 21f772720cb4a1784a1ec7a2b50a91a971551f8b Mon Sep 17 00:00:00 2001 From: Hiroaki Ishibashi <66629597+monookenai@users.noreply.github.com> Date: Mon, 16 Nov 2026 14:29:55 +0900 Subject: [PATCH 858/887] fix code format --- test/ut3_tester/core/test_ut_metadata.pkb | 3 +-- test/ut3_tester/core/test_ut_metadata.pks | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/test/ut3_tester/core/test_ut_metadata.pkb b/test/ut3_tester/core/test_ut_metadata.pkb index 9be3cb4ba..1d2a5a87b 100644 --- a/test/ut3_tester/core/test_ut_metadata.pkb +++ b/test/ut3_tester/core/test_ut_metadata.pkb @@ -1,5 +1,4 @@ -create or replace package body test_ut_metadata -is +create or replace package body test_ut_metadata is procedure test_over_varchar2_limit is diff --git a/test/ut3_tester/core/test_ut_metadata.pks b/test/ut3_tester/core/test_ut_metadata.pks index 9061a2208..fe739c6aa 100644 --- a/test/ut3_tester/core/test_ut_metadata.pks +++ b/test/ut3_tester/core/test_ut_metadata.pks @@ -1,5 +1,4 @@ -create or replace package test_ut_metadata -is +create or replace package test_ut_metadata is --%suite(ut_metadata) --%suitepath(utplsql.ut3_tester.core) From 77fc2b49bc288f5fd9523aa98ee76328adeb5769 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 16 Nov 2026 09:53:10 +0000 Subject: [PATCH 859/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index a28d2964e..c000845d3 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4620 +4624 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 13e11bca7..72318f2ea 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4620-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4624-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From f0f79c7924f56e7938ea3efcb1ca85cfc7e86d93 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Mon, 16 Nov 2026 20:56:24 +0900 Subject: [PATCH 860/887] Change filtering from a loop to SQL --- source/core/ut_metadata.pkb | 43 +++++++++++++++---------------------- 1 file changed, 17 insertions(+), 26 deletions(-) diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index 105a19387..2ab988665 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -77,34 +77,25 @@ create or replace noneditionable package body ut_metadata as if not nvl(c_key = g_cached_object, false) then g_cached_object := c_key; execute immediate - 'select /*+ no_parallel */ trim(text) text - from '||l_view_name||q'[ s - where s.owner = :a_owner - and s.name = :a_object_name - /*skip the declarations, consider only definitions*/ - and s.type not in ('PACKAGE', 'TYPE') - order by line]' + 'with v_source as ( + select /*+ no_parallel */ s.line + , nvl( + max(case when instr(s.text, chr(10)) > 0 then s.line else null end) + over (order by s.line rows between unbounded preceding and 1 preceding ) + , 0) + 1 first_line + , s.text + from '||l_view_name||q'[ s + where s.owner = :a_owner + and s.name = :a_object_name + /*skip the declarations, consider only definitions*/ + and s.type not in ('PACKAGE', 'TYPE') + order by s.line) + select trim(s.text) + from v_source s + where s.line = s.first_line + order by s.line]' bulk collect into g_source_cache using a_owner, a_object_name; - - declare - l_text all_source.text%type; - l_source t_cache; - begin - l_source := t_cache(); - for i in 1..g_source_cache.count loop - if l_text is null then - l_text := g_source_cache(i); - end if; - if instr(g_source_cache(i), chr(10)) > 0 then - l_source.extend; - l_source(l_source.count) := l_text; - l_text := null; - end if; - end loop; - - g_source_cache := l_source; - end; end if; if g_source_cache.exists(a_line_no) then From 9e84246f2d161a83577437f3ad970b5fe8921f92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Tue, 17 Nov 2026 00:21:36 +0900 Subject: [PATCH 861/887] add test script --- test/install_ut3_tester_tests.sql | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/install_ut3_tester_tests.sql b/test/install_ut3_tester_tests.sql index cc96b2b64..d4d5de265 100644 --- a/test/install_ut3_tester_tests.sql +++ b/test/install_ut3_tester_tests.sql @@ -25,6 +25,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core/test_file_mapper.pks @@ut3_tester/core/test_output_buffer.pks @@ut3_tester/core/test_suite_builder.pks +@@ut3_tester/core/test_ut_metadata.pks @@ut3_tester/core.pkb @@ -44,6 +45,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core/test_file_mapper.pkb @@ut3_tester/core/test_output_buffer.pkb @@ut3_tester/core/test_suite_builder.pkb +@@ut3_tester/core/test_ut_metadata.pkb From 280f8f2834c6a261d147cd6e827f93985cdc14cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Tue, 17 Nov 2026 00:38:44 +0900 Subject: [PATCH 862/887] update test code --- test/ut3_tester/core/test_ut_metadata.pkb | 44 +++++++++++++++-------- test/ut3_tester/core/test_ut_metadata.pks | 4 +-- 2 files changed, 31 insertions(+), 17 deletions(-) diff --git a/test/ut3_tester/core/test_ut_metadata.pkb b/test/ut3_tester/core/test_ut_metadata.pkb index 1d2a5a87b..1e8580cd7 100644 --- a/test/ut3_tester/core/test_ut_metadata.pkb +++ b/test/ut3_tester/core/test_ut_metadata.pkb @@ -1,43 +1,57 @@ create or replace package body test_ut_metadata is - procedure test_over_varchar2_limit + procedure test_over_varchar2_limit_trim_first_4000 is l_actual all_source.text%type; l_expect all_source.text%type; begin - l_expect := '/* [varcahr2 limit]*****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************[varcahr2 limit]'; - ut.expect(length(l_expect)).to_equal(4000); - l_actual := ut3_develop.ut_metadata.get_source_definition_line('ut3_tester', 'TEST_PACKAGE1', 5); - ut.expect(l_actual).to_equal(l_actual); - - l_expect := 'null;/* expect line */'; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('ut3_tester', 'TEST_PACKAGE1', 6); - ut.expect(l_actual).to_equal(l_actual); + l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||chr(10); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 15); + ut.expect(l_actual).to_equal(l_expect); end; procedure create_test_package is pragma autonomous_transaction; begin + execute immediate + 'create table test_table( + id number(10,0) + , value varchar2(4000) + )'; + execute immediate 'create or replace package test_package1 is - procedure sp_test; + --%suite(varchar2 limitation) + + --%test(test limitation) + procedure test_max_length; end;'; execute immediate - 'create or replace package body test_package1 is - procedure sp_test + q'[create or replace package body test_package1 is + procedure test_max_length is + l_actual varchar2(4000); + l_expect varchar2(4000); begin -/* [varcahr2 limit]*****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************[varcahr2 limit][over] */ - null;/* expect line */ + insert into test_table(id, value) values (1, substr(rpad('varchar2 limit text ACTUAL', 4000, '*'), 1, 4000)); + + select t.value + into l_actual + from test_table t + where t.id = 1; + + l_expect := 'varchar2 limit text*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************'; + ut.expect(l_actual).to_equal(l_expect); end; - end;'; + end;]'; end; procedure drop_test_package is pragma autonomous_transaction; begin execute immediate 'drop package test_package1'; + execute immediate 'drop table test_table'; end; end; / \ No newline at end of file diff --git a/test/ut3_tester/core/test_ut_metadata.pks b/test/ut3_tester/core/test_ut_metadata.pks index fe739c6aa..95c820abc 100644 --- a/test/ut3_tester/core/test_ut_metadata.pks +++ b/test/ut3_tester/core/test_ut_metadata.pks @@ -2,8 +2,8 @@ create or replace package test_ut_metadata is --%suite(ut_metadata) --%suitepath(utplsql.ut3_tester.core) - --%test(source line is over varchar2 limit) - procedure test_over_varchar2_limit; + --%test(source line over 4000 limit is trimmed to first 4000) + procedure test_over_varchar2_limit_trim_first_4000; --%beforeall procedure create_test_package; From fb673a6995033431a6b977b8aba81043fe90284c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Wed, 18 Nov 2026 00:41:58 +0900 Subject: [PATCH 863/887] Creating test code specify line break characters --- test/ut3_tester/core/test_ut_metadata.pkb | 189 +++++++++++++++++----- test/ut3_tester/core/test_ut_metadata.pks | 31 +++- 2 files changed, 180 insertions(+), 40 deletions(-) diff --git a/test/ut3_tester/core/test_ut_metadata.pkb b/test/ut3_tester/core/test_ut_metadata.pkb index 1e8580cd7..fe1416f5e 100644 --- a/test/ut3_tester/core/test_ut_metadata.pkb +++ b/test/ut3_tester/core/test_ut_metadata.pkb @@ -1,57 +1,174 @@ create or replace package body test_ut_metadata is - procedure test_over_varchar2_limit_trim_first_4000 + c_cr constant varchar2(1) := chr(13); + c_lf constant varchar2(2) := chr(10); + c_crlf constant varchar2(2) := chr(13)||chr(10); + + c_create_table constant varchar2(1000) := + 'create table test_table( + id number(10,0) + , value varchar2(4000) + )'; + + c_pks_lf constant varchar2(1000) := + 'create or replace package test_package_lf is'||c_lf + ||' --%suite(varchar2 limitation)'||c_lf + ||''||c_lf + ||' --%test(test limitation)'||c_lf + ||' procedure test_max_length;'||c_lf + ||'end;' + ; + c_pkg_lf constant varchar2(20000) := + q'[create or replace package body test_package_lf is]'||c_lf + ||q'[ procedure test_max_length]'||c_lf + ||q'[ is]'||c_lf + ||q'[ l_actual varchar2(4000);]'||c_lf + ||q'[ l_expect varchar2(4000);]'||c_lf + ||q'[ begin]'||c_lf + ||q'[ insert into test_table(id, value) values (1, substr(rpad('varchar2 limit text ACTUAL', 4000, '*'), 1, 4000));]'||c_lf + ||q'[]'||c_lf + ||q'[ select t.value]'||c_lf + ||q'[ into l_actual]'||c_lf + ||q'[ from test_table t]'||c_lf + ||q'[ where t.id = 1;]'||c_lf + ||q'[]'||c_lf + ||q'[ l_expect := 'varchar2 limit text*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************';]'||c_lf + ||q'[ ut.expect(l_actual).to_equal(l_expect);]'||c_lf + ||q'[ end;]'||c_lf + ||q'[ end;]' + ; + + c_pks_crlf constant varchar2(1000) := + 'create or replace package test_package_crlf is'||c_crlf + ||' --%suite(varchar2 limitation)'||c_crlf + ||''||c_crlf + ||' --%test(test limitation)'||c_crlf + ||' procedure test_max_length;'||c_crlf + ||'end;' + ; + c_pkg_crlf constant varchar2(20000) := + q'[create or replace package body test_package_crlf is]'||c_crlf + ||q'[ procedure test_max_length]'||c_crlf + ||q'[ is]'||c_crlf + ||q'[ l_actual varchar2(4000);]'||c_crlf + ||q'[ l_expect varchar2(4000);]'||c_crlf + ||q'[ begin]'||c_crlf + ||q'[ insert into test_table(id, value) values (1, substr(rpad('varchar2 limit text ACTUAL', 4000, '*'), 1, 4000));]'||c_crlf + ||q'[]'||c_crlf + ||q'[ select t.value]'||c_crlf + ||q'[ into l_actual]'||c_crlf + ||q'[ from test_table t]'||c_crlf + ||q'[ where t.id = 1;]'||c_crlf + ||q'[]'||c_crlf + ||q'[ l_expect := 'varchar2 limit text*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************';]'||c_crlf + ||q'[ ut.expect(l_actual).to_equal(l_expect);]'||c_crlf + ||q'[ end;]'||c_crlf + ||q'[ end;]' + ; + + c_pks_cr constant varchar2(1000) := + 'create or replace package test_package_cr is'||c_cr + ||' --%suite(varchar2 limitation)'||c_cr + ||''||c_cr + ||' --%test(test limitation)'||c_cr + ||' procedure test_max_length;'||c_cr + ||'end;' + ; + c_pkg_cr constant varchar2(20000) := + q'[create or replace package body test_package_cr is]'||c_cr + ||q'[ procedure test_max_length]'||c_cr + ||q'[ is]'||c_cr + ||q'[ l_actual varchar2(4000);]'||c_cr + ||q'[ l_expect varchar2(4000);]'||c_cr + ||q'[ begin]'||c_cr + ||q'[ insert into test_table(id, value) values (1, substr(rpad('varchar2 limit text ACTUAL', 4000, '*'), 1, 4000));]'||c_cr + ||q'[]'||c_cr + ||q'[ select t.value]'||c_cr + ||q'[ into l_actual]'||c_cr + ||q'[ from test_table t]'||c_cr + ||q'[ where t.id = 1;]'||c_cr + ||q'[]'||c_cr + ||q'[ l_expect := 'varchar2 limit text*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************';]'||c_cr + ||q'[ ut.expect(l_actual).to_equal(l_expect);]'||c_cr + ||q'[ end;]'||c_cr + ||q'[ end;]' + ; + + procedure test_over_varchar2_limit_trim_first_4000_lf is l_actual all_source.text%type; l_expect all_source.text%type; begin - l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||chr(10); - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 15); + l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_lf; + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE_LF', 15); ut.expect(l_actual).to_equal(l_expect); end; - procedure create_test_package is - pragma autonomous_transaction; + procedure test_over_varchar2_limit_trim_first_4000_crlf is + l_actual all_source.text%type; + l_expect all_source.text%type; begin - execute immediate - 'create table test_table( - id number(10,0) - , value varchar2(4000) - )'; - - execute immediate - 'create or replace package test_package1 is - --%suite(varchar2 limitation) + l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_crlf; + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE_CRLF', 15); + ut.expect(l_actual).to_equal(l_expect); + end; - --%test(test limitation) - procedure test_max_length; - end;'; + procedure test_over_varchar2_limit_trim_first_4000_cr + is + l_actual all_source.text%type; + l_expect all_source.text%type; + begin + l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_cr; + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE_LF', 15); + ut.expect(l_actual).to_equal(l_expect); + end; - execute immediate - q'[create or replace package body test_package1 is - procedure test_max_length - is - l_actual varchar2(4000); - l_expect varchar2(4000); - begin - insert into test_table(id, value) values (1, substr(rpad('varchar2 limit text ACTUAL', 4000, '*'), 1, 4000)); + procedure create_table is + pragma autonomous_transaction; + begin + execute immediate c_create_table; + end; + procedure drop_table is + pragma autonomous_transaction; + begin + execute immediate 'drop table test_table'; + end; - select t.value - into l_actual - from test_table t - where t.id = 1; + procedure create_test_package_lf is + pragma autonomous_transaction; + begin + execute immediate c_pks_lf; + execute immediate c_pkg_lf; + end; + procedure drop_test_package_lf is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_package_lf'; + end; - l_expect := 'varchar2 limit text*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************'; - ut.expect(l_actual).to_equal(l_expect); - end; - end;]'; + procedure create_test_package_crlf is + pragma autonomous_transaction; + begin + execute immediate c_pks_crlf; + execute immediate c_pkg_crlf; + end; + procedure drop_test_package_crlf is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_package_crlf'; end; - procedure drop_test_package is + procedure create_test_package_cr is pragma autonomous_transaction; begin - execute immediate 'drop package test_package1'; - execute immediate 'drop table test_table'; + execute immediate c_pks_cr; + execute immediate c_pkg_cr; end; + procedure drop_test_package_cr is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_package_cr'; + end; + end; / \ No newline at end of file diff --git a/test/ut3_tester/core/test_ut_metadata.pks b/test/ut3_tester/core/test_ut_metadata.pks index 95c820abc..a69a92b2c 100644 --- a/test/ut3_tester/core/test_ut_metadata.pks +++ b/test/ut3_tester/core/test_ut_metadata.pks @@ -2,12 +2,35 @@ create or replace package test_ut_metadata is --%suite(ut_metadata) --%suitepath(utplsql.ut3_tester.core) - --%test(source line over 4000 limit is trimmed to first 4000) - procedure test_over_varchar2_limit_trim_first_4000; + --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak lf]) + --%beforetest(create_test_package_lf) + --%aftertest(drop_test_package_lf) + procedure test_over_varchar2_limit_trim_first_4000_lf; + + --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak:crlf]) + --%beforetest(create_test_package_crlf) + --%aftertest(drop_test_package_crlf) + procedure test_over_varchar2_limit_trim_first_4000_crlf; + + --%disabled(PLS-00103 occurs when execute immediate CR package) + --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak cr]) + --%beforetest(create_test_package_cr) + --%aftertest(drop_test_package_cr) + procedure test_over_varchar2_limit_trim_first_4000_cr; --%beforeall - procedure create_test_package; + procedure create_table; --%afterall - procedure drop_test_package; + procedure drop_table; + + procedure create_test_package_lf; + procedure drop_test_package_lf; + + procedure create_test_package_crlf; + procedure drop_test_package_crlf; + + procedure create_test_package_cr; + procedure drop_test_package_cr; + end; / \ No newline at end of file From c70b17c6cd8738ce6db210b5c5a56e2dec08f093 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Thu, 19 Nov 2026 12:49:28 +0200 Subject: [PATCH 864/887] Update of bug report template --- .github/ISSUE_TEMPLATE/bug_report.md | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index b3e52a19a..77cbe1c25 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -13,20 +13,21 @@ A clear and concise description of what the bug is. **Provide version info** Information about utPLSQL and Database version, ```sql -set serveroutput on -declare - l_version varchar2(255); - l_compatibility varchar2(255); -begin - dbms_utility.db_version( l_version, l_compatibility ); - dbms_output.put_line( l_version ); - dbms_output.put_line( l_compatibility ); -end; -/ -select substr(ut.version(),1,60) as ut_version from dual; -select * from v$version; +with + function version_compatibility return varchar2 as + l_ver varchar2(100); + l_comp varchar2(100); + begin + dbms_utility.db_version(l_ver, l_comp); + return l_comp; + end; +select product, version, version_full, version_compatibility, + sys_context('userenv', 'current_edition_name') active_edition, + substr(dbms_utility.port_string,1,60) as cpu_type_and_os + from product_component_version; + select * from nls_session_parameters; -select substr(dbms_utility.port_string,1,60) as port_string from dual; + ``` **Information about client software** From 01a89eae1b359b858a41224327670e9b4d32bdc9 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Thu, 19 Nov 2026 11:55:11 +0000 Subject: [PATCH 865/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index c000845d3..4bb8b1814 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4624 +4629 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 72318f2ea..ad762d123 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4624-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4629-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 2ff22b40c660692822cc83b80c518b86c2065c0d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Thu, 19 Nov 2026 22:11:13 +0900 Subject: [PATCH 866/887] datatype %type -> varchar2(32767) --- test/ut3_tester/core/test_ut_metadata.pkb | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/test/ut3_tester/core/test_ut_metadata.pkb b/test/ut3_tester/core/test_ut_metadata.pkb index fe1416f5e..24eae2b9a 100644 --- a/test/ut3_tester/core/test_ut_metadata.pkb +++ b/test/ut3_tester/core/test_ut_metadata.pkb @@ -96,8 +96,8 @@ create or replace package body test_ut_metadata is procedure test_over_varchar2_limit_trim_first_4000_lf is - l_actual all_source.text%type; - l_expect all_source.text%type; + l_actual varchar2(32767); + l_expect varchar2(32767); begin l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_lf; l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE_LF', 15); @@ -105,8 +105,8 @@ create or replace package body test_ut_metadata is end; procedure test_over_varchar2_limit_trim_first_4000_crlf is - l_actual all_source.text%type; - l_expect all_source.text%type; + l_actual varchar2(32767); + l_expect varchar2(32767); begin l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_crlf; l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE_CRLF', 15); @@ -115,8 +115,8 @@ create or replace package body test_ut_metadata is procedure test_over_varchar2_limit_trim_first_4000_cr is - l_actual all_source.text%type; - l_expect all_source.text%type; + l_actual varchar2(32767); + l_expect varchar2(32767); begin l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_cr; l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE_LF', 15); From 9a366952e78a818b422c6d3e911b434517df04d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Thu, 19 Nov 2026 22:25:35 +0900 Subject: [PATCH 867/887] package, package body definition 3 times ->1 time and reuse --- test/ut3_tester/core/test_ut_metadata.pkb | 99 +++++------------------ test/ut3_tester/core/test_ut_metadata.pks | 10 +-- 2 files changed, 23 insertions(+), 86 deletions(-) diff --git a/test/ut3_tester/core/test_ut_metadata.pkb b/test/ut3_tester/core/test_ut_metadata.pkb index 24eae2b9a..f4d0058f3 100644 --- a/test/ut3_tester/core/test_ut_metadata.pkb +++ b/test/ut3_tester/core/test_ut_metadata.pkb @@ -11,7 +11,7 @@ create or replace package body test_ut_metadata is )'; c_pks_lf constant varchar2(1000) := - 'create or replace package test_package_lf is'||c_lf + 'create or replace package test_package1 is'||c_lf ||' --%suite(varchar2 limitation)'||c_lf ||''||c_lf ||' --%test(test limitation)'||c_lf @@ -19,7 +19,7 @@ create or replace package body test_ut_metadata is ||'end;' ; c_pkg_lf constant varchar2(20000) := - q'[create or replace package body test_package_lf is]'||c_lf + q'[create or replace package body test_package1 is]'||c_lf ||q'[ procedure test_max_length]'||c_lf ||q'[ is]'||c_lf ||q'[ l_actual varchar2(4000);]'||c_lf @@ -38,69 +38,13 @@ create or replace package body test_ut_metadata is ||q'[ end;]' ; - c_pks_crlf constant varchar2(1000) := - 'create or replace package test_package_crlf is'||c_crlf - ||' --%suite(varchar2 limitation)'||c_crlf - ||''||c_crlf - ||' --%test(test limitation)'||c_crlf - ||' procedure test_max_length;'||c_crlf - ||'end;' - ; - c_pkg_crlf constant varchar2(20000) := - q'[create or replace package body test_package_crlf is]'||c_crlf - ||q'[ procedure test_max_length]'||c_crlf - ||q'[ is]'||c_crlf - ||q'[ l_actual varchar2(4000);]'||c_crlf - ||q'[ l_expect varchar2(4000);]'||c_crlf - ||q'[ begin]'||c_crlf - ||q'[ insert into test_table(id, value) values (1, substr(rpad('varchar2 limit text ACTUAL', 4000, '*'), 1, 4000));]'||c_crlf - ||q'[]'||c_crlf - ||q'[ select t.value]'||c_crlf - ||q'[ into l_actual]'||c_crlf - ||q'[ from test_table t]'||c_crlf - ||q'[ where t.id = 1;]'||c_crlf - ||q'[]'||c_crlf - ||q'[ l_expect := 'varchar2 limit text*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************';]'||c_crlf - ||q'[ ut.expect(l_actual).to_equal(l_expect);]'||c_crlf - ||q'[ end;]'||c_crlf - ||q'[ end;]' - ; - - c_pks_cr constant varchar2(1000) := - 'create or replace package test_package_cr is'||c_cr - ||' --%suite(varchar2 limitation)'||c_cr - ||''||c_cr - ||' --%test(test limitation)'||c_cr - ||' procedure test_max_length;'||c_cr - ||'end;' - ; - c_pkg_cr constant varchar2(20000) := - q'[create or replace package body test_package_cr is]'||c_cr - ||q'[ procedure test_max_length]'||c_cr - ||q'[ is]'||c_cr - ||q'[ l_actual varchar2(4000);]'||c_cr - ||q'[ l_expect varchar2(4000);]'||c_cr - ||q'[ begin]'||c_cr - ||q'[ insert into test_table(id, value) values (1, substr(rpad('varchar2 limit text ACTUAL', 4000, '*'), 1, 4000));]'||c_cr - ||q'[]'||c_cr - ||q'[ select t.value]'||c_cr - ||q'[ into l_actual]'||c_cr - ||q'[ from test_table t]'||c_cr - ||q'[ where t.id = 1;]'||c_cr - ||q'[]'||c_cr - ||q'[ l_expect := 'varchar2 limit text*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************';]'||c_cr - ||q'[ ut.expect(l_actual).to_equal(l_expect);]'||c_cr - ||q'[ end;]'||c_cr - ||q'[ end;]' - ; - procedure test_over_varchar2_limit_trim_first_4000_lf is l_actual varchar2(32767); l_expect varchar2(32767); begin l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_lf; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE_LF', 15); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 15); ut.expect(l_actual).to_equal(l_expect); end; @@ -109,7 +53,7 @@ create or replace package body test_ut_metadata is l_expect varchar2(32767); begin l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_crlf; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE_CRLF', 15); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 15); ut.expect(l_actual).to_equal(l_expect); end; @@ -119,10 +63,15 @@ create or replace package body test_ut_metadata is l_expect varchar2(32767); begin l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_cr; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE_LF', 15); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 15); ut.expect(l_actual).to_equal(l_expect); end; + procedure clear_cache is + begin + ut3_develop.UT_METADATA.RESET_SOURCE_DEFINITION_CACHE(); + end; + procedure create_table is pragma autonomous_transaction; begin @@ -133,6 +82,11 @@ create or replace package body test_ut_metadata is begin execute immediate 'drop table test_table'; end; + procedure drop_test_package is + pragma autonomous_transaction; + begin + execute immediate 'drop package test_package1'; + end; procedure create_test_package_lf is pragma autonomous_transaction; @@ -140,34 +94,19 @@ create or replace package body test_ut_metadata is execute immediate c_pks_lf; execute immediate c_pkg_lf; end; - procedure drop_test_package_lf is - pragma autonomous_transaction; - begin - execute immediate 'drop package test_package_lf'; - end; procedure create_test_package_crlf is pragma autonomous_transaction; begin - execute immediate c_pks_crlf; - execute immediate c_pkg_crlf; - end; - procedure drop_test_package_crlf is - pragma autonomous_transaction; - begin - execute immediate 'drop package test_package_crlf'; + execute immediate replace(c_pks_lf, c_lf, c_crlf); + execute immediate replace(c_pkg_lf, c_lf, c_crlf); end; procedure create_test_package_cr is pragma autonomous_transaction; begin - execute immediate c_pks_cr; - execute immediate c_pkg_cr; - end; - procedure drop_test_package_cr is - pragma autonomous_transaction; - begin - execute immediate 'drop package test_package_cr'; + execute immediate replace(c_pks_lf, c_lf, c_cr); + execute immediate replace(c_pkg_lf, c_lf, c_cr); end; end; diff --git a/test/ut3_tester/core/test_ut_metadata.pks b/test/ut3_tester/core/test_ut_metadata.pks index a69a92b2c..346f0634e 100644 --- a/test/ut3_tester/core/test_ut_metadata.pks +++ b/test/ut3_tester/core/test_ut_metadata.pks @@ -4,33 +4,31 @@ create or replace package test_ut_metadata is --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak lf]) --%beforetest(create_test_package_lf) - --%aftertest(drop_test_package_lf) procedure test_over_varchar2_limit_trim_first_4000_lf; --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak:crlf]) --%beforetest(create_test_package_crlf) - --%aftertest(drop_test_package_crlf) procedure test_over_varchar2_limit_trim_first_4000_crlf; --%disabled(PLS-00103 occurs when execute immediate CR package) --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak cr]) --%beforetest(create_test_package_cr) - --%aftertest(drop_test_package_cr) procedure test_over_varchar2_limit_trim_first_4000_cr; --%beforeall procedure create_table; --%afterall procedure drop_table; + --%beforeeach + procedure clear_cache; + --%aftereach + procedure drop_test_package; procedure create_test_package_lf; - procedure drop_test_package_lf; procedure create_test_package_crlf; - procedure drop_test_package_crlf; procedure create_test_package_cr; - procedure drop_test_package_cr; end; / \ No newline at end of file From 25803d9e5f9f1fcc6e5f5ed19733004d05075e24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Fri, 20 Nov 2026 20:45:45 +0900 Subject: [PATCH 868/887] window function max -> lag query formatting --- source/core/ut_metadata.pkb | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index 2ab988665..ab523a01c 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -77,22 +77,23 @@ create or replace noneditionable package body ut_metadata as if not nvl(c_key = g_cached_object, false) then g_cached_object := c_key; execute immediate - 'with v_source as ( - select /*+ no_parallel */ s.line - , nvl( - max(case when instr(s.text, chr(10)) > 0 then s.line else null end) - over (order by s.line rows between unbounded preceding and 1 preceding ) - , 0) + 1 first_line - , s.text - from '||l_view_name||q'[ s - where s.owner = :a_owner - and s.name = :a_object_name - /*skip the declarations, consider only definitions*/ - and s.type not in ('PACKAGE', 'TYPE') - order by s.line) + 'with + all_source_filter as ( + select /*+ no_parallel */ + lag( + case when substr(text, -1) = chr(10) then 1 else 0 end + , 1 + ) over (partition by owner, name, type order by line) prev_line_end, + a.* + from '||l_view_name||q'[ a + ) select trim(s.text) - from v_source s - where s.line = s.first_line + from all_source_filter s + where s.owner = :a_owner + and s.name = :a_object_name + /*skip the declarations, consider only definitions*/ + and s.type not in ('PACKAGE', 'TYPE') + and nvl(s.prev_line_end, 1) > 0 order by s.line]' bulk collect into g_source_cache using a_owner, a_object_name; From 1806e5a551c0b62a9989c93148b344ca16a2e95c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Fri, 27 Nov 2026 20:11:45 +0900 Subject: [PATCH 869/887] change to lowercase --- test/ut3_tester/core/test_ut_metadata.pkb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ut3_tester/core/test_ut_metadata.pkb b/test/ut3_tester/core/test_ut_metadata.pkb index f4d0058f3..aa9f846f4 100644 --- a/test/ut3_tester/core/test_ut_metadata.pkb +++ b/test/ut3_tester/core/test_ut_metadata.pkb @@ -69,7 +69,7 @@ create or replace package body test_ut_metadata is procedure clear_cache is begin - ut3_develop.UT_METADATA.RESET_SOURCE_DEFINITION_CACHE(); + ut3_develop.ut_metadata.reset_source_definition_cache(); end; procedure create_table is From 34ac108df1b821e9acb75faac013270d5dd9e92e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Fri, 27 Nov 2026 20:27:51 +0900 Subject: [PATCH 870/887] move owner/name/type filter inside with clause --- source/core/ut_metadata.pkb | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/source/core/ut_metadata.pkb b/source/core/ut_metadata.pkb index ab523a01c..ed8391638 100644 --- a/source/core/ut_metadata.pkb +++ b/source/core/ut_metadata.pkb @@ -84,16 +84,16 @@ create or replace noneditionable package body ut_metadata as case when substr(text, -1) = chr(10) then 1 else 0 end , 1 ) over (partition by owner, name, type order by line) prev_line_end, - a.* + line, text from '||l_view_name||q'[ a + where a.owner = :a_owner + and a.name = :a_object_name + /*skip the declarations, consider only definitions*/ + and a.type not in ('PACKAGE', 'TYPE') ) select trim(s.text) from all_source_filter s - where s.owner = :a_owner - and s.name = :a_object_name - /*skip the declarations, consider only definitions*/ - and s.type not in ('PACKAGE', 'TYPE') - and nvl(s.prev_line_end, 1) > 0 + where nvl(s.prev_line_end, 1) > 0 order by s.line]' bulk collect into g_source_cache using a_owner, a_object_name; From 881ecd92fec96694e72d41fc5e21b3597a9f1773 Mon Sep 17 00:00:00 2001 From: vasipallyn <207942208+vasipallyn@users.noreply.github.com> Date: Fri, 27 Nov 2026 22:18:40 +0000 Subject: [PATCH 871/887] Truncate long source lines in expectation caller info A failing expectation on a source line close to 4000 bytes raised ORA-06502 in ut_expectation_processor.who_called_expectation, so the test ended as errored instead of failed. The source line shown after the caller is now cut to 500 characters (ending with [...]), and the whole caller info is limited to 4000 bytes. Resolves #1397 --- source/core/ut_expectation_processor.pkb | 20 ++++-- .../test_expectation_processor.pkb | 66 +++++++++++++++++++ .../test_expectation_processor.pks | 16 +++++ 3 files changed, 97 insertions(+), 5 deletions(-) diff --git a/source/core/ut_expectation_processor.pkb b/source/core/ut_expectation_processor.pkb index 8876cbb30..e95576d8e 100644 --- a/source/core/ut_expectation_processor.pkb +++ b/source/core/ut_expectation_processor.pkb @@ -149,12 +149,14 @@ create or replace noneditionable package body ut_expectation_processor as end; function who_called_expectation(a_call_stack varchar2) return varchar2 is - l_caller_stack_line varchar2(4000); - l_call_stack varchar2(4000); + c_max_source_line_len constant integer := 500; + l_caller_stack_line varchar2(32767); + l_call_stack varchar2(32767); l_line_no integer; l_owner varchar2(1000); l_object_name varchar2(1000); - l_result varchar2(4000); + l_source_line varchar2(32767); + l_result varchar2(32767); -- format_call_stack reports not only package name, but also the procedure name function cut_header_and_expectations( a_stack varchar2 ) return varchar2 is begin @@ -191,13 +193,21 @@ create or replace noneditionable package body ut_expectation_processor as l_line_no := to_number( regexp_substr( l_caller_stack_line, ', line (\d+)', subexpression => 1 ) ); l_owner := regexp_substr( l_caller_stack_line, 'at "([[:alnum:]$#_]+)\.(([[:alnum:]$#_]+)(\.([[:alnum:]$#_]+))?)", line (\d+)', subexpression => 1 ); l_object_name := regexp_substr( l_caller_stack_line, 'at "([[:alnum:]$#_]+)\.(([[:alnum:]$#_]+)(\.([[:alnum:]$#_]+))?)", line (\d+)', subexpression => 3 ); + l_source_line := rtrim(ut_metadata.get_source_definition_line(l_owner, l_object_name, l_line_no),chr(10)); + if length( l_source_line ) > c_max_source_line_len then + l_source_line := substr( l_source_line, 1, c_max_source_line_len - ut_utils.gc_more_data_string_len ) || ut_utils.gc_more_data_string; + end if; l_result := - l_caller_stack_line || ' ' || rtrim(ut_metadata.get_source_definition_line(l_owner, l_object_name, l_line_no),chr(10)) + l_caller_stack_line || ' ' || l_source_line || replace( l_call_stack, l_caller_stack_line ); else l_result := l_call_stack; end if; - return rtrim(l_result,chr(10)); + l_result := rtrim(l_result,chr(10)); + if lengthb( l_result ) > ut_utils.gc_max_storage_varchar2_len then + l_result := substrb( l_result, 1, ut_utils.gc_max_storage_varchar2_len - ut_utils.gc_more_data_string_len ) || ut_utils.gc_more_data_string; + end if; + return l_result; end; procedure add_warning(a_messsage varchar2) is diff --git a/test/ut3_tester/core/expectations/test_expectation_processor.pkb b/test/ut3_tester/core/expectations/test_expectation_processor.pkb index 63ce3c791..b1df80fd2 100644 --- a/test/ut3_tester/core/expectations/test_expectation_processor.pkb +++ b/test/ut3_tester/core/expectations/test_expectation_processor.pkb @@ -1,6 +1,8 @@ create or replace package body test_expectation_processor is gc_user constant varchar2(128) := sys_context('userenv','current_schema'); + gc_long_line_package constant varchar2(128) := 'TEST_EXPECTATION_LONG_LINE'; + gc_long_line constant varchar2(4000) := 'ut.expect(1).to_equal(2); /*'||rpad('*', 3900, '*')||'*/'; procedure who_called_expectation is l_stack_trace varchar2(4000); @@ -101,5 +103,69 @@ handle number name ).to_be_like('at "SCOTT.TEST_BETWNSTR.BASIC_USAGE", line 7 %'); end; + procedure create_long_line_package is + begin + execute immediate 'create or replace package '||gc_long_line_package||' is + procedure long_line; +end;'; + execute immediate 'create or replace package body '||gc_long_line_package||' is + procedure long_line is + begin + '||gc_long_line||' + end; +end;'; + end; + + procedure drop_long_line_package is + begin + execute immediate 'drop package '||gc_long_line_package; + end; + + procedure who_called_exp_long_line is + l_stack_trace varchar2(4000); + l_result varchar2(32767); + begin + l_stack_trace := q'[----- PL/SQL Call Stack ----- + object line object + handle number name +0x80e701d8 26 UT3_DEVELOP.UT_EXPECTATION_RESULT +0x85e10150 112 UT3_DEVELOP.UT_EXPECTATION +0x8b54bad8 21 UT3_DEVELOP.UT_EXPECTATION_NUMBER +0x85cfd238 4 package body ]'||gc_user||'.'||gc_long_line_package||q'[ +0x85def380 6 anonymous block +]'; + l_result := ut3_develop.ut_expectation_processor.who_called_expectation(l_stack_trace); + + ut.expect( l_result ).to_equal( + 'at "'||gc_user||'.'||gc_long_line_package||'", line 4 ' + || substr( gc_long_line, 1, 500 - length('[...]') ) || '[...]' + || chr(10) || 'at "anonymous block", line 6' + ); + end; + + procedure who_called_exp_long_stack is + l_stack_trace varchar2(32767); + l_result varchar2(32767); + begin + l_stack_trace := q'[----- PL/SQL Call Stack ----- + object line object + handle number name +0x80e701d8 26 UT3_DEVELOP.UT_EXPECTATION_RESULT +0x85e10150 112 UT3_DEVELOP.UT_EXPECTATION +0x8b54bad8 21 UT3_DEVELOP.UT_EXPECTATION_NUMBER +0x85cfd238 4 package body ]'||gc_user||'.'||gc_long_line_package||chr(10); + -- distinct callers, so the stack after the first frame is long + for i in 1 .. 100 loop + l_stack_trace := l_stack_trace + || '0x85cfd238 '||to_char(1000 + i)||' package body '||gc_user||'.'||gc_long_line_package||chr(10); + end loop; + + l_result := ut3_develop.ut_expectation_processor.who_called_expectation(l_stack_trace); + + ut.expect( lengthb( l_result ) ).to_be_less_or_equal( 4000 ); + ut.expect( l_result ).to_be_like( 'at "'||gc_user||'.'||gc_long_line_package||'", line 4 ut.expect(1).to_equal(2); /*%' ); + ut.expect( l_result ).to_be_like( '%[...]' ); + end; + end; / diff --git a/test/ut3_tester/core/expectations/test_expectation_processor.pks b/test/ut3_tester/core/expectations/test_expectation_processor.pks index 6087eb045..4797dd613 100644 --- a/test/ut3_tester/core/expectations/test_expectation_processor.pks +++ b/test/ut3_tester/core/expectations/test_expectation_processor.pks @@ -19,5 +19,21 @@ create or replace package test_expectation_processor is --%endcontext + --%context(who_called_expectation_long_lines) + + --%beforeall + procedure create_long_line_package; + + --%afterall + procedure drop_long_line_package; + + --%test(truncates a long source line of the calling code - regression for #1397) + procedure who_called_exp_long_line; + + --%test(limits caller info to 4000 bytes when the call stack is long - regression for #1397) + procedure who_called_exp_long_stack; + + --%endcontext + end; / From 66e319f456a5e0be7c8e8586360c98e566c0bacf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Sat, 28 Nov 2026 21:18:54 +0900 Subject: [PATCH 872/887] updating tests. remove annotations( --%suite, --%test. add context. --- test/ut3_tester/core/test_ut_metadata.pkb | 33 +++--------------- test/ut3_tester/core/test_ut_metadata.pks | 42 +++++++++++------------ 2 files changed, 25 insertions(+), 50 deletions(-) diff --git a/test/ut3_tester/core/test_ut_metadata.pkb b/test/ut3_tester/core/test_ut_metadata.pkb index aa9f846f4..bdfae2ff7 100644 --- a/test/ut3_tester/core/test_ut_metadata.pkb +++ b/test/ut3_tester/core/test_ut_metadata.pkb @@ -4,17 +4,9 @@ create or replace package body test_ut_metadata is c_lf constant varchar2(2) := chr(10); c_crlf constant varchar2(2) := chr(13)||chr(10); - c_create_table constant varchar2(1000) := - 'create table test_table( - id number(10,0) - , value varchar2(4000) - )'; - c_pks_lf constant varchar2(1000) := 'create or replace package test_package1 is'||c_lf - ||' --%suite(varchar2 limitation)'||c_lf ||''||c_lf - ||' --%test(test limitation)'||c_lf ||' procedure test_max_length;'||c_lf ||'end;' ; @@ -25,14 +17,7 @@ create or replace package body test_ut_metadata is ||q'[ l_actual varchar2(4000);]'||c_lf ||q'[ l_expect varchar2(4000);]'||c_lf ||q'[ begin]'||c_lf - ||q'[ insert into test_table(id, value) values (1, substr(rpad('varchar2 limit text ACTUAL', 4000, '*'), 1, 4000));]'||c_lf - ||q'[]'||c_lf - ||q'[ select t.value]'||c_lf - ||q'[ into l_actual]'||c_lf - ||q'[ from test_table t]'||c_lf - ||q'[ where t.id = 1;]'||c_lf - ||q'[]'||c_lf - ||q'[ l_expect := 'varchar2 limit text*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************';]'||c_lf + ||q'[ l_expect := 'varchar2 limit text]'||rpad('*', 4000, '*')||q'[';]'||c_lf ||q'[ ut.expect(l_actual).to_equal(l_expect);]'||c_lf ||q'[ end;]'||c_lf ||q'[ end;]' @@ -44,7 +29,7 @@ create or replace package body test_ut_metadata is l_expect varchar2(32767); begin l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_lf; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 15); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 8); ut.expect(l_actual).to_equal(l_expect); end; @@ -53,7 +38,7 @@ create or replace package body test_ut_metadata is l_expect varchar2(32767); begin l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_crlf; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 15); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 8); ut.expect(l_actual).to_equal(l_expect); end; @@ -63,7 +48,7 @@ create or replace package body test_ut_metadata is l_expect varchar2(32767); begin l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_cr; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 15); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 8); ut.expect(l_actual).to_equal(l_expect); end; @@ -72,16 +57,6 @@ create or replace package body test_ut_metadata is ut3_develop.ut_metadata.reset_source_definition_cache(); end; - procedure create_table is - pragma autonomous_transaction; - begin - execute immediate c_create_table; - end; - procedure drop_table is - pragma autonomous_transaction; - begin - execute immediate 'drop table test_table'; - end; procedure drop_test_package is pragma autonomous_transaction; begin diff --git a/test/ut3_tester/core/test_ut_metadata.pks b/test/ut3_tester/core/test_ut_metadata.pks index 346f0634e..b4a1d601c 100644 --- a/test/ut3_tester/core/test_ut_metadata.pks +++ b/test/ut3_tester/core/test_ut_metadata.pks @@ -2,33 +2,33 @@ create or replace package test_ut_metadata is --%suite(ut_metadata) --%suitepath(utplsql.ut3_tester.core) - --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak lf]) - --%beforetest(create_test_package_lf) - procedure test_over_varchar2_limit_trim_first_4000_lf; + --%context(get_source_definition_line) - --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak:crlf]) - --%beforetest(create_test_package_crlf) - procedure test_over_varchar2_limit_trim_first_4000_crlf; + --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak lf]) + --%beforetest(create_test_package_lf) + procedure test_over_varchar2_limit_trim_first_4000_lf; - --%disabled(PLS-00103 occurs when execute immediate CR package) - --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak cr]) - --%beforetest(create_test_package_cr) - procedure test_over_varchar2_limit_trim_first_4000_cr; + --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak:crlf]) + --%beforetest(create_test_package_crlf) + procedure test_over_varchar2_limit_trim_first_4000_crlf; - --%beforeall - procedure create_table; - --%afterall - procedure drop_table; - --%beforeeach - procedure clear_cache; - --%aftereach - procedure drop_test_package; + --%disabled(PLS-00103 occurs when execute immediate CR package) + --%test(source line over 4000 limit is trimmed to first 4000 [linebreeak cr]) + --%beforetest(create_test_package_cr) + procedure test_over_varchar2_limit_trim_first_4000_cr; - procedure create_test_package_lf; + --%beforeeach + procedure clear_cache; + --%aftereach + procedure drop_test_package; - procedure create_test_package_crlf; + procedure create_test_package_lf; - procedure create_test_package_cr; + procedure create_test_package_crlf; + + procedure create_test_package_cr; + + --%endcontext end; / \ No newline at end of file From 735dc3dcebd9e6e2083ac366095114e41b21509e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9F=B3=E6=A9=8B=E3=80=80=E5=AF=9B=E6=98=AD?= <66629597+monookenai@users.noreply.github.com> Date: Sat, 28 Nov 2026 21:54:33 +0900 Subject: [PATCH 873/887] update test. generate long text using rpad. --- test/ut3_tester/core/test_ut_metadata.pkb | 45 +++++++++++++++++------ 1 file changed, 33 insertions(+), 12 deletions(-) diff --git a/test/ut3_tester/core/test_ut_metadata.pkb b/test/ut3_tester/core/test_ut_metadata.pkb index bdfae2ff7..905f31081 100644 --- a/test/ut3_tester/core/test_ut_metadata.pkb +++ b/test/ut3_tester/core/test_ut_metadata.pkb @@ -6,19 +6,16 @@ create or replace package body test_ut_metadata is c_pks_lf constant varchar2(1000) := 'create or replace package test_package1 is'||c_lf - ||''||c_lf ||' procedure test_max_length;'||c_lf ||'end;' ; c_pkg_lf constant varchar2(20000) := q'[create or replace package body test_package1 is]'||c_lf - ||q'[ procedure test_max_length]'||c_lf - ||q'[ is]'||c_lf - ||q'[ l_actual varchar2(4000);]'||c_lf - ||q'[ l_expect varchar2(4000);]'||c_lf + ||q'[ procedure test_max_length is]'||c_lf ||q'[ begin]'||c_lf - ||q'[ l_expect := 'varchar2 limit text]'||rpad('*', 4000, '*')||q'[';]'||c_lf - ||q'[ ut.expect(l_actual).to_equal(l_expect);]'||c_lf + ||q'[ /* long comment over 4000 characters 1]'||rpad('*', 8000, '*')||'*/'||c_lf + ||substrb(q'[ /* long comment 3999 and linebreak]'||rpad('*', 4000, '*'), 1, 3997)||'*/'||c_lf + ||q'[ dbms_output.put_line('test_max_length called.');]'||c_lf ||q'[ end;]'||c_lf ||q'[ end;]' ; @@ -28,8 +25,16 @@ create or replace package body test_ut_metadata is l_actual varchar2(32767); l_expect varchar2(32767); begin - l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_lf; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 8); + l_expect := trim(substrb(q'[ /* long comment over 4000 characters 1]'||rpad('*', 8000, '*')||'*/'||c_lf, 1, 4000)); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 4); + ut.expect(l_actual).to_equal(l_expect); + + l_expect := trim(substrb(q'[ /* long comment 3999 and linebreak]'||rpad('*', 4000, '*'), 1, 3997)||'*/'||c_lf); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 5); + ut.expect(l_actual).to_equal(l_expect); + + l_expect := 'dbms_output.put_line(''test_max_length called.'');'||c_lf; + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 6); ut.expect(l_actual).to_equal(l_expect); end; @@ -37,8 +42,16 @@ create or replace package body test_ut_metadata is l_actual varchar2(32767); l_expect varchar2(32767); begin - l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_crlf; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 8); + l_expect := trim(substrb(q'[ /* long comment over 4000 characters 1]'||rpad('*', 8000, '*')||'*/'||c_crlf, 1, 4000)); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 4); + ut.expect(l_actual).to_equal(l_expect); + + l_expect := trim(substrb(q'[ /* long comment 3999 and linebreak]'||rpad('*', 4000, '*'), 1, 3997)||'*/'||c_cr); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 5); + ut.expect(l_actual).to_equal(l_expect); + + l_expect := 'dbms_output.put_line(''test_max_length called.'');'||c_crlf; + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 6); ut.expect(l_actual).to_equal(l_expect); end; @@ -47,8 +60,16 @@ create or replace package body test_ut_metadata is l_actual varchar2(32767); l_expect varchar2(32767); begin + l_expect := trim(substrb(q'[ /* long comment over 4000 characters 1]'||rpad('*', 8000, '*')||'*/'||c_cr, 1, 4000)); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 4); + ut.expect(l_actual).to_equal(l_expect); + + l_expect := trim(substrb(q'[ /* long comment 3999 and linebreak]'||rpad('*', 4000, '*'), 1, 3997)||'*/'||c_cr); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 5); + ut.expect(l_actual).to_equal(l_expect); + l_expect := 'ut.expect(l_actual).to_equal(l_expect);'||c_cr; - l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 8); + l_actual := ut3_develop.ut_metadata.get_source_definition_line('UT3_TESTER', 'TEST_PACKAGE1', 6); ut.expect(l_actual).to_equal(l_expect); end; From 3a3acdc1ce5a57c0d25a100da6f68f140089ffed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Sun, 29 Nov 2026 00:53:03 +0200 Subject: [PATCH 874/887] Change pipeline to allow PR builds from forks. --- .github/workflows/build.yml | 46 ++++++++++++++++++++----------------- 1 file changed, 25 insertions(+), 21 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 046d9f964..f97880a48 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -23,25 +23,26 @@ defaults: jobs: build: - name: Build and test on ${{matrix.db_version_name}} DB + name: Build and test on ${{matrix.db.db_version_name}} DB runs-on: ubuntu-latest timeout-minutes: 90 env: - ORACLE_VERSION: ${{matrix.oracle-version}} - ORACLE_SID: ${{matrix.oracle-sid}} - CONNECTION_STR: ${{ format( '127.0.0.1:1521/{0}', matrix.oracle-sid ) }} + ORACLE_VERSION: ${{matrix.db.oracle-version}} + ORACLE_SID: ${{matrix.db.oracle-sid}} + CONNECTION_STR: ${{ format( '127.0.0.1:1521/{0}', matrix.db.oracle-sid ) }} ORACLE_PASSWORD: oracle - DOCKER_VOLUME: ${{matrix.docker-volume}} + DOCKER_VOLUME: ${{matrix.db.docker-volume}} + HAS_SONAR_TOKEN: ${{ secrets.SONAR_TOKEN != '' }} strategy: fail-fast: false matrix: - include: + # The DB versions are values of a matrix key, not `include` entries, because `exclude` can't remove `include` entries. + db: - id: 1 db_version_name: '19.20-ee' oracle-sid: 'UTPLSQL' oracle-version: "utplsqlv3/oracledb:19.20-utplsql" - check-coding-style: true - validate-utplsql-uninstall: true + run-sonar-scanner: true - id: 2 db_version_name: '21XE' oracle-sid: 'XE' @@ -51,19 +52,22 @@ jobs: oracle-sid: 'FREEPDB1' oracle-version: "gvenzl/oracle-free:23-slim-faststart" fips-enabled: true - run-sonar-scanner: true + check-coding-style: true + validate-utplsql-uninstall: true + exclude: + # Pull requests from forks can't access secrets, so they can't pull the private utplsqlv3 19.20-ee image. + - db: + id: ${{ github.event.pull_request.head.repo.fork == true && 1 || 0 }} services: html_checker: image: ghcr.io/validator/validator:latest options: >- -p 8888:8888 oracle: - image: ${{matrix.oracle-version}} + image: ${{matrix.db.oracle-version}} env: ORACLE_PASSWORD: oracle - credentials: - username: ${{ secrets.DOCKER_USER }} - password: ${{ secrets.DOCKER_PASSWORD }} + credentials: ${{ secrets.DOCKER_USER && fromJSON( format( '{{"username":"{0}","password":"{1}"}}', secrets.DOCKER_USER, secrets.DOCKER_PASSWORD ) ) || fromJSON( '{}' ) }} volumes: - ${{github.workspace}}:/utPLSQL ports: @@ -98,7 +102,7 @@ jobs: - name: Enable FIPS 140 on Oracle DB id: enable-fips - if: ${{ matrix.fips-enabled == true }} + if: ${{ matrix.db.fips-enabled == true }} run: | docker exec oracle bash -c " echo \"ALTER SYSTEM SET DBFIPS_140=TRUE SCOPE=SPFILE; @@ -141,17 +145,17 @@ jobs: run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install.sh - name: Check code style - if: ${{ matrix.check-style == true }} + if: ${{ matrix.db.check-coding-style == true }} id: check-coding-style run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle "$SQLCLI" ${UT3_DEVELOP_SCHEMA}/${UT3_DEVELOP_SCHEMA_PASSWORD}@//${CONNECTION_STR} @/utPLSQL/development/utplsql_style_check.sql - name: Validate utPLSQL uninstall - if: ${{ matrix.validate-utplsql-uninstall == true }} + if: ${{ matrix.db.validate-utplsql-uninstall == true }} id: validate-uninstall run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/uninstall_validate_utplsql.sh - name: Reinstall utPLSQL - if: ${{ matrix.validate-utplsql-uninstall == true }} + if: ${{ matrix.db.validate-utplsql-uninstall == true }} id: reinstall-utplsql run: docker exec -w /utPLSQL ${DOCKER_ENV} oracle .github/scripts/install.sh @@ -191,7 +195,7 @@ jobs: if: ${{ always() && steps.run-tests.outcome == 'failure' }} uses: actions/upload-artifact@v4 with: - name: my-artifact$-${{matrix.db_version_name}} + name: my-artifact$-${{matrix.db.db_version_name}} path: ${{github.workspace}}/database-diag #End Needed to diagnose occasional failures of DB on test runs @@ -204,7 +208,7 @@ jobs: with: token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos files: ./cobertura.xml - flags: ${{matrix.db_version_name}} + flags: ${{matrix.db.db_version_name}} fail_ci_if_error: true # optional (default = false) - name: Publish unit test results @@ -215,14 +219,14 @@ jobs: - name: SonarCloud Scan id: sonar - if: ${{ always() && matrix.run-sonar-scanner == true }} + if: ${{ always() && matrix.db.run-sonar-scanner == true && env.HAS_SONAR_TOKEN == 'true' }} uses: SonarSource/sonarqube-scan-action@master env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} with: args: > - -Dsonar.buildString=${{ format( '{0}.{1}', env.UTPLSQL_BUILD_VERSION, matrix.id ) }} + -Dsonar.buildString=${{ format( '{0}.{1}', env.UTPLSQL_BUILD_VERSION, matrix.db.id ) }} -Dsonar.plsql.jdbc.url=${{ format( 'jdbc:oracle:thin:@//localhost:1521/{0}', env.ORACLE_SID ) }} -Dsonar.plsql.jdbc.driver.path=${{ format( '{0}/ojdbc8.jar', env.OJDBC_HOME ) }} From 1a189ca5811161488b3fe3263777e5944180e286 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 28 Nov 2026 23:10:48 +0000 Subject: [PATCH 875/887] Updated project version after build [skip ci] --- BUILD_NO | 2 +- source/core/ut_utils.pks | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILD_NO b/BUILD_NO index 4bb8b1814..209cee314 100644 --- a/BUILD_NO +++ b/BUILD_NO @@ -1 +1 @@ -4629 +4647 diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index ad762d123..1bb353806 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -21,7 +21,7 @@ create or replace noneditionable package ut_utils authid definer is * */ - gc_version constant varchar2(50) := 'v3.2.4.4629-develop'; + gc_version constant varchar2(50) := 'v3.2.4.4647-develop'; subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; From 7e61d2fb9280dfba868190b2f1577d4f1ba25974 Mon Sep 17 00:00:00 2001 From: vasipallyn <207942208+vasipallyn@users.noreply.github.com> Date: Mon, 30 Nov 2026 12:41:17 +0000 Subject: [PATCH 876/887] Run long-line test fixture DDL as autonomous transactions The DDL in create_long_line_package and drop_long_line_package committed the runner transaction and removed its savepoints, so the automatic rollback after the tests logged a warning even when they passed. --- .../ut3_tester/core/expectations/test_expectation_processor.pkb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/ut3_tester/core/expectations/test_expectation_processor.pkb b/test/ut3_tester/core/expectations/test_expectation_processor.pkb index b1df80fd2..6af3a7e74 100644 --- a/test/ut3_tester/core/expectations/test_expectation_processor.pkb +++ b/test/ut3_tester/core/expectations/test_expectation_processor.pkb @@ -104,6 +104,7 @@ handle number name end; procedure create_long_line_package is + pragma autonomous_transaction; begin execute immediate 'create or replace package '||gc_long_line_package||' is procedure long_line; @@ -117,6 +118,7 @@ end;'; end; procedure drop_long_line_package is + pragma autonomous_transaction; begin execute immediate 'drop package '||gc_long_line_package; end; From bd24025949f2b2df03e558de102ae0d8bb4108ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacek=20G=C4=99bal?= Date: Tue, 1 Dec 2026 14:24:31 +0200 Subject: [PATCH 877/887] Show utPLSQL support line in human-readable reports The documentation reporter ends its output with a one-line link to utPLSQL commercial support and sponsorship (https://utplsql.org/support), the TAP reporter prints the same line as a trailing comment, and the HTML coverage report shows it as a link in its footer. Machine-readable reporters don't include it. The line can be switched off with the new a_support_info parameter of ut.run (boolean for procedures, 0/1 for functions) and ut_runner.run. The setting is carried to reporters by ut_run.support_info_flag. --- docs/userguide/reporters.md | 11 +++ docs/userguide/running-unit-tests.md | 17 ++++ source/api/ut.pkb | 87 ++++++++++++------- source/api/ut.pks | 36 +++++--- source/api/ut_runner.pkb | 6 +- source/api/ut_runner.pks | 4 +- source/core/types/ut_run.tpb | 9 +- source/core/types/ut_run.tps | 5 +- source/core/ut_utils.pks | 5 +- .../reporters/ut_coverage_html_reporter.tpb | 3 +- .../ut_coverage_report_html_helper.pkb | 10 ++- .../ut_coverage_report_html_helper.pks | 3 +- .../reporters/ut_documentation_reporter.tpb | 3 + source/reporters/ut_tap_reporter.tpb | 3 + test/install_ut3_tester_tests.sql | 2 + .../core/test_coverage_report_html_helper.pkb | 29 +++++++ .../core/test_coverage_report_html_helper.pks | 13 +++ test/ut3_tester/core/test_suite_manager.pkb | 2 +- test/ut3_user/api/test_ut_run.pkb | 32 +++++++ test/ut3_user/api/test_ut_run.pks | 20 +++++ test/ut3_user/reporters.pks | 2 + .../test_html_coverage_reporter.pkb | 20 +++++ .../test_html_coverage_reporter.pks | 3 + .../reporters/test_documentation_reporter.pkb | 24 ++++- .../reporters/test_documentation_reporter.pks | 6 ++ test/ut3_user/reporters/test_tap_reporter.pkb | 20 +++++ test/ut3_user/reporters/test_tap_reporter.pks | 6 ++ 27 files changed, 327 insertions(+), 54 deletions(-) create mode 100644 test/ut3_tester/core/test_coverage_report_html_helper.pkb create mode 100644 test/ut3_tester/core/test_coverage_report_html_helper.pks diff --git a/docs/userguide/reporters.md b/docs/userguide/reporters.md index b0f26ca18..8a3a1bd55 100644 --- a/docs/userguide/reporters.md +++ b/docs/userguide/reporters.md @@ -180,6 +180,17 @@ Some information in debug log might be redundant. - db object names
    - etc. +## Support line + +utPLSQL is free and open source. Support and sponsorship provides funding for the project. To let teams know that commercial support is available and that their organization can help keep the project maintained, some reporters enrich their output with this line: + +``` +Using utPLSQL at work? Get support and help keep it maintained: https://utplsql.org/support +``` + +To switch the line off, call `ut.run` or `ut_runner.run` with `a_support_info => false` (or `a_support_info => 0` with `ut.run` functions). +See [Switching off the support line](running-unit-tests.md#switching-off-the-support-line). + ## Custom reporters It is possible to add your own reporters by creating an appropriate object type. diff --git a/docs/userguide/running-unit-tests.md b/docs/userguide/running-unit-tests.md index a4797b735..e19ba66fc 100644 --- a/docs/userguide/running-unit-tests.md +++ b/docs/userguide/running-unit-tests.md @@ -217,6 +217,7 @@ Outputs of multiple reporters can be consumed in parallel. This allows for live - controlling client character set for HTML and XML reports - controlling rollback behavior of test-run - controlling random order of test execution +- switching off the support line Running with multiple reporters. @@ -570,6 +571,22 @@ end; **Note:** >This option is not available when running tests using `ut.run` as a table function. +## Switching off the support line + +Some of the reporters include a short line about [utPLSQL support and sponsorship](reporters.md#support-line). +To leave it out, set `a_support_info` to `false` when calling `ut.run` procedures or `ut_runner.run`, or to `0` when calling `ut.run` functions. + +```sql linenums="1" +set serveroutput on +begin + ut.run('hr.test_apply_bonus', a_support_info => false); +end; +``` + +```sql linenums="1" +select * from table(ut.run('hr.test_apply_bonus', a_support_info => 0)); +``` + ## Reports character-set encoding To get properly encoded reports, when running utPLSQL with HTML/XML reports on data containing national characters you need to provide your client character set when calling `ut.run` functions and procedures. diff --git a/source/api/ut.pkb b/source/api/ut.pkb index d2cd65f1d..4515900d7 100644 --- a/source/api/ut.pkb +++ b/source/api/ut.pkb @@ -135,7 +135,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) is pragma autonomous_transaction; begin @@ -158,7 +159,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + ut_utils.int_to_boolean(a_support_info) ); rollback; end; @@ -179,7 +181,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) is pragma autonomous_transaction; begin @@ -203,7 +206,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + ut_utils.int_to_boolean(a_support_info) ); rollback; end; @@ -253,7 +257,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -274,7 +279,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -301,7 +307,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -322,7 +329,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -350,7 +358,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -371,7 +380,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -399,7 +409,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -420,7 +431,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -448,7 +460,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -469,7 +482,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -497,7 +511,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined is l_reporter ut_reporter_base := a_reporter; l_results sys_refcursor; @@ -518,7 +533,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); if l_reporter is of (ut_output_reporter_base) then l_results := treat(l_reporter as ut_output_reporter_base).get_lines_cursor(); @@ -547,7 +563,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ) is l_reporter ut_reporter_base := a_reporter; begin @@ -571,7 +588,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); else run_autonomous( @@ -590,7 +608,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + ut_utils.boolean_to_int(a_support_info) ); end if; if l_reporter is of (ut_output_reporter_base) then @@ -616,7 +635,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ) is l_reporter ut_reporter_base := a_reporter; begin @@ -637,7 +657,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); end; @@ -657,7 +678,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ) is begin ut.run( @@ -677,7 +699,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); end; @@ -697,7 +720,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ) is begin ut.run( @@ -717,7 +741,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); end; @@ -738,7 +763,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ) is begin ut.run( @@ -758,7 +784,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); end; @@ -779,7 +806,8 @@ create or replace noneditionable package body ut is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ) is begin ut.run( @@ -799,7 +827,8 @@ create or replace noneditionable package body ut is a_include_schema_expr, a_include_object_expr, a_exclude_schema_expr, - a_exclude_object_expr + a_exclude_object_expr, + a_support_info ); end; diff --git a/source/api/ut.pks b/source/api/ut.pks index 2fb843f22..0324a164c 100644 --- a/source/api/ut.pks +++ b/source/api/ut.pks @@ -66,7 +66,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined; function run( @@ -84,7 +85,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined; function run( @@ -103,7 +105,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined; function run( @@ -122,7 +125,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined; function run( @@ -141,7 +145,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined; function run( @@ -160,7 +165,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info integer := 1 ) return ut_varchar2_rows pipelined; procedure run( @@ -179,7 +185,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ); procedure run( @@ -198,7 +205,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ); procedure run( @@ -218,7 +226,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ); procedure run( @@ -238,7 +247,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ); procedure run( @@ -258,7 +268,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ); procedure run( @@ -278,7 +289,8 @@ create or replace noneditionable package ut authid current_user as a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ); /** diff --git a/source/api/ut_runner.pkb b/source/api/ut_runner.pkb index 3366562af..9c64ffdba 100644 --- a/source/api/ut_runner.pkb +++ b/source/api/ut_runner.pkb @@ -73,7 +73,8 @@ create or replace noneditionable package body ut_runner is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ) is l_run ut_run; l_coverage_schema_names ut_varchar2_rows; @@ -133,7 +134,8 @@ create or replace noneditionable package body ut_runner is a_test_file_mappings => set(a_test_file_mappings), a_client_character_set => a_client_character_set, a_random_test_order_seed => l_random_test_order_seed, - a_run_tags => a_tags + a_run_tags => a_tags, + a_support_info => a_support_info ); ut_suite_manager.configure_execution_by_path(l_paths, l_run.items, l_random_test_order_seed, a_tags); diff --git a/source/api/ut_runner.pks b/source/api/ut_runner.pks index 6f73138ea..7ef938f45 100644 --- a/source/api/ut_runner.pks +++ b/source/api/ut_runner.pks @@ -45,6 +45,7 @@ create or replace noneditionable package ut_runner authid current_user is * @param a_fail_on_errors true/false - should an exception be thrown when tests are completed with failures/errors * @param a_client_character_set if provided, affects some of reporters by setting specific character set for XML/HTML reports * @param a_force_manual_rollback true/false - should the transaction control be forced to --%rollback(manual) and no rollback issued at the end of the run + * @param a_support_info true/false - should the reporters print the utPLSQL support line * * @example * Parameter `a_paths` accepts values of the following formats: @@ -75,7 +76,8 @@ create or replace noneditionable package ut_runner authid current_user is a_include_schema_expr varchar2 := null, a_include_object_expr varchar2 := null, a_exclude_schema_expr varchar2 := null, - a_exclude_object_expr varchar2 := null + a_exclude_object_expr varchar2 := null, + a_support_info boolean := true ); /** diff --git a/source/core/types/ut_run.tpb b/source/core/types/ut_run.tpb index 1e70a2fc4..85fa930e4 100644 --- a/source/core/types/ut_run.tpb +++ b/source/core/types/ut_run.tpb @@ -24,7 +24,8 @@ create or replace noneditionable type body ut_run as a_test_file_mappings ut_file_mappings := null, a_client_character_set varchar2 := null, a_random_test_order_seed positive := null, - a_run_tags varchar2 := null + a_run_tags varchar2 := null, + a_support_info boolean := true ) return self as result is begin self.run_paths := a_run_paths; @@ -36,9 +37,15 @@ create or replace noneditionable type body ut_run as self.results_count := ut_results_counter(); self.test_file_mappings := coalesce(a_test_file_mappings, ut_file_mappings()); self.coverage_options := a_coverage_options; + self.support_info_flag := ut_utils.boolean_to_int(coalesce(a_support_info, true)); return; end; + member function get_support_info_flag return boolean is + begin + return ut_utils.int_to_boolean(self.support_info_flag); + end; + overriding member procedure mark_as_skipped(self in out nocopy ut_run,a_skip_reason in varchar2) is begin null; diff --git a/source/core/types/ut_run.tps b/source/core/types/ut_run.tps index f55a84dda..a3f0b69b8 100644 --- a/source/core/types/ut_run.tps +++ b/source/core/types/ut_run.tps @@ -26,6 +26,7 @@ create or replace noneditionable type ut_run under ut_suite_item ( test_file_mappings ut_file_mappings, client_character_set varchar2(100), random_test_order_seed number(38,0), + support_info_flag integer(1), constructor function ut_run( self in out nocopy ut_run, a_items ut_suite_items := null, @@ -34,8 +35,10 @@ create or replace noneditionable type ut_run under ut_suite_item ( a_test_file_mappings ut_file_mappings := null, a_client_character_set varchar2 := null, a_random_test_order_seed positive := null, - a_run_tags varchar2 := null + a_run_tags varchar2 := null, + a_support_info boolean := true ) return self as result, + member function get_support_info_flag return boolean, overriding member procedure mark_as_skipped(self in out nocopy ut_run,a_skip_reason in varchar2), overriding member function do_execute(self in out nocopy ut_run) return boolean, overriding member procedure set_rollback_type(self in out nocopy ut_run, a_rollback_type integer, a_force boolean := false), diff --git a/source/core/ut_utils.pks b/source/core/ut_utils.pks index 1bb353806..57d8527fe 100644 --- a/source/core/ut_utils.pks +++ b/source/core/ut_utils.pks @@ -22,7 +22,10 @@ create or replace noneditionable package ut_utils authid definer is */ gc_version constant varchar2(50) := 'v3.2.4.4647-develop'; - + + gc_support_url constant varchar2(100) := 'https://utplsql.org/support'; + gc_support_text constant varchar2(200) := 'Using utPLSQL at work? Get support and help keep it maintained'; + subtype t_executable_type is varchar2(30); gc_before_all constant t_executable_type := 'beforeall'; gc_before_each constant t_executable_type := 'beforeeach'; diff --git a/source/reporters/ut_coverage_html_reporter.tpb b/source/reporters/ut_coverage_html_reporter.tpb index 50b0fd57c..49f412cb1 100644 --- a/source/reporters/ut_coverage_html_reporter.tpb +++ b/source/reporters/ut_coverage_html_reporter.tpb @@ -39,7 +39,8 @@ create or replace noneditionable type body ut_coverage_html_reporter is a_coverage_data => l_coverage_data, a_assets_path => self.assets_path, a_project_name => self.project_name, - a_charset => a_run.client_character_set + a_charset => a_run.client_character_set, + a_support_info => a_run.get_support_info_flag() ) ); end; diff --git a/source/reporters/ut_coverage_report_html_helper.pkb b/source/reporters/ut_coverage_report_html_helper.pkb index 7d19968a5..2ab989eea 100644 --- a/source/reporters/ut_coverage_report_html_helper.pkb +++ b/source/reporters/ut_coverage_report_html_helper.pkb @@ -285,7 +285,8 @@ create or replace noneditionable package body ut_coverage_report_html_helper is a_assets_path varchar2, a_project_name varchar2 := null, a_command_line varchar2 := null, - a_charset varchar2 := null + a_charset varchar2 := null, + a_support_info boolean := true ) return ut_varchar2_rows is l_file_part varchar2(32767); @@ -329,9 +330,12 @@ create or replace noneditionable package body ut_coverage_report_html_helper is ut_utils.append_to_list(l_result, file_list('All files', a_coverage_data)); l_file_part := chr(10) || '
    '; ut_utils.append_to_list(l_result, l_file_part); diff --git a/source/reporters/ut_coverage_report_html_helper.pks b/source/reporters/ut_coverage_report_html_helper.pks index 4eddee9a7..a6dd7eb30 100644 --- a/source/reporters/ut_coverage_report_html_helper.pks +++ b/source/reporters/ut_coverage_report_html_helper.pks @@ -36,7 +36,8 @@ create or replace noneditionable package ut_coverage_report_html_helper authid c a_assets_path varchar2, a_project_name varchar2 := null, a_command_line varchar2 := null, - a_charset varchar2 := null + a_charset varchar2 := null, + a_support_info boolean := true ) return ut_varchar2_rows; end; diff --git a/source/reporters/ut_documentation_reporter.tpb b/source/reporters/ut_documentation_reporter.tpb index 42e5c0fdf..ad3d1fb69 100644 --- a/source/reporters/ut_documentation_reporter.tpb +++ b/source/reporters/ut_documentation_reporter.tpb @@ -216,6 +216,9 @@ create or replace noneditionable type body ut_documentation_reporter is if a_run.random_test_order_seed is not null then self.print_text('Tests were executed with random order seed '''||a_run.random_test_order_seed||'''.'); end if; + if a_run.get_support_info_flag() then + self.print_cyan_text(ut_utils.gc_support_text || ': ' || ut_utils.gc_support_url); + end if; self.print_text(' '); (self as ut_reporter_base).after_calling_run(a_run); end; diff --git a/source/reporters/ut_tap_reporter.tpb b/source/reporters/ut_tap_reporter.tpb index 468d9363c..e1b3b617d 100644 --- a/source/reporters/ut_tap_reporter.tpb +++ b/source/reporters/ut_tap_reporter.tpb @@ -134,6 +134,9 @@ create or replace noneditionable type body ut_tap_reporter is overriding member procedure after_calling_run(self in out nocopy ut_tap_reporter, a_run in ut_run) as begin self.lvl := 0; + if a_run.get_support_info_flag() then + self.print_comment(ut_utils.gc_support_text || ': ' || ut_utils.gc_support_url); + end if; end; end; / diff --git a/test/install_ut3_tester_tests.sql b/test/install_ut3_tester_tests.sql index cc96b2b64..d46d947e4 100644 --- a/test/install_ut3_tester_tests.sql +++ b/test/install_ut3_tester_tests.sql @@ -25,6 +25,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core/test_file_mapper.pks @@ut3_tester/core/test_output_buffer.pks @@ut3_tester/core/test_suite_builder.pks +@@ut3_tester/core/test_coverage_report_html_helper.pks @@ut3_tester/core.pkb @@ -44,6 +45,7 @@ alter session set plsql_optimize_level=0; @@ut3_tester/core/test_file_mapper.pkb @@ut3_tester/core/test_output_buffer.pkb @@ut3_tester/core/test_suite_builder.pkb +@@ut3_tester/core/test_coverage_report_html_helper.pkb diff --git a/test/ut3_tester/core/test_coverage_report_html_helper.pkb b/test/ut3_tester/core/test_coverage_report_html_helper.pkb new file mode 100644 index 000000000..a4cd36ed1 --- /dev/null +++ b/test/ut3_tester/core/test_coverage_report_html_helper.pkb @@ -0,0 +1,29 @@ +create or replace package body test_coverage_report_html_helper is + + gc_support_link constant varchar2(4000) := + '' || ut3_develop.ut_utils.gc_support_text || ''; + + function get_index(a_support_info boolean) return clob is + l_coverage_data ut3_develop.ut_coverage.t_coverage; + begin + return ut3_develop.ut_utils.table_to_clob( + ut3_develop.ut_coverage_report_html_helper.get_index( + a_coverage_data => l_coverage_data, + a_assets_path => null, + a_support_info => a_support_info + ) + ); + end; + + procedure index_includes_support_link is + begin + ut.expect( get_index(a_support_info => true) ).to_be_like( '%%' ); + end; + + procedure index_omits_support_link is + begin + ut.expect( get_index(a_support_info => false) ).not_to_be_like( '%' || ut3_develop.ut_utils.gc_support_url || '%' ); + end; + +end; +/ diff --git a/test/ut3_tester/core/test_coverage_report_html_helper.pks b/test/ut3_tester/core/test_coverage_report_html_helper.pks new file mode 100644 index 000000000..bad1192b8 --- /dev/null +++ b/test/ut3_tester/core/test_coverage_report_html_helper.pks @@ -0,0 +1,13 @@ +create or replace package test_coverage_report_html_helper is + + --%suite(coverage_report_html_helper) + --%suitepath(utplsql.ut3_tester.core) + + --%test(Index page footer includes support link by default) + procedure index_includes_support_link; + + --%test(Index page footer omits support link when switched off) + procedure index_omits_support_link; + +end; +/ diff --git a/test/ut3_tester/core/test_suite_manager.pkb b/test/ut3_tester/core/test_suite_manager.pkb index d3afae3aa..8ab9b96d9 100644 --- a/test/ut3_tester/core/test_suite_manager.pkb +++ b/test/ut3_tester/core/test_suite_manager.pkb @@ -1284,7 +1284,7 @@ end;'; l_test_report ut3_develop.ut_varchar2_list; begin - select * bulk collect into l_test_report from table(ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER')||'.test_dependencies')); + select * bulk collect into l_test_report from table(ut3_develop.ut.run(sys_context('USERENV', 'CURRENT_USER')||'.test_dependencies', a_support_info => 0)); ut.expect(l_test_report(l_test_report.count-1)).to_be_like('1 test_, 0 failed, 0 errored, 0 disabled, 0 warning(s)'); --execute immediate 'select * from table(ut3_develop.ut.run(''UT3_DEVELOP.test_dependencies'', ut3_develop.utplsql_test_reporter()))' into l_result; diff --git a/test/ut3_user/api/test_ut_run.pkb b/test/ut3_user/api/test_ut_run.pkb index 87a048904..12ab6cdba 100644 --- a/test/ut3_user/api/test_ut_run.pkb +++ b/test/ut3_user/api/test_ut_run.pkb @@ -935,6 +935,38 @@ Failures:% ut.expect(anydata.convertCollection(l_actual)).to_equal(anydata.convertCollection(l_expected)); end; + + procedure run_proc_prints_support_info is + begin + ut3_develop.ut.run('ut3_tester_helper.test_package_1'); + + ut.expect( ut3_tester_helper.main_helper.get_dbms_output_as_clob() ).to_be_like( '%' || reporters.gc_support_line || '%' ); + end; + + procedure run_proc_omits_support_info is + begin + ut3_develop.ut.run('ut3_tester_helper.test_package_1', a_support_info => false); + + ut.expect( ut3_tester_helper.main_helper.get_dbms_output_as_clob() ).not_to_be_like( '%' || reporters.gc_support_line || '%' ); + end; + + procedure run_func_prints_support_info is + l_results ut3_develop.ut_varchar2_list; + begin + select * bulk collect into l_results + from table ( ut3_develop.ut.run('ut3_tester_helper.test_package_1') ); + + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).to_be_like( '%' || reporters.gc_support_line || '%' ); + end; + + procedure run_func_omits_support_info is + l_results ut3_develop.ut_varchar2_list; + begin + select * bulk collect into l_results + from table ( ut3_develop.ut.run('ut3_tester_helper.test_package_1', a_support_info => 0) ); + + ut.expect( ut3_tester_helper.main_helper.table_to_clob(l_results) ).not_to_be_like( '%' || reporters.gc_support_line || '%' ); + end; procedure test_run_by_one_tag is l_results clob; diff --git a/test/ut3_user/api/test_ut_run.pks b/test/ut3_user/api/test_ut_run.pks index 97c2a2b16..552c5dbf3 100644 --- a/test/ut3_user/api/test_ut_run.pks +++ b/test/ut3_user/api/test_ut_run.pks @@ -181,6 +181,26 @@ create or replace package test_ut_run is --%endcontext + --%context(support_info) + + --%displayname(Support line) + --%beforeall(create_ut3_user_tests) + --%afterall(drop_ut3_user_tests) + + --%test(ut.run() procedure prints support line by default) + procedure run_proc_prints_support_info; + + --%test(ut.run() procedure omits support line when a_support_info is false) + procedure run_proc_omits_support_info; + + --%test(ut.run() function prints support line by default) + procedure run_func_prints_support_info; + + --%test(ut.run() function omits support line when a_support_info is 0) + procedure run_func_omits_support_info; + + --%endcontext + --%context(run with paths in several schemas) --%beforeall(create_ut3_user_tests, create_test_suite_in_ut3_user) diff --git a/test/ut3_user/reporters.pks b/test/ut3_user/reporters.pks index c5ad72e22..412091984 100644 --- a/test/ut3_user/reporters.pks +++ b/test/ut3_user/reporters.pks @@ -1,5 +1,7 @@ create or replace package reporters is + gc_support_line constant varchar2(200) := 'Using utPLSQL at work? Get support and help keep it maintained: https://utplsql.org/support'; + --%suite --%suitepath(utplsql.test_user) diff --git a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb index e88a94131..883909eb5 100644 --- a/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb +++ b/test/ut3_user/reporters/test_coverage/test_html_coverage_reporter.pkb @@ -30,6 +30,26 @@ create or replace package body test_html_coverage_reporter is ut.expect(l_actual).to_be_like(l_expected); end; + procedure report_support_link is + l_actual clob; + begin + l_actual := + ut3_tester_helper.coverage_helper.run_tests_as_job( + q'[ + ut3_develop.ut.run( + a_path => 'ut3_develop.test_dummy_coverage', + a_reporter=> ut3_develop.ut_coverage_html_reporter() + ) + ]' + ); + + ut.expect(l_actual).to_be_like( + '%