PHPUnit_Framework_Assert::assertAttributeCount

Asserts the number of elements of an array, Countable or Traversable that is stored in an attribute.