Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import { config } from 'dotenv';
- config();
- import { expect } from 'chai';
- import { getOneTaxAuthorityById } from '../../taxAuthCodes/getOneTaxAuthorityById';
- import { updateFederalTaxAuthorityById } from '../updateFederalTaxAuthorityById';
- describe('Test suite for updateFederalTaxAuthorityById', () => {
- it('should update a row', async () => {
- const id = '00';
- const updateName = 'FEDERAL GOVERNMENT';
- const preUpdateName = 'TEST';
- const row = await getOneTaxAuthorityById(id);
- expect(row).to.have.property('peoId');
- expect(row).to.have.property('id');
- expect(row).to.have.property('name');
- await updateFederalTaxAuthorityById(id, preUpdateName);
- const preUpdateRow = await getOneTaxAuthorityById(id);
- await updateFederalTaxAuthorityById(id, updateName);
- const updatedRow = await getOneTaxAuthorityById(id);
- expect(preUpdateRow).to.not.equal(updatedRow);
- });
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement