Skip to content

Commit

Permalink
Only config locally
Browse files Browse the repository at this point in the history
  • Loading branch information
Tofandel committed Jun 20, 2024
1 parent b69b541 commit 4adabf4
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ abstract class TestCase extends PHPUnitTestCase
private $tempTestDir;
private $initialGlobalHookDir;

private $shouldSignGpg;

final public function setUp(): void
{
$this->initialGlobalHookDir = global_hook_dir();
Expand All @@ -25,8 +23,7 @@ final public function setUp(): void
mkdir($this->tempTestDir);
chdir($this->tempTestDir);
shell_exec('git init');
$this->shouldSignGpg = shell_exec('git config --global commit.gpgsign false');
shell_exec('git config --global commit.gpgsign false');
shell_exec('git config commit.gpgsign false');
shell_exec('git config user.email "cghooks@example.com"');
shell_exec('git config user.name "Composer Git Hooks"');

Expand All @@ -39,7 +36,6 @@ final public function setUp(): void

final public function tearDown(): void
{
shell_exec('git config --global commit.gpgsign '.$this->shouldSignGpg);
chdir('..');
self::rmdir($this->tempTestDir);
$this->restoreGlobalHookDir();
Expand Down

0 comments on commit 4adabf4

Please sign in to comment.