summaryrefslogtreecommitdiff
path: root/test/run
AgeCommit message (Collapse)AuthorFilesLines
2022-10-22test: Fix typo in test nameMichal Suchanek1-2/+2
For other sandbox tests the printed test name corresponds to the configuration except for this one. Signed-off-by: Michal Suchanek <msuchanek@suse.de> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Simon Glass <sjg@chromium.org>
2022-09-13Makefile: Add a pcheck option to run tests in parallelSimon Glass1-8/+32
Running tests in parallel is much faster, e.g. 15 seconds to run the tests on sandbox (only), instead of 100 seconds (on a 16-core machine). Add a 'make pcheck' option to access this feature. Note that the tools/ tests still run each tool's tests once after the other, although within that, they do run in parallel. So for example, the buildman tests run in parallel, then the binman tests run in parallel. There would be a signiificant advantage to running them all in parallel together, but that would require a large amount of refactoring, e.g. with more use of pytest fixtures. Update the documentation to represent the current state. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-13test: Refactor arg parsing for the run scriptSimon Glass1-4/+7
Tidy up this code a little. Also use '-k' consistently, since -m is more limited in what it can accept. Signed-off-by: Simon Glass <sjg@chromium.org>
2021-03-26test: Run sandbox_spl tests on sandbox_noinstSimon Glass1-0/+4
Run the tests on this build too, to prevent regressions. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org>
2020-10-29test: Run SPL unit testsSimon Glass1-1/+1
Update the 'run' script to include SPL unit tests. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-07-25patman: Add a 'test' subcommandSimon Glass1-1/+1
At present we use --test to indicate that tests should be run. It is better to use a subcommand for list, like binman. Change it and adjust the existing code to fit under a 'send' subcommand, the default. Give this subcommand the same default arguments as the others. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-07-24Revert "Merge tag 'dm-pull-20jul20' of git://git.denx.de/u-boot-dm"Tom Rini1-1/+1
This reverts commit 5d3a21df6694ebd66d5c34c9d62a26edc7456fc7, reversing changes made to 56d37f1c564107e27d873181d838571b7d7860e7. Unfortunately this is causing CI failures: https://travis-ci.org/github/trini/u-boot/jobs/711313649 Signed-off-by: Tom Rini <trini@konsulko.com>
2020-07-20patman: Add a 'test' subcommandSimon Glass1-1/+1
At present we use --test to indicate that tests should be run. It is better to use a subcommand for list, like binman. Change it and adjust the existing code to fit under a 'send' subcommand, the default. Give this subcommand the same default arguments as the others. Signed-off-by: Simon Glass <sjg@chromium.org>
2020-04-26Add a 'make tcheck' option to test toolsSimon Glass1-10/+16
Running all the unit tests takes a while and is not useful when you are just modifying the tools. Add an option to run only the tools tests. Signed-off-by: Simon Glass <sjg@chromium.org>
2019-07-24binman: Convert to use ArgumentParserSimon Glass1-2/+2
This class is the new way to handle arguments in Python. Convert binman over to use it. At the same time, introduce commands so that we can separate out the different parts of binman functionality. Signed-off-by: Simon Glass <sjg@chromium.org>
2019-07-24binman: Pass the toolpath to testsSimon Glass1-3/+6
Tools like ifwitool may not be available in the PATH, but are available in the build. These tools may be needed by tests, so allow tests to use the --toolpath flag. Also use this flag with travis. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-11-29test: Add a 'make qcheck' target for quicker testingSimon Glass1-2/+8
At present tests are quite slow to run, over a minute on my machine. This presents a considerable barrier to bisecting for failures. The slowest tests are the filesystem ones and the buildman --fetch-arch test. Add a new 'qcheck' target that skips these tests. This reduces test time down to about 40 second, still too long, but bearable. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-11-26spl: Add support for passing handoff info to U-Boot properSimon Glass1-1/+1
There is some basic informaton that SPL normally wants to pass through to U-Boot, such as the SDRAM size and bank information. Mkae use of the new bloblist structure for this. Add a new 'handoff' blob which is set up in SPL and passed to U-Boot proper. Also adda test for sandbox_spl that checks that this works correctly and a new 'sb' command to show the information passed from SPL. Reviewed-by: Tom Rini <trini@konsulko.com> Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08test: Reduce the number of tests run with sandbox_flattreeSimon Glass1-1/+2
We only need to run driver-model tests with this config, since this is the only thing that is different when CONFIG_OF_LIVE is not defined. Filter out the other tests to same time. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08test: Tidy up comments and variable nameSimon Glass1-4/+8
The 'result' variable counts the number of failures in running the tests. Rename it to 'failures' to make this more obvious. Also tidy up a few comments. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08test: Print the name of each test before running itSimon Glass1-11/+19
At present the tests are run without any indication of what is running. For the tests which start with a build this is pretty obvious, but for tools it is not. Add a name for each test we run, and print it before starting the test. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-10-08test: Simplify the PATH setupSimon Glass1-9/+9
Use 'export' to avoid repeating the path setup for each command. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-07-09test: Enable cover-coverage tests for dtoc and fdtSimon Glass1-0/+4
Now that we have 100% code coverage we can enable these tests in the test script also. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-07-09binman: Switch to 'python-coverage'Tom Rini1-2/+1
The most portable way to get access to coverage is to invoke it as 'python-coverage'. Cc: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Rini <trini@konsulko.com> Signed-off-by: Simon Glass <sjg@chromium.org>
2018-06-07test: Fix sandbox_spl test filterSimon Glass1-2/+1
This filter does not match the test it is intended to anymore. Update it so that it works again. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-01-16test: Set the DTC environment variableSimon Glass1-3/+5
Set this to our own device-tree compiler since we know it is new enough to run the tests. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-01-16binman: Run code coverage testsSimon Glass1-0/+7
Binman has 100% test coverage for the code as it is at present. To encourage it to stay that way, run the code-coverage test as part of the normal U-Boot tests. This is RFC because it requires the Python code coverage tools to be available. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-01-16test: Run dtoc testsSimon Glass1-0/+1
Update the test script to run the dtoc tests also. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-01-16test: Run buildman testsSimon Glass1-0/+1
Update the test script to run the buildman tests also. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-01-16test: Run patman testsSimon Glass1-0/+1
Update the test script to run the patman tests also. Signed-off-by: Simon Glass <sjg@chromium.org>
2018-01-16test: Run binman testsSimon Glass1-0/+3
Update the test script to run the binman tests also. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-11-28test: Correct operation when tests passSimon Glass1-1/+2
When tests pass an error message is printed because of a variable that is not initialised. Fix this. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-11-23test/run: Report and return failureSimon Glass1-3/+17
This script runs the tests but does not report failure. Also it always returns an exit code of 0 even on failure. Fix these problems by checking the result of each test. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01test: Update 'make test' to run more testsSimon Glass1-1/+7
The standard sandbox board cannot run the of-platdata test since it needs SPL. Also, we should test the flat tree version of sandbox. Add these tests to the default test script. Signed-off-by: Simon Glass <sjg@chromium.org>
2016-07-15test: Add a simple script to run tests on sandboxSimon Glass1-0/+4
A common check before sending patches is to run all available tests on sandbox. But everytime I do this I have to look up the README. This presents quite a barrier to actually doing this. Add a shell script to help. To run the tests, type: test/run in the U-Boot directory, which should be easy to remember. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Teddy Reed <teddy.reed@gmail.com>