Skip to content

Commit df88415

Browse files
committed
docs: Wrap example code in describe block in README
1 parent 19f34e0 commit df88415

File tree

1 file changed

+22
-20
lines changed

1 file changed

+22
-20
lines changed

README.md

Lines changed: 22 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -73,26 +73,28 @@ There are two method:
7373
Example:
7474

7575
```js
76-
it("assert ([a, b])", () => {
77-
let a = [1, 2];
78-
let b = [1, 2, 3];
79-
a.push(3);
80-
// PASS
81-
assert([a, b]);
82-
});
83-
it("assert (a === b)", () => {
84-
let a = [1, 2];
85-
let b = [1, 2, 3];
86-
a.push(3);
87-
// FAIL
88-
assert(a === b);
89-
});
90-
it("assert (String(a) === String(b))", () => {
91-
let a = [1, 2];
92-
let b = [1, 2, 3];
93-
a.push(3);
94-
// PASS
95-
assert(String(a) === String(b));
76+
describe("Test", () => {
77+
it("assert ([a, b])", () => {
78+
let a = [1, 2];
79+
let b = [1, 2, 3];
80+
a.push(3);
81+
// PASS
82+
assert([a, b]);
83+
});
84+
it("assert (a === b)", () => {
85+
let a = [1, 2];
86+
let b = [1, 2, 3];
87+
a.push(3);
88+
// FAIL
89+
assert(a === b);
90+
});
91+
it("assert (String(a) === String(b))", () => {
92+
let a = [1, 2];
93+
let b = [1, 2, 3];
94+
a.push(3);
95+
// PASS
96+
assert(String(a) === String(b));
97+
});
9698
});
9799
```
98100

0 commit comments

Comments
 (0)