You are here

public function GTMBaseTestCase::testModule in GoogleTagManager 7

Same name and namespace in other branches
  1. 7.2 tests/google_tag.base.test \GTMBaseTestCase::testModule()

Test the module.

File

tests/google_tag.base.test, line 45

Class

GTMBaseTestCase
Tests the Google Tag Manager.

Code

public function testModule() {
  variable_set('google_tag_debug_output', '1');

  // This does not carry through to the gtm_test realm. Why?
  //     variable_set('google_tag_include_environment', '1');
  try {
    $this
      ->createData();
    $this
      ->checkSnippetFiles();
    $this
      ->checkPageResponse();
  } catch (Exception $e) {
    $this
      ->assertTrue(TRUE, t('Inside CATCH block'));
    watchdog_exception('gtm_test', $e);
  } finally {
    $this
      ->assertTrue(TRUE, t('Inside FINALLY block'));
  }
}