MessageTest: use TestNet3Params, rather than UnitTestParams
package org.bitcoinj.core;
-import org.bitcoinj.params.UnitTestParams;
+import org.bitcoinj.params.TestNet3Params;
import org.junit.Test;
public class MessageTest {
- private static final NetworkParameters UNITTEST = UnitTestParams.get();
+ private static final NetworkParameters TESTNET = TestNet3Params.get();
// If readStr() is vulnerable this causes OutOfMemory
@Test(expected = ProtocolException.class)
public void readStrOfExtremeLength() {
VarInt length = new VarInt(Integer.MAX_VALUE);
byte[] payload = length.encode();
- new VarStrMessage(UNITTEST, payload);
+ new VarStrMessage(TESTNET, payload);
}
static class VarStrMessage extends Message {
@@ -47,7 +47,7 @@ public class MessageTest {
public void readByteArrayOfExtremeLength() {
VarInt length = new VarInt(Integer.MAX_VALUE);
byte[] payload = length.encode();
- new VarBytesMessage(UNITTEST, payload);
+ new VarBytesMessage(TESTNET, payload);
}
static class VarBytesMessage extends Message {
