-
Notifications
You must be signed in to change notification settings - Fork 335
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add tracks attr_reader to Configuration (#664)
- Loading branch information
1 parent
0fbc9a1
commit 427fdfa
Showing
2 changed files
with
34 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# frozen_string_literal: true | ||
|
||
require_relative "spec_helper" | ||
|
||
describe Rack::Attack::Configuration do | ||
subject { Rack::Attack::Configuration.new } | ||
|
||
describe 'attributes' do | ||
it 'exposes the safelists attribute' do | ||
_(subject.safelists).must_equal({}) | ||
end | ||
|
||
it 'exposes the blocklists attribute' do | ||
_(subject.blocklists).must_equal({}) | ||
end | ||
|
||
it 'exposes the throttles attribute' do | ||
_(subject.throttles).must_equal({}) | ||
end | ||
|
||
it 'exposes the tracks attribute' do | ||
_(subject.tracks).must_equal({}) | ||
end | ||
|
||
it 'exposes the anonymous_blocklists attribute' do | ||
_(subject.anonymous_blocklists).must_equal([]) | ||
end | ||
|
||
it 'exposes the anonymous_safelists attribute' do | ||
_(subject.anonymous_safelists).must_equal([]) | ||
end | ||
end | ||
end |