SimpleTestFunctionalTest::stubTest

7 simpletest.test SimpleTestFunctionalTest::stubTest()
8 simpletest.test SimpleTestFunctionalTest::stubTest()

Test to be run and the results confirmed.

File

modules/simpletest/simpletest.test, line 157
Tests for simpletest.module.

Code

function stubTest() {
  $this->pass($this->pass);
  $this->fail($this->fail);

  $this->drupalCreateUser(array($this->valid_permission));
  $this->drupalCreateUser(array($this->invalid_permission));

  $this->pass(t('Test ID is @id.', array('@id' => $this->testId)));

  // Generates a warning.
  $i = 1 / 0;

  // Call an assert function specific to that class.
  $this->assertNothing();

  // Generates a warning inside a PHP function.
  array_key_exists(NULL, NULL);

  debug('Foo', 'Debug');
}
Login or register to post comments