使用VS2015预览我试图创建一个测试项目(vnext库(dll))。使用here
中的示例//Test Class
using System;
using Xunit;
namespace testproject.Tests
{
public class Class1
{
[Fact]
public void TrueisTrue()
{
Assert.True(true);
}
[Fact]
public void OnePlusOneIsTwo()
{
Assert.Equal(2, 1 + 1);
}
}
}
// project.json
{
"version": "1.0.0-*",
"dependencies": {
"Xunit.KRunner": "1.0.0-beta1"
},
"commands": {
"test": "Xunit.KRunner"
},
"frameworks": {
"aspnet50": {
"dependencies": {
"System.Runtime": "4.0.20-beta-22231"
}
},
"aspnetcore50": {
"dependencies": {
"System.Runtime": "4.0.20-beta-22231"
}
},
"k10": {
"dependencies": {
"System.Runtime": "4.0.20-beta-22231"
}
}
}
}
我在错误窗口中收到这些错误,但测试确实运行正常。这是测试版中的错误,还是我在配置中遗漏了什么?
答案 0 :(得分:1)
k10
project.json
不需要aspnet50