fixture
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| fixture [2025/09/09 19:24] – plida | fixture [2025/09/09 19:24] (current) – plida | ||
|---|---|---|---|
| Line 8: | Line 8: | ||
| It is useful because of: | It is useful because of: | ||
| - | |||
| * The reuse of the arrangement code. | * The reuse of the arrangement code. | ||
| * A single initial state for a group of tests. | * A single initial state for a group of tests. | ||
| Line 16: | Line 15: | ||
| - The fixtures should be minimal — just what is needed for the tests. | - The fixtures should be minimal — just what is needed for the tests. | ||
| - Use SetUp/ | - Use SetUp/ | ||
| - | - Don't overload the fixtures with logic — they are for preparation, | + | - In Python and Go, it is convenient to use yield/defer to free up resources. |
| - | - Python and Go, it is convenient to use yield/defer to free up resources. | + | |
fixture.1757445856.txt.gz · Last modified: by plida
