summaryrefslogtreecommitdiffstats
path: root/tests/init_shutdown.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/init_shutdown.c')
-rw-r--r--tests/init_shutdown.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/init_shutdown.c b/tests/init_shutdown.c
index 522686017..abaaf6821 100644
--- a/tests/init_shutdown.c
+++ b/tests/init_shutdown.c
@@ -35,3 +35,14 @@ void dummy_init_and_shutdown_test_success(void **state)
{
run_lifecycle(state, PROGRAMMER_DUMMY, "bus=parallel+lpc+fwh+spi");
}
+
+void linux_spi_init_and_shutdown_test_success(void **state)
+{
+ /*
+ * Current implementation tests a particular path of the init procedure.
+ * There are two ways for it to succeed: reading the buffer size from sysfs
+ * and the fallback to getpagesize(). This test does the latter (fallback to
+ * getpagesize).
+ */
+ run_lifecycle(state, PROGRAMMER_LINUX_SPI, "dev=/dev/null");
+}