Skip to content

Commit 559d67d

Browse files
committed
Fix test.
1 parent ecc318a commit 559d67d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

ssh/src/test/java/ch/cyberduck/core/sftp/auth/SFTPPublicKeyAuthenticationTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ public Credentials prompt(final Host bookmark, String username, String title, St
221221
}
222222
}
223223

224-
@Test(expected = LoginFailureException.class)
224+
@Test
225225
public void testUnknownFormat() throws Exception {
226226
final Local key = new Local(System.getProperty("java.io.tmpdir"), UUID.randomUUID().toString());
227227
try {
@@ -231,7 +231,7 @@ public void testUnknownFormat() throws Exception {
231231
session.disconnect();
232232
session.open(new DisabledProxyFinder(), new DisabledHostKeyCallback(), new DisabledLoginCallback(), new DisabledCancelCallback());
233233
session.getHost().getCredentials().setIdentity(key);
234-
assertTrue(new SFTPPublicKeyAuthentication(session.getClient()).authenticate(session.getHost(), new DisabledLoginCallback() {
234+
assertFalse(new SFTPPublicKeyAuthentication(session.getClient()).authenticate(session.getHost(), new DisabledLoginCallback() {
235235
@Override
236236
public Credentials prompt(final Host bookmark, String username, String title, String reason, LoginOptions options) throws LoginCanceledException {
237237
fail();

0 commit comments

Comments
 (0)