Skip to content

Commit 5f3f6ef

Browse files
committed
🐛 fix: Send the correct case to ZTC service
For some requests (like POSTS) BFF sends data as-is to the service without serialising using the proper Struct. As-is, was actually not as-is, as DRF was translating camelCase to snake_case and consequently BFF was sending snake_case fields to ZTC service. OZ uses snake_case internally, so that's why it did still respond as expected, but that's a coincidence and implementation detail of OZ we shouldn't depend on.
1 parent 565b5ec commit 5f3f6ef

File tree

3 files changed

+62
-35
lines changed

3 files changed

+62
-35
lines changed

backend/src/openbeheer/api/views.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
Protocol,
1212
Sequence,
1313
get_origin,
14+
override,
1415
runtime_checkable,
1516
)
1617
from uuid import UUID
@@ -31,6 +32,7 @@
3132
)
3233
from msgspec.json import Encoder, decode
3334
from rest_framework import status
35+
from rest_framework.parsers import BaseParser, JSONParser
3436
from rest_framework.renderers import BaseRenderer, JSONRenderer
3537
from rest_framework.response import Response
3638
from rest_framework.views import APIView as _APIView
@@ -119,10 +121,17 @@ def _add_mixin(render_class: type[BaseRenderer]) -> type[BaseRenderer]:
119121
class MsgspecAPIView(_APIView):
120122
serializer_class = None
121123

124+
@override
122125
def get_renderers(self) -> list[BaseRenderer]:
123126
render_classes = (_add_mixin(_class) for _class in self.renderer_classes)
124127
return [MsgspecJSONRenderer()] + [r() for r in render_classes]
125128

129+
@override
130+
def get_parsers(self) -> list[BaseParser]:
131+
# Because we, pass-through PATCH, POST and PUT data as-is to the service
132+
# we shouldn't snake_case the incoming json.
133+
return [JSONParser()] + super().get_parsers()
134+
126135

127136
type Expansion[T: Struct, R] = Callable[[APIClient, Iterable[T]], Iterable[R]]
128137

backend/src/openbeheer/besluittypen/tests/files/vcr_cassettes/BesluitTypeListViewTests/test_create.yaml

