btrfs-progs: tests: update README

Wording, runtime dependencies.

Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
David Sterba 2017-08-29 17:07:15 +02:00
parent 7da5841e3f
commit c4dd5fef8a
1 changed files with 11 additions and 4 deletions

View File

@ -30,7 +30,7 @@ category, eg. `fsck-tests-results.txt`.
## Selective testing ## Selective testing
The test are prefixed by a number for ordering and uniqueness. To run a The tests are prefixed by a number for ordering and uniqueness. To run a
particular test use: particular test use:
```shell ```shell
@ -76,8 +76,7 @@ will run the first test in fsck-tests subdirectory.
* anything that does not fit to the above, the test driver script will only * anything that does not fit to the above, the test driver script will only
execute `./test.sh` in the test directory execute `./test.sh` in the test directory
*tests/common:* *tests/common, tests/common.convert:*
*tests/common.convert:*
* script with shell helpers, separated by functionality * script with shell helpers, separated by functionality
@ -146,6 +145,13 @@ the loop devices as they are managed on a per-test basis.
There's a script `test-console.sh` that will run shell commands in a loop and There's a script `test-console.sh` that will run shell commands in a loop and
logs the output with the testing environment set up. logs the output with the testing environment set up.
### Runtime dependencies
The tests use some common system utilities like `find`, `rm`, `dd`. Additionally,
specific tests need the following packages installed: `acl`, `attr`,
`e2fsprogs`, `reiserfsprogs`
## New test ## New test
1. Pick the category for the new test or fallback to `misc-tests` if not sure. For 1. Pick the category for the new test or fallback to `misc-tests` if not sure. For
@ -162,7 +168,7 @@ begining of `test.sh`. You don't need to add the file to git yet.
4. Write the test commands, comment anything that's not obvious. 4. Write the test commands, comment anything that's not obvious.
5. Test your test. Use the `TEST` variable to jump right to your test: 5. **Test your test.** Use the `TEST` variable to jump right to your test:
```shell ```shell
$ make TEST=012\* tests-misc # from top directory $ make TEST=012\* tests-misc # from top directory
$ TEST=012\* ./misc-tests.sh # from tests/ $ TEST=012\* ./misc-tests.sh # from tests/
@ -172,6 +178,7 @@ $ TEST=012\* ./misc-tests.sh # from tests/
fixed the bug (or both). Subject line of the shall mention the name of the fixed the bug (or both). Subject line of the shall mention the name of the
new directory for ease of search, eg. `btrfs-progs: tests: add 012-subvolume-sync-must-wait` new directory for ease of search, eg. `btrfs-progs: tests: add 012-subvolume-sync-must-wait`
### Crafted/fuzzed images ### Crafted/fuzzed images
Images that are create by fuzzing or specially crafted to trigger some error Images that are create by fuzzing or specially crafted to trigger some error