summaryrefslogtreecommitdiffstats
path: root/tests/io_mock.h
diff options
context:
space:
mode:
authorAnastasia Klimchuk <aklm@chromium.org>2021-09-17 15:31:01 +1000
committerNico Huber <nico.h@gmx.de>2021-10-18 12:22:30 +0000
commit97acc374e453233fed65b397c4195c21dd5a0a57 (patch)
tree6612c0a801aa7476d8ee1d643a541aa397d6b978 /tests/io_mock.h
parent83b5191399157ff7a3ade3d95974cf5e3c8a077e (diff)
downloadflashrom-97acc374e453233fed65b397c4195c21dd5a0a57.tar.gz
flashrom-97acc374e453233fed65b397c4195c21dd5a0a57.tar.bz2
flashrom-97acc374e453233fed65b397c4195c21dd5a0a57.zip
tests: Move current_io to io_mock.c be visible across tests
tests.c is growing and needs to be split, specifically all libusb wraps need to be extracted into their own file. See later in the chain a lot more wraps are added for libusb functions. To be able to split it, current_io needs to be moved one level up, to be visible across tests. This allows having multiple files with wraps, and all the wraps can use current_io. BUG=b:181803212 TEST=builds and ninja test Change-Id: I5327b5de430afe13a8cc931c8b4b188dcb8c8cf6 Signed-off-by: Anastasia Klimchuk <aklm@chromium.org> Reviewed-on: https://review.coreboot.org/c/flashrom/+/57915 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Nico Huber <nico.h@gmx.de>
Diffstat (limited to 'tests/io_mock.h')
-rw-r--r--tests/io_mock.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/io_mock.h b/tests/io_mock.h
index a285e5345..7c235d820 100644
--- a/tests/io_mock.h
+++ b/tests/io_mock.h
@@ -95,4 +95,6 @@ struct io_mock {
void io_mock_register(const struct io_mock *io);
+const struct io_mock *get_io(void);
+
#endif