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

add unit tests for policy specification #211

Conversation

Ian-Nara
Copy link
Contributor

@Ian-Nara Ian-Nara commented Sep 12, 2023

New tests to validate desire behavior:

  • tokenGenerateNewParticipantNoPolicySpecified
  • tokenGenerateNewParticipantWrongPolicySpecified
  • tokenGenerateNewParticipantNoPolicySpecifiedOlderKeySuccessful
  • tokenGenerateNewParticipantWrongPolicySpecifiedOlderKeySuccessful
  • identityMapNewParticipantNoPolicySpecified
  • identityMapNewParticipantWrongPolicySpecified
  • identityMapNewParticipantNoPolicySpecifiedOlderKeySuccessful
  • identityMapNewParticipantWrongPolicySpecifiedOlderKeySuccessful

Existing tests to validate desired behavior:

  • tokenGenerateRespectOptOutOption
  • identityMapRespectOptOutOption
  • other existing identity map and token generate tests that do not specify policy for old participants

@Ian-Nara Ian-Nara marked this pull request as ready for review September 12, 2023 19:58
@Ian-Nara Ian-Nara requested a review from zaiweidu September 12, 2023 19:58
@@ -738,6 +738,51 @@ void tokenGenerateNoEmailOrHashSpecified(String apiVersion, Vertx vertx, VertxTe
});
}

@Test
void tokenGenerateNewParticipantNoPolicySpecified(Vertx vertx, VertxTestContext testContext) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Are these tests covering the right things given that the parent PR is not using the new oldest key function from uid2-shared?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have updated the unit test for this change

@zaiweidu zaiweidu force-pushed the zdu-UID2-1776-Add-policy-check-for-Publisher branch from 1256174 to 6cfbbe5 Compare September 18, 2023 22:00
…UID2-1778-unit-test-optout-policy

# Conflicts:
#	src/main/java/com/uid2/operator/vertx/UIDOperatorVerticle.java
@zaiweidu
Copy link
Contributor

This PR was combined with #207 and merged into Master branch.

@zaiweidu zaiweidu closed this Sep 21, 2023
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.

3 participants