chore: commit current workspace changes
This commit is contained in:
@@ -10,7 +10,9 @@ use App\Models\Artwork;
|
||||
use App\Models\Group;
|
||||
use App\Models\GroupChallenge;
|
||||
use App\Services\HomepageService;
|
||||
use App\Services\Worlds\WorldService;
|
||||
use Illuminate\Support\Carbon;
|
||||
use Illuminate\Support\Facades\Cache;
|
||||
use Illuminate\Support\Str;
|
||||
use Inertia\Testing\AssertableInertia;
|
||||
use cPad\Plugins\News\Models\NewsArticle;
|
||||
@@ -98,6 +100,25 @@ it('renders public worlds index and detail pages', function (): void {
|
||||
->where('world.slug', 'summer-slam-2026'));
|
||||
});
|
||||
|
||||
it('returns a relative latest world navigation link regardless of request host', function (): void {
|
||||
Cache::forget('worlds.navigation_campaign');
|
||||
|
||||
$world = publicWorld([
|
||||
'title' => 'Hello Again',
|
||||
'slug' => 'hello-again',
|
||||
'campaign_priority' => 999,
|
||||
]);
|
||||
|
||||
$this->get('https://fooyd0.skinbase.org/worlds')
|
||||
->assertOk();
|
||||
|
||||
$campaign = app(WorldService::class)->navigationCampaign();
|
||||
|
||||
expect($campaign)->not->toBeNull()
|
||||
->and($campaign['title'])->toBe('Hello Again')
|
||||
->and($campaign['url'])->toBe('/worlds/hello-again');
|
||||
});
|
||||
|
||||
it('includes rewarded contributors on public world pages', function (): void {
|
||||
$creator = User::factory()->create([
|
||||
'username' => 'rewardedcreator-' . Str::lower(Str::random(6)),
|
||||
|
||||
Reference in New Issue
Block a user