mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
singlestat: render time of last point based on dashboard timezone (#11425)
* singlestat: render time of last point based on dashboard timezone * changelog: add note for #10338
This commit is contained in:
committed by
Torkel Ödegaard
parent
e52aceeaba
commit
ef0b7bda6f
@@ -23,6 +23,7 @@ export function ControllerTestContext() {
|
||||
};
|
||||
},
|
||||
};
|
||||
this.isUtc = false;
|
||||
|
||||
this.providePhase = function(mocks) {
|
||||
return angularMocks.module(function($provide) {
|
||||
@@ -46,6 +47,10 @@ export function ControllerTestContext() {
|
||||
self.$q = $q;
|
||||
self.panel = new PanelModel({ type: 'test' });
|
||||
self.dashboard = { meta: {} };
|
||||
self.isUtc = false;
|
||||
self.dashboard.isTimezoneUtc = function() {
|
||||
return self.isUtc;
|
||||
};
|
||||
|
||||
$rootScope.appEvent = sinon.spy();
|
||||
$rootScope.onAppEvent = sinon.spy();
|
||||
@@ -93,6 +98,10 @@ export function ControllerTestContext() {
|
||||
});
|
||||
});
|
||||
};
|
||||
|
||||
this.setIsUtc = function(isUtc = false) {
|
||||
self.isUtc = isUtc;
|
||||
};
|
||||
}
|
||||
|
||||
export function ServiceTestContext() {
|
||||
|
||||
Reference in New Issue
Block a user