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
66aab4cc
Commit
66aab4cc
authored
Jun 14, 2021
by
charlie ablett
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Tech debt - eq [] to be_empty
parent
026957b9
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
6 additions
and
6 deletions
+6
-6
spec/graphql/mutations/design_management/upload_spec.rb
spec/graphql/mutations/design_management/upload_spec.rb
+1
-1
spec/graphql/resolvers/boards_resolver_spec.rb
spec/graphql/resolvers/boards_resolver_spec.rb
+1
-1
spec/models/concerns/awardable_spec.rb
spec/models/concerns/awardable_spec.rb
+2
-2
spec/models/snippet_spec.rb
spec/models/snippet_spec.rb
+1
-1
spec/support/shared_examples/requests/api/resource_label_events_api_shared_examples.rb
...requests/api/resource_label_events_api_shared_examples.rb
+1
-1
No files found.
spec/graphql/mutations/design_management/upload_spec.rb
View file @
66aab4cc
...
...
@@ -105,7 +105,7 @@ RSpec.describe Mutations::DesignManagement::Upload do
context
"with a valid design"
do
it
"returns the updated designs"
do
expect
(
resolve
[
:errors
]).
to
eq
[]
expect
(
resolve
[
:errors
]).
to
be_empty
expect
(
resolve
[
:designs
].
map
(
&
:filename
)).
to
contain_exactly
(
"dk.png"
)
end
end
...
...
spec/graphql/resolvers/boards_resolver_spec.rb
View file @
66aab4cc
...
...
@@ -9,7 +9,7 @@ RSpec.describe Resolvers::BoardsResolver do
shared_examples_for
'group and project boards resolver'
do
it
'does not create a default board'
do
expect
(
resolve_boards
).
to
eq
[]
expect
(
resolve_boards
).
to
be_empty
end
it
'calls Boards::BoardsFinder'
do
...
...
spec/models/concerns/awardable_spec.rb
View file @
66aab4cc
...
...
@@ -108,7 +108,7 @@ RSpec.describe Awardable do
it
"doesn't include unused thumbs buttons when disabled in project"
do
issue_without_downvote
.
project
.
show_default_award_emojis
=
false
expect
(
issue_without_downvote
.
grouped_awards
.
keys
.
sort
).
to
eq
[]
expect
(
issue_without_downvote
.
grouped_awards
.
keys
.
sort
).
to
be_empty
end
it
"includes unused thumbs buttons when enabled in project"
do
...
...
@@ -118,7 +118,7 @@ RSpec.describe Awardable do
end
it
"doesn't include unused thumbs buttons in summary"
do
expect
(
issue_without_downvote
.
grouped_awards
(
with_thumbs:
false
).
keys
).
to
eq
[]
expect
(
issue_without_downvote
.
grouped_awards
(
with_thumbs:
false
).
keys
).
to
be_empty
end
it
"includes used thumbs buttons when disabled in project"
do
...
...
spec/models/snippet_spec.rb
View file @
66aab4cc
...
...
@@ -750,7 +750,7 @@ RSpec.describe Snippet do
end
it
'returns an empty array'
do
expect
(
subject
).
to
eq
[]
expect
(
subject
).
to
be_empty
end
end
end
...
...
spec/support/shared_examples/requests/api/resource_label_events_api_shared_examples.rb
View file @
66aab4cc
...
...
@@ -48,7 +48,7 @@ RSpec.shared_examples 'resource_label_events API' do |parent_type, eventable_typ
get
api
(
"/
#{
parent_type
}
/
#{
parent
.
id
}
/
#{
eventable_type
}
/
#{
eventable
[
id_name
]
}
/resource_label_events"
,
user
)
expect
(
json_response
).
to
be_an
Array
expect
(
json_response
).
to
eq
[]
expect
(
json_response
).
to
be_empty
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