| package net.glowstone.constants; |
| |
| import static org.hamcrest.CoreMatchers.is; |
| import static org.junit.Assert.assertThat; |
| |
| import org.bukkit.block.Biome; |
| import org.junit.jupiter.api.Disabled; |
| import org.junit.jupiter.params.ParameterizedTest; |
| import org.junit.jupiter.params.provider.EnumSource; |
| |
| /** |
| * Tests for {@link GlowBiome}. |
| */ |
| // TODO: use builder |
| @Disabled |
| public class BiomeTest { |
| |
| @EnumSource(Biome.class) |
| @ParameterizedTest |
| public void testIdMapping(Biome biome) { |
| int id = GlowBiome.getId(biome); |
| assertThat("No id specified for biome " + biome, id == -1, is(false)); |
| assertThat("Mapping for id " + id + " mismatch", GlowBiome.getBiome(id), is(biome)); |
| } |
| |
| } |