forked from enix/san-iscsi-csi
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: new command line script for running csi-sanity
Created a new sanity-cli test script to be used for running tests from the command line, requires updates to .env Signed-off-by: Joe Skazinski <[email protected]>
- Loading branch information
1 parent
8129575
commit 8b7d14b
Showing
8 changed files
with
103 additions
and
30 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
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
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,16 @@ | ||
# | ||
# Fill in all values below using the example as a template. | ||
# Passwords with special characters must be escaped and quoted. | ||
# | ||
# Example: | ||
# TEST_USERNAME=username | ||
# TEST_PASSWORD=\"\!password\" | ||
# TEST_IP=http://1.2.3.4 | ||
# TEST_POOL=A|B | ||
# TEST_FSTYPE=ext3|ext4|xfs | ||
# | ||
TEST_USERNAME= | ||
TEST_PASSWORD= | ||
TEST_IP= | ||
TEST_POOL= | ||
TEST_FSTYPE= |
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,56 @@ | ||
#! /usr/bin/env bash | ||
|
||
echo "" | ||
echo "[] sanity-cli" | ||
|
||
secretsTemplate="secrets.template.yml" | ||
secrets="secrets.yml" | ||
volumeTemplate="volume.template.yml" | ||
volume="volume.yml" | ||
|
||
set -e | ||
|
||
function pause() | ||
{ | ||
echo "" | ||
read -s -n 1 -p "===== Press any key to contine =====" | ||
echo "" | ||
} | ||
|
||
function setup { | ||
cd $(dirname $0) | ||
set -a; . .env; set +a | ||
|
||
echo "" | ||
|
||
envsubst < ${secretsTemplate} > ${secrets} | ||
echo "===== ${secrets} =====" | ||
cat ${secrets} | ||
echo "===== END =====" | ||
|
||
echo "" | ||
|
||
envsubst < ${volumeTemplate} > ${volume} | ||
echo "===== ${volume} =====" | ||
cat ${volume} | ||
echo "===== END =====" | ||
} | ||
|
||
setup | ||
pause | ||
|
||
controller=unix:///var/run/csi-exos-x.seagate.com/csi-controller.sock | ||
node=unix:///var/run/csi-exos-x.seagate.com/csi-node.sock | ||
sanity=/home/seagate/github.com/kubernetes-csi/csi-test/cmd/csi-sanity/csi-sanity | ||
focus="CreateVolume" | ||
focus="DeleteVolume" | ||
focus="" | ||
|
||
echo "" | ||
echo "[] csi-sanity" | ||
echo "sudo ${sanity} -csi.controllerendpoint ${controller} -csi.endpoint ${node} -csi.secrets ${secrets} -ginkgo.focus \"${focus}\" -csi.testvolumeparameters ${volume} -ginkgo.failFast > sanity.log" | ||
sudo ${sanity} -csi.controllerendpoint ${controller} -csi.endpoint ${node} -csi.secrets ${secrets} -ginkgo.focus "${focus}" -csi.testvolumeparameters ${volume} -ginkgo.failFast > sanity.log | ||
|
||
out=$? | ||
|
||
exit ${out} |
File renamed without changes.
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 |
---|---|---|
@@ -1,28 +1,28 @@ | ||
CreateVolumeSecret: | ||
username: $STORAGE_USERNAME | ||
password: $STORAGE_PASSWORD | ||
apiAddress: $STORAGE_API_ADDR | ||
username: $TEST_USERNAME | ||
password: $TEST_PASSWORD | ||
apiAddress: $TEST_IP | ||
DeleteVolumeSecret: | ||
username: $STORAGE_USERNAME | ||
password: $STORAGE_PASSWORD | ||
apiAddress: $STORAGE_API_ADDR | ||
username: $TEST_USERNAME | ||
password: $TEST_PASSWORD | ||
apiAddress: $TEST_IP | ||
ControllerPublishVolumeSecret: | ||
username: $STORAGE_USERNAME | ||
password: $STORAGE_PASSWORD | ||
apiAddress: $STORAGE_API_ADDR | ||
username: $TEST_USERNAME | ||
password: $TEST_PASSWORD | ||
apiAddress: $TEST_IP | ||
ControllerUnpublishVolumeSecret: | ||
username: $STORAGE_USERNAME | ||
password: $STORAGE_PASSWORD | ||
apiAddress: $STORAGE_API_ADDR | ||
username: $TEST_USERNAME | ||
password: $TEST_PASSWORD | ||
apiAddress: $TEST_IP | ||
NodeStageVolumeSecret: | ||
username: $STORAGE_USERNAME | ||
password: $STORAGE_PASSWORD | ||
apiAddress: $STORAGE_API_ADDR | ||
username: $TEST_USERNAME | ||
password: $TEST_PASSWORD | ||
apiAddress: $TEST_IP | ||
NodePublishVolumeSecret: | ||
username: $STORAGE_USERNAME | ||
password: $STORAGE_PASSWORD | ||
apiAddress: $STORAGE_API_ADDR | ||
username: $TEST_USERNAME | ||
password: $TEST_PASSWORD | ||
apiAddress: $TEST_IP | ||
ControllerValidateVolumeCapabilitiesSecret: | ||
username: $STORAGE_USERNAME | ||
password: $STORAGE_PASSWORD | ||
apiAddress: $STORAGE_API_ADDR | ||
username: $TEST_USERNAME | ||
password: $TEST_PASSWORD | ||
apiAddress: $TEST_IP |
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,2 @@ | ||
pool: $TEST_POOL | ||
fsType: $TEST_FSTYPE |