renames jest files to match new convention

This commit is contained in:
bergquist
2018-09-11 14:09:08 +02:00
parent abd5a74e4c
commit 6ba5550f5f
@@ -13,7 +13,11 @@ describe('grafana data source', () => {
};
const templateSrvStub = {
replace: val => val.replace('$var', 'replaced')
replace: val => {
return val
.replace('$var2', 'replaced|replaced2')
.replace('$var', 'replaced');
}
};
const ds = new GrafanaDatasource(backendSrvStub, q, templateSrvStub);
@@ -32,6 +36,21 @@ describe('grafana data source', () => {
});
});
describe('with tags that have multi value template variables', () => {
const options = setupAnnotationQueryOptions(
{tags: ['$var2']}
);
beforeEach(() => {
return ds.annotationQuery(options);
});
it('should interpolate template variables in tags in query options', () => {
expect(calledBackendSrvParams.tags[0]).toBe('replaced');
expect(calledBackendSrvParams.tags[1]).toBe('replaced2');
});
});
describe('with type dashboard', () => {
const options = setupAnnotationQueryOptions(
{