diff options
Diffstat (limited to 'gems/click_house-client/spec/click_house')
-rw-r--r-- | gems/click_house-client/spec/click_house/client/configuration_spec.rb | 2 | ||||
-rw-r--r-- | gems/click_house-client/spec/click_house/client/database_spec.rb | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/gems/click_house-client/spec/click_house/client/configuration_spec.rb b/gems/click_house-client/spec/click_house/client/configuration_spec.rb index 8cbd64ca650..c6bd2974b7e 100644 --- a/gems/click_house-client/spec/click_house/client/configuration_spec.rb +++ b/gems/click_house-client/spec/click_house/client/configuration_spec.rb @@ -29,7 +29,7 @@ RSpec.describe ClickHouse::Client::Configuration do expect(configuration.databases.size).to eq(1) database = configuration.databases[:my_db] - expect(database.uri.to_s).to eq('http://localhost:3333?database=test_db&join_use_nulls=1') + expect(database.uri.to_s).to eq('http://localhost:3333?database=test_db&enable_http_compression=1&join_use_nulls=1') end context 'when adding the same DB multiple times' do diff --git a/gems/click_house-client/spec/click_house/client/database_spec.rb b/gems/click_house-client/spec/click_house/client/database_spec.rb index 112b2ee12b1..a74d4a119a4 100644 --- a/gems/click_house-client/spec/click_house/client/database_spec.rb +++ b/gems/click_house-client/spec/click_house/client/database_spec.rb @@ -17,13 +17,15 @@ RSpec.describe ClickHouse::Client::Database do describe '#uri' do it 'builds the correct URL' do - expect(database.uri.to_s).to eq('http://localhost:3333?database=test_db&join_use_nulls=1') + expect(database.uri.to_s).to eq('http://localhost:3333?database=test_db&enable_http_compression=1&join_use_nulls=1') end end describe '#headers' do it 'returns the correct headers' do expect(database.headers).to eq({ + "Content-Encoding" => "gzip", + "X-ClickHouse-Format" => "JSON", 'X-ClickHouse-User' => 'user', 'X-ClickHouse-Key' => 'pass' }) |