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

TransFirst Express: Fix blank address2 values #3231

Merged

Conversation

britth
Copy link
Contributor

@britth britth commented May 22, 2019

If a user passes in an empty string for the address2 field, their
transaction will fail on this gateway. This PR ensures that address2
only gets passed through if it is present and not blank. Additionally
it cleans up some remote test failures. test_successful_verify still
fails in the remote tests, but failure is unrelated to change.

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

Remote:
33 tests, 107 assertions, 1 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
96.9697% passed

@britth
Copy link
Contributor Author

britth commented May 22, 2019

@jknipp

@jknipp jknipp requested a review from a team May 22, 2019 20:47
response = @gateway.verify(credit_card, @options)
assert_success response
assert_match 'Succeeded', response.message
end
Copy link
Member

Choose a reason for hiding this comment

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

Why did we remove the tests for Amercian Express, Mastercard and Discover?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It seems like something has changed since these were initially added such that only the visa card actually succeeds for the verify test. Looks like they've been broken since at least earlier this year (#3133). I haven't had luck yet, but I can try to dig into the docs some more to figure out why that's the case - would that be better left to a separate PR (and change this back) or a fix here?

Copy link
Member

Choose a reason for hiding this comment

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

I'd do a cursory look to see if TransFirst provides updated test cards, I wouldn't spend more than ~30 mins on that. If you can't find them, revert the change and notate the PR with the test(s) that fail and that they are unrelated to your change. This is an instance where it's ok to ignore the test and move on.

@britth britth force-pushed the ecs-334-tfte-empty-string-address2 branch from 1f6f66e to 9c32309 Compare May 23, 2019 13:35
Copy link
Member

@jknipp jknipp left a comment

Choose a reason for hiding this comment

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

👍 LGTM

@britth britth force-pushed the ecs-334-tfte-empty-string-address2 branch from 9c32309 to fa02b2b Compare May 24, 2019 13:42
If a user passes in an empty string for the address2 field, their 
transaction will fail on this gateway. This PR ensures that address2 
only gets passed through if it is present and not blank. Additionally 
it cleans up some remote test failures. test_successful_verify still 
fails in the remote tests, but failure is unrelated to change.

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

Remote:
33 tests, 107 assertions, 1 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
96.9697% passed

Closes activemerchant#3231
@britth britth force-pushed the ecs-334-tfte-empty-string-address2 branch from 83e1c51 to b69fcad Compare May 28, 2019 13:52
@britth britth merged commit b69fcad into activemerchant:master May 28, 2019
whitby3001 pushed a commit to whitby3001/active_merchant that referenced this pull request Sep 3, 2019
If a user passes in an empty string for the address2 field, their 
transaction will fail on this gateway. This PR ensures that address2 
only gets passed through if it is present and not blank. Additionally 
it cleans up some remote test failures. test_successful_verify still 
fails in the remote tests, but failure is unrelated to change.

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

Remote:
33 tests, 107 assertions, 1 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
96.9697% passed

Closes activemerchant#3231
@britth britth deleted the ecs-334-tfte-empty-string-address2 branch October 29, 2019 18:03
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