Skip to content

Commit 6084102

Browse files
committed
docs: add info on fixture types
risk: nonprod
1 parent 2bdd0fc commit 6084102

1 file changed

Lines changed: 21 additions & 0 deletions

File tree

CONTRIBUTING.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -328,3 +328,24 @@ venv automatically. So when docker tox tests are executed after localhost tests
328328
329329
# How to generate and maintain OpenAPI clients
330330
Refer to our [OpenAPI client README](./.openapi-generator/README.md)
331+
332+
# Kinds of fixtures and layouts
333+
334+
There are several kinds of fixtures used for the tests.
335+
This is important to know about when you're making changes or updating cassettes as it can surprise you.
336+
You have to keep in mind especially if you want to add new attributes to be used across several tests.
337+
338+
- `packages/tests-support/fixtures` are used as the default layout for tests that are uploaded by docker compose. They
339+
are also uploaded by the `upload_demo_layout.py` script.
340+
341+
## Gooddata SDK
342+
343+
These are common places for fixtures used in Gooddata SDK:
344+
345+
- `packages/gooddata-sdk/tests/catalog/refresh`: this is the layout that actually *replaces* the layout after some kinds of catalog tests, and hence overrides the layout from docker compose.
346+
You have to make changes also here if you want to make changes to the default layout.
347+
It's a current TODO to merge this and `packages/tests-support/fixtures` into one layout.
348+
- `packages/gooddata-sdk/tests/catalog/expected`: these are fixtures that are used to compare against in various catalog tests.
349+
- `packages/gooddata-sdk/tests/catalog/store`, `packages/gooddata-sdk/tests/catalog/load`, `packages/gooddata-sdk/tests/catalog/load_with_locale`, `packages/gooddata-sdk/tests/catalog/load_with_locale`, ...
350+
- These are numerous fixtures that are used for load and put tests. You often need to change more of them.
351+
- Note that some of these contain `workspace` and `workspace_content` subfolders, depending on where the fixtures are used to load

0 commit comments

Comments
 (0)