2021-05-12
1940
#vanilla javascript
Michiel Mulders
47767
May 12, 2021 â‹… 6 min read

JavaScript testing: 9 best practices to learn

Michiel Mulders Michiel loves the Node.js and Go programming languages. A backend/core blockchain developer and avid writer, he's very passionate about blockchain technology.

Recent posts:

is OpenNext really the key to Next.js portability

Is OpenNext really the key to Next.js portability?

There’s been major controversy surrounding Next.js’s openness. Discover how OpenNext is addressing the bubbling issue of Next.js portability.

Elijah Asaolu
Apr 30, 2025 â‹… 5 min read

Solid series: Single Responsibility Principle (SRP)

By using SRP, developers can produce code that is easier to debug, test, and extend, making it clearer, more maintainable, and scalable.

Oyinkansola Awosan
Apr 30, 2025 â‹… 8 min read
axios post requests

Axios POST requests: Handling errors, authentication, & best practices

Learn about the Axios POST method and discover how to deploy it in vanilla JavaScript and frameworks like React.

Chimezie Innocent
Apr 29, 2025 â‹… 16 min read
creating server-driven web apps with htmx

Creating server-driven web apps with htmx

Explore htmx, a small browser-oriented JavaScript library aimed at building no-nonsense, server-driven web apps.

Elijah Asaolu
Apr 29, 2025 â‹… 16 min read
View all posts

One Reply to "JavaScript testing: 9 best practices to learn"

  1. Using Faker or random test data is a bad idea. Your tests should be repeatable and deterministic.

    If a test fails because of the data (perhaps you forgot to escape apostrophes and Faker gave you an Irish surname like O’Neill), when you run the test again to debug the code, you won’t have the same data and the test may pass.

Leave a Reply