/**
  * @param Builder $builder
  * @param $matches
  */
 protected function handleMetaData(Builder $builder, $matches)
 {
     if (intval($matches[7]) != 0) {
         // we are not on TAG commit, add "dev" and git commit hash as pre release part
         $preRelease = array_merge($builder->getPreRelease(), array('dev', $matches[8]));
         $builder->setPreRelease($preRelease);
     }
 }
 public function testSetPreRelease()
 {
     $pre = array('pre', '1');
     $this->assertSame($this->builder, $this->builder->setPreRelease($pre));
     $this->assertEquals($pre, $this->builder->getPreRelease());
 }