Skip to content

Commit 2eb1a9f

Browse files
authored
GlobalAPI: clarify key path behavior
1 parent bd1c6db commit 2eb1a9f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

website/versioned_docs/version-29.7/GlobalAPI.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ Use `describe.each` if you keep duplicating the same test suites with different
250250
- `%#` - Index of the test case.
251251
- `%%` - single percent sign ('%'). This does not consume an argument.
252252
- Or generate unique test titles by injecting properties of test case object with `$variable`
253-
- To inject nested object values use you can supply a keyPath i.e. `$variable.path.to.value`
253+
- To inject nested object values use you can supply a keyPath i.e. `$variable.path.to.value` (only works for ["own" properites](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/hasOwnProperty), e.g. `$obj.constructor.name` wouldn't work)
254254
- You can use `$#` to inject the index of the test case
255255
- You cannot use `$variable` with the `printf` formatting except for `%%`
256256
- `fn`: `Function` the suite of tests to be run, this is the function that will receive the parameters in each row as function arguments.

0 commit comments

Comments
 (0)