/** * @return void */ public function testPrependPushesValueToTopOfContainer() { $this->container['foo'] = 'bar'; $this->container->prepend('baz'); $expected = array('baz', 'foo' => 'bar'); $array = $this->container->getArrayCopy(); $this->assertSame($expected, $array); }
/** * Prepend data * @param string $prepend * @return \RtHeadtitle\Controller\Plugin\HeadTitle */ public function prepend($prepend) { $this->container->prepend($prepend); return $this; }