### Question:
LogicalPath { public static LogicalPath getInstance(final Path path, final String module) { return new LogicalPath(module, path); } private  LogicalPath(final String module, final Path path); static LogicalPath getInstance(final Path path, final String module); static LogicalPath getInstance(final String modulePlusPath); int compareTo(final LogicalPath o); @Override boolean equals(final Object obj); String getModule(); String getName(); Path getPath(); String getPathRelativeToPom(final Pom pom); @Override int hashCode(); boolean isModuleRoot(); boolean isProjectRoot(); @Override final String toString(); static final String MODULE_PATH_SEPARATOR; static final String PATH_SEPARATOR; }### Answer:
@Test(expected = IllegalArgumentException.class) public void testGetInstanceFromBlankString() { LogicalPath.getInstance(" "); }
@Test public void testGetInstanceFromCombinedPathAndModuleName() { final LogicalPath instance = LogicalPath.getInstance(MODULE_PLUS_PATH); assertContextualPath(instance, MODULE_PLUS_PATH, MODULE_NAME); }
@Test(expected = IllegalArgumentException.class) public void testGetInstanceFromEmptyString() { LogicalPath.getInstance(""); }
@Test(expected = NullPointerException.class) public void testGetInstanceFromNullString() { LogicalPath.getInstance((String) null); }
@Test public void testGetInstanceFromPathNameOnly() { final LogicalPath instance = LogicalPath.getInstance(PATH.name()); assertContextualPath(instance, PATH.name(), ""); }