Skip to content

Commit

Permalink
Tests: Wire up in-svsm tests for VirtioBlkDriver
Browse files Browse the repository at this point in the history
Add a virtio-blk device to the in-svsm test setup to allow
the VirtioBlkDriver tests to run.

Signed-off-by: Oliver Steffen <[email protected]>
  • Loading branch information
osteffenrh committed Dec 9, 2024
1 parent 4f7f546 commit 1f1362b
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions scripts/test-in-svsm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,17 @@ test_io(){
done
}

PIPES_DIR=$(mktemp -d -q)
mkfifo $PIPES_DIR/pipe.in
mkfifo $PIPES_DIR/pipe.out
TEST_DIR=$(mktemp -d -q)
mkfifo $TEST_DIR/pipe.in
mkfifo $TEST_DIR/pipe.out
truncate -s 16M $TEST_DIR/svsm_state.raw

test_io $PIPES_DIR/pipe.in $PIPES_DIR/pipe.out &
test_io $TEST_DIR/pipe.in $TEST_DIR/pipe.out &
TEST_IO_PID=$!

$SCRIPT_DIR/launch_guest.sh --igvm $SCRIPT_DIR/../bin/coconut-test-qemu.igvm \
--unit-tests $PIPES_DIR/pipe || true
--state $TEST_DIR/svsm_state.raw \
--unit-tests $TEST_DIR/pipe || true

kill $TEST_IO_PID
rm -rf $PIPES_DIR
rm -rf $TEST_DIR

0 comments on commit 1f1362b

Please sign in to comment.