+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)