Toggle navigation
Toggle navigation
This project
Loading...
Sign in
강동현
/
nodejs-game
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
강동현
2021-06-08 00:48:09 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
01b42c6989838dcb1a702706c1771dc81450204a
01b42c69
1 parent
f00a02d7
Builds for 1 pipeline
passed
in 6 minutes 40 seconds
room.canStart() 리턴 타입에 맞게 테스트 수정
Changes
1
Builds
3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
server/test/ready.test.ts
server/test/ready.test.ts
View file @
01b42c6
...
...
@@ -53,7 +53,7 @@ describe("준비", () => {
it
(
"혼자 있는 방에서는 게임을 시작할 수 없습니다"
,
()
=>
{
const
{
room
}
=
prepareJoinedRoom
(
1
);
expect
(
room
.
canStart
()).
eq
(
false
);
expect
(
room
.
canStart
()
.
ok
).
eq
(
false
);
});
it
(
"모두가 준비해야 게임을 시작할 수 있습니다"
,
()
=>
{
const
{
...
...
@@ -62,7 +62,7 @@ describe("준비", () => {
}
=
prepareJoinedRoom
(
3
);
// 2, 3 모두 준비 안함
expect
(
room
.
canStart
()).
eq
(
false
);
expect
(
room
.
canStart
()
.
ok
).
eq
(
false
);
// 2만 준비
expect
(
socket2
.
test
(
"ready"
,
{
ready
:
true
}).
ok
).
eq
(
true
);
...
...
@@ -70,10 +70,10 @@ describe("준비", () => {
// 3만 준비
expect
(
socket2
.
test
(
"ready"
,
{
ready
:
false
}).
ok
).
eq
(
true
);
expect
(
socket3
.
test
(
"ready"
,
{
ready
:
true
}).
ok
).
eq
(
true
);
expect
(
room
.
canStart
()).
eq
(
false
);
expect
(
room
.
canStart
()
.
ok
).
eq
(
false
);
// 2, 3 모두 준비
expect
(
socket2
.
test
(
"ready"
,
{
ready
:
true
}).
ok
).
eq
(
true
);
expect
(
room
.
canStart
()).
eq
(
true
);
expect
(
room
.
canStart
()
.
ok
).
eq
(
true
);
});
});
...
...
Please
register
or
login
to post a comment