From df8cc7c8e4495a1aec8eff31fda9d5cc5f724c2f Mon Sep 17 00:00:00 2001 From: Ben Bachem <10088265+bezbac@users.noreply.github.com> Date: Tue, 7 Jan 2025 11:04:48 +0100 Subject: [PATCH] wip --- tests/Dockerfile | 3 +++ tests/expect.sh | 3 +++ tests/integration_test.sh | 4 ++-- 3 files changed, 8 insertions(+), 2 deletions(-) create mode 100755 tests/expect.sh diff --git a/tests/Dockerfile b/tests/Dockerfile index 408b82b..7aa09c1 100644 --- a/tests/Dockerfile +++ b/tests/Dockerfile @@ -5,6 +5,9 @@ RUN apt update # Install curl RUN apt install curl -y +# Install expect +RUN apt install expect -y + # Install zsh RUN apt install zsh -y RUN chsh -s $(which zsh) diff --git a/tests/expect.sh b/tests/expect.sh new file mode 100755 index 0000000..2ccc0d3 --- /dev/null +++ b/tests/expect.sh @@ -0,0 +1,3 @@ +#!/usr/bin/expect + +spawn "/bin/zellij attach -c main" diff --git a/tests/integration_test.sh b/tests/integration_test.sh index 183e30a..6a9d71f 100755 --- a/tests/integration_test.sh +++ b/tests/integration_test.sh @@ -10,5 +10,5 @@ cargo build --release cd .. docker build -t zellij:test -f ./tests/Dockerfile . -# Run the docker image in interactive mode -docker run -it zellij:test +# Run the expect script inside the docker container +docker run -v ./tests/expect.sh:/expect.sh -t zellij:test -c "/expect.sh"