World worldMock = mock(World.class);
Warzone zoneMock = mock(Warzone.class);
when(zoneMock.getTeams()).thenReturn(new ArrayList<Team>());
when(zoneMock.getMonuments()).thenReturn(new ArrayList<Monument>());
ZoneVolume volume = new ZoneVolume("test", worldMock, zoneMock);
Location nw = new Location(worldMock, -64, 64, 64);
// Act
Location existingCorner1 = new Location(worldMock, -32, 32, 32); // nw
volume.setCornerOne(existingCorner1); // corner 1 already set
Location existingCorner2 = new Location(worldMock, 32, 96, -32); // se
volume.setCornerTwo(existingCorner2); // corner 2 already set
volume.setNorthwest(nw);
// Assert
// first corner should move but not along y
Location movedOne = new Location(worldMock, -64, 32, 64);
assertEquals(movedOne, volume.getCornerOne());
// second corner shouldn't move
assertEquals(existingCorner2, volume.getCornerTwo());
}