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

Trans First Express: Don't pass blank name field #3133

Closed

Conversation

curiousepic
Copy link
Contributor

Remote (Failures probably due to changes to sandbox, relevant remote
test does pass):
32 tests, 83 assertions, 9 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
71.875% passed

Unit:
21 tests, 103 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed

@curiousepic curiousepic requested a review from a team February 1, 2019 20:41
@curiousepic curiousepic force-pushed the ECS_135_tfte_blank_name branch from 4f9a0bb to cd4dd48 Compare February 1, 2019 20:42
credit_card = CreditCard.new(credit_card_opts)
response = @gateway.purchase(@amount, credit_card, @options)
assert_success response
assert_equal 'Succeeded', response.message
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it worth looking for the name being absent from the request? Or will the sandbox error if you send it blank

Copy link
Contributor

Choose a reason for hiding this comment

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

It could be a unit test, alternatively.

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 did manually test that, but probably a good idea.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added case to same test.

Copy link
Contributor

Choose a reason for hiding this comment

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

I guess I was thinking about verifying that the blank name field is not added to the request. But I wasn't sure if you needed to write that into the test necessarily, or if the sandbox would error in that case.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah, I see. Yes, this was in response to the gateway throwing an error when the field was sent as an empty string, so the remote test should be inherently sufficient.

Remote (Failures probably due to changes to sandbox, relevant remote
test does pass):
34 tests, 83 assertions, 9 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
71.875% passed

Unit:
21 tests, 103 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
@curiousepic curiousepic force-pushed the ECS_135_tfte_blank_name branch from cd4dd48 to 3876a2e Compare February 1, 2019 20:55
@curiousepic curiousepic deleted the ECS_135_tfte_blank_name branch February 1, 2019 21:31
whitby3001 pushed a commit to whitby3001/active_merchant that referenced this pull request Sep 3, 2019
Closes activemerchant#3133

Remote (Failures probably due to changes to sandbox, relevant remote
test does pass):
34 tests, 83 assertions, 9 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
71.875% passed

Unit:
21 tests, 103 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
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.

2 participants