Cyberduck Mountain Duck CLI

Changeset 41232


Ignore:
Timestamp:
Jun 6, 2017 10:00:12 AM (14 months ago)
Author:
dkocher
Message:

Add test.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/cryptomator/src/test/java/ch/cyberduck/core/cryptomator/impl/CryptoDirectoryProviderTest.java

    r40738 r41232  
    4545
    4646    @Test(expected = NotfoundException.class)
    47     public void testToEncryptedFile() throws Exception {
     47    public void testToEncryptedInvalidArgument() throws Exception {
    4848        final Path home = new Path("/vault", EnumSet.of(Path.Type.directory));
    4949        final CryptoVault vault = new CryptoVault(home, new DisabledPasswordStore());
    5050        final CryptoDirectoryProvider provider = new CryptoDirectoryProvider(home, vault);
    5151        provider.toEncrypted(new NullSession(new Host(new TestProtocol())), null, new Path("/vault/f", EnumSet.of(Path.Type.file)));
     52    }
     53
     54    @Test(expected = NotfoundException.class)
     55    public void testToEncryptedInvalidPath() throws Exception {
     56        final Path home = new Path("/vault", EnumSet.of(Path.Type.directory));
     57        final CryptoVault vault = new CryptoVault(home, new DisabledPasswordStore());
     58        final CryptoDirectoryProvider provider = new CryptoDirectoryProvider(home, vault);
     59        provider.toEncrypted(new NullSession(new Host(new TestProtocol())), null, new Path("/", EnumSet.of(Path.Type.directory)));
    5260    }
    5361
Note: See TracChangeset for help on using the changeset viewer.
swiss made software