Skip to content
Snippets Groups Projects
Verified Commit 718d2509 authored by Damien's avatar Damien
Browse files

Fix unit tests

parent 243c47a5
No related branches found
No related tags found
No related merge requests found
......@@ -51,7 +51,7 @@ class NoteController
$check = Validator::stringType()->notEmpty()->validate($data['note_text']);
if (!$check) {
return $response->withStatus(400)->withJson(['errors' => 'note_text is empty or not a string']);
return $response->withStatus(400)->withJson(['errors' => 'Data note_text is empty or not a string']);
}
if (!ResController::hasRightByResId(['resId' => $aArgs['resId'], 'userId' => $GLOBALS['userId']])) {
......
......@@ -145,6 +145,6 @@ class NoteControllerTest extends TestCase
$response = $noteController->create($fullRequest, new \Slim\Http\Response(), $resID);
$responseBody = json_decode((string)$response->getBody());
$this->assertSame('Bad Request note text', $responseBody->errors);
$this->assertSame('Data note_text is empty or not a string', $responseBody->errors);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment