Are Your Tests Slowing You Down?

How a Developer Productivity Engineering (DPE) approach can speed up writing, running and debugging tests.

Abstract

Testing is a Good Thing, right? Especially automated testing. But “Good things come to those who wait” is not something that’s going to appeal to the busy developer. You want results, and you want them now. You’re in The Zone working on a problem, and the last thing you want is to break your flow wrestling with your testing framework or waiting for the tests to finish running.

More code means more tests. More coverage means more tests. More tests mean more time. Time that you want to spend being productive, creative, innovative. How can you balance the need for quality with the need for speed?

In this talk, Trisha will identify issues that slow down developers when writing, running and debugging tests, and look at tools that can help developers with each of these problems. There will be live coding, analysis of social media poll results, an overview of solutions in this space, “best practice” recommendations, and machine learning will be mentioned at some point.

Video

Virtual JUG Embed

I first gave the presentation at Devoxx Belgium, if you want to see it in a conference setting.

Slides

Resources

Writing Tests

IntelliJ IDEA tips for writing code

Using ML & AI

Debugging / Troubleshooting Tests

  • IntelliJ IDEA for Debugging (YouTube playlist)
  • Remote Debugging (reference documentation)
  • Remote Debugging tutorial
  • Analyze stack trace (reference documentation)
  • Using a Build Scan to troubleshoot Maven and Gradle builds

Flaky tests

  • Your tests are failing you (video) - my rant on the Continuous Delivery channel about flaky tests
  • 5 causes of test intermittency (video) - Dave Farley gives excellent pointers on why your tests might be flaky
  • Non Determinism (Martin Fowler)
  • Why fix your flaky tests (blog) - I wrote this blog because I thought perhaps people might not understand why flaky tests are a problem
  • How to use Develocity to identify your flaky tests (blog) - I wrote this product-specific blog not only to help sales of Gradle’s Develocity tool, but also to talk about how to use tooling to find your problem tests
  • How to fix your flaky tests (blog) - I use a bunch of ideas from Dave’s video on test intermittency (above) to give pointers on how to fix your flaky tests
  • How Top Banks Handle Flaky Tests (blog) - a case study of four banks’ approaches, and i also inserted some extra tips on addressing flaky tests
  • Develocity Flaky Test Detection (reference documentation)
  • If you want to show your disdain for flaky tests, you can literally buy the t-shirt.
  • Surveying the Developer Experience of Flaky Tests (PDF)

Running tests

Cleaning up your test suite

General information about testing

Other

Books & courses

Attributions

If you like my stuff, buy my books and courses!!