#!/bin/sh -e
# SPDX-FileCopyrightText: 2021 John Scott <jscott@posteo.net>
# SPDX-License-Identifier: GPL-3.0-or-later
sh-elf-gcc -o "$AUTOPKGTEST_TMP"/echo debian/tests/echo.c
cd "$AUTOPKGTEST_TMP"
string='Hello, world'
output=$(sh-elf-run ./echo $string)
if [ "$output" != "$string" ]
then
	echo Expected "$string", got "$output" >&2
	exit 1
fi
