Commit Diff


commit - b9d87303f685642215a2ac4216badc0c42489e0b
commit + 31e2cf639f9bcc5ab85206bb3bb21610cf77a761
blob - 56a7ec4735fe0c61640ad50561f09796abd92eb5
blob + 5e69e7a41136867e7c6a7becce542178c8034e37
--- util/got-build-regress.sh
+++ util/got-build-regress.sh
@@ -21,6 +21,7 @@ worktree=$HOME/got
 fromaddr_arg=
 force=0
 gotd=0
+webd=0
 testroot="/tmp"
 
 while getopts b:fGR:r:w: arg; do
@@ -31,6 +32,8 @@ while getopts b:fGR:r:w: arg; do
 			force=1 ;;
 		G)
 			gotd=1 ;;
+		W)
+			webd=1 ;;
 		w)
 			worktree="$OPTARG" ;;
 		r)
@@ -194,6 +197,21 @@ if [ $gotd -ne 0 ]; then
 	fi
 fi
 
+if [ $webd -ne 0 ]; then
+	printf "\n\n\tRunning gotwebd tests\n\n" >> build.log
+	log_cmd regress.log doas env PATH=$HOME/bin:$PATH make webd-regress
+	regress_status=$?
+	cat regress.log >> build.log
+	egrep "test.*failed" regress.log > failures.log
+	regress_failure_grep="$?"
+	if [ "$regress_status" -ne 0 -o "$regress_failure_grep" -eq 0 ]; then
+		printf "\n\n\t Test failures:\n\n" >> build.log
+		cat failures.log >> build.log
+		mail $fromaddr_arg -s "$prog regress failure" $recipients < build.log
+		exit 0
+	fi
+fi
+
 printf "\n\n\tTesting a release build\n\n" >> build.log
 log_cmd build.log make clean
 log_cmd build.log make obj