[Toybox] macOS realpath test failures

Rob Landley rob at landley.net
Tue Jan 10 13:46:33 PST 2023


I note I'm building mkroot images for the release so this bugfix won't be in
0.8.9, but Android has its own sync points. :)

On 1/9/23 18:10, enh wrote:
> and here's the ls -lR for it...

This has been on my todo list because I need to make an f2fs filesystem, which
is flash based, so I need to fake up a flash device with an erase block size. (I
did that years ago and need to find my notes. Possibly easiest to do with qemu
instead of that weird annotate-a-block-device driver?)

> FAIL: realpath -s .. eats symlink in $PWD
> echo -ne '' | cd dos && realpath -s ..

The -s says "don't expand symlinks" so logically it means ".." should strip the
last entry off of $PWD instead of traversing the filesystem? (That's why it
expects that output, anyway...)

> --- expected 2023-01-09 21:52:49.611701819 +0000
> +++ actual 2023-01-09 21:52:49.635701818 +0000
> @@ -1 +1 @@
> -/data/local/tmp/toybox-tests-tmp.a8tofxJqRN/realpath
> +/data/local/tmp/toybox-tests-tmp.a8tofxJqRN/realpath/one

The ls contents look right. I'll see if I can set up a test environment later
today...

Rob


More information about the Toybox mailing list