File tree Expand file tree Collapse file tree 3 files changed +25
-2
lines changed
Expand file tree Collapse file tree 3 files changed +25
-2
lines changed Original file line number Diff line number Diff line change @@ -100,7 +100,7 @@ Feature: Handle properly invalid data submitted to the API
100100 """
101101 Then the response status code should be 400
102102 And the response should be in JSON
103- And the header "Content-Type" should be equal to "application/ld +json; charset=utf-8"
103+ And the header "Content-Type" should be equal to "application/problem +json; charset=utf-8"
104104
105105 Scenario : Send non-array data when an array is expected
106106 When I add "Content-Type" header equal to "application/ld+json"
Original file line number Diff line number Diff line change 1414namespace ApiPlatform \Tests \Functional ;
1515
1616use ApiPlatform \Symfony \Bundle \Test \ApiTestCase ;
17+ use ApiPlatform \Tests \Fixtures \TestBundle \ApiResource \Issue6718 \Organization ;
18+ use ApiPlatform \Tests \SetupClassResourcesTrait ;
1719
1820class ItemUriTemplateTest extends ApiTestCase
1921{
22+ use SetupClassResourcesTrait;
23+
24+ /**
25+ * @return class-string[]
26+ */
27+ public static function getResources (): array
28+ {
29+ return [Organization::class];
30+ }
31+
2032 public function testIssue6718 (): void
2133 {
2234 self ::createClient ()->request ('GET ' , '/6718_users/1/organisation ' , [
Original file line number Diff line number Diff line change 1616use ApiPlatform \Symfony \Bundle \Test \ApiTestCase ;
1717use ApiPlatform \Tests \Fixtures \TestBundle \Entity \Issue6465 \Bar ;
1818use ApiPlatform \Tests \Fixtures \TestBundle \Entity \Issue6465 \Foo ;
19+ use ApiPlatform \Tests \SetupClassResourcesTrait ;
1920use Doctrine \ORM \EntityManagerInterface ;
2021use Doctrine \ORM \Tools \SchemaTool ;
2122
22- class JsonLd extends ApiTestCase
23+ class JsonLdTest extends ApiTestCase
2324{
25+ use SetupClassResourcesTrait;
26+
27+ /**
28+ * @return class-string[]
29+ */
30+ public static function getResources (): array
31+ {
32+ return [Foo::class, Bar::class];
33+ }
34+
2435 /**
2536 * The input DTO denormalizes an existing Doctrine entity.
2637 */
You can’t perform that action at this time.
0 commit comments