diff mbox series

btrfs-progs: tests: mkfs/011: Fix path for rootdir

Message ID 1576564610.3899.20.camel@suse.com (mailing list archive)
State New, archived
Headers show
Series btrfs-progs: tests: mkfs/011: Fix path for rootdir | expand

Commit Message

An Long Dec. 17, 2019, 6:36 a.m. UTC
Documentation folder path is wrong on exported testsutie. Fix this by
replace TOP with INTERNAL_BIN.

Signed-off-by: An Long <lan@suse.com>
---
 tests/mkfs-tests/011-rootdir-create-file/test.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--

Comments

David Sterba Dec. 18, 2019, 4:19 p.m. UTC | #1
On Tue, Dec 17, 2019 at 06:36:51AM +0000, Long An wrote:
> Documentation folder path is wrong on exported testsutie. Fix this by
> replace TOP with INTERNAL_BIN.

It feels wrong that the tests use INTERNAL_BIN but it obviously exists
and works so I'll apply the patch but maybe this could use some cleanup.
Thanks.
Qu Wenruo Dec. 20, 2019, 6:09 a.m. UTC | #2
On 2019/12/19 上午12:19, David Sterba wrote:
> On Tue, Dec 17, 2019 at 06:36:51AM +0000, Long An wrote:
>> Documentation folder path is wrong on exported testsutie. Fix this by
>> replace TOP with INTERNAL_BIN.
> 
> It feels wrong that the tests use INTERNAL_BIN but it obviously exists
> and works so I'll apply the patch but maybe this could use some cleanup.
> Thanks.
> 

The patch itself is kinda OK, but I guess we'd better to have some file
generation function to test mkfs.btrfs --rootdir.

Thanks,
Qu
diff mbox series

Patch

diff --git a/tests/mkfs-tests/011-rootdir-create-file/test.sh b/tests/mkfs-tests/011-rootdir-create-file/test.sh
index 20f7c4ce..a21c6245 100755
--- a/tests/mkfs-tests/011-rootdir-create-file/test.sh
+++ b/tests/mkfs-tests/011-rootdir-create-file/test.sh
@@ -10,6 +10,6 @@  check_prereq mkfs.btrfs
 tmp=$(mktemp -d --tmpdir btrfs-progs-mkfs.rootdirXXXXXXX)
 # we can't use TEST_DEV, a file is needed
 img=$(mktemp btrfs-progs-mkfs.rootdirXXXXXXX)
-run_check "$TOP/mkfs.btrfs" -f --rootdir "$TOP/Documentation/" "$img"
+run_check "$TOP/mkfs.btrfs" -f --rootdir "$INTERNAL_BIN/Documentation/" "$img"
 
 rm -rf -- "$img"