Ming-Hung Tsai
16190f0f9a
[tests] Pull out common submodules
...
New modules: fixture, process, program, target, and thin
2021-07-21 17:50:34 +08:00
Ming-Hung Tsai
66b49e6f3d
[tests] Change the path type to OsString for compatibility
2021-07-21 17:27:13 +08:00
Ming-Hung Tsai
6cecf0f673
[file_utils] Check the file type to prevent unexpected writes by thin_repair
2021-07-09 01:22:22 +08:00
Ming-Hung Tsai
87ada9b493
[tests] Add basic tests for cache_dump
2021-07-09 01:22:22 +08:00
Ming-Hung Tsai
f395bab7be
[tests] Use traits to specify test parameters
...
To deal with variety in target attributes and their expected outputs,
the test parameters are categorized into traits, thus the test program
could define test parameters in a more structured way, without having
to pass multiple tightly-coupled parameters to test functions.
2021-07-09 01:22:22 +08:00
Ming-Hung Tsai
12ef69c31b
[tests] Pull out common tests on i/o options into reusable modules
...
- Introduce modules for testing input/output options
- Provide macros for generating test cases
- Hide details of subprocess execution
2021-07-08 22:02:44 +08:00
Ming-Hung Tsai
6660fde3c4
[tests] Refine the test naming and error messages
...
- Make the naming of test cases less ambiguous, e.g., rename
"missing_input_file" to "missing_input_arg" or "input_file_not_found"
- Unify the error messages on input/output options
2021-07-08 01:05:15 +08:00
Kay Lin
c18cd42d35
[build] Update dependencies
...
- Update crc32c to 0.6, which allows it to be built on AArch64.
- Update base64 to 0.13
- Update byteorder to 0.14
- Update io-uring to 0.4
- Update libc to 0.2.83
- Update nix to 0.19
- Update nom to 6.0.1
- Update quick-xml to 0.20
- Update rand to 0.8
- Update tempfile to 3.2
- Update tui to 0.14
Signed-off-by: Kay Lin <i@v2bv.net>
2021-06-26 00:08:58 +08:00
Ming-Hung Tsai
fba2adbe56
[tests] Fix minor test errors
...
- Fix command line arguments
- Adapt error messages for rust implementations
2021-06-21 23:27:51 +08:00
Ming-Hung Tsai
2bd3c17578
[tests] Fix version string checking
2021-06-21 23:27:51 +08:00
Ming-Hung Tsai
bfc7f96d9f
[tests] Enable testing the rust targets
...
This is a temporary solution for development.
Usage: cargo test --features rust_tests
2021-06-21 23:27:51 +08:00
Ming-Hung Tsai
5ecae3ad88
[tests] Fix numeric literal annotation
2021-05-28 03:19:42 +08:00
Ming-Hung Tsai
b7bf82b8f2
[all] Fix newline in version string
2021-05-12 12:03:52 +08:00
Ming-Hung Tsai
5baeab4a5c
Merge branch 'main' into rust-cache-tools
2021-05-11 23:16:08 +08:00
Ming-Hung Tsai
43e433149b
[all] Apply cargo fmt
2021-05-04 16:10:23 +08:00
Ming-Hung Tsai
74fcb9d505
[cache (rust)] Fix data types
2021-02-26 23:31:12 +08:00
Ming-Hung Tsai
8d59a83f7c
[functional-tests] Update thin_delta help text
2021-01-12 02:50:46 +08:00
Ming-Hung Tsai
1fe8a0dbde
[thin_check] Allow using --clear-needs-check and --skip-mappings together
...
Although it is not recommended to clear the flag without a full
examination, however, the usage has been documented as an approach
to reduce lvchange run time [1]. For the purpose of backward
compatibility and avoiding boot failure after upgrading thin_check [2],
the limitation is now removed.
[1] https://wiki.archlinux.org/index.php/LVM#Thinly-provisioned_root_volume_device_times_out
[2] Community feedback on previous commit:
https://github.com/jthornber/thin-provisioning-tools/commit/b278f4f
2020-11-24 18:17:36 +08:00
Joe Thornber
e9fbcc31de
[thin_dump (rust)] First pass at thin_dump.
...
Doesn't include --repair.
This includes <def> and <ref> sections for shared regions.
2020-09-28 15:45:13 +01:00
Joe Thornber
7834d661e2
[thin_check (rust)] auto repair space map leaks
2020-08-19 14:31:01 +01:00
Joe Thornber
7466cd7182
[functional-tests (rust)] TestDir now creates dir in ./
...
O_DIRECT doesn't work with /tmp/
2020-08-14 10:54:31 +01:00
Joe Thornber
2fa732a93c
[functional tests] Port some of Hank's sh tests to Rust.
...
Run with 'cargo test'
2020-08-13 14:20:29 +01:00
Joe Thornber
c254ebe384
[functional-tests] Port 3 --auto-repair tests from Scheme to Rust
2020-08-12 13:03:01 +01:00
Joe Thornber
5a16f21199
[functional tests] Fixup a few tests that broke when we bumped the version nr.
2020-08-12 12:33:16 +01:00
Joe Thornber
8f76371bb2
[functional-tests] Fix clippy warnings
2020-08-07 15:41:21 +01:00
Joe Thornber
fa4ea3e2d9
[functional-tests] port some of the cache_check tests to Rust
2020-08-07 14:30:00 +01:00
Joe Thornber
904d9b0c84
[functional-tests] port thin_metadata_unpack tests to Rust.
...
cargo test
2020-08-05 10:00:44 +01:00
Joe Thornber
d2678fdf27
[functional-tests] port thin_metadata_pack tests to Rust.
...
cargo test
2020-08-05 09:09:18 +01:00
Joe Thornber
23568aaa11
[functional-tests] port thin_delta tests to rust.
...
cargo test
2020-08-05 08:24:52 +01:00
Joe Thornber
4ac428128a
[functional-tests (rust)] port thin_repair tests to rust.
...
cargo test
2020-08-04 11:30:46 +01:00
Joe Thornber
cdf19b2454
[functional-tests (rust)] remove comment
2020-08-03 11:00:09 +01:00
Joe Thornber
39822a7165
[functional-tests (rust)] squash warnings
2020-08-03 10:59:19 +01:00
Joe Thornber
9552cb4817
[functional-tests] Port thin_rmap tests to Rust.
...
cargo test
2020-08-03 10:47:03 +01:00
Joe Thornber
ad29fe65fa
[functional-tests] Use thin_restore macro
2020-07-31 16:34:04 +01:00
Joe Thornber
baf1fe325f
[functional-tests] Move thin_dump tests to Rust.
...
cargo test
2020-07-31 16:31:10 +01:00
Joe Thornber
78db9a24fa
[functional-tests (rust)] factor out TestDir
2020-07-31 14:26:22 +01:00
Joe Thornber
084a26bf85
[functional-tests] Recode thin_restore tests in Rust.
...
Now part of 'cargo test'
2020-07-31 12:12:40 +01:00
Joe Thornber
fcfcc60b89
[functional-tests] Move thin_check functional tests to Rust.
...
They'll be run as part of 'cargo test' now.
2020-07-31 11:04:12 +01:00
Joe Thornber
32019ac388
[thin_shrink] add a trivial snapshot test.
...
Still need much more work on snap tests.
2020-07-22 16:07:34 +01:00
Joe Thornber
470d0b7532
[thin_shrink] more test cases
2020-07-01 07:52:53 +01:00
Joe Thornber
4d7f9c7ddc
[thin_shrink] add some more test cases
2020-06-30 08:32:04 +01:00
Joe Thornber
3618da3a12
[thin_shrink] Get test framework built
...
This verifies data has been moved to the correct place.
2020-06-29 10:49:40 +01:00
Joe Thornber
d03dac8f75
[thin_shrink] write test harness
2020-06-26 16:44:47 +01:00