diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 4ed4dd5..aa87319 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -8,6 +8,8 @@ stages:
build:
stage: build
+ only:
+ - pushes
script:
- dotnet restore
- dotnet build --configuration Release --no-restore
@@ -18,10 +20,31 @@ build:
test:
stage: test
+ only:
+ - pushes
script:
- - dotnet test --verbosity normal
- dependencies:
- - build
+ - dotnet test HopFrame.sln --logger "trx;LogFilePrefix=testresults" --collect:"XPlat Code Coverage" --results-directory TestResults
+ - dotnet tool install --global trx2junit
+ - dotnet tool install --global dotnet-reportgenerator-globaltool
+ - export PATH="$PATH:/root/.dotnet/tools"
+ - for file in TestResults/*.trx; do trx2junit "$file"; done
+ - reportgenerator -reports:"TestResults/**/coverage.cobertura.xml" -targetdir:"coveragereport" -reporttypes:"Cobertura;HtmlInline"
+ - echo total_coverage=$(grep -o 'line-rate="[0-9.]*"' coveragereport/Cobertura.xml | head -n1 | sed -E 's/line-rate="([0-9.]+)"/\1/' | awk '{printf "%.2f", $1 * 100}')
+ - tar -cvf coveragereport.tar coveragereport/
+ artifacts:
+ when: always
+ expire_in: 1 week
+ paths:
+ - TestResults/*.xml
+ - TestResults/**/*.coverage.cobertura.xml
+ - coveragereport.tar
+ reports:
+ junit:
+ - TestResults/*.xml
+ coverage_report:
+ coverage_format: cobertura
+ path: coveragereport/Cobertura.xml
+ coverage: '/total_coverage=(\d+(\.\d+)?)/'
publish:
stage: publish
diff --git a/.idea/.idea.HopFrame/.idea/workspace.xml b/.idea/.idea.HopFrame/.idea/workspace.xml
index d483158..85f3cbc 100644
--- a/.idea/.idea.HopFrame/.idea/workspace.xml
+++ b/.idea/.idea.HopFrame/.idea/workspace.xml
@@ -11,11 +11,7 @@
-
-
-
-
-
+
@@ -132,7 +128,7 @@
"RunOnceActivity.git.unshallow": "true",
"b5f11219-dfc4-47a1-b02c-90ab603034fb.executor": "Debug",
"dcdf1689-dc07-47e4-8824-2e60a4fbf301.executor": "Debug",
- "git-widget-placeholder": "!35 on feature/advanced-search",
+ "git-widget-placeholder": "feature/test-reports",
"list.type.of.created.stylesheet": "CSS",
"node.js.detected.package.eslint": "true",
"node.js.detected.package.tslint": "true",
@@ -269,87 +265,8 @@
-
-
-
-
- 1737023058093
-
-
-
- 1737023058093
-
-
-
- 1737035288104
-
-
-
- 1737035288104
-
-
-
- 1737037853482
-
-
-
- 1737037853482
-
-
-
- 1737040612038
-
-
-
- 1737040612038
-
-
-
- 1737040946489
-
-
-
- 1737040946489
-
-
-
- 1737042229086
-
-
-
- 1737042229086
-
-
-
- 1737055409534
-
-
-
- 1737055409535
-
-
-
- 1737129518866
-
-
-
- 1737129518866
-
-
-
- 1737202192471
-
-
-
- 1737202192471
-
-
-
- 1737203441319
-
-
-
- 1737203441319
+
+
@@ -663,7 +580,87 @@
1751721064458
-
+
+
+ 1751721576913
+
+
+
+ 1751721576913
+
+
+
+ 1751747279843
+
+
+
+ 1751747279844
+
+
+
+ 1751747347169
+
+
+
+ 1751747347169
+
+
+
+ 1751747836791
+
+
+
+ 1751747836791
+
+
+
+ 1751748307061
+
+
+
+ 1751748307061
+
+
+
+ 1751748936783
+
+
+
+ 1751748936783
+
+
+
+ 1751749638139
+
+
+
+ 1751749638139
+
+
+
+ 1751750081208
+
+
+
+ 1751750081208
+
+
+
+ 1751750341741
+
+
+
+ 1751750341742
+
+
+
+ 1751750495636
+
+
+
+ 1751750495636
+
+
@@ -693,16 +690,6 @@
-
-
-
-
-
-
-
-
-
-
@@ -718,37 +705,16 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- file://$PROJECT_DIR$/src/HopFrame.Core/Services/Implementations/SearchExpressionBuilder.cs
- 102
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file