Test-driven Development Using React

Test-driven Development (TDD) and React work together to create clean, reliable code. This course will teach you the fundamentals of both while giving you essential hands-on experience so that you can quickly implement both in your projects.
Course info
Rating
(52)
Level
Beginner
Updated
Jun 8, 2018
Duration
1h 54m
Table of contents
Description
Course info
Rating
(52)
Level
Beginner
Updated
Jun 8, 2018
Duration
1h 54m
Description

At the core of being able to write clean code that you can depend on is a thorough knowledge of unit testing. In Test-driven Development Using React, you will learn how to use the TDD cycle to create real-world user interfaces with the popular JavaScript library that was created by Facebook, React. First, you will discover how to use TDD to write JavaScript functions. Next, you will explore the syntax and ideas behind React. Finally, you will learn how to combine React and TDD by using the Jest testing framework. When you are finished with this course, you will have a foundational knowledge of both Test-driven Development and React that will help you as you move forward with using TDD in any programming language as well as with learning advanced React and React Native development.

About the author
About the author

Chris is a prolific author, trainer, speaker, and web developer. His company, WatzThis?, is dedicated to finding better ways to teach computer and programming skills to beginners.

More from the author
Section Introduction Transcripts
Section Introduction Transcripts

Course Overview
Hi everyone! My name is Chris Minnick, and welcome to my course, Test-driven Development Using React. I'm the CEO at Watzthis. Test-driven development, or TDD, is a critical tool for software developers and software development teams. Whether your goal is to use TDD 100% of the time, or whether you just need an understanding of how to solve difficult problems using it, it's important to both understand the ideas behind it, as well as to see in work with examples. In this course, we're going to learn the fundamentals of TDD. We're also learning one of the most popular and sought after user interface libraries for both the web and mobile apps, React. Some of the major topics that we'll cover include What is TDD? What is React? How to use Jest, Facebook's testing framework for react. And how to write good tests. By the end of this course, you'll know how to write good tests for React components and how to write the React components to pass those tests. Before beginning this course, you should be familiar with JavaScript. I recommend also having some exposure to classes in JavaScript and to some of the new syntax that's been part of the language since ES2015, also known as ES6. I hope you'll join me on this journey to learn how to write clean code that works with the Test-driven Development Using React course at Pluralsight.

Course Introduction
Hi! I'm Chris Minnick, and this is my course on Test-driven Development Using React. I'm the CEO at Watzthis, and I've been working with React and teaching it at companies around the world since 2015. Test-driven development is a style of programming where code, testing, and design are tightly interwoven. React is a popular, high-performance library for building web user interfaces. In test-driven development using React, you'll learn how to use TDD to increase your productivity while writing clean code that works. In the process, you'll learn to use the Jest testing framework, how to write good tests for React, and how to write the React code to pass those tests. When you're finished with this course, you'll have the skills you need to start using TDD in any programming language and to immediately implement React in your applications using professional tools and methodologies.

Introducing TDD with React
Hi, and welcome back to test-driven development using React. In this module, I'm going to show you how to get started with test-driven development and with React. But before I do that, I'm going to tell you what you can expect to know by the end of this module. You're going to learn what test-driven development is and why you should use it. And then you're going to learn what React is and why you should use that. Then I'll go through the process of actually getting started using test-driven development and React. So let's get started. If you're a front-end web developer, or if you've worked around front-end web developers, you know that web development is notoriously complex. The languages, tools, and techniques used to create web user interfaces for a wide variety of different devices are constantly in flux as new and sometimes better ways of doing things are invented or discovered. Putting together the right combination of libraries, APIs, and languages while avoiding conflicts and keeping your app performant can sometimes feel like a matter of luck. And, frankly, for many developers, it is a matter of luck. The chaos that can rule within a front-end development team can be stressful and often leads to errors and unreliable code. But front-end development doesn't have to be chaotic and unpredictable. There are ways to gain control over your development process and to know for certain that your user interface will work correctly and can be safely deployed.

Discovering the Need for TDD
In this module, I'll get into more details about how test-driven development works. I'll talk about some of the best practices and patterns that software teams use to implement TDD. Then I'll build a simple version of the Wired Brain Coffee store locator application without React using TDD. From these humble beginnings, we'll have the foundation for the React greatness that is to come, and you can experience with using Jest without having to deal with React at the same time. Here's what you should know by the end of this module. You'll be able to name at least three types of automated tests. You'll know what you should test in an application. And you'll be able to name some characteristics of a good test. So let's get started.