mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-03-25 22:30:29 -04:00
rework panel to not need platform (#5270)
This commit is contained in:
@@ -10,6 +10,7 @@ import { Dialog, DialogTab } from 'sql/platform/dialog/dialogTypes';
|
||||
import { DialogPane } from 'sql/platform/dialog/dialogPane';
|
||||
import { DialogComponentParams } from 'sql/platform/dialog/dialogContainer.component';
|
||||
import { bootstrapAngular } from 'sql/platform/bootstrap/node/bootstrapService';
|
||||
import { TestThemeService } from 'vs/platform/theme/test/common/testThemeService';
|
||||
|
||||
|
||||
interface BootstrapAngular {
|
||||
@@ -41,7 +42,8 @@ suite('Dialog Pane Tests', () => {
|
||||
bootstrapCalls++;
|
||||
});
|
||||
dialog.content = modelViewId;
|
||||
let dialogPane = new DialogPane(dialog.title, dialog.content, () => undefined, undefined, false);
|
||||
const themeService = new TestThemeService();
|
||||
let dialogPane = new DialogPane(dialog.title, dialog.content, () => undefined, undefined, themeService, false);
|
||||
dialogPane.createBody(container);
|
||||
assert.equal(bootstrapCalls, 1);
|
||||
});
|
||||
@@ -55,7 +57,8 @@ suite('Dialog Pane Tests', () => {
|
||||
bootstrapCalls++;
|
||||
});
|
||||
dialog.content = [new DialogTab('', modelViewId)];
|
||||
let dialogPane = new DialogPane(dialog.title, dialog.content, () => undefined, undefined, false);
|
||||
const themeService = new TestThemeService();
|
||||
let dialogPane = new DialogPane(dialog.title, dialog.content, () => undefined, undefined, themeService, false);
|
||||
dialogPane.createBody(container);
|
||||
assert.equal(bootstrapCalls, 1);
|
||||
});
|
||||
@@ -71,7 +74,8 @@ suite('Dialog Pane Tests', () => {
|
||||
let modelViewId1 = 'test_content_1';
|
||||
let modelViewId2 = 'test_content_2';
|
||||
dialog.content = [new DialogTab('tab1', modelViewId1), new DialogTab('tab2', modelViewId2)];
|
||||
let dialogPane = new DialogPane(dialog.title, dialog.content, valid => dialog.notifyValidityChanged(valid), undefined, false);
|
||||
const themeService = new TestThemeService();
|
||||
let dialogPane = new DialogPane(dialog.title, dialog.content, valid => dialog.notifyValidityChanged(valid), undefined, themeService, false);
|
||||
dialogPane.createBody(container);
|
||||
|
||||
let validityChanges: boolean[] = [];
|
||||
|
||||
Reference in New Issue
Block a user