1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-16 00:00:02 +01:00
VILLASnode/tests/integration/hook-shift_ts.sh

18 lines
340 B
Bash
Raw Normal View History

2017-03-27 12:39:29 +02:00
#!/bin/bash
STATS_FILE=$(mktemp)
OFFSET=10
EPSILON=0.05
villas-signal sine -l 10 -r 10 | villas-hook shift_ts offset=${OFFSET} | villas-hook stats format=\"json\" output=\"${STATS_FILE}\" > /dev/null
#jq .owd ${STATS_FILE}
jq -e ".owd.mean - ${OFFSET} | length < ${EPSILON}" ${STATS_FILE} > /dev/null
RC=$?
rm ${STATS_FILE}
exit $RC