Renaming frame in tests

This commit is contained in:
David Négrier 2020-05-08 15:20:49 +02:00
parent 492196b333
commit 8e9c1cac1e

View File

@ -3,7 +3,7 @@ import {Message} from "../src/Model/Websocket/Message";
describe("Message Model", () => {
it("should find userId and roomId", () => {
let message = {userId: "test1", roomId: "test2", name: "foo", frame: "user"};
let message = {userId: "test1", roomId: "test2", name: "foo", character: "user"};
let messageObject = new Message(message);
expect(messageObject.userId).toBe("test1");
expect(messageObject.roomId).toBe("test2");
@ -12,9 +12,9 @@ describe("Message Model", () => {
})
it("should expose a toJson method", () => {
let message = {userId: "test1", roomId: "test2", name: "foo", frame: "user"};
let message = {userId: "test1", roomId: "test2", name: "foo", character: "user"};
let messageObject = new Message(message);
expect(messageObject.toJson()).toEqual({userId: "test1", roomId: "test2", name: "foo", frame: "user"});
expect(messageObject.toJson()).toEqual({userId: "test1", roomId: "test2", name: "foo", character: "user"});
});
it("should find throw error when no userId", () => {