Commit 609b0fa4 by Patrick O'Carroll

added a test

parent 5e484e83
......@@ -54,7 +54,6 @@ describe('SaveDashboardModal', () => {
{
current: {
selected: true,
//tags: Array(0),
text: 'server_002',
value: 'server_002',
},
......@@ -86,5 +85,44 @@ describe('SaveDashboardModal', () => {
expect(modal.timeChange).toBe(false);
expect(modal.variableChange).toBe(false);
});
it('should hide variable checkboxes', () => {
let fakeDashboardSrv = {
dash: {
templating: {
list: [
{
current: {
selected: true,
text: 'server_002',
value: 'server_002',
},
name: 'Server',
},
{
current: {
selected: true,
text: 'web_002',
value: 'web_002',
},
name: 'Web',
},
],
},
originalTemplating: [
{
current: {
selected: true,
text: 'server_002',
value: 'server_002',
},
name: 'Server',
},
],
},
};
let modal = new SaveDashboardModalCtrl(fakeDashboardSrv);
expect(modal.variableChange).toBe(false);
});
});
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment