mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-23 06:45:19 -07:00
coverage fixes
This commit is contained in:
parent
bc02f4ef92
commit
12522b2abf
3 changed files with 8 additions and 13 deletions
|
@ -390,12 +390,9 @@ stages:
|
|||
vmImage: 'vs2017-win2016'
|
||||
steps:
|
||||
- checkout: self
|
||||
- task: DownloadPipelineArtifact@2
|
||||
displayName: Download Test Artifact
|
||||
inputs:
|
||||
buildType: 'current'
|
||||
artifactName: Tests
|
||||
targetPath: $(testsFolder)
|
||||
submodules: true
|
||||
- bash: ./build.sh --only-backend
|
||||
displayName: Build Lidarr Backend
|
||||
- task: Bash@3
|
||||
displayName: Coverage Unit Tests
|
||||
inputs:
|
||||
|
@ -406,4 +403,4 @@ stages:
|
|||
displayName: Publish Coverage Results
|
||||
inputs:
|
||||
codeCoverageTool: 'cobertura'
|
||||
summaryFileLocation: '**/coverage.cobertura.xml'
|
||||
summaryFileLocation: './Coverage.xml'
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
"build": "gulp build",
|
||||
"start": "gulp watch",
|
||||
"watch": "gulp watch",
|
||||
"clean": "rimraf ./_output/UI",
|
||||
"clean": "git clean -fXd",
|
||||
"eslint": "esprint check",
|
||||
"eslint-fix": "eslint --fix frontend/** ",
|
||||
"stylelint-linux": "stylelint $(find frontend -name '*.css') --config frontend/.stylelintrc",
|
||||
|
@ -112,7 +112,6 @@
|
|||
"redux-thunk": "2.3.0",
|
||||
"require-nocache": "1.0.0",
|
||||
"reselect": "4.0.0",
|
||||
"rimraf": "2.6.3",
|
||||
"run-sequence": "2.2.1",
|
||||
"signalr": "2.4.1",
|
||||
"streamqueue": "1.1.2",
|
||||
|
|
7
test.sh
7
test.sh
|
@ -9,8 +9,6 @@ ASSEMBLIES=""
|
|||
TEST_LOG_FILE="TestLog.txt"
|
||||
COVERAGE_FILE="$TEST_DIR/Coverage.xml"
|
||||
|
||||
dotnet tool install --global coverlet.console
|
||||
|
||||
if [ -d "$TEST_DIR/_tests" ]; then
|
||||
TEST_DIR="$TEST_DIR/_tests"
|
||||
fi
|
||||
|
@ -21,7 +19,6 @@ rm -f "$TEST_LOG_FILE"
|
|||
export LIDARR_TESTS_LOG_OUTPUT="File"
|
||||
|
||||
NUNIT="$TEST_DIR/NUnit.ConsoleRunner.3.7.0/tools/nunit3-console.exe"
|
||||
OPEN_COVER="coverlet"
|
||||
NUNIT_COMMAND="$NUNIT"
|
||||
NUNIT_PARAMS="--workers=1"
|
||||
|
||||
|
@ -60,7 +57,9 @@ done
|
|||
|
||||
if [ "$COVERAGE" = "Coverage" ]; then
|
||||
if [ "$PLATFORM" = "Windows" ] ; then
|
||||
$OPEN_COVER ./_tests/Lidarr.Core.Test --format "cobertura" --target "$NUNIT" --targetargs "$NUNIT_PARAMS --where=\"$WHERE\" $ASSEMBLIES";
|
||||
dotnet tool install coverlet.console --tool-path=./_tests/coverlet/
|
||||
OPEN_COVER="./_tests/coverlet/coverlet"
|
||||
$OPEN_COVER ./_tests/ --format "cobertura" --output "$COVERAGE_FILE" --exclude "[Lidarr.*.Test]*" --exclude "[Lidarr.Test.*]*" --exclude "[Marr.Data]*" --exclude "[MonoTorrent]*" --exclude "[CurlSharp]*" --target "$NUNIT" --targetargs "$NUNIT_PARAMS --where=\"$WHERE\" $ASSEMBLIES";
|
||||
EXIT_CODE=$?
|
||||
else
|
||||
echo "Coverage only supported on Windows"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue