Clean up dnx references
This commit is contained in:
Родитель
ce068c6019
Коммит
61de025fa1
18
README.md
18
README.md
|
@ -1,6 +1,6 @@
|
|||
## <a href="https://github.com/xunit/xunit"><img src="https://raw.github.com/xunit/media/master/full-logo.png" title="xUnit.net DNX Runner" /></a>
|
||||
## <a href="https://github.com/xunit/xunit"><img src="https://raw.github.com/xunit/media/master/full-logo.png" title="xUnit.net CoreCLR Runner" /></a>
|
||||
|
||||
This runner supports [xUnit.net](https://github.com/xunit/xunit) tests for [DNX 4.5.1+, and DNX Core 5+](https://github.com/aspnet/dnx) (this includes [ASP.NET 5+](https://github.com/aspnet)).
|
||||
This runner supports [xUnit.net](https://github.com/xunit/xunit) tests for [dotnet 4.5.1+, and dotnet Core 5+](https://github.com/dotnet/corefx) (this includes [ASP.NET 5+](https://github.com/aspnet)).
|
||||
|
||||
### Usage
|
||||
|
||||
|
@ -10,11 +10,9 @@ To install this package, ensure your project.json contains the following lines:
|
|||
{
|
||||
"dependencies": {
|
||||
"xunit": "2.1.0-*",
|
||||
"xunit.runner.dnx": "2.1.0-*"
|
||||
"dotnet-test-xunit": "2.1.0-*"
|
||||
},
|
||||
"commands": {
|
||||
"test": "xunit.runner.dnx"
|
||||
}
|
||||
"testRunner": "dotnet-test-xunit"
|
||||
}
|
||||
```
|
||||
|
||||
|
@ -22,15 +20,15 @@ To run tests from the command line, use the following.
|
|||
|
||||
```Shell
|
||||
# Restore NuGet packages
|
||||
dnu restore
|
||||
dotnet restore
|
||||
|
||||
# Run tests in current directory
|
||||
dnx test
|
||||
dotnet test
|
||||
|
||||
# Run tests if tests are not in the current directory
|
||||
dnx -p path/to/project test
|
||||
dotnet -p path/to/project test // not yet implemented
|
||||
```
|
||||
|
||||
### More Information
|
||||
|
||||
For more complete example usage, please see [Getting Started with xUnit.net and DNX / ASP.NET 5](http://xunit.github.io/docs/getting-started-dnx.html).
|
||||
For more complete example usage, please see [Getting Started with xUnit.net and CoreCLR / ASP.NET 5](http://xunit.github.io/docs/getting-started-coreclr.html).
|
||||
|
|
|
@ -1,90 +0,0 @@
|
|||
<Project DefaultTargets="Test" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
|
||||
<UsingTask
|
||||
AssemblyFile="packages\xunit.buildtasks\tools\CodePlex.MSBuildTasks.dll"
|
||||
TaskName="CodePlex.MSBuildTasks.RegexReplace"/>
|
||||
<UsingTask
|
||||
AssemblyFile="packages\xunit.buildtasks\tools\CodePlex.MSBuildTasks.dll"
|
||||
TaskName="CodePlex.MSBuildTasks.Zip"/>
|
||||
|
||||
<!-- Settings -->
|
||||
|
||||
<PropertyGroup>
|
||||
<Configuration Condition="'$(Configuration)' == ''">Release</Configuration>
|
||||
<TrackFileAccess>false</TrackFileAccess>
|
||||
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">$(MSBuildProjectDirectory)</SolutionDir>
|
||||
<NuGetExePath Condition=" '$(NuGetExePath)' == '' ">$(SolutionDir)\.nuget\nuget.exe</NuGetExePath>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<ProjectFiles Include="src\**\project.json" />
|
||||
</ItemGroup>
|
||||
|
||||
<!-- Build server targets -->
|
||||
|
||||
<Target Name="CI" DependsOnTargets="PackageRestore;SetVersionNumber;Test;ZipArtifacts" />
|
||||
|
||||
<Target Name="PackageRestore" DependsOnTargets="_DownloadNuGet">
|
||||
<Message Text="Restoring NuGet packages..." Importance="High" />
|
||||
<Exec Command=""$(NuGetExePath)" install xunit.buildtasks -Source http://www.myget.org/F/b4ff5f68eccf4f6bbfed74f055f88d8f/ -SolutionDir "$(SolutionDir)" -Verbosity quiet -ExcludeVersion" Condition="!Exists('$(SolutionDir)\packages\xunit.buildtasks\')" />
|
||||
</Target>
|
||||
|
||||
<Target Name="Build" DependsOnTargets="PackageRestore">
|
||||
<Exec Command="powershell -NoProfile -NonInteractive -ExecutionPolicy RemoteSigned tools\dnx-build.ps1" />
|
||||
</Target>
|
||||
|
||||
<Target Name="Test" DependsOnTargets="Build">
|
||||
<Exec Command="powershell -NoProfile -NonInteractive -ExecutionPolicy RemoteSigned tools\dnx-tests.ps1" />
|
||||
</Target>
|
||||
|
||||
<Target Name="SetVersionNumber">
|
||||
<RegexReplace
|
||||
Pattern='99\.99\.99-dev'
|
||||
Replacement='$(BuildSemanticVersion)'
|
||||
Files='@(ProjectFiles)'
|
||||
Condition=" '$(BuildSemanticVersion)' != '' "/>
|
||||
</Target>
|
||||
|
||||
<Target Name='ZipArtifacts'>
|
||||
<ItemGroup>
|
||||
<Binaries Include="src\**\*.nupkg" />
|
||||
</ItemGroup>
|
||||
|
||||
<Delete Files="binaries.zip" />
|
||||
<Zip Files="@(Binaries)" ZipFileName="binaries.zip" StripPath="true" />
|
||||
</Target>
|
||||
|
||||
<Target Name="_DownloadNuGet">
|
||||
<MakeDir Directories="$(SolutionDir)\.nuget" />
|
||||
<DownloadNuGet OutputFilename="$(NuGetExePath)" Condition="!Exists('$(NuGetExePath)')" />
|
||||
</Target>
|
||||
|
||||
<UsingTask TaskName="DownloadNuGet" TaskFactory="CodeTaskFactory" AssemblyFile="$(MSBuildToolsPath)\Microsoft.Build.Tasks.v4.0.dll">
|
||||
<ParameterGroup>
|
||||
<OutputFilename ParameterType="System.String" Required="true" />
|
||||
</ParameterGroup>
|
||||
<Task>
|
||||
<Reference Include="System.Core" />
|
||||
<Using Namespace="System" />
|
||||
<Using Namespace="System.IO" />
|
||||
<Using Namespace="System.Net" />
|
||||
<Using Namespace="Microsoft.Build.Framework" />
|
||||
<Using Namespace="Microsoft.Build.Utilities" />
|
||||
<Code Type="Fragment" Language="cs">
|
||||
<![CDATA[
|
||||
try {
|
||||
OutputFilename = Path.GetFullPath(OutputFilename);
|
||||
|
||||
Log.LogMessage("Downloading latest version of NuGet.exe...");
|
||||
WebClient webClient = new WebClient();
|
||||
webClient.DownloadFile("https://www.nuget.org/nuget.exe", OutputFilename);
|
||||
|
||||
return true;
|
||||
}
|
||||
catch (Exception ex) {
|
||||
Log.LogErrorFromException(ex);
|
||||
return false;
|
||||
}
|
||||
]]>
|
||||
</Code>
|
||||
</Task>
|
||||
</UsingTask>
|
||||
</Project>
|
Двоичные данные
dnx.xunit.v2.ncrunchsolution
Двоичные данные
dnx.xunit.v2.ncrunchsolution
Двоичный файл не отображается.
|
@ -7,7 +7,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{8EE7A674-CE0
|
|||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "test", "test", "{8B1FE5A0-EA59-456D-B293-82B806DDBEFD}"
|
||||
EndProject
|
||||
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "test.xunit.runner.dnx", "test\test.xunit.runner.dnx\test.xunit.runner.dnx.xproj", "{838070AB-04F2-4A37-9C86-91669E633F70}"
|
||||
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "test.dotnet-test-xunit", "test\test.dotnet-test-xunit\test.dotnet-test-xunit.xproj", "{838070AB-04F2-4A37-9C86-91669E633F70}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{02FA41F5-A5D0-457A-96E7-724756124491}"
|
||||
ProjectSection(SolutionItems) = preProject
|
|
@ -237,7 +237,7 @@ namespace Xunit.Runner.DotNet
|
|||
|
||||
project.Filters.IncludedNameSpaces.Add(option.Value);
|
||||
}
|
||||
// BEGIN: Special command line switches for DNX <=> Visual Studio integration
|
||||
// BEGIN: Special command line switches for dotnet <=> Visual Studio integration
|
||||
else if (optionName == "test" || optionName == "-test")
|
||||
{
|
||||
if (option.Value == null)
|
||||
|
@ -255,7 +255,7 @@ namespace Xunit.Runner.DotNet
|
|||
GuardNoOptionValue(option);
|
||||
DesignTime = true;
|
||||
}
|
||||
// END: Special command line switches for DNX <=> Visual Studio integration
|
||||
// END: Special command line switches for dotnet <=> Visual Studio integration
|
||||
else
|
||||
{
|
||||
// Might be a reporter...
|
||||
|
|
|
@ -199,7 +199,7 @@ namespace Xunit.Runner.DotNet
|
|||
{
|
||||
Console.WriteLine("Copyright (C) 2015 Outercurve Foundation.");
|
||||
Console.WriteLine();
|
||||
Console.WriteLine("usage: xunit.runner.dnx [configFile.json] [options] [reporter] [resultFormat filename [...]]");
|
||||
Console.WriteLine("usage: dotnet-test-xunit [configFile.json] [options] [reporter] [resultFormat filename [...]]");
|
||||
Console.WriteLine();
|
||||
Console.WriteLine("Valid options:");
|
||||
Console.WriteLine(" -nologo : do not show the copyright message");
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
using System.Reflection;
|
||||
|
||||
[assembly : AssemblyTitle("xUnit.net Test Runner (DNX / DNX Core)")]
|
||||
[assembly : AssemblyTitle("xUnit.net Test Runner (CoreCLR)")]
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
"title": "xUnit.net [Runner: dotnet]",
|
||||
"description": "Console and Visual Studio runner for xUnit.net.Supported platforms:- dotnet 5.4+",
|
||||
"name": "dotnet-test-xunit",
|
||||
"projectUrl": "https://github.com/xunit/dnx.xunit",
|
||||
"projectUrl": "https://github.com/xunit/coreclr.xunit",
|
||||
"iconUrl": "https://raw.githubusercontent.com/xunit/media/master/logo-512-transparent.png",
|
||||
"licenseUrl": "https://raw.githubusercontent.com/xunit/xunit/master/license.txt",
|
||||
"requireLicenseAcceptance": false,
|
||||
|
|
|
@ -1,21 +0,0 @@
|
|||
$toolsPath = split-path $MyInvocation.MyCommand.Definition
|
||||
$dnvm = join-path $toolsPath "dnvm.ps1"
|
||||
$solutionPath = [System.IO.Path]::GetFullPath($(join-path $toolsPath ".."))
|
||||
$globalJson = join-path $solutionPath "global.json"
|
||||
$dnxVersion = (ConvertFrom-JSON ([System.IO.File]::ReadAllText($globalJson))).sdk.version
|
||||
|
||||
& $dnvm use $dnxVersion -runtime CLR -arch x86
|
||||
& dnx -p $(join-path $solutionPath "test\test.xunit.runner.dnx") test
|
||||
if ($LastExitCode -ne 0) { exit 1 }
|
||||
|
||||
& $dnvm use $dnxVersion -runtime CoreCLR -arch x86
|
||||
& dnx -p $(join-path $solutionPath "test\test.xunit.runner.dnx") test
|
||||
if ($LastExitCode -ne 0) { exit 1 }
|
||||
|
||||
& $dnvm use $dnxVersion -runtime CLR -arch x64
|
||||
& dnx -p $(join-path $solutionPath "test\test.xunit.runner.dnx") test
|
||||
if ($LastExitCode -ne 0) { exit 1 }
|
||||
|
||||
& $dnvm use $dnxVersion -runtime CoreCLR -arch x64
|
||||
& dnx -p $(join-path $solutionPath "test\test.xunit.runner.dnx") test
|
||||
if ($LastExitCode -ne 0) { exit 1 }
|
Загрузка…
Ссылка в новой задаче