import React from 'react' import { render, screen } from '../utilities/test-utils' import PersonContact from './_person_contact' const testId = 'personContact' const multipleTestId = 'personContactMultiple' const PersonContactTest = (props) => { return ( <> ) } test('should render custom class and data', () => { render() const kit = screen.getByTestId(testId) expect(kit).toHaveClass('custom-class') }) test('should render id', () => { render() const kit = screen.getByTestId(testId) expect(kit).toHaveProperty('id', testId) }) test('should render aria-label', () => { render() const kit = screen.getByTestId(testId) expect(kit).toHaveAttribute('aria-label', testId) }) test('should render firstName', () => { render() const kit = screen.getByTestId(testId) expect(kit).toHaveTextContent('Jose') }) test('should render lastName', () => { render() const kit = screen.getByTestId(testId) expect(kit).toHaveTextContent('da Silva') }) test('should render contact value', () => { render() const kit = screen.getByTestId(testId) expect(kit).toHaveTextContent('(555) 555-5555') }) test('should render contact detail', () => { render() const kit = screen.getByTestId(testId) expect(kit).toHaveTextContent('Home') }) test('should render multiple contacts', () => { render() const kit = screen.getByTestId(multipleTestId) expect(kit).toHaveTextContent('Brenda Walters') }) test('should render wrong number', () => { render() const kit = screen.getByTestId(multipleTestId) expect(kit).toHaveTextContent('wrong number') })