| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent dcba374 commit ff212f4
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -37,3 +37,7 @@ channel.publish(input); | |||
| 37 | 37 | // Should not publish after subscriber is unsubscribed | |
| 38 | 38 | channel.unsubscribe(subscriber); | |
| 39 | 39 | assert.ok(!channel.hasSubscribers); | |
| 40 | + | ||
| 41 | + assert.throws(() => { | ||
| 42 | + channel.subscribe(null); | ||
| 43 | + }, { code: 'ERR_INVALID_ARG_TYPE' }); | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -20,3 +20,9 @@ channel.subscribe(common.mustCall((message, name) => { | |||
| 20 | 20 | })); | |
| 21 | 21 | ||
| 22 | 22 | channel.publish(input); | |
| 23 | + | ||
| 24 | + { | ||
| 25 | + assert.throws(() => { | ||
| 26 | + dc.channel(null); | ||
| 27 | + }, /ERR_INVALID_ARG_TYPE/); | ||
| 28 | + } | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments