static Tests() { BuildServerDetector.Detected = false; DiffTools.AddTool( name: "MyTools", autoRefresh: true, isMdi: false, supportsText: true, requiresTarget: true, arguments: (path1, path2) => $"\"{path1}\" \"{path2}\"", exePath: diffToolPath, binaryExtensions: new[] { "knownBin" }); var binPath = AllFiles.Files["jpg"]; var newPath = Path.ChangeExtension(binPath.Path, "knownBin"); File.Copy(binPath.Path, newPath, true); AllFiles.UseFile(Category.Image, newPath); SharedVerifySettings.RegisterFileConverter <TypeToSplit>( "txt", (split, settings) => new ConversionResult( split.Info, new List <Stream> { new MemoryStream(FileHelpers.Utf8NoBOM.GetBytes(split.Property1)), new MemoryStream(FileHelpers.Utf8NoBOM.GetBytes(split.Property2)) })); DiffRunner.MaxInstancesToLaunch(int.MaxValue); }
static Tests() { BuildServerDetector.Detected = false; DiffRunner.Disabled = false; DiffTools.AddTool( name: "MyTools", autoRefresh: true, isMdi: false, supportsText: true, requiresTarget: true, arguments: (path1, path2) => $"\"{path1}\" \"{path2}\"", exePath: diffToolPath, binaryExtensions: new[] { "knownBin" }); var binPath = AllFiles.Files["jpg"]; var newPath = Path.ChangeExtension(binPath.Path, "knownBin"); File.Copy(binPath.Path, newPath, true); AllFiles.UseFile(Category.Image, newPath); VerifierSettings.RegisterFileConverter <TypeToSplit>( (split, _) => new ConversionResult( split.Info, new List <Target> { new("txt", split.Property1), new("txt", split.Property2) }));
public void UseFile() { var pathToFile = SourceFile; #region UseFile AllFiles.UseFile(Category.Document, pathToFile); Assert.Contains(pathToFile, AllFiles.DocumentPaths); #endregion }