mirror of
https://github.com/OPCFoundation/UA-.NETStandard.git
synced 2026-10-16 21:02:51 +08:00
18 lines
791 B
Bash
Executable File
18 lines
791 B
Bash
Executable File
#!/bin/bash
|
|
# Copyright (c) OPC Foundation. All rights reserved.
|
|
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
|
|
BUILDROOT=$(pwd)/..
|
|
cd $BUILDROOT
|
|
|
|
rm -r ./CodeCoverage
|
|
rm -r ./TestResults
|
|
dotnet test "UA.slnx" -v n --configuration Release --framework net10.0 --collect:"XPlat Code Coverage" --settings ./tests/coverlet.runsettings.xml --results-directory ./TestResults
|
|
|
|
# ensure latest report tool is installed
|
|
dotnet tool uninstall -g dotnet-reportgenerator-globaltool
|
|
dotnet tool install -g dotnet-reportgenerator-globaltool
|
|
reportgenerator -reports:./TestResults/**/coverage.cobertura.xml -targetdir:./CodeCoverage -reporttypes:"Badges;Html;HtmlSummary;Cobertura"
|
|
|
|
# Display result in browser (mac OS)
|
|
open ./CodeCoverage/index.html |