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

Mananmukim/sc 146920/verify api client library changes #16

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

MananMukim
Copy link

Verify Response Updates

@shortcut-integration
Copy link

This pull request has been linked to Shortcut Story #146920: Verify API Client Library Changes.

Copy link
Contributor

@prakhar-j prakhar-j left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

@gilbertdev gilbertdev left a comment

Choose a reason for hiding this comment

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

Everything seems to work and match bouncer code changes.

@@ -8,4 +8,7 @@
@NoArgsConstructor
public class ActivityResponse extends FCResponse {
Double emails;
Double online;
Double social;
Double employment;

Choose a reason for hiding this comment

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

This all matches bouncer class ActivityResponse, except bouncer has added a new field "message."

private String givenName;
private String phone;
private String email;
private Double risk;

Choose a reason for hiding this comment

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

This all matches bouncer's MatchResponse, though bouncer has several more fields available now.

Assert.assertEquals("household", response.getFamilyName());
Assert.assertEquals("household", response.getPostalCode());
Assert.assertEquals("household", response.getCountry());
Assert.assertEquals("household", response.getCity());

Choose a reason for hiding this comment

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

This test passes with new code.

Assert.assertEquals("0.82", String.valueOf(response.getEmails()));
Assert.assertEquals("0.32", String.valueOf(response.getSocial()));
Assert.assertEquals("0.78", String.valueOf(response.getEmployment()));
Assert.assertEquals("0.91", String.valueOf(response.getOnline()));
}

Choose a reason for hiding this comment

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

This test passes with new code.

"emails" : 0.82,
"online" : 0.91,
"social" : 0.32,
"employment" : 0.78

Choose a reason for hiding this comment

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

This is mocked for test to pass. I do wonder if we should have a test for this library with live api calls in the future.

"familyName": "household",
"phone" : "tangled",
"email" : "self",
"risk" : 0.21

Choose a reason for hiding this comment

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

Mocked for test to pass.

"emails" : 0.82,
"online" : 0.91,
"social" : 0.32,
"employment" : 0.78

Choose a reason for hiding this comment

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

Tests pass with mock.

"familyName": "household",
"phone" : "tangled",
"email" : "self",
"risk" : 0.21

Choose a reason for hiding this comment

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

Tests pass with mock.

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