Files
explore/ui/txs/TxsStats.pw.tsx
tom goriunovandGitHub fae4990e1f API resource refactoring (#2699)
* add prefix to API resources

* fix pw tests

* refactor config

* remove unnecessary prefixes in resource names

* fixes

* update screenshots
2025-05-01 15:22:38 +02:00

16 lines
560 B
TypeScript

import React from 'react';
import * as statsMock from 'mocks/stats';
import * as txsStatsMock from 'mocks/txs/stats';
import { test, expect } from 'playwright/lib';
import TxsStats from './TxsStats';
test('base view +@mobile', async({ render, mockApiResponse, mockEnvs }) => {
await mockEnvs([ [ 'NEXT_PUBLIC_STATS_API_HOST', '' ] ]);
await mockApiResponse('general:stats', statsMock.base);
await mockApiResponse('general:txs_stats', txsStatsMock.base);
const component = await render(<TxsStats/>);
await expect(component).toHaveScreenshot();
});