@@ -3,6 +3,27 @@ import { describe, expect, it } from 'vitest';
|
||||
import { ProcurementPaymentInsights } from '../../resources/js/components/procurement-payment-insights';
|
||||
|
||||
describe('confirmed payment expense', () => {
|
||||
it('describes one confirmed payment in the singular without changing the exact amount', () => {
|
||||
const html = renderToStaticMarkup(
|
||||
<ProcurementPaymentInsights
|
||||
data={{
|
||||
from: null,
|
||||
to: null,
|
||||
coverage: {
|
||||
invoices: 1,
|
||||
indeterminate: 0,
|
||||
confirmed_payments: 1,
|
||||
},
|
||||
currencies: [
|
||||
{ currency: 'MZN', count: 1, amount_minor: '4000' },
|
||||
],
|
||||
}}
|
||||
/>,
|
||||
);
|
||||
expect(html).toContain('1 pagamento confirmado.');
|
||||
expect(html).toContain('40,00 MZN');
|
||||
expect(html).not.toContain('1 pagamentos');
|
||||
});
|
||||
it('shows supplier identity with exact totals and preserves filters in its independent pagination', () => {
|
||||
const html = renderToStaticMarkup(
|
||||
<ProcurementPaymentInsights
|
||||
|
||||
Reference in New Issue
Block a user