#!/bin/ksh -p # # This file and its contents are supplied under the terms of the # Common Development and Distribution License ("CDDL"), version 1.0. # You may only use this file in accordance with the terms of version # 1.0 of the CDDL. # # A full copy of the text of the CDDL should have accompanied this # source. A copy of the CDDL is also available via the Internet at # http://www.illumos.org/license/CDDL. # # # Copyright 2017, loli10K . All rights reserved. # . $STF_SUITE/tests/functional/truncate/truncate.cfg . $STF_SUITE/include/libtest.shlib . $STF_SUITE/include/math.shlib # # DESCRIPTION: # Ensure both truncate(2)/ftruncate(2) update target file mtime/ctime attributes # # STRATEGY: # 1. Create a file # 2. Truncate the file # 3. Verify both mtime/ctime are updated # 4. Rinse and repeat for both truncate(2) and ftruncate(2) with various sizes # verify_runnable "both" function verify_truncate #