Skip to content

Commit d4dc780

Browse files
committed
Update tests: 1. automl.py (#1417)
* Add: Dedicated fixtures location * Add: Typing to conftest * Fix: More typing * Move: Dask fixtures to own location * Move: backend to it's own fixture location * Move: Automlstub thing to it's own fixture * Fix: docstring warning in conftest * Fix: Remove dead code * Add: Functionality to skip marked `slow` tests * Add: Fixture for getting datasets * Update: Tests for automl.py w/ fixtures, cases, mocks This commit (too much) focues on extending our pytest capabilities to make things more modular. Notably, making a fixtures and mocks folders for testing so there is a unified source of mocks and fixture locations. Split the tests for automl.py into seperate sub files to allow for an easier time discerning what is being tested where. Introduces `pytest_cases` to allow for easier future testing of properties. Introduces cached automl models to allow for a quicker time testing attributes while keeping tests seperate and distinct. This also rearragnes `unittest` import unfortunatly which causes many files to be touched. * Doc: Add documentation about our testing to conftest.py * Doc: Add a bit more on documenting of tests * Fix: Add pytest-cases to test dependancies * Fix: Broken tests * Fix: Failing test * Fix: Ordering of check in `_includes` * Remove `_includes` and use sets instead * Fix: Black * Update: test workflow knows about `.pytest_cache`
1 parent 37a89e5 commit d4dc780

File tree

106 files changed

+2968
-1909
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

106 files changed

+2968
-1909
lines changed

.flake8

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ extend-exclude =
55
venv
66
.venv
77
build
8+
autosklearn/automl_common
89
extend-ignore =
910
# No whitespace before ':' in [x : y]
1011
E203

.github/workflows/pytest.yml

+2
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,8 @@ jobs:
137137
- name: Check for files left behind by test
138138
if: ${{ always() }}
139139
run: |
140+
# Deleting `.pytest_chache` as it's used during testing and not deleted
141+
rm -rf ".pytest_cache"
140142
before="${{ steps.status-before.outputs.BEFORE }}"
141143
after="$(git status --porcelain -b)"
142144
if [[ "$before" != "$after" ]]; then

0 commit comments

Comments
 (0)