summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/parser/Makefile.am2
-rw-r--r--test/parser/test-grub2-lexer-error.c13
-rw-r--r--test/parser/test-grub2-parser-error.c13
3 files changed, 28 insertions, 0 deletions
diff --git a/test/parser/Makefile.am b/test/parser/Makefile.am
index 8159bd6..e7146c5 100644
--- a/test/parser/Makefile.am
+++ b/test/parser/Makefile.am
@@ -35,6 +35,8 @@ TESTS = \
test-grub2-single-line-if \
test-grub2-f18-ppc64 \
test-grub2-ubuntu-13_04-x86 \
+ test-grub2-lexer-error \
+ test-grub2-parser-error \
test-kboot-single \
test-yaboot-single \
test-yaboot-partition \
diff --git a/test/parser/test-grub2-lexer-error.c b/test/parser/test-grub2-lexer-error.c
new file mode 100644
index 0000000..503ec99
--- /dev/null
+++ b/test/parser/test-grub2-lexer-error.c
@@ -0,0 +1,13 @@
+
+#include "parser-test.h"
+
+#if 0 /* PARSER_EMBEDDED_CONFIG */
+&
+#endif
+
+void run_test(struct parser_test *test)
+{
+ test_read_conf_embedded(test);
+ test_run_parser(test, "grub2");
+ check_boot_option_count(test->ctx, 0);
+}
diff --git a/test/parser/test-grub2-parser-error.c b/test/parser/test-grub2-parser-error.c
new file mode 100644
index 0000000..a7a00a4
--- /dev/null
+++ b/test/parser/test-grub2-parser-error.c
@@ -0,0 +1,13 @@
+
+#include "parser-test.h"
+
+#if 0 /* PARSER_EMBEDDED_CONFIG */
+{
+#endif
+
+void run_test(struct parser_test *test)
+{
+ test_read_conf_embedded(test);
+ test_run_parser(test, "grub2");
+ check_boot_option_count(test->ctx, 0);
+}
OpenPOWER on IntegriCloud