Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Feature - include/exclude objects and schemas by regex #1186

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

Merged
merged 20 commits into from
Mar 2, 2022

Conversation

lwasylow
Copy link
Member

@lwasylow lwasylow commented Feb 9, 2022

Adding support for inclusion and exclusion of objects and schemas using regex.

begin
  ut.run(
    a_path => 'unit_test_schema', 
    a_reporter => ut_coverage_html_reporter(), 
    a_include_schema_expr => '(user_...)|(..._user)',
    a_include_object_expr => '(bonus.*)|(.*_process_.*)',
    a_exclude_schema_expr => '(user_t..)|(t.._user)',
    a_exclude_object_expr => '(.*award.*)|(.*calc.*)'
  );
end;

Current approach is that a_include_object_expr and a_include_schema_expr silently overwrites a_include_object_expr

Closes #1053

@codecov
Copy link

codecov bot commented Feb 9, 2022

Codecov Report

Merging #1186 (2533638) into develop (cc75f85) will decrease coverage by 0.38%.
The diff coverage is 93.93%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop    #1186      +/-   ##
===========================================
- Coverage    94.77%   94.39%   -0.39%     
===========================================
  Files          104      107       +3     
  Lines         4881     5063     +182     
  Branches        22       22              
===========================================
+ Hits          4626     4779     +153     
- Misses         247      277      +30     
+ Partials         8        7       -1     
Flag Coverage Δ
11XE 93.67% <93.93%> (-0.49%) ⬇️
12.1EE 93.69% <93.93%> (-0.42%) ⬇️
18XE 94.02% <93.93%> (-0.40%) ⬇️
21XE 94.19% <93.93%> (-0.41%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
source/api/ut.pkb 93.26% <ø> (ø)
source/api/ut_runner.pkb 95.32% <ø> (+1.86%) ⬆️
source/core/coverage/ut_coverage.pkb 97.05% <93.10%> (+15.00%) ⬆️
source/core/types/ut_coverage_options.tpb 100.00% <100.00%> (+15.78%) ⬆️
...ource/reporters/ut_coverage_report_html_helper.pkb 52.77% <0.00%> (ø)
source/reporters/ut_coverage_html_reporter.tpb 88.88% <0.00%> (ø)
source/reporters/ut_coveralls_reporter.tpb 74.28% <0.00%> (ø)
source/core/ut_utils.pkb 94.44% <0.00%> (+0.25%) ⬆️
...ource/reporters/ut_coverage_cobertura_reporter.tpb 96.96% <0.00%> (+3.03%) ⬆️
... and 5 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b4d72e3...2533638. Read the comment docs.

@github-actions
Copy link
Contributor

github-actions bot commented Feb 9, 2022

Unit Test Results

       1 files         2 suites   3m 5s ⏱️
1 039 tests 1 035 ✔️ 4 💤 0
1 042 runs  1 034 ✔️ 8 💤 0

Results for commit 2533638.

♻️ This comment has been updated with latest results.

…ture/1053_exclude_include_cov_by_regex

Adding supporting tests
@jgebal
Copy link
Member

jgebal commented Feb 23, 2022

@lwasylow
It would probably be good to have those new parameters exposed in utPLSQLcli/SQLDeveloper/PL-SQLDeveloper/maven-plugin.

Can you open issues in corresponding projects, once this PR is complete and merged?

@jgebal jgebal added this to the 3.1.13 milestone Feb 25, 2022
@jgebal jgebal changed the title Initial checkin for exclude objects regex. Feature - include/exclude objects and schemas by regex Feb 26, 2022
@sonarqubecloud
Copy link

sonarqubecloud bot commented Mar 2, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

95.2% 95.2% Coverage
0.0% 0.0% Duplication

@jgebal jgebal merged commit 428eda5 into develop Mar 2, 2022
@jgebal jgebal deleted the feature/1053_exclude_include_cov_by_regex branch March 3, 2022 00:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Exclude Objects from code coverage by wildcard
2 participants