diff options
author | Karel Zak <kzak@redhat.com> | 2010-02-09 16:24:51 +0100 |
---|---|---|
committer | Karel Zak <kzak@redhat.com> | 2010-02-09 16:24:51 +0100 |
commit | a5445cd2e5e1f942384d4fbb4aa66eb7a46df311 (patch) | |
tree | a24cd1387e2e292922b0f127eb9ff1980607e0c0 /tests/ts | |
parent | 5792255b542fe97c1fed77bbd1f8c0bfa7aea1db (diff) | |
download | util-linux-old-a5445cd2e5e1f942384d4fbb4aa66eb7a46df311.tar.gz |
tests: fix and update old fdisk tests
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'tests/ts')
-rwxr-xr-x | tests/ts/fdisk/doslabel | 24 | ||||
-rwxr-xr-x | tests/ts/fdisk/oddinput | 2 | ||||
-rwxr-xr-x | tests/ts/fdisk/sunlabel | 16 |
3 files changed, 21 insertions, 21 deletions
diff --git a/tests/ts/fdisk/doslabel b/tests/ts/fdisk/doslabel index a7c259ea..762cdaac 100755 --- a/tests/ts/fdisk/doslabel +++ b/tests/ts/fdisk/doslabel @@ -37,63 +37,63 @@ FDISK_CMD_DELETE_EXTENDED="d\n2\n" # delete second primary ts_log "Initialize empty image" TEST_IMAGE_NAME=$(ts_image_init 10) -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 # need to run init twice, to change system ID after new label, otherwise system # ID will be random and will screw up md5's ts_log "Create new DOS partition table" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_CREATE_DOSLABEL}${FDISK_CMD_INIT}${FDISK_CMD_WRITE_CLOSE}" \ | $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Create primary partition" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_CREATE_PRIMARY}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Set partition type" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_CHANGE_PARTTYPE}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Set primary partition active" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_SET_ACTIVE}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Re-create primary partition" echo -e "${FDISK_CMD_INIT}d\n${FDISK_CMD_CREATE_PRIMARY}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Create extended partition" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_CREATE_EXTENDED}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Create logical partitions" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_CREATE_LOGICAL}${FDISK_CMD_CREATE_LOGICAL}${FDISK_CMD_CREATE_LOGICAL}${FDISK_CMD_CREATE_LOGICAL}${FDISK_CMD_WRITE_CLOSE}" \ | $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Delete logical partitions" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_DELETE_LOGICALS}${FDISK_CMD_WRITE_CLOSE}" \ | $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Create another logical partition" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_CREATE_LOGICAL}${FDISK_CMD_WRITE_CLOSE}" \ | $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Delete primary partition" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_DELETE_PRIMARY}${FDISK_CMD_WRITE_CLOSE}" \ | $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Delete extended partition" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_DELETE_EXTENDED}${FDISK_CMD_WRITE_CLOSE}" \ | $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_finalize diff --git a/tests/ts/fdisk/oddinput b/tests/ts/fdisk/oddinput index c8698416..9d5c4762 100755 --- a/tests/ts/fdisk/oddinput +++ b/tests/ts/fdisk/oddinput @@ -24,7 +24,7 @@ ts_init "$*" ts_log "Initialize empty image" TEST_IMAGE_NAME=$(ts_image_init 10) -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Empty image listing" # this should report empty partition table # TEST_IMAGE_NAME has absolute path, and is by definition different on each computer, we need to sed it away diff --git a/tests/ts/fdisk/sunlabel b/tests/ts/fdisk/sunlabel index 9c2b0188..6bf7e0ed 100755 --- a/tests/ts/fdisk/sunlabel +++ b/tests/ts/fdisk/sunlabel @@ -34,41 +34,41 @@ FDISK_CMD_CREATE_SECONDARY="n\n2\n128\n\n" # create secondary partition cylinder ts_log "Initialize empty image" TEST_IMAGE_NAME=$(ts_image_init 10) -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Create new SUN partition table" echo -e "${FDISK_CMD_INIT}${FDISK_CMD_DELETEALL}${FDISK_CMD_WRITE_CLOSE}" \ | $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Create first partition" echo -e "${FDISK_CMD_CREATE_PRIMARY}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Set partition sysid" echo -e "${FDISK_CMD_CHANGE_SYSID}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Set first partition readonly" echo -e "${FDISK_CMD_TOGGLE_READONLY}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Set first partition mountable" echo -e "${FDISK_CMD_TOGGLE_MOUNTABLE}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Create second partition" echo -e "${FDISK_CMD_CREATE_SECONDARY}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_log "Delete all partitions" echo -e "${FDISK_CMD_DELETEALL}${FDISK_CMD_WRITE_CLOSE}" | \ $TS_CMD_FDISK ${TEST_IMAGE_NAME} &> /dev/null -ts_image_md5sum 2>&1 >> $TS_OUTPUT +ts_image_md5sum >> $TS_OUTPUT 2>&1 ts_finalize |