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
0
Merge Requests
0
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
Tatuya Kamada
gitlab-ce
Commits
820d227b
Commit
820d227b
authored
Feb 25, 2016
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/Baertierchen/gitlab-ce-showTestCoverage'
parents
8d3e5cf0
f36fde94
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
22 additions
and
3 deletions
+22
-3
CHANGELOG
CHANGELOG
+1
-0
app/views/projects/builds/index.html.haml
app/views/projects/builds/index.html.haml
+3
-1
features/project/builds/summary.feature
features/project/builds/summary.feature
+2
-0
features/steps/project/builds/summary.rb
features/steps/project/builds/summary.rb
+6
-0
features/steps/shared/builds.rb
features/steps/shared/builds.rb
+5
-1
spec/factories/ci/builds.rb
spec/factories/ci/builds.rb
+5
-1
No files found.
CHANGELOG
View file @
820d227b
...
@@ -20,6 +20,7 @@ v 8.5.1
...
@@ -20,6 +20,7 @@ v 8.5.1
- Changed padding & background color for highlighted notes
- Changed padding & background color for highlighted notes
- Re-add the newrelic_rpm gem which was removed without any deprecation or warning (Stan Hu)
- Re-add the newrelic_rpm gem which was removed without any deprecation or warning (Stan Hu)
- Update sentry-raven gem to 0.15.6
- Update sentry-raven gem to 0.15.6
- Add build coverage in project's builds page (Steffen Köhler)
v 8.5.0
v 8.5.0
- Fix duplicate "me" in tooltip of the "thumbsup" awards Emoji (Stan Hu)
- Fix duplicate "me" in tooltip of the "thumbsup" awards Emoji (Stan Hu)
...
...
app/views/projects/builds/index.html.haml
View file @
820d227b
...
@@ -51,9 +51,11 @@
...
@@ -51,9 +51,11 @@
%th
Name
%th
Name
%th
Duration
%th
Duration
%th
Finished at
%th
Finished at
-
if
@project
.
build_coverage_enabled?
%th
Coverage
%th
%th
-
@builds
.
each
do
|
build
|
-
@builds
.
each
do
|
build
|
=
render
'projects/commit_statuses/commit_status'
,
commit_status:
build
,
commit_sha:
true
,
stage:
true
,
allow_retry:
true
=
render
'projects/commit_statuses/commit_status'
,
commit_status:
build
,
commit_sha:
true
,
stage:
true
,
coverage:
@project
.
build_coverage_enabled?
,
allow_retry:
true
=
paginate
@builds
,
theme:
'gitlab'
=
paginate
@builds
,
theme:
'gitlab'
features/project/builds/summary.feature
View file @
820d227b
...
@@ -3,6 +3,7 @@ Feature: Project Builds Summary
...
@@ -3,6 +3,7 @@ Feature: Project Builds Summary
Given
I sign in as a user
Given
I sign in as a user
And
I own a project
And
I own a project
And
project has CI enabled
And
project has CI enabled
And
project has coverage enabled
And
project has a recent build
And
project has a recent build
Scenario
:
I
browse build details page
Scenario
:
I
browse build details page
...
@@ -12,6 +13,7 @@ Feature: Project Builds Summary
...
@@ -12,6 +13,7 @@ Feature: Project Builds Summary
Scenario
:
I
browse project builds page
Scenario
:
I
browse project builds page
When
I visit project builds page
When
I visit project builds page
Then
I see coverage
Then
I see button to CI Lint
Then
I see button to CI Lint
Scenario
:
I
erase a build
Scenario
:
I
erase a build
...
...
features/steps/project/builds/summary.rb
View file @
820d227b
...
@@ -4,6 +4,12 @@ class Spinach::Features::ProjectBuildsSummary < Spinach::FeatureSteps
...
@@ -4,6 +4,12 @@ class Spinach::Features::ProjectBuildsSummary < Spinach::FeatureSteps
include
SharedBuilds
include
SharedBuilds
include
RepoHelpers
include
RepoHelpers
step
'I see coverage'
do
page
.
within
(
'td.coverage'
)
do
expect
(
page
).
to
have_content
"99.9%"
end
end
step
'I see button to CI Lint'
do
step
'I see button to CI Lint'
do
page
.
within
(
'.nav-controls'
)
do
page
.
within
(
'.nav-controls'
)
do
ci_lint_tool_link
=
page
.
find_link
(
'CI Lint'
)
ci_lint_tool_link
=
page
.
find_link
(
'CI Lint'
)
...
...
features/steps/shared/builds.rb
View file @
820d227b
...
@@ -5,9 +5,13 @@ module SharedBuilds
...
@@ -5,9 +5,13 @@ module SharedBuilds
@project
.
enable_ci
@project
.
enable_ci
end
end
step
'project has coverage enabled'
do
@project
.
update_attribute
(
:build_coverage_regex
,
/Coverage (\d+)%/
)
end
step
'project has a recent build'
do
step
'project has a recent build'
do
@ci_commit
=
create
(
:ci_commit
,
project:
@project
,
sha:
@project
.
commit
.
sha
)
@ci_commit
=
create
(
:ci_commit
,
project:
@project
,
sha:
@project
.
commit
.
sha
)
@build
=
create
(
:ci_build
,
commit:
@ci_commit
)
@build
=
create
(
:ci_build
_with_coverage
,
commit:
@ci_commit
)
end
end
step
'recent build is successful'
do
step
'recent build is successful'
do
...
...
spec/factories/ci/builds.rb
View file @
820d227b
...
@@ -53,6 +53,10 @@ FactoryGirl.define do
...
@@ -53,6 +53,10 @@ FactoryGirl.define do
tag
true
tag
true
end
end
factory
:ci_build_with_coverage
do
coverage
99.9
end
trait
:trace
do
trait
:trace
do
after
(
:create
)
do
|
build
,
evaluator
|
after
(
:create
)
do
|
build
,
evaluator
|
build
.
trace
=
'BUILD TRACE'
build
.
trace
=
'BUILD TRACE'
...
@@ -68,7 +72,7 @@ FactoryGirl.define do
...
@@ -68,7 +72,7 @@ FactoryGirl.define do
build
.
artifacts_metadata
=
build
.
artifacts_metadata
=
fixture_file_upload
(
Rails
.
root
.
join
(
'spec/fixtures/ci_build_artifacts_metadata.gz'
),
fixture_file_upload
(
Rails
.
root
.
join
(
'spec/fixtures/ci_build_artifacts_metadata.gz'
),
'application/x-gzip'
)
'application/x-gzip'
)
build
.
save!
build
.
save!
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