Skip to main content

Testing Fundamentals [EpicWeb]

5h 16m 16s
English
Paid

Course description

In this workshop, Artem Zakharchenko, testing expert and creator of the Mock Service Worker API mocking library, will guide you through creating your own version of the Vitest testing framework.

Building a testing framework from scratch will give you a deep understanding of how the pieces fit together, and change the way you think about testing for the better.

Read more about the course

What You'll Learn

The workshop is broken out into four parts, each with its own challenges and exercises that build upon the last:

Principles

First, you'll explore the principles and mental models that underlie testing strategies. This is where you will begin to distinguish between the intention of your code and its implementation details. When you focus the intention of what your code should accomplish, you can write tests that are more resilient to change.

Test Structure

Next, you'll do a deep dive into the structure of the testing framework. You'll create your own expect and test functions, configure your test environment, and use hooks to manage side effects in your tests.

Testing Asynchronous Code

Testing asynchronous code requires a slightly different approach when compared to testing synchronous code. Here you'll practice with testing promises and async functions, as well as handling errors and rejections.

Moving to Vitest

Once you've learned the fundamentals of testing and built your own mini-framework, you will migrate your tests to the Vitest framework. This process will cement your understanding of not just the "hows", but also the "whys" of testing.

Who This Workshop Is For

This workshop is for developers who have some testing experience, but feel like they're missing the bigger picture. If you're tired of writing tests that feel like a chore, and want to understand how to write tests that are actually useful, this workshop is for you.

Watch Online

This is a demo lesson (10:00 remaining)

You can watch up to 10 minutes for free. Subscribe to unlock all 40 lessons in this course and access 10,000+ hours of premium content across all courses.

View Pricing

Watch Online Testing Fundamentals [EpicWeb]

0:00
/
#1: Testing Fundamentals Workshop Introduction

All Course Lessons (40)

#Lesson TitleDurationAccess
1
Testing Fundamentals Workshop Introduction Demo
01:44
2
Overview of Testing Principles
01:11
3
Write an Intentional Test - PROBLEM
01:06
4
-----Ignore this video-------
27:31
5
Implement the Automated Greeting Test - SOLUTION
01:15
6
Debugging Intent vs. Implementation - PROBLEM
00:41
7
-----Ignore this video-------
27:31
8
Trusting Your Test - SOLUTION
00:28
9
Testing Principles Outro
00:15
10
Structure Your Tests
00:56
11
Imperative vs. Declarative Assertions - PROBLEM
01:08
12
-----Ignore this video-------
27:31
13
Implement a Declarative API - SOLUTION
02:01
14
Isolating Tests with Test Blocks - PROBLEM
00:59
15
-----Ignore this video-------
27:31
16
Create Test Blocks for Better Organization - SOLUTION
01:27
17
Move Tests into Modules - PROBLEM
00:55
18
-----Ignore this video-------
27:31
19
Modular Tests and Global Helpers - SOLUTION
03:23
20
Handle Test Side Effects - PROBLEM
01:26
21
-----Ignore this video-------
27:31
22
Implement Hooks for Test Setup & Cleanup - SOLUTION
03:52
23
Test Structure Recap
00:23
24
Overview of Testing Async Code
00:48
25
Handling Promises in Tests - PROBLEM
01:24
26
-----Ignore this video-------
27:31
27
Awaiting Async Tests - SOLUTION
01:55
28
Error Assertions for Rejected Promises - PROBLEM
00:43
29
-----Ignore this video-------
27:31
30
Handling Promise Rejections - SOLUTION
03:21
31
Testing with Async Side Effects - PROBLEM
01:53
32
-----Ignore this video-------
27:31
33
Reliably Wait for Async Operations - SOLUTION
03:19
34
Recap of Testing Asynchronous Code
00:22
35
Overview of Vitest
00:34
36
Migrate Tests to Vitest - PROBLEM
00:24
37
-----Ignore this video-------
27:31
38
Installing, Configuring, and Testing in Vitest - SOLUTION
02:28
39
Vitest Review
00:19
40
Testing Fundamentals Workshop Outro
00:26

Unlock unlimited learning

Get instant access to all 39 lessons in this course, plus thousands of other premium courses. One subscription, unlimited knowledge.

Learn more about subscription

Comments

0 comments

Want to join the conversation?

Sign in to comment

Similar courses

Developing LLM App Frontends with Streamlit

Developing LLM App Frontends with Streamlit

Sources: zerotomastery.io
This byte-sized course will teach Streamlit fundamentals and how to use Streamlit to create a frontend for your LLM-powered applications.
1 hour 43 minutes 52 seconds
The Ultimate Web Scraping Course

The Ultimate Web Scraping Course

Sources: Adrian Horning (The Web Scraping Guy)
I have been earning a living through web scraping for over 3 years, have made over $125,000, have more than 25,000 followers on social media, and in this...
10 hours 33 minutes 19 seconds
The Complete 2023 Web Development Bootcamp

The Complete 2023 Web Development Bootcamp

Sources: udemy
Welcome to the Complete Web Development Bootcamp, the only course you need to learn to code and become a full-stack web developer. With over 12,000 ratings and a 4.8 average, my...
62 hours 32 minutes 23 seconds
Frontend architecture and patterns bootcamp

Frontend architecture and patterns bootcamp

Sources: udemy
This comprehensive course covers a wide range of software architecture topics, including component-oriented patterns, Single Page Application (SPA)...
4 hours 21 minutes 43 seconds
Clean Code: Writing Code for Humans

Clean Code: Writing Code for Humans

Sources: pluralsight
Anyone can write code a computer can understand, but professional developers write code *humans* can understand. Clean code is a reader-focused development styl
3 hours 10 minutes 36 seconds