fix(curriculum): Update test to accept solution with semicolon also (#53596)

Co-authored-by: Krzysztof G. <60067306+gikf@users.noreply.github.com>
This commit is contained in:
Korada Shanmukh Sai
2024-02-08 10:49:24 +05:30
committed by GitHub
parent 3b2cb6391d
commit 44fb7c7c01

View File

@@ -32,7 +32,7 @@ assert.match(code, /\[\s*\.\.\.addToCartBtns\s*\]\s*\.\s*forEach\s*\(\s*(?:\(\s*
You should add an empty callback function to the event listener. Remember to give it an `event` parameter.
```js
assert.match(code, /\[\s*\.\.\.addToCartBtns\s*\]\s*\.\s*forEach\s*\(\s*(?:\(\s*btn\s*\)|btn)\s*=>\s*\{\s*btn\s*\.\s*addEventListener\s*\(\s*('|"|`)click\1\s*,\s*(\(\s*event\s*\)|event)\s*=>\s*\{\s*\}\s*\)\s*\s*\}\s*\)/);
assert.match(code, /\[\s*\.\.\.addToCartBtns\s*\]\s*\.\s*forEach\s*\(\s*(?:\(\s*btn\s*\)|btn)\s*=>\s*\{\s*btn\s*\.\s*addEventListener\s*\(\s*('|"|`)click\1\s*,\s*(\(\s*event\s*\)|event)\s*=>\s*\{\s*\}\s*\)\s*;?\s*\}\s*\)/);
```
# --seed--