X-Git-Url: http://git.ozlabs.org/?p=petitboot;a=blobdiff_plain;f=test%2Fparser%2Fparser-test.h;h=383680fabb9ede74bfda88e3a3a5c5cd42b5a63e;hp=c0339b89a4f2ca809f6ca27e9ffe9986cf99022a;hb=2c97f136757b5428bb68f91cfa723990dcd985c8;hpb=c14b12980885edd035322cd3bc87efff444c39b1 diff --git a/test/parser/parser-test.h b/test/parser/parser-test.h index c0339b8..383680f 100644 --- a/test/parser/parser-test.h +++ b/test/parser/parser-test.h @@ -33,13 +33,19 @@ int test_run_parser(struct parser_test *test, const char *parser_name); void test_hotplug_device(struct parser_test *test, struct discover_device *dev); void test_remove_device(struct parser_test *test, struct discover_device *dev); +/* Note that the testing filesystem will only reflect files and + * directories that you explicitly add, so it is possible for a test + * to inconsistently believe that a file exists but that its parent + * directory does not. */ void test_add_file_data(struct parser_test *test, struct discover_device *dev, const char *filename, const void *data, int size); void test_add_dir(struct parser_test *test, struct discover_device *dev, const char *dirname); + void test_set_event_source(struct parser_test *test); void test_set_event_param(struct event *event, const char *name, const char *value); +void test_set_event_device(struct event *event, const char *dev); #define test_add_file_string(test, dev, filename, str) \ test_add_file_data(test, dev, filename, str, sizeof(str) - 1)