-
Notifications
You must be signed in to change notification settings - Fork 33
deps: update all deps #413
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
Conversation
# otherwise run all the sessions. | ||
if [[ -n "${NOX_SESSION:-}" ]]; then | ||
python3 -m nox -s ${NOX_SESSION:-} | ||
elif [[ "${RUN_COMPLIANCE_TESTS}" -eq "false" ]]; then |
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.
This ensures that if RUN_COMPLIANCE_TESTS=false
has been set, then we only run the unit tests (and not lint, migration tests, etc.). All of those are covered by GitHub Actions runners.
env_vars: { | ||
key: "NOX_SESSION" | ||
value: "compliance_test_20" | ||
value: "unit" |
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.
TODO in a next step: Remove this entire workflow. It is slow and not needed. The tests against the emulator should be enough.
|
||
if USE_EMULATOR: | ||
database = instance.database("compliance-test") | ||
database.drop() |
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.
This ensures that each test really gets a fresh database. SQLAlchemy just ignored AlreadyExists
errors that happened when the tests tried to create the same database again on the emulator, which caused some tests to show unpredictable behavior.
Note that database.drop()
is a no-op if the database does not exist.
BLACK_VERSION = "black==22.3.0" | ||
BLACK_PATHS = ["google", "test", "noxfile.py", "setup.py", "samples"] | ||
DEFAULT_PYTHON_VERSION = "3.8" | ||
DEFAULT_PYTHON_VERSION_FOR_SQLALCHEMY_20 = "3.12" |
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.
Run compliance tests for SQLAlchemy 2.0 on Python 3.12. That is a currently supported version (https://devguide.python.org/versions/)
zip_safe=False, | ||
) | ||
with warnings.catch_warnings(): | ||
warnings.simplefilter("ignore") |
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.
This makes sure that the tests do not fail due to a warning about deprecation being logged.
cls.ot_exporter = get_test_ot_exporter() | ||
|
||
def teardown(self): | ||
def teardown_method(self): |
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.
TODOs in next steps: