chore: Refactor configuration files based on Laravel 10 skeleton
This commit is contained in:
parent
3f78d5118a
commit
bebbfec510
35 changed files with 205 additions and 284 deletions
|
@ -65,7 +65,7 @@ class FeedsTest extends TestCase
|
|||
'author' => [
|
||||
'type' => 'card',
|
||||
'name' => config('user.displayname'),
|
||||
'url' => config('app.longurl'),
|
||||
'url' => config('url.longurl'),
|
||||
],
|
||||
'children' => [[
|
||||
'type' => 'entry',
|
||||
|
@ -126,7 +126,7 @@ class FeedsTest extends TestCase
|
|||
'author' => [
|
||||
'type' => 'card',
|
||||
'name' => config('user.displayname'),
|
||||
'url' => config('app.longurl'),
|
||||
'url' => config('url.longurl'),
|
||||
],
|
||||
'children' => [[
|
||||
'type' => 'entry',
|
||||
|
|
|
@ -11,28 +11,28 @@ class ShortURLsControllerTest extends TestCase
|
|||
/** @test */
|
||||
public function shortDomainRedirectsToLongDomain(): void
|
||||
{
|
||||
$response = $this->get('https://' . config('app.shorturl'));
|
||||
$response = $this->get('https://' . config('url.shorturl'));
|
||||
$response->assertRedirect(config('app.url'));
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function shortDomainSlashAtRedirectsToTwitter(): void
|
||||
{
|
||||
$response = $this->get('https://' . config('app.shorturl') . '/@');
|
||||
$response = $this->get('https://' . config('url.shorturl') . '/@');
|
||||
$response->assertRedirect('https://twitter.com/jonnybarnes');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function shortDomainSlashTRedirectsToLongDomainSlashNotes(): void
|
||||
{
|
||||
$response = $this->get('https://' . config('app.shorturl') . '/t/E');
|
||||
$response = $this->get('https://' . config('url.shorturl') . '/t/E');
|
||||
$response->assertRedirect(config('app.url') . '/notes/E');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function shortDomainSlashBRedirectsToLongDomainSlashBlog(): void
|
||||
{
|
||||
$response = $this->get('https://' . config('app.shorturl') . '/b/1');
|
||||
$response = $this->get('https://' . config('url.shorturl') . '/b/1');
|
||||
$response->assertRedirect(config('app.url') . '/blog/s/1');
|
||||
}
|
||||
}
|
||||
|
|
|
@ -123,7 +123,7 @@ class NotesTest extends TestCase
|
|||
{
|
||||
$note = Note::factory()->make();
|
||||
$note->id = 14;
|
||||
$this->assertEquals(config('app.shorturl') . '/notes/E', $note->shorturl);
|
||||
$this->assertEquals(config('url.shorturl') . '/notes/E', $note->shorturl);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
|
|
|
@ -54,7 +54,7 @@ class PlacesTest extends TestCase
|
|||
$place = Place::factory()->create([
|
||||
'name' => 'The Bridgewater Pub',
|
||||
]);
|
||||
$this->assertEquals(config('app.shorturl') . '/places/the-bridgewater-pub', $place->shorturl);
|
||||
$this->assertEquals(config('url.shorturl') . '/places/the-bridgewater-pub', $place->shorturl);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue