Example #1
0
 /**
  * @dataProvider existingPathProvider
  */
 public function testStatusModifiedFile($filename)
 {
     // first we need a checkout
     $result = $this->client->checkout($this->checkoutDir);
     // next modify a file
     $tmpfile = $this->checkoutDir . '/' . $filename;
     file_put_contents($tmpfile, uniqid(null, true));
     $this->client->add($filename);
     // stage the change (needed for git)
     $result = $this->client->status();
     $file = new VcsFileInfo(basename($tmpfile), $this->client->getHead());
     $file->setStatus(Status::MODIFIED);
     $expected = array($file);
     $this->assertEquals($expected, $result);
 }