Add missing patch.
This commit is contained in:
parent
f4c55ad7ce
commit
a07b7192b7
32
rubygem-pg-1.1.3-Fix-specs-for-PostgreSQL-11.patch
Normal file
32
rubygem-pg-1.1.3-Fix-specs-for-PostgreSQL-11.patch
Normal file
@ -0,0 +1,32 @@
|
||||
# HG changeset patch
|
||||
# User Lars Kanis <lars@greiz-reinsdorf.de>
|
||||
# Date 1545850926 -3600
|
||||
# Node ID 74879444e437d42028a636425a4482467a65a711
|
||||
# Parent 626befee1debcc59472051e64f9ff067522fc3e1
|
||||
Fix specs for PostgreSQL-11
|
||||
|
||||
PG-11 changed the way how/when parameters are interpret.
|
||||
|
||||
Fixes 287: https://bitbucket.org/ged/ruby-pg/issues/287/pg-connection-server-ping-returns-correct
|
||||
|
||||
diff --git a/spec/pg/connection_spec.rb b/spec/pg/connection_spec.rb
|
||||
--- a/spec/pg/connection_spec.rb
|
||||
+++ b/spec/pg/connection_spec.rb
|
||||
@@ -1140,8 +1140,16 @@
|
||||
expect( ping ).to eq( PG::PQPING_NO_RESPONSE )
|
||||
end
|
||||
|
||||
+ it "returns error when ping connection arguments are wrong" do
|
||||
+ ping = described_class.ping('localhost', 'localhost', nil, nil, :test, nil, nil)
|
||||
+ expect( ping ).to_not eq( PG::PQPING_OK )
|
||||
+ end
|
||||
+
|
||||
it "returns correct response when ping connection arguments are wrong" do
|
||||
- ping = described_class.ping('localhost', 'localhost', nil, nil, :test, nil, nil)
|
||||
+ ping = described_class.ping(
|
||||
+ :host => 'localhost',
|
||||
+ :invalid_option => 9999,
|
||||
+ :dbname => :test)
|
||||
expect( ping ).to eq( PG::PQPING_NO_ATTEMPT )
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user