Use junit 4 API

This commit is contained in:
Sam Harwell 2012-11-01 08:46:56 -05:00
parent eca9090fce
commit 0446c91280
1 changed files with 5 additions and 4 deletions

View File

@ -1,10 +1,11 @@
package org.antlr.v4.test; package org.antlr.v4.test;
import junit.framework.TestCase;
import org.antlr.v4.runtime.atn.ArrayPredictionContext; import org.antlr.v4.runtime.atn.ArrayPredictionContext;
import org.antlr.v4.runtime.atn.PredictionContext; import org.antlr.v4.runtime.atn.PredictionContext;
import org.antlr.v4.runtime.atn.PredictionContextCache; import org.antlr.v4.runtime.atn.PredictionContextCache;
import org.antlr.v4.runtime.atn.SingletonPredictionContext; import org.antlr.v4.runtime.atn.SingletonPredictionContext;
import static org.junit.Assert.*;
import org.junit.Before;
import org.junit.Test; import org.junit.Test;
import java.util.ArrayDeque; import java.util.ArrayDeque;
@ -12,11 +13,11 @@ import java.util.Deque;
import java.util.IdentityHashMap; import java.util.IdentityHashMap;
import java.util.Map; import java.util.Map;
public class TestGraphNodes extends TestCase { public class TestGraphNodes {
PredictionContextCache contextCache; PredictionContextCache contextCache;
@Override @Before
protected void setUp() throws Exception { public void setUp() {
PredictionContext.globalNodeCount = 1; PredictionContext.globalNodeCount = 1;
contextCache = new PredictionContextCache(); contextCache = new PredictionContextCache();
} }