Files
twenty/front/src/interfaces/person.interface.test.ts
T
Anders Borch 8ed09d61ef Refactor GraphqlPerson to GraphqlQueryPerson
A GraphqlQueryPerson has an id which is used in mutations.
2023-04-25 12:55:27 +02:00

24 lines
482 B
TypeScript

import { mapPerson } from './person.interface';
describe('mapPerson', () => {
it('should map person', () => {
const person = mapPerson({
id: 1,
firstname: 'John',
lastname: 'Doe',
email: '',
phone: '',
city: '',
created_at: '',
company: {
__typename: '',
id: 1,
company_name: '',
company_domain: '',
},
__typename: '',
});
expect(person.fullName).toBe('John Doe');
});
});