Skip to content
This repository has been archived by the owner on Jan 4, 2023. It is now read-only.

@orta: Fixes for Kiosk CC testing on Staging, Unresolved bids, Bidding errors #510

Merged
merged 11 commits into from
Sep 24, 2015

Conversation

ashfurrow
Copy link
Contributor

Fixes:

@ashfurrow
Copy link
Contributor Author

  • Add Stripe's test publishable key.
  • Add CardFlight's API key and merchant account.
  • Write code to use one or the other against the API depending on app settings.
  • Test against staging with Stripe's test CC's.

@ashfurrow ashfurrow changed the title [WIP] Fixes for Kiosk @orta: Fixes for Kiosk Sep 23, 2015
@ashfurrow ashfurrow changed the title @orta: Fixes for Kiosk @orta: Fixes for Kiosk CC testing on Staging Sep 23, 2015
let signal = RACSignal.`if`(boolSignal, then: self.updateUser(), `else`: self.createNewUser())

// After update/create signal finishes, add a CC to their account (if we've collceted one)
Copy link
Contributor

Choose a reason for hiding this comment

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

typo: collected

@orta
Copy link
Contributor

orta commented Sep 23, 2015

structurally it looks good, but there's a lot of code in here with changes and no tests

@ashfurrow
Copy link
Contributor Author

Cool, I'll add some tests.

@@ -3,8 +3,13 @@ import UIKit
class DeveloperOnlyView: UIView {

override func awakeFromNib() {
let shouldShow = AppSetup.sharedState.showDebugButtons && AppSetup.sharedState.useStaging
let notTests = NSClassFromString("XCTest") == nil
self.hidden = !shouldShow && notTests
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The logic here was messy, so I made it prettier.

@ashfurrow
Copy link
Contributor Author

OK, got the tests passing again, and added some minimal tests. ConfirmYourBidPINViewController needs to be split into a view model, I've opened #511 to do so when I get a chance.

The dev-only views were showing in some tests, which has been correct. Also, I changed the placeholder for the manual CC entry's year to be in the future.

@ashfurrow ashfurrow changed the title @orta: Fixes for Kiosk CC testing on Staging @orta: Fixes for Kiosk CC testing on Staging, Unresolved bids Sep 23, 2015
@ashfurrow ashfurrow changed the title @orta: Fixes for Kiosk CC testing on Staging, Unresolved bids @orta: Fixes for Kiosk CC testing on Staging, Unresolved bids, Bidding errors Sep 23, 2015
expect(subject.bidderPosition?.id) == "5437dd107261692daa170000"
}

it("maps bid deatils into a proper request") {
Copy link
Contributor

Choose a reason for hiding this comment

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

chore: typo

@orta
Copy link
Contributor

orta commented Sep 24, 2015

Blocker, this test seems wrong, either in the logic or the name
screen shot 2015-09-24 at 07 13 09

@ashfurrow
Copy link
Contributor Author

No, that's correct. The bid has been submitted, we just don't know whether or not the user is the highest bidder. "Bid Submitted" is the most neutral language we could find. The previous screenshot was incorrect, as well, since it indicates you need to increase your bid (the test setup was wrong).

@ashfurrow
Copy link
Contributor Author

I'll rename the test, remove "error" – good idea.

@orta
Copy link
Contributor

orta commented Sep 24, 2015

Ace 👍

orta added a commit that referenced this pull request Sep 24, 2015
@orta: Fixes for Kiosk CC testing on Staging, Unresolved bids, Bidding errors
@orta orta merged commit 81b6037 into master Sep 24, 2015
@ashfurrow ashfurrow deleted the error-messaging branch October 8, 2015 20:51
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants