From f83f5b03c1eea3fe26a0929583ffbd16df7c64f0 Mon Sep 17 00:00:00 2001 From: Timothy Manning Date: Tue, 27 Jul 2021 18:11:58 +1200 Subject: [PATCH] Added a docstring explaining how to use test_runner.py Also deleted the old Makefile based test runner. Signed-off-by: Timothy Manning --- direct/test-framework/unit_tests/Makefile | 12 ---------- .../test-framework/unit_tests/test_runner.py | 24 ++++++++++++------- 2 files changed, 15 insertions(+), 21 deletions(-) delete mode 100644 direct/test-framework/unit_tests/Makefile diff --git a/direct/test-framework/unit_tests/Makefile b/direct/test-framework/unit_tests/Makefile deleted file mode 100644 index c2b46e3..0000000 --- a/direct/test-framework/unit_tests/Makefile +++ /dev/null @@ -1,12 +0,0 @@ - -TEST_DIR = quick_tests \ - is_yaffs_working_tests - -all: - $(foreach var,$(TEST_DIR), $(MAKE) -j -C $(var);) - -phony. test: - $(foreach var,$(TEST_DIR), $(MAKE) -j -C $(var) test;) - -phony. clean: - $(foreach var,$(TEST_DIR), $(MAKE) -j -C $(var) clean;) \ No newline at end of file diff --git a/direct/test-framework/unit_tests/test_runner.py b/direct/test-framework/unit_tests/test_runner.py index a8af075..77bab48 100755 --- a/direct/test-framework/unit_tests/test_runner.py +++ b/direct/test-framework/unit_tests/test_runner.py @@ -1,14 +1,20 @@ #!/usr/bin/env python3 """ - * YAFFS: Yet another FFS. A NAND-flash specific file system. - * - * Copyright (C) 2002-2021 Aleph One Ltd. - * - * Created by Timothy Manning - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. +test_runner.py +This file runs all of the yaffs unit tests and aggrates the outputs. + +To run this file you can use: + +$ python3 test_runner.py + +or + +$ ./test_runner.py + +To add a new test to this test runner, add the test dir path to the +test_list below. Inside that folder there need to be a makefile with +a "test" target that compiles and runs the test script. I.e. "make test" +is called in every test directory. """ -- 2.30.2