Skip to content

Commit

Permalink
docs(testing): add how to test against local banch
Browse files Browse the repository at this point in the history
  • Loading branch information
Guts committed Apr 19, 2024
1 parent 0f6f639 commit 2975e43
Showing 1 changed file with 24 additions and 1 deletion.
25 changes: 24 additions & 1 deletion docs/development/testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Complete it by installing tests requirements:
python -m pip install -U -r requirements/testing.txt
```

## Run
## Run unit tests

Simply run Pytest:

Expand All @@ -34,3 +34,26 @@ It's also possible to run an individual test:
```sh
python -m unittest tests.test_qplugin_object.TestQgisPluginObject.test_profile_load_from_json_basic
```

## Try current QDT version

Let's say you're working on a branch and you want to run QDT against your changes.
Make the following changes to the `scenario.qdt.yml` to point to the current folder:

```yaml
[...]
steps:
- name: Download profiles from remote git repository
uses: qprofiles-downloader
with:
source: file://.
protocol: git_local
[...]
```

Every time you edit the profiles stored in the `examples` folder, don't forget to commit to your local history:

```sh
git commit examples/ -m "wip"
QGIS_CUSTOM_CONFIG_PATH=tests/fixtures/tmp/ qdt -vv -s scenario.qdt.yml
```

0 comments on commit 2975e43

Please sign in to comment.