fix(referrals): restore existing hosted referral CTA and remove native placeholder

This commit is contained in:
DeCentN2Madness committed 2026-11-01 18:10:51 -07:00
1 parent 85def8466c
commit 5c8ba2e11e
7 files changed
+27 -11

No files matched your search

+6 -1
View File
@@ -548,7 +548,7 @@ test('Phase 5A conversion CTAs resolve to the intended published local route or
['/es/aba-therapy', 'Solicitar una consulta', '/es/client-consultation'],
['/es/autism-evaluations', 'Solicitar una consulta', '/es/client-consultation'],
['/es/learner-social-club', 'Solicitar una consulta', '/es/client-consultation'],
['/referrals', 'Refer a Client', '#form-title'],
['/referrals', 'Refer a Client', 'https://form.jotform.com/231638510219149'],
['/aba-therapy-intake-process', 'Take the First Step', '/client-consultation'],
['/es/aba-therapy-intake-process', 'Take the First Step', '/es/client-consultation'],
['/services', 'Consult with a Client Advocate', '/client-consultation'],
@@ -563,6 +563,11 @@ test('Phase 5A conversion CTAs resolve to the intended published local route or
assert.equal(link.length, 1, `${route}: ${label}`);
assert.equal(link.attr('href'), href, route);
const target = new URL(href, site + route);
if (target.origin !== new URL(site).origin) {
assert.equal(route, '/referrals', 'only the explicitly approved referral CTA leaves the site');
assert.equal(target.href, 'https://form.jotform.com/231638510219149');
continue;
}
const destination = page(target.pathname);
if (target.hash) assert.equal(destination(`[id="${target.hash.slice(1)}"]`).length, 1, href);
}