Skip to content

Commit

Permalink
test(hydra): fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
valentin-dassonville committed Oct 29, 2024
1 parent 93e7b9d commit ce964a4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion features/hydra/docs.feature
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Feature: Documentation support
And the response should be in JSON
And the header "Content-Type" should be equal to "application/ld+json; charset=utf-8"
# Context
And the JSON node "@context[0]" should be equal to "http://www.w3.org/ns/hydra/context.jsonld"
And the JSON node "@context[0]" should be equal to "https://www.w3.org/ns/hydra/context.jsonld"
And the JSON node "@context[1].@vocab" should be equal to "http://example.com/docs.jsonld#"
And the JSON node "@context[1].hydra" should be equal to "http://www.w3.org/ns/hydra/core#"
And the JSON node "@context[1].rdf" should be equal to "http://www.w3.org/1999/02/22-rdf-syntax-ns#"
Expand Down
6 changes: 3 additions & 3 deletions src/Hydra/Tests/Serializer/DocumentationNormalizerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ private function doTestNormalize($resourceMetadataFactory = null): void

$expected = [
'@context' => [
'http://www.w3.org/ns/hydra/context.jsonld',
'https://www.w3.org/ns/hydra/context.jsonld',
[
'@vocab' => '/doc#',
'hydra' => 'http://www.w3.org/ns/hydra/core#',
Expand Down Expand Up @@ -406,7 +406,7 @@ public function testNormalizeInputOutputClass(): void

$expected = [
'@context' => [
'http://www.w3.org/ns/hydra/context.jsonld',
'https://www.w3.org/ns/hydra/context.jsonld',
[
'@vocab' => '/doc#',
'hydra' => 'http://www.w3.org/ns/hydra/core#',
Expand Down Expand Up @@ -766,7 +766,7 @@ public function testNormalizeWithoutPrefix(): void

$expected = [
'@context' => [
'http://www.w3.org/ns/hydra/context.jsonld',
'https://www.w3.org/ns/hydra/context.jsonld',
[
'@vocab' => '/doc#',
'hydra' => 'http://www.w3.org/ns/hydra/core#',
Expand Down
2 changes: 1 addition & 1 deletion tests/JsonLd/ContextBuilderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ public function testResourceContextWithoutHydraPrefix(): void
$contextBuilder = new ContextBuilder($this->resourceNameCollectionFactoryProphecy->reveal(), $this->resourceMetadataCollectionFactoryProphecy->reveal(), $this->propertyNameCollectionFactoryProphecy->reveal(), $this->propertyMetadataFactoryProphecy->reveal(), $this->urlGeneratorProphecy->reveal(), null, null, [ContextBuilder::HYDRA_CONTEXT_HAS_PREFIX => false]);

$expected = [
'http://www.w3.org/ns/hydra/context.jsonld',
'https://www.w3.org/ns/hydra/context.jsonld',
[
'@vocab' => '#',
'hydra' => 'http://www.w3.org/ns/hydra/core#',
Expand Down

0 comments on commit ce964a4

Please sign in to comment.