/** * @expectedException \Hansel23\Dictionaries\Exceptions\InvalidKeyException */ public function testAccessingUnsettedItemThrowsException() { $dictionary = new Dictionary(gettype(2), gettype('string')); $dictionary->add(1, 'First'); foreach ($dictionary as $key => $value) { $dictionary->offsetUnset($key); $dictionary->offsetGet($key); } }
public function __construct() { $stringTypeName = gettype(''); parent::__construct($stringTypeName, $stringTypeName); }