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

Allow running tests using sqlite #516

Merged
merged 2 commits into from
Mar 21, 2024

Conversation

jayvdb
Copy link
Member

@jayvdb jayvdb commented Dec 26, 2021

Problem

Distro build workers do not want to install postgres in order to run the tests.

Solution

Added capability to use sqlite instead using env flag SQLITE

Commandments

  • Write PEP8 compliant code.
  • Cover it with tests.
  • Update CHANGES.rst file to describe the changes, and quote according issue with GH-<issue_number>.
  • Pay attention to backward compatibility, or if it breaks it, explain why.
  • Update documentation (if relevant).

@codecov
Copy link

codecov bot commented Dec 26, 2021

Codecov Report

Merging #516 (7096314) into master (208e226) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #516   +/-   ##
=======================================
  Coverage   95.15%   95.15%           
=======================================
  Files           6        6           
  Lines         825      825           
=======================================
  Hits          785      785           
  Misses         40       40           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 208e226...7096314. Read the comment docs.

Copy link
Contributor

@auvipy auvipy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good

else:
DATABASES = {
"default": {
"ENGINE": "django.db.backends.postgresql_psycopg2",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"django.db.backends.postgresql_psycopg2", should be just postgresql as per new django releases

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, that will work dj2.2+ ; will update..

@jayvdb
Copy link
Member Author

jayvdb commented Mar 14, 2022

ping @auvipy. I can merge but would be bad practise IMO.

@foarsitter foarsitter added this to the 4.5.0 milestone Mar 21, 2024
@foarsitter foarsitter merged commit 6e7158b into jazzband:master Mar 21, 2024
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.

3 participants