Files
Creeer-Web/components/sections/__tests__/Cierre.test.tsx
T
erikgh b3bd698e9b fix: a11y (gold-deep token AA, Disciplinas ul/li, Cierre nav) + scaffold cleanup
- Add gold-deep #7A5F15 token (~5.97:1 on white, WCAG AA) for small-text eyebrows
- Apply text-gold-deep to 4 eyebrows (Hero, Disciplinas, ComoEmpezar, Estratega)
- Disciplinas: div grid → semantic ul/li for screen-reader consistency
- Cierre: wrap contact links in <nav aria-label="Contacto">
- Estratega: portrait gradient → Tailwind tokens (from-ink to-gold), drop inline hex
- Delete unused Geist fonts (app/fonts/, ~134KB)
- Replace default README with creeer README
- Tests: +2 structural (Disciplinas ul/li, Cierre nav aria-label)
2026-07-22 10:06:46 -06:00

24 lines
997 B
TypeScript

import { render, screen } from '@testing-library/react';
import { describe, it, expect } from 'vitest';
import { Cierre } from '../Cierre';
describe('<Cierre />', () => {
it('renders the closing quote', () => {
render(<Cierre />);
expect(screen.getByText(/Devuélvele claridad/i)).toBeInTheDocument();
});
it('renders 3 contact links with correct hrefs', () => {
render(<Cierre />);
const wa = screen.getByRole('link', { name: /whatsapp/i });
const mail = screen.getByRole('link', { name: /email/i });
const li = screen.getByRole('link', { name: /linkedin/i });
expect(wa.getAttribute('href')).toMatch(/^https:\/\/wa\.me\//);
expect(mail.getAttribute('href')).toMatch(/^mailto:/);
expect(li.getAttribute('href')).toMatch(/^https:\/\/(www\.)?linkedin\./);
});
it('wraps contact links in a nav with aria-label="Contacto"', () => {
render(<Cierre />);
expect(screen.getByRole('navigation', { name: /contacto/i })).toBeInTheDocument();
});
});