Loki: Add autocomplete option for $__range variable (#36717)

* Add autocomplete option for Loki & Promtheus rates

* Update test
This commit is contained in:
Ivana Huckova
2021-07-14 07:44:23 -04:00
committed by GitHub
parent f29f190e73
commit d9897a457d
3 changed files with 4 additions and 1 deletions

View File

@@ -124,8 +124,9 @@ describe('Language completion provider', () => {
expect(result.suggestions).toMatchObject([
{
items: [
{ label: '$__interval', sortValue: '$__interval' }, // TODO: figure out why this row and sortValue is needed
{ label: '$__interval', sortValue: '$__interval' },
{ label: '$__rate_interval', sortValue: '$__rate_interval' },
{ label: '$__range', sortValue: '$__range' },
{ label: '1m', sortValue: '00:01:00' },
{ label: '5m', sortValue: '00:05:00' },
{ label: '10m', sortValue: '00:10:00' },