Clean up mtree keyword support a slight bit and add a few more default keywords
- Parameterize the mtree keywords as $DEFAULT_MTREE_KEYWORDS - Test with the extra mtree keywords, `mode,gid,uid`. - Add a note about mtrees with time support not working with makefs right now MFC after: 1 week Sponsored by: EMC / Isilon Storage Division
This commit is contained in:
parent
c34d46ff59
commit
c213f0dbec
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=290267
@ -113,7 +113,7 @@ from_mtree_spec_file_body()
|
||||
create_test_inputs
|
||||
|
||||
atf_check -e empty -o save:$TEST_SPEC_FILE -s exit:0 \
|
||||
mtree -c -k type,link,size -p $TEST_INPUTS_DIR
|
||||
mtree -c -k "$DEFAULT_MTREE_KEYWORDS" -p $TEST_INPUTS_DIR
|
||||
cd $TEST_INPUTS_DIR
|
||||
atf_check -e empty -o empty -s exit:0 \
|
||||
$MAKEFS $TEST_IMAGE $TEST_SPEC_FILE
|
||||
|
@ -105,7 +105,7 @@ from_mtree_spec_file_body()
|
||||
create_test_inputs
|
||||
|
||||
atf_check -e empty -o save:$TEST_SPEC_FILE -s exit:0 \
|
||||
mtree -c -k type,link,size -p $TEST_INPUTS_DIR
|
||||
mtree -c -k "$DEFAULT_MTREE_KEYWORDS" -p $TEST_INPUTS_DIR
|
||||
|
||||
cd $TEST_INPUTS_DIR
|
||||
atf_check -e empty -o not-empty -s exit:0 \
|
||||
|
@ -29,6 +29,13 @@
|
||||
|
||||
KB=1024
|
||||
: ${TMPDIR=/tmp}
|
||||
# TODO: add mtree `time` support; get a lot of errors like this right now when
|
||||
# passing generating disk images with keyword mtree support, like:
|
||||
#
|
||||
# `[...]/mtree.spec:8: error: time: invalid value '1446458503'`
|
||||
#
|
||||
#DEFAULT_MTREE_KEYWORDS="type,mode,gid,uid,size,link,time"
|
||||
DEFAULT_MTREE_KEYWORDS="type,mode,gid,uid,size,link"
|
||||
TEST_IMAGE="$TMPDIR/test.img"
|
||||
TEST_INPUTS_DIR="$TMPDIR/inputs"
|
||||
TEST_MD_DEVICE_FILE="$TMPDIR/md.output"
|
||||
@ -39,7 +46,7 @@ check_image_contents()
|
||||
{
|
||||
local directories=$TEST_INPUTS_DIR
|
||||
local excludes mtree_excludes_arg mtree_file
|
||||
local mtree_keywords="type,link,size"
|
||||
local mtree_keywords="$DEFAULT_MTREE_KEYWORDS"
|
||||
|
||||
while getopts "d:f:m:X:" flag; do
|
||||
case "$flag" in
|
||||
|
Loading…
Reference in New Issue
Block a user