CARDS-2131: Increase test coverage cards-permissions - #1417
Open
sofi2002sofi wants to merge 2 commits into
Open
Conversation
veronikaslc
reviewed
Jun 16, 2023
| @Test | ||
| public void matchesForTreeWithoutResourceTypePropertyReturnsFalse() | ||
| { | ||
| NodeBuilderTree tree = new NodeBuilderTree(UUID.randomUUID().toString(), EmptyNodeState.EMPTY_NODE.builder()); |
Contributor
There was a problem hiding this comment.
missed test case of tree created from sling:resourceType other than cards/Form
veronikaslc
reviewed
Jun 16, 2023
| @Test | ||
| public void matchesForTreeWithoutResourceSuperTypePropertyReturnsFalse() | ||
| { | ||
| NodeBuilderTree tree = new NodeBuilderTree(UUID.randomUUID().toString(), EmptyNodeState.EMPTY_NODE.builder()); |
Contributor
There was a problem hiding this comment.
missed test case of tree created from sling:resourceType other than cards/Answer
veronikaslc
reviewed
Jun 16, 2023
| @Test | ||
| public void matchesForTreeWithoutResourceSuperTypePropertyReturnsFalse() | ||
| { | ||
| NodeBuilderTree tree = new NodeBuilderTree(UUID.randomUUID().toString(), EmptyNodeState.EMPTY_NODE.builder()); |
Contributor
There was a problem hiding this comment.
missed test case of tree created from sling:resourceType other than cards/AnswerSection
Contributor
|
|
Contributor
|
|
Contributor
|
jacoco.zip |
sofi2002sofi
force-pushed
the
CARDS-2131-permissions-test
branch
from
August 26, 2023 17:23
7433108 to
0912d65
Compare
sdumitriu
force-pushed
the
CARDS-2131-permissions-test
branch
from
August 26, 2023 21:54
0912d65 to
ef9b731
Compare
veronikaslc
force-pushed
the
CARDS-2131-permissions-test
branch
from
December 4, 2025 21:11
ba0bf6f to
553181e
Compare
Modernize the revived tests and complete the module coverage to 100%: - migrate the tests to the current platform APIs: the Jakarta servlet request built through the public Builders API, Mockito 5, sling-mock 4 - drop the Mockito runner in favor of plain mocks with reflection injection, since concurrently running runners collide on Mockito's global listener registry under the parallel surefire configuration - remove the redundant osgi.cmpn dependency: it bundles an old copy of org.osgi.util.converter that shadows the one needed by the scripting BindingsValuesProvider tracker, breaking every Oak-backed test context - raise the sling-mock resource resolver factory timeout, the default 500ms is not always enough when several Oak-backed contexts start in parallel - cover the previously untested paths: non-matching restriction targets, restriction comparison when removing an entry with restrictions, mismatched rule/principal/restriction removal attempts, forms without a subject, subjects with no matching ancestor, missing thread resource resolvers in the restriction factories - drop the meaningless constructor smoke tests and rename the remaining vague test names - remove the module's coverage exemption, restoring the default 1.00 required instruction coverage ratio
sdumitriu
force-pushed
the
CARDS-2131-permissions-test
branch
from
July 27, 2026 20:37
553181e to
a62525d
Compare
| } | ||
|
|
||
| @Test | ||
| public void getPatternForOakPathAndNotEmptyRestrictionsSetReturnsAnswerRestrictionPattern() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.