Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Test
- void run() throws IOException, ClassNotFoundException {
- //given
- FXMLWarehouse warehouse = spy(new FXMLWarehouse(100, 1000));
- Server server = spy(new Server(warehouse));
- //when
- when(server.readObject(server.fromClient)).thenReturn(0x2);
- server.run();
- //then
- verify(server).writeObject(null, warehouse.getAllCargo());
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement