public async Task ShouldNotThrowInvalidInterceptionIdIfTheRequestWasCancelled() { await Page.SetContentAsync("<iframe></iframe>"); IRoute route = null; await Page.RouteAsync("**/*", (r) => route = r); _ = Page.EvalOnSelectorAsync("iframe", "(frame, url) => frame.src = url", Server.EmptyPage); // Wait for request interception. await Page.WaitForRequestAsync("**/*"); // Delete frame to cause request to be canceled. await Page.EvalOnSelectorAsync("iframe", "frame => frame.remove()"); await route.ContinueAsync(); }