clean_model 0.0.8 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 291805503fe051f6355d448b0edc4685fc9e7dfe
4
+ data.tar.gz: dd566abe70a6a631887d6c06c0ef71e5aea4903c
5
+ SHA512:
6
+ metadata.gz: eb6959d0e814e559c6a8ce46bd9661168f6732b3021ae28fa2f3ebe2312b7f302c9e3f975062aa40c84f5ac1eeb3949035f2718bc3b4140d98062aea2ab82438
7
+ data.tar.gz: c05ca172db8ff1a7df2f61332dc7791e311175d3a87394e0bfe46f9b58c01a00d5ccd9bcdc06a57e744ded0db90fdb8a2ff2bad0e4ae6a1a9c574957837d8397
data/.coveralls.yml ADDED
@@ -0,0 +1,2 @@
1
+ service_name: travis-ci
2
+ repo_token: NxxSqeXoO3pvmPFzPqqm7a6MU9zlf2IvQ
data/.gitignore CHANGED
@@ -3,3 +3,4 @@
3
3
  Gemfile.lock
4
4
  pkg/*
5
5
  .idea
6
+ coverage
data/.travis.yml CHANGED
@@ -3,5 +3,4 @@ rvm:
3
3
  - 1.9.2
4
4
  - 1.9.3
5
5
  - 2.0
6
- - jruby
7
- script: bundle exec rspec spec
6
+ - jruby
data/Gemfile CHANGED
@@ -2,3 +2,5 @@ source "http://rubygems.org"
2
2
 
3
3
  # Specify your gem's dependencies in clean_model.gemspec
4
4
  gemspec
5
+
6
+ gem 'coveralls', require: false
data/README.md CHANGED
@@ -1,6 +1,10 @@
1
1
  # CleanModel
2
2
 
3
+ [![Gem Version](https://badge.fury.io/rb/clean_model.png)](https://rubygems.org/gems/clean_model)
3
4
  [![Build Status](https://travis-ci.org/gabynaiman/clean_model.png?branch=master)](https://travis-ci.org/gabynaiman/clean_model)
5
+ [![Coverage Status](https://coveralls.io/repos/gabynaiman/clean_model/badge.png?branch=master)](https://coveralls.io/r/gabynaiman/clean_model?branch=master)
6
+ [![Code Climate](https://codeclimate.com/github/gabynaiman/clean_model.png)](https://codeclimate.com/github/gabynaiman/clean_model)
7
+ [![Dependency Status](https://gemnasium.com/gabynaiman/clean_model.png)](https://gemnasium.com/gabynaiman/clean_model)
4
8
 
5
9
  Extensions for ActiveModel to implement multiple types of models
6
10
 
data/Rakefile CHANGED
@@ -1 +1,11 @@
1
1
  require "bundler/gem_tasks"
2
+ require 'rspec/core/rake_task'
3
+
4
+ RSpec::Core::RakeTask.new do |task|
5
+ task.pattern = 'spec/**/*_spec.rb'
6
+ task.rspec_opts = '--tty --color -f documentation'
7
+ task.verbose = false
8
+ end
9
+
10
+ task default: :spec
11
+
data/clean_model.gemspec CHANGED
@@ -1,24 +1,28 @@
1
1
  # -*- encoding: utf-8 -*-
2
- $:.push File.expand_path("../lib", __FILE__)
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
4
  require 'clean_model/version'
4
5
 
5
- Gem::Specification.new do |s|
6
- s.name = 'clean_model'
7
- s.version = CleanModel::VERSION
8
- s.authors = ['Gabriel Naiman']
9
- s.email = ['gabynaiman@gmail.com']
10
- s.homepage = 'https://github.com/gabynaiman/clean_model'
11
- s.summary = 'Extensions for ActiveModel to implement multiple types of models'
12
- s.description = 'Extensions for ActiveModel to implement multiple types of models'
6
+ Gem::Specification.new do |spec|
7
+ spec.name = 'clean_model'
8
+ spec.version = CleanModel::VERSION
9
+ spec.authors = ['Gabriel Naiman']
10
+ spec.email = ['gabynaiman@gmail.com']
11
+ spec.homepage = 'https://github.com/gabynaiman/clean_model'
12
+ spec.summary = 'Extensions for ActiveModel to implement multiple types of models'
13
+ spec.description = 'Extensions for ActiveModel to implement multiple types of models'
13
14
 
14
- s.files = `git ls-files`.split("\n")
15
- s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
16
- s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
17
- s.require_paths = ["lib"]
15
+ spec.files = `git ls-files`.split($/)
16
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
17
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
18
+ spec.require_paths = ['lib']
18
19
 
19
- s.add_dependency 'activemodel', '>= 3.0.0'
20
- s.add_dependency 'web_client', '~> 0.0'
20
+ spec.add_dependency 'activemodel', '~> 3.2'
21
+ spec.add_dependency 'web_client', '0.0.5'
21
22
 
22
- s.add_development_dependency 'rspec'
23
- s.add_development_dependency 'webmock'
23
+ spec.add_development_dependency 'bundler', '~> 1.3'
24
+ spec.add_development_dependency 'rake'
25
+ spec.add_development_dependency 'rspec', '2.13.0'
26
+ spec.add_development_dependency 'webmock'
27
+ spec.add_development_dependency 'simplecov'
24
28
  end
@@ -27,6 +27,7 @@ module CleanModel
27
27
  save_fail(response)
28
28
  end
29
29
  rescue WebClient::Error => ex
30
+ puts ex.inspect
30
31
  errors[:base] = ex.message
31
32
  end
32
33
  errors.empty?
@@ -1,3 +1,3 @@
1
1
  module CleanModel
