public function testOverwriteWithTraversable() { $c = new Collection(array('foo' => 1, 'baz' => 2, 'bar' => 3)); $b = new Collection(array('foo' => 10, 'bar' => 300)); $c->overwriteWith($b->getIterator()); $this->assertEquals(array('foo' => 10, 'baz' => 2, 'bar' => 300), $c->toArray()); }