]>
git.proxmox.com Git - mirror_zfs.git/blob - tests/zfs-tests/tests/functional/cli_root/zfs_sysfs/zfs_sysfs_live.ksh
17ac8f8a1a4b41f34d654571bd08431b6a6d211b
5 # The contents of this file are subject to the terms of the
6 # Common Development and Distribution License (the "License").
7 # You may not use this file except in compliance with the License.
9 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 # or http://www.opensolaris.org/os/licensing.
11 # See the License for the specific language governing permissions
12 # and limitations under the License.
14 # When distributing Covered Code, include this CDDL HEADER in each
15 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 # If applicable, add the following below this CDDL HEADER, with the
17 # fields enclosed by brackets "[]" replaced with your own identifying
18 # information: Portions Copyright [yyyy] [name of copyright owner]
24 # Copyright (c) 2018 by Delphix. All rights reserved.
27 .
$STF_SUITE/include
/libtest.shlib
31 # Test if the expected '/sys/module/zfs/<dir>/<attr>' are present
34 verify_runnable
"global"
37 log_unsupported
"sysfs is linux-only"
40 claim
="Expected '/sys/module/zfs/<dir>/<attr>' attributes are present"
42 feature_attr
="/sys/module/zfs/features.pool/org.open-zfs:large_blocks/guid"
43 pool_prop__attr
="/sys/module/zfs/properties.pool/comment/values"
44 ds_prop__attr
="/sys/module/zfs/properties.dataset/recordsize/values"
48 log_must
cat $feature_attr
49 log_must
cat $pool_prop__attr
50 log_must
cat $ds_prop__attr
52 # force a read of all the attributes for show func code coverage
53 log_must
grep -R "[a-z]" /sys
/module
/zfs
/features.
*
54 log_must
grep -R "[a-z]" /sys
/module
/zfs
/properties.
*
55 log_mustnot
grep -RE "[^[:print:]]" /sys
/module
/zfs
/properties.
*