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 2b9b78e commit 5c6ece9Copy full SHA for 5c6ece9
tests/wploadersuite/AjaxTest.php
@@ -26,11 +26,15 @@ public function testAjaxCallbackWillFailIfNumberNotOnlyOnceIsInvalid(): void
26
{
27
$response = null;
28
try {
29
+ global $wpdb;
30
+ $wpdb->suppress_errors = true; // Due to a WooCommerce activation issue in older versions.
31
$this->_handleAjax('test_ajax_action');
32
} catch (\WPAjaxDieContinueException) {
33
$response = json_decode($this->_last_response);
34
}
35
36
+ $wpdb->suppress_errors = false;
37
+
38
$this->assertNotNull($response);
39
$this->assertFalse($response->success);
40
$this->assertEquals('Number not only once is invalid', $response->data);
0 commit comments