@Override
    public Path mkdir(final Path folder, final TransferStatus status) throws BackgroundException {
        final SMBSession.DiskShareWrapper share = session.openShare(folder);
        try {
            share.get().mkdir(new SMBPathContainerService(session).getKey(folder));
        }
        catch(SMBRuntimeException e) {
            throw new SMBExceptionMappingService().map("Cannot create folder {0}", e, folder);
        }
        finally {
            session.releaseShare(share);
        }
        return folder;
    }
@Test
    public void testMakeDirectory() throws Exception {
        final Path test = new SMBDirectoryFeature(session).mkdir(
                new Path(new DefaultHomeFinderService(session).find(), new AlphanumericRandomStringService().random(), EnumSet.of(Path.Type.directory)), new TransferStatus());
        assertTrue(new SMBFindFeature(session).find(test));
        assertThrows(ConflictException.class, () -> new SMBDirectoryFeature(session).mkdir(test, new TransferStatus()));
        new SMBDeleteFeature(session).delete(Collections.singletonList(test), new DisabledLoginCallback(), new Delete.DisabledCallback());
    }