@@ -350,7 +350,7 @@ Feature: Subresource support
350
350
And the header "Content-Type" should be equal to "application/ld+json; charset=utf-8"
351
351
And the JSON should be equal to:
352
352
"""
353
- {
353
+ {+
354
354
"@context": "/contexts/DummyProduct",
355
355
"@id": "/dummy_products/2",
356
356
"@type": "DummyProduct",
@@ -365,3 +365,37 @@ Feature: Subresource support
365
365
"parent": null
366
366
}
367
367
"""
368
+
369
+ @dropSchema
370
+ Scenario : The OneToOne subresource should be accessible from owned side
371
+ Given there is a RelatedOwnedDummy and a RelatedOwningDummy object with OneToOne bidirectional relation
372
+ When I send a "GET" request to "/related_owned_dummies/1/related_owning_dummy"
373
+ And the response status code should be 200
374
+ And the response should be in JSON
375
+ And the header "Content-Type" should be equal to "application/ld+json; charset=utf-8"
376
+ And the JSON should be equal to:
377
+ """
378
+ {
379
+ "@context": "/contexts/RelatedOwningDummy",
380
+ "@id": "/related_owning_dummies/1",
381
+ "@type": "RelatedOwningDummy",
382
+ "id": 1
383
+ }
384
+ """
385
+
386
+ @dropSchema
387
+ Scenario : The OneToOne subresource should be accessible from owning side
388
+ Given there is a RelatedOwnedDummy and a RelatedOwningDummy object with OneToOne bidirectional relation
389
+ When I send a "GET" request to "/related_owning_dummies/1/related_owned_dummy"
390
+ And the response status code should be 200
391
+ And the response should be in JSON
392
+ And the header "Content-Type" should be equal to "application/ld+json; charset=utf-8"
393
+ And the JSON should be equal to:
394
+ """
395
+ {
396
+ "@context": "/contexts/RelatedOwnedDummy",
397
+ "@id": "/related_owned_dummies/1",
398
+ "@type": "RelatedOwnedDummy",
399
+ "id": 1
400
+ }
401
+ """
0 commit comments