added test for path shortening; fixed short paths (thank you unit tests)