(url)
| 174 | } |
| 175 | |
| 176 | async function testRequestError(url) { |
| 177 | const requestWillBeSentFuture = once(session, 'Network.requestWillBeSent') |
| 178 | .then(([event]) => verifyRequestWillBeSent(event, { url, method: 'GET' })); |
| 179 | session.on('Network.responseReceived', common.mustNotCall()); |
| 180 | session.on('Network.loadingFinished', common.mustNotCall()); |
| 181 | |
| 182 | const loadingFailedFuture = once(session, 'Network.loadingFailed') |
| 183 | .then(([event]) => verifyLoadingFailed(event)); |
| 184 | |
| 185 | fetch(url, { |
| 186 | headers: requestHeaders, |
| 187 | }).catch(common.mustCall()); |
| 188 | |
| 189 | await requestWillBeSentFuture; |
| 190 | await loadingFailedFuture; |
| 191 | } |
| 192 | |
| 193 | const testNetworkInspection = async () => { |
| 194 | // HTTP |
no test coverage detected
searching dependent graphs…