mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-05-28 18:26:54 +00:00
fix(curriculum): updated challenge tests (#60076)
This commit is contained in:
+4
-4
@@ -14,25 +14,25 @@ Inside your `.cat-ears` element, create two `div` elements with the classes `cat
|
||||
You should not change the existing `div` element with the class `cat-ears`.
|
||||
|
||||
```js
|
||||
assert(document.querySelectorAll('div.cat-ears').length === 1);
|
||||
assert.lengthOf(document.querySelectorAll('div.cat-ears'), 1);
|
||||
```
|
||||
|
||||
You should create two `div` elements inside your `.cat-ears` element.
|
||||
|
||||
```js
|
||||
assert(document.querySelectorAll('.cat-ears div').length === 2);
|
||||
assert.lengthOf(document.querySelectorAll('.cat-ears div'), 2);
|
||||
```
|
||||
|
||||
Your first `div` element should have the class `cat-left-ear`.
|
||||
|
||||
```js
|
||||
assert(document.querySelectorAll('.cat-ears div')[0]?.classList.contains('cat-left-ear'));
|
||||
assert.isTrue(document.querySelectorAll('.cat-ears div')[0]?.classList.contains('cat-left-ear'));
|
||||
```
|
||||
|
||||
Your second `div` element should have the class `cat-right-ear`.
|
||||
|
||||
```js
|
||||
assert(document.querySelectorAll('.cat-ears div')[1]?.classList.contains('cat-right-ear'));
|
||||
assert.isTrue(document.querySelectorAll('.cat-ears div')[1]?.classList.contains('cat-right-ear'));
|
||||
```
|
||||
|
||||
# --seed--
|
||||
|
||||
Reference in New Issue
Block a user