mirror of
https://github.com/apache/superset.git
synced 2026-05-12 11:25:56 +00:00
fix(table chart): render bigint value in a raw mode (#34556)
(cherry picked from commit 8700a0b939)
This commit is contained in:
committed by
Michael S. Molina
parent
d1ded45633
commit
8828e59dca
@@ -305,6 +305,27 @@ describe('plugin-chart-table', () => {
|
||||
expect(cells[4]).toHaveTextContent('$ 2.47k');
|
||||
});
|
||||
|
||||
it('render data with a bigint value in a raw record mode', () => {
|
||||
render(
|
||||
ProviderWrapper({
|
||||
children: (
|
||||
<TableChart
|
||||
{...transformProps(testData.bigint)}
|
||||
sticky={false}
|
||||
isRawRecords
|
||||
/>
|
||||
),
|
||||
}),
|
||||
);
|
||||
const cells = document.querySelectorAll('td');
|
||||
expect(document.querySelectorAll('th')[0]).toHaveTextContent('name');
|
||||
expect(document.querySelectorAll('th')[1]).toHaveTextContent('id');
|
||||
expect(cells[0]).toHaveTextContent('Michael');
|
||||
expect(cells[1]).toHaveTextContent('4312');
|
||||
expect(cells[2]).toHaveTextContent('John');
|
||||
expect(cells[3]).toHaveTextContent('1234567890123456789');
|
||||
});
|
||||
|
||||
it('render raw data', () => {
|
||||
const props = transformProps({
|
||||
...testData.raw,
|
||||
|
||||
Reference in New Issue
Block a user