Fix post-registration 404, add speaker management, and simplify event creation.
Deploy Ladill Events / deploy (push) Successful in 28s
Deploy Ladill Events / deploy (push) Successful in 28s
Proxy registration transaction paths on Events, add a join button on the confirmation page, introduce speaker roster management, and replace the QR design wizard with merchant-style create/show flows. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\Feature;
|
||||
|
||||
use App\Models\QrCode;
|
||||
use App\Models\QrEventRegistration;
|
||||
use App\Models\User;
|
||||
use Illuminate\Foundation\Testing\RefreshDatabase;
|
||||
use Tests\TestCase;
|
||||
|
||||
class EventRegistrationConfirmationTest extends TestCase
|
||||
{
|
||||
use RefreshDatabase;
|
||||
|
||||
public function test_confirmed_page_renders_for_valid_registration(): void
|
||||
{
|
||||
$owner = User::create([
|
||||
'public_id' => 'usr_reg_confirm',
|
||||
'name' => 'Event Owner',
|
||||
'email' => 'owner-reg-confirm@example.com',
|
||||
]);
|
||||
|
||||
$event = QrCode::create([
|
||||
'user_id' => $owner->id,
|
||||
'short_code' => 'webinar-demo',
|
||||
'type' => QrCode::TYPE_EVENT,
|
||||
'label' => 'Product webinar',
|
||||
'payload' => [
|
||||
'content' => [
|
||||
'name' => 'Product webinar',
|
||||
'format' => 'virtual',
|
||||
'virtual_sessions' => [
|
||||
['join_url' => 'https://meet.ladill.com/r/demo-room'],
|
||||
],
|
||||
],
|
||||
'style' => [],
|
||||
],
|
||||
'is_active' => true,
|
||||
]);
|
||||
|
||||
QrEventRegistration::create([
|
||||
'qr_code_id' => $event->id,
|
||||
'user_id' => $owner->id,
|
||||
'reference' => 'QRE-TESTREF123456',
|
||||
'badge_code' => 'BADGE123',
|
||||
'tier_name' => 'General admission',
|
||||
'amount_minor' => 0,
|
||||
'currency' => 'GHS',
|
||||
'attendee_name' => 'Jane Doe',
|
||||
'attendee_email' => 'jane@example.com',
|
||||
'attendee_phone' => '+233200000000',
|
||||
'status' => QrEventRegistration::STATUS_CONFIRMED,
|
||||
]);
|
||||
|
||||
$this->get('/q/webinar-demo/registered/QRE-TESTREF123456', [
|
||||
'X-Ladill-Internal' => '1',
|
||||
])
|
||||
->assertOk()
|
||||
->assertSee('Jane Doe', false)
|
||||
->assertSee('BADGE123', false)
|
||||
->assertSee('Join webinar', false)
|
||||
->assertSee('https://meet.ladill.com/r/demo-room', false);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user