Lines changed: 35 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
interactions:
22
- request:
3-
body: '{"domein": "QYWBT", "rsin": "123456782", "contactpersoonBeheerNaam": "Ubaldo",
4-
"naam": "Test catalogus"}'
3+
body: '{"domein": "MXUIQ", "rsin": "123456782", "contactpersoonBeheerNaam": "Ubaldo",
4+
"naam": "Time stay agree law."}'
55
headers:
66
Accept:
77
- '*/*'
@@ -12,15 +12,15 @@ interactions:
1212
Connection:
1313
- keep-alive
1414
Content-Length:
15-
- '104'
15+
- '110'
1616
Content-Type:
1717
- application/json
1818
method: POST
1919
uri: http://localhost:8003/catalogi/api/v1/catalogussen
2020
response:
2121
body:
22-
string: '{"url":"http://localhost:8003/catalogi/api/v1/catalogussen/e72ef872-efb6-48b1-9b6c-63c23259dad0","domein":"QYWBT","rsin":"123456782","contactpersoonBeheerNaam":"Ubaldo","contactpersoonBeheerTelefoonnummer":"","contactpersoonBeheerEmailadres":"","zaaktypen":[],"besluittypen":[],"informatieobjecttypen":[],"naam":"Test
23-
catalogus","versie":"","begindatumVersie":null}'
22+
string: '{"url":"http://localhost:8003/catalogi/api/v1/catalogussen/6f882079-47fb-47b4-bfcd-6b2c37015c07","domein":"MXUIQ","rsin":"123456782","contactpersoonBeheerNaam":"Ubaldo","contactpersoonBeheerTelefoonnummer":"","contactpersoonBeheerEmailadres":"","zaaktypen":[],"besluittypen":[],"informatieobjecttypen":[],"naam":"Time
23+
stay agree law.","versie":"","begindatumVersie":null}'
2424
headers:
2525
API-version:
2626
- 1.3.1
@@ -29,13 +29,13 @@ interactions:
2929
Connection:
3030
- keep-alive
3131
Content-Length:
32-
- '365'
32+
- '371'
3333
Content-Type:
3434
- application/json
3535
Cross-Origin-Opener-Policy:
3636
- same-origin
3737
Location:
38-
- http://localhost:8003/catalogi/api/v1/catalogussen/e72ef872-efb6-48b1-9b6c-63c23259dad0
38+
- http://localhost:8003/catalogi/api/v1/catalogussen/6f882079-47fb-47b4-bfcd-6b2c37015c07
3939
Referrer-Policy:
4040
- same-origin
4141
Vary:
@@ -48,14 +48,14 @@ interactions:
4848
code: 201
4949
message: Created
5050
- request:
51-
body: '{"omschrijving": "Another test zaaktype", "vertrouwelijkheidaanduiding":
51+
body: '{"omschrijving": "Hair door produce run.", "vertrouwelijkheidaanduiding":
5252
"openbaar", "doel": "New Zaaktype 001", "aanleiding": "New Zaaktype 001", "indicatieInternOfExtern":
5353
"intern", "handelingInitiator": "aanvragen", "onderwerp": "New Zaaktype 001",
5454
"handelingBehandelaar": "handelin", "doorlooptijd": "P40D", "opschortingEnAanhoudingMogelijk":
5555
false, "verlengingMogelijk": true, "verlengingstermijn": "P40D", "publicatieIndicatie":
5656
false, "productenOfDiensten": ["https://example.com/product/321"], "referentieproces":
5757
{"naam": "ReferentieProces 1"}, "verantwoordelijke": "200000000", "beginGeldigheid":
58-
"2025-06-19", "versiedatum": "2025-06-19", "catalogus": "http://localhost:8003/catalogi/api/v1/catalogussen/e72ef872-efb6-48b1-9b6c-63c23259dad0",
58+
"2025-06-19", "versiedatum": "2025-06-19", "catalogus": "http://localhost:8003/catalogi/api/v1/catalogussen/6f882079-47fb-47b4-bfcd-6b2c37015c07",
5959
"besluittypen": [], "gerelateerdeZaaktypen": [], "selectielijstProcestype":
6060
"https://selectielijst.openzaak.nl/api/v1/procestypen/aa8aa2fd-b9c6-4e34-9a6c-58a677f60ea0"}'
6161
headers:
@@ -68,18 +68,18 @@ interactions:
6868
Connection:
6969
- keep-alive
7070
Content-Length:
71-
- '922'
71+
- '923'
7272
Content-Type:
7373
- application/json
7474
method: POST
7575
uri: http://localhost:8003/catalogi/api/v1/zaaktypen
7676
response:
7777
body:
78-
string: '{"url":"http://localhost:8003/catalogi/api/v1/zaaktypen/82bffef9-2fd7-4b0f-8904-154aa76f1316","identificatie":"ZAAKTYPE-2025-0000000001","omschrijving":"Another
79-
test zaaktype","omschrijvingGeneriek":"","vertrouwelijkheidaanduiding":"openbaar","doel":"New
78+
string: '{"url":"http://localhost:8003/catalogi/api/v1/zaaktypen/4f0a8e80-e9f5-48e0-995e-b22390418176","identificatie":"ZAAKTYPE-2025-0000000022","omschrijving":"Hair
79+
door produce run.","omschrijvingGeneriek":"","vertrouwelijkheidaanduiding":"openbaar","doel":"New
8080
Zaaktype 001","aanleiding":"New Zaaktype 001","toelichting":"","indicatieInternOfExtern":"intern","handelingInitiator":"aanvragen","onderwerp":"New
8181
Zaaktype 001","handelingBehandelaar":"handelin","doorlooptijd":"P40D","servicenorm":null,"opschortingEnAanhoudingMogelijk":false,"verlengingMogelijk":true,"verlengingstermijn":"P40D","trefwoorden":[],"publicatieIndicatie":false,"publicatietekst":"","verantwoordingsrelatie":[],"productenOfDiensten":["https://example.com/product/321"],"selectielijstProcestype":"https://selectielijst.openzaak.nl/api/v1/procestypen/aa8aa2fd-b9c6-4e34-9a6c-58a677f60ea0","referentieproces":{"naam":"ReferentieProces
82-
1","link":""},"concept":true,"verantwoordelijke":"200000000","beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"versiedatum":"2025-06-19","beginObject":"2025-06-19","eindeObject":null,"catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/e72ef872-efb6-48b1-9b6c-63c23259dad0","statustypen":[],"resultaattypen":[],"eigenschappen":[],"informatieobjecttypen":[],"roltypen":[],"besluittypen":[],"deelzaaktypen":[],"gerelateerdeZaaktypen":[],"zaakobjecttypen":[]}'
82+
1","link":""},"concept":true,"verantwoordelijke":"200000000","beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"versiedatum":"2025-06-19","beginObject":"2025-06-19","eindeObject":null,"catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/6f882079-47fb-47b4-bfcd-6b2c37015c07","statustypen":[],"resultaattypen":[],"eigenschappen":[],"informatieobjecttypen":[],"roltypen":[],"besluittypen":[],"deelzaaktypen":[],"gerelateerdeZaaktypen":[],"zaakobjecttypen":[]}'
8383
headers:
8484
API-version:
8585
- 1.3.1
@@ -88,13 +88,13 @@ interactions:
8888
Connection:
8989
- keep-alive
9090
Content-Length:
91-
- '1373'
91+
- '1374'
9292
Content-Type:
9393
- application/json
9494
Cross-Origin-Opener-Policy:
9595
- same-origin
9696
Location:
97-
- http://localhost:8003/catalogi/api/v1/zaaktypen/82bffef9-2fd7-4b0f-8904-154aa76f1316
97+
- http://localhost:8003/catalogi/api/v1/zaaktypen/4f0a8e80-e9f5-48e0-995e-b22390418176
9898
Referrer-Policy:
9999
- same-origin
100100
Vary:
@@ -107,8 +107,8 @@ interactions:
107107
code: 201
108108
message: Created
109109
- request:
110-
body: '{"catalogus": "http://localhost:8003/catalogi/api/v1/catalogussen/e72ef872-efb6-48b1-9b6c-63c23259dad0",
111-
"publicatie_indicatie": true, "informatieobjecttypen": [], "begin_geldigheid":
110+
body: '{"catalogus": "http://localhost:8003/catalogi/api/v1/catalogussen/6f882079-47fb-47b4-bfcd-6b2c37015c07",
111+
"publicatieIndicatie": true, "informatieobjecttypen": [], "beginGeldigheid":
112112
"2025-06-19", "omschrijving": "Tja"}'
113113
headers:
114114
Accept:
@@ -120,14 +120,14 @@ interactions:
120120
Connection:
121121
- keep-alive
122122
Content-Length:
123-
- '220'
123+
- '218'
124124
Content-Type:
125125
- application/json
126126
method: POST
127127
uri: http://localhost:8003/catalogi/api/v1/besluittypen
128128
response:
129129
body:
130-
string: '{"url":"http://localhost:8003/catalogi/api/v1/besluittypen/61c2be8f-7bc4-4427-81e1-f3127f15c251","catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/e72ef872-efb6-48b1-9b6c-63c23259dad0","zaaktypen":[],"omschrijving":"Tja","omschrijvingGeneriek":"","besluitcategorie":"","reactietermijn":null,"publicatieIndicatie":true,"publicatietekst":"","publicatietermijn":null,"toelichting":"","informatieobjecttypen":[],"beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"concept":true,"resultaattypen":[],"resultaattypenOmschrijving":[],"vastgelegdIn":[],"beginObject":"2025-06-19","eindeObject":null}'
130+
string: '{"url":"http://localhost:8003/catalogi/api/v1/besluittypen/d3c208b2-4f6a-4106-afec-7153ef531e82","catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/6f882079-47fb-47b4-bfcd-6b2c37015c07","zaaktypen":[],"omschrijving":"Tja","omschrijvingGeneriek":"","besluitcategorie":"","reactietermijn":null,"publicatieIndicatie":true,"publicatietekst":"","publicatietermijn":null,"toelichting":"","informatieobjecttypen":[],"beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"concept":true,"resultaattypen":[],"resultaattypenOmschrijving":[],"vastgelegdIn":[],"beginObject":"2025-06-19","eindeObject":null}'
131131
headers:
132132
API-version:
133133
- 1.3.1
@@ -142,7 +142,7 @@ interactions:
142142
Cross-Origin-Opener-Policy:
143143
- same-origin
144144
Location:
145-
- http://localhost:8003/catalogi/api/v1/besluittypen/61c2be8f-7bc4-4427-81e1-f3127f15c251
145+
- http://localhost:8003/catalogi/api/v1/besluittypen/d3c208b2-4f6a-4106-afec-7153ef531e82
146146
Referrer-Policy:
147147
- same-origin
148148
Vary:
@@ -166,14 +166,14 @@ interactions:
166166
Connection:
167167
- keep-alive
168168
method: GET
169-
uri: http://localhost:8003/catalogi/api/v1/zaaktypen/82bffef9-2fd7-4b0f-8904-154aa76f1316
169+
uri: http://localhost:8003/catalogi/api/v1/zaaktypen/4f0a8e80-e9f5-48e0-995e-b22390418176
170170
response:
171171
body:
172-
string: '{"url":"http://localhost:8003/catalogi/api/v1/zaaktypen/82bffef9-2fd7-4b0f-8904-154aa76f1316","identificatie":"ZAAKTYPE-2025-0000000001","omschrijving":"Another
173-
test zaaktype","omschrijvingGeneriek":"","vertrouwelijkheidaanduiding":"openbaar","doel":"New
172+
string: '{"url":"http://localhost:8003/catalogi/api/v1/zaaktypen/4f0a8e80-e9f5-48e0-995e-b22390418176","identificatie":"ZAAKTYPE-2025-0000000022","omschrijving":"Hair
173+
door produce run.","omschrijvingGeneriek":"","vertrouwelijkheidaanduiding":"openbaar","doel":"New
174174
Zaaktype 001","aanleiding":"New Zaaktype 001","toelichting":"","indicatieInternOfExtern":"intern","handelingInitiator":"aanvragen","onderwerp":"New
175175
Zaaktype 001","handelingBehandelaar":"handelin","doorlooptijd":"P40D","servicenorm":null,"opschortingEnAanhoudingMogelijk":false,"verlengingMogelijk":true,"verlengingstermijn":"P40D","trefwoorden":[],"publicatieIndicatie":false,"publicatietekst":"","verantwoordingsrelatie":[],"productenOfDiensten":["https://example.com/product/321"],"selectielijstProcestype":"https://selectielijst.openzaak.nl/api/v1/procestypen/aa8aa2fd-b9c6-4e34-9a6c-58a677f60ea0","referentieproces":{"naam":"ReferentieProces
176-
1","link":""},"concept":true,"verantwoordelijke":"200000000","beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"versiedatum":"2025-06-19","beginObject":"2025-06-19","eindeObject":null,"catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/e72ef872-efb6-48b1-9b6c-63c23259dad0","statustypen":[],"resultaattypen":[],"eigenschappen":[],"informatieobjecttypen":[],"roltypen":[],"besluittypen":[],"deelzaaktypen":[],"gerelateerdeZaaktypen":[],"zaakobjecttypen":[]}'
176+
1","link":""},"concept":true,"verantwoordelijke":"200000000","beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"versiedatum":"2025-06-19","beginObject":"2025-06-19","eindeObject":null,"catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/6f882079-47fb-47b4-bfcd-6b2c37015c07","statustypen":[],"resultaattypen":[],"eigenschappen":[],"informatieobjecttypen":[],"roltypen":[],"besluittypen":[],"deelzaaktypen":[],"gerelateerdeZaaktypen":[],"zaakobjecttypen":[]}'
177177
headers:
178178
API-version:
179179
- 1.3.1
@@ -182,13 +182,13 @@ interactions:
182182
Connection:
183183
- keep-alive
184184
Content-Length:
185-
- '1373'
185+
- '1374'
186186
Content-Type:
187187
- application/json
188188
Cross-Origin-Opener-Policy:
189189
- same-origin
190190
ETag:
191-
- '"6272072f5218982f508b03840e13da4f"'
191+
- '"38d7e2eafb46521bbc4c31ad5b46294c"'
192192
Referrer-Policy:
193193
- same-origin
194194
Vary:
@@ -201,7 +201,7 @@ interactions:
201201
code: 200
202202
message: OK
203203
- request:
204-
body: '{"besluittypen": ["http://localhost:8003/catalogi/api/v1/besluittypen/61c2be8f-7bc4-4427-81e1-f3127f15c251"]}'
204+
body: '{"besluittypen": ["http://localhost:8003/catalogi/api/v1/besluittypen/d3c208b2-4f6a-4106-afec-7153ef531e82"]}'
205205
headers:
206206
Accept:
207207
- '*/*'
@@ -216,14 +216,14 @@ interactions:
216216
Content-Type:
217217
- application/json
218218
method: PATCH
219-
uri: http://localhost:8003/catalogi/api/v1/zaaktypen/82bffef9-2fd7-4b0f-8904-154aa76f1316
219+
uri: http://localhost:8003/catalogi/api/v1/zaaktypen/4f0a8e80-e9f5-48e0-995e-b22390418176
220220
response:
221221
body:
222-
string: '{"url":"http://localhost:8003/catalogi/api/v1/zaaktypen/82bffef9-2fd7-4b0f-8904-154aa76f1316","identificatie":"ZAAKTYPE-2025-0000000001","omschrijving":"Another
223-
test zaaktype","omschrijvingGeneriek":"","vertrouwelijkheidaanduiding":"openbaar","doel":"New
222+
string: '{"url":"http://localhost:8003/catalogi/api/v1/zaaktypen/4f0a8e80-e9f5-48e0-995e-b22390418176","identificatie":"ZAAKTYPE-2025-0000000022","omschrijving":"Hair
223+
door produce run.","omschrijvingGeneriek":"","vertrouwelijkheidaanduiding":"openbaar","doel":"New
224224
Zaaktype 001","aanleiding":"New Zaaktype 001","toelichting":"","indicatieInternOfExtern":"intern","handelingInitiator":"aanvragen","onderwerp":"New
225225
Zaaktype 001","handelingBehandelaar":"handelin","doorlooptijd":"P40D","servicenorm":null,"opschortingEnAanhoudingMogelijk":false,"verlengingMogelijk":true,"verlengingstermijn":"P40D","trefwoorden":[],"publicatieIndicatie":false,"publicatietekst":"","verantwoordingsrelatie":[],"productenOfDiensten":["https://example.com/product/321"],"selectielijstProcestype":"https://selectielijst.openzaak.nl/api/v1/procestypen/aa8aa2fd-b9c6-4e34-9a6c-58a677f60ea0","referentieproces":{"naam":"ReferentieProces
226-
1","link":""},"concept":true,"verantwoordelijke":"200000000","beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"versiedatum":"2025-06-19","beginObject":"2025-06-19","eindeObject":null,"catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/e72ef872-efb6-48b1-9b6c-63c23259dad0","statustypen":[],"resultaattypen":[],"eigenschappen":[],"informatieobjecttypen":[],"roltypen":[],"besluittypen":["http://localhost:8003/catalogi/api/v1/besluittypen/61c2be8f-7bc4-4427-81e1-f3127f15c251"],"deelzaaktypen":[],"gerelateerdeZaaktypen":[],"zaakobjecttypen":[]}'
226+
1","link":""},"concept":true,"verantwoordelijke":"200000000","beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"versiedatum":"2025-06-19","beginObject":"2025-06-19","eindeObject":null,"catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/6f882079-47fb-47b4-bfcd-6b2c37015c07","statustypen":[],"resultaattypen":[],"eigenschappen":[],"informatieobjecttypen":[],"roltypen":[],"besluittypen":["http://localhost:8003/catalogi/api/v1/besluittypen/d3c208b2-4f6a-4106-afec-7153ef531e82"],"deelzaaktypen":[],"gerelateerdeZaaktypen":[],"zaakobjecttypen":[]}'
227227
headers:
228228
API-version:
229229
- 1.3.1
@@ -232,7 +232,7 @@ interactions:
232232
Connection:
233233
- keep-alive
234234
Content-Length:
235-
- '1462'
235+
- '1463'
236236
Content-Type:
237237
- application/json
238238
Cross-Origin-Opener-Policy:
@@ -260,10 +260,10 @@ interactions:
260260
Connection:
261261
- keep-alive
262262
method: GET
263-
uri: http://localhost:8003/catalogi/api/v1/besluittypen/61c2be8f-7bc4-4427-81e1-f3127f15c251
263+
uri: http://localhost:8003/catalogi/api/v1/besluittypen/d3c208b2-4f6a-4106-afec-7153ef531e82
264264
response:
265265
body:
266-
string: '{"url":"http://localhost:8003/catalogi/api/v1/besluittypen/61c2be8f-7bc4-4427-81e1-f3127f15c251","catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/e72ef872-efb6-48b1-9b6c-63c23259dad0","zaaktypen":["http://localhost:8003/catalogi/api/v1/zaaktypen/82bffef9-2fd7-4b0f-8904-154aa76f1316"],"omschrijving":"Tja","omschrijvingGeneriek":"","besluitcategorie":"","reactietermijn":null,"publicatieIndicatie":true,"publicatietekst":"","publicatietermijn":null,"toelichting":"","informatieobjecttypen":[],"beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"concept":true,"resultaattypen":[],"resultaattypenOmschrijving":[],"vastgelegdIn":[],"beginObject":"2025-06-19","eindeObject":null}'
266+
string: '{"url":"http://localhost:8003/catalogi/api/v1/besluittypen/d3c208b2-4f6a-4106-afec-7153ef531e82","catalogus":"http://localhost:8003/catalogi/api/v1/catalogussen/6f882079-47fb-47b4-bfcd-6b2c37015c07","zaaktypen":["http://localhost:8003/catalogi/api/v1/zaaktypen/4f0a8e80-e9f5-48e0-995e-b22390418176"],"omschrijving":"Tja","omschrijvingGeneriek":"","besluitcategorie":"","reactietermijn":null,"publicatieIndicatie":true,"publicatietekst":"","publicatietermijn":null,"toelichting":"","informatieobjecttypen":[],"beginGeldigheid":"2025-06-19","eindeGeldigheid":null,"concept":true,"resultaattypen":[],"resultaattypenOmschrijving":[],"vastgelegdIn":[],"beginObject":"2025-06-19","eindeObject":null}'
267267
headers:
268268
API-version:
269269
- 1.3.1
@@ -278,7 +278,7 @@ interactions:
278278
Cross-Origin-Opener-Policy:
279279
- same-origin
280280
ETag:
281-
- '"6e79b99da9b5502b0468612e7286e335"'
281+
- '"7e0aa869ebe1440c06b9e689322022bd"'
282282
Referrer-Policy:
283283
- same-origin
284284
Vary:

backend/src/openbeheer/besluittypen/tests/test_views.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,24 @@ def test_create(self):
9595
refreshed = ztc_client("OZ").get(data["url"]).json()
9696
self.assertIn(self.zaaktype.url, refreshed["zaaktypen"])
9797

98+
assert self.cassette
99+
# we shouldn't have sent snake_case to the service
100+
# OZ might work, but other implementations may not
101+
requests_to_service = (
102+
r for r in self.cassette.requests if r.uri.startswith(self.service.api_root)
103+
)
104+
requests_with_snake_case = [
105+
(r, r.body)
106+
for r in requests_to_service
107+
if r.body
108+
and any(
109+
snake_case in r.body
110+
for snake_case in [b"begin_geldigheid", b"publicatie_indicatie"]
111+
)
112+
]
113+
114+
assert requests_with_snake_case == []
115+
98116

99117
class BesluitTypeDetailViewTest(VCRAPITestCase):
100118
@classmethod

0 commit comments

Comments
 (0)