glib/tests/run-markup-tests.sh
Havoc Pennington 32ef70d4b2 New module to parse a simple markup language
2000-10-24  Havoc Pennington  <hp@pobox.com>

        * gmarkup.h, gmarkup.c: New module to parse a simple
	markup language

	* Makefile.am: add gmarkup.h, gmarkup.c

	* tests/Makefile.am: add markup-test

	* gstring.h (g_string_new_len): new function to create a string
	with a length
	(g_string_new): avoid a gratuitous realloc
2000-10-27 02:46:04 +00:00

19 lines
363 B
Bash
Executable File

#! /bin/sh
fail ()
{
echo "Test failed: $*"
exit 1
}
for I in markups/fail-*.gmarkup; do
echo "Parsing $I, should fail"
./markup-test $I > /dev/null && fail "failed to generate error on $I"
done
for I in markups/valid-*.gmarkup; do
echo "Parsing $I, should succeed"
./markup-test $I > /dev/null || fail "failed on $I"
done
echo "All tests passed."