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
cfd7602d
Commit
cfd7602d
authored
Feb 23, 2017
by
Kamil Trzciński
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'fix-test-for-build-attributes' into 'master'
Fix build attributes test See merge request !9409
parents
7e662dc7
9e6b2c5d
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
5 deletions
+6
-5
app/services/ci/retry_build_service.rb
app/services/ci/retry_build_service.rb
+4
-3
spec/services/ci/retry_build_service_spec.rb
spec/services/ci/retry_build_service_spec.rb
+2
-2
No files found.
app/services/ci/retry_build_service.rb
View file @
cfd7602d
module
Ci
class
RetryBuildService
<
::
BaseService
CLONE_ATTRIBUTES
=
%i[pipeline
ref tag options commands tag_list
name
CLONE_ATTRIBUTES
=
%i[pipeline
project ref tag options commands
name
allow_failure stage stage_idx trigger_request
yaml_variables when environment coverage_regex]
.
freeze
REJECT_ATTRIBUTES
=
%i[id status user token coverage trace runner
artifacts_file artifacts_metadata artifacts_size
artifacts_expire_at artifacts_file
artifacts_metadata artifacts_size
created_at updated_at started_at finished_at
queued_at erased_by erased_at]
.
freeze
IGNORE_ATTRIBUTES
=
%i[t
race type lock_version project
target_url
IGNORE_ATTRIBUTES
=
%i[t
ype lock_version gl_project_id
target_url
deploy job_id description]
.
freeze
def
execute
(
build
)
...
...
spec/services/ci/retry_build_service_spec.rb
View file @
cfd7602d
...
...
@@ -12,7 +12,7 @@ describe Ci::RetryBuildService, :services do
shared_examples
'build duplication'
do
let
(
:build
)
do
create
(
:ci_build
,
:failed
,
:artifacts
,
:erased
,
:trace
,
create
(
:ci_build
,
:failed
,
:artifacts
_expired
,
:erased
,
:trace
,
:queued
,
:coverage
,
pipeline:
pipeline
)
end
...
...
@@ -38,7 +38,7 @@ describe Ci::RetryBuildService, :services do
described_class
::
IGNORE_ATTRIBUTES
+
described_class
::
REJECT_ATTRIBUTES
expect
(
attributes
.
size
).
to
eq
build
.
attributes
.
size
expect
(
build
.
attributes
.
size
).
to
eq
(
attributes
.
size
)
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