mirror of
https://github.com/apache/superset.git
synced 2026-04-16 14:45:21 +00:00
perf: Optimize performance of Results and Samples tables on Explore (#12257)
This commit is contained in:
committed by
GitHub
parent
76b06b215f
commit
fd15dff60e
@@ -23,7 +23,6 @@ import {
|
||||
buildV1ChartDataPayload,
|
||||
getExploreUrl,
|
||||
getExploreLongUrl,
|
||||
getDataTablePageSize,
|
||||
shouldUseLegacyApi,
|
||||
getSimpleSQLExpression,
|
||||
} from 'src/explore/exploreUtils';
|
||||
@@ -202,20 +201,6 @@ describe('exploreUtils', () => {
|
||||
});
|
||||
});
|
||||
|
||||
describe('getDataTablePageSize', () => {
|
||||
it('divides samples data into pages dynamically', () => {
|
||||
let pageSize;
|
||||
pageSize = getDataTablePageSize(500);
|
||||
expect(pageSize).toEqual(20);
|
||||
pageSize = getDataTablePageSize(0);
|
||||
expect(pageSize).toEqual(50);
|
||||
pageSize = getDataTablePageSize(1);
|
||||
expect(pageSize).toEqual(10000);
|
||||
pageSize = getDataTablePageSize(1000000);
|
||||
expect(pageSize).toEqual(5);
|
||||
});
|
||||
});
|
||||
|
||||
describe('buildV1ChartDataPayload', () => {
|
||||
it('generate valid request payload despite no registered buildQuery', () => {
|
||||
const v1RequestPayload = buildV1ChartDataPayload({
|
||||
|
||||
Reference in New Issue
Block a user