We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 99a3fb8 commit 27f2bc8Copy full SHA for 27f2bc8
cypress/support/commands/api_commands.js
@@ -71,9 +71,10 @@ const setRequestIntercepted = (value) =>
71
/**
72
* Gets the current value of the request interception flag from Cypress environment.
73
* This flag indicates whether a request matching an intercept pattern was detected.
74
- * @returns {boolean} The current value of the request interception flag
+ * @returns {boolean} The current value of the request interception flag, by default returns false
75
*/
76
-const getRequestIntercepted = () => Cypress.env('wasRequestIntercepted');
+const getRequestIntercepted = () =>
77
+ Cypress.env('wasRequestIntercepted') || false;
78
79
80
* Custom command to intercept API calls and wait for them to complete.
0 commit comments