From 28a70eeee0e92f81d5d5491779c32f9a08b0557a Mon Sep 17 00:00:00 2001 From: fdai7782 Date: Tue, 19 Dec 2023 17:47:44 +0000 Subject: [PATCH] Update Lerntagebuch.md --- Lerntagebuch.md | 75 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) diff --git a/Lerntagebuch.md b/Lerntagebuch.md index 567d1a3..9453e62 100644 --- a/Lerntagebuch.md +++ b/Lerntagebuch.md @@ -349,5 +349,80 @@ Errors can have a significant impact on software systems. They can cause softwar ### Feedback +--- + +## SU 08 (19.12.2023) + +### Takeaway + +**Automated testing of software** + +- Motivation + - Reasons why automated testing is useful: + - Reduces quality costs + - Improves software quality + - Accelerates the software development process + - Reasons why automated testing is not always useful: + - High upfront costs + - Complexity of the software + - Lack of team support +- Fundamentals + - Types of tests that can be automated: + - Unit tests + - Integration tests + - System tests + - Acceptance tests + - Difference between unit tests and integration tests: + - Unit tests + - Timing: Run early in the development process, ideally after each save. + - Test tools: Have simple APIs and are easy to learn and use. + - Maintainability: Are stable against changes to other units and therefore require little maintenance. + - Results: Show which requirement is not met, where the error exists, and under what conditions it occurs. + - Goal: Testing business logic + - Application/Module tests + - Timing: Run late in the development process, often only in the test or integration phase. + - Test tools: Are more complex and require more experience in testing. + - Maintainability: Are more susceptible to changes to other units and therefore require more maintenance. + - Results: Show that an error exists, but not where. + - Goal: Testing the interaction of multiple units +- Unit tests + - Definition of a unit test: + - A unit test is an automated test that tests a single unit of software. + - Characteristics of a good unit test: + - Fast + - Independent + - Repeatable + - Selfevaluating + - Timely + - Readable + - Trustworthy + - Maintainable + - Definition of maintainability: + - Maintainability is the ability of code to be easily changed without compromising the quality of the software. +- Requirements for code to be tested + - What improves testability? + - Well-structured code + - Clear interfaces + - Uniform data formats + - Avoiding global variables + - Using test data + - How can isolation of a unit be achieved? + - Using mock objects + - Using test data + - Using dependency injection + +### Perception + +**Unit tests** + + For the group project, I intend to utilize unit tests to thoroughly scrutinize the individual modules of our software. Unit tests are relatively straightforward to develop and maintain, and they can significantly aid me in identifying and rectifying errors promptly. + +### Repetition + +**Application/Module tests** + + Application/Module tests are automated tests that test the interaction of multiple units of software. They are typically executed later in the development process than unit tests. Application/Module tests can help to identify errors that are caused by the interaction of the units. + +### Feedback ---