Hi, fairly new to CI, and especially to Circle CI. I’ve been asked to evaluate some CI platforms by the boss man
Circle CI was a breeze to get integrated with Bitbucket, run a build - but I’m really struggling to work out how to get it to run a suite of xunit.net tests (C# .netcore project). Does anyone have an example, tutorial or similar they could point me in the direction of?
I found: https://circleci.com/docs/manually/#tests which shows an example for php scripts - but I’m not sure what the command line for xunit.net tests would be - I get the feeling it’s just a line or two of code, but a lot of google searching has not turned anything up.
Thanks Lev, I was hoping it would be a quick fix, but I added a circle.yml file (until that point I’d been able to achieve everything including checkout, builds via your website which was really easy and quick) and pasted the above into it. I now get this output at the test stage:
bash: line 1: dotnet: command not found
dotnet test returned exit code 127
My knowledge here is a little limited - am I failing to include something in the project.json file that results in there being no dotnet.exe available to the build agent, or is there something wrong with the build agent?
@levlaz The command “dotnet” doesn’t appear to be available. A sample project with tests in would be great - I’ll be happy to create one on Bitbucket once I get this working, but I could do with some help to understand why “dotnet test” doesn’t work.
Right, you need to install it, we do not have dotnet core installed by default. In the sample project I installed it by adding the following to my circle.yml file
We only have a small number of dotnet core projects building on CircleCI right now. It would be great if you continue to share your experience (and especially any issues that you might run into) here!
Not sure which CI solution my boss / office will go with, but CircleCI is one of my preferences, and the only good hosted solution I’ve found with a free tier, so at the very least I will be using it for a couple of personal projects.
The tests run, and indicate status to the build properly, but I don’t yet have detailed output/reporting from the tests so I will look into this next.
Once I have something working properly end to end, I will put up a public Bitbucket repository and document what happened - but I’m about to go on holiday for a few weeks, so might not be until late January. (unless it’s very rainy while I’m holiday!)