|
9 | 9 | let(:domain) { 'example.com' }
|
10 | 10 | let(:subdomain) { nil }
|
11 | 11 |
|
12 |
| - it { is_expected.to eq(['domain = ?', 'example.com']) } |
| 12 | + it { is_expected.to eq(['LOWER(domain) = ?', 'example.com']) } |
13 | 13 | end
|
14 | 14 |
|
15 | 15 | context 'with only subdomain' do
|
16 | 16 | let(:domain) { nil }
|
17 | 17 | let(:subdomain) { 'example' }
|
18 | 18 |
|
19 |
| - it { is_expected.to eq(['subdomain = ?', 'example']) } |
| 19 | + it { is_expected.to eq(['LOWER(subdomain) = ?', 'example']) } |
20 | 20 | end
|
21 | 21 |
|
22 | 22 | context 'with domain and subdomain' do
|
|
25 | 25 |
|
26 | 26 | it do
|
27 | 27 | is_expected.to eq([
|
28 |
| - 'domain = ? OR subdomain = ?', 'example.com', 'example' |
| 28 | + 'LOWER(domain) = ? OR LOWER(subdomain) = ?', 'example.com', 'example' |
29 | 29 | ])
|
30 | 30 | end
|
31 | 31 | end
|
|
38 | 38 | let(:domain) { 'example.com' }
|
39 | 39 | let(:subdomain) { nil }
|
40 | 40 |
|
41 |
| - it { is_expected.to eq(['domain = ?', 'example.com']) } |
| 41 | + it { is_expected.to eq(['LOWER(domain) = ?', 'example.com']) } |
42 | 42 | end
|
43 | 43 |
|
44 | 44 | context 'with only subdomain' do
|
|
52 | 52 | let(:domain) { 'example.com' }
|
53 | 53 | let(:subdomain) { 'example' }
|
54 | 54 |
|
55 |
| - it { is_expected.to eq(['domain = ?', 'example.com']) } |
| 55 | + it { is_expected.to eq(['LOWER(domain) = ?', 'example.com']) } |
56 | 56 | end
|
57 | 57 |
|
58 | 58 | after { Detectify.reset_config }
|
|
72 | 72 | let(:domain) { nil }
|
73 | 73 | let(:subdomain) { 'example' }
|
74 | 74 |
|
75 |
| - it { is_expected.to eq(['subdomain = ?', 'example']) } |
| 75 | + it { is_expected.to eq(['LOWER(subdomain) = ?', 'example']) } |
76 | 76 | end
|
77 | 77 |
|
78 | 78 | context 'with domain and subdomain' do
|
79 | 79 | let(:domain) { 'example.com' }
|
80 | 80 | let(:subdomain) { 'example' }
|
81 | 81 |
|
82 |
| - it { is_expected.to eq(['subdomain = ?', 'example']) } |
| 82 | + it { is_expected.to eq(['LOWER(subdomain) = ?', 'example']) } |
83 | 83 | end
|
84 | 84 |
|
85 | 85 | after { Detectify.reset_config }
|
|
0 commit comments