Category: Testing

Re-Introducing Jenkins: Automated Testing with Pipelines

As our applications become more complex – with Composer dependencies, Webpack build scripts, and per-environment variables – we inevitably reach a point where testing all of these different intricacies becomes slow and laborious, especially when you’re tearing down and rebuilding the entire environmen...

A Favor for Your Future Self

Alicia Sedlock, on removing a large section of a website:… it’s the ultimate “I really hope this doesn’t break something else” situation. It was a stressful and tedious effort of triple checking that the things we were removing weren’t dependencies elsewhere. To be honest, we wouldn’t have been able...

An Intro to Monkey Testing with Gremlins.js

A common idiom in our industry is, “You never can predict how the user will use your product once they get it in their hands.” If you’ve ever watched a stakeholder use a website or web application for the first time, you may know this firsthand. I can’t count the number of times I’ve seen ...

Where Are The World’s Best Open Device Labs?

   Every developer knows that just because a website looks like and does what it’s meant to on the latest iPhone, doesn’t mean it will work across every mobile device. In this article, we’ll highlight some of the many open dev...

A Crash Course of Changes to Exception Handling in PHP 7

Exception handling saves your code in the most unusual circumstances. PHP 7 has introduced two new classes that assist a developer in handling errors with ease, and that’s what we’ll look at in this post. Before the introduction of these classes in PHP 7, exception error classes were written to handle the d...

Testing PHP Code with Atoum – an Alternative to PHPUnit

If you’ve been around PHP for more than a little while, you’ve no doubt started to test your code. And if you ask anyone in the PHP space what to use for writing unit tests, likely the first answer that they’ll give you is PHPUnit. It’s the de facto standard in the PHP community, and with good reason. But it’...

How to Test React Components Using Jest

This article is by guest author Jack Franklin. SitePoint guest posts aim to bring you engaging content from prominent writers and speakers of the JavaScript community. In this article, we’ll take a look at using Jest — a testing framework maintained by Facebook — to test our ReactJS components. WeR...

Quick Intro: PhpCompatibility for PHPCS – Are You PHP7 Ready?

Sooner or later, there will come a time when you will need to migrate your projects to different PHP versions. How will you check if you’re compatible with a PHP version different to the one you’ve been developing on? One possibility is always to install the version of PHP we want to migrate to, run […...

JavaScript Refactoring Techniques: Specific to Generic Code

In a recent thread on SitePoint’s forums, some code was given to let one dropdown box control when another dropdown box is visible. Even though the code worked just fine, I realized that it left much to be desired. It was brittle and incapable of withstanding even small changes to the accompanying HTML. Here is t...

Static analysis with PHPSA: PHP Smart Analyzer

One requirement that never changes whether you are working on your projects alone or in a team, on small projects or big, is Code Quality. The bigger the project and the team, the harder it gets to maintain it.A good way of slowing this increase in difficulty down is to use static analysis tools. Static analysis is t...