Daniel Hofstetter
49fb72ed21
du: disable test on Android
2023-12-03 14:07:03 +01:00
Daniel Hofstetter
12e61d451c
du: make -l/--count-links work
2023-11-09 16:07:02 +01:00
Daniel Hofstetter
7afb8461cb
du: add -H (alias for --dereference-args)
2023-11-07 10:30:54 +01:00
Daniel Hofstetter
bbdde2890a
du: ignore test under Android & FreeBSD
2023-11-05 14:27:20 +01:00
Daniel Hofstetter
29f6631554
du: add -P/--no-dereference
2023-11-03 17:17:44 +01:00
Terts Diepraam
c3f9e19a3b
all: normalize license notice in all *.rs files
2023-08-24 12:21:09 +02:00
Daniel Hofstetter
c99d81a05b
du: fix "unused import" warning on Windows
2023-06-27 15:05:27 +02:00
John Shin
b34e7f7bf6
du: directories have apparent size of 0
2023-06-25 15:56:57 -07:00
Daniel Hofstetter
7730c8171d
du: fix clippy warning in test
2023-04-21 17:01:40 +02:00
Sylvestre Ledru
47cb40c020
du: adjust test_du_basics_bad_name as we made it work
2023-04-13 13:27:04 +02:00
Sylvestre Ledru
eea8d40e78
du: add support of --dereference-args
...
Should fix tests/du/deref.sh
2023-04-13 13:27:04 +02:00
Sylvestre Ledru
5a1d9cec7e
du: an error code when done on a non existing file
2023-04-13 13:27:04 +02:00
Maciej Habasiński
d277603bf1
du: fmt fix
2023-03-26 23:38:31 +02:00
Maciej Habasiński
892f1d910a
test: du invalid threshold
2023-03-26 15:08:56 +02:00
Daniel Hofstetter
0140f4f7d0
tests: fix "unresolved import" warnings on Windows
2023-03-20 16:26:31 +01:00
Daniel Hofstetter
6988eb7ec6
tests: expand wildcard imports
2023-03-20 15:32:35 +01:00
Koki Ueha
0b042f0b32
test_du: fix unnecessary boolean operation
2023-03-19 04:59:08 +00:00
Guilherme Gonçalves
d29119728a
tests/du: run test_du_time with TZ=UTC.
...
du --time formats a file's timestamp according to the local timezone,
but the test implicitly assumed UTC. This caused it to fail when
running locally in my UTC+1 machine.
$ cargo test --features "du touch" --no-default-features
Failure: https://gist.github.com/eggpi/651e01559b7c59e9457c1b22fe4c0c19
2023-03-02 22:14:03 +00:00
Daniel Hofstetter
f6b646e4e5
clippy: fix warnings introduced with Rust 1.67.0
2023-01-27 17:37:56 +01:00
Joining7943
1fadeb43b2
tests/util: Do not trim stderr in CmdResult::stderr_is. Add method stderr_trimmed_is.
...
Fix tests assert whitespace instead of trimming it. Disable some tests in `test_tr` because `tr`
produces too many newlines.
2023-01-22 14:56:19 +01:00
Terts Diepraam
9177cb7b24
all: add tests for usage error exit code
2022-09-10 20:59:42 +02:00
Ackerley Tng
c2bb9596d9
du: update du to use parse_glob::from_str
2022-08-09 10:36:23 +02:00
Daniel Hofstetter
27dd59635a
uucore: add InvalidSuffix to ParseSizeError
2022-05-17 15:37:49 +02:00
Ackerley Tng
88a62c4922
du: use common error methods with show! instead of set_exit_code
2022-05-04 07:33:19 -07:00
Justin Tracey
2a0d58d060
get android builds to compile and pass tests
2022-04-20 08:44:49 +02:00
Sylvestre Ledru
8b719a8591
du: add support for --exclude and --exclude-from ( #3381 )
...
* du: add support for --exclude and --exclude-from
And add an option --verbose (doesn't exist in GNU)
2022-04-11 22:50:01 +02:00
Sylvestre Ledru
a2cefd9b52
du: Return non zero error code when dealing with permissions errors
...
Nd make the tests/du/no-x.sh & long-sloop.sh pass
2022-04-10 01:47:39 +02:00
Daniel Eades
4f8d1c5fcf
add additional lints
2022-01-31 20:40:47 +01:00
Syukron Rifail M
37c986b005
test_du: ignore unsupported --time=birth
2021-07-19 06:55:11 +07:00
Sylvestre Ledru
2177b8dc37
Merge pull request #2481 from Funky185540/fix/test_du_bytes_nondynamic_on_linux
...
test: du: Skip nondynamic comparison on linux for test_du_bytes
2021-07-09 09:11:52 +02:00
Jan Scheer
14b348dd4b
tests: fix tests for CICD environment
2021-07-08 11:17:18 +02:00
Jan Scheer
31aa8b2062
test_du: refactor use expected_result from common/util.rs
2021-07-07 22:09:01 +02:00
Andreas Hartmann
f64b708410
test: du: Skip nondynamic comparison on linux for test_du_bytes
...
The `test_du_bytes` testcase for the `du --bytes` command is written to perform
a dynamic comparison on linux hosts, i.e. it compares the output of the command
to that of the hosts `du` from the GNU coreutils.
Previously the test was written such that it would *first* perform the dynamic
comparison, and *after that* continue to a static comparison which may fail for
specific hosts that have a filesystem different from what the test expects.
This patch excludes linux hosts from the static comparison to ensure the test
performs only the dynamic comparison.
2021-07-06 19:45:06 +02:00
Syukron Rifail M
27e0507844
du: more tests
2021-06-28 07:51:17 +07:00
Syukron Rifail M
d8a33da5b3
du: add --inodes
2021-06-28 07:51:17 +07:00
Jan Scheer
c0be979611
fix some issues with locale (replace "LANGUAGE" with "LC_ALL")
...
`LANGUAGE=C` is not enough, `LC_ALL=C` is needed as the environment
variable that overrides all the other localization settings.
e.g.
```bash
$ LANGUAGE=C id foobar
id: ‘foobar’: no such user
$ LC_ALL=C id foobar
id: 'foobar': no such user
```
* replace `LANGUAGE` with `LC_ALL` as environment variable in the tests
* fix the the date string of affected uutils
* replace `‘` and `’` with `'`
2021-06-23 11:30:28 +02:00
Syukron Rifail M
bc8415c9db
du: add --dereference
2021-06-17 14:06:41 +07:00
Anup Mahindre
fa12b46c51
tests: Add test for du threshold feature
2021-06-12 19:56:05 +05:30
Jan Scheer
39f5f70f2b
Merge branch 'master' into refactoring_parse_size
2021-06-12 02:24:07 +02:00
Syukron Rifail M
0c364e635b
du: add --one-file-system
2021-06-11 16:18:57 +07:00
Jan Scheer
f8e96150f8
fix clippy warnings and spelling
...
* add some missing LICENSE headers
2021-06-04 15:39:34 +02:00
Jan Scheer
130bf49e5d
Merge branch 'master' of github.com:uutils/coreutils into refactoring_parse_size
2021-06-03 22:32:34 +02:00
Jan Scheer
db3ee61742
du/sort/od/stdbuf: make error handling of SIZE/BYTES/MODE arguments more consistent
...
* od: add stderr info for not yet implemented '--strings' flag
2021-06-03 21:00:03 +02:00
Syukron Rifail M
05aeaf3061
du: fix --time behavior
2021-06-03 08:18:23 +07:00
Jan Scheer
cc659c8572
Merge branch 'master' of github.com:uutils/coreutils into refactoring_parse_size
2021-06-01 12:35:48 +02:00
Jan Scheer
8bf1e33b5d
Merge branch 'master' of github.com:uutils/coreutils into refactoring_parse_size
...
* truncate: use "parse_size" from uucore
* workaround fix for "test_reference"
2021-05-31 19:11:06 +02:00
Roy Ivy III
4e20dedf58
tests ~ refactor/polish spelling (comments, names, and exceptions)
2021-05-31 08:23:57 -05:00
Jan Scheer
f9a088cecf
du: use "parse_size" from uucore
...
* fix stderr to be the same than GNU's `du` in case of invalid SIZE
2021-05-31 15:22:37 +02:00
Sylvestre Ledru
69850942b6
fix a clippy warning
...
WARNING: `cargo clippy`: single-character string constant used as pattern
2021-05-30 16:26:03 +02:00
Sylvestre Ledru
41539df91d
Merge pull request #2280 from jhscheer/symlink_tests
...
Improve symlink/hardlink handling in tests
2021-05-27 09:41:48 +02:00