Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitlab-ci.yml8
-rw-r--r--ci/run_windows_tests.ps142
2 files changed, 29 insertions, 21 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 05944a467..57720f211 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -272,15 +272,7 @@ gst-build:
- 'docker'
- 'windows'
- '2022'
- parallel:
- matrix:
- - CI_CARGO_FEATURES:
- - "--no-default-features"
- - "--all-features"
- - ""
script:
- - echo $env:CI_CARGO_FEATURES
-
# Set the code page to UTF-8
- chcp 65001
diff --git a/ci/run_windows_tests.ps1 b/ci/run_windows_tests.ps1
index f2333d99f..7c2b54054 100644
--- a/ci/run_windows_tests.ps1
+++ b/ci/run_windows_tests.ps1
@@ -1,26 +1,42 @@
$env:ErrorActionPreference='Stop'
-$exclude_crates = @(
+[string[]] $exclude_crates = @(
"--exclude",
"gst-plugin-csound",
"--exclude",
"gst-plugin-webp"
)
-Write-Host "Features: $env:CI_CARGO_FEATURES"
-Write-Host "Exlcude string: $exclude_crates"
+[string[]] $features_matrix = @(
+ "--no-default-features",
+ "",
+ "--all-features"
+)
-cargo build --color=always --workspace $exclude_crates --all-targets $env:CI_CARGO_FEATURES
+function Run-Tests {
+ param (
+ $Features
+ )
-if (!$?) {
- Write-Host "Build failed"
- Exit 1
-}
+ Write-Host "Features: $Features"
+ Write-Host "Exclude string: $exclude_crates"
+
+ cargo build --color=always --workspace $exclude_crates --all-targets $Features
-$env:G_DEBUG="fatal_warnings"
-cargo test --no-fail-fast --color=always --workspace $exclude_crates --all-targets $env:CI_CARGO_FEATURES
+ if (!$?) {
+ Write-Host "Build failed"
+ Exit 1
+ }
+
+ $env:G_DEBUG="fatal_warnings"
+ cargo test --no-fail-fast --color=always --workspace $exclude_crates --all-targets $Features
+
+ if (!$?) {
+ Write-Host "Tests failed"
+ Exit 1
+ }
+}
-if (!$?) {
- Write-Host "Tests failed"
- Exit 1
+foreach($feature in $features_matrix) {
+ Run-Tests -Features $feature
}