@Test public void testWindowsHome() throws Exception { final LocalSession session = new LocalSession(new Host(new LocalProtocol(), new LocalProtocol().getDefaultHostname())); session.open(Proxy.DIRECT, new DisabledHostKeyCallback(), new DisabledLoginCallback()); session.login(Proxy.DIRECT, new DisabledLoginCallback(), new DisabledCancelCallback()); assertEquals("/C:/Users/Default", new LocalHomeFinderFeature(session).toPath("C:\\Users\\Default").getAbsolute()); session.close(); }
protected Path toPath(final String home) { return new Path(StringUtils.replace(home, "\\", "/"), EnumSet.of(Path.Type.directory)); }
LocalHomeFinderFeature extends DefaultHomeFinderService { protected Path toPath(final String home) { return new Path(StringUtils.replace(home, "\\", "/"), EnumSet.of(Path.Type.directory)); } }
LocalHomeFinderFeature extends DefaultHomeFinderService { protected Path toPath(final String home) { return new Path(StringUtils.replace(home, "\\", "/"), EnumSet.of(Path.Type.directory)); } LocalHomeFinderFeature(final LocalSession session); }
LocalHomeFinderFeature extends DefaultHomeFinderService { protected Path toPath(final String home) { return new Path(StringUtils.replace(home, "\\", "/"), EnumSet.of(Path.Type.directory)); } LocalHomeFinderFeature(final LocalSession session); @Override Path find(); }
LocalHomeFinderFeature extends DefaultHomeFinderService { protected Path toPath(final String home) { return new Path(StringUtils.replace(home, "\\", "/"), EnumSet.of(Path.Type.directory)); } LocalHomeFinderFeature(final LocalSession session); @Override Path find();  }