Session
From zero to hero with Cypress
SHORT ABSTRACT
Have you heard of Cypress but never really had the chance to play around with it? Well here you go!
Cypress is one of the most popular tools for end-to-end test automation. Actually it has a lot of 'framework' characteristics. This means that in order for us to fully 'yield' its potential we need to do things a certain way and keep to certain rules or best-practices.
That is exactly what this workshop is all about! After this workshop you will have the skills and knowledge to work on any Cypress project or setup your own in an effective and sustainable way. You'll be aware of the pitfalls!
================================
FULL ABSTRACT
In this tutorial we will not just dive in and start automating (like crazy) just because we can. We will build a solid foundation first by exploring why well designed (and implemented_ test automation frameworks still seem to fail and some (technically) lesser designed frameworks could still add more value. The questions we need answering before actually diving into tools is: "Why do we need or want a test automation framework?" and naturally also "What characteristics are most valuably to my/your specific situation?". Once you understand the (and your) purpose for (e2e) test automation, we will start shaping our test automation framework. To make easy to get started I will provide a (publicly hosted) system-under-test (SUT) for which we will build a test automation framework using Cypress Cypress is one of the most popular tools in test automation and has a lot of 'framework' characteristics. This implies that Cypress wants us to do things a certain way. That doesn't mean that the learning curve is a steep one: on the contrary! Cypress is actually not that difficult to master but it might look 'funny' at first. You'll get used to it! During this tutorial we will cover all of it's typical characteristics and how it differs from other great tools like playwright, testcafé and selenium. This tutorial is meant for Cypress-beginners. However some experience with (e2e) test automation and some (very) basic programming skills (also when that's not with JS/TS) will come of use. After this tutorial you will be familiar with the most common features and use cases Cypress has to offer. You will be able to setup and implement a sustainable test automation framework containing end-to-end (e2e), API and component testing using Cypress. By the end of the day you will be ready to share your skill and knowledge with your organisation or team.
==========================================
COLLABORATION
Test automation frameworks and projects do not always have the best reputation. When looking at such projects we often come across many of the same issues. Typically we can divide these issues into methodical issues (soft) such as a undefined test (automation) strategy, and technical issues (hard) such as poor maintainability and flakiness.
This workshop aims to address both issues. First we will have a look at how a well defined test automation strategy (using the test-pyramid and alike figures) can actually help a team with their test planning (how and what are we testing?) during refinements by clarifying test responsibilities and roles.
Secondly we will learn how to make a test automation project effective, efficient and maintainable for an entire team (not just the TA engineer) to collaborate on.
We will start learning Cypress with a exercise to setup (and run) a 'first test' (according to our strategy). We will be testing public app (SUT) that is hosted for the sake of this workshop (to avoid installation issues and loose time over this).
Next we will improve upon our project with an assignments/exercises on using fixtures and hooks to make tests less dependent and more effective.
After that wil will thoroughly cover best-practices for selector and locators to simulate an end-user as best we can and explore some dangerous pitfalls.
Finally we will implement a popular design pattern called the 'Page object model' to improve maintainability. Then we improve upon the POM by adding interactions to it. For the fast learner we have a variation (bonus) where we add 'composition' (replacing interactions) which makes it even more DRY and maintainable.
1. How to set up an effective TA framework using Cypress
2. 2 Ways to implement the Page object model (basic: only abstracting selector/locators, advanced: make use of 'composition')
3. Best practice selector- and locator strategies
===================
All participants are required to bring their own laptop with a (local) installation of the latest NodeJS and a working internet connection.
No docker (compose) required. We will work with a publicly hosted SUT.
No hardcore JS/TS skill are required. Just some (very) basic programming (in any language) will be sufficient to keep up during the workshop. There is little JS/TS syntax that would cause complexity.
Please note that Sessionize is not responsible for the accuracy or validity of the data provided by speakers. If you suspect this profile to be fake or spam, please let us know.
Jump to top