We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
dbopen
1 parent b6e25d4 commit 3c350e6Copy full SHA for 3c350e6
test/client_test.rb
@@ -200,6 +200,18 @@ class ClientTest < TinyTds::TestCase
200
end
201
assert_new_connections_work
202
203
+
204
+ it "raises TinyTds exception with invalid database name" do
205
+ action = lambda { new_connection(database: "DOESNOTEXIST") }
206
207
+ assert_raise_tinytds_error(action) do |e|
208
+ assert_equal 911, e.db_error_number
209
+ assert_equal 16, e.severity
210
+ assert_equal "Database 'DOESNOTEXIST' does not exist. Make sure that the name is entered correctly.", e.message
211
+ end
212
213
+ assert_new_connections_work
214
215
216
217
describe "#parse_username" do
0 commit comments