Skip to content

Commit

Permalink
Fix process path issue (#121)
Browse files Browse the repository at this point in the history
  • Loading branch information
jesseleite authored Nov 25, 2024
1 parent 86fe776 commit 0854880
Show file tree
Hide file tree
Showing 5 changed files with 1 addition and 13 deletions.
2 changes: 1 addition & 1 deletion src/Configurator.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public function normalize()

$this->preparePhpCsFixer();

Process::run(['vendor/bin/php-cs-fixer', 'fix', $path, '--rules', $rules]);
Process::run([getcwd().'/vendor/bin/php-cs-fixer', 'fix', $path, '--rules', $rules]);

return $this;
}
Expand Down
3 changes: 0 additions & 3 deletions tests/ConfiguratorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace Tests;

use Facades\Statamic\Console\Processes\Process;
use Statamic\Facades\Path;
use Statamic\Migrator\Configurator;

Expand All @@ -15,8 +14,6 @@ public function setUp(): void
$this->files->copy(__DIR__.'/Fixtures/config/configurator-test.php', $this->path());

$this->configurator = Configurator::file('statamic/configurator-test.php');

Process::swap(new \Statamic\Console\Processes\Process(__DIR__.'/../'));
}

protected function path()
Expand Down
3 changes: 0 additions & 3 deletions tests/MigrateAssetContainerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace Tests;

use Facades\Statamic\Console\Processes\Process;
use Statamic\Facades\Path;
use Statamic\Migrator\Configurator;
use Statamic\Migrator\YAML;
Expand All @@ -15,8 +14,6 @@ public function setUp(): void
parent::setUp();

$this->configurator = Configurator::file('filesystems.php');

Process::swap(new \Statamic\Console\Processes\Process(__DIR__.'/../'));
}

protected function paths()
Expand Down
3 changes: 0 additions & 3 deletions tests/MigrateSettingsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace Tests;

use Facades\Statamic\Console\Processes\Process;
use Illuminate\Support\Facades\File;

class MigrateSettingsTest extends TestCase
Expand All @@ -20,8 +19,6 @@ public function setUp(): void
{
parent::setUp();

Process::swap(new \Statamic\Console\Processes\Process(__DIR__.'/../'));

$this->files->copy(__DIR__.'/Fixtures/routes/web.php', $this->paths('routesFile'));
}

Expand Down
3 changes: 0 additions & 3 deletions tests/MigrateSiteTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace Tests;

use Facades\Statamic\Console\Processes\Process;
use Statamic\Facades\Path;
use Statamic\Migrator\Configurator;
use Statamic\Migrator\YAML;
Expand Down Expand Up @@ -55,8 +54,6 @@ protected function setUp(): void
$this->files->copyDirectory(__DIR__.'/Fixtures/site', base_path('site'));
$this->files->copyDirectory(__DIR__.'/Fixtures/assets', base_path('assets'));
$this->files->copy(__DIR__.'/Fixtures/routes/web.php', $this->paths('routesFile'));

Process::swap(new \Statamic\Console\Processes\Process(__DIR__.'/../'));
}

/** @test */
Expand Down

0 comments on commit 0854880

Please sign in to comment.