diff options
author | catch <catch@35733.no-reply.drupal.org> | 2020-11-17 11:45:23 +0000 |
---|---|---|
committer | catch <catch@35733.no-reply.drupal.org> | 2020-11-17 11:45:23 +0000 |
commit | 38144b9ee0090e5b932e29a3ec9660708720e00d (patch) | |
tree | 098fa0fd2166815b1fb6e43b2584077a0e1990b6 /core/tests/Drupal/FunctionalJavascriptTests/BrowserWithJavascriptTest.php | |
parent | 99b763a12ac9cbe49ab099589f5bbb245825567a (diff) | |
download | drupal-38144b9ee0090e5b932e29a3ec9660708720e00d.tar.gz drupal-38144b9ee0090e5b932e29a3ec9660708720e00d.zip |
Issue #3176655 by alexpott, jungle, longwave, ayushmishra206, Gábor Hojtsy, andypost: Deprecate GoutteDriver use in core and use Behat\Mink\Driver\BrowserKitDriver directly instead
Diffstat (limited to 'core/tests/Drupal/FunctionalJavascriptTests/BrowserWithJavascriptTest.php')
-rw-r--r-- | core/tests/Drupal/FunctionalJavascriptTests/BrowserWithJavascriptTest.php | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/core/tests/Drupal/FunctionalJavascriptTests/BrowserWithJavascriptTest.php b/core/tests/Drupal/FunctionalJavascriptTests/BrowserWithJavascriptTest.php index 2372faceb772..8938fa632141 100644 --- a/core/tests/Drupal/FunctionalJavascriptTests/BrowserWithJavascriptTest.php +++ b/core/tests/Drupal/FunctionalJavascriptTests/BrowserWithJavascriptTest.php @@ -2,7 +2,6 @@ namespace Drupal\FunctionalJavascriptTests; -use Behat\Mink\Driver\GoutteDriver; use PHPUnit\Framework\AssertionFailedError; /** @@ -41,6 +40,10 @@ class BrowserWithJavascriptTest extends WebDriverTestBase { }()); JS; $this->assertJsCondition($javascript); + + // Ensure that \Drupal\Tests\UiHelperTrait::isTestUsingGuzzleClient() works + // as expected. + $this->assertFalse($this->isTestUsingGuzzleClient()); } public function testAssertJsCondition() { @@ -151,9 +154,9 @@ JS; $this->metaRefreshCount = 0; } - // Log only for WebDriverTestBase tests because for Goutte we log with - // ::getResponseLogHandler. - if ($this->htmlOutputEnabled && !($this->getSession()->getDriver() instanceof GoutteDriver)) { + // Log only for WebDriverTestBase tests because for DrupalTestBrowser we log + // with ::getResponseLogHandler. + if ($this->htmlOutputEnabled && !$this->isTestUsingGuzzleClient()) { $html_output = 'GET request to: ' . $url . '<hr />Ending URL: ' . $this->getSession()->getCurrentUrl(); $html_output .= '<hr />' . $out; |