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
84a5106c
Commit
84a5106c
authored
Feb 02, 2022
by
Tiger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Show KAS version on admin dashboard
Changelog: added
parent
8fc00aea
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
37 additions
and
0 deletions
+37
-0
app/views/admin/dashboard/index.html.haml
app/views/admin/dashboard/index.html.haml
+5
-0
locale/gitlab.pot
locale/gitlab.pot
+3
-0
spec/views/admin/dashboard/index.html.haml_spec.rb
spec/views/admin/dashboard/index.html.haml_spec.rb
+29
-0
No files found.
app/views/admin/dashboard/index.html.haml
View file @
84a5106c
...
...
@@ -143,6 +143,11 @@
=
_
(
'GitLab Pages'
)
%span
.float-right
=
Gitlab
::
Pages
::
VERSION
-
if
Gitlab
::
Kas
.
enabled?
%p
=
_
(
'GitLab KAS'
)
%span
.float-right
=
Gitlab
::
Kas
.
version
=
render_if_exists
'admin/dashboard/geo'
...
...
locale/gitlab.pot
View file @
84a5106c
...
...
@@ -16271,6 +16271,9 @@ msgstr ""
msgid "GitLab Issue"
msgstr ""
msgid "GitLab KAS"
msgstr ""
msgid "GitLab Pages"
msgstr ""
...
...
spec/views/admin/dashboard/index.html.haml_spec.rb
View file @
84a5106c
...
...
@@ -63,4 +63,33 @@ RSpec.describe 'admin/dashboard/index.html.haml' do
expect
(
rendered
).
to
have_selector
(
'.js-gitlab-version-check'
)
end
end
describe
'GitLab KAS'
do
before
do
allow
(
Gitlab
::
Kas
).
to
receive
(
:enabled?
).
and_return
(
enabled
)
allow
(
Gitlab
::
Kas
).
to
receive
(
:version
).
and_return
(
'kas-1.2.3'
)
end
context
'KAS enabled'
do
let
(
:enabled
)
{
true
}
it
'includes KAS version'
do
render
expect
(
rendered
).
to
have_content
(
'GitLab KAS'
)
expect
(
rendered
).
to
have_content
(
'kas-1.2.3'
)
end
end
context
'KAS disabled'
do
let
(
:enabled
)
{
false
}
it
'does not include KAS version'
do
render
expect
(
rendered
).
not_to
have_content
(
'GitLab KAS'
)
expect
(
rendered
).
not_to
have_content
(
'kas-1.2.3'
)
end
end
end
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