#!/bin/bash # # Integration test for remote API # # @author Steffen Vogel # @copyright 2014-2022, Institute for Automation of Complex Power Systems, EONERC # @license Apache 2.0 ################################################################################## set -e DIR=$(mktemp -d) pushd ${DIR} function finish { popd rm -rf ${DIR} } trap finish EXIT cat > config.json < fetched.json # Shutdown VILLASnode kill $! # Compare local config with the fetched one jq -e '(.[0].in | index("testnode2")) and (.[0].out | index("testnode1")) and (. | length == 1)' fetched.json > /dev/null