pg_audit_log 0.6.0 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rspec +1 -1
- data/lib/pg_audit_log/extensions/postgresql_adapter.rb +1 -0
- data/lib/pg_audit_log/version.rb +1 -1
- data/pg_audit_log.gemspec +1 -1
- data/spec/pg_audit_log_spec.rb +9 -0
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3a44d380da2ae044f211eb1ef93271c533bb7873
|
4
|
+
data.tar.gz: ba9618687337d3f033319baa07f7fb59e0662c8f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a10362edd035d160eeb5e086628b9b6017c63c5c66794f17029b1103770f1b5054b244737b1facc835c31c57d2f4101665bc46185e6b2a5d5ab507a359e0cd64
|
7
|
+
data.tar.gz: 56e04973995ef7e880148a6daa5de455b6252c8de0db7864b1974aadc3129311876dd3f3b1f830e936c7450cd20e3383ccdf23435996f6427b826ecba71852db
|
data/.rspec
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
--format
|
1
|
+
--format documentation
|
2
2
|
--color
|
@@ -14,6 +14,7 @@ class ActiveRecord::ConnectionAdapters::PostgreSQLAdapter
|
|
14
14
|
create_table_without_auditing(table_name, options, &block)
|
15
15
|
unless options[:temporary] ||
|
16
16
|
PgAuditLog::IGNORED_TABLES.include?(table_name) ||
|
17
|
+
PgAuditLog::IGNORED_TABLES.any? { |table| table =~ table_name if table.is_a? Regexp } ||
|
17
18
|
PgAuditLog::Triggers.tables_with_triggers.include?(table_name)
|
18
19
|
PgAuditLog::Triggers.create_for_table(table_name)
|
19
20
|
end
|
data/lib/pg_audit_log/version.rb
CHANGED
data/pg_audit_log.gemspec
CHANGED
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
|
|
21
21
|
|
22
22
|
spec.add_dependency 'rails', '>= 3.2', '< 4.2'
|
23
23
|
spec.add_dependency 'pg', '>= 0.9.0'
|
24
|
-
spec.add_development_dependency 'rspec'
|
24
|
+
spec.add_development_dependency 'rspec', '2.14.1'
|
25
25
|
spec.add_development_dependency 'rspec-rails'
|
26
26
|
spec.add_development_dependency 'with_model', '>= 0.1.3'
|
27
27
|
end
|
data/spec/pg_audit_log_spec.rb
CHANGED
@@ -338,5 +338,14 @@ describe PgAuditLog do
|
|
338
338
|
connection.drop_table('ignored_table')
|
339
339
|
end
|
340
340
|
end
|
341
|
+
|
342
|
+
context "when creating one of those tables that matches a regexp" do
|
343
|
+
it "should not automatically create a trigger for it" do
|
344
|
+
PgAuditLog::IGNORED_TABLES << /ignored_table/
|
345
|
+
connection.create_table('second_ignored_table')
|
346
|
+
PgAuditLog::Triggers.tables_with_triggers.should_not include('second_ignored_table')
|
347
|
+
connection.drop_table('second_ignored_table')
|
348
|
+
end
|
349
|
+
end
|
341
350
|
end
|
342
351
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pg_audit_log
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Case Commons, LLC
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-10-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -48,16 +48,16 @@ dependencies:
|
|
48
48
|
name: rspec
|
49
49
|
requirement: !ruby/object:Gem::Requirement
|
50
50
|
requirements:
|
51
|
-
- -
|
51
|
+
- - '='
|
52
52
|
- !ruby/object:Gem::Version
|
53
|
-
version:
|
53
|
+
version: 2.14.1
|
54
54
|
type: :development
|
55
55
|
prerelease: false
|
56
56
|
version_requirements: !ruby/object:Gem::Requirement
|
57
57
|
requirements:
|
58
|
-
- -
|
58
|
+
- - '='
|
59
59
|
- !ruby/object:Gem::Version
|
60
|
-
version:
|
60
|
+
version: 2.14.1
|
61
61
|
- !ruby/object:Gem::Dependency
|
62
62
|
name: rspec-rails
|
63
63
|
requirement: !ruby/object:Gem::Requirement
|
@@ -144,7 +144,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
144
144
|
version: '0'
|
145
145
|
requirements: []
|
146
146
|
rubyforge_project:
|
147
|
-
rubygems_version: 2.
|
147
|
+
rubygems_version: 2.4.2
|
148
148
|
signing_key:
|
149
149
|
specification_version: 4
|
150
150
|
summary: PostgreSQL-only database-level audit logging of all databases changes.
|