Browse Source

attempt to fix path issues on travis

pull/299/head
Scott Williams 9 years ago
parent
commit
e7d288b01d
  1. 2
      tests/ImageSharp.Tests/TestFile.cs
  2. 8
      tests/ImageSharp.Tests/TestUtilities/TestEnvironment.cs

2
tests/ImageSharp.Tests/TestFile.cs

@ -92,7 +92,7 @@ namespace SixLabors.ImageSharp.Tests
/// </returns> /// </returns>
public static string GetInputFileFullPath(string file) public static string GetInputFileFullPath(string file)
{ {
return Path.Combine(InputImagesDirectory, file); return Path.Combine(InputImagesDirectory, file).Replace('\\', Path.DirectorySeparatorChar);
} }
/// <summary> /// <summary>

8
tests/ImageSharp.Tests/TestUtilities/TestEnvironment.cs

@ -91,24 +91,24 @@ namespace SixLabors.ImageSharp.Tests
/// Gets the correct full path to the Input Images directory. /// Gets the correct full path to the Input Images directory.
/// </summary> /// </summary>
internal static string InputImagesDirectoryFullPath => internal static string InputImagesDirectoryFullPath =>
Path.Combine(SolutionDirectoryFullPath, InputImagesRelativePath); Path.Combine(SolutionDirectoryFullPath, InputImagesRelativePath).Replace('\\', Path.DirectorySeparatorChar);
/// <summary> /// <summary>
/// Gets the correct full path to the Actual Output directory. (To be written to by the test cases.) /// Gets the correct full path to the Actual Output directory. (To be written to by the test cases.)
/// </summary> /// </summary>
internal static string ActualOutputDirectoryFullPath => Path.Combine( internal static string ActualOutputDirectoryFullPath => Path.Combine(
SolutionDirectoryFullPath, SolutionDirectoryFullPath,
ActualOutputDirectoryRelativePath); ActualOutputDirectoryRelativePath).Replace('\\', Path.DirectorySeparatorChar);
/// <summary> /// <summary>
/// Gets the correct full path to the Expected Output directory. (To compare the test results to.) /// Gets the correct full path to the Expected Output directory. (To compare the test results to.)
/// </summary> /// </summary>
internal static string ReferenceOutputDirectoryFullPath => Path.Combine( internal static string ReferenceOutputDirectoryFullPath => Path.Combine(
SolutionDirectoryFullPath, SolutionDirectoryFullPath,
ReferenceOutputDirectoryRelativePath); ReferenceOutputDirectoryRelativePath).Replace('\\', Path.DirectorySeparatorChar);
internal static string GetReferenceOutputFileName(string actualOutputFileName) => internal static string GetReferenceOutputFileName(string actualOutputFileName) =>
actualOutputFileName.Replace("ActualOutput", @"External\ReferenceOutput"); actualOutputFileName.Replace("ActualOutput", @"External\ReferenceOutput").Replace('\\', Path.DirectorySeparatorChar);
internal static IImageDecoder GetReferenceDecoder(string filePath) internal static IImageDecoder GetReferenceDecoder(string filePath)
{ {

Loading…
Cancel
Save