Skip to content
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 #1124

Merged
merged 3 commits into from
Feb 10, 2023
Merged

Fix failing tests #1124

merged 3 commits into from
Feb 10, 2023

Conversation

ddabble
Copy link
Member

@ddabble ddabble commented Feb 6, 2023

Description

Due to recent changes on Django's main branch, Python versions 3.8 and 3.9 can no longer be tested with it, and the USE_TZ settings needs to be explicitly set to False.

Also fixed the non-rendering status badge for the build workflow (later renamed to Test) in README.rst.

Related Issue

Not deemed necessary.

Motivation and Context

Fixing the recently failing tests.

How Has This Been Tested?

Only through GitHub Actions.

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • I have run the pre-commit run command to format and lint.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • I have added my name and/or github handle to AUTHORS.rst
  • I have added my change to CHANGES.rst
  • All new and existing tests passed.

In Django's `main` branch, the default value of the `USE_TZ` setting was changed from `False` to `True`
(see django/django@602d9a3),
which caused the tests relying on timezone-naive `datetime` objects, to fail.

Example of some of the failing tests:
https://github.com/jazzband/django-simple-history/actions/runs/4108104757/jobs/7088397467.
...to fix the remaining failing tests.
This is due to Django's `main` branch now requiring Python >=3.10.

Example of the errors:
https://github.com/jazzband/django-simple-history/actions/runs/4108104757/jobs/7088396098.
These URLs were not updated when the `build` workflow was renamed to `test`
(in 60beaf4).
@codecov
Copy link

codecov bot commented Feb 6, 2023

Codecov Report

Merging #1124 (891174e) into master (add4f15) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #1124   +/-   ##
=======================================
  Coverage   97.23%   97.23%           
=======================================
  Files          23       23           
  Lines        1231     1231           
  Branches      199      199           
=======================================
  Hits         1197     1197           
  Misses         16       16           
  Partials       18       18           

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@ddabble ddabble merged commit 018099c into jazzband:master Feb 10, 2023
@ddabble ddabble deleted the fix/failing-tests branch February 10, 2023 22:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants