From 61c4aa8531595ea7d78a251a5fdf3f7343ba937c Mon Sep 17 00:00:00 2001 From: Michelle Weidling Date: Wed, 9 Mar 2022 13:20:14 +0100 Subject: [PATCH] fix: rephrase software coverage for clarity --- chapters/software-tests.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/chapters/software-tests.md b/chapters/software-tests.md index a6b596f..2f3f21f 100644 --- a/chapters/software-tests.md +++ b/chapters/software-tests.md @@ -1,13 +1,13 @@ ## Software Tests -All functions (except getter and setter methods) `MUST` provide proper tests. -This is understood on a component level, meaning every method should have at least one test. -Whether you achieve this by Test Driven Development (TDD) or other means depends on your preferred way to work. +Software tests aim at ensuring that the code you write does exactly what you expect it to do. + +All functions (except `get`ter and `set`ter methods) `MUST` provide proper tests. +Every method should have enough tests to cover each line of code, aiming at a code coverage of 100\%. +Also all possible outcomes of a method should be considered and covered by tests. -Please keep in mind not only to write a test for each of your functions but also -consider all possible outcomes. -It is e.g. not sufficient to test if a function creates a file if the written content depends on variables etc. +Whether you achieve this by Test Driven Development (TDD) or other means depends on your preferred way to work. Examples for writing tests in different programming languages are: -- GitLab