mirror of
https://github.com/grafana/grafana.git
synced 2024-11-30 04:34:23 -06:00
fix: fix cloudwatch metricFindQuery error that stopped it working completely, fixes #9876
This commit is contained in:
parent
5b674ce29c
commit
119f5427af
@ -333,7 +333,7 @@ function (angular, _, moment, dateMath, kbn, templatingVariable) {
|
||||
};
|
||||
|
||||
return backendSrv.datasourceRequest(options).then(function(result) {
|
||||
return result;
|
||||
return result.data;
|
||||
});
|
||||
};
|
||||
|
||||
|
@ -68,7 +68,7 @@ describe('CloudWatchDatasource', function() {
|
||||
beforeEach(function() {
|
||||
ctx.backendSrv.datasourceRequest = function(params) {
|
||||
requestParams = params.data;
|
||||
return ctx.$q.when(response);
|
||||
return ctx.$q.when({data: response});
|
||||
};
|
||||
});
|
||||
|
||||
@ -213,7 +213,7 @@ describe('CloudWatchDatasource', function() {
|
||||
beforeEach(function() {
|
||||
ctx.backendSrv.datasourceRequest = function(params) {
|
||||
requestParams = params.data;
|
||||
return ctx.$q.when(response);
|
||||
return ctx.$q.when({data: response});
|
||||
};
|
||||
});
|
||||
|
||||
@ -235,7 +235,7 @@ describe('CloudWatchDatasource', function() {
|
||||
setupCallback();
|
||||
ctx.backendSrv.datasourceRequest = args => {
|
||||
scenario.request = args.data;
|
||||
return ctx.$q.when(scenario.requestResponse);
|
||||
return ctx.$q.when({data: scenario.requestResponse});
|
||||
};
|
||||
ctx.ds.metricFindQuery(query).then(args => {
|
||||
scenario.result = args;
|
||||
|
Loading…
Reference in New Issue
Block a user