Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

test: run test on django 4.2 #568

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ name: Python CI
on:
push:
branches:
- master
- master
pull_request:
branches:
- '**'
- '**'

jobs:
run_tests:
Expand All @@ -15,10 +15,11 @@ jobs:
strategy:
matrix:
os:
- ubuntu-20.04
- ubuntu-20.04
python-version:
- 3.8
toxenv: [ django32 ]
- 3.8
toxenv: [ django32, django42 ]
fail-fast: false
steps:
- uses: actions/checkout@v1
- name: setup python
Expand Down
4 changes: 2 additions & 2 deletions registrar/apps/api/mixins.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,10 @@ def _track(self, status_code):
context = {
'page': {
'path': self.request.path,
'referrer': self.request.META.get('HTTP_REFERER'),
'referrer': self.request.headers.get('referer'),
'url': self.request.build_absolute_uri(),
},
'userAgent': self.request.META.get('HTTP_USER_AGENT'),
'userAgent': self.request.headers.get('user-agent'),
}

segment.track(self.request.user.username, event_name, properties, context)
Expand Down
1 change: 0 additions & 1 deletion registrar/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,6 @@

USE_I18N = True

USE_L10N = True

USE_TZ = True

Expand Down
5 changes: 5 additions & 0 deletions requirements/common_constraints.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
# See BOM-2721 for more details.
# Below is the copied and edited version of common_constraints

# This is a temporary solution to override the real common_constraints.txt
# In edx-lint, until the pyjwt constraint in edx-lint has been removed.
# See BOM-2721 for more details.
# Below is the copied and edited version of common_constraints

# A central location for most common version constraints
# (across edx repos) for pip-installation.
#
Expand Down
2 changes: 1 addition & 1 deletion requirements/devstack.txt
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ exceptiongroup==1.1.3
# pytest
factory-boy==3.3.0
# via -r requirements/local.txt
faker==19.7.0
faker==19.8.0
# via
# -r requirements/local.txt
# factory-boy
Expand Down
2 changes: 1 addition & 1 deletion requirements/local.txt
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ exceptiongroup==1.1.3
# pytest
factory-boy==3.3.0
# via -r requirements/test.txt
faker==19.7.0
faker==19.8.0
# via
# -r requirements/test.txt
# factory-boy
Expand Down
2 changes: 1 addition & 1 deletion requirements/monitoring/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ factory-boy==3.3.0
# -r requirements/monitoring/../devstack.txt
# -r requirements/monitoring/../local.txt
# -r requirements/monitoring/../test.txt
faker==19.7.0
faker==19.8.0
# via
# -r requirements/monitoring/../devstack.txt
# -r requirements/monitoring/../local.txt
Expand Down
2 changes: 1 addition & 1 deletion requirements/test.txt
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ exceptiongroup==1.1.3
# via pytest
factory-boy==3.3.0
# via -r requirements/test.in
faker==19.7.0
faker==19.8.0
# via
# -r requirements/test.in
# factory-boy
Expand Down
9 changes: 5 additions & 4 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
[tox]
envlist = py38-django{32}
envlist = py38-django{32, 42}
skipsdist = true

[testenv]
passenv = *
deps =
deps =
django32: -r requirements/django.txt
django42: Django>=4.2,<4.3
-r{toxinidir}/requirements/test.txt
whitelist_externals =
whitelist_externals =
i18n_tool
/bin/bash
commands = {posargs:pytest}
commands = {posargs:pytest}
Loading