Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
6c962600
Commit
6c962600
authored
May 16, 2020
by
rpereira2
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add templating key to accessors
Add templating key to accessors in PrometheusDashboard model.
parent
53da4358
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
1 deletion
+6
-1
app/models/performance_monitoring/prometheus_dashboard.rb
app/models/performance_monitoring/prometheus_dashboard.rb
+1
-1
ee/spec/models/performance_monitoring/prometheus_dashboard_spec.rb
...odels/performance_monitoring/prometheus_dashboard_spec.rb
+5
-0
No files found.
app/models/performance_monitoring/prometheus_dashboard.rb
View file @
6c962600
...
...
@@ -4,7 +4,7 @@ module PerformanceMonitoring
class
PrometheusDashboard
include
ActiveModel
::
Model
attr_accessor
:dashboard
,
:panel_groups
,
:path
,
:environment
,
:priority
attr_accessor
:dashboard
,
:panel_groups
,
:path
,
:environment
,
:priority
,
:templating
validates
:dashboard
,
presence:
true
validates
:panel_groups
,
presence:
true
...
...
ee/spec/models/performance_monitoring/prometheus_dashboard_spec.rb
View file @
6c962600
...
...
@@ -6,6 +6,11 @@ describe PerformanceMonitoring::PrometheusDashboard do
let
(
:json_content
)
do
{
"dashboard"
=>
"Dashboard Title"
,
"templating"
=>
{
"variables"
=>
{
"variable1"
=>
%w(value1 value2 value3)
}
},
"panel_groups"
=>
[{
"group"
=>
"Group Title"
,
"panels"
=>
[{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment