fix(curriculum): stop false positives in test for array hard coding (#42461)
* Fixed test regex to avoid false matches * Changed regex to only match values in globalArray * Revert non-English changes
This commit is contained in:
@ -40,7 +40,7 @@ assert(
|
|||||||
`nonMutatingSort(globalArray)` should not be hard coded.
|
`nonMutatingSort(globalArray)` should not be hard coded.
|
||||||
|
|
||||||
```js
|
```js
|
||||||
assert(!nonMutatingSort.toString().match(/[23569]/g));
|
assert(!nonMutatingSort.toString().match(/\[.*?[23569].*?\]/gs));
|
||||||
```
|
```
|
||||||
|
|
||||||
The function should return a new array, not the array passed to it.
|
The function should return a new array, not the array passed to it.
|
||||||
|
Reference in New Issue
Block a user