Merge commit 'f8f4ea6ad3ad12a6d41fd4e6c3ec44c4eeb65f3d'
Improves gdisk_test.sh script
This commit is contained in:
3
Makefile
3
Makefile
@@ -28,6 +28,9 @@ sgdisk: $(LIB_OBJS) sgdisk.o gptcl.o
|
|||||||
fixparts: $(MBR_LIB_OBJS) fixparts.o
|
fixparts: $(MBR_LIB_OBJS) fixparts.o
|
||||||
$(CXX) $(MBR_LIB_OBJS) fixparts.o $(LDFLAGS) -o fixparts
|
$(CXX) $(MBR_LIB_OBJS) fixparts.o $(LDFLAGS) -o fixparts
|
||||||
|
|
||||||
|
test:
|
||||||
|
./gdisk_test.sh
|
||||||
|
|
||||||
lint: #no pre-reqs
|
lint: #no pre-reqs
|
||||||
lint $(SRCS)
|
lint $(SRCS)
|
||||||
|
|
||||||
|
|||||||
@@ -115,9 +115,23 @@ Y
|
|||||||
w
|
w
|
||||||
Y
|
Y
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
ret=$?
|
||||||
|
if [ $ret -ne 0 ]
|
||||||
|
then
|
||||||
|
pretty_print "FAILED" "gdisk return $ret when creating partition table"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
sgdisk)
|
sgdisk)
|
||||||
$SGDISK_BIN $TEMP_DISK -${OPT_CLEAR}
|
$SGDISK_BIN $TEMP_DISK -${OPT_CLEAR}
|
||||||
|
|
||||||
|
ret=$?
|
||||||
|
if [ $ret -ne 0 ]
|
||||||
|
then
|
||||||
|
pretty_print "FAILED" "sgdisk return $ret when creating partition table"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
@@ -354,7 +368,7 @@ EOF
|
|||||||
###################################
|
###################################
|
||||||
|
|
||||||
# create a file to simulate a real device
|
# create a file to simulate a real device
|
||||||
dd if=/dev/zero of=$TEMP_DISK bs=1024 count=$TEMP_DISK_SIZE
|
dd if=/dev/zero of=$TEMP_DISK bs=1024 count=$TEMP_DISK_SIZE > /dev/null 2>&1
|
||||||
|
|
||||||
if [ -s $TEMP_DISK ]
|
if [ -s $TEMP_DISK ]
|
||||||
then
|
then
|
||||||
|
|||||||
Reference in New Issue
Block a user