Example #1
0
 /**
  * @param $file
  * @param $remove
  *
  * @covers ::add
  * @covers ::rm
  * @covers ::getPath
  * @covers ::output
  * @covers ::history
  * @depends testCreatingFiles
  * @dataProvider filesProvider
  */
 public function testAddingAndRemoving($file, $remove)
 {
     $counter = count(self::$git->history());
     $this->assertEmpty(self::$git->add($file)->output());
     $this->assertCount(++$counter, self::$git->history());
     if ($remove) {
         $this->assertStringStartsWith(sprintf("rm '%s'", $file), self::$git->rm($file)->output());
         $this->assertCount(++$counter, self::$git->history());
     }
 }