8000 Add initial tests for the framework registry by stianst · Pull Request #31433 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content

Add initial tests for the framework registry - #31433

Merged
stianst merged 1 commit into
keycloak:mainfrom
stianst:testpoc-framework-tests
Jul 19, 2024
Merged

stianst merged 1 commit into
keycloak:mainfrom
stianst:testpoc-framework-tests

Conversation

@stianst
@stianst stianst commented Jul 19, 2024
Copy link
Copy Markdown
Contributor

Closes #31432

@stianst
stianst requested a review from a team as a code owner July 19, 2024 10:54
Closes keycloak#31432

Signed-off-by: stianst <stianst@gmail.com>
@stianst
stianst force-pushed the testpoc-framework-tests branch from 95ca20a to a860db9 Compare July 19, 2024 10:55
assertClosed(parentAndChildTest.parent, parentAndChildTest.child);

registry.beforeEach(parentAndChildTest);
Assertions.assertNotSame(child1, parentAndChildTest.child);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you check the parent here the references will be different than from the previous beforeEach, right?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, exactly. Didn't check that explicitly here since it's already checked that it's closed, and have tests that covers making sure a "closed" resource isn't re-used ;)

@pedroigor pedroigor left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In addition to "self-coverage" the framework, it makes indeed clear how the lifecycle works and what to expect.

@stianst
stianst merged commit 02e3339 into keycloak:main Jul 19, 2024
@stianst
stianst deleted the testpoc-framework-tests branch July 19, 2024 12:45
stianst added a commit to stianst/keycloak that referenced this pull request Jul 25, 2024
Closes keycloak#31432

Signed-off-by: stianst <stianst@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Testsuite PoC - Add tests for the testing framework itself

2 participants

0