You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Upgraded to APIP4 - except upload put
* Finish upgrade, remove PUT request support by default
* CS Fixes
* Remove 8.3 support
* Fix text for info.version regex allow hyphens
* Fix route voter
* Fix for next release of voters in symfony
* Fix updates to security contracts of voter and UserChecker
@@ -166,10 +167,16 @@ public function iSendARequestToTheResourceWithBody(string $method, string $resou
166
167
thrownewExpectationException(\sprintf("The resource with name $resource has not been defined. (Components that exist are `%s`)", implode('`, `', array_keys($this->resources))), $this->minkContext->getSession()->getDriver());
Copy file name to clipboardExpand all lines: features/publishable/publishable.feature
+8-8Lines changed: 8 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -203,7 +203,7 @@ Feature: Access to unpublished/draft resources should be configurable
203
203
Scenario: As a user with draft access, when I update a published resource, it should create and return a draft resource. Draft resource should not have the component position.
204
204
Given there is a publishable resource set to publish at "1970-12-31T23:59:59+00:00"
205
205
And there is a ComponentPosition with the resource "publishable_published"
206
-
When I send a "PUT" request to the resource "publishable_published" with body:
206
+
When I send a "PATCH" request to the resource "publishable_published" with body:
207
207
"""
208
208
{
209
209
"reference": "updated"
@@ -247,7 +247,7 @@ Feature: Access to unpublished/draft resources should be configurable
247
247
@loginAdmin
248
248
Scenario Outline: As a user with draft access, when I update a published resource with a publication date in the past (or now), it should be ignored.
249
249
Given there is a publishable resource set to publish at "1970-12-31T23:59:59+00:00"
250
-
When I send a "PUT" request to the resource "publishable_published" with data:
250
+
When I send a "PATCH" request to the resource "publishable_published" with data:
251
251
| publishedAt |
252
252
| <publishedAt> |
253
253
Then the response status code should be 200
@@ -260,7 +260,7 @@ Feature: Access to unpublished/draft resources should be configurable
260
260
@loginAdmin
261
261
Scenario Outline: As a user with draft access, when I update a published/draft resource with a draft resource available, and set a publication date in the past (or now), it should update the draft resource, merge it with the public resource, and remove the draft resource.
262
262
Given there is a published resource with a draft set to publish at "2999-12-31T23:59:59+00:00"
263
-
When I send a "PUT" request to the resource "<component>" with data:
263
+
When I send a "PATCH" request to the resource "<component>" with data:
264
264
| publishedAt | reference |
265
265
| <publishedAt> | updated |
266
266
Then the response status code should be 200
@@ -278,7 +278,7 @@ Feature: Access to unpublished/draft resources should be configurable
278
278
@loginAdmin
279
279
Scenario: As a user with draft access, when I update a published resource with a draft resource available, and set a publication date in the future, it should update and return the draft resource.
280
280
Given there is a published resource with a draft set to publish at "2999-12-31T23:59:59+00:00"
281
-
When I send a "PUT" request to the resource "publishable_published" with body:
281
+
When I send a "PATCH" request to the resource "publishable_published" with body:
282
282
"""
283
283
{
284
284
"publishedAt": "2991-11-11T23:59:59+00:00"
@@ -291,7 +291,7 @@ Feature: Access to unpublished/draft resources should be configurable
291
291
@loginUser
292
292
Scenario: As a user with no draft access, when I update a published resource, it should update and return the published resource.
293
293
Given there is a publishable resource set to publish at "1970-12-31T23:59:59+00:00"
294
-
When I send a "PUT" request to the resource "publishable_published" with body:
294
+
When I send a "PATCH" request to the resource "publishable_published" with body:
295
295
"""
296
296
{
297
297
"reference": "updated"
@@ -304,7 +304,7 @@ Feature: Access to unpublished/draft resources should be configurable
304
304
@loginUser
305
305
Scenario: As a user with no draft access, I cannot update a draft resource.
306
306
Given there is a publishable resource set to publish at "2999-12-31T23:59:59+00:00"
307
-
When I send a "PUT" request to the resource "publishable_draft" with body:
307
+
When I send a "PATCH" request to the resource "publishable_draft" with body:
308
308
"""
309
309
{
310
310
"reference": "updated"
@@ -315,7 +315,7 @@ Feature: Access to unpublished/draft resources should be configurable
315
315
@loginAdmin
316
316
Scenario: I cannot modify the publishedResource property via the API
317
317
Given there is a publishable resource set to publish at "2999-12-31T23:59:59+00:00"
318
-
When I send a "PUT" request to the resource "publishable_draft" with body:
318
+
When I send a "PATCH" request to the resource "publishable_draft" with body:
319
319
"""
320
320
{
321
321
"reference": "updated",
@@ -410,7 +410,7 @@ Feature: Access to unpublished/draft resources should be configurable
410
410
Scenario: When I publish a draft component where there is an existing published component, the newly published draft should inherit the old published component positions
411
411
Given there is a published resource with a draft set to publish at "2999-12-31T23:59:59+00:00"
412
412
And there is a ComponentPosition with the resource "publishable_published"
413
-
When I send a "PUT" request to the resource "publishable_draft" with body:
413
+
When I send a "PATCH" request to the resource "publishable_draft" with body:
Copy file name to clipboardExpand all lines: features/publishable/publishable_soft_validation.feature
+6-6Lines changed: 6 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -39,7 +39,7 @@ Feature: Soft validation on draft resources
39
39
@loginAdmin
40
40
Scenario Outline: When I update a draft resource, there should be a header to indicate whether validation is passing if I were to try and publish it
41
41
Given there is a DummyPublishableWithValidation resource
42
-
When I send a "PUT" request to the resource "publishable_draft" with data:
42
+
When I send a "PATCH" request to the resource "publishable_draft" with data:
43
43
| resourceData |
44
44
| <data> |
45
45
Then the response status code should be 200
@@ -53,7 +53,7 @@ Feature: Soft validation on draft resources
53
53
@loginAdmin
54
54
Scenario Outline: I update a draft resource with data that is OK for a draft, but not for published
55
55
Given there is a DummyPublishableWithValidation resource
56
-
When I send a "PUT" request to the resource "publishable_draft" and the postfix "?<postfix>" with data:
56
+
When I send a "PATCH" request to the resource "publishable_draft" and the postfix "?<postfix>" with data:
57
57
| publishedAt | resourceData |
58
58
| <publishedAt> | <data> |
59
59
Then the response status code should be <httpStatus>
@@ -66,7 +66,7 @@ Feature: Soft validation on draft resources
66
66
@loginAdmin
67
67
Scenario Outline: I update a draft resource with data that is valid to make it published when ready
68
68
Given there is a DummyPublishableWithValidation resource
69
-
When I send a "PUT" request to the resource "publishable_draft" and the postfix "?<postfix>" with data:
69
+
When I send a "PATCH" request to the resource "publishable_draft" and the postfix "?<postfix>" with data:
70
70
| publishedAt | resourceData |
71
71
| <publishedAt> | <data> |
72
72
Then the response status code should be <httpStatus>
@@ -80,7 +80,7 @@ Feature: Soft validation on draft resources
80
80
@loginAdmin
81
81
Scenario Outline: I update a draft resource and expect to see a hard fail with validation errors and no need to populate metadata as the output is the violations
82
82
Given there is a DummyPublishableWithValidation resource
83
-
When I send a "PUT" request to the resource "publishable_draft" and the postfix "?<postfix>" with data:
83
+
When I send a "PATCH" request to the resource "publishable_draft" and the postfix "?<postfix>" with data:
84
84
| publishedAt | resourceData |
85
85
| <publishedAt> | <data> |
86
86
Then the response status code should be <httpStatus>
@@ -100,7 +100,7 @@ Feature: Soft validation on draft resources
100
100
@loginAdmin
101
101
Scenario Outline: Updating a resource to published. The querystring should make no difference and the response is published so no header should exist
102
102
Given there is a DummyPublishableWithValidation resource
103
-
When I send a "PUT" request to the resource "publishable_draft" and the postfix "?<postfix>" with data:
103
+
When I send a "PATCH" request to the resource "publishable_draft" and the postfix "?<postfix>" with data:
104
104
| publishedAt | resourceData |
105
105
| <publishedAt> | <data> |
106
106
Then the response status code should be <httpStatus>
@@ -114,7 +114,7 @@ Feature: Soft validation on draft resources
114
114
@loginAdmin
115
115
Scenario: I update a published resource with the querystring "validate_published=false" and "published=true" should have no effect and published resource validation should still apply
116
116
Given there is a DummyPublishableWithValidation resource set to publish at "1970-12-31T23:59:59+00:00"
117
-
When I send a "PUT" request to the resource "publishable_published" and the postfix "?validate_published=false&published=true" with body:
117
+
When I send a "PATCH" request to the resource "publishable_published" and the postfix "?validate_published=false&published=true" with body:
0 commit comments