feat: CTA orientação no WhatsApp para indecisos (MAN-127)
All checks were successful
CI / static (pull_request) Successful in 2m25s
CI / unit (pull_request) Successful in 3m4s
CI / feature (pull_request) Successful in 2m53s
CI / container (pull_request) Successful in 1m13s
CI / browser (pull_request) Successful in 5m58s

Banda de modalidades passa a abrir wa.me com mensagem distinta (fallback /briefing). Glossário canônico vive em SPEC.md §8.0.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-13 23:16:05 -03:00
parent dfd9763029
commit 70d19a7c55
9 changed files with 122 additions and 48 deletions

View File

@@ -213,7 +213,26 @@ class HomePageContentTest extends TestCase
false,
)
->assertSee('target="_blank"', false)
->assertDontSee(route('briefing', ['servico_interesse' => 'Grand Jour']), false);
->assertDontSee(route('briefing', ['servico_interesse' => 'Grand Jour']), false)
->assertSee(
'https://wa.me/5511988887777?text='.rawurlencode('Olá, ainda não sei qual modalidade de acompanhamento combina com o meu casamento e gostaria de orientação da Amare.'),
false,
);
}
public function test_orientation_cta_falls_back_to_briefing_without_whatsapp_number(): void
{
SiteSetting::instance()->update(['whatsapp_number' => null]);
$response = $this->get(route('home'));
$response
->assertOk()
->assertSee('href="'.route('briefing').'"', false)
->assertDontSee(
'Olá, ainda não sei qual modalidade de acompanhamento combina com o meu casamento e gostaria de orientação da Amare.',
false,
);
}
public function test_corporate_steps_and_placeholder_render_from_settings(): void

View File

@@ -50,4 +50,18 @@ class ServicesPageCtaTest extends TestCase
->assertSee('href="'.route('briefing', ['servico_interesse' => 'Essenza']).'"', false)
->assertDontSee('wa.me/', false);
}
public function test_orientation_cta_uses_distinct_whatsapp_message_when_a_number_is_configured(): void
{
SiteSetting::instance()->update(['whatsapp_number' => '+55 11 98888-7777']);
$response = $this->get(route('services.index'));
$response
->assertOk()
->assertSee(
'https://wa.me/5511988887777?text='.rawurlencode('Olá, ainda não sei qual modalidade de acompanhamento combina com o meu casamento e gostaria de orientação da Amare.'),
false,
);
}
}