static::
assertSame(Response::HTTP_NO_CONTENT,
$this->
getBrowser()->
getResponse()->
getStatusCode(),
(string) $this->
getBrowser()->
getResponse()->
getContent());
static::
assertNotEmpty($response->headers->
get('Location'
));
static::
assertEquals('http://localhost/api/country/' .
$id,
$response->headers->
get('Location'
));
$browser =
$this->
getBrowser();
$connection =
$this->
getBrowser()->
getContainer()->
get(Connection::
class);
$user = TestUser::
createNewTestUser($connection,
['country:update', 'country:read'
]);
$user->
authorizeBrowser($browser);
$data =
['name' => 'not in system language'
];
$languageId =
$this->
getNonSystemLanguageId();
$browser->
setServerParameter('HTTP_sw-language-id',
$languageId);
$browser->
request( 'PATCH',
'/api/country/' .
$id,
[],
[],
[],
json_encode($data, \JSON_THROW_ON_ERROR
) );