Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

utPLSQL tests fails on Oracle 11.2.0.4 due to Oracle Bug 14402514 #891

Closed
PhilippSalvisberg opened this issue Apr 2, 2019 · 2 comments

Comments

Projects
None yet
2 participants
@PhilippSalvisberg
Copy link
Member

commented Apr 2, 2019

Describe the bug
When I run the utPLSQL tests against a Oracle Database Version
11.2.0.4.190115 (Enterprise Edition, Linux x86_64 within Docker) as follows

. development/env.sh
test/install_and_run_tests.sh

I the following result:

Failures:
 
  1) test_bad_procedure_annotation
      Actual: (clob)
          '<UT_LOGICAL_SUITE><SELF_TYPE>UT_SUITE</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>some_package</NAME><DESCRIPTION>Cool</DESCRIPTION><PATH>some_package</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>1</LINE_NO><PARSE_TIME>02.04.19 09:40:34.283553</PARSE_TIME><WARNINGS><VARCHAR2>Unsupported annotation &quot;--%bad_procedure_annotation&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.SOME_PROCEDURE&quot;, line 2</VARCHAR2></WARNINGS><ITEMS><UT_SUITE_ITEM><SELF_TYPE>UT_TEST</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>do_stuff</NAME><DESCRIPTION>A test</DESCRIPTION><PATH>some_package.do_stuff</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>6</LINE_NO><PARSE_TIME>02.04.19 09:40:34.283553</PARSE_TIME><WARNINGS/><BEFORE_EACH_LIST/><BEFORE_TEST_LIST/><ITEM><SELF_TYPE>UT_EXECUTABLE_TEST</SELF_TYPE><EXECUTABLE_TYPE>test</EXECUTABLE_TYPE><OWNER_NAME>UT3_TESTER</OWNER_NAME><OBJECT_NAME>some_package</OBJECT_NAME><PROCEDURE_NAME>do_stuff</PROCEDURE_NAME></ITEM><AFTER_TEST_LIST/><AFTER_EACH_LIST/><ALL_EXPECTATIONS/><FAILED_EXPECTATIONS/></UT_SUITE_ITEM></ITEMS><BEFORE_ALL_LIST/><AFTER_ALL_LIST/></UT_LOGICAL_SUITE>'
      was expected to be like: 
          '%<WARNINGS><VARCHAR2>Unsupported annotation &quot;--\%bad_procedure_annotation&quot;. Annotation ignored.% line 2</VARCHAR2></WARNINGS>%'
      , escape '\'
      at "UT3_TESTER.TEST_SUITE_BUILDER", line 1098 ut.expect(l_actual).to_be_like('%<WARNINGS><VARCHAR2>Unsupported annotation &quot;--\%bad_procedure_annotation&quot;. Annotation ignored.% line 2</VARCHAR2></WARNINGS>%', '\');
      
       
  2) test_bad_package_annotation
      Actual: (clob)
          '<UT_LOGICAL_SUITE><SELF_TYPE>UT_SUITE</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>some_package</NAME><DESCRIPTION>Cool</DESCRIPTION><PATH>some_package</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>1</LINE_NO><PARSE_TIME>02.04.19 09:40:34.335352</PARSE_TIME><WARNINGS><VARCHAR2>Unsupported annotation &quot;--%bad_package_annotation&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE&quot;, line 17</VARCHAR2></WARNINGS><ITEMS><UT_SUITE_ITEM><SELF_TYPE>UT_TEST</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>do_stuff</NAME><DESCRIPTION>A test</DESCRIPTION><PATH>some_package.do_stuff</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>24</LINE_NO><PARSE_TIME>02.04.19 09:40:34.335352</PARSE_TIME><WARNINGS/><BEFORE_EACH_LIST/><BEFORE_TEST_LIST/><ITEM><SELF_TYPE>UT_EXECUTABLE_TEST</SELF_TYPE><EXECUTABLE_TYPE>test</EXECUTABLE_TYPE><OWNER_NAME>UT3_TESTER</OWNER_NAME><OBJECT_NAME>some_package</OBJECT_NAME><PROCEDURE_NAME>do_stuff</PROCEDURE_NAME></ITEM><AFTER_TEST_LIST/><AFTER_EACH_LIST/><ALL_EXPECTATIONS/><FAILED_EXPECTATIONS/></UT_SUITE_ITEM></ITEMS><BEFORE_ALL_LIST/><AFTER_ALL_LIST/></UT_LOGICAL_SUITE>'
      was expected to be like: 
          '%<WARNINGS><VARCHAR2>Unsupported annotation &quot;--\%bad_package_annotation&quot;. Annotation ignored.% line 17</VARCHAR2></WARNINGS>%'
      , escape '\'
      at "UT3_TESTER.TEST_SUITE_BUILDER", line 1114 ut.expect(l_actual).to_be_like('%<WARNINGS><VARCHAR2>Unsupported annotation &quot;--\%bad_package_annotation&quot;. Annotation ignored.% line 17</VARCHAR2></WARNINGS>%', '\');
      
       
  3) before_after_mixed_with_test
      Actual: (clob)
          '<UT_LOGICAL_SUITE><SELF_TYPE>UT_SUITE</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>some_package</NAME><DESCRIPTION>Cool</DESCRIPTION><PATH>some_package</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>1</LINE_NO><PARSE_TIME>02.04.19 09:40:35.989674</PARSE_TIME><WARNINGS><VARCHAR2>Annotation &quot;--%afterall&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 5</VARCHAR2><VARCHAR2>Annotation &quot;--%aftereach&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 4</VARCHAR2><VARCHAR2>Annotation &quot;--%beforeall&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 2</VARCHAR2><VARCHAR2>Annotation &quot;--%beforeeach&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 3</VARCHAR2></WARNINGS><ITEMS><UT_SUITE_ITEM><SELF_TYPE>UT_TEST</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>do_stuff</NAME><DESCRIPTION>A test</DESCRIPTION><PATH>some_package.do_stuff</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>6</LINE_NO><PARSE_TIME>02.04.19 09:40:35.989674</PARSE_TIME><WARNINGS/><BEFORE_EACH_LIST/><BEFORE_TEST_LIST/><ITEM><SELF_TYPE>UT_EXECUTABLE_TEST</SELF_TYPE><EXECUTABLE_TYPE>test</EXECUTABLE_TYPE><OWNER_NAME>UT3_TESTER</OWNER_NAME><OBJECT_NAME>some_package</OBJECT_NAME><PROCEDURE_NAME>do_stuff</PROCEDURE_NAME></ITEM><AFTER_TEST_LIST/><AFTER_EACH_LIST/><ALL_EXPECTATIONS/><FAILED_EXPECTATIONS/></UT_SUITE_ITEM></ITEMS><BEFORE_ALL_LIST/><AFTER_ALL_LIST/></UT_LOGICAL_SUITE>'
      was expected to be like: '%<WARNINGS>%Annotation &quot;--\%beforeall&quot;%line 2%</WARNINGS>%'  , escape '\'
      at "UT3_TESTER.TEST_SUITE_BUILDER", line 611 ut.expect(l_actual).to_be_like('%<WARNINGS>%Annotation &quot;--\%beforeall&quot;%line 2%</WARNINGS>%', '\');
      
       
      Actual: (clob)
          '<UT_LOGICAL_SUITE><SELF_TYPE>UT_SUITE</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>some_package</NAME><DESCRIPTION>Cool</DESCRIPTION><PATH>some_package</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>1</LINE_NO><PARSE_TIME>02.04.19 09:40:35.989674</PARSE_TIME><WARNINGS><VARCHAR2>Annotation &quot;--%afterall&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 5</VARCHAR2><VARCHAR2>Annotation &quot;--%aftereach&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 4</VARCHAR2><VARCHAR2>Annotation &quot;--%beforeall&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 2</VARCHAR2><VARCHAR2>Annotation &quot;--%beforeeach&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 3</VARCHAR2></WARNINGS><ITEMS><UT_SUITE_ITEM><SELF_TYPE>UT_TEST</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>do_stuff</NAME><DESCRIPTION>A test</DESCRIPTION><PATH>some_package.do_stuff</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>6</LINE_NO><PARSE_TIME>02.04.19 09:40:35.989674</PARSE_TIME><WARNINGS/><BEFORE_EACH_LIST/><BEFORE_TEST_LIST/><ITEM><SELF_TYPE>UT_EXECUTABLE_TEST</SELF_TYPE><EXECUTABLE_TYPE>test</EXECUTABLE_TYPE><OWNER_NAME>UT3_TESTER</OWNER_NAME><OBJECT_NAME>some_package</OBJECT_NAME><PROCEDURE_NAME>do_stuff</PROCEDURE_NAME></ITEM><AFTER_TEST_LIST/><AFTER_EACH_LIST/><ALL_EXPECTATIONS/><FAILED_EXPECTATIONS/></UT_SUITE_ITEM></ITEMS><BEFORE_ALL_LIST/><AFTER_ALL_LIST/></UT_LOGICAL_SUITE>'
      was expected to be like: '%<WARNINGS>%Annotation &quot;--\%beforeeach&quot;%line 3%</WARNINGS>%'  , escape '\'
      at "UT3_TESTER.TEST_SUITE_BUILDER", line 612 ut.expect(l_actual).to_be_like('%<WARNINGS>%Annotation &quot;--\%beforeeach&quot;%line 3%</WARNINGS>%', '\');
      
       
      Actual: (clob)
          '<UT_LOGICAL_SUITE><SELF_TYPE>UT_SUITE</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>some_package</NAME><DESCRIPTION>Cool</DESCRIPTION><PATH>some_package</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>1</LINE_NO><PARSE_TIME>02.04.19 09:40:35.989674</PARSE_TIME><WARNINGS><VARCHAR2>Annotation &quot;--%afterall&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 5</VARCHAR2><VARCHAR2>Annotation &quot;--%aftereach&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 4</VARCHAR2><VARCHAR2>Annotation &quot;--%beforeall&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 2</VARCHAR2><VARCHAR2>Annotation &quot;--%beforeeach&quot; cannot be used with &quot;--%test&quot;. Annotation ignored.
          at &quot;UT3_TESTER.SOME_PACKAGE.DO_STUFF&quot;, line 3</VARCHAR2></WARNINGS><ITEMS><UT_SUITE_ITEM><SELF_TYPE>UT_TEST</SELF_TYPE><OBJECT_OWNER>UT3_TESTER</OBJECT_OWNER><OBJECT_NAME>some_package</OBJECT_NAME><NAME>do_stuff</NAME><DESCRIPTION>A test</DESCRIPTION><PATH>some_package.do_stuff</PATH><ROLLBACK_TYPE>0</ROLLBACK_TYPE><DISABLED_FLAG>0</DISABLED_FLAG><LINE_NO>6</LINE_NO><PARSE_TIME>02.04.19 09:40:35.989674</PARSE_TIME><WARNINGS/><BEFORE_EACH_LIST/><BEFORE_TEST_LIST/><ITEM><SELF_TYPE>UT_EXECUTABLE_TEST</SELF_TYPE><EXECUTABLE_TYPE>test</EXECUTABLE_TYPE><OWNER_NAME>UT3_TESTER</OWNER_NAME><OBJECT_NAME>some_package</OBJECT_NAME><PROCEDURE_NAME>do_stuff</PROCEDURE_NAME></ITEM><AFTER_TEST_LIST/><AFTER_EACH_LIST/><ALL_EXPECTATIONS/><FAILED_EXPECTATIONS/></UT_SUITE_ITEM></ITEMS><BEFORE_ALL_LIST/><AFTER_ALL_LIST/></UT_LOGICAL_SUITE>'
      was expected to be like: '%<WARNINGS>%Annotation &quot;--\%aftereach&quot;%line 4%</WARNINGS>%'  , escape '\'
      at "UT3_TESTER.TEST_SUITE_BUILDER", line 613 ut.expect(l_actual).to_be_like('%<WARNINGS>%Annotation &quot;--\%aftereach&quot;%line 4%</WARNINGS>%', '\');
      
       
Finished in 176.665283 seconds
799 tests, 3 failed, 0 errored, 1 disabled, 0 warning(s)

Provide version info

SQL> declare
  2    l_version varchar2(255);
  3    l_compatibility varchar2(255);
  4  begin
  5    dbms_utility.db_version( l_version, l_compatibility );
  6    dbms_output.put_line( l_version );
  7    dbms_output.put_line( l_compatibility );
  8  end;
  9  /
11.2.0.4.0
11.2.0.4.0


PL/SQL procedure successfully completed.

SQL> select substr(ut.version(),1,60) as ut_version from dual;

UT_VERSION                                                  
------------------------------------------------------------
v3.1.7.2795-develop                                         

SQL> select * from v$version;

BANNER                                                                          
--------------------------------------------------------------------------------
Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production    
PL/SQL Release 11.2.0.4.0 - Production                                          
CORE	11.2.0.4.0	Production                                                      
TNS for Linux: Version 11.2.0.4.0 - Production                                  
NLSRTL Version 11.2.0.4.0 - Production                                          

SQL> select * from nls_session_parameters;

PARAMETER                      VALUE                                   
------------------------------ ----------------------------------------
NLS_LANGUAGE                   AMERICAN                                
NLS_TERRITORY                  SWITZERLAND                             
NLS_CURRENCY                   SFr.                                    
NLS_ISO_CURRENCY               SWITZERLAND                             
NLS_NUMERIC_CHARACTERS         .'                                      
NLS_CALENDAR                   GREGORIAN                               
NLS_DATE_FORMAT                DD.MM.RR                                
NLS_DATE_LANGUAGE              AMERICAN                                
NLS_SORT                       BINARY                                  
NLS_TIME_FORMAT                HH24:MI:SSXFF                           
NLS_TIMESTAMP_FORMAT           DD.MM.RR HH24:MI:SSXFF                  
NLS_TIME_TZ_FORMAT             HH24:MI:SSXFF TZR                       
NLS_TIMESTAMP_TZ_FORMAT        DD.MM.RR HH24:MI:SSXFF TZR              
NLS_DUAL_CURRENCY              SF                                      
NLS_COMP                       BINARY                                  
NLS_LENGTH_SEMANTICS           BYTE                                    
NLS_NCHAR_CONV_EXCP            FALSE                                   

17 rows selected. 

SQL> select substr(dbms_utility.port_string,1,60) as port_string from dual;

PORT_STRING                                                 
------------------------------------------------------------
x86_64/Linux 2.4.xx

Information about client software
current utPLSQL-cli

To Reproduce

  1. Install an Oracle Database containing this bug, e.g this
  2. install utPLSQL development environment
  3. run test/install_and_run_tests.sh

Expected behavior
test/install_and_run_tests.sh produces no errors.

Additional context
Further information about the Oracle bug are available on My Oracle Support:

The recommended workaround is to use REGEXP_LIKE instead of LIKE with an escape character.

Related lines in utPLSQL:

All these tests use to_be_like with an escape character. Behind the scenes a LIKE expression with an escape character is used and this leads in these cases to a wrong result.

@PhilippSalvisberg PhilippSalvisberg self-assigned this Apr 2, 2019

@PhilippSalvisberg

This comment has been minimized.

Copy link
Member Author

commented Apr 2, 2019

@jgebal suggested in Slack that to_match could be used instead of to_be_like, especially if this bug is hit and document it.

In this case it is much easier to change the expressions in the test cases than to simulate a like ... escape ... using a regexp_like in a general fashion.

@pesse

This comment has been minimized.

Copy link
Member

commented Apr 2, 2019

Seems like a good question/suggestion for a FAQ document, right?

@PhilippSalvisberg PhilippSalvisberg added this to the v3.1.7 milestone Apr 2, 2019

PhilippSalvisberg added a commit to PhilippSalvisberg/utPLSQL that referenced this issue Apr 2, 2019

lwasylow added a commit that referenced this issue Jun 18, 2019

Release/v3.1.7 (#942)
* Test to verify there's a problem with cursor-comparison on 12.1

when there are several numbers with different precision and we make use of package-level nested table types

* Typo

* Initial checkin

* Adding handling of xml error

* Adding new API user.

* Updated `install.md`

* Updated project version after build [skip ci]

* Separating tests.

* Update properties

* Change user that executes tests as helper that is super user.

* Updated version to `3.1.7`

* Updated project version after build [skip ci]

* Adding next set of tests migrated.
expectations/binary/test_equal
expectations/binary/test_expect_to_be_less_than
expectations/test_expectation_anydata
expectations/test_expectation_processor

* Adding next set of tests migrated.
expectations/binary/test_be_less_or_equal

changing name of function to more meaningful.

* Fixing test package

* Added set of tests:
expectations/binary/test_be_greater_or_equal
expectations/binary/test_be_greater_than
expectations/unary/test_expect_not_to_be_null

Passing username implicit into ut_test_runner.

* Adding set of tests :
expectations/unary/test_expect_to_be_empty
expectations/unary/test_expect_to_be_null
expectations/unary/test_expect_to_be_true_false
expectations/unary/test_expect_to_have_count

Adding dummy type for testing.

* Adding schema prefix to failing tests from 12.1

* Fixing development scripts

* Fixed bug for deployments with uninstall included.
Added new user to `template.env.sh`

* Updated project version after build [skip ci]

* FIX : removal of non existing types from uninstall script

* INSTALL:Is it too many monkeys ?:)

* Added support for random order of test execution.
Resolves #422

* Adding set of tests:
api/test_ut_run

* Adding set of tests:
api/test_ut_run

* Fixing one bad test.
Workaround for current issue with `unordered()` comparison of blank lines.

* Fixing issue with null vs null being returned as false.
Fixing change in Oracle 12.2+ where XML is stored as binary XML and not preserving insignificant white space. This require store data as clob.

* Revert test

* Fixed bad test.
Added `dbms_output.enable` in `core` test package

* Adding set of tests:
api/test_ut_run

* Adding set of tests:
core/annotations/test_annotation_parser
core/annotations/test_annot_throws_exception
core/annotations/test_annotation_manager

* Adding set of tests:
core/test_ut_test
core/test_ut_utils

* Adding set of tests:
core/test_ut_executable
core/test_ut_suite

* Adding set of tests:
core/test_file_mapper
core/test_output_buffer
core/test_suite_manager
core/test_ut_executable

* Adding tests
core/test_suite_builder

* Adding tests:
reporters
reporters/test_junit_reporter
reporters/test_sonar_test_reporter
reporters/test_teamcity_reporter
reporters/test_tfs_junit_reporter

* Fixed storage for clob in output bugger table - make it inline.
Changed how delete from output buffer table is handled - use ROWID.
Increased fetch size from 100 to 3000 rows for output buffer.

* Improved performance for reading data from output buffer.
Decreased read limit back to 1000 as it should not have significant performance impact anymore.

* Increased read limit to 5000.
Fixed bug with increasing `max_message_id` even when nothing was read.

* Adding set of tests:
reporters/test_coverage
reporters/test_debug_reporter
reporters/test_documentation_reporter
reporters/test_extended_coverage
reporters/test_realtime_reporter

Fixing some helper methods.

* Split output buffers into two.
Now we have separate buffer for CLOB data and VARCHAR2 text data.

* Adding extra tests:
reporters/test_coverage/test_cov_cobertura_reporter
reporters/test_coverage/test_coverage_sonar_reporter
reporters/test_coverage/test_coveralls_reporter
reporters/test_coverage/test_html_extended_reporter

* Updated documentation for random order of test execution

* Adding tests:
reporters/test_coverage
reporters/test_coverage/test_html_proftab_reporter
reporters/test_proftab_coverage

* Updated project version after build [skip ci]

* Fixing broken test.
Adding test:
reporters/test_coverage/test_html_extended_reporter
reporters/test_extended_coverage

* Adding test:
unary/test_expect_to_be_not_null

* Adding global setup

* document how to avoid Oracle Bug 14402514 (see #891)

* Fixes #891 - use to_match instead of to_be_like to avoid Oracle bug 14402514 on some 11.2.0.4 instances

* Updated project version after build [skip ci]

* Update cleanup script after branching from random order branch

* Fixed invalid suitepath in `core` package.
Updated cli version to 3.1.6
Added top package `utplsql` with dbms_output.enable for both test users.
Renamed suitepath to match username (ut3_tester)

* Updated project version after build [skip ci]

* Cursor error handling

* Update tests for handling usr friendly error

* Applying fixes as per PR review.
Removal of unused procedure from expactation_processor
Switch to use constant in error message creation
Update tests to match full message.

* Cleanup whitespaces

* fixing ORA-00907 when comparing ref cursors with BINARY_DOUBLE/BINRAY_FLOAT columns

fixing ORA-00907: missing right parenthesis when comparing ref cursors with BINARY_DOUBLE/BINARY_FLOAT columns, because these column types do not support type length

* fix/ORA-00907: adding simple testcase

* fix/ORA-00907: shortening test case name

* fix/ORA-00907: wrong schema name in test case check

* Updated project version after build [skip ci]

* Call stack differs based on version

* Fix typo

* Update error lines

* Adding ROWID to list of types that do not provide a length.

* cleaning up tests

* Update tests

* testing wildcard, there is some unexpected white space that is not appearing on local tests or other similar for expected.

* Fix : No length datatypes mapping. This is to address issue when Oracle dont expect a length value against data type but cursor description return a max_len not being null.

* Update test

* Mysterious whitespace appears from time to time.
TODO

* Updated project version after build [skip ci]

* Fixing issue with a special column names non XML compliant (#903)

* Fixing issue with a special column names that do not adhere to XML rules.

* removing unused global constant.

* Modification after PR comments.
Inline call to function.
Remove constants to be private.
Expose only one function rest to be private

* Updated project version after build [skip ci]

* Adding trigger solution for annotation parsing.

* Fixed some issues with trigger
Some tests need to be fixed to disable trigger before testing
Some tests need to be added to prove trigger is working

* Fixed uninstall script and constant.
Disabled `-scc` flag in tests

* Removed commented code.

* Added tags for tests and tags for suite.

* Switch to use VARCHAR2 instead of UT_VARCHAR2_ROWS()

Signed-off-by: lwasylow <lwasylow@gmail.com>

* Switch to use VARCHAR2 instead of UT_VARCHAR2_ROWS()

Signed-off-by: lwasylow <lwasylow@gmail.com>

* Fix/oracle bug with xmlspaces (#895)

* Address issue with whitespace in XML.
Cursor describe is ignoring whitespace so max len of column with value ' t ' is showing as 1.
XMLTABLE when extracting values from tag with whitespaces its ignoring them. It works properly if there is any character there e.g ' t '.

* Update tests

* Updated project version after build [skip ci]

* Adding Tests to tags #suitebuilder

* Change annotation to --%tags

* Fixing empty tags to use xmlgen

* Adding tests for ut.run
Change query to use regexp as instr was giving false positives.

* Added tests for ut.run procedure

* Added extra tests for ut run function

* Fixing error message function

* Update docs

* Update docs and tests

* Fixes to PR comments

* Fixes to PR comments

* Updates to PR

* Separated the install for trigger.

* Phase 2 : switch to varchar_rows()

* Number precision from dbms_sql not correct (#908)

* Fixing issue with number from dual and precision being incorrectly read.

* Updated tests

* Updated project version after build [skip ci]

* add tests on 19c DB version

* Phase 2 : switch to varchar_rows()

* Remove a 4k tests

* Added constant

* Updated project version after build [skip ci]

* Added-back rigger installation to CI/CD process.

* Moved test to new package structure and improved test details.

* Fixed test to run only on 12 and above.

* Updated project version after build [skip ci]

* Removed garbage after PR merge.

* Updates to PR.
Switch to common add tags to suite item

* Move query to template to simplify view

* Updated project version after build [skip ci]

* Fix to issue when column was removed from the middle of cursor using a exclude or include.
this left a gap in orders and cause an columns mismatch on position for remainder of columns.

* Fix typo

* Make sure that order of the columns is kept when rewriting an order and nothing was removed.

* Partition should not be across column name but a full table set.

* Removal of row_number as its excessive we dont partition by any

* fix message_id increment

* the fix

* shorten test name

* fix type

* Updated project version after build [skip ci]

* Updated project version after build [skip ci]

* Fixed issue with missing newlines in cobertura coverage for non-executed packages.
Resolves #917

* Updated project version after build [skip ci]

* Initial checkin

* Failure details in sonar test reporter are now CDATA

* Update ut_junit_reporter.tpb

* Added handling of CDATA in failure messages for XML reporters.

* Fixing PR comments.

* Update docs with sample

* TAG: Phase2
Adding a new attribute filterpath that is used for filtering cursor in anydata / refcursor.
This value will be different from cursor in anydata as we skip root element.

* TAG: Phase2
Adding a new attribute filterpath that is used for filtering cursor in anydata / refcursor.
This value will be different from cursor in anydata as we skip root element.

* PHASE 2

* Fixing unit test for Oracle 11.2 & 12.1

* Fixing code duplication

* Updated project version after build [skip ci]

* Fixes #921 - Assert input params in dynamic SQL

Used dbms_assert.qualified_sql_name whenever possible.
This is much less invasive than dbms_assert.enquote_name.
Code converting case is left untouched.

* Updated project version after build [skip ci]

* Fixing sonar violation on duplicated code.

* Updated project version after build [skip ci]

* update tests to be less complicated

* Fixing encoding issue

* Updated project version after build [skip ci]

* Renamed `gc_tag` to `gc_tags`
Added debug logging of suite cache query.

* Updated project version after build [skip ci]

* Fixed install of release until feature is merged back.

* Enabled-back dbms_preprocessor

* Fixed bug in parsing annotations from DDL trigger.

* Fixed issues with parsing code through trigger.
Added disabling trigger on annotation parser tests.

* Fixed re-install of trigger.

* Updated readme for installation with trigger.
Added additional tests for annotation management with / without trigger.
Fixed code for situations when trigger gets added on pre-existing tests.

* Addressed review comments.
Refactored install scripts to avoid duplication.
Added check for `oracle_maintained` schema when firing DDL trigger.

* Fixed issue with style check.
Reorganized code to avoid problems with conditional compilation on 12.2 for triggers.

* Updated project version after build [skip ci]

* Fixing sonar exclusions for analysis and coverage.

* Updated project version after build [skip ci]

* Fixed output_buffer purging error.
Resolves #934

* Updated project version after build [skip ci]

* add test cases for warning texts in tests, suites

* implement new test cases and adapt existing ones

Structure of test cases is affected since new PL/SQL package is created which is also used in the whole run.

* emit warning texts on test and suite level

* complete cleanup after run

* Updated project version after build [skip ci]

* Removed dependency on `dbms_utility.name_resolve`.

Fixed issue with utPLSQL failing to run when schema contains package named the same as schema owning it.
It is now possible to have utPLSQL test package like this:
```
create or replace package some_schema.some_schema as
  --%suite

  --%test
  procedure sample_test;
end;
/

create or replace package body some_schema.some_schema as
   procedure sample_test is begin ut.expect(1).to_equal(1); end;
end;
/
```

The tests from the package can be invoked by calling:
`exec ut.run('some_schema.some_schema');`

If only schema is provided, all test packages in schema are executed.
`exec ut.run('some_schema');`

Resolves #569
Resolves #885

* Fixed issue with parsing by trigger when source contains leading comments.

* Fixed typo.

* Improved time needed for clob-to-table conversion.
Timing before change (with dbms_lob.read):
`clob_to_table - Took:+000000000 00:00:00.012957000`
After change:
`clob_to_table - Took:+000000000 00:00:00.001236000`
Speed improved by order of magnitude.

* Resolved issues with regex for DDL trigger processing.

* Adressed review comment.

* Fixed typo.

* Updated project version after build [skip ci]

* Updated project version after build [skip ci]

* Feature/json object (#928)

* Initial checkin.
General skelet of code

* Adding json tree parsing.
Enabling 12.2

* Update tests.
Update sonar rules.

* small fixes

* PHASE 2:
Moving diff into temp table and init data compare during compare implementation to avoid finding same differences twice
Adding have count and negated have count matcher.l

* Added more complex tests.
Added test when extract a piece from two different jsons.
Small fixes to code on same hierarchy parent arrays

* Update mddocs
Fix to json traverse array when object is element of array, the element name is content of object which can be different order but same semantic content.

* Fixing sonar

* Switch to use supertype

* PHASE3 : Adding a functionality for install in pre 12.2

* PHASE3 : Adding a functionality for install in pre 12.2

* PHASE3 : Adding a functionality for install in pre 12.2

* PHASE3 : Adding a functionality for install in pre 12.2

* PHASE3 : Adding a functionality for install in pre 12.2

* PHASE3 : Adding a functionality for install in pre 12.2

* update tests

* Update set define off

* Code cleanup

* fix slash

* Creating a dummy specs and removing conditional compilation for code cleanup

* PR fixes.

* Reverting development script changes.

* Refactored JSON code.
Changed formatting of JSON-diff output.
Changed date formats.

* Fixed install on Oracle < 12.2

* Updated project version after build [skip ci]

* Update readme.md

* Updated copyright year

* Updated project version after build [skip ci]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.