cia 0.5.6 → 0.5.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 095757bdffb2cf6dd9966a37562bd4a61958fd20
4
+ data.tar.gz: d01a2b7a29c0791224934dcf4a012a20cc60c512
5
+ SHA512:
6
+ metadata.gz: 377d5103d09854f5dac67ae4fcc9e84ee3bc94ec51519a19b5dfa97b3482bb15198dda28a543121eb5a44ff6a765b947c95f045982e080b90aa978c46a6d6a55
7
+ data.tar.gz: 4d940a36f27b7108e609509ae6b76d8eba745b33f59cb634ac5b1ec0530a85d056ab4857a63e133b1fb5f0f4d884c096705a4c5b255844c1c5b6a743785b64d6
data/.travis.yml CHANGED
@@ -1,3 +1,12 @@
1
+ bundler_args: ""
1
2
  rvm:
2
3
  - 1.9.3
3
4
  - 2.0.0
5
+ gemfile:
6
+ - gemfiles/rails2.gemfile
7
+ - gemfiles/rails3.gemfile
8
+ matrix:
9
+ exclude:
10
+ - rvm: 2.0.0
11
+ gemfile: gemfiles/rails2.gemfile
12
+ script: bundle exec rake spec
data/Gemfile CHANGED
@@ -5,5 +5,6 @@ gem 'bump'
5
5
  gem 'rake'
6
6
  gem 'rspec', '~>2'
7
7
  gem 'appraisal'
8
+ gem 'wwtd'
8
9
  gem 'activerecord'
9
10
  gem 'sqlite3'
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- cia (0.5.6)
4
+ cia (0.5.7)
5
5
  json
6
6
 
7
7
  GEM
@@ -26,7 +26,7 @@ GEM
26
26
  bump (0.3.9)
27
27
  diff-lcs (1.1.3)
28
28
  i18n (0.6.1)
29
- json (1.8.0)
29
+ json (1.8.1)
30
30
  multi_json (1.5.0)
31
31
  rake (10.0.3)
32
32
  rspec (2.12.0)
@@ -39,6 +39,7 @@ GEM
39
39
  rspec-mocks (2.12.1)
40
40
  sqlite3 (1.3.6)
41
41
  tzinfo (0.3.35)
42
+ wwtd (0.4.4)
42
43
 
43
44
  PLATFORMS
44
45
  ruby
@@ -51,3 +52,4 @@ DEPENDENCIES
51
52
  rake
52
53
  rspec (~> 2)
53
54
  sqlite3
55
+ wwtd
data/Rakefile CHANGED
@@ -1,10 +1,10 @@
1
+ require 'bundler/setup'
1
2
  require 'appraisal'
2
3
  require 'bundler/gem_tasks'
3
4
  require 'bump/tasks'
5
+ require 'wwtd/tasks'
4
6
 
5
- task :default do
6
- sh "bundle exec rake appraisal:install && bundle exec rake appraisal spec"
7
- end
7
+ task :default => ["appraisal:gemfiles", :wwtd]
8
8
 
9
9
  task :spec do
10
10
  sh "rspec spec/"
@@ -6,6 +6,7 @@ gem "bump"
6
6
  gem "rake"
7
7
  gem "rspec", "~>2"
8
8
  gem "appraisal"
9
+ gem "wwtd"
9
10
  gem "sqlite3"
10
11
  gem "activerecord", "2.3.14"
11
12
  gem "after_commit"
@@ -1,7 +1,7 @@
1
1
  PATH
2
- remote: /Users/mgrosser/code/tools/cia
2
+ remote: ../
3
3
  specs:
4
- cia (0.5.5)
4
+ cia (0.5.6)
5
5
  json
6
6
 
7
7
  GEM
@@ -17,7 +17,7 @@ GEM
17
17
  rake
18
18
  bump (0.3.9)
19
19
  diff-lcs (1.1.3)
20
- json (1.8.0)
20
+ json (1.8.1)
21
21
  rake (0.9.2.2)
22
22
  rspec (2.10.0)
23
23
  rspec-core (~> 2.10.0)
@@ -28,6 +28,7 @@ GEM
28
28
  diff-lcs (~> 1.1.3)
29
29
  rspec-mocks (2.10.1)
30
30
  sqlite3 (1.3.6)
31
+ wwtd (0.4.4)
31
32
 
32
33
  PLATFORMS
33
34
  ruby
@@ -41,3 +42,4 @@ DEPENDENCIES
41
42
  rake