2
- VERSION = '0.0.8'
2
+ VERSION = '0.0.9'
3
3
  end
@@ -0,0 +1,8 @@
1
+ require 'simplecov'
2
+ require 'coveralls'
3
+
4
+ SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
5
+ SimpleCov::Formatter::HTMLFormatter,
6
+ Coveralls::SimpleCov::Formatter
7
+ ]
8
+ SimpleCov.start
data/spec/spec_helper.rb CHANGED
@@ -1,8 +1,5 @@
1
+ require 'coverage_helper'
1
2
  require 'webmock/rspec'
2
3
  require 'clean_model'
3
4
 
4
5
  Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
5
-
6
- RSpec.configure do |config|
7
-
8
- end
metadata CHANGED
@@ -1,78 +1,111 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: clean_model
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
5
- prerelease:
4
+ version: 0.0.9
6
5
  platform: ruby
7
6
  authors:
8
7
  - Gabriel Naiman
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2013-04-04 00:00:00.000000000 Z
11
+ date: 2014-07-14 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: activemodel
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
- - - ! '>='
17
+ - - ~>
20
18
  - !ruby/object:Gem::Version
21
- version: 3.0.0
19
+ version: '3.2'
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
- version: 3.0.0
26
+ version: '3.2'
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: web_client
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
- - - ~>
31
+ - - '='
36
32
  - !ruby/object:Gem::Version
37
- version: '0.0'
33
+ version: 0.0.5
38
34
  type: :runtime
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
37
+ requirements:
38
+ - - '='
39
+ - !ruby/object:Gem::Version
40
+ version: 0.0.5
41
+ - !ruby/object:Gem::Dependency
42
+ name: bundler
43
+ requirement: !ruby/object:Gem::Requirement
42
44
  requirements:
43
45
  - - ~>
44
46
  - !ruby/object:Gem::Version
45
- version: '0.0'
47
+ version: '1.3'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ~>
53
+ - !ruby/object:Gem::Version
54
+ version: '1.3'
46
55
  - !ruby/object:Gem::Dependency
47
- name: rspec
56
+ name: rake
48
57
  requirement: !ruby/object:Gem::Requirement
49
- none: false
50
58
  requirements:
51
- - - ! '>='
59
+ - - '>='
52
60
  - !ruby/object:Gem::Version
53
61
  version: '0'
54
62
  type: :development
55
63
  prerelease: false
56
64
  version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
65
  requirements:
59
- - - ! '>='
66
+ - - '>='
60
67
  - !ruby/object:Gem::Version
61
68
  version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: rspec
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - '='
74
+ - !ruby/object:Gem::Version
75
+ version: 2.13.0
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - '='
81
+ - !ruby/object:Gem::Version
82
+ version: 2.13.0
62
83
  - !ruby/object:Gem::Dependency
63
84
  name: webmock
64
85
  requirement: !ruby/object:Gem::Requirement
65
- none: false
66
86
  requirements:
67
- - - ! '>='
87
+ - - '>='
68
88
  - !ruby/object:Gem::Version
69
89
  version: '0'
70
90
  type: :development
71
91
  prerelease: false
72
92
  version_requirements: !ruby/object:Gem::Requirement
73
- none: false
74
93
  requirements:
75
- - - ! '>='
94
+ - - '>='
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: simplecov
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - '>='
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - '>='
76
109
  - !ruby/object:Gem::Version
77
110
  version: '0'
78
111
  description: Extensions for ActiveModel to implement multiple types of models
@@ -82,6 +115,7 @@ executables: []
82
115
  extensions: []
83
116
  extra_rdoc_files: []
84
117
  files:
118
+ - .coveralls.yml
85
119
  - .gitignore
86
120
  - .travis.yml
87
121
  - Gemfile
@@ -96,6 +130,7 @@ files:
96
130
  - lib/clean_model/remote.rb
97
131
  - lib/clean_model/version.rb
98
132
  - spec/base_model_spec.rb
133
+ - spec/coverage_helper.rb
99
134
  - spec/persistent_model_spec.rb
100
135
  - spec/remote_models_spec.rb
101
136
  - spec/spec_helper.rb
@@ -104,27 +139,33 @@ files:
104
139
  - spec/support/models/remote_models.rb
105
140
  homepage: https://github.com/gabynaiman/clean_model
106
141
  licenses: []
142
+ metadata: {}
107
143
  post_install_message:
108
144
  rdoc_options: []
109
145
  require_paths:
110
146
  - lib
111
147
  required_ruby_version: !ruby/object:Gem::Requirement
112
- none: false
113
148
  requirements:
114
- - - ! '>='
149
+ - - '>='
115
150
  - !ruby/object:Gem::Version
116
151
  version: '0'
117
152
  required_rubygems_version: !ruby/object:Gem::Requirement
118
- none: false
119
153
  requirements:
120
- - - ! '>='
154
+ - - '>='
121
155
  - !ruby/object:Gem::Version
122
156
  version: '0'
123
157
  requirements: []
124
158
  rubyforge_project:
125
- rubygems_version: 1.8.24
159
+ rubygems_version: 2.2.2
126
160
  signing_key:
127
- specification_version: 3
161
+ specification_version: 4
128
162
  summary: Extensions for ActiveModel to implement multiple types of models
129
- test_files: []
130
- has_rdoc:
163
+ test_files:
164
+ - spec/base_model_spec.rb
165
+ - spec/coverage_helper.rb
166
+ - spec/persistent_model_spec.rb
167
+ - spec/remote_models_spec.rb
168
+ - spec/spec_helper.rb
169
+ - spec/support/models/base_models.rb
170
+ - spec/support/models/persistent_models.rb
171
+ - spec/support/models/remote_models.rb