Browse Source

Can now run all tests with code coverage or run all the tests in the current project.

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/branches/3.0@3882 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
Matt Ward 17 years ago
parent
commit
de9ecf1083
  1. BIN
      data/resources/StringResources.cz.resources
  2. BIN
      data/resources/StringResources.de.resources
  3. BIN
      data/resources/StringResources.es-mx.resources
  4. BIN
      data/resources/StringResources.es.resources
  5. BIN
      data/resources/StringResources.fr.resources
  6. BIN
      data/resources/StringResources.nl.resources
  7. BIN
      data/resources/StringResources.tr.resources
  8. 17
      src/AddIns/Misc/CodeCoverage/Project/CodeCoverage.addin
  9. 1
      src/AddIns/Misc/CodeCoverage/Project/CodeCoverage.csproj
  10. 28
      src/AddIns/Misc/CodeCoverage/Project/Src/RunAllTestsWithCodeCoverageCommand.cs
  11. 25
      src/AddIns/Misc/UnitTesting/Src/RunTestCommands.cs
  12. 26
      src/AddIns/Misc/UnitTesting/UnitTesting.addin
  13. BIN
      src/Main/StartUp/Project/Resources/StringResources.resources

BIN
data/resources/StringResources.cz.resources

Binary file not shown.

BIN
data/resources/StringResources.de.resources

Binary file not shown.

BIN
data/resources/StringResources.es-mx.resources

Binary file not shown.

BIN
data/resources/StringResources.es.resources

Binary file not shown.

BIN
data/resources/StringResources.fr.resources

Binary file not shown.

BIN
data/resources/StringResources.nl.resources

Binary file not shown.

BIN
data/resources/StringResources.tr.resources

Binary file not shown.

17
src/AddIns/Misc/CodeCoverage/Project/CodeCoverage.addin

@ -87,6 +87,23 @@ @@ -87,6 +87,23 @@
</ComplexCondition>
</Path>
<Path name="/SharpDevelop/Workbench/MainMenu/QualityTools/Test">
<ComplexCondition action="Disable">
<And>
<Condition name="SolutionOpen"/>
<Not>
<Condition name="RunningTests"/>
</Not>
</And>
<MenuItem id = "RunAllWithCodeCoverage"
insertbefore = "RunProjectTests"
insertafter = "RunAll"
icon = "CodeCoverage.Icons.16x16.Run"
label = "${res:ICSharpCode.UnitTesting.RunAllWithCoverage}"
class = "ICSharpCode.CodeCoverage.RunAllTestsWithCodeCoverageCommand"/>
</ComplexCondition>
</Path>
<Path path = "/SharpDevelop/BackendBindings/ProjectOptions/AllManaged">
<DialogPanel id = "CodeCoverage"
label = "${res:ICSharpCode.UnitTesting.CodeCoverage}"

1
src/AddIns/Misc/CodeCoverage/Project/CodeCoverage.csproj

@ -60,6 +60,7 @@ @@ -60,6 +60,7 @@
<Compile Include="Src\PartCoverExitEventArgs.cs" />
<Compile Include="Src\PartCoverRunner.cs" />
<Compile Include="Src\PartCoverSettings.cs" />
<Compile Include="Src\RunAllTestsWithCodeCoverageCommand.cs" />
<Compile Include="Src\SequencePointListViewSorter.cs" />
<Compile Include="Src\ToggleCodeCoverageCommand.cs" />
<Compile Include="Src\CodeCoverageHighlighter.cs" />

28
src/AddIns/Misc/CodeCoverage/Project/Src/RunAllTestsWithCodeCoverageCommand.cs

@ -0,0 +1,28 @@ @@ -0,0 +1,28 @@
// <file>
// <copyright see="prj:///doc/copyright.txt"/>
// <license see="prj:///doc/license.txt"/>
// <owner name="Matthew Ward" email="mrward@users.sourceforge.net"/>
// <version>$Revision$</version>
// </file>
using System;
using ICSharpCode.UnitTesting;
namespace ICSharpCode.CodeCoverage
{
public class RunAllTestsWithCodeCoverageCommand : RunTestWithCodeCoverageCommand
{
public RunAllTestsWithCodeCoverageCommand()
{
}
/// <summary>
/// Set Owner to null so all tests are run.
/// </summary>
public override void Run()
{
Owner = null;
base.Run();
}
}
}

25
src/AddIns/Misc/UnitTesting/Src/RunTestCommands.cs

@ -525,4 +525,29 @@ namespace ICSharpCode.UnitTesting @@ -525,4 +525,29 @@ namespace ICSharpCode.UnitTesting
base.Run();
}
}
public class RunProjectTestsInPadCommand : RunTestInPadCommand, ITestTreeView
{
public override void Run()
{
Owner = this;
base.Run();
}
public IMember SelectedMethod {
get { return null; }
}
public IClass SelectedClass {
get { return null; }
}
public IProject SelectedProject {
get { return ProjectService.CurrentProject; }
}
public string SelectedNamespace {
get { return null; }
}
}
}

26
src/AddIns/Misc/UnitTesting/UnitTesting.addin

@ -173,10 +173,32 @@ @@ -173,10 +173,32 @@
</And>
<MenuItem id = "RunAll"
icon = "Icons.16x16.RunAllIcon"
label = "Run all tests"
tooltip = "${res:NUnitPad.NUnitPadContent.RunAllTests}"
label = "${res:NUnitPad.NUnitPadContent.RunAllTests}"
class = "ICSharpCode.UnitTesting.RunAllTestsInPadCommand"/>
</ComplexCondition>
<ComplexCondition action="Disable">
<And>
<Condition name="SolutionOpen"/>
<Not>
<Condition name="RunningTests"/>
<Condition name="ProjectActive" activeproject="*"/>
</Not>
</And>
<MenuItem id = "RunProjectTests"
icon = "Icons.16x16.RunProgramIcon"
label = "${res:ICSharpCode.UnitTesting.RunProjectTests}"
class = "ICSharpCode.UnitTesting.RunProjectTestsInPadCommand"/>
</ComplexCondition>
<ComplexCondition action="Disable">
<And>
<Condition name="SolutionOpen"/>
<Condition name="RunningTests"/>
</And>
<MenuItem id = "Stop"
icon = "Icons.16x16.Debug.StopProcess"
label = "${res:NUnitPad.NUnitPadContent.StopTests}"
class = "ICSharpCode.UnitTesting.StopTestsCommand"/>
</ComplexCondition>
</Path>
<!-- Options panel -->

BIN
src/Main/StartUp/Project/Resources/StringResources.resources

Binary file not shown.
Loading…
Cancel
Save