1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

added integration test for remote file node-type

This commit is contained in:
Steffen Vogel 2017-03-29 20:15:04 +02:00
parent a799f625f9
commit 2d4836f21d

View file

@ -0,0 +1,42 @@
#!/bin/bash
CONFIG_FILE=$(mktemp)
INPUT_FILE=$(mktemp)
OUTPUT_FILE=$(mktemp)
URI=https://1Nrd46fZX8HbggT:badpass@rwth-aachen.sciebo.de/public.php/webdav/node/tests/pipe
cat > ${CONFIG_FILE} <<EOF
nodes = {
remote_file_out = {
type = "file",
out = {
uri = "${URI}"
mode = "w+"
},
},
remote_file_in = {
type = "file",
in = {
uri = "${URI}"
mode = "r"
epoch_mode = "original"
}
}
}
EOF
villas signal sine -n -l 10 > ${INPUT_FILE}
villas pipe -s ${CONFIG_FILE} remote_file_out < ${INPUT_FILE}
villas pipe -r ${CONFIG_FILE} remote_file_in > ${OUTPUT_FILE}
villas test-cmp -j ${INPUT_FILE} ${OUTPUT_FILE}
RC=$?
rm -f ${CONFIG_FILE} ${INPUT_FILE} ${OUTPUT_FILE}
exit $RC