/** * Test adding element to collection * * @return void */ public function testAdd() { $collection = $this->collection->add(7); $this->assertCount(4, $this->collection); $this->assertEquals(7, $this->collection->get(3)); $this->assertSame($this->collection, $collection); }
/** * Add new process to the queue * * @param Process $process * @return $this */ public function add(Process $process) { $this->queue->add($process); return $this; }