Expanded class hierarchy of TraversableStringTest
class TraversableStringTest extends \PHPUnit_Framework_TestCase {
public function testString() {
$foo = new TraversableString('foo', array(
'foo',
'bar',
));
$this
->assertEquals('foo', (string) $foo);
}
public function testArray() {
$foo = new TraversableString('foo', array(
'foo',
'bar',
));
$values = array();
foreach ($foo as $value) {
$values[] = $value;
}
$this
->assertEquals(array(
'foo',
'bar',
), $values);
}
}
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
TraversableStringTest:: |
public | function | ||
TraversableStringTest:: |
public | function |