Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
lwm1986
roslyn
提交
da3b3660
R
roslyn
项目概览
lwm1986
/
roslyn
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
roslyn
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
da3b3660
编写于
2月 02, 2018
作者:
J
Jared Parsons
提交者:
GitHub
2月 02, 2018
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #24611 from jaredpar/fix-xunit
Move to xunit.console for CoreClr tests
上级
e2472c4a
6e7d1924
变更
5
显示空白变更内容
内联
并排
Showing
5 changed file
with
23 addition
and
7 deletion
+23
-7
build/scripts/build.ps1
build/scripts/build.ps1
+1
-1
build/scripts/tests.sh
build/scripts/tests.sh
+2
-2
src/Scripting/CSharpTest/CommandLineRunnerTests.cs
src/Scripting/CSharpTest/CommandLineRunnerTests.cs
+3
-2
src/Test/Utilities/Portable/Compilation/RuntimeUtilities.cs
src/Test/Utilities/Portable/Compilation/RuntimeUtilities.cs
+15
-0
src/Test/Utilities/Portable/Metadata/IlasmUtilities.cs
src/Test/Utilities/Portable/Metadata/IlasmUtilities.cs
+2
-2
未找到文件。
build/scripts/build.ps1
浏览文件 @
da3b3660
...
...
@@ -393,7 +393,7 @@ function Test-XUnitCoreClr() {
$tf
= "
netcoreapp2.0
"
$logDir
= Join-Path
$unitDir
"
xUnitResults
"
Create-Directory
$logDir
$xunitConsole
= Join-Path (Get-PackageDir "
dotnet-xunit
") "
tools\
$tf
\xunit.console.dll
"
$xunitConsole
= Join-Path (Get-PackageDir "
xunit.runner.console
") "
tools\
$tf
\xunit.console.dll
"
$dlls
= @()
$allGood
=
$true
...
...
build/scripts/tests.sh
浏览文件 @
da3b3660
...
...
@@ -20,11 +20,11 @@ xunit_console_version="$(get_package_version dotnet-xunit)"
if
[[
"
${
runtime
}
"
==
"dotnet"
]]
;
then
target_framework
=
netcoreapp2.0
xunit_console
=
"
${
nuget_dir
}
"
/
dotnet-xunit
/
"
${
xunit_console_version
}
"
/tools/
${
target_framework
}
/xunit.console.dll
xunit_console
=
"
${
nuget_dir
}
"
/
xunit.runner.console
/
"
${
xunit_console_version
}
"
/tools/
${
target_framework
}
/xunit.console.dll
elif
[[
"
${
runtime
}
"
==
"mono"
]]
;
then
source
${
root_path
}
/build/scripts/obtain_mono.sh
target_framework
=
net461
xunit_console
=
"
${
nuget_dir
}
"
/
dotnet-xunit
/
"
${
xunit_console_version
}
"
/tools/net452/xunit.console.exe
xunit_console
=
"
${
nuget_dir
}
"
/
xunit.runner.console
/
"
${
xunit_console_version
}
"
/tools/net452/xunit.console.exe
else
echo
"Unknown runtime:
${
runtime
}
"
exit
1
...
...
src/Scripting/CSharpTest/CommandLineRunnerTests.cs
浏览文件 @
da3b3660
...
...
@@ -84,9 +84,10 @@ private static IEnumerable<string> GetReferences()
string
workingDirectory
=
null
)
{
var
io
=
new
TestConsoleIO
(
input
);
var
clientDir
=
Path
.
GetDirectoryName
(
RuntimeUtilities
.
GetAssemblyLocation
(
typeof
(
CommandLineRunnerTests
)));
var
buildPaths
=
new
BuildPaths
(
clientDir
:
AppContext
.
BaseDirectory
,
workingDir
:
workingDirectory
??
AppContext
.
BaseDirectory
,
clientDir
:
clientDir
,
workingDir
:
workingDirectory
??
clientDir
,
sdkDir
:
null
,
tempDir
:
Path
.
GetTempPath
());
...
...
src/Test/Utilities/Portable/Compilation/RuntimeUtilities.cs
浏览文件 @
da3b3660
using
System
;
using
System.Collections.Generic
;
using
System.IO
;
using
System.Reflection
;
using
System.Runtime.InteropServices
;
using
System.Text
;
using
Roslyn.Test.Utilities
;
...
...
@@ -48,6 +49,20 @@ internal static AnalyzerAssemblyLoader CreateAnalyzerAssemblyLoader()
return
new
DesktopAnalyzerAssemblyLoader
();
#else
return
new
ThrowingAnalyzerAssemblyLoader
();
#endif
}
/// <summary>
/// Get the location of the assembly that contains this type
/// </summary>
internal
static
string
GetAssemblyLocation
(
Type
type
)
{
#if NET461 || NET46 || NETCOREAPP2_0
return
type
.
GetTypeInfo
().
Assembly
.
Location
;
#elif NETSTANDARD1_3
throw
new
NotSupportedException
();
#else
#error Unsupported configuration
#endif
}
}
...
...
src/Test/Utilities/Portable/Metadata/IlasmUtilities.cs
浏览文件 @
da3b3660
...
...
@@ -24,14 +24,14 @@ private static string GetIlasmPath()
if
(
CoreClrShim
.
AssemblyLoadContext
.
Type
==
null
)
{
return
Path
.
Combine
(
Path
.
GetDirectoryName
(
CorLightup
.
Desktop
.
GetAssemblyLocation
(
typeof
(
object
).
GetTypeInfo
().
Assembly
)),
Path
.
GetDirectoryName
(
RuntimeUtilities
.
GetAssemblyLocation
(
typeof
(
object
)
)),
"ilasm.exe"
);
}
else
{
var
ilasmExeName
=
PlatformInformation
.
IsWindows
?
"ilasm.exe"
:
"ilasm"
;
var
directory
=
AppContext
.
BaseDirectory
;
var
directory
=
Path
.
GetDirectoryName
(
RuntimeUtilities
.
GetAssemblyLocation
(
typeof
(
RuntimeUtilities
)))
;
string
path
=
null
;
while
(
directory
!=
null
&&
!
File
.
Exists
(
path
=
Path
.
Combine
(
directory
,
"Binaries"
,
"Tools"
,
"ILAsm"
,
ilasmExeName
)))
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录