fix: fixed types in MessageRelay and LobbyConnection
This commit is contained in:
parent
fcf43fcd83
commit
d2d9712b61
@ -0,0 +1,2 @@
|
|||||||
|
package uulm.teamname.marvelous.server.Lobby.pipelining;public class PauseSegment {
|
||||||
|
}
|
@ -94,8 +94,8 @@ public class LobbyConnection {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public boolean contains(WebSocket webSocket) {
|
public boolean contains(Participant participant) {
|
||||||
return player1 == webSocket || player2 == webSocket || spectators.contains(webSocket);
|
return player1 == participant || player2 == participant || spectators.contains(participant);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Methods to send events
|
// Methods to send events
|
||||||
|
@ -31,7 +31,7 @@ public class MessageRelay {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void sendMessage (LobbyConnection origin, Participant recipient, Event[] events) {
|
public void sendMessage (LobbyConnection origin, Participant recipient, Event[] events) {
|
||||||
switch (target) {
|
switch (recipient.type) {
|
||||||
case Player1 -> {
|
case Player1 -> {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,5 @@
|
|||||||
|
import static org.mockito.Mockito.*;
|
||||||
|
import static org.junit.jupiter.api.Assertions.*;
|
||||||
|
class PauseSegmentTest {
|
||||||
|
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user