mirror of
https://github.com/essentials/Essentials.git
synced 2025-08-16 03:24:31 +02:00
Put test classes where they belong
This commit is contained in:
@@ -2,7 +2,6 @@ package com.earth2me.essentials;
|
||||
|
||||
import com.earth2me.essentials.api.NoLoanPermittedException;
|
||||
import com.earth2me.essentials.api.UserDoesNotExistException;
|
||||
import com.earth2me.essentials.craftbukkit.DummyOfflinePlayer;
|
||||
import com.earth2me.essentials.user.User;
|
||||
import java.io.IOException;
|
||||
import junit.framework.TestCase;
|
||||
@@ -35,7 +34,7 @@ public class EconomyTest extends TestCase
|
||||
{
|
||||
fail("IOException");
|
||||
}
|
||||
server.addPlayer(new User(new DummyOfflinePlayer(PLAYERNAME), ess));
|
||||
server.addPlayer(new User(new FakeOfflinePlayer(PLAYERNAME), ess));
|
||||
}
|
||||
|
||||
// only one big test, since we use static instances
|
||||
|
@@ -1,4 +1,4 @@
|
||||
package com.earth2me.essentials.craftbukkit;
|
||||
package com.earth2me.essentials;
|
||||
|
||||
import java.util.Map;
|
||||
import org.bukkit.Bukkit;
|
||||
@@ -7,11 +7,11 @@ import org.bukkit.OfflinePlayer;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
|
||||
public class DummyOfflinePlayer implements OfflinePlayer
|
||||
public class FakeOfflinePlayer implements OfflinePlayer
|
||||
{
|
||||
private final transient String name;
|
||||
|
||||
public DummyOfflinePlayer(String name)
|
||||
public FakeOfflinePlayer(String name)
|
||||
{
|
||||
this.name = name;
|
||||
}
|
@@ -1,7 +1,6 @@
|
||||
package com.earth2me.essentials;
|
||||
|
||||
import com.avaje.ebean.config.ServerConfig;
|
||||
import com.earth2me.essentials.craftbukkit.FakeWorld;
|
||||
import java.io.File;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.Callable;
|
||||
|
@@ -1,4 +1,4 @@
|
||||
package com.earth2me.essentials.craftbukkit;
|
||||
package com.earth2me.essentials;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.Collection;
|
@@ -1,7 +1,6 @@
|
||||
package com.earth2me.essentials;
|
||||
|
||||
import com.earth2me.essentials.api.IUser;
|
||||
import com.earth2me.essentials.craftbukkit.DummyOfflinePlayer;
|
||||
import com.earth2me.essentials.user.User;
|
||||
import java.io.IOException;
|
||||
import junit.framework.TestCase;
|
||||
@@ -33,7 +32,7 @@ public class UserTest extends TestCase
|
||||
{
|
||||
fail("IOException");
|
||||
}
|
||||
base1 = new User(new DummyOfflinePlayer("testPlayer1"), ess);
|
||||
base1 = new User(new FakeOfflinePlayer("testPlayer1"), ess);
|
||||
server.addPlayer(base1);
|
||||
ess.getUser(base1);
|
||||
}
|
||||
|
Reference in New Issue
Block a user