Ticket #3866 (new defect)
building as root breaks the tests
Reported by: | anatoly.borodin | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | Future Releases |
Component: | tests | Version: | master |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Branch state: | no branch | Votes for changeset: |
Description
tests/src/vfs/extfs/helpers-list/mc_parse_ls_l.c contains code to replace the numeric uids and gids with '<<uid>>'/'<<gid>>' if they are equal to the ids of the process. Running the tests as root breaks the tests, because '<<uid>>' / '<<gid>>' appear where 0 are expected.
Looking in tests/src/vfs/extfs/helpers-list/test-suite.log:
... ------------ diff of the expected output vs the actual output: ------------- --- /root/mc/tests/src/vfs/extfs/helpers-list/data/hp48+.output 2017-10-01 21:14:01.070736734 +0000 +++ /tmp/hp48+.actual-parsed-output.l8hNvZZv 2017-10-01 21:14:12.875106282 +0000 @@ -1,3 +1,3 @@ --rw-r--r-- 1 0 0 30 /YEN --rw-r--r-- 1 0 0 21848 /JYTLIGHT --rw-r--r-- 1 0 0 37 /IOPAR +-rw-r--r-- 1 <<uid>> <<gid>> 30 /YEN +-rw-r--r-- 1 <<uid>> <<gid>> 21848 /JYTLIGHT +-rw-r--r-- 1 <<uid>> <<gid>> 37 /IOPAR ------------------------------- end of diff -------------------------------- ...
I don't know if it's intended, or a bug.
Change History
Note: See
TracTickets for help on using
tickets.
PS Some may argue that it's not really a problem: just build mc as a normal user. But building in docker can be tricky, as the default user is 0 there, so you need to either patch the test files, or create a normal user just for the tests...