diff --git a/testsuite/expect/inc21.30.5 b/testsuite/expect/inc21.30.5
index 2a4187c6a26930353b8625a86df4bcddc1fb6d42..ffc0ec3adeb905b146f238343835e819ac60399a 100644
--- a/testsuite/expect/inc21.30.5
+++ b/testsuite/expect/inc21.30.5
@@ -28,7 +28,7 @@
 # Test MaxCpus limits
 proc inc21_30_5 {} {
 
-	global salloc acct number srun bin_sleep maxcpu_num
+	global salloc acct number srun bin_sleep maxcpu_num exit_code
 
 	send_user "\nStarting MaxCPUs limit test (Within: inc21.30.5)\n\n"
 	set job_id1 0
diff --git a/testsuite/expect/inc21.30.6 b/testsuite/expect/inc21.30.6
index 1fb093182d7c8f238a3c6f952e67d0481709180a..2bb4438a0eb3339f8d23ed92e448723cf63e085a 100644
--- a/testsuite/expect/inc21.30.6
+++ b/testsuite/expect/inc21.30.6
@@ -28,7 +28,7 @@
 # Test MaxNode limit
 proc inc21_30_6 {} {
 
-	global salloc acct number srun job_id1 bin_sleep maxnode_num
+	global salloc acct number srun job_id1 bin_sleep maxnode_num exit_code
 
 	send_user "\nStarting MaxNode limit test (Within: inc21.30.6)\n\n"
 	set job_id1 0