$BATS_TEST_NAME
–
Function Name of Test
$BATS_TEST_NAME
is the name of the function containing the current test case.
Links
Examples
- Print name of current test function
1 2 3
@test "Example" { echo "Function name: $BATS_TEST_NAME" >&3 }
BashSupport Pro is a shell script IDE with support for bats-core’s $BATS_TEST_NAME – try it now!