Add mock to test files

This commit is contained in:
Tobias Skarhed
2018-07-04 11:16:31 +02:00
parent 962340bcd1
commit 74bf80962d
4 changed files with 19 additions and 26 deletions

View File

@ -1,13 +1,14 @@
import moment from 'moment';
import { PostgresDatasource } from '../datasource';
import { CustomVariable } from 'app/features/templating/custom_variable';
import { TemplateSrvStub } from 'test/specs/helpers';
describe('PostgreSQLDatasource', function() {
let instanceSettings = { name: 'postgresql' };
let backendSrv = {};
let templateSrv = new TemplateSrvStub();
let templateSrv = {
replace: jest.fn(text => text),
};
let ctx = <any>{
backendSrv,
};