activerecord-sqlserver-adapter 7.2.3 → 7.2.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/VERSION +1 -1
- data/lib/active_record/connection_adapters/sqlserver/schema_statements.rb +1 -1
- data/test/cases/coerced_tests.rb +12 -0
- data/test/cases/schema_test_sqlserver.rb +6 -0
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e85a529bb9b684087f56962cc806b12aa3138de66dd85ad5985d364a4d749243
|
4
|
+
data.tar.gz: 5c5b790e60fc34d9c7ac5eb733f0cbd2b9b5e1dc0a821a5e8af02d1903204a7f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1573a27c3712d8ab232b85d33710626988100e98f52f00f6d4d11ef0168c1c27f53ce1ab97b73708507d5ee2b53ee7093b56ab43ae2b75a73fa05554b4e482cf
|
7
|
+
data.tar.gz: ca4b98cad31184e0695249cfbf919f02b7c36798a60911d23bf389f3752f11adb055c52f68b8d61ae4116fa574f14b403312f9d39c4f59720c86fa9048802fbe
|
data/CHANGELOG.md
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
7.2.
|
1
|
+
7.2.4
|
data/test/cases/coerced_tests.rb
CHANGED
@@ -376,6 +376,18 @@ module ActiveRecord
|
|
376
376
|
end
|
377
377
|
|
378
378
|
class CalculationsTest < ActiveRecord::TestCase
|
379
|
+
# SELECT columns must be in the GROUP clause.
|
380
|
+
coerce_tests! :test_should_count_with_group_by_qualified_name_on_loaded
|
381
|
+
def test_should_count_with_group_by_qualified_name_on_loaded_coerced
|
382
|
+
accounts = Account.group("accounts.id").select("accounts.id")
|
383
|
+
expected = { 1 => 1, 2 => 1, 3 => 1, 4 => 1, 5 => 1, 6 => 1 }
|
384
|
+
assert_not_predicate accounts, :loaded?
|
385
|
+
assert_equal expected, accounts.count
|
386
|
+
accounts.load
|
387
|
+
assert_predicate accounts, :loaded?
|
388
|
+
assert_equal expected, accounts.count(:id)
|
389
|
+
end
|
390
|
+
|
379
391
|
# Fix randomly failing test. The loading of the model's schema was affecting the test.
|
380
392
|
coerce_tests! :test_offset_is_kept
|
381
393
|
def test_offset_is_kept_coerced
|
@@ -101,5 +101,11 @@ class SchemaTestSQLServer < ActiveRecord::TestCase
|
|
101
101
|
assert_equal "[with].[select notation]", connection.send(:get_raw_table_name, "INSERT INTO [with].[select notation] SELECT * FROM [table_name]")
|
102
102
|
end
|
103
103
|
end
|
104
|
+
|
105
|
+
describe 'CREATE VIEW statements' do
|
106
|
+
it do
|
107
|
+
assert_equal "test_table_as", connection.send(:get_raw_table_name, "CREATE VIEW test_views ( test_table_a_id, test_table_b_id ) AS SELECT test_table_as.id as test_table_a_id, test_table_bs.id as test_table_b_id FROM (test_table_as with(nolock) LEFT JOIN test_table_bs with(nolock) ON (test_table_as.id = test_table_bs.test_table_a_id))")
|
108
|
+
end
|
109
|
+
end
|
104
110
|
end
|
105
111
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activerecord-sqlserver-adapter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.2.
|
4
|
+
version: 7.2.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ken Collins
|
@@ -15,7 +15,7 @@ authors:
|
|
15
15
|
autorequire:
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
|
-
date:
|
18
|
+
date: 2025-01-08 00:00:00.000000000 Z
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
21
|
name: activerecord
|
@@ -239,8 +239,8 @@ licenses:
|
|
239
239
|
- MIT
|
240
240
|
metadata:
|
241
241
|
bug_tracker_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/issues
|
242
|
-
changelog_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/blob/v7.2.
|
243
|
-
source_code_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/tree/v7.2.
|
242
|
+
changelog_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/blob/v7.2.4/CHANGELOG.md
|
243
|
+
source_code_uri: https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/tree/v7.2.4
|
244
244
|
post_install_message:
|
245
245
|
rdoc_options: []
|
246
246
|
require_paths:
|