Comments (5)
Further, I tried executing the exe manually and I get the following:
C:\>C:\BuildAgent\tools\xunit-runner\bin\2.2.0\xunit.console.exe C:/BuildAgent/work/68ab5b6fa6e51f21/Tests/XUnitCore.dll -teamcity
xUnit.net Console Runner (64-bit .NET 4.0.30319.42000)
System.IO.FileNotFoundException: Could not load file or assembly 'System.Runtime, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
Adding this to my project didn't seem to fix anything (there isn't even a v4.2.0.0 so I did 4.3.0)
from xunit-teamcity.
I have finally found that TeamCity.VSTest.TestAdapter will give me a more detailed error:
Step 6/6: xUnit
[16:27:14][Step 6/6] Runner parameters { Version = 2.2.0, runtime = .NET 4.5, platform = AnyCPU/MSIL}
[16:27:14][Step 6/6] Failed to run tests
[16:27:14]
[Step 6/6] java.lang.NumberFormatException: For input string: ""
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
at java.lang.Integer.parseInt(Integer.java:592)
at java.lang.Integer.parseInt(Integer.java:615)
at se.capeit.dev.xunittestrunner.XUnitBuildProcess.call(XUnitBuildProcess.java:58)
at se.capeit.dev.xunittestrunner.XUnitBuildProcess.call(XUnitBuildProcess.java:19)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
[16:27:14][Step 6/6] Step xUnit failed
(note, 2 steps are disabled which is why you may noticed step 6/6) but I only mentioned 4 steps.
from xunit-teamcity.
Hi @Dev123213,
Sorry that it is not working for you. I think there are multiple problems here, so let's go through them.
In the first post, you get the error "No assemblies were matched - no tests will be run!". This is because you are specifying an absolute path, which as discovered in #27 is not supported yet. Until I've had time to fix that, I would recommend changing to a relative path, ie Tests/*.dll
instead.
The third post makes me wonder what version of the plugin you are using? The error you are seeing in your last comment looks like one that occurred in a fork of the plugin. While that is still published on the Teamcity plugins page, it is by now quite old and has a few bugs.
But even fixing those two issues, I think your second post shows the error that will happen when the two other are resolved. The current (2.2) release of xUnit does not support .net core, as seen in the compatibility matrix. I'm not sure when 2.3 will hit a full release, but there will likely be a few other changes required to support the new runner.
from xunit-teamcity.
Hi Carl, thanks for getting back to me promptly. I have fixed the path, and am using the most recent plugin version advertised here (1.2) https://github.com/carlpett/xUnit-TeamCity/releases/tag/v1.2.0.
To clarify your last paragraph, xunit does support .net core (https://xunit.github.io/docs/getting-started-dotnet-core.html), but the plugin for team city does not? If so, I will have to abandon xunit for now as we want net core.
from xunit-teamcity.
Ok, that is good to know. I'll see if I can recreate it. The line numbers in the stack trace don't seem to match the code, though, which is confusing....
xUnit supports .net core in their beta releases, yes, but there is no supported version with a finalized way of running it yet (it has changed between different beta versions, as I understand it). So I'm a bit wary of integrating it before that has settled down.
One thing you could do as a workaround until this is supported would be to add a "Command line" build step and run dotnet xunit -teamcity
there, which should turn on teamcity reporting mode so that it is properly picked up.
from xunit-teamcity.
Related Issues (20)
- runner missing from zip HOT 2
- Teamcity Version 10.0.1 and version 1.1.3a HOT 1
- Support for xUnit 2.2.0? HOT 3
- Missing 2.2.0 in Runner Parameters HOT 2
- Add build step -> xUnit -> no parameters show up HOT 8
- No assemblies were matched - no tests will be run! HOT 6
- Teamcity variables are not expanded in assembly list HOT 2
- 'Test Failure' reported as 'Success' in TeamCity when message contains Unicode ’ char (RIGHT SINGLE QUOTATION MARK) HOT 3
- Update .Net Framework requirements to support framework 4.7 HOT 6
- Release 1.2.1 is not available in the TeamCity plugins area HOT 1
- Agent requirements not met - no compatible agents HOT 2
- Output message in each project nested to deep hierarchy HOT 3
- xUnit console runner fails to execute some (random) tests on Team City HOT 2
- Support for xUnit 2.4.0 HOT 4
- Platform parameter gets reset to default value when editing the step HOT 9
- can't select higher than 4.5 version of .NET Runtime HOT 2
- Version 1.3.0, but in teamcity-plugin.xml, version is 1.1.0 HOT 1
- aspnet 5.0 HOT 1
- TLS error during test runs
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xunit-teamcity.