File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -46,6 +46,7 @@ OPTION:
4646 --extra-skip-list-suffixes SEMICOLON-SEPARATED LIST OF SUFFIXES
4747 --select-from-file SELECTFILE
4848 --test-expr EXPRESSION
49+ --debug-fail
4950"
5051
5152err () {
@@ -88,6 +89,7 @@ SKIP_PIP=false
8889SKIP_PYTORCH=false
8990TEST_UNSKIP=false
9091TEST_FILTER_EXPRESSION=" "
92+ TEST_DEBUG_FAIL=false
9193
9294while (( $# != 0 )) ; do
9395 case " $1 " in
@@ -279,6 +281,10 @@ while (( $# != 0 )); do
279281 TEST_FILTER_EXPRESSION=" $2 "
280282 shift 2
281283 ;;
284+ --debug-fail)
285+ TEST_DEBUG_FAIL=true
286+ shift
287+ ;;
282288 --help)
283289 echo " $HELP "
284290 exit 0
@@ -376,6 +382,10 @@ run_pytest_command() {
376382 pytest_args+=(" -k" " $pytest_expr " )
377383 fi
378384
385+ if [[ " $TEST_DEBUG_FAIL " == true ]]; then
386+ pytest_args+=(" --pdb" )
387+ fi
388+
379389 if [[ -n " $TRITON_TEST_SELECTFILE " ]] || [[ -n " $pytest_expr " ]]; then
380390 if pytest " ${pytest_args[@]} " --collect-only > /dev/null 2>&1 ; then
381391 pytest " ${pytest_args[@]} "
You can’t perform that action at this time.
0 commit comments