mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-06-19 21:09:51 +08:00
feat(curriculum): add test to check anchor text (#57375)
This commit is contained in:
parent
f1d5f2ea41
commit
eb775d45db
@ -17,6 +17,12 @@ You should use the existing anchor element, do not create a new one.
|
||||
assert.lengthOf(document.querySelectorAll('a'), 1);
|
||||
```
|
||||
|
||||
The text inside the anchor element should not change, it must be `cat photos`.
|
||||
|
||||
```js
|
||||
assert.strictEqual(document.querySelector('a').innerText, "cat photos");
|
||||
```
|
||||
|
||||
You should have the words `See more ` before the anchor element. Make sure you include the space after the last word.
|
||||
|
||||
```js
|
||||
|
||||
@ -17,6 +17,12 @@ You should use the existing anchor element, do not create a new one.
|
||||
assert.lengthOf(document.querySelectorAll('a'), 1);
|
||||
```
|
||||
|
||||
The text inside the anchor element should not change, it must be `cat photos`.
|
||||
|
||||
```js
|
||||
assert.strictEqual(document.querySelector('a').innerText, "cat photos");
|
||||
```
|
||||
|
||||
You should have the words `See more ` before the anchor element.
|
||||
|
||||
```js
|
||||
|
||||
Loading…
Reference in New Issue
Block a user