Skip to content

Commit 4ba6892

Browse files
committed
docs: remove unmock func from docs
1 parent 699c0e5 commit 4ba6892

File tree

1 file changed

+0
-28
lines changed

1 file changed

+0
-28
lines changed

docs/test-doubles.md

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -41,34 +41,6 @@ EOF
4141
```
4242
:::
4343

44-
## unmock
45-
46-
> `unmock "function"`
47-
48-
Undo the previous overridden behavior of a callable using mock.
49-
50-
::: code-group
51-
```bash [Example]
52-
function test_example() {
53-
function code() {
54-
ps a | grep bash
55-
}
56-
57-
mock ps<<EOF
58-
PID TTY TIME CMD
59-
13525 pts/7 00:00:01 bash
60-
24162 pts/7 00:00:00 ps
61-
EOF
62-
63-
# At this point, ps will return the mocked value above
64-
assert_equals "13525 pts/7 00:00:01 bash" "$(code)"
65-
66-
# From now on, ps will have the original behaviour again
67-
unmock ps
68-
}
69-
```
70-
:::
71-
7244
## spy
7345
> `spy "function"`
7446

0 commit comments

Comments
 (0)