Session

Who test the tests?

If tests are meant to guarantee the quality of our code, have you ever questioned yourself who is responsible for guaranteeing the quality of our tests?

In this talk we will explore the concept of mutation tests, technique designed to ensure that your tests are working as expected - or in other words - the test of your tests.

Mutation testing involves automatically rewriting the code in a way that breaks the unit tests - this is what we call a mutation. If after rewriting the code with a mutation the tests are still passing it means the tests are not catching that mutation. After trying several mutations in a row, a test that survives them all without breaking might not be testing anything after all!

The talk is structured as follows:
1. Introduction: what is mutation testing? (5 min)
2. How to programmatically rewrite code in Go, including a gentle introduction to Abstract Syntax Trees (10 min)
3. How to use compiler overlays to replace files during compilation time (5 min)
4. Combine previous steps to perform a conditional mutation (10 min)
5. Current state of mutation testing in Go (2 min)
6. Conclusions and final words (2 min)

Talk code will be based on: https://github.com/danicat/selene

Daniela Petruzalek

Executive Director at JPMC | Google Developer Expert

London, United Kingdom

Actions

Please note that Sessionize is not responsible for the accuracy or validity of the data provided by speakers. If you suspect this profile to be fake or spam, please let us know.

Jump to top