Testing or more specifically, front-end testing is undeniably in the top 3 of the most complex topics associated with Angular & front-end development.
When one is confronted with this complexity, it is tempting to give up, but at what cost? It is totally possible to develop an application without tests but is it really faster? What happens to code maintainability a few months or sometimes just weeks later? Can we serenely refactor and deploy our apps regularly while it is getting older and complex in our hands? What about end-to-end tests, they sound attractive but are they enough?
This workshop presents, through practical exercises, pragmatic Angular testing techniques. You will also learn how to implement simple, meaningful, maintainable, and above all profitable tests.
What attendees will learn
During this workshop, you will learn:
- how to implement tests for your Angular application with the Test-Driven Development approach,
- how to choose the type of tests that fits best depending on the context,
- how to decouple tests from code to encourage refactoring and tidying up when needed,
- how to implement maintainable and human-readable tests,
- the difference between dummies, stubs, spies, mocks, and fakes + how and when to use them,
- the difference between isolated, shallow & integration component testing,
- how to choose the right scope for your tests,
- lots of tips & tricks that will help you adopt a pragmatic testing strategy.
Course Benefits
You will learn how to write profitable tests, in other terms, you'll learn how to reduce the cost of writing and maintaining tests while increasing their trustworthiness. This will boost the whole team’s confidence and efficiency. You will be able to choose the right tests to implement and how to implement them. You will also learn how to leverage the benefits of Progressive TDD to change your code with confidence, and you will be able to decouple your tests from the tested code so you change the code structure without having to fix tests all the time.
Workshop Agenda
👨🏻🏫 Overview
👨🏻🏫Introduction to testing
- Why test?
- What should we expect from a test?
- The different types of tests: Narrow & Wide vs Unit & Integration.
👨🏻🏫Jest
- Do you need Jest?
- Pros & cons.
💻 Exercise: First Test
- Progressive TDD.
- Making tests readable and maintainable with Object Mothers.
- Tips & Tricks.
- Testing asynchronous code.
💻Exercise: Test Doubles
- Dummies vs Stubs vs Mocks vs Spies vs Fakes: which one should we use?
- Contract testing fakes
👨🏻🏫Component Testing
- Different types of component tests: Integration vs Shallow vs Isolated.
- Angular Testing Library: Pros & Cons.
- Cypress Component Testing: Pros & Cons.
- Playwright Component Testing: Pros & Cons.
💻Exercise: Testing Components with Playwright Component Testing
- Which Test Doubles should we use?
- Testing Inputs & Outputs based communication.
👨🏻🏫Visual Regression Testing
- Testing the presentation.
- Visual regression testing with Playwright Component Testing
👨🏻🏫Building your Pragmatic Testing Strategy
- What should we test and how?
🙋♀️ Q/A
Angular Core Team, Google | USA
Angular Core Team, Google | France
Angular Core Team, Google | USA
Angular Core Team, Google | USA
Angular Core Team, Google | USA
Lead of Frontend Competence Center, Avenga | Poland
Consultant and Author, softwarearchitekt.at | Austria
Developer Evangelist for Web and Cloud, UK
Principal UI Architect, Cisco | Canada
Front End Tech Lead, Tikal | Israel
Trainer & Consultant, AngularArchitects.io | Austria
Senior Frontend Developer, BigPicture | Poland
Frontend Engineer & Angular Trainer, BASF | Germany
Dev Manager , Xebia Poland | Poland
Front-End Architect, Spyrosoft | Poland
Senior Frontend Developer, Axel Springer NMT | Germany
Software Development Cook, Teacher & Coach, GDE | France
GDE, Trainer, Senior Software Engineer, Push-Based.io | Albania
Senior Developer Advocate, Okta | USA
Teacher and Consultant, ngIndia | India
Chief Technology Officer, Builder.io | USA
Frontend Developer, Prowly PR Software | Poland
Staff Software Engineer, ClickUp | UK
CEO, push-based.io | Austria
Independent Consultant, Architect, Developer & Trainer, Poland
Trainer and Consultant, AngularArchitects.io | Austria
Principal Angular Consultant and Trainer, Lowgular | Poland
Technical Lead, ADB SAFEGATE | Sweden
Solution Architect, Future Processing | Poland
Founder & Developer, GDE, e-square.io | Israel
Lead Performance Engineer, Trainer & Consultant, push-based.io | Austria
Director of Engineering, FlowUp |
Full Stack Engineer, push-based.io | Mexico
Nx Champion 🏆 / Angular Architect, Angular Bros | Poland
Sign up to receive updates about NG Poland, including workshops, speaker previews, ticket launches, NG Awards, Behind the Code Magazine, CFP details and other exclusive content. We won’t spam you and will only send you emails we genuinely think you’ll find interesting. You can unsubscribe at any time and you can find more information here.