public function Framework_AssertTest::testAssertChildrenContentAttributes

@covers PHPUnit_Framework_Assert::assertTag

File

drupal/core/vendor/phpunit/phpunit/Tests/Framework/AssertTest.php, line 3277

Class

Framework_AssertTest
@package PHPUnit @author Sebastian Bergmann <sebastian@phpunit.de> @author Bernhard Schussek <bschussek@2bepublished.at> @copyright 2001-2013 Sebastian Bergmann <sebastian@phpunit.de> @license …

Code

public function testAssertChildrenContentAttributes() {
  $matcher = array(
    'id' => 'test_children',
    'content' => 'My Children',
    'attributes' => array(
      'class' => 'children',
    ),
    'children' => array(
      'less_than' => '25',
      'greater_than' => '2',
      'only' => array(
        'tag' => 'div',
        'attributes' => array(
          'class' => 'my_child',
        ),
      ),
    ),
  );
  $this
    ->assertTag($matcher, $this->html);
}