1
0
mirror of synced 2024-11-21 21:06:07 +03:00

Fix tests

This commit is contained in:
Uryvskiy Dima 2024-01-16 23:47:15 +03:00
parent f37434af17
commit 0fce4a49db
3 changed files with 24 additions and 23 deletions

View File

@ -3,8 +3,8 @@
/**
* PHP version 7.3
*
* @category TaskHistory
* @package RetailCrm\Api\Model\Entity\TaskComment
* @category TaskComment
* @package RetailCrm\Api\Model\Entity\T
*/
namespace RetailCrm\Api\Model\Entity\Tasks;

View File

@ -283,7 +283,7 @@ class Tasks extends AbstractApiResourceGroup
* $request->limit = 100;
* $request->page = 1;
* $request->filter = new TaskHistoryFilter();
* $request->filter->sinceId = 1111;
* $request->filter->sinceId = 1;
*
* try {
* $response = $client->tasks->history($request);
@ -326,6 +326,7 @@ class Tasks extends AbstractApiResourceGroup
$request,
TasksHistoryResponse::class
);
return $response;
}
}

View File

@ -193,12 +193,12 @@ EOF;
"oldValue": null,
"newValue": 1,
"task": {
"id":95978,
"id": 1,
"text": "",
"commentary": "",
"createdAt": "2023-03-22 19:00:29",
"complete": false,
"performer":116,
"performer": 2,
"performerType": "user",
"customer":{
"type": "customer",
@ -210,9 +210,9 @@ EOF;
}
EOF;
$mock = static::createApiMockBuilder('tasks/1');
$mock = static::createApiMockBuilder('tasks/history');
$mock->matchMethod(RequestMethod::GET)
->reply(200)
->reply()
->withBody($json);
$client = TestClientFactory::createClient($mock->getClient());
@ -225,6 +225,6 @@ EOF;
$response = $client->tasks->history($request);
self::assertModelEqualsToResponse($json, $response);
self::assertModelEqualsToResponse($json, $response, true);
}
}