Browse Source

VaultTest refactor

feature-vault
fdai6352 3 years ago
parent
commit
b8ebd3b2f2
  1. 8
      src/test/java/VaultTest.java

8
src/test/java/VaultTest.java

@ -26,9 +26,6 @@ public class VaultTest {
vlt.inputS = System.in;
}
@Test
void configure() {vlt.configure();}
@Test
void addCredential() {vlt.addCredential();}
@ -44,7 +41,7 @@ public class VaultTest {
@Test
void openConfigureMenu() {
ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
vlt.inputS = getEmptyStringInputStream();
vlt.inputS = new ByteArrayInputStream("__\n".getBytes(StandardCharsets.UTF_8));
vlt.outputS = outputStream;
vlt.configure();
assertTrue(outputStream.toString().startsWith("Configure:"));
@ -71,6 +68,9 @@ public class VaultTest {
assertTrue(outputStream.toString().startsWith("Configure:"));
}
// @Test
// void
private ByteArrayInputStream getEmptyStringInputStream() {

Loading…
Cancel
Save