mirror of
https://github.com/hierynomus/sshj.git
synced 2025-12-06 07:10:53 +03:00
Added assertions to testPromptFormat
This commit is contained in:
committed by
Jeroen van Erp
parent
aed3decf1d
commit
3729119e23
@@ -69,9 +69,12 @@ public class TestConsolePasswordFinder {
|
||||
|
||||
@Test
|
||||
public void testPromptFormat() {
|
||||
// expecting no Exceptions
|
||||
ConsolePasswordFinder.builder().setPromptFormat("");
|
||||
ConsolePasswordFinder.builder().setPromptFormat("%s");
|
||||
Assert.assertNotNull(
|
||||
"Empty format should create valid ConsolePasswordFinder",
|
||||
ConsolePasswordFinder.builder().setPromptFormat("").build());
|
||||
Assert.assertNotNull(
|
||||
"Single-string format should create valid ConsolePasswordFinder",
|
||||
ConsolePasswordFinder.builder().setPromptFormat("%s").build());
|
||||
}
|
||||
|
||||
@Test(expected = IllegalArgumentException.class)
|
||||
|
||||
Reference in New Issue
Block a user