-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix failing tests #1960
Fix failing tests #1960
Conversation
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wow, that looks great! Now can you explain why the test runs shown by GitHub are only run for Python 3.8/3.9, Django 3.2/4.2 and ES?
@black3r and I have agreed that we will make small moves so pull requests will be as small as possible to ease the code review process. |
As the project is set up right now, the tests are started by GitHub actions and then handed over to Tox. So which tests are started is decided in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for explaining, this looks so promising 🥇
fixes #1917
this PR does the following:
start-solr-test-server.sh
and Set container URLs for tests running in GitHub Actions #1921) This setup script is also usable to run the test locally (for example with running solr withdocker run -it --rm -p 9001:8983 solr:6
)tox.ini
to properly configuretox-gh-actions
DJANGO
env var set up by github actions, so it doesn't set up django according totox.ini
but instead just installs theDjango>=3.2
specified insetup.py
ending up with all the tests running with Django 4.2, this fixes that...pypy3
fromtox.ini
because it seems unused currently. If it's actually needed, let me know and I will re-add it and add it to the github actionstest.yml
too...HaystackTestCase
which would call the.reset()
method on all indexes in its setUpClass method, similar to what django'sTestCase
does with databases, and subclass that for every testcase... for now I just fixed that in the affected tests...build_solr_schema
used to depend on Solr server being set up locally, but for testing this command we don't actually need a live Solr server, we can mock the Solr server instead...