feat: lab2 done

This commit is contained in:
2026-10-09 15:48:03 +03:00
parent f743ee10a2
commit 575f8ee386
104 changed files with 7038 additions and 1099 deletions
@@ -0,0 +1,40 @@
meta {
name: Send message as second user
type: http
seq: 2
}
post {
url: {{baseUrl}}/api/v1/chats/{{chatId}}/messages
body: json
auth: none
}
headers {
Authorization: Bearer {{secondToken}}
}
docs {
Любой участник чата может писать. Второе сообщение нужно, чтобы
страница с limit=1 вернула next_cursor и пагинацию можно было проверить.
}
body:json {
{
"text": "Ответ второго участника"
}
}
tests {
test("201 created", function() {
expect(res.status).to.equal(201);
});
test("sender — второй пользователь", function() {
expect(res.body.sender_id).to.equal(bru.getVar("secondUserId"));
});
}
script:post-response {
bru.setVar("secondMessageId", res.body.id);
}