You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 24, 2020. It is now read-only.
Multiple junit tests fail, both from the IDE and from "mvn clean install". For instance:
java.lang.ArrayIndexOutOfBoundsException: 0
at com.blockcypher.utils.sign.SignUtils.getBytesFromBase58Key(SignUtils.java:97)
at com.blockcypher.utils.sign.SignUtils.sign(SignUtils.java:50)
at com.blockcypher.utils.sign.SignUtils.signWithBase58KeyWithPubKey(SignUtils.java:40)
at com.blockcypher.service.TransactionServiceTest.testNewTransactionFromInputs(TransactionServiceTest.java:75)
and
java.lang.ArrayIndexOutOfBoundsException: 0
at com.blockcypher.utils.sign.SignUtils.getBytesFromBase58Key(SignUtils.java:97)
at com.blockcypher.utils.sign.SignUtils.sign(SignUtils.java:50)
at com.blockcypher.utils.sign.SignUtils.signWithBase58KeyWithPubKey(SignUtils.java:40)
at com.blockcypher.service.MultiSigTest.testMultiSigWithWebsocketOnConfirmedTransaction(MultiSigTest.java:57)
and
junit.framework.AssertionFailedError
at junit.framework.Assert.fail(Assert.java:55)
at junit.framework.Assert.assertTrue(Assert.java:22)
at junit.framework.Assert.assertNotNull(Assert.java:256)
at junit.framework.Assert.assertNotNull(Assert.java:248)
at com.blockcypher.service.AddressServiceTest.testGetAddress(AddressServiceTest.java:51)
The text was updated successfully, but these errors were encountered:
Hi spicylobe,
Did you put your own private key in:
public class AbstractServiceTest {
// In order to signWithBase58Key.. Of course do not store this is plain your java code... This is for test only!
protected static final String MY_PRIVATE_KEY = "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa";
I wouldn't expect to have to modify any code just to get unit tests to run. Why not include a valid private key that was generated only for use in unit tests? It seems like you could then test many additional elements that require matching key pairs.
Multiple junit tests fail, both from the IDE and from "mvn clean install". For instance:
java.lang.ArrayIndexOutOfBoundsException: 0
at com.blockcypher.utils.sign.SignUtils.getBytesFromBase58Key(SignUtils.java:97)
at com.blockcypher.utils.sign.SignUtils.sign(SignUtils.java:50)
at com.blockcypher.utils.sign.SignUtils.signWithBase58KeyWithPubKey(SignUtils.java:40)
at com.blockcypher.service.TransactionServiceTest.testNewTransactionFromInputs(TransactionServiceTest.java:75)
and
java.lang.ArrayIndexOutOfBoundsException: 0
at com.blockcypher.utils.sign.SignUtils.getBytesFromBase58Key(SignUtils.java:97)
at com.blockcypher.utils.sign.SignUtils.sign(SignUtils.java:50)
at com.blockcypher.utils.sign.SignUtils.signWithBase58KeyWithPubKey(SignUtils.java:40)
at com.blockcypher.service.MultiSigTest.testMultiSigWithWebsocketOnConfirmedTransaction(MultiSigTest.java:57)
and
junit.framework.AssertionFailedError
at junit.framework.Assert.fail(Assert.java:55)
at junit.framework.Assert.assertTrue(Assert.java:22)
at junit.framework.Assert.assertNotNull(Assert.java:256)
at junit.framework.Assert.assertNotNull(Assert.java:248)
at com.blockcypher.service.AddressServiceTest.testGetAddress(AddressServiceTest.java:51)
The text was updated successfully, but these errors were encountered: