@Test
public void getAccountCount() throws Exception {

    KeyPair account1 = createRandomAccount();
    KeyPair account2 = createRandomAccount();
    KeyPair account3 = createRandomAccount();
    fakeKeyStore = new FakeKeyStore(Arrays.asList(account1, account2, account3));
    kinClient = createNewKinClient();
    assertThat(kinClient.getAccountCount(), equalTo(3));
    kinClient.deleteAccount(2);
    kinClient.deleteAccount(1);
    assertThat(kinClient.getAccountCount(), equalTo(1));
    kinClient.addAccount();
    assertThat(kinClient.getAccountCount(), equalTo(2));
    kinClient.deleteAccount(1);
    kinClient.deleteAccount(0);
    assertThat(kinClient.getAccountCount(), equalTo(0));
}