Skip to content

BC Breaks #7258

Closed
Closed
@norkunas

Description

@norkunas

API Platform version(s) affected: 4.1.17

Description
Not sure when and where, but now some tests fail:

--- Expected
+++ Actual
@@ @@
         '@type' => 'CompanyLeadPreference'
         'industries' => Array (
-            0 => '/api/industries/01936891-9...'
+            0 => 'http://localhost/api/industries/01936891-9...'
         )
         'markets' => Array (
-            0 => '/api/markets/01934ee1-5083...'
+            0 => 'http://localhost/api/markets/01934ee1-5083...'
         )

Here we have an intermediate resource which is not api resource, but the skill resource has apiresource definition:

--- Expected
+++ Actual
@@ @@
        
             '@type' => 'CompanySkill'
             'skill' => Array (
                 '@type' => 'Skill'
-                '@id' => '/api/skills/01935232-6f05-7e2...fe23e1'
                 'id' => '01935232-6f05-7e2e-b4f6-943d3dfe23e1'

and not sure about this:

Failed asserting that '{\n
    "@context": "/api/contexts/Error",\n
    "@id": "/api/errors/403",\n
    "@type": "hydra:Error",\n
    "title": "An error occurred",\n
    "detail": "Access Denied. The user doesn't have ROLE_ADMIN.",\n
    "status": 403,\n
    "type": "/errors/403",\n
    "description": "Access Denied. The user doesn't have ROLE_ADMIN.",\n
    "hydra:description": "Access Denied. The user doesn't have ROLE_ADMIN.",\n
    "hydra:title": "An error occurred"\n
}' matches JSON string "{
  "@context": "/api/contexts/Error",
  "@id": "/api/errors/403",
  "@type": "hydra:Error",
  "title": "An error occurred",
  "description": "Access Denied.",
  "detail": "Access Denied.",
  "status": 403,
  "type": "/errors/403",
  "hydra:title": "An error occurred",
  "hydra:description": "Access Denied."
}".

How to reproduce

Possible Solution

Additional Context

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions