Skip to content
Draft
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
374 changes: 374 additions & 0 deletions .redocly.lint-ignore.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion tests/Fixtures/TestBundle/ApiResource/DummyWebhook.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
use ApiPlatform\OpenApi\Model\PathItem;

#[ApiResource(operations: [new Get(openapi: new Webhook(
name: 'a',
name: 'a/{id}',
pathItem: new PathItem(
get: new Operation(
summary: 'Something else here',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,15 @@ class NumericValidated
#[ORM\Column]
public int $greaterThanMe;

#[Assert\GreaterThanOrEqual(value: '10.99')]
#[Assert\GreaterThanOrEqual(value: 10.99)]
#[ORM\Column]
public float $greaterThanOrEqualToMe;

#[Assert\LessThan(value: 99)]
#[ORM\Column]
public int $lessThanMe;

#[Assert\LessThanOrEqual(value: '99.33')]
#[Assert\LessThanOrEqual(value: 99.33)]
#[ORM\Column]
public float $lessThanOrEqualToMe;

Expand Down
2 changes: 1 addition & 1 deletion tests/Fixtures/TestBundle/Entity/Issue7135/Foo.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
shortName: 'FooPr7135',
operations: [
new Post(
uriTemplate: '/pull-request-7135/foo/',
uriTemplate: '/pull-request-7135/foo',
),
],
normalizationContext: ['iri_only' => true],
Expand Down
4 changes: 4 additions & 0 deletions tests/Fixtures/app/ruleset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,7 @@ rules:
component-description: false
paths-kebab-case: false
no-unnecessary-combinator: false
oas-missing-type: false
oas3-unused-component: false
operation-tags: false
oas3-api-servers: false
4 changes: 2 additions & 2 deletions tests/Functional/Issues/Issue7135Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public function testValidPostRequestWithIriWhenIdentifierIsUuid(): void
$this->recreateSchema(self::getResources());
$bar = $this->loadBarFixture();

$response = self::createClient()->request('POST', '/pull-request-7135/foo/', [
$response = self::createClient()->request('POST', '/pull-request-7135/foo', [
'json' => [
'bar' => 'pull-request-7135/bar/'.$bar->id,
],
Expand All @@ -63,7 +63,7 @@ public function testInvalidPostRequestWithIriWhenIdentifierIsUuid(): void
$this->markTestSkipped();
}

$response = self::createClient()->request('POST', '/pull-request-7135/foo/', [
$response = self::createClient()->request('POST', '/pull-request-7135/foo', [
'json' => [
'bar' => 'pull-request-7135/bar/invalid-uuid',
],
Expand Down
2 changes: 1 addition & 1 deletion tests/Functional/OpenApiTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ public function testRetrieveTheOpenApiDocumentation(): void
$this->assertSame('Allows you to reduce the response to contain only the properties you need. If your desired property is nested, you can address it using nested arrays. Example: foobar[]={propertyName}&foobar[]={anotherPropertyName}&foobar[{nestedPropertyParent}][]={nestedProperty}', $json['paths']['/dummy_cars']['get']['parameters'][9]['description']);

// Webhook
$this->assertSame('Something else here for example', $json['webhooks']['a']['get']['description']);
$this->assertSame('Something else here for example', $json['webhooks']['a/{id}']['get']['description']);
$this->assertSame('Hi! it\'s me, I\'m the problem, it\'s me', $json['webhooks']['b']['post']['description']);

// Subcollection - check filter on subResource
Expand Down
Loading