Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
李少辉-开发者
gitlab-foss
提交
353d426e
G
gitlab-foss
项目概览
李少辉-开发者
/
gitlab-foss
通知
15
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
gitlab-foss
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
未验证
提交
353d426e
编写于
9月 24, 2015
作者:
D
Dmitriy Zaporozhets
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Show CI status on Your projects page and Starred projects page
Signed-off-by:
N
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
上级
3e866b2a
变更
9
隐藏空白更改
内联
并排
Showing
9 changed file
with
39 addition
and
10 deletion
+39
-10
CHANGELOG
CHANGELOG
+1
-0
app/assets/stylesheets/pages/projects.scss
app/assets/stylesheets/pages/projects.scss
+7
-1
app/views/dashboard/projects/_projects.html.haml
app/views/dashboard/projects/_projects.html.haml
+1
-1
app/views/shared/projects/_list.html.haml
app/views/shared/projects/_list.html.haml
+2
-1
app/views/shared/projects/_project.html.haml
app/views/shared/projects/_project.html.haml
+11
-2
features/dashboard/dashboard.feature
features/dashboard/dashboard.feature
+3
-1
features/steps/dashboard/dashboard.rb
features/steps/dashboard/dashboard.rb
+4
-0
features/steps/project/graph.rb
features/steps/project/graph.rb
+0
-4
features/steps/shared/project.rb
features/steps/shared/project.rb
+10
-0
未找到文件。
CHANGELOG
浏览文件 @
353d426e
...
...
@@ -7,6 +7,7 @@ v 8.1.0 (unreleased)
- Fix cases where Markdown did not render links in activity feed (Stan Hu)
- Add first and last to pagination (Zeger-Jan van de Weg)
- Show CI status on commit page
- Show CI status on Your projects page and Starred projects page
v 8.0.2 (unreleased)
- Skip check_initd_configured_correctly on omnibus installs
...
...
app/assets/stylesheets/pages/projects.scss
浏览文件 @
353d426e
...
...
@@ -297,9 +297,15 @@ pre.light-well {
color
:
#4c4e54
;
}
.pull-right.light
{
.project-controls
{
float
:
right
;
color
:
$gl-gray
;
line-height
:
45px
;
color
:
#7f8fa4
;
a
:hover
{
text-decoration
:
none
;
}
}
.project-description
{
...
...
app/views/dashboard/projects/_projects.html.haml
浏览文件 @
353d426e
...
...
@@ -7,4 +7,4 @@
=
link_to
new_project_path
,
class:
'btn btn-success'
do
New project
=
render
'shared/projects/list'
,
projects:
@projects
=
render
'shared/projects/list'
,
projects:
@projects
,
ci:
true
app/views/shared/projects/_list.html.haml
浏览文件 @
353d426e
-
projects_limit
=
20
unless
local_assigns
[
:projects_limit
]
-
avatar
=
true
unless
local_assigns
[
:avatar
]
==
false
-
stars
=
true
unless
local_assigns
[
:stars
]
==
false
-
ci
=
false
unless
local_assigns
[
:ci
]
==
true
%ul
.projects-list
-
projects
.
each_with_index
do
|
project
,
i
|
-
css_class
=
(
i
>=
projects_limit
)
?
'hide'
:
nil
=
render
"shared/projects/project"
,
project:
project
,
avatar:
avatar
,
stars:
stars
,
css_class:
css_class
avatar:
avatar
,
stars:
stars
,
css_class:
css_class
,
ci:
ci
-
if
projects
.
size
>
projects_limit
%li
.bottom.center
...
...
app/views/shared/projects/_project.html.haml
浏览文件 @
353d426e
-
avatar
=
true
unless
local_assigns
[
:avatar
]
==
false
-
stars
=
true
unless
local_assigns
[
:stars
]
==
false
-
ci
=
false
unless
local_assigns
[
:ci
]
==
true
-
css_class
=
''
unless
local_assigns
[
:css_class
]
-
css_class
+=
" no-description"
unless
project
.
description
.
present?
%li
.project-row
{
class:
css_class
}
=
cache
[
project
.
namespace
,
project
,
controller
.
controller_name
,
controller
.
action_name
,
'v2.
1
'
]
do
=
cache
[
project
.
namespace
,
project
,
controller
.
controller_name
,
controller
.
action_name
,
'v2.
2
'
]
do
=
link_to
project_path
(
project
),
class:
dom_class
(
project
)
do
-
if
avatar
.dash-project-avatar
...
...
@@ -15,8 +16,16 @@
\/
%span
.project-name.filter-title
=
project
.
name
.project-controls
-
if
ci
&&
!
project
.
empty_repo?
-
if
ci_commit
=
project
.
ci_commit
(
project
.
commit
.
sha
)
=
link_to
ci_status_path
(
ci_commit
),
class:
"c
#{
ci_status_color
(
ci_commit
)
}
"
,
title:
"Build status:
#{
ci_commit
.
status
}
"
,
data:
{
toggle:
'tooltip'
,
placement:
'left'
}
do
=
ci_status_icon
(
ci_commit
)
-
if
stars
%span
.pull-right.light
%span
%i
.fa.fa-star
=
project
.
star_count
-
if
project
.
description
.
present?
...
...
features/dashboard/dashboard.feature
浏览文件 @
353d426e
...
...
@@ -4,12 +4,14 @@ Feature: Dashboard
Given
I sign in as a user
And
I own project
"Shop"
And
project
"Shop"
has push event
And
project
"Shop"
has CI enabled
And
project
"Shop"
has CI build
And
I visit dashboard page
@javascript
Scenario
:
I
should see projects list
Then
I should see
"New Project"
link
Then
I should see
"Shop"
project link
Then
I should see
"Shop"
project CI status
@javascript
Scenario
:
I
should see activity list
...
...
features/steps/dashboard/dashboard.rb
浏览文件 @
353d426e
...
...
@@ -11,6 +11,10 @@ class Spinach::Features::Dashboard < Spinach::FeatureSteps
expect
(
page
).
to
have_link
"Shop"
end
step
'I should see "Shop" project CI status'
do
expect
(
page
).
to
have_link
"Build status: skipped"
end
step
'I should see last push widget'
do
expect
(
page
).
to
have_content
"You pushed to fix"
expect
(
page
).
to
have_link
"Create Merge Request"
...
...
features/steps/project/graph.rb
浏览文件 @
353d426e
...
...
@@ -23,10 +23,6 @@ class Spinach::Features::ProjectGraph < Spinach::FeatureSteps
visit
ci_namespace_project_graph_path
(
project
.
namespace
,
project
,
'master'
)
end
step
'project "Shop" has CI enabled'
do
project
.
enable_ci
(
@user
)
end
step
'page should have CI graphs'
do
expect
(
page
).
to
have_content
'Overall'
expect
(
page
).
to
have_content
'Builds chart for last week'
...
...
features/steps/shared/project.rb
浏览文件 @
353d426e
...
...
@@ -196,4 +196,14 @@ module SharedProject
create
(
:label
,
project:
project
,
title:
'feature'
)
create
(
:label
,
project:
project
,
title:
'enhancement'
)
end
step
'project "Shop" has CI enabled'
do
project
=
Project
.
find_by
(
name:
"Shop"
)
project
.
enable_ci
(
@user
)
end
step
'project "Shop" has CI build'
do
project
=
Project
.
find_by
(
name:
"Shop"
)
create
:ci_commit
,
project:
project
.
gitlab_ci_project
,
sha:
project
.
commit
.
sha
end
end
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录