forked from ceph/ceph
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
We have a few Python rbd-wnbd tests that are invoked explicitly by the ceph-build scripts [1]. There are a few issues with that: * it's a separate repo that has to be updated whenever we add new tests * new tests that reside in the ceph repo will not be executed by the PR check * some tests may be missing in case of older branches For this reason, we're adding a new script as part of the Ceph repo that will take care of invoking the Windows rbd-wnbd tests. The ceph-build script has already been updated accordingly [2]. [1] https://github.com/ceph/ceph-build/blob/main/scripts/ceph-windows/run_tests#L73-L80 [2] ceph/ceph-build#2094 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> Co-Authored-By: Ionut Balutoiu <ibalutoiu@cloudbasesolutions.com>
- Loading branch information
1 parent
0bf85c7
commit 2b014e1
Showing
4 changed files
with
41 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,4 @@ tasks: | |
clients: | ||
client.0: | ||
- windows/libvirt_vm/setup.sh | ||
- windows/run-rbd-wnbd-tests.sh | ||
- windows/run-tests.sh |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
$ProgressPreference = "SilentlyContinue" | ||
$ErrorActionPreference = "Stop" | ||
|
||
$scriptLocation = [System.IO.Path]::GetDirectoryName( | ||
$myInvocation.MyCommand.Definition) | ||
|
||
$testRbdWnbd = "$scriptLocation/test_rbd_wnbd.py" | ||
|
||
function safe_exec() { | ||
# Powershell doesn't check the command exit code, we'll need to | ||
# do it ourselves. Also, in case of native commands, it treats stderr | ||
# output as an exception, which is why we'll have to capture it. | ||
cmd /c "$args 2>&1" | ||
if ($LASTEXITCODE) { | ||
throw "Command failed: $args" | ||
} | ||
} | ||
|
||
safe_exec python.exe $testRbdWnbd --test-name RbdTest --iterations 100 | ||
safe_exec python.exe $testRbdWnbd --test-name RbdFioTest --iterations 100 | ||
safe_exec python.exe $testRbdWnbd --test-name RbdStampTest --iterations 100 | ||
|
||
# It can take a while to setup the partition (~10s), we'll use fewer iterations. | ||
safe_exec python.exe $testRbdWnbd --test-name RbdFsTest --iterations 4 | ||
safe_exec python.exe $testRbdWnbd --test-name RbdFsFioTest --iterations 4 | ||
safe_exec python.exe $testRbdWnbd --test-name RbdFsStampTest --iterations 4 | ||
|
||
safe_exec python.exe $testRbdWnbd ` | ||
--test-name RbdResizeFioTest --image-size-mb 64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/usr/bin/env bash | ||
set -ex | ||
|
||
DIR="$(cd $(dirname "${BASH_SOURCE[0]}") && pwd)" | ||
|
||
source ${DIR}/libvirt_vm/build_utils.sh | ||
source ${DIR}/libvirt_vm/connection_info.sh | ||
|
||
# Run the Windows tests | ||
scp_upload ${DIR} /windows-workunits | ||
SSH_TIMEOUT=30m ssh_exec powershell.exe -File /windows-workunits/run-tests.ps1 |