I need to test my subscription.create code. Can I do that with a fake paymentMethodToken or do I have to create the customer/payment to get the token?
Full disclosure: I work as a developer at Braintree
The best way to test your subscription is through your Sandbox account.
Create or login to your Sandbox account.
Set up the plan you would like to test.
Create a test customer and a payment method using one of these testing values.
Create a subscription with the token from the payment method you created with the test values.
Related
I'm fairly new to the BDD/Cucumber/Ruby field and I'm trying to help my team with writing new API tests in Cucumber/Ruby and one of the tests we need is a to check wether users can log in via Facebook.
So the behaviour looks like the following:
Scenario: As a user, when I connect with a verified facebook account for the first time, then I can sign up a new account
Given I am a new user
When `I connect with a verified facebook account`
Then I can create a new account
I have step definitions for all steps apart from the one in backticks above.
Could you help?
Try
Given I am a new user
And I have a verified facebook account
When I connect with my facebook account
so you can separate setting up the account, from using the account to connect to your application.
Then you have a number of ways to make this work. You could
Use a real facebook account to connect
Record the interaction using a facebook account using something like https://github.com/vcr/vcr, and use the recording
Mock the facebook account
I think I'd probably go with 2.
I want to make a interface so that user can register and login themselves at citrus using PHP technology and use that wallet in their payment. Does citrus provide any API for this?
Yes, Citrus-Pay does provide APIs for Integrating with Wallet where you can define your own interface.
Alternatively, you may also use the standard UI provided by Citrus. If you want to go forward with APIs,
1) Get a signup token using the API mentioned in this link: https://developers.citruspay.com/documentation/wallettab/identity-profile/oauth-token-api/
2) Call Find Or Create User API as next step. This API will trigger an OTP to the customer's mobile number passed in the request.(A Citrus Wallet is uniquely identified by a mobile number)
API on dev guide: https://developers.citruspay.com/documentation/wallettab/identity-profile/find-or-create-a-wallet/
3) Now this OTP has to be entered in an appropriate API.Which API to be used is told in the response of find or create wallet API called in step 2. (Password-based login is also supported).
It could be sign in with MOTP API ( for an existing citrus wallet customer) or verify mobile and sign API ( for new wallet accounts just being created)enter link description here
4)You will get a full access token (prepaid_pay) in response.Pass this in header of all other APIs which you need to call on behalf of user.
5)For Eg: To make a payment using the customers existing wallet balance , use the following API : https://developers.citruspay.com/documentation/wallettab/pay-using-citrus-wallet/make-payment/
Hope this helps
I am trying to develop a wrapper for the Square Connect API. I am looking for a sandbox account or a way to import test data to a new account so I can get started quickly with the development side.
Thank you!
For future reference for people who land here from Google, Square now offers this. Every account is given a set of sandbox credentials, as well as there is an anonymous sandbox you can use without logging in.
Login here and create an application. Once you create the application, there will be Sandbox settings that you can use.
https://connect.squareup.com/apps
Here is some more documentation:
https://docs.connect.squareup.com/articles/using-sandbox/
https://docs.connect.squareup.com/ (general guide)
Unfortunately it doesn't seem like there is a dashboard where you can see the transactions in Sandbox mode, but I suppose it's not 100% needed.
You can download the Square register app on a mobile device and submit cash transactions to a live merchant account. Not ideal, but this is what I do to add test data.
i have searched a lot but only got following login url for sagepay test account.
https://test.sagepay.com/mysagepay/login.msp
Can any one please help me from where i can create account to log in at above screen.
I have already created simulator account at
simulator account
To use this test sagepay login you need a normal sagepay payment gateway / merchant account or have a MySagePay account. This test URL is given to clients who have access to the live side for their day to day transactions.
If you have an account with Sage you can get them to set up the test environment for you.
create mysagepay test account
http://www.sagepay.co.uk/sign-up-for-beta-testing
I was just wondering if anybody knows how to test magento's payment options.
I have got a few questions.
Do I need to change any code within any of the pages?
Do I need to make any changes to the admin settings ?
Is there a simple setting to test these payment methods out?
Is there only certain payment methods that you can actually check?
No you dont need to change any code. Its all handled from backend.
Generally for development purpose we use Cash on delivery or Check/Money Order payment method.
So you just need to enable these method from backend.
For Testing Credit Cards enable 'Saved CC' Payment Method and during checkout use test credit card type VISA, card number 4111111111111111 with any date of future for Expiration Date and any cvv number
Additionally for proper payment gateway integration You will need to purchase payment gateway which will provide Magento Module along with it. This Payment Method will have 2 modes test and live that are configurable from banckend. So with test mode you can continue development and testing.
Similarly with Paypal. Yo can setup Sandbox test account. Module is already there.
If you want to use Express Checkout:
Go to developer.paypal.com and log in using your PayPal account (it doesn't matter if the acount is empty or not).
Click on the menu item on the top dashboard and then select Accounts from the sidebar.
There, you will find 2 test accounts already set for you. You can modify the existing acounts or create new ones.
This post may help you.
Yes you can test on local host with setup sendbox account.
You can create a 99% discount coupon.
PS: From my experience, that's the standard to test live websites. The sandbox payment only works on staging/dev sites, as it puts the entire website on dev mode.