summaryrefslogtreecommitdiffstats
path: root/src/test/java
diff options
context:
space:
mode:
authormbax <matt@phozop.net>2013-11-13 17:53:49 -0700
committerWesley Wolfe <weswolf@aol.com>2013-11-30 19:01:48 -0600
commit3f04224e85bd0482968a992719e88a3dd8a80035 (patch)
treed6d63bfe3f0ca3eb896b8f918419d44fbeca8f6c /src/test/java
parent36b2175edb77920293bc5c88a3338bbbd8346552 (diff)
downloadbukkit-3f04224e85bd0482968a992719e88a3dd8a80035.tar
bukkit-3f04224e85bd0482968a992719e88a3dd8a80035.tar.gz
bukkit-3f04224e85bd0482968a992719e88a3dd8a80035.tar.lz
bukkit-3f04224e85bd0482968a992719e88a3dd8a80035.tar.xz
bukkit-3f04224e85bd0482968a992719e88a3dd8a80035.zip
Update Update Bukkit to 1.7.2
Diffstat (limited to 'src/test/java')
-rw-r--r--src/test/java/org/bukkit/AchievementTest.java21
-rw-r--r--src/test/java/org/bukkit/MaterialTest.java10
-rw-r--r--src/test/java/org/bukkit/StatisticTest.java15
3 files changed, 8 insertions, 38 deletions
diff --git a/src/test/java/org/bukkit/AchievementTest.java b/src/test/java/org/bukkit/AchievementTest.java
deleted file mode 100644
index 53ac7fa6..00000000
--- a/src/test/java/org/bukkit/AchievementTest.java
+++ /dev/null
@@ -1,21 +0,0 @@
-package org.bukkit;
-
-import static org.hamcrest.CoreMatchers.is;
-import static org.junit.Assert.assertThat;
-
-import org.junit.Test;
-
-public class AchievementTest {
-
- @Test
- public void getById() {
- for (Achievement achievement : Achievement.values()) {
- assertThat(Achievement.getById(achievement.getId()), is(achievement));
- }
- }
-
- @Test
- public void getByOffset() {
- assertThat(Achievement.getById(Achievement.STATISTIC_OFFSET), is(Achievement.values()[0]));
- }
-}
diff --git a/src/test/java/org/bukkit/MaterialTest.java b/src/test/java/org/bukkit/MaterialTest.java
index e74e2f28..cbca8409 100644
--- a/src/test/java/org/bukkit/MaterialTest.java
+++ b/src/test/java/org/bukkit/MaterialTest.java
@@ -15,8 +15,11 @@ public class MaterialTest {
}
@Test
- public void getById() {
+ public void getById() throws Throwable {
for (Material material : Material.values()) {
+ if (material.getClass().getField(material.name()).getAnnotation(Deprecated.class) != null) {
+ continue;
+ }
assertThat(Material.getMaterial(material.getId()), is(material));
}
}
@@ -56,8 +59,11 @@ public class MaterialTest {
}
@Test
- public void matchMaterialById() {
+ public void matchMaterialById() throws Throwable {
for (Material material : Material.values()) {
+ if (material.getClass().getField(material.name()).getAnnotation(Deprecated.class) != null) {
+ continue;
+ }
assertThat(Material.matchMaterial(String.valueOf(material.getId())), is(material));
}
}
diff --git a/src/test/java/org/bukkit/StatisticTest.java b/src/test/java/org/bukkit/StatisticTest.java
deleted file mode 100644
index 5fc763f0..00000000
--- a/src/test/java/org/bukkit/StatisticTest.java
+++ /dev/null
@@ -1,15 +0,0 @@
-package org.bukkit;
-
-import static org.hamcrest.CoreMatchers.is;
-import static org.junit.Assert.assertThat;
-
-import org.junit.Test;
-
-public class StatisticTest {
- @Test
- public void getById() {
- for (Statistic statistic : Statistic.values()) {
- assertThat(Statistic.getById(statistic.getId()), is(statistic));
- }
- }
-}