App & Browser Testing Made Easy

Give your users a seamless experience by testing on 3000+ real devices and browsers. Don't compromise with emulators and simulators

Get Started free
Home Guide How to test payments in Shopify

How to test payments in Shopify

By The Nerdy Geek, Community Contributor -

Shopify Test Payments is a feature in Shopify that helps you ensure that whenever a customer has purchased a product, the payment can go through smoothly. However, for anyone who is new to Shopify, testing payments can be a little confusing on it. 

This article explores Shopify and how to test Shopify payments and maximize its benefits further.

What is Shopify

How to test payments in Shopify 1 Shopify is an Ecommerce platform that started over ten years ago that allows anyone to set up an online store and sell their products. In Shopify, not just online, Merchants can even sell their products in person with Shopify POS. 

Shopify now caters to businesses of all sizes and scales and has become the leading commerce platform in a very short span. Shopify gives you the platform to sell products online, in-store, on social media, and just anywhere and everywhere. 

With over 20% of eCommerce websites on Shopify globally, it is important to deliver a seamless user experience. This article focuses on how to test Shopify Payments using different methods for a smooth checkout.

Why do you need Test Shopify Payments

It is essential for everyone who is a business owner on Shopify to understand all the available modes of payment and the entire payment process on Shopify. 

There is a range of payment options available on Shopify that can be opted for by the Shopify admin, and the customers can choose any one of those selected methods. Depending on what method you choose to present to the customers, you will have to consider the underlying factors. 

How to test Shopify Payments

Source

For example, If you allow your customers to use Credit Cards, you can either go for Shopify Payments or a third-party provider. Other options than credit cards would be online payment options such as Amazon Pay, PayPal, etc. You can even enable alternative payment methods such as cryptocurrencies. 

So, you can imagine the range of options that you need to ensure that they work seamlessly and do not have any serious bugs. In order to ensure that, one must thoroughly test all the payment modes that are going to be chosen for the customers. 

What are the methods to test payments in Shopify?

Now that you know why it is so crucial to test payments in Shopify, let us look at some of the available methods to test that. 

1. Using the Shopify_payment_capture gem

The Shopify_payment_capture gem is great for testing purposes as it allows you to actually process the payments without having to go through the entire checkout process. This is quicker and easier as one can test the scenario quickly without doing the entire process. 

2. Using the Shopify sandbox

Shopify also offers a sandbox environment that can be used to test new features. This can also be used to test payments without affecting the actual environment. 

3. Using test mode

Test mode is a new feature of Shopify Payments and is the most widely used one. It is used to test how customers can pay for their orders and, later, how those orders are processed. 

Once the test mode is activated in your environment, real credit cards can’t be used for payments. Along with that, some local payment methods, such as iDEAL and Sofort, become unavailable in the checkout stage, and hence, you must ensure that test mode has not been activated in your production environment. 

Once you are done testing, you can simply deactivate the test mode so that real credit cards can be used further. 

Test Shopify Website on Real Devices

How to enable test mode for Shopify payment

As mentioned, you need to enable Test mode in Shopify payments before you start creating test orders. Below are the steps that demonstrate how can you enable test mode

Step 1: Login into your Shopify account using your email and password.  Login Shopify to test Payments

Step 2: Select Payment Providers: 

First, Go to Settings.

Enabling Test Mode in ShopifyUnder Settings, you can select Payments >> Payment Providers.  Choose a Payment Provider to test Shopify Payements

Step 3: Click on Choose a Provider option next.  Choose a Provider option to test Shopify Payments

Step 4: Enable the Test Mode by Clicking on the Bogus Gateway option for testing Select Bogus Payment Gateway to test Shopify Payements

Step 5: Click on activate the Bogus Gateway for testing option. Select Bogus Gateway for Testing Payments in Shopify

You can also deactivate the same anytime, through the same options. Enabling Test Mode in Shopify to Test Payments

Test successful transactions for Shopify Payments

In order to simulate a successful transaction, you can use the following information when the credit card details are asked at checkout

  • Name on card: Enter at least any two words.
  • Security code: Enter any three digits.
  • Expiry date: Enter any date that lies in the future.
  • Card number: Use any of the following numbers taken from Shopify Card Payments Test Data

 

Card TypeTest Credit Number
Mastercard5555555555554444
Visa4242424242424242
Discover6011111111111117
American Express378282246310005
JCB3530111333300000
Diners Club30569309025904

Test failed transactions for Shopify Payments

In order to simulate any failed transaction, you can use the following information when the credit card details are asked at checkout, and explore the various error messages that will be displayed to the customer. 

  • An expired year in the past generates an invalid expiry year message.
  • An expired month, for example, 14, generates an invalid expiry month message.
  • A two-digit security code can be used to generate an invalid security code message
  • An incorrect credit card number, for example, 4000000000000002, can be used to generate a card declined message.
  • Credit card number 4242424242424241 can be used to generate an incorrect number message.
  • Credit card number 4000000000000259  can be used to simulate a disputed transaction.

Testing Shopify on Real Devices using BrowserStack

We all know that there is no method other than Testing on Real Devices that can ensure accurate results and are effective. Now, every user can be using your Shopify payments from a different device altogether. However, in order to ensure a seamless user experience, you need to test the payments from all such ranges of devices. 

Maintaining a large variety of devices is not a cakewalk, as it requires a lot of investment and effort in procuring and maintaining them. Buying a subscription to a real device cloud like BrowserStack enables developers and testers to test their websites and mobile applications across 3000+ real browsers, operating systems, and mobile devices.  

BrowserStack’s real device cloud provides QA teams with the ideal testing infrastructure for comprehensive mobile web testing.

Test Shopify Website on Real Devices

Along with that, BrowserStack offers you the Shopify plugin that you can install easily and use Shopify along with BrowserStack and its listed devices. Using BrowserStack’s Shopify plugin, you can take cross-browser and cross-device screenshots using one click in less than 30 seconds. You can even find UI bugs in your Shopify product and pages.

Note: You can find the steps to install the Shopify plugin and use the one-click screenshots at BrowserStack – Shopify Integration.

Once the plugin is installed, you can use any of the available Browser-OS combinations and test your Shopify Payments. 

Testing Shopify Payments on Real Devices with BrowserStack

Tags
UI Testing Website Testing

Featured Articles

Tips to Boost Speed of Shopify Website

Browser Compatibility Check for Shopify Websites

App & Browser Testing Made Easy

Seamlessly test across 20,000+ real devices with BrowserStack