vertica 0.9.0.beta6 → 0.9.0.beta7

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.9.0.beta6
1
+ 0.9.0.beta7
@@ -129,6 +129,11 @@ class Vertica::Connection
129
129
  end
130
130
  return job.run
131
131
  end
132
+
133
+ def inspect
134
+ safe_options = @options.reject{ |name, _| name == :password }
135
+ "#<Vertica::Connection:#{object_id} @parameters=#{@parameters.inspect} @backend_pid=#{@backend_pid}, @backend_key=#{@backend_key}, @transaction_status=#{@transaction_status}, @socket=#{@socket}, @options=#{safe_options.inspect}, @row_style=#{@row_style}>"
136
+ end
132
137
 
133
138
  protected
134
139
 
@@ -153,7 +158,7 @@ class Vertica::Connection
153
158
  end
154
159
 
155
160
  def startup_connection
156
- write Vertica::Messages::Startup.new(@options[:user], @options[:database])
161
+ write Vertica::Messages::Startup.new(@options[:user] || @options[:username], @options[:database])
157
162
  message = nil
158
163
  begin
159
164
  case message = read_message
@@ -68,4 +68,10 @@ class ConnectionTest < Test::Unit::TestCase
68
68
  Vertica::Connection.new(TEST_CONNECTION_HASH.merge('database' => 'nonexistant_db'))
69
69
  end
70
70
  end
71
+
72
+ def test_connection_inspect_should_not_print_password
73
+ @connection = Vertica::Connection.new(TEST_CONNECTION_HASH)
74
+ inspected_string = @connection.inspect
75
+ assert_no_match /:password=>#{TEST_CONNECTION_HASH[:password]}/, inspected_string
76
+ end
71
77
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vertica
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.0.beta6
4
+ version: 0.9.0.beta7
5
5
  prerelease: 6
6
6
  platform: ruby
7
7
  authors:
@@ -11,11 +11,12 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2011-11-09 00:00:00.000000000 Z
14
+ date: 2011-11-15 00:00:00.000000000 -05:00
15
+ default_executable:
15
16
  dependencies:
16
17
  - !ruby/object:Gem::Dependency
17
18
  name: rake
18
- requirement: &2165802180 !ruby/object:Gem::Requirement
19
+ requirement: &2153826360 !ruby/object:Gem::Requirement
19
20
  none: false
20
21
  requirements:
21
22
  - - ! '>='
@@ -23,10 +24,10 @@ dependencies:
23
24
  version: '0'
24
25
  type: :runtime
25
26
  prerelease: false
26
- version_requirements: *2165802180
27
+ version_requirements: *2153826360
27
28
  - !ruby/object:Gem::Dependency
28
29
  name: jeweler
29
- requirement: &2165801500 !ruby/object:Gem::Requirement
30
+ requirement: &2153825660 !ruby/object:Gem::Requirement
30
31
  none: false
31
32
  requirements:
32
33
  - - ! '>='
@@ -34,7 +35,7 @@ dependencies:
34
35
  version: '0'
35
36
  type: :runtime
36
37
  prerelease: false
37
- version_requirements: *2165801500
38
+ version_requirements: *2153825660
38
39
  description: Query Vertica with ruby
39
40
  email: sprsquish@gmail.com
40
41
  executables: []
@@ -96,6 +97,7 @@ files:
96
97
  - test/unit/backend_message_test.rb
97
98
  - test/unit/frontend_message_test.rb
98
99
  - test/unit/quoting_test.rb
100
+ has_rdoc: true
99
101
  homepage: http://github.com/sprsquish/vertica
100
102
  licenses: []
101
103
  post_install_message:
@@ -116,7 +118,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
116
118
  version: 1.3.1
117
119
  requirements: []
118
120
  rubyforge_project:
119
- rubygems_version: 1.8.10
121
+ rubygems_version: 1.6.2
120
122
  signing_key:
121
123
  specification_version: 3
122
124
  summary: Pure ruby library for interacting with Vertica