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
Boxiang Sun
gitlab-ce
Commits
ca089d91
Commit
ca089d91
authored
Jul 16, 2019
by
Patrick Derichs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Modified spec so a second call to json_response is avoided
parent
52bdcdff
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
spec/controllers/boards/issues_controller_spec.rb
spec/controllers/boards/issues_controller_spec.rb
+7
-2
No files found.
spec/controllers/boards/issues_controller_spec.rb
View file @
ca089d91
...
@@ -196,7 +196,7 @@ describe Boards::IssuesController do
...
@@ -196,7 +196,7 @@ describe Boards::IssuesController do
sign_in
(
signed_in_user
)
sign_in
(
signed_in_user
)
end
end
it
'
moves issue
s as expected'
do
it
'
respond
s as expected'
do
put
:bulk_move
,
params:
move_issues_params
put
:bulk_move
,
params:
move_issues_params
expect
(
response
).
to
have_gitlab_http_status
(
expected_status
)
expect
(
response
).
to
have_gitlab_http_status
(
expected_status
)
...
@@ -208,13 +208,18 @@ describe Boards::IssuesController do
...
@@ -208,13 +208,18 @@ describe Boards::IssuesController do
expect
(
json_response
[
'issues'
].
pluck
(
'id'
)).
to
match_array
(
move_issues_params
[
:ids
])
expect
(
json_response
[
'issues'
].
pluck
(
'id'
)).
to
match_array
(
move_issues_params
[
:ids
])
end
end
end
it
'moves issues as expected'
do
put
:bulk_move
,
params:
move_issues_params
expect
(
response
).
to
have_gitlab_http_status
(
expected_status
)
list_issues
user:
requesting_user
,
board:
board
,
list:
list2
list_issues
user:
requesting_user
,
board:
board
,
list:
list2
expect
(
response
).
to
have_gitlab_http_status
(
200
)
expect
(
response
).
to
have_gitlab_http_status
(
200
)
expect
(
response
).
to
match_response_schema
(
'entities/issue_boards'
)
expect
(
response
).
to
match_response_schema
(
'entities/issue_boards'
)
responded_issues
=
JSON
.
parse
(
response
.
body
)
[
'issues'
]
responded_issues
=
json_response
[
'issues'
]
expect
(
responded_issues
.
length
).
to
eq
expected_issue_count
expect
(
responded_issues
.
length
).
to
eq
expected_issue_count
ids_in_order
=
responded_issues
.
pluck
(
'id'
)
ids_in_order
=
responded_issues
.
pluck
(
'id'
)
...
...
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