Skip to content

Commit

Permalink
fixed NPCList test in order not to break tests caching NPCList
Browse files Browse the repository at this point in the history
  • Loading branch information
nhnb committed Oct 21, 2023
1 parent c232b84 commit 556ab86
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
1 change: 0 additions & 1 deletion src/games/stendhal/server/entity/npc/NPCList.java
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ public static NPCList get() {
}

protected NPCList() {
instance = this;
contents = new HashMap<String, SpeakerNPC>();

}
Expand Down
12 changes: 0 additions & 12 deletions tests/games/stendhal/server/entity/npc/NPCListTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,25 +15,13 @@
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertSame;

import org.junit.Test;

import games.stendhal.server.core.engine.SingletonRepository;
import utilities.PlayerTestHelper;

public class NPCListTest {

/**
* Tests for get.
*/
@Test
public final void testGet() {
final NPCList npclist = new NPCList() {
};
assertSame(npclist, SingletonRepository.getNPCList());
}

/**
* Tests for addHas.
*/
Expand Down

0 comments on commit 556ab86

Please sign in to comment.