activerecord_views 0.0.16 → 0.0.17
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/lib/active_record_views/version.rb +1 -1
- data/lib/tasks/active_record_views.rake +1 -1
- data/spec/active_record_views_spec.rb +1 -1
- data/spec/tasks_spec.rb +2 -2
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: b2627c1dce47cf8e2c072dc3e47c36792dac3d2f1ff21271dc0c3268e502f386
|
4
|
+
data.tar.gz: e7faba517dfd15a41741c87e7657dd9e190e8b5a1047c155e18f8bfd300de3be
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d93b3071f407c190a08c52f8bc998600049971bd1751ecf1f1a1b05682061b4e75d1d5ec2aa46d32feb54b24ba2153045644a0c22e1e6a595e4e6b212b44f857
|
7
|
+
data.tar.gz: f3df8e14207b91c5be93f40473ef63f4b3d56a52075d875c2e624edda16fe1594e9cb01bd9faa08ecf0408354cb7dd244c7d2dec1d0b14cb3635ce23aabe6c5f
|
@@ -18,7 +18,7 @@ Rake::Task['db:structure:dump'].enhance do
|
|
18
18
|
raise 'active_record_views metadata dump failed' unless $?.success?
|
19
19
|
|
20
20
|
File.open filename, 'a' do |io|
|
21
|
-
io.puts 'UPDATE active_record_views SET refreshed_at = NULL WHERE refreshed_at IS NOT NULL;'
|
21
|
+
io.puts 'UPDATE public.active_record_views SET refreshed_at = NULL WHERE refreshed_at IS NOT NULL;'
|
22
22
|
end
|
23
23
|
end
|
24
24
|
end
|
@@ -205,7 +205,7 @@ describe ActiveRecordViews do
|
|
205
205
|
it 'supports creating unique indexes on materialized views' do
|
206
206
|
create_test_view 'select 1 as foo, 2 as bar, 3 as baz', materialized: true, unique_columns: [:foo, 'bar']
|
207
207
|
index_sql = connection.select_value("SELECT indexdef FROM pg_indexes WHERE schemaname = 'public' AND indexname = 'test_pkey';")
|
208
|
-
expect(index_sql).to eq 'CREATE UNIQUE INDEX test_pkey ON test USING btree (foo, bar)'
|
208
|
+
expect(index_sql).to eq 'CREATE UNIQUE INDEX test_pkey ON public.test USING btree (foo, bar)'
|
209
209
|
end
|
210
210
|
|
211
211
|
it 'errors if trying to create unique index on non-materialized view' do
|
data/spec/tasks_spec.rb
CHANGED
@@ -11,7 +11,7 @@ describe 'rake db:structure:dump' do
|
|
11
11
|
sql = File.read('spec/internal/db/structure.sql')
|
12
12
|
FileUtils.rm_f 'spec/internal/db/structure.sql'
|
13
13
|
|
14
|
-
expect(sql).to match(/COPY active_record_views.+test_view\tTestView/m)
|
15
|
-
expect(sql).to match(/UPDATE active_record_views SET refreshed_at = NULL/)
|
14
|
+
expect(sql).to match(/COPY public\.active_record_views.+test_view\tTestView/m)
|
15
|
+
expect(sql).to match(/UPDATE public\.active_record_views SET refreshed_at = NULL/)
|
16
16
|
end
|
17
17
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activerecord_views
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.17
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jason Weathered
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-03-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -155,7 +155,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
155
155
|
version: '0'
|
156
156
|
requirements: []
|
157
157
|
rubyforge_project:
|
158
|
-
rubygems_version: 2.6
|
158
|
+
rubygems_version: 2.7.6
|
159
159
|
signing_key:
|
160
160
|
specification_version: 4
|
161
161
|
summary: Automatic database view creation for ActiveRecord
|