function _size($list) { return Underscore::size($list); }
/** * @dataProvider peopleDataProvider * @tags collections */ public function testSize($people, $type, $meta) { // it should count the number of items in any list $this->integer(_::size($people))->isEqualTo(5); // it should be able to count scalar (even if it mean nothing...) $this->integer(_::size("hello"))->isEqualTo(1); // it should return 0 for null $this->integer(_::size(null))->isIdenticalTo(0); }