-imagex capture dir2 new.wim newname
-imagex info dir.wim --boot 0
-! imagex export dir.wim all new.wim --boot
+if ! imagex capture dir2 new.wim newname; then
+ error "Failed to capture test WIM"
+fi
+if ! imagex info dir.wim --boot 0; then
+ error "Failed to clear boot index on test WIM"
+fi
+if imagex export dir.wim all new.wim --boot; then
+ error "Successfully exported multiple images with --boot but with no bootable images"
+fi
+
+echo "**********************************************************"
+echo " Basic imagex tests passed "
+echo "**********************************************************"