Skip to content

Commit

Permalink
Blargh
Browse files Browse the repository at this point in the history
  • Loading branch information
JohnathonKoster committed May 11, 2024
1 parent 5b3e9ab commit f88a565
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 14 deletions.
2 changes: 1 addition & 1 deletion tests/BaseTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ protected function getEnvironmentSetUp($app)
$app['config']->set('statamic.sites', [
'default' => 'en',
'sites' => [
'en' => ['name' => 'English', 'locale' => 'en_US', 'url' => 'http://localhost/'],
'default' => ['name' => 'English', 'locale' => 'en_US', 'url' => 'http://localhost/'],
],
]);
$app['config']->set('auth.providers.users.driver', 'statamic');
Expand Down
15 changes: 2 additions & 13 deletions tests/Factories/EntryFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,17 +104,6 @@ public function create()
return tap($this->make())->save();
}

private function getLocale()
{
$version = Statamic::version();

if (Str::startsWith($version, '5')) {
return 'default';
}

return 'en';
}

protected function createCollection()
{
if ($this->collection instanceof StatamicCollection) {
Expand All @@ -123,7 +112,7 @@ protected function createCollection()

return Collection::findByHandle($this->collection)
?? Collection::make($this->collection)
->sites([$this->getLocale()])
->sites(['default'])
->save();
}

Expand All @@ -135,7 +124,7 @@ private function reset()
$this->data = [];
$this->published = true;
$this->order = null;
$this->locale = $this->getLocale();
$this->locale = 'default';
$this->origin = null;
$this->collection = null;
}
Expand Down

0 comments on commit f88a565

Please sign in to comment.