mirror of
https://github.com/apache/superset.git
synced 2026-04-21 00:54:44 +00:00
chore: Drill to detail Modal tests (#21148)
* Add DrillDetailModal test * Add DrillDetailPane tests * Add TableControls test * Lint * Enhance SliceHeaderControls tests * Update superset-frontend/src/dashboard/components/DrillDetailPane/TableControls.test.tsx Co-authored-by: Michael S. Molina <70410625+michael-s-molina@users.noreply.github.com> * Update superset-frontend/src/dashboard/components/DrillDetailPane/TableControls.test.tsx Co-authored-by: Michael S. Molina <70410625+michael-s-molina@users.noreply.github.com> * Update superset-frontend/src/dashboard/components/DrillDetailPane/TableControls.test.tsx Co-authored-by: Michael S. Molina <70410625+michael-s-molina@users.noreply.github.com> * Update superset-frontend/src/dashboard/components/DrillDetailPane/TableControls.test.tsx Co-authored-by: Michael S. Molina <70410625+michael-s-molina@users.noreply.github.com> * Update superset-frontend/src/dashboard/components/DrillDetailPane/TableControls.test.tsx Co-authored-by: Michael S. Molina <70410625+michael-s-molina@users.noreply.github.com> Co-authored-by: Michael S. Molina <70410625+michael-s-molina@users.noreply.github.com>
This commit is contained in:
@@ -236,3 +236,23 @@ test('Should "Enter fullscreen"', () => {
|
||||
userEvent.click(screen.getByText('Enter fullscreen'));
|
||||
expect(props.handleToggleFullSize).toBeCalledTimes(1);
|
||||
});
|
||||
|
||||
test('Drill to detail modal is under featureflag', () => {
|
||||
// @ts-ignore
|
||||
global.featureFlags = {
|
||||
[FeatureFlag.DRILL_TO_DETAIL]: false,
|
||||
};
|
||||
const props = createProps();
|
||||
renderWrapper(props);
|
||||
expect(screen.queryByText('Drill to detail')).not.toBeInTheDocument();
|
||||
});
|
||||
|
||||
test('Should show the "Drill to detail"', () => {
|
||||
// @ts-ignore
|
||||
global.featureFlags = {
|
||||
[FeatureFlag.DRILL_TO_DETAIL]: true,
|
||||
};
|
||||
const props = createProps();
|
||||
renderWrapper(props);
|
||||
expect(screen.getByText('Drill to detail')).toBeInTheDocument();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user