]> git.ozlabs.org Git - petitboot/blobdiff - test/parser/test-pxe-local.c
test/parser: Add local PXE test
[petitboot] / test / parser / test-pxe-local.c
diff --git a/test/parser/test-pxe-local.c b/test/parser/test-pxe-local.c
new file mode 100644 (file)
index 0000000..3a85645
--- /dev/null
@@ -0,0 +1,18 @@
+#include "parser-test.h"
+
+#if 0 /* PARSER_EMBEDDED_CONFIG */
+menuentry 'Linux' {
+       linux   /vmlinux
+       initrd  /initrd
+}
+#endif
+
+/* check that the PXE parser won't break on a local device */
+void run_test(struct parser_test *test)
+{
+       test_read_conf_embedded(test, "/grub2/grub.cfg");
+
+       test_run_parser(test, "pxe");
+
+       check_boot_option_count(test->ctx, 0);
+}