forked from projectblacklight/blacklight_advanced_search
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request projectblacklight#106 from dkinzer/fix-local-param…
…-hash-fails Fix local_params_hash method fails field_def is nil.
- Loading branch information
Showing
2 changed files
with
21 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
20 changes: 20 additions & 0 deletions
20
spec/lib/blacklight_advanced_search/parsing_nesting_parser_spec.rb
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,20 @@ | ||
describe BlacklightAdvancedSearch::ParsingNestingParser, type: :module do | ||
let(:blacklight_config) do | ||
Blacklight::Configuration.new do |config| | ||
config.add_facet_field 'type' | ||
end | ||
end | ||
|
||
let(:subject) { (Object.new).extend(BlacklightAdvancedSearch::ParsingNestingParser) } | ||
|
||
describe "#local_param_hash" do | ||
|
||
context 'with config[key] being nil' do | ||
let(:key) { "foo" } | ||
|
||
it "does not fail do no nil error" do | ||
expect { subject.local_param_hash(key, blacklight_config) }.not_to raise_error | ||
end | ||
end | ||
end | ||
end |