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
74613d28
Commit
74613d28
authored
Nov 06, 2019
by
Ryan Cobb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix dashboard service and finder specs
parent
0487769e
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
4 deletions
+6
-4
spec/lib/gitlab/metrics/dashboard/finder_spec.rb
spec/lib/gitlab/metrics/dashboard/finder_spec.rb
+2
-2
spec/services/metrics/dashboard/project_dashboard_service_spec.rb
...vices/metrics/dashboard/project_dashboard_service_spec.rb
+2
-1
spec/services/metrics/dashboard/system_dashboard_service_spec.rb
...rvices/metrics/dashboard/system_dashboard_service_spec.rb
+2
-1
No files found.
spec/lib/gitlab/metrics/dashboard/finder_spec.rb
View file @
74613d28
...
...
@@ -136,7 +136,7 @@ describe Gitlab::Metrics::Dashboard::Finder, :use_clean_rails_memory_store_cachi
describe
'.find_all_paths'
do
let
(
:all_dashboard_paths
)
{
described_class
.
find_all_paths
(
project
)
}
let
(
:system_dashboard
)
{
{
path:
system_dashboard_path
,
display_name:
'Default'
,
default:
true
}
}
let
(
:system_dashboard
)
{
{
path:
system_dashboard_path
,
display_name:
'Default'
,
default:
true
,
system_dashboard:
true
}
}
it
'includes only the system dashboard by default'
do
expect
(
all_dashboard_paths
).
to
eq
([
system_dashboard
])
...
...
@@ -147,7 +147,7 @@ describe Gitlab::Metrics::Dashboard::Finder, :use_clean_rails_memory_store_cachi
let
(
:project
)
{
project_with_dashboard
(
dashboard_path
)
}
it
'includes system and project dashboards'
do
project_dashboard
=
{
path:
dashboard_path
,
display_name:
'test.yml'
,
default:
false
}
project_dashboard
=
{
path:
dashboard_path
,
display_name:
'test.yml'
,
default:
false
,
system_dashboard:
false
}
expect
(
all_dashboard_paths
).
to
contain_exactly
(
system_dashboard
,
project_dashboard
)
end
...
...
spec/services/metrics/dashboard/project_dashboard_service_spec.rb
View file @
74613d28
...
...
@@ -80,7 +80,8 @@ describe Metrics::Dashboard::ProjectDashboardService, :use_clean_rails_memory_st
[{
path:
dashboard_path
,
display_name:
'test.yml'
,
default:
false
default:
false
,
system_dashboard:
false
}]
)
end
...
...
spec/services/metrics/dashboard/system_dashboard_service_spec.rb
View file @
74613d28
...
...
@@ -44,7 +44,8 @@ describe Metrics::Dashboard::SystemDashboardService, :use_clean_rails_memory_sto
[{
path:
described_class
::
SYSTEM_DASHBOARD_PATH
,
display_name:
described_class
::
SYSTEM_DASHBOARD_NAME
,
default:
true
default:
true
,
system_dashboard:
true
}]
)
end
...
...
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