complete story 14.1

This commit is contained in:
Naser Mansour
2026-01-09 16:51:55 +02:00
parent 6504327ed7
commit 972af7a127
6 changed files with 201 additions and 27 deletions
+80
View File
@@ -0,0 +1,80 @@
<?php
test('home page is accessible', function () {
$this->get('/')
->assertOk();
});
test('home page displays English tagline when locale is English', function () {
$this->withSession(['locale' => 'en'])
->get('/')
->assertOk()
->assertSee('Committed to Justice Grounded in Dignity Driven to Advocate');
});
test('home page displays Arabic tagline when locale is Arabic', function () {
$this->withSession(['locale' => 'ar'])
->get('/')
->assertOk()
->assertSee('ملتزمون بالعدالة – متجذرون بالكرامة – مدفوعون للدفاع');
});
test('home page displays English intro text when locale is English', function () {
$this->withSession(['locale' => 'en'])
->get('/')
->assertOk()
->assertSee('Libra for Rights is a legal institution woven from the fabric of society');
});
test('home page displays Arabic intro text when locale is Arabic', function () {
$this->withSession(['locale' => 'ar'])
->get('/')
->assertOk()
->assertSee('ليبرا للحقوق مؤسسة قانونية منسوجة من نسيج المجتمع');
});
test('home page displays Book a Consultation button in English', function () {
$this->withSession(['locale' => 'en'])
->get('/')
->assertOk()
->assertSee('Book a Consultation');
});
test('home page displays Book a Consultation button in Arabic', function () {
$this->withSession(['locale' => 'ar'])
->get('/')
->assertOk()
->assertSee('احجز استشارة');
});
test('home page displays Our Services button in English', function () {
$this->withSession(['locale' => 'en'])
->get('/')
->assertOk()
->assertSee('Our Services');
});
test('home page displays Our Services button in Arabic', function () {
$this->withSession(['locale' => 'ar'])
->get('/')
->assertOk()
->assertSee('خدماتنا');
});
test('home page contains link to booking page', function () {
$this->get('/')
->assertOk()
->assertSee('href="'.route('booking').'"', false);
});
test('home page contains link to services section', function () {
$this->get('/')
->assertOk()
->assertSee('href="#services"', false);
});
test('home page contains services section with id', function () {
$this->get('/')
->assertOk()
->assertSee('id="services"', false);
});