How to Perform a Thorough Regression Test

April 25, 2017 by Ethan Harmon

eCommerce Technology Magento 2
Magento 2
regression test

So, you have just pushed some new code. Or maybe you installed a new extension on your M2 store. Regardless of the feature, extension, or function added to a Magento build, it’s always best to perform a regression test afterward. Now, what is a regression test? This test essentially makes sure the site works correctly after the new code was pushed. Basically, you will need to test the site to ensure the new features did not break anything.

This isn’t a simple spot-check. You will need to do a thorough investigation of the site. New code might break the strangest, most unrelated things, but it can happen. When performing a regression test, it’s best to follow a pattern and check the site in segments. If you need a bit of direction for your tests, follow the following steps:

Check Content and Styling

Taking a look at the content and styling should be the first and easiest part of the regression test. Load your site in an incognito window and look at the home page. Are all of the images correct? Do any of the images or links break? Is the copy correct? Look carefully.

Don’t just do this for the home page. Go through your FAQ, privacy policy, terms of service, and product pages (this one is especially important). Now, not every single product page needs to receive testing, but test at least one of each product type. Take note of any styling or content issues, and if you spot several, see if you can spot a pattern.

Make Sure Drop Downs and Filters Work Properly

If you did not spot any issue with styling or content, move on to drop downs. See if the drop downs appear when the mouse hovers over them. Click through the pages to see if they load properly. If you have subcategories, ensure they are clickable and load. And while you are going through these category pages, use the filterable attributes. See if the correct number of results appear after clicking on a filter. Again, note any issues you may come across.

Test All Product Types

This is going to be different from checking the content. Instead, you will be making sure the products themselves appear to be working correctly. If you have a configurable product, see if you are able to select all of the simple options. See if custom options are selectable, if these are attached to simples. Try to add multiple simples to the cart if attached to a grouped product. Make sure all products are shoppable and can be added to the cart.

Be sure to also ensure the cart page is working. Does the cart dropdown work? Can you add and remove product quantities? On the cart page, try a few different states/zip codes to test the rates. Take a look at the subtotal and see if taxes are being applies. If all is well, click “Proceed to checkout,” as it’s time to move to the last leg of our regression test.

Complete a Test Order

When fulfilling a test order, it’s best to avoid the pricey items in your catalog. We suggest you actually create a test item with a cost of $1 and add that to the cart. Now, you should go through the checkout process in a few different ways: logged in, as a guest, and using multiple addresses (if applicable to your site).

You must also try each type of payment method to see if they work. See if the credit card option can catch an invalid card number. See if the PayPal method will redirect to their site. Now, you don’t necessarily need to complete the order, but we suggest you do so, as every step in checkout might work except the “Place Order” button. You can always refund or cancel your test orders in the back-end.

First of Many

Any issues found during the test needs to be reported to a developer to be fixed. Once the bugs are addressed, it’s time to run another regression test. This cycle repeats until the new feature works without creating any problems for the rest of the site. It’s good practice to regression test anytime something new gets pushed, so get used to the cycle and create a system for you and your team. The more you run regression tests, the fewer issues you will have in the future.

Subscribe to our newsletter for regular community updates, case studies, and more.