From eb17a81b6374c340e8aedc8b1f456d43d13b947c Mon Sep 17 00:00:00 2001 From: Gaspar Nagy Date: Tue, 24 Nov 2009 14:10:15 +0100 Subject: [PATCH 1/7] =?UTF-8?q?=EF=BB=BFrefactor=20tools?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Generator/Properties/AssemblyInfo.cs | 36 + Generator/TechTalk.SpecFlow.Generator.csproj | 58 ++ .../BatchTestGeneration/BatchTestGenerator.cs | 79 ++ GeneratorTools/Generator.cs | 56 -- .../MsBuild/BatchTestGeneratorTask.cs | 16 + GeneratorTools/Program.cs | 157 +-- .../TechTalk.SpecFlow.GeneratorTools.csproj | 26 +- Parser/Configuration/MsBuildProjectReader.cs | 46 + Parser/Configuration/SpecFlowProject.cs | 12 + Parser/SpecFlowGenerator.cs | 139 ++- Parser/SpecFlowUnitTestConverter.cs | 16 +- Parser/TechTalk.SpecFlow.Parser.csproj | 1 + Reporting/NConsoler/NConsoler.cs | 925 ------------------ Reporting/TechTalk.SpecFlow.Reporting.csproj | 4 +- .../ConfigurationSectionHandler.cs | 25 + Runtime/ObjectContainer.cs | 23 +- TechTalk.SpecFlow.sln | 6 + Tests/ParserTests/SuccessfulGenerationTest.cs | 4 +- Tests/RuntimeTests/ExecutionTestBase.cs | 5 +- VsIntegration/SpecFlowSingleFileGenerator.cs | 10 +- .../NConsoler => lib/nconsoler}/NConsoler.cs | 0 21 files changed, 435 insertions(+), 1209 deletions(-) create mode 100644 Generator/Properties/AssemblyInfo.cs create mode 100644 Generator/TechTalk.SpecFlow.Generator.csproj create mode 100644 GeneratorTools/BatchTestGeneration/BatchTestGenerator.cs delete mode 100644 GeneratorTools/Generator.cs create mode 100644 GeneratorTools/MsBuild/BatchTestGeneratorTask.cs create mode 100644 Parser/Configuration/MsBuildProjectReader.cs delete mode 100644 Reporting/NConsoler/NConsoler.cs rename {GeneratorTools/NConsoler => lib/nconsoler}/NConsoler.cs (100%) diff --git a/Generator/Properties/AssemblyInfo.cs b/Generator/Properties/AssemblyInfo.cs new file mode 100644 index 000000000..11c3a4740 --- /dev/null +++ b/Generator/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("Generator")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("Generator")] +[assembly: AssemblyCopyright("Copyright © 2009")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("743e1609-8937-4775-9896-6e8757c6d98d")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/Generator/TechTalk.SpecFlow.Generator.csproj b/Generator/TechTalk.SpecFlow.Generator.csproj new file mode 100644 index 000000000..a26be8d32 --- /dev/null +++ b/Generator/TechTalk.SpecFlow.Generator.csproj @@ -0,0 +1,58 @@ + + + + Debug + AnyCPU + 9.0.30729 + 2.0 + {453D8014-B6CD-4E86-80A8-D59F59092334} + Library + Properties + TechTalk.SpecFlow.Generator + TechTalk.SpecFlow.Generator + v3.5 + 512 + + + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + 3.5 + + + 3.5 + + + 3.5 + + + + + + + + + + \ No newline at end of file diff --git a/GeneratorTools/BatchTestGeneration/BatchTestGenerator.cs b/GeneratorTools/BatchTestGeneration/BatchTestGenerator.cs new file mode 100644 index 000000000..563dab2c2 --- /dev/null +++ b/GeneratorTools/BatchTestGeneration/BatchTestGenerator.cs @@ -0,0 +1,79 @@ +using System; +using System.Diagnostics; +using System.IO; +using System.Linq; +using System.Text; +using TechTalk.SpecFlow.Parser; +using TechTalk.SpecFlow.Parser.Configuration; + +namespace TechTalk.SpecFlow.GeneratorTools.BatchTestGeneration +{ + public static class BatchTestGenerator + { + public static void ProcessProject(SpecFlowProject specFlowProject, bool forceGenerate, bool verbose) + { + if (verbose) + Console.WriteLine("Processing project: " + specFlowProject); + + SpecFlowGenerator generator = new SpecFlowGenerator(specFlowProject); + + foreach (var featureFile in specFlowProject.FeatureFiles) + { + string featureFileFullPath = featureFile.GetFullPath(specFlowProject); + + string codeFileFullPath = featureFileFullPath + ".cs"; + + bool needsProcessing = true; + + if (!forceGenerate && IsUpToDate(generator, featureFileFullPath, codeFileFullPath)) + { + needsProcessing = false; + } + + if (verbose || needsProcessing) + { + Console.WriteLine("Processing file: {0}", featureFileFullPath); + if (!needsProcessing) + Console.WriteLine(" up-to-date"); + } + + if (needsProcessing) + { + using (var writer = new StreamWriter(codeFileFullPath, false, Encoding.UTF8)) + { + generator.GenerateCSharpTestFile(featureFile, writer); + } + } + } + } + + private static bool IsUpToDate(SpecFlowGenerator generator, string featureFileFullPath, string codeFileFullPath) + { + // check existance of the target file + if (!File.Exists(codeFileFullPath)) + return false; + + // check modification time of the target file + try + { + var featureFileModificationTime = File.GetLastWriteTime(featureFileFullPath); + var codeFileModificationTime = File.GetLastWriteTime(codeFileFullPath); + + if (featureFileModificationTime > codeFileModificationTime) + return false; + } + catch (Exception ex) + { + Debug.WriteLine(ex); + return false; + } + + // check tools version + var codeFileVersion = generator.GetGeneratedFileSpecFlowVersion(codeFileFullPath); + if (codeFileVersion == null || codeFileVersion != generator.GetCurrentSpecFlowVersion()) + return false; + + return true; + } + } +} \ No newline at end of file diff --git a/GeneratorTools/Generator.cs b/GeneratorTools/Generator.cs deleted file mode 100644 index f1a027fd4..000000000 --- a/GeneratorTools/Generator.cs +++ /dev/null @@ -1,56 +0,0 @@ -using System; -using System.CodeDom; -using System.CodeDom.Compiler; -using System.IO; -using System.Text; -using Microsoft.CSharp; -using NConsoler; -using TechTalk.SpecFlow.Parser; -using TechTalk.SpecFlow.Parser.Configuration; -using TechTalk.SpecFlow.Reporting; - -namespace TechTalk.SpecFlow.GeneratorTools -{ - class Program - { - static void Main(string[] args) - { - Consolery.Run(typeof(Program), args); - return; - } - - [Action("Generate tests from all feature files")] - public static void Generate( - [Required] string projectFile - ) - { - SpecFlowProject specFlowProject = MsBuildProjectReader.LoadSpecFlowProjectFromMsBuild(projectFile); - - ProcessProject(specFlowProject); - } - - private static void ProcessProject(SpecFlowProject specFlowProject) - { - Console.WriteLine("Processing project: " + specFlowProject); - - foreach (var featureFile in specFlowProject.FeatureFiles) - { - string featureFileFullPath = featureFile.GetFullPath(specFlowProject); - - Console.WriteLine("Processing file: " + featureFileFullPath); - - SpecFlowGenerator generator = new SpecFlowGenerator(specFlowProject); - CodeCompileUnit compileUnit = generator.GenerateTestFileCode(featureFile); - - string codeFileFullPath = featureFileFullPath + ".cs"; - using (var writer = new StreamWriter(codeFileFullPath, false, Encoding.UTF8)) - { - CSharpCodeProvider codeProvider = new CSharpCodeProvider(); - CodeGeneratorOptions options = new CodeGeneratorOptions(); - options.BracingStyle = "C"; - codeProvider.GenerateCodeFromCompileUnit(compileUnit, writer, options); - } - } - } - } -} \ No newline at end of file diff --git a/GeneratorTools/MsBuild/BatchTestGeneratorTask.cs b/GeneratorTools/MsBuild/BatchTestGeneratorTask.cs new file mode 100644 index 000000000..9b805e523 --- /dev/null +++ b/GeneratorTools/MsBuild/BatchTestGeneratorTask.cs @@ -0,0 +1,16 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using Microsoft.Build.Utilities; + +namespace TechTalk.SpecFlow.Tools.MsBuild +{ + public class BatchTestGeneratorTask : Task + { + public override bool Execute() + { + throw new System.NotImplementedException(); + } + } +} \ No newline at end of file diff --git a/GeneratorTools/Program.cs b/GeneratorTools/Program.cs index 1cd34b66a..2714ba866 100644 --- a/GeneratorTools/Program.cs +++ b/GeneratorTools/Program.cs @@ -1,20 +1,8 @@ -using System; -using System.CodeDom; -using System.CodeDom.Compiler; -using System.Collections.Generic; -using System.Globalization; -using System.IO; -using System.Linq; -using System.Reflection; -using System.Text; -using Microsoft.CSharp; -using NConsoler; -using TechTalk.SpecFlow.Parser; +using NConsoler; +using TechTalk.SpecFlow.GeneratorTools.BatchTestGeneration; using TechTalk.SpecFlow.Parser.Configuration; -using TechTalk.SpecFlow.Parser.SyntaxElements; -using TechTalk.SpecFlow.Reporting; -namespace TechTalk.SpecFlow.Runner +namespace TechTalk.SpecFlow.Tools { class Program { @@ -24,141 +12,16 @@ static void Main(string[] args) return; } - [Action("Process all feature files")] - public static void All( - [Required] string projectFile + [Action("Generate tests from all feature files")] + public static void Generate( + [Required] string projectFile, + [Optional(false, "force", "f")] bool forceGeneration, + [Optional(false, "verbose", "v")] bool verboseOutput ) { SpecFlowProject specFlowProject = MsBuildProjectReader.LoadSpecFlowProjectFromMsBuild(projectFile); - ProcessProject(specFlowProject); - -// Console.ReadLine(); - } - - [Action("Run all feature files")] - public static void Run( - [Required] string projectFile - ) - { - SpecFlowProject specFlowProject = MsBuildProjectReader.LoadSpecFlowProjectFromMsBuild(projectFile); - - RunProject(specFlowProject); - - Console.ReadLine(); - } - - private static void RunProject(SpecFlowProject specFlowProject) - { - Console.WriteLine("Processing project: " + specFlowProject); -// -// AssemblyName name = AssemblyName.GetAssemblyName( -// @"C:\Users\jba\Dev\Projects\SpecFlow\Samples\BowlingKata\Bowling.Specflow\bin\Debug\Bowling.dll"); -// AppDomain.CurrentDomain.Load(name); - - ITestRunner testRunner = new TestRunner(); - - List bindingAssemblies = new List(); - - string projectAssemblyPath = specFlowProject.ProjectFolder + @"\bin\Debug\" + specFlowProject.AssemblyName + ".dll"; - Assembly projectAssembly = Assembly.LoadFrom(projectAssemblyPath); - bindingAssemblies.Add(projectAssembly); -// string projectAssemblyDir = specFlowProject.ProjectFolder + @"\bin\Debug\"; -// string[] assemblies = Directory.GetFiles(projectAssemblyDir, "*.dll"); -// foreach (string assembly in assemblies) -// { -// Assembly projectAssembly2 = Assembly.LoadFrom(assembly); -// AssemblyName name2 = AssemblyName.GetAssemblyName(assembly); -// AppDomain.CurrentDomain.Load(name2); -//// bindingAssemblies.Add(projectAssembly2); -// } - - testRunner.InitializeTestRunner(bindingAssemblies.ToArray()); - - - foreach (var featureFile in specFlowProject.FeatureFiles) - { - SpecFlowLangParser parser = new SpecFlowLangParser(specFlowProject.GeneratorConfiguration.FeatureLanguage); - Feature feature = parser.Parse(new StringReader(File.ReadAllText(featureFile.GetFullPath(specFlowProject))), featureFile.GetFullPath(specFlowProject)); - - TechTalk.SpecFlow.FeatureInfo featureInfo = new TechTalk.SpecFlow.FeatureInfo(new System.Globalization.CultureInfo("en"), "Score Calculation", "In order to know my performance\r\nAs a player\r\nI want the system to calculate my t" + -"otal score", ((string[])(null))); - testRunner.OnFeatureStart(featureInfo); - - foreach (Scenario scenario in feature.Scenarios) - { - TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Gutter game", ((string[])(null))); - testRunner.OnScenarioStart(scenarioInfo); - - foreach (ScenarioStep scenarioStep in scenario.Steps) - { - TechTalk.SpecFlow.Table table1 = null; - if (scenarioStep.TableArg != null) - { - Console.WriteLine("Table: " + scenarioStep.TableArg); - - table1 = new TechTalk.SpecFlow.Table(new string[] { "Pins" }); - foreach (Row row in scenarioStep.TableArg.Body) - { - string[] cells = new string[row.Cells.Count()]; - for (int i = 0; i < row.Cells.Count(); i++ ) - { - cells[i] = row.Cells[i].Value; - } - table1.AddRow(cells); - } - - } - - if (scenarioStep is Given) - { - Console.WriteLine("Given: " + scenarioStep.Text); - testRunner.Given(scenarioStep.Text); - } - else if (scenarioStep is When) - { - Console.WriteLine("When: " + scenarioStep.Text); - testRunner.When(scenarioStep.Text, null, table1); - } - else if (scenarioStep is Then) - { - Console.WriteLine("Then: " + scenarioStep.Text); - testRunner.Then(scenarioStep.Text); - } - else if (scenarioStep is And) - { - Console.WriteLine("And: " + scenarioStep.Text); - testRunner.And(scenarioStep.Text); - } - } - testRunner.OnScenarioEnd(); - } - testRunner.OnFeatureEnd(); - } - } - - private static void ProcessProject(SpecFlowProject specFlowProject) - { - Console.WriteLine("Processing project: " + specFlowProject); - - foreach (var featureFile in specFlowProject.FeatureFiles) - { - string featureFileFullPath = featureFile.GetFullPath(specFlowProject); - - Console.WriteLine("Processing file: " + featureFileFullPath); - - SpecFlowGenerator generator = new SpecFlowGenerator(specFlowProject); - CodeCompileUnit compileUnit = generator.GenerateTestFileCode(featureFile); - - string codeFileFullPath = featureFileFullPath + ".cs"; - using (var writer = new StreamWriter(codeFileFullPath, false, Encoding.UTF8)) - { - CSharpCodeProvider codeProvider = new CSharpCodeProvider(); - CodeGeneratorOptions options = new CodeGeneratorOptions(); - options.BracingStyle = "C"; - codeProvider.GenerateCodeFromCompileUnit(compileUnit, writer, options); - } - } + BatchTestGenerator.ProcessProject(specFlowProject, false, false); } } -} +} \ No newline at end of file diff --git a/GeneratorTools/TechTalk.SpecFlow.GeneratorTools.csproj b/GeneratorTools/TechTalk.SpecFlow.GeneratorTools.csproj index d53510c6f..6a46c9ff5 100644 --- a/GeneratorTools/TechTalk.SpecFlow.GeneratorTools.csproj +++ b/GeneratorTools/TechTalk.SpecFlow.GeneratorTools.csproj @@ -8,8 +8,8 @@ {87BE7FE6-C3DE-4409-ABF6-FA5B60AF3DE1} Exe Properties - TechTalk.SpecFlow.GeneratorTools - TechTalk.SpecFlow.Generator + TechTalk.SpecFlow.Tools + specflow v3.5 512 @@ -33,9 +33,9 @@ 4 - - False - ..\lib\nunit\nunit.framework.dll + + + 3.5 @@ -51,8 +51,12 @@ - - + + NConsoler\NConsoler.cs + + + + @@ -60,14 +64,6 @@ {7CCEF6D6-FC17-422E-9BED-EDD752B6496F} TechTalk.SpecFlow.Parser - - {FC43509F-E7D3-40C4-B4C3-1E6C9D5530A4} - TechTalk.SpecFlow.Reporting - - - {413EE28C-4F89-4C6F-BA1E-2CDEE4CD43B4} - TechTalk.SpecFlow - + + + specflow.exe + + + + + + + + + + false + + false + false + false + + + + false + true + + + + + <__FeatureFiles Include="@(Content)" Condition=" '%(Content.Extension)' == '.feature' " /> + + + + + + + + + + + + + + + + diff --git a/Tools/TechTalk.SpecFlow.tasks b/Tools/TechTalk.SpecFlow.tasks new file mode 100644 index 000000000..35b939eea --- /dev/null +++ b/Tools/TechTalk.SpecFlow.tasks @@ -0,0 +1,14 @@ + + + + specflow.exe + + + + + + + + From 2bef63817316d460136549f190e7c132408c54ab Mon Sep 17 00:00:00 2001 From: Gaspar Nagy Date: Wed, 25 Nov 2009 10:59:30 +0100 Subject: [PATCH 5/7] =?UTF-8?q?=EF=BB=BFfix=20msbuild=20task?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Generator/BatchTestGenerator.cs | 79 ------------------------- Tools/MsBuild/BatchTestGeneratorTask.cs | 16 ----- Tools/MsBuild/GeneratorTask.cs | 3 +- Tools/MsBuild/GeneratorTaskBase.cs | 75 +++++++++++++++++++---- Tools/MsBuild/TaskBase.cs | 13 +++- Tools/MsBuild/TechTalk.SpecFlow.targets | 58 ++++++++++++++++++ Tools/MsBuild/TechTalk.SpecFlow.tasks | 17 ++++++ Tools/Program.cs | 14 ++++- Tools/TechTalk.SpecFlow.Tools.csproj | 13 +++- Tools/TechTalk.SpecFlow.targets | 65 -------------------- Tools/TechTalk.SpecFlow.tasks | 14 ----- 11 files changed, 176 insertions(+), 191 deletions(-) delete mode 100644 Generator/BatchTestGenerator.cs delete mode 100644 Tools/MsBuild/BatchTestGeneratorTask.cs create mode 100644 Tools/MsBuild/TechTalk.SpecFlow.targets create mode 100644 Tools/MsBuild/TechTalk.SpecFlow.tasks delete mode 100644 Tools/TechTalk.SpecFlow.targets delete mode 100644 Tools/TechTalk.SpecFlow.tasks diff --git a/Generator/BatchTestGenerator.cs b/Generator/BatchTestGenerator.cs deleted file mode 100644 index 1d76135cd..000000000 --- a/Generator/BatchTestGenerator.cs +++ /dev/null @@ -1,79 +0,0 @@ -using System; -using System.Diagnostics; -using System.IO; -using System.Linq; -using System.Text; -using TechTalk.SpecFlow.Generator; -using TechTalk.SpecFlow.Generator.Configuration; - -namespace TechTalk.SpecFlow.GeneratorTools.BatchTestGeneration -{ - public static class BatchTestGenerator - { - public static void ProcessProject(SpecFlowProject specFlowProject, bool forceGenerate, bool verbose) - { - if (verbose) - Console.WriteLine("Processing project: " + specFlowProject); - - SpecFlowGenerator generator = new SpecFlowGenerator(specFlowProject); - - foreach (var featureFile in specFlowProject.FeatureFiles) - { - string featureFileFullPath = featureFile.GetFullPath(specFlowProject); - - string codeFileFullPath = featureFileFullPath + ".cs"; - - bool needsProcessing = true; - - if (!forceGenerate && IsUpToDate(generator, featureFileFullPath, codeFileFullPath)) - { - needsProcessing = false; - } - - if (verbose || needsProcessing) - { - Console.WriteLine("Processing file: {0}", featureFileFullPath); - if (!needsProcessing) - Console.WriteLine(" up-to-date"); - } - - if (needsProcessing) - { - using (var writer = new StreamWriter(codeFileFullPath, false, Encoding.UTF8)) - { - generator.GenerateCSharpTestFile(featureFile, writer); - } - } - } - } - - private static bool IsUpToDate(SpecFlowGenerator generator, string featureFileFullPath, string codeFileFullPath) - { - // check existance of the target file - if (!File.Exists(codeFileFullPath)) - return false; - - // check modification time of the target file - try - { - var featureFileModificationTime = File.GetLastWriteTime(featureFileFullPath); - var codeFileModificationTime = File.GetLastWriteTime(codeFileFullPath); - - if (featureFileModificationTime > codeFileModificationTime) - return false; - } - catch (Exception ex) - { - Debug.WriteLine(ex); - return false; - } - - // check tools version - var codeFileVersion = generator.GetGeneratedFileSpecFlowVersion(codeFileFullPath); - if (codeFileVersion == null || codeFileVersion != generator.GetCurrentSpecFlowVersion()) - return false; - - return true; - } - } -} \ No newline at end of file diff --git a/Tools/MsBuild/BatchTestGeneratorTask.cs b/Tools/MsBuild/BatchTestGeneratorTask.cs deleted file mode 100644 index 9b805e523..000000000 --- a/Tools/MsBuild/BatchTestGeneratorTask.cs +++ /dev/null @@ -1,16 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using Microsoft.Build.Utilities; - -namespace TechTalk.SpecFlow.Tools.MsBuild -{ - public class BatchTestGeneratorTask : Task - { - public override bool Execute() - { - throw new System.NotImplementedException(); - } - } -} \ No newline at end of file diff --git a/Tools/MsBuild/GeneratorTask.cs b/Tools/MsBuild/GeneratorTask.cs index b85e23374..e55e8077e 100644 --- a/Tools/MsBuild/GeneratorTask.cs +++ b/Tools/MsBuild/GeneratorTask.cs @@ -58,7 +58,8 @@ protected override void DoExecute() { SpecFlowProject specFlowProject = MsBuildProjectReader.LoadSpecFlowProjectFromMsBuild(ProjectPath); - BatchGenerator batchGenerator = new MsBuildBatchGenerator(GetMessageWriter(), VerboseOutput, this); + BatchGenerator batchGenerator = new MsBuildBatchGenerator( + GetMessageWriter(MessageImportance.High), VerboseOutput, this); batchGenerator.ProcessProject(specFlowProject, ForceGeneration); } } diff --git a/Tools/MsBuild/GeneratorTaskBase.cs b/Tools/MsBuild/GeneratorTaskBase.cs index 4895ca679..7e78dea40 100644 --- a/Tools/MsBuild/GeneratorTaskBase.cs +++ b/Tools/MsBuild/GeneratorTaskBase.cs @@ -10,6 +10,7 @@ public abstract class GeneratorTaskBase : TaskBase { public bool BuildServerMode { get; set; } public bool OverwriteReadOnlyFiles { get; set; } + public bool OnlyUpdateIfChanged { get; set; } public class OutputFile { @@ -31,7 +32,7 @@ public virtual void Done(CompilerErrorCollection result) } } - public class VerifyDifferenceOutputFile : OutputFile + public abstract class TempOutputFile : OutputFile { public string TempFilePath { get; private set; } @@ -40,23 +41,51 @@ public override string FilePathForWriting get { return TempFilePath; } } - public VerifyDifferenceOutputFile(string filePath) : base(filePath) + protected TempOutputFile(string filePath) + : base(filePath) { TempFilePath = Path.Combine(Path.GetTempPath(), "tmp" + Path.GetFileName(filePath)); } public override void Done(CompilerErrorCollection result) { - Compare(TempFilePath, FilePath, result); + SafeDeleteFile(TempFilePath); + } + } + + public class VerifyDifferenceOutputFile : TempOutputFile + { + public VerifyDifferenceOutputFile(string filePath) : base(filePath) + { } - private void Compare(string path1, string path2, CompilerErrorCollection result) + public override void Done(CompilerErrorCollection result) { - if (FileCompare(path1, path2)) - return; + if (!FileCompare(TempFilePath, FilePath)) + { + string message = String.Format("Error during file generation. The target file '{0}' is read-only, but different from the transformation result. This problem can be a sign of an inconsistent source code package. Compile and check-in the current version of the file from the development environment or remove the read-only flag from the generation result. To compile a solution that contains messaging project on a build server, you can also exclude the messaging project from the build-server solution or set the msbuild project parameter to 'true' in the messaging project file.", + Path.GetFullPath(FilePath)); + result.Add(new CompilerError(String.Empty, 0, 0, null, message)); + } - string message = String.Format("Error during file generation. The target file '{0}' is read-only, but different from the transformation result. This problem can be a sign of an inconsistent source code package. Compile and check-in the current version of the file from the development environment or remove the read-only flag from the generation result. To compile a solution that contains messaging project on a build server, you can also exclude the messaging project from the build-server solution or set the msbuild project parameter to 'true' in the messaging project file.", Path.GetFullPath(path2)); - result.Add(new CompilerError(String.Empty, 0, 0, null, message)); + base.Done(result); + } + } + + public class UpdateIfChangedOutputFile : TempOutputFile + { + public UpdateIfChangedOutputFile(string filePath) : base(filePath) + { + } + + public override void Done(CompilerErrorCollection result) + { + if (!FileCompare(TempFilePath, FilePath)) + { + ReplaceFile(TempFilePath, FilePath); + } + + base.Done(result); } } @@ -71,6 +100,9 @@ public OutputFile PrepareOutputFile(string outputFilePath) if (isReadOnly && BuildServerMode) return new VerifyDifferenceOutputFile(outputFilePath); + if (OnlyUpdateIfChanged) + return new UpdateIfChangedOutputFile(outputFilePath); + return new OutputFile(outputFilePath); } @@ -119,7 +151,7 @@ private static bool FileCompare(string filePath1, string filePath2) return ((file1byte - file2byte) == 0); } - private bool IsReadOnly(string path) + private static bool IsReadOnly(string path) { try { @@ -138,11 +170,34 @@ private bool IsReadOnly(string path) } } - private void RemoveReadOnly(string path) + private static void RemoveReadOnly(string path) { FileInfo fileInfo = new FileInfo(path); if (fileInfo.Exists && fileInfo.IsReadOnly) fileInfo.IsReadOnly = false; } + + private static void SafeDeleteFile(string path) + { + try + { + if (IsReadOnly(path)) + RemoveReadOnly(path); + File.Delete(path); + + } + catch (Exception ex) + { + Debug.WriteLine(ex, "SaveDeleteFile"); + } + } + + private static void ReplaceFile(string sourcePath, string targetPath) + { + if (File.Exists(targetPath)) + SafeDeleteFile(targetPath); + + File.Move(sourcePath, targetPath); + } } } \ No newline at end of file diff --git a/Tools/MsBuild/TaskBase.cs b/Tools/MsBuild/TaskBase.cs index 2486b5995..70b0b2352 100644 --- a/Tools/MsBuild/TaskBase.cs +++ b/Tools/MsBuild/TaskBase.cs @@ -80,13 +80,19 @@ protected void OutputInformation(MessageImportance importance, string message, p private class MessageTextWriter : TextWriter { private TaskBase task; - MessageImportance importance = MessageImportance.Normal; + private MessageImportance importance = MessageImportance.Normal; public MessageTextWriter(TaskBase task) { this.task = task; } + public MessageTextWriter(TaskBase task, MessageImportance importance) + { + this.task = task; + this.importance = importance; + } + public override Encoding Encoding { get { return Encoding.Unicode; } @@ -113,6 +119,11 @@ protected TextWriter GetMessageWriter() return new MessageTextWriter(this); } + protected TextWriter GetMessageWriter(MessageImportance importance) + { + return new MessageTextWriter(this, importance); + } + protected abstract void DoExecute(); } } \ No newline at end of file diff --git a/Tools/MsBuild/TechTalk.SpecFlow.targets b/Tools/MsBuild/TechTalk.SpecFlow.targets new file mode 100644 index 000000000..6f19eebe0 --- /dev/null +++ b/Tools/MsBuild/TechTalk.SpecFlow.targets @@ -0,0 +1,58 @@ + + + + + + + + false + + + + false + + false + false + false + + + + false + true + + + + + UpdateFeatureFilesInProject; + $(BuildDependsOn) + + + SwitchToForceGenerate; + $(RebuildDependsOn) + + + + + + true + true + + + + + + + + + diff --git a/Tools/MsBuild/TechTalk.SpecFlow.tasks b/Tools/MsBuild/TechTalk.SpecFlow.tasks new file mode 100644 index 000000000..0e74b9cbf --- /dev/null +++ b/Tools/MsBuild/TechTalk.SpecFlow.tasks @@ -0,0 +1,17 @@ + + + + specflow.exe + + + + + <__SpecFlowTasksFullPath>$(SpecFlowTasksPath) + + <__SpecFlowTasksFullPath Condition="Exists('$(MSBuildProjectDirectory)\$(SpecFlowTasksPath)')" + >$(MSBuildProjectDirectory)\$(SpecFlowTasksPath) + + + + + diff --git a/Tools/Program.cs b/Tools/Program.cs index 9bb6a2040..82ac5ba3c 100644 --- a/Tools/Program.cs +++ b/Tools/Program.cs @@ -1,6 +1,7 @@ -using NConsoler; +using System; +using NConsoler; +using TechTalk.SpecFlow.Generator; using TechTalk.SpecFlow.Generator.Configuration; -using TechTalk.SpecFlow.GeneratorTools.BatchTestGeneration; namespace TechTalk.SpecFlow.Tools { @@ -21,7 +22,14 @@ public static void Generate( { SpecFlowProject specFlowProject = MsBuildProjectReader.LoadSpecFlowProjectFromMsBuild(projectFile); - BatchTestGenerator.ProcessProject(specFlowProject, false, false); + BatchGenerator batchGenerator = new BatchGenerator(Console.Out, verboseOutput); + batchGenerator.ProcessProject(specFlowProject, forceGeneration); + } + + [Action] + public static void ToBeDefinedAction() + { + } } } \ No newline at end of file diff --git a/Tools/TechTalk.SpecFlow.Tools.csproj b/Tools/TechTalk.SpecFlow.Tools.csproj index ad59bdbb5..10de94e81 100644 --- a/Tools/TechTalk.SpecFlow.Tools.csproj +++ b/Tools/TechTalk.SpecFlow.Tools.csproj @@ -54,8 +54,9 @@ NConsoler\NConsoler.cs - - + + + @@ -69,6 +70,14 @@ TechTalk.SpecFlow.Parser + + + PreserveNewest + + + PreserveNewest + + - - - specflow.exe - - - - - - - - - - false - - false - false - false - - - - false - true - - - - - <__FeatureFiles Include="@(Content)" Condition=" '%(Content.Extension)' == '.feature' " /> - - - - - - - - - - - - - - - - diff --git a/Tools/TechTalk.SpecFlow.tasks b/Tools/TechTalk.SpecFlow.tasks deleted file mode 100644 index 35b939eea..000000000 --- a/Tools/TechTalk.SpecFlow.tasks +++ /dev/null @@ -1,14 +0,0 @@ - - - - specflow.exe - - - - - - - - From 13da34f0767a41a732cdf964c8c6f73732ba6722 Mon Sep 17 00:00:00 2001 From: Gaspar Nagy Date: Wed, 25 Nov 2009 11:16:48 +0100 Subject: [PATCH 6/7] =?UTF-8?q?=EF=BB=BFmerge=20reporting=20to=20specflow.?= =?UTF-8?q?exe,=20and=20small=20fixes?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../NUnitExecutionReportGenerator.cs | 11 +++++- Reporting/Program.cs | 26 +++---------- .../StepDefinitionReportGenerator.cs | 14 ++++++- Reporting/TechTalk.SpecFlow.Reporting.csproj | 7 ++-- Tools/Program.cs | 39 ++++++++++++++++--- Tools/TechTalk.SpecFlow.Tools.csproj | 4 ++ lib/nconsoler/NConsoler.cs | 2 +- 7 files changed, 70 insertions(+), 33 deletions(-) diff --git a/Reporting/NUnitExecutionReport/NUnitExecutionReportGenerator.cs b/Reporting/NUnitExecutionReport/NUnitExecutionReportGenerator.cs index 1d93ea452..79038052e 100644 --- a/Reporting/NUnitExecutionReport/NUnitExecutionReportGenerator.cs +++ b/Reporting/NUnitExecutionReport/NUnitExecutionReportGenerator.cs @@ -11,13 +11,20 @@ namespace TechTalk.SpecFlow.Reporting.NUnitExecutionReport { - internal class NUnitExecutionReportGenerator + public class NUnitExecutionReportGenerator { private ReportElements.NUnitExecutionReport report; - private SpecFlowProject specFlowProject; + private readonly SpecFlowProject specFlowProject; private readonly string xmlTestResultPath; private readonly string labeledTestOutputPath; + public NUnitExecutionReportGenerator(string projectFile, string xmlTestResultPath, string labeledTestOutputPath) + { + this.xmlTestResultPath = xmlTestResultPath; + this.specFlowProject = MsBuildProjectReader.LoadSpecFlowProjectFromMsBuild(projectFile); + this.labeledTestOutputPath = labeledTestOutputPath; + } + public NUnitExecutionReportGenerator(SpecFlowProject specFlowProject, string xmlTestResultPath, string labeledTestOutputPath) { this.xmlTestResultPath = xmlTestResultPath; diff --git a/Reporting/Program.cs b/Reporting/Program.cs index ef1e23c59..bdb466df6 100644 --- a/Reporting/Program.cs +++ b/Reporting/Program.cs @@ -1,4 +1,4 @@ -using System; +/*using System; using System.Collections.Generic; using System.IO; using NConsoler; @@ -24,19 +24,9 @@ public static void StepDefinitionReport( [Optional("StepDefinitionReport.html", "out")] string outputFile ) { - SpecFlowProject specFlowProject = MsBuildProjectReader.LoadSpecFlowProjectFromMsBuild(projectFile); - - List parsedFeatures = ParserHelper.GetParsedFeatures(specFlowProject); - - var basePath = Path.Combine(specFlowProject.ProjectFolder, binFolder); - List bindings = BindingCollector.CollectBindings(specFlowProject, basePath); - - StepDefinitionReportGenerator generator = new StepDefinitionReportGenerator(specFlowProject, bindings, parsedFeatures, - true); + StepDefinitionReportGenerator generator = new StepDefinitionReportGenerator(projectFile, binFolder, true); generator.GenerateReport(); - - string outputFilePath = Path.GetFullPath(outputFile); - generator.TransformReport(outputFilePath); + generator.TransformReport(Path.GetFullPath(outputFile)); } [Action] @@ -47,16 +37,12 @@ public static void NUnitExecutionReport( [Optional("TestResult.html", "out")] string outputFile ) { - SpecFlowProject specFlowProject = MsBuildProjectReader.LoadSpecFlowProjectFromMsBuild(projectFile); - NUnitExecutionReportGenerator generator = new NUnitExecutionReportGenerator( - specFlowProject, + projectFile, Path.GetFullPath(xmlTestResult), Path.GetFullPath(labeledTestOutput)); generator.GenerateReport(); - - string outputFilePath = Path.GetFullPath(outputFile); - generator.TransformReport(outputFilePath); + generator.TransformReport(Path.GetFullPath(outputFile)); } } -} \ No newline at end of file +}*/ \ No newline at end of file diff --git a/Reporting/StepDefinitionReport/StepDefinitionReportGenerator.cs b/Reporting/StepDefinitionReport/StepDefinitionReportGenerator.cs index 6fda176d7..c4718e521 100644 --- a/Reporting/StepDefinitionReport/StepDefinitionReportGenerator.cs +++ b/Reporting/StepDefinitionReport/StepDefinitionReportGenerator.cs @@ -15,7 +15,7 @@ namespace TechTalk.SpecFlow.Reporting.StepDefinitionReport { - internal class StepDefinitionReportGenerator + public class StepDefinitionReportGenerator { private readonly SpecFlowProject specFlowProject; private readonly List bindings; @@ -27,6 +27,18 @@ internal class StepDefinitionReportGenerator private Dictionary bindingByStepDef; private readonly List stepDefsWithNoBinding = new List(); + public StepDefinitionReportGenerator(string projectFile, string binFolder, bool showBindingsWithoutInsance) + { + specFlowProject = MsBuildProjectReader.LoadSpecFlowProjectFromMsBuild(projectFile); + + parsedFeatures = ParserHelper.GetParsedFeatures(specFlowProject); + + var basePath = Path.Combine(specFlowProject.ProjectFolder, binFolder); + bindings = BindingCollector.CollectBindings(specFlowProject, basePath); + + this.showBindingsWithoutInsance = showBindingsWithoutInsance; + } + public StepDefinitionReportGenerator(SpecFlowProject specFlowProject, List bindings, List parsedFeatures, bool showBindingsWithoutInsance) { this.specFlowProject = specFlowProject; diff --git a/Reporting/TechTalk.SpecFlow.Reporting.csproj b/Reporting/TechTalk.SpecFlow.Reporting.csproj index 83a26445f..2ece5eeaa 100644 --- a/Reporting/TechTalk.SpecFlow.Reporting.csproj +++ b/Reporting/TechTalk.SpecFlow.Reporting.csproj @@ -6,7 +6,7 @@ 9.0.30729 2.0 {FC43509F-E7D3-40C4-B4C3-1E6C9D5530A4} - Exe + Library Properties TechTalk.SpecFlow.Reporting TechTalk.SpecFlow.Reporting @@ -22,6 +22,8 @@ true ..\specflow.snk + + true @@ -56,9 +58,6 @@ - - NConsoler\NConsoler.cs - VersionInfo.cs diff --git a/Tools/Program.cs b/Tools/Program.cs index 82ac5ba3c..f7f98fe0d 100644 --- a/Tools/Program.cs +++ b/Tools/Program.cs @@ -1,7 +1,10 @@ using System; +using System.IO; using NConsoler; using TechTalk.SpecFlow.Generator; using TechTalk.SpecFlow.Generator.Configuration; +using TechTalk.SpecFlow.Reporting.NUnitExecutionReport; +using TechTalk.SpecFlow.Reporting.StepDefinitionReport; namespace TechTalk.SpecFlow.Tools { @@ -13,8 +16,8 @@ static void Main(string[] args) return; } - [Action("Generate tests from all feature files")] - public static void Generate( + [Action("Generate tests from all feature files in a project")] + public static void GenerateAll( [Required] string projectFile, [Optional(false, "force", "f")] bool forceGeneration, [Optional(false, "verbose", "v")] bool verboseOutput @@ -26,10 +29,36 @@ public static void Generate( batchGenerator.ProcessProject(specFlowProject, forceGeneration); } - [Action] - public static void ToBeDefinedAction() + #region Reports + + [Action("Generates a report about usage and binding of steps")] + public static void StepDefinitionReport( + [Required] string projectFile, + [Optional("bin\\Debug")] string binFolder, + [Optional("StepDefinitionReport.html", "out")] string outputFile + ) { - + StepDefinitionReportGenerator generator = new StepDefinitionReportGenerator(projectFile, binFolder, true); + generator.GenerateReport(); + generator.TransformReport(Path.GetFullPath(outputFile)); } + + [Action("Formats an NUnit execution report to SpecFlow style")] + public static void NUnitExecutionReport( + [Required] string projectFile, + [Optional("TestResult.xml")] string xmlTestResult, + [Optional("TestResult.txt", "testOutput")] string labeledTestOutput, + [Optional("TestResult.html", "out")] string outputFile + ) + { + NUnitExecutionReportGenerator generator = new NUnitExecutionReportGenerator( + projectFile, + Path.GetFullPath(xmlTestResult), + Path.GetFullPath(labeledTestOutput)); + generator.GenerateReport(); + generator.TransformReport(Path.GetFullPath(outputFile)); + } + + #endregion } } \ No newline at end of file diff --git a/Tools/TechTalk.SpecFlow.Tools.csproj b/Tools/TechTalk.SpecFlow.Tools.csproj index 10de94e81..308579ce3 100644 --- a/Tools/TechTalk.SpecFlow.Tools.csproj +++ b/Tools/TechTalk.SpecFlow.Tools.csproj @@ -69,6 +69,10 @@ {7CCEF6D6-FC17-422E-9BED-EDD752B6496F} TechTalk.SpecFlow.Parser + + {FC43509F-E7D3-40C4-B4C3-1E6C9D5530A4} + TechTalk.SpecFlow.Reporting + diff --git a/lib/nconsoler/NConsoler.cs b/lib/nconsoler/NConsoler.cs index 375a5b581..591e37caa 100644 --- a/lib/nconsoler/NConsoler.cs +++ b/lib/nconsoler/NConsoler.cs @@ -507,7 +507,7 @@ private void PrintGeneralMulticommandUsage() _messenger.Write("Available subcommands:"); foreach (MethodInfo method in _actionMethods) { - _messenger.Write(method.Name.ToLower() + " " + GetMethodDescription(method)); + _messenger.Write(method.Name.ToLower() + " - " + GetMethodDescription(method)); } } From 30d26b465666b1a77d34820864acb16c36abd37c Mon Sep 17 00:00:00 2001 From: Gaspar Nagy Date: Wed, 25 Nov 2009 11:20:02 +0100 Subject: [PATCH 7/7] =?UTF-8?q?=EF=BB=BFfix=20installer=20+=20changelog?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Installer/SpecFlowSetup/SpecFlowSetup.vdproj | 253 ++++++++++++++++--- changelog.txt | 1 + 2 files changed, 225 insertions(+), 29 deletions(-) diff --git a/Installer/SpecFlowSetup/SpecFlowSetup.vdproj b/Installer/SpecFlowSetup/SpecFlowSetup.vdproj index f5f868f97..4c32ab2c6 100644 --- a/Installer/SpecFlowSetup/SpecFlowSetup.vdproj +++ b/Installer/SpecFlowSetup/SpecFlowSetup.vdproj @@ -45,8 +45,32 @@ } "Entry" { + "MsmKey" = "8:_109CA2795B9A7ADE61C883D41F3F86F5" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { "MsmKey" = "8:_12B423DBA56C8DC0E3B05977AFDCC8BB" - "OwnerKey" = "8:_F568BBC0422746FA9ADF497EFE4B6809" + "OwnerKey" = "8:_8B2D5366F6C941138FF83318D8C65C46" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_12B423DBA56C8DC0E3B05977AFDCC8BB" + "OwnerKey" = "8:_6E1CCF469FF44C51440438B84FAA9363" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_12B423DBA56C8DC0E3B05977AFDCC8BB" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_12B423DBA56C8DC0E3B05977AFDCC8BB" + "OwnerKey" = "8:_8B7827FFE66F143641790B9E6A834514" "MsmSig" = "8:_UNDEFINED" } "Entry" @@ -94,13 +118,25 @@ "Entry" { "MsmKey" = "8:_277A812A65804F067023A54D435F95E9" - "OwnerKey" = "8:_8B2D5366F6C941138FF83318D8C65C46" + "OwnerKey" = "8:_8B7827FFE66F143641790B9E6A834514" "MsmSig" = "8:_UNDEFINED" } "Entry" { "MsmKey" = "8:_277A812A65804F067023A54D435F95E9" - "OwnerKey" = "8:_F568BBC0422746FA9ADF497EFE4B6809" + "OwnerKey" = "8:_6E1CCF469FF44C51440438B84FAA9363" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_277A812A65804F067023A54D435F95E9" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_277A812A65804F067023A54D435F95E9" + "OwnerKey" = "8:_8B2D5366F6C941138FF83318D8C65C46" "MsmSig" = "8:_UNDEFINED" } "Entry" @@ -196,19 +232,19 @@ "Entry" { "MsmKey" = "8:_64C0AC2C36F206D7B415B1588A67AB7D" - "OwnerKey" = "8:_8B2D5366F6C941138FF83318D8C65C46" + "OwnerKey" = "8:_277A812A65804F067023A54D435F95E9" "MsmSig" = "8:_UNDEFINED" } "Entry" { "MsmKey" = "8:_64C0AC2C36F206D7B415B1588A67AB7D" - "OwnerKey" = "8:_F568BBC0422746FA9ADF497EFE4B6809" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" "MsmSig" = "8:_UNDEFINED" } "Entry" { "MsmKey" = "8:_64C0AC2C36F206D7B415B1588A67AB7D" - "OwnerKey" = "8:_277A812A65804F067023A54D435F95E9" + "OwnerKey" = "8:_8B2D5366F6C941138FF83318D8C65C46" "MsmSig" = "8:_UNDEFINED" } "Entry" @@ -249,12 +285,36 @@ } "Entry" { + "MsmKey" = "8:_6E1CCF469FF44C51440438B84FAA9363" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { "MsmKey" = "8:_72BA062375FF32683B46885AB8FB9F3C" "OwnerKey" = "8:_12B423DBA56C8DC0E3B05977AFDCC8BB" "MsmSig" = "8:_UNDEFINED" } "Entry" { + "MsmKey" = "8:_72BA062375FF32683B46885AB8FB9F3C" + "OwnerKey" = "8:_109CA2795B9A7ADE61C883D41F3F86F5" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_72BA062375FF32683B46885AB8FB9F3C" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_75A70548B8444C668B2D0462EC9CC366" + "OwnerKey" = "8:_UNDEFINED" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { "MsmKey" = "8:_76A50A8C2366870C6FF9029C08057BC1" "OwnerKey" = "8:_CDB5EF528F7640FEF9EE58B3A2D014B2" "MsmSig" = "8:_UNDEFINED" @@ -328,7 +388,13 @@ "Entry" { "MsmKey" = "8:_887B7AF445E3CB62E718707DB1A2DB74" - "OwnerKey" = "8:_F568BBC0422746FA9ADF497EFE4B6809" + "OwnerKey" = "8:_6E1CCF469FF44C51440438B84FAA9363" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_887B7AF445E3CB62E718707DB1A2DB74" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" "MsmSig" = "8:_UNDEFINED" } "Entry" @@ -346,6 +412,12 @@ "Entry" { "MsmKey" = "8:_887B7AF445E3CB62E718707DB1A2DB74" + "OwnerKey" = "8:_8B7827FFE66F143641790B9E6A834514" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_887B7AF445E3CB62E718707DB1A2DB74" "OwnerKey" = "8:_8B2D5366F6C941138FF83318D8C65C46" "MsmSig" = "8:_UNDEFINED" } @@ -369,6 +441,24 @@ } "Entry" { + "MsmKey" = "8:_8B7827FFE66F143641790B9E6A834514" + "OwnerKey" = "8:_8B2D5366F6C941138FF83318D8C65C46" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_8B7827FFE66F143641790B9E6A834514" + "OwnerKey" = "8:_6E1CCF469FF44C51440438B84FAA9363" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_8B7827FFE66F143641790B9E6A834514" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { "MsmKey" = "8:_8C9C7FF1DB4641FF874CFFD3CFF10E62" "OwnerKey" = "8:_UNDEFINED" "MsmSig" = "8:_UNDEFINED" @@ -382,7 +472,7 @@ "Entry" { "MsmKey" = "8:_ABD5677C265A4D7BC34829F543181C87" - "OwnerKey" = "8:_F568BBC0422746FA9ADF497EFE4B6809" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" "MsmSig" = "8:_UNDEFINED" } "Entry" @@ -508,7 +598,7 @@ "Entry" { "MsmKey" = "8:_ED3D10E989AADCAA0A7443322308EE1F" - "OwnerKey" = "8:_F568BBC0422746FA9ADF497EFE4B6809" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" "MsmSig" = "8:_UNDEFINED" } "Entry" @@ -531,12 +621,6 @@ } "Entry" { - "MsmKey" = "8:_F568BBC0422746FA9ADF497EFE4B6809" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { "MsmKey" = "8:_FCA7A8942BCF47809C58574D51DA4A7B" "OwnerKey" = "8:_UNDEFINED" "MsmSig" = "8:_UNDEFINED" @@ -550,19 +634,19 @@ "Entry" { "MsmKey" = "8:_UNDEFINED" - "OwnerKey" = "8:_F568BBC0422746FA9ADF497EFE4B6809" + "OwnerKey" = "8:_75A70548B8444C668B2D0462EC9CC366" "MsmSig" = "8:_UNDEFINED" } "Entry" { "MsmKey" = "8:_UNDEFINED" - "OwnerKey" = "8:_12B423DBA56C8DC0E3B05977AFDCC8BB" + "OwnerKey" = "8:_6E1CCF469FF44C51440438B84FAA9363" "MsmSig" = "8:_UNDEFINED" } "Entry" { "MsmKey" = "8:_UNDEFINED" - "OwnerKey" = "8:_72BA062375FF32683B46885AB8FB9F3C" + "OwnerKey" = "8:_109CA2795B9A7ADE61C883D41F3F86F5" "MsmSig" = "8:_UNDEFINED" } "Entry" @@ -580,6 +664,12 @@ "Entry" { "MsmKey" = "8:_UNDEFINED" + "OwnerKey" = "8:_8B7827FFE66F143641790B9E6A834514" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_UNDEFINED" "OwnerKey" = "8:_277A812A65804F067023A54D435F95E9" "MsmSig" = "8:_UNDEFINED" } @@ -592,6 +682,18 @@ "Entry" { "MsmKey" = "8:_UNDEFINED" + "OwnerKey" = "8:_12B423DBA56C8DC0E3B05977AFDCC8BB" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_UNDEFINED" + "OwnerKey" = "8:_72BA062375FF32683B46885AB8FB9F3C" + "MsmSig" = "8:_UNDEFINED" + } + "Entry" + { + "MsmKey" = "8:_UNDEFINED" "OwnerKey" = "8:_3062EBEC857307CE646864E951AD7CF4" "MsmSig" = "8:_UNDEFINED" } @@ -922,6 +1024,37 @@ "IsDependency" = "11:TRUE" "IsolateTo" = "8:" } + "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_109CA2795B9A7ADE61C883D41F3F86F5" + { + "AssemblyRegister" = "3:1" + "AssemblyIsInGAC" = "11:FALSE" + "AssemblyAsmDisplayName" = "8:Microsoft.Build.Utilities.v3.5, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" + "ScatterAssemblies" + { + "_109CA2795B9A7ADE61C883D41F3F86F5" + { + "Name" = "8:Microsoft.Build.Utilities.v3.5.dll" + "Attributes" = "3:512" + } + } + "SourcePath" = "8:Microsoft.Build.Utilities.v3.5.dll" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_2D85F2CCE0F64901A8231E38E3C0F2A8" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:TRUE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_12B423DBA56C8DC0E3B05977AFDCC8BB" { "AssemblyRegister" = "3:1" @@ -1241,6 +1374,37 @@ "IsDependency" = "11:TRUE" "IsolateTo" = "8:" } + "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_6E1CCF469FF44C51440438B84FAA9363" + { + "AssemblyRegister" = "3:1" + "AssemblyIsInGAC" = "11:FALSE" + "AssemblyAsmDisplayName" = "8:TechTalk.SpecFlow.Reporting, Version=1.1.0.0, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL" + "ScatterAssemblies" + { + "_6E1CCF469FF44C51440438B84FAA9363" + { + "Name" = "8:TechTalk.SpecFlow.Reporting.dll" + "Attributes" = "3:512" + } + } + "SourcePath" = "8:TechTalk.SpecFlow.Reporting.dll" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_2D85F2CCE0F64901A8231E38E3C0F2A8" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_72BA062375FF32683B46885AB8FB9F3C" { "AssemblyRegister" = "3:1" @@ -1427,6 +1591,37 @@ "IsDependency" = "11:TRUE" "IsolateTo" = "8:" } + "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_8B7827FFE66F143641790B9E6A834514" + { + "AssemblyRegister" = "3:1" + "AssemblyIsInGAC" = "11:FALSE" + "AssemblyAsmDisplayName" = "8:TechTalk.SpecFlow.Generator, Version=1.1.0.0, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL" + "ScatterAssemblies" + { + "_8B7827FFE66F143641790B9E6A834514" + { + "Name" = "8:TechTalk.SpecFlow.Generator.dll" + "Attributes" = "3:512" + } + } + "SourcePath" = "8:TechTalk.SpecFlow.Generator.dll" + "TargetName" = "8:" + "Tag" = "8:" + "Folder" = "8:_2D85F2CCE0F64901A8231E38E3C0F2A8" + "Condition" = "8:" + "Transitive" = "11:FALSE" + "Vital" = "11:TRUE" + "ReadOnly" = "11:FALSE" + "Hidden" = "11:FALSE" + "System" = "11:FALSE" + "Permanent" = "11:FALSE" + "SharedLegacy" = "11:FALSE" + "PackageAs" = "3:1" + "Register" = "3:1" + "Exclude" = "11:FALSE" + "IsDependency" = "11:TRUE" + "IsolateTo" = "8:" + } "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_8C9C7FF1DB4641FF874CFFD3CFF10E62" { "SourcePath" = "8:..\\..\\VsIntegration\\obj\\Debug\\SpecFlowEventDefinition.zip" @@ -2684,9 +2879,9 @@ { } } - "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_8B2D5366F6C941138FF83318D8C65C46" + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_75A70548B8444C668B2D0462EC9CC366" { - "SourcePath" = "8:..\\..\\VsIntegration\\obj\\Debug\\TechTalk.SpecFlow.VsIntegration.dll" + "SourcePath" = "8:..\\..\\Tools\\obj\\Debug\\specflow.exe" "TargetName" = "8:" "Tag" = "8:" "Folder" = "8:_2D85F2CCE0F64901A8231E38E3C0F2A8" @@ -2706,18 +2901,18 @@ "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" "OutputGroupCanonicalName" = "8:Built" - "OutputProjectGuid" = "8:{5703CA95-A08A-46AE-AE24-DB6B21FD6F7E}" + "OutputProjectGuid" = "8:{87BE7FE6-C3DE-4409-ABF6-FA5B60AF3DE1}" "ShowKeyOutput" = "11:TRUE" "ExcludeFilters" { } } - "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_F40F425B3B5D4365A81330EA775FCC1B" + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_8B2D5366F6C941138FF83318D8C65C46" { - "SourcePath" = "8:..\\DevenvSetupCustomAction\\obj\\Debug\\DevenvSetupCustomAction.dll" + "SourcePath" = "8:..\\..\\VsIntegration\\obj\\Debug\\TechTalk.SpecFlow.VsIntegration.dll" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_256850BB5BF44587B0F43F11538A0DA3" + "Folder" = "8:_2D85F2CCE0F64901A8231E38E3C0F2A8" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -2734,18 +2929,18 @@ "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" "OutputGroupCanonicalName" = "8:Built" - "OutputProjectGuid" = "8:{02F3B86D-0421-4D45-A701-44F3C94CF07D}" + "OutputProjectGuid" = "8:{5703CA95-A08A-46AE-AE24-DB6B21FD6F7E}" "ShowKeyOutput" = "11:TRUE" "ExcludeFilters" { } } - "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_F568BBC0422746FA9ADF497EFE4B6809" + "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_F40F425B3B5D4365A81330EA775FCC1B" { - "SourcePath" = "8:..\\..\\Reporting\\obj\\Debug\\TechTalk.SpecFlow.Reporting.exe" + "SourcePath" = "8:..\\DevenvSetupCustomAction\\obj\\Debug\\DevenvSetupCustomAction.dll" "TargetName" = "8:" "Tag" = "8:" - "Folder" = "8:_2D85F2CCE0F64901A8231E38E3C0F2A8" + "Folder" = "8:_256850BB5BF44587B0F43F11538A0DA3" "Condition" = "8:" "Transitive" = "11:FALSE" "Vital" = "11:TRUE" @@ -2762,7 +2957,7 @@ "ProjectOutputGroupRegister" = "3:1" "OutputConfiguration" = "8:" "OutputGroupCanonicalName" = "8:Built" - "OutputProjectGuid" = "8:{FC43509F-E7D3-40C4-B4C3-1E6C9D5530A4}" + "OutputProjectGuid" = "8:{02F3B86D-0421-4D45-A701-44F3C94CF07D}" "ShowKeyOutput" = "11:TRUE" "ExcludeFilters" { diff --git a/changelog.txt b/changelog.txt index ebec93733..b676fcfd6 100644 --- a/changelog.txt +++ b/changelog.txt @@ -2,6 +2,7 @@ vNext - ??? New features: ++ Allow transformation of feature files from command-line and MsBuild (Issue 3) Fixed issues: + MsTest does not refresh tests automatically (Issue 25)