public void TestAbsoluteToRelativePath_SeparatePaths() { var assetsPath = "C:/Documents/Project/Assets/"; var scenePath = "C:/SomeOtherFolder/Scenes/LoadingScene.unity"; Assert.IsNull(DialogHelper.AbsoluteToRelativePath(scenePath, assetsPath)); }
public void TestAbsoluteToRelativePath_RedundantPaths() { var assetsPath = "C:/Documents/Project/Assets"; var scenePath = "C:/Documents/Project/Assets/C:/Documents/Project/Assets/LoadingScene.unity"; Assert.AreEqual("Assets/C:/Documents/Project/Assets/LoadingScene.unity", DialogHelper.AbsoluteToRelativePath(scenePath, assetsPath)); }
public void TestAbsoluteToRelativePath_EmptyPaths() { Assert.IsNull(DialogHelper.AbsoluteToRelativePath("", "")); }
public void TestAbsoluteToRelativePath_EqualPaths() { var assetsPath = "C:/Documents/Project/Assets/"; Assert.AreEqual("Assets/", DialogHelper.AbsoluteToRelativePath(assetsPath, assetsPath)); }