Last month I survived my first public presentation, at Bucharest WordPress Meetup, our local monthly meetup. Special thanks to Marius Vetrici, Bogdan Dragomir and Cezar Cazan for all the support they provided.
– or if the client wants some changes.
Depending on how much time passed since we last worked on that project, we might or might not remember all the features of that project. So, changing things could break some functionality.
This can happen also when we work on a large project, that takes several months to develop. We will not remember all the little details of the project, so, changing things could break some functionality.
When we work on a large project, when more teams are working together, and each developer is implementing a totally different feature, we have no way of knowing in what way our changes will affect the rest of the features, so, changing things could break some functionality.
As we also discussed in our previous meeting, we want to upgrade the theme or a plugin in our application, but even if we know what was changed, we do not know how these changes are affecting the application, because, changing things could break some functionality.
What could we do to avoid this? Let me tell you a bit about Acceptance Testing.
What is Acceptance Testing ?
Acceptance Testing is the functional testing of a USER STORY. The USER STORY captures the WHO, WHAT and WHY of a requirement, in a very simple / condensed way.
Acceptance Testing is the type of testing that is performed in order to certify that the application respects the requirements.
Acceptance Testing is the method of confirming that the system behaves as predicted, FROM THE USER’S PERSPECTIVE.
Why Use Acceptance Testing ?
Because we develop complex web applications, we need to use a testing framework. A testing framework will allow us to test all links, pages, forms, element interaction, and anything else in just minutes, using automated test scripts.
What Testing Framework to Use ?
We are already familiar with PHP, so we could useCodeception, this testing framework allows us to write our tests in PHP. Also, Codeception can naturalize the scenarios we create, converting these into plain English. This makes it so that also the non-technical people can read and understand the tests.
Codeception allows us to write our tests in PHP, and the locators are stable: we can use : names, labels, CSS to match the elements in our tests.
Codeception modules integrate with all popular PHP frameworks, but these work for any website, even if you use a custom CMS or framework. Codeception keeps the tests in one place, structured, readable and very easy to use.
The syntax is simple and just by looking at the test code we can have a clear idea of what the test is doing.
Photo credits: Cezar Cazan, Bogdan Dragomir, and Vladd.