File tree Expand file tree Collapse file tree 2 files changed +25
-7
lines changed
lib/elasticsearch/dsl/search/queries
spec/elasticsearch/dsl/search/queries Expand file tree Collapse file tree 2 files changed +25
-7
lines changed Original file line number Diff line number Diff line change @@ -40,19 +40,21 @@ class Match
40
40
include BaseComponent
41
41
42
42
option_method :query
43
- option_method :operator
44
- option_method :minimum_should_match
45
- option_method :type
46
- option_method :boost
43
+ option_method :analyzer
44
+ option_method :auto_generate_synonyms_phrase_query
47
45
option_method :fuzziness
48
- option_method :prefix_length
49
46
option_method :max_expansions
47
+ option_method :prefix_length
48
+ option_method :fuzzy_transpositions
50
49
option_method :fuzzy_rewrite
51
- option_method :analyzer
52
50
option_method :lenient
51
+ option_method :operator
52
+ option_method :minimum_should_match
53
53
option_method :zero_terms_query
54
+
55
+ option_method :type
56
+ option_method :boost
54
57
option_method :cutoff_frequency
55
- option_method :max_expansions
56
58
end
57
59
58
60
end
Original file line number Diff line number Diff line change 68
68
expect ( search . to_hash [ :match ] [ :type ] ) . to eq ( 10 )
69
69
end
70
70
end
71
+
72
+ describe '#auto_generate_synonyms_phrase_query' do
73
+ it 'applies the option' do
74
+ search . auto_generate_synonyms_phrase_query 'false'
75
+
76
+ expect ( search . to_hash [ :match ] [ :auto_generate_synonyms_phrase_query ] ) . to eq ( 'false' )
77
+ end
78
+ end
79
+
80
+ describe '#fuzzy_transpositions' do
81
+ it 'applies the option' do
82
+ search . fuzzy_transpositions 'false'
83
+
84
+ expect ( search . to_hash [ :match ] [ :fuzzy_transpositions ] ) . to eq ( 'false' )
85
+ end
86
+ end
71
87
end
72
88
73
89
describe '#initialize' do
You can’t perform that action at this time.
0 commit comments