Skip to content

Commit 7c0a493

Browse files
committed
Update versions support
1 parent c01bbc7 commit 7c0a493

File tree

9 files changed

+57
-178
lines changed

9 files changed

+57
-178
lines changed

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// README at: https://github.com/devcontainers/templates/tree/main/src/python
33
{
44
"name": "Cdrf Env",
5-
"image": "mcr.microsoft.com/devcontainers/python:0-3.8",
5+
"image": "mcr.microsoft.com/devcontainers/python:0-3.10",
66
// Use 'forwardPorts' to make a list of ports inside the container available locally.
77
"forwardPorts": [
88
8000

.github/workflows/build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ jobs:
1111
runs-on: ubuntu-22.04
1212
steps:
1313
- uses: actions/checkout@v3
14-
- name: Set up Python 3.8
14+
- name: Set up Python 3.13
1515
uses: actions/setup-python@v4
1616
with:
17-
python-version: 3.8
17+
python-version: 3.13
1818
- name: Install dependencies
1919
run: |
2020
pip install --upgrade pip

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ jobs:
77
runs-on: ubuntu-22.04
88
steps:
99
- uses: actions/checkout@v3
10-
- name: Set up Python 3.8
10+
- name: Set up Python 3.13
1111
uses: actions/setup-python@v4
1212
with:
13-
python-version: 3.8
13+
python-version: 3.13
1414
- name: Install dependencies
1515
run: |
1616
pip install --upgrade pip

build.ini

Lines changed: 35 additions & 150 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,13 @@
11
[tox]
22
skipsdist=True
33
envlist =
4-
drf{31,32,33,34,35,36,37,38,39,310,311,312,313,314},
5-
drfbuild{31,32,33,34,35,36,37,38,39,310,311,312,313,314},
4+
drf{39,310,311,312,313,314,315,316},
5+
drfbuild{39,310,311,312,313,314,315,316},
66

77
[testenv]
88
deps =
99
-r{toxinidir}/requirements-tox.txt
1010

11-
deps31 =
12-
django==1.11.29
13-
djangorestframework>=3.1,<3.2
14-
15-
deps32 =
16-
django==1.11.29
17-
djangorestframework>=3.2,<3.3
18-
19-
deps33 =
20-
django==1.11.29
21-
djangorestframework>=3.3,<3.4
22-
23-
deps34 =
24-
django==1.11.29
25-
djangorestframework>=3.4,<3.5
26-
27-
deps35 =
28-
django==1.11.29
29-
djangorestframework>=3.5,<3.6
30-
31-
deps36 =
32-
django==1.11.29
33-
djangorestframework>=3.6,<3.7
34-
35-
deps37 =
36-
django==2.2
37-
djangorestframework>=3.7,<3.8
38-
39-
deps38 =
40-
django==2.2
41-
djangorestframework>=3.8,<3.9
42-
4311
deps39 =
4412
django==2.2
4513
djangorestframework>=3.9,<3.10
@@ -64,6 +32,14 @@ deps314 =
6432
django==4.1.0
6533
djangorestframework>=3.14,<3.15
6634

35+
deps315 =
36+
django==5.2.5
37+
djangorestframework>=3.15,<3.16
38+
39+
deps316 =
40+
django==5.2.5
41+
djangorestframework>=3.16,<3.17
42+
6743
setenv =
6844
PYTHONPATH = {toxinidir}
6945

@@ -78,62 +54,6 @@ commands =
7854
commands =
7955
fab version
8056

81-
[testenv:drf31]
82-
deps =
83-
{[testenv]deps}
84-
{[testenv]deps31}
85-
commands =
86-
{[index]commands}
87-
88-
[testenv:drf32]
89-
deps =
90-
{[testenv]deps}
91-
{[testenv]deps32}
92-
commands =
93-
{[index]commands}
94-
95-
[testenv:drf33]
96-
deps =
97-
{[testenv]deps}
98-
{[testenv]deps33}
99-
commands =
100-
{[index]commands}
101-
102-
[testenv:drf34]
103-
deps =
104-
{[testenv]deps}
105-
{[testenv]deps34}
106-
commands =
107-
{[index]commands}
108-
109-
[testenv:drf35]
110-
deps =
111-
{[testenv]deps}
112-
{[testenv]deps35}
113-
commands =
114-
{[index]commands}
115-
116-
[testenv:drf36]
117-
deps =
118-
{[testenv]deps}
119-
{[testenv]deps36}
120-
commands =
121-
{[index]commands}
122-
123-
[testenv:drf37]
124-
deps =
125-
{[testenv]deps}
126-
{[testenv]deps37}
127-
commands =
128-
{[index]commands}
129-
130-
[testenv:drf38]
131-
deps =
132-
{[testenv]deps}
133-
{[testenv]deps38}
134-
commands =
135-
{[index]commands}
136-
13757
[testenv:drf39]
13858
deps =
13959
{[testenv]deps}
@@ -176,72 +96,21 @@ deps =
17696
commands =
17797
{[index]commands}
17898

179-
180-
# SITE GENERATION
181-
182-
[testenv:drfbuild31]
183-
deps =
184-
{[testenv:drf31]deps}
185-
envdir =
186-
{toxworkdir}/drf31
187-
commands =
188-
{[build]commands}
189-
190-
[testenv:drfbuild32]
191-
deps =
192-
{[testenv:drf32]deps}
193-
envdir =
194-
{toxworkdir}/drf32
195-
commands =
196-
{[build]commands}
197-
198-
[testenv:drfbuild33]
99+
[testenv:drf315]
199100
deps =
200-
{[testenv:drf33]deps}
201-
envdir =
202-
{toxworkdir}/drf33
203-
commands =
204-
{[build]commands}
205-
206-
[testenv:drfbuild34]
207-
deps =
208-
{[testenv:drf34]deps}
209-
envdir =
210-
{toxworkdir}/drf34
211-
commands =
212-
{[build]commands}
213-
214-
[testenv:drfbuild35]
215-
deps =
216-
{[testenv:drf35]deps}
217-
envdir =
218-
{toxworkdir}/drf35
219-
commands =
220-
{[build]commands}
221-
222-
[testenv:drfbuild36]
223-
deps =
224-
{[testenv:drf36]deps}
225-
envdir =
226-
{toxworkdir}/drf36
101+
{[testenv]deps}
102+
{[testenv]deps315}
227103
commands =
228-
{[build]commands}
104+
{[index]commands}
229105

230-
[testenv:drfbuild37]
106+
[testenv:drf316]
231107
deps =
232-
{[testenv:drf37]deps}
233-
envdir =
234-
{toxworkdir}/drf37
108+
{[testenv]deps}
109+
{[testenv]deps316}
235110
commands =
236-
{[build]commands}
111+
{[index]commands}
237112

238-
[testenv:drfbuild38]
239-
deps =
240-
{[testenv:drf38]deps}
241-
envdir =
242-
{toxworkdir}/drf38
243-
commands =
244-
{[build]commands}
113+
# SITE GENERATION
245114

246115
[testenv:drfbuild39]
247116
deps =
@@ -290,3 +159,19 @@ envdir =
290159
{toxworkdir}/drf314
291160
commands =
292161
{[build]commands}
162+
163+
[testenv:drfbuild315]
164+
deps =
165+
{[testenv:drf315]deps}
166+
envdir =
167+
{toxworkdir}/drf315
168+
commands =
169+
{[build]commands}
170+
171+
[testenv:drfbuild316]
172+
deps =
173+
{[testenv:drf316]deps}
174+
envdir =
175+
{toxworkdir}/drf316
176+
commands =
177+
{[build]commands}

requirements-test.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
-r requirements-tox.txt
2-
djangorestframework==3.14.0
3-
django==4.1.13
4-
pytest==7.1.2
5-
pytest-cov==4.1.0
6-
coveralls==3.3.1
2+
djangorestframework==3.16.0
3+
django==5.2.5
4+
pytest==8.4.1
5+
pytest-cov==6.2.1
6+
coveralls==4.0.1

requirements-tox.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Fabric==2.7.0
2-
Jinja2==3.1.2
3-
Pygments==2.15.0
4-
python-decouple==3.6
1+
Fabric==3.2.2
2+
Jinja2==3.1.6
3+
Pygments==2.19.2
4+
python-decouple==3.8

requirements.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
Fabric==2.7.0
2-
python-decouple==3.6
3-
tox==3.25.0
1+
Fabric==3.2.2
2+
python-decouple==3.8
3+
tox==4.29.0

rest_framework_ccbv/config.py

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,14 @@
22

33

44
REST_FRAMEWORK_VERSIONS = [
5-
"3.1",
6-
"3.2",
7-
"3.3",
8-
"3.4",
9-
"3.5",
10-
"3.6",
11-
"3.7",
12-
"3.8",
135
"3.9",
146
"3.10",
157
"3.11",
168
"3.12",
179
"3.13",
18-
"3.14"
10+
"3.14",
11+
"3.15",
12+
"3.16",
1913
]
2014

2115

tests/test_renderers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
from rest_framework_ccbv.inspector import Attributes
1414

1515
KLASS_FILE_CONTENT = (
16-
'{"3.2": {"rest_framework.generics": ["RetrieveDestroyAPIView", "ListAPIView"]},'
16+
'{"3.9": {"rest_framework.generics": ["RetrieveDestroyAPIView", "ListAPIView"]},'
1717
'"%s": {"rest_framework.generics": ["RetrieveDestroyAPIView", "ListAPIView"]}}' % VERSION
1818
)
1919

@@ -98,7 +98,7 @@ def setUp(self):
9898
def test_context(self, get_template_mock):
9999
self.renderer.render('foo')
100100
context = get_template_mock.return_value.render.call_args_list[0][0][0]
101-
assert context['other_versions'] == ['3.2']
101+
assert context['other_versions'] == ['3.9']
102102
assert context['name'] == ListAPIView.__name__
103103
assert isinstance(context['ancestors'], (list, tuple))
104104
assert isinstance(context['direct_ancestors'], (list, tuple))

0 commit comments

Comments
 (0)