test: test for restart and upgrade

This commit is contained in:
Rohit T P
2024-05-02 12:54:27 +00:00
parent 6610f30213
commit f179ecf325
4 changed files with 90 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
#!/usr/bin/env bats
NOCO_HOME="${HOME}/.nocodb"
export NOCO_HOME
WORKING_DIR="$(pwd)"
setup() {
cd "${WORKING_DIR}" || exit 1
./setup.sh "setup"
}
teardown() {
cd "${WORKING_DIR}" || exit 1
./setup.sh
}
@test "Check Redis, WatchTower and NocoDB are upgraded" {
../expects/configure/upgrade.sh
cd "${NOCO_HOME}" || exit 1
# Verify container is running
docker compose ps | grep -q 'redis'
docker compose ps | grep -q 'watchtower'
docker compose ps | grep -q 'nocodb'
}