Handle false return by TinyTDS if connection fails and fixed CI #818
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Ruby 25 (https://ci.appveyor.com/project/wpolicarpo/activerecord-sqlserver-adapter/builds/32855936/job/6lxy5y73pv8d4h6y) and 26 (https://ci.appveyor.com/project/rails-sqlserver/activerecord-sqlserver-adapter/builds/32856253/job/aymtvlvjfb3c9qon) both fail with
File does not exist: tiny_tds/tiny_tds
error. Allow these CIs to fail. They can be added as issues to be fixed later.Allowing Ruby 27 and 27-x64 to fail as they are not installed on the AppVeyor Windows instance. See https://ci.appveyor.com/project/wpolicarpo/activerecord-sqlserver-adapter/builds/32868782/job/vx7gopv5benhf8in
TinyTDS returns
false
instead of results if the database fails. Updated adapter to throw aTinyTds::Error
iffalse
returned by TinyTDS. This has resolved theNoMethodError: undefined method do for false:FalseClass
CI errors on Windows (example of this error https://ci.appveyor.com/project/rails-sqlserver/activerecord-sqlserver-adapter/builds/32850932/job/gop6taxai5sblxgd). This issue is open in the TinyTDS project as rails-sqlserver/tiny_tds#464https://github.com/rails-sqlserver/tiny_tds/blob/7fb858045e8c918b81f8001dc46e3aafe7cbb2c3/ext/tiny_tds/client.c#L256