added tests

This commit is contained in:
pinpong 2016-12-27 23:51:12 +01:00
parent 11bb41a889
commit 8eb007993b

View File

@ -3,6 +3,9 @@ package jota;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import jota.dto.response.*;
import jota.error.ArgumentException;
import jota.error.InvalidBundleException;
import jota.error.InvalidSignatureException;
import jota.model.Transfer;
import org.hamcrest.core.Is;
import org.hamcrest.core.IsNull;
@ -184,4 +187,15 @@ public class IotaAPIProxyTest {
public void shouldFindTransactionObjects() {
assertThat(proxy.findTransactionObjects(new String[]{TEST_ADDRESS_WITH_CHECKSUM}), IsNull.notNullValue());
}
@Test
public void shouldGetBundle() throws InvalidBundleException, ArgumentException, InvalidSignatureException {
assertThat(proxy.getBundle(TEST_HASH), IsNull.notNullValue());
}
@Test
public void shouldGetTrasfers() throws InvalidBundleException, ArgumentException, InvalidSignatureException {
assertThat(proxy.getTransfers(TEST_SEED, 0, 2, true), IsNull.notNullValue());
assertThat(proxy.getTransfers(TEST_SEED, 0, 2, false), IsNull.notNullValue());
}
}