Skip to content
This repository has been archived by the owner on Feb 21, 2024. It is now read-only.

Commit

Permalink
Add notes from "Clean Craftsmanship"
Browse files Browse the repository at this point in the history
  • Loading branch information
lealceldeiro committed Sep 7, 2023
1 parent 4120eb2 commit 441aba3
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions CleanCraftsmanship/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,21 @@ Rule 5: Generalize where possible.

> As the tests get more specific, the code gets more generic.
**Stairstep tests**

Some tests are written just to force us to create classes or functions or other structures that we’re going to need.
Sometimes these tests are so simple that they assert nothing. Other times they assert something very naive. Often
these tests are superseded by more comprehensive tests later and can be safely deleted. We call these kinds of tests
_stairstep tests_ because they are like stairs that allow us to incrementally increase the complexity to the
appropriate level.

**Misplaced responsibility**

A design flaw in which the function that claims to perform a computation does not actually perform the computation.
The computation is performed elsewhere.

Rule 6: When the code feels wrong, fix the design before proceeding.

## Part I: Standards

## Part I: Ethics

0 comments on commit 441aba3

Please sign in to comment.