42
43
  rspec (~> 2)
43
44
  sqlite3
45
+ wwtd
@@ -6,6 +6,7 @@ gem "bump"
6
6
  gem "rake"
7
7
  gem "rspec", "~>2"
8
8
  gem "appraisal"
9
+ gem "wwtd"
9
10
  gem "sqlite3"
10
11
  gem "activerecord", "3.2.3"
11
12
 
@@ -1,7 +1,7 @@
1
1
  PATH
2
- remote: /Users/mgrosser/code/tools/cia
2
+ remote: ../
3
3
  specs:
4
- cia (0.5.5)
4
+ cia (0.5.6)
5
5
  json
6
6
 
7
7
  GEM
@@ -26,7 +26,7 @@ GEM
26
26
  bump (0.3.9)
27
27
  diff-lcs (1.1.3)
28
28
  i18n (0.6.1)
29
- json (1.8.0)
29
+ json (1.8.1)
30
30
  multi_json (1.5.0)
31
31
  rake (10.0.3)
32
32
  rspec (2.12.0)
@@ -39,6 +39,7 @@ GEM
39
39
  rspec-mocks (2.12.1)
40
40
  sqlite3 (1.3.6)
41
41
  tzinfo (0.3.35)
42
+ wwtd (0.4.4)
42
43
 
43
44
  PLATFORMS
44
45
  ruby
@@ -51,3 +52,4 @@ DEPENDENCIES
51
52
  rake
52
53
  rspec (~> 2)
53
54
  sqlite3
55
+ wwtd
data/lib/cia/event.rb CHANGED
@@ -5,7 +5,7 @@ module CIA
5
5
 
6
6
  belongs_to :actor, :polymorphic => true
7
7
  belongs_to :source, :polymorphic => true
8
- has_many :attribute_changes, :foreign_key => :cia_event_id
8
+ has_many :attribute_changes, :foreign_key => :cia_event_id, :dependent => :destroy
9
9
 
10
10
  validates_presence_of :action
11
11
 
data/lib/cia/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module CIA
2
- VERSION = '0.5.6'
2
+ VERSION = '0.5.7'
3
3
  end
@@ -4,6 +4,8 @@ describe CIA::Event do
4
4
  it "has many attribute_changes" do
5
5
  change = create_change
6
6
  change.event.attribute_changes.should == [change]
7
+ change.event.destroy
8
+ expect{ change.reload }.to raise_error(ActiveRecord::RecordNotFound)
7
9
  end
8
10
 
9
11
  context "attribute_change_hash" do
metadata CHANGED
@@ -1,30 +1,27 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cia
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.6
5
- prerelease:
4
+ version: 0.5.7
6
5
  platform: ruby
7
6
  authors:
8
7
  - Michael Grosser
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2013-10-03 00:00:00.000000000 Z
11
+ date: 2013-12-05 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: json
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
- - - ! '>='
17
+ - - '>='
20
18
  - !ruby/object:Gem::Version
21
19
  version: '0'
22
20
  type: :runtime
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
- - - ! '>='
24
+ - - '>='
28
25
  - !ruby/object:Gem::Version
29
26
  version: '0'
30
27
  description:
@@ -58,33 +55,26 @@ files:
58
55
  homepage: http://github.com/grosser/cia
59
56
  licenses:
60
57
  - MIT
58
+ metadata: {}
61
59
  post_install_message:
62
60
  rdoc_options: []
63
61
  require_paths:
64
62
  - lib
65
63
  required_ruby_version: !ruby/object:Gem::Requirement
66
- none: false
67
64
  requirements:
68
- - - ! '>='
65
+ - - '>='
69
66
  - !ruby/object:Gem::Version
70
67
  version: '0'
71
- segments:
72
- - 0
73
- hash: -2304256345469928152
74
68
  required_rubygems_version: !ruby/object:Gem::Requirement
75
- none: false
76
69
  requirements:
77
- - - ! '>='
70
+ - - '>='
78
71
  - !ruby/object:Gem::Version
79
72
  version: '0'
80
- segments:
81
- - 0
82
- hash: -2304256345469928152
83
73
  requirements: []
84
74
  rubyforge_project:
85
- rubygems_version: 1.8.25
75
+ rubygems_version: 2.0.3
86
76
  signing_key:
87
- specification_version: 3
77
+ specification_version: 4
88
78
  summary: Audit model events like update/create/delete + attribute changes + group
89
79
  them by transaction, in normalized table layout for easy query access.
90
80
  test_files: []