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
eef3f4e2
Commit
eef3f4e2
authored
Jan 26, 2021
by
Quang-Minh Nguyen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix missing mock in rack attack ee spec
parent
d9b3cd13
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
ee/spec/lib/gitlab/rack_attack_spec.rb
ee/spec/lib/gitlab/rack_attack_spec.rb
+3
-0
No files found.
ee/spec/lib/gitlab/rack_attack_spec.rb
View file @
eef3f4e2
...
...
@@ -6,6 +6,7 @@ RSpec.describe Gitlab::RackAttack, :aggregate_failures do
describe
'.configure'
do
let
(
:fake_rack_attack
)
{
class_double
(
"Rack::Attack"
)
}
let
(
:fake_rack_attack_request
)
{
class_double
(
"Rack::Attack::Request"
)
}
let
(
:fake_cache
)
{
instance_double
(
"Rack::Attack::Cache"
)
}
before
do
stub_const
(
"Rack::Attack"
,
fake_rack_attack
)
...
...
@@ -16,6 +17,8 @@ RSpec.describe Gitlab::RackAttack, :aggregate_failures do
allow
(
fake_rack_attack
).
to
receive
(
:track
)
allow
(
fake_rack_attack
).
to
receive
(
:safelist
)
allow
(
fake_rack_attack
).
to
receive
(
:blocklist
)
allow
(
fake_rack_attack
).
to
receive
(
:cache
).
and_return
(
fake_cache
)
allow
(
fake_cache
).
to
receive
(
:store
=
)
end
it
'adds the incident management throttle'
do
...
...
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