Skip to content

Commit e11e41f

Browse files
committed
Update on "[build] Add editable mode unittest"
As titled. To do this we need to refactor the arguments being passed into `setup-linux.sh` `setup-macos.sh` and `unittest-linux.sh` `unittest-macos.sh`. [ghstack-poisoned]
2 parents 133c015 + c0c1f90 commit e11e41f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

.ci/scripts/utils.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -173,15 +173,15 @@ parse_args() {
173173
for ((i=0; i<${#args[@]}; i++)); do
174174
case "${args[$i]}" in
175175
--build-tool)
176-
BUILD_TOOL="${args[$((i+1))]:-}"
176+
BUILD_TOOL="${args[$((i+1))]}"
177177
i=$((i+1))
178178
;;
179179
--build-mode)
180-
BUILD_MODE="${args[$((i+1))]:-Release}"
180+
BUILD_MODE="${args[$((i+1))]}"
181181
i=$((i+1))
182182
;;
183183
--editable)
184-
EDITABLE="${args[$((i+1))]:-false}"
184+
EDITABLE="${args[$((i+1))]}"
185185
i=$((i+1))
186186
;;
187187
*)
@@ -200,14 +200,14 @@ parse_args() {
200200
echo "Require buck2 or cmake for --build-tool, got ${BUILD_TOOL}, exiting..."
201201
exit 1
202202
fi
203-
203+
BUILD_MODE="${BUILD_MODE:-Release}"
204204
if [[ "$BUILD_MODE" =~ ^(Debug|Release)$ ]]; then
205205
echo "Running tests in build mode ${BUILD_MODE} ..."
206206
else
207207
echo "Unsupported build mode ${BUILD_MODE}, options are Debug or Release."
208208
exit 1
209209
fi
210-
210+
EDITABLE="${EDITABLE:-false}"
211211
if [[ $EDITABLE =~ ^(true|false)$ ]]; then
212212
echo "Editable mode is ${EDITABLE} ..."
213213
else

0 commit comments

Comments
 (0)