protected function assertNoGitTag(GitWorkingCopy $repository, $tag)
{
try {
$repository->run(array('rev-parse ' . $tag));
} catch (GitException $e) {
// Expected result. The tag does not exist.
return;
}
throw new \Exception("Expecting that the tag '{$tag}' doesn't exist, but it does.");
}