mirror of
				https://github.com/inf112-v20/Fiasko.git
				synced 2025-11-04 03:33:45 +01:00 
			
		
		
		
	Flytter tester som hadde havnet i feil klasse
This commit is contained in:
		@@ -40,16 +40,6 @@ public class TileTypeTest {
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Test
 | 
			
		||||
    public void invalidTileTypeIDReturnsNull() {
 | 
			
		||||
        assertNull(TileType.getTileTypeFromID(-1));
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Test (expected = IllegalArgumentException.class)
 | 
			
		||||
    public void invalidTileDirectionThrowsError() {
 | 
			
		||||
        new Tile(TileType.TILE, Direction.NORTH_EAST);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Test
 | 
			
		||||
    public void allTilesHaveUniqueId() {
 | 
			
		||||
        /* This test is also done implicitly by the allTileTypesIDConversionToIDAndBack test, but that test may fail
 | 
			
		||||
 
 | 
			
		||||
@@ -6,6 +6,7 @@ import org.junit.Before;
 | 
			
		||||
import org.junit.Test;
 | 
			
		||||
 | 
			
		||||
import static org.junit.Assert.assertEquals;
 | 
			
		||||
import static org.junit.Assert.assertNull;
 | 
			
		||||
 | 
			
		||||
public class TileTest {
 | 
			
		||||
    private Tile tile;
 | 
			
		||||
@@ -38,8 +39,13 @@ public class TileTest {
 | 
			
		||||
        assertEquals(Direction.SOUTH, tile2.getDirection());
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Test
 | 
			
		||||
    public void invalidTileTypeIDReturnsNull() {
 | 
			
		||||
        assertNull(TileType.getTileTypeFromID(-1));
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Test (expected = IllegalArgumentException.class)
 | 
			
		||||
    public void invalidTileThrowsException() {
 | 
			
		||||
        new Tile(TileType.CONVEYOR_BELT_FAST, Direction.NORTH_EAST);
 | 
			
		||||
    public void invalidTileDirectionThrowsError() {
 | 
			
		||||
        new Tile(TileType.TILE, Direction.NORTH_EAST);
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
		Reference in New Issue
	
	Block a user