Comments (10)
Okay, that's a really good point. So would TestRunner be better in your situation if you could pass multiple .dll
s to it on the command line, like:
TestRunner.exe /path/to/sometests.dll /path/to/somemoretests.dll /path/to/evenmoretests.dll
I don't personally think this is any better than using for
or find
, but if supporting it makes TestRunner a better drop-in replacement for mstest, then I think you've convinced me it's a good idea.
from testrunner.
Hi Pascal,
Apologies for taking so long to respond - I've been on vacation.
My (and Einstein's) general philosophy is to keep things as simple as they can be, but no simpler. So I'd assumed you'd just loop and run TestRunner for each assembly.
It's also nice from a technical perspective because each assembly runs in a pristine process, guaranteed to be free of leftover threads, assembly configuration, memory consumption, etc.
That said, I would consider the feature if there was a compelling use case. Do you have one?
Regards,
Ron
from testrunner.
Hi Ron,
vacations are always a priority, so I understand
Yes, I have a case where it would be useful. I use Gitlab CI, and the most simple option here (as Einstein would have loved) is to test all assemblies from one single command, since Gitlab CI will use the error code to stop. The other option for me is to create a batch, detect generated assemblies, use the errorlevel
to exit if there is an error.
However, I was ready to contribute and submit the pull request for this.
Regards.
Pascal.
from testrunner.
Hi Pascal,
Won't something like this work as your CI test step:
for %%f in (C:\path\to\tests\*.dll) do (
path\to\TestRunner.exe "%%f"
if not %errorlevel% == 0 exit /b %errorlevel%
)
This will work even if it picks up .dll
files that contain no tests or aren't even .NET assemblies, since TestRunner returns exit code 0 in those cases.
I'm really hesitant to add file-finding functionality to TestRunner when better tools for the job already exist (in this case Windows for
and Unix find
).
I'm still open to being convinced otherwise, if you feel strongly about it and have a good argument.
Regards,
Ron
from testrunner.
I've also updated the readme to document exit codes in more detail as discussed above. 6e4ea30
from testrunner.
Yes it would work, but currently the original mstest
application does the job better, so I'll probably stay with it.
from testrunner.
For the record, the mstest
program is no better than TestRunner in this regard: It accepts a path to a single test dll via its /testcontainer
switch.
According to its documentation, it also appears to be able to work off of .orderedtest
and .vsmdi
files, but it's not clear to me what those are or how useful that functionality is.
https://msdn.microsoft.com/en-us/library/ms182489.aspx#Anchor_0
from testrunner.
... But it accepts the /testcontainer
multiple times, so it can test multiple assemblies in a single call
from testrunner.
Done for v1.5
from testrunner.
Thank you, I'll take a look at it.
from testrunner.
Related Issues (20)
- Not compatible with System.Reactive.Interfaces, Version=3.1.1 HOT 10
- TestContext property getter(s) not working on .NET Core HOT 1
- Multiprocess not working on .NET Core HOT 1
- Mono automated builds and tests HOT 1
- Research whether it's possible for assembly redirects in switched config files to work HOT 1
- TestRunDirectory support
- .trx output file format support HOT 4
- .config file redirection doesn't work on Mono
- Research correct behaviour on exceptions in initialize and cleanup methods
- Move non-essential logic out of runners into event handlers HOT 1
- Add TestRunBeginEvent, TestRunEndEvent, and TestRunResults HOT 1
- ResultAccumulatingEventHandler HOT 1
- Add --class option HOT 2
- Fold `Results` into `Events`
- Add --method option HOT 3
- Pure reflection test discovery HOT 1
- TestContext support HOT 10
- Remove assembly reference(s) from test suites to TestRunner HOT 2
- Auto-discover tests in solution
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 testrunner.