Coder Social home page Coder Social logo

Comments (5)

tonerdo avatar tonerdo commented on August 15, 2024

What's .trx?

from coverlet.

pms1969 avatar pms1969 commented on August 15, 2024

it's the logger output for dotnet test.

To run my tests, I do the following:

    time \
        dotnet test \
            --no-build \
            --no-restore \
            --filter 'TestCategory!=Integration&TestCategory!=Explicit&TestCategory!=Performance' \
            --logger:trx \
            -r .output/ \
            $testproj \
            /nowarn:NU1701,NU1603,NU1605 \
            /p:CollectCoverage=true \
            /p:CoverletOutputFormat=opencover

the --logger:trx, produces the trx output file (which is vstest output format?). This is then picked up by sonarqube and processed to identify failed tests.

from coverlet.

sampwil avatar sampwil commented on August 15, 2024

@pms1969 Once again it seems we are have some of the same issues. I think it is because we are attempting to run this in a CI/CD environment. I encountered the same no output if I have the --no-build and --no-restore switch. When I removed the switch I would I get the "because it is being used by another process" issue again. I discovered if I let the process build into empty directory it would fail. When I ran a dotnet publish and specified the configuration switch to it previously run publish directory it would succeed. I have put my successful patterns below.

dotnet publish src/Server.Tests/Server.Tests.csproj -c Debug
dotnet add src/Server.Tests/Server.Tests.csproj package coverlet.msbuild --version 1.1.0
dotnet test src/Server.Tests/Server.Tests.csproj /p:CollectCoverage=true /p:CoverletOutputFormat=json -c Debug


dotnet publish src/Server.Tests/Server.Tests.csproj -c Release
dotnet add src/Server.Tests/Server.Tests.csproj package coverlet.msbuild --version 1.1.0
dotnet test src/Server.Tests/Server.Tests.csproj /p:CollectCoverage=true /p:CoverletOutputFormat=json -c Release

from coverlet.

pms1969 avatar pms1969 commented on August 15, 2024

@sampwil Thanks. I haven't had time to circle back to this yet. Hopefully soon. I thought I'd managed to rid us of the "used by another process" problem. but apparently not. There's a newer version out, since I posted this originally, so maybe something in there fixes this. maybe not :/ I'll just have to play again and see.

Unfortunately publishing, and rebuilding every time doesn't work for us. The coverage job takes neigh on 22 minutes at present. Using coverlet and linux docker instead of the current dotcover and windows, I can get the time down to 14'ish minutes. It has to be something simple.

from coverlet.

tonerdo avatar tonerdo commented on August 15, 2024

Moved discussion to #72

from coverlet.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.