You are here

public function GeolocationCommonMapAjaxJavascriptTest::testCommonMap in Geolocation Field 8.3

Same name and namespace in other branches
  1. 8 tests/src/FunctionalJavascript/GeolocationCommonMapAjaxJavascriptTest.php \Drupal\Tests\geolocation\FunctionalJavascript\GeolocationCommonMapAjaxJavascriptTest::testCommonMap()
  2. 8.2 tests/src/FunctionalJavascript/GeolocationCommonMapAjaxJavascriptTest.php \Drupal\Tests\geolocation\FunctionalJavascript\GeolocationCommonMapAjaxJavascriptTest::testCommonMap()

Tests the CommonMap style.

File

tests/src/FunctionalJavascript/GeolocationCommonMapAjaxJavascriptTest.php, line 113

Class

GeolocationCommonMapAjaxJavascriptTest
Tests the common map style AJAX JavaScript functionality.

Namespace

Drupal\Tests\geolocation\FunctionalJavascript

Code

public function testCommonMap() {
  $this
    ->drupalGet('geolocation-common-map-ajax-test');
  $this
    ->assertSession()
    ->elementExists('css', '.geolocation-map-container');
  $this
    ->assertSession()
    ->elementExists('css', '.geolocation-location');

  // If Google works, either gm-style or gm-err-container will be present.
  $this
    ->assertSession()
    ->elementExists('css', '.geolocation-map-container [class^="gm-"]');
}