with_model 1.2.0 → 1.2.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e58c6b921cca191793c25a9d245ed3783b5438dd
4
- data.tar.gz: 51c4bdcdde34e76a3f807b8feb92f7752479a35d
3
+ metadata.gz: fa91ae8171d006cf36ea0fe3f849f5087d5e2e42
4
+ data.tar.gz: 9b709891a0c2eed053f23ab153d54aa7af0929d7
5
5
  SHA512:
6
- metadata.gz: 33c20fcfd6aaa8efc10ffd72b41dba4d115e4ed146dacf42b7b980df368475001a6e72b47a2e99725a46a35836e92571c343d9693527685d5e1b3361ad0933ec
7
- data.tar.gz: 6914dc77114c8b787b210b6a4618857bac68dc51823d5d80d46b97ab6ee733d338689246551c231d78907105aeb1c9856b8a7abf00ede6619769cb6052391c79
6
+ metadata.gz: 9c771d0886b9f2c57ba44c035c4fad21a6c83ac26af2234bbc07c22c267e433af91fbe8c30315422f433d5ff687adc62925a7e0c4e1c765b716203f5fac5501b
7
+ data.tar.gz: f09b067cdfd82d425bc9ca698be041e4f809841bee41b7843d3595dcfd283ea9468d7102addcde1aa752a5defd98259ea99076e6354b8f418e4bd5bdf52b733d
data/.gitignore CHANGED
@@ -1,9 +1,17 @@
1
- pkg/*
2
- doc
3
- coverage
4
- Gemfile.lock
5
- .rvmrc
6
- .idea
7
- .bundle
8
- *.rbc
9
1
  *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
data/.travis.yml CHANGED
@@ -1,16 +1,18 @@
1
1
  language: ruby
2
2
 
3
3
  rvm:
4
- - 1.9.3
5
- - 2.0.0
6
- - 2.1.1
4
+ - "1.9"
5
+ - "2.0"
6
+ - "2.1"
7
7
  - jruby-19mode
8
- - rbx-2.2
8
+ - rbx-2
9
+
10
+ install:
11
+ - bundle install --retry=3
9
12
 
10
13
  env:
11
14
  - ACTIVE_RECORD_BRANCH="master"
12
- - ACTIVE_RECORD_BRANCH="4-1-stable"
13
- - ACTIVE_RECORD_BRANCH="4-0-stable"
15
+ - ACTIVE_RECORD_VERSION="~> 4.2.0"
14
16
  - ACTIVE_RECORD_VERSION="~> 4.1.0"
15
17
  - ACTIVE_RECORD_VERSION="~> 4.0.0"
16
18
  - ACTIVE_RECORD_VERSION="~> 3.2.0"
@@ -20,5 +22,10 @@ env:
20
22
  matrix:
21
23
  allow_failures:
22
24
  - env: ACTIVE_RECORD_BRANCH="master"
23
- - env: ACTIVE_RECORD_BRANCH="4-1-stable"
24
- - env: ACTIVE_RECORD_BRANCH="4-0-stable"
25
+ exclude:
26
+ - env: ACTIVE_RECORD_BRANCH="master"
27
+ rvm: "1.9"
28
+ - env: ACTIVE_RECORD_BRANCH="master"
29
+ rvm: "2.0"
30
+ - env: ACTIVE_RECORD_BRANCH="master"
31
+ rvm: jruby-19mode
data/Gemfile CHANGED
@@ -2,7 +2,7 @@ source 'https://rubygems.org'
2
2
 
3
3
  gemspec
4
4
 
5
- gem 'activerecord', :github => 'rails', :branch => ENV['ACTIVE_RECORD_BRANCH'] if ENV['ACTIVE_RECORD_BRANCH']
5
+ gem 'activerecord', :git => 'https://github.com/rails/rails.git', :branch => ENV['ACTIVE_RECORD_BRANCH'] if ENV['ACTIVE_RECORD_BRANCH']
6
6
  gem 'activerecord', ENV['ACTIVE_RECORD_VERSION'] if ENV['ACTIVE_RECORD_VERSION']
7
7
  gem 'activerecord-jdbcsqlite3-adapter', :platforms => :jruby
8
8
  gem 'coveralls', :require => false, :platforms => :mri_20
data/README.md CHANGED
@@ -1,10 +1,9 @@
1
1
  # [with_model](https://github.com/Casecommons/with_model)
2
2
 
3
3
  [![Build Status](https://secure.travis-ci.org/Casecommons/with_model.svg?branch=master)](https://travis-ci.org/Casecommons/with_model)
4
- [![Code Climate](https://img.shields.io/codeclimate/github/Casecommons/with_model.svg)](https://codeclimate.com/github/Casecommons/with_model)
5
- [![Coverage Status](https://img.shields.io/coveralls/Casecommons/with_model/master.svg)](https://coveralls.io/r/Casecommons/with_model)
6
- [![Gem Version](https://badge.fury.io/rb/with_model.svg)](https://rubygems.org/gems/with_model)
7
- [![Dependency Status](https://gemnasium.com/Casecommons/with_model.svg)](https://gemnasium.com/Casecommons/with_model)
4
+ [![Code Climate](https://img.shields.io/codeclimate/github/Casecommons/with_model.svg?style=flat)](https://codeclimate.com/github/Casecommons/with_model)
5
+ [![Coverage Status](https://img.shields.io/coveralls/Casecommons/with_model/master.svg?style=flat)](https://coveralls.io/r/Casecommons/with_model)
6
+ [![Gem Version](https://img.shields.io/gem/v/with_model.svg?style=flat)](https://rubygems.org/gems/with_model)
8
7
 
9
8
  `with_model` dynamically builds an ActiveRecord model (with table) before each test in a group and destroys it afterwards.
10
9
 
@@ -56,7 +55,7 @@ describe "A blog post" do
56
55
  # The table block works just like a migration.
57
56
  table do |t|
58
57
  t.string :title
59
- t.timestamps
58
+ t.timestamps null: false
60
59
  end
61
60
 
62
61
  # The model block works just like the class definition.
@@ -80,7 +79,7 @@ describe "A blog post" do
80
79
  table do |t|
81
80
  t.string :text
82
81
  t.belongs_to :blog_post
83
- t.timestamps
82
+ t.timestamps null: false
84
83
  end
85
84
 
86
85
  model do
@@ -154,7 +153,7 @@ describe "with table options" do
154
153
  with_model :WithOptions do
155
154
  table :id => false do |t|
156
155
  t.string 'foo'
157
- t.timestamps
156
+ t.timestamps null: false
158
157
  end
159
158
  end
160
159
 
@@ -1,3 +1,3 @@
1
1
  module WithModel
2
- VERSION = '1.2.0'.freeze
2
+ VERSION = '1.2.1'.freeze
3
3
  end
@@ -11,7 +11,7 @@ describe "ActiveRecord behaviors" do
11
11
  @regular_model.connection.create_table(@regular_model.table_name, force: true) do |t|
12
12
  t.string 'title'
13
13
  t.text 'content'
14
- t.timestamps
14
+ t.timestamps null: false
15
15
  end
16
16
  end
17
17
 
@@ -23,7 +23,7 @@ describe "ActiveRecord behaviors" do
23
23
  table do |t|
24
24
  t.string 'title'
25
25
  t.text 'content'
26
- t.timestamps
26
+ t.timestamps null: false
27
27
  end
28
28
 
29
29
  model do
data/spec/readme_spec.rb CHANGED
@@ -13,7 +13,7 @@ describe "A blog post" do
13
13
  # The table block works just like a migration.
14
14
  table do |t|
15
15
  t.string :title
16
- t.timestamps
16
+ t.timestamps null: false
17
17
  end
18
18
 
19
19
  # The model block works just like the class definition.
@@ -37,7 +37,7 @@ describe "A blog post" do
37
37
  table do |t|
38
38
  t.string :text
39
39
  t.belongs_to :blog_post
40
- t.timestamps
40
+ t.timestamps null: false
41
41
  end
42
42
 
43
43
  model do
@@ -111,7 +111,7 @@ describe "with table options" do
111
111
  with_model :WithOptions do
112
112
  table :id => false do |t|
113
113
  t.string 'foo'
114
- t.timestamps
114
+ t.timestamps null: false
115
115
  end
116
116
  end
117
117
 
@@ -27,7 +27,7 @@ describe "a temporary ActiveRecord model created with with_model" do
27
27
  table do |t|
28
28
  t.string 'title'
29
29
  t.text 'content'
30
- t.timestamps
30
+ t.timestamps null: false
31
31
  end
32
32
 
33
33
  model do
@@ -203,7 +203,7 @@ describe "a temporary ActiveRecord model created with with_model" do
203
203
  with_model :WithOptions do
204
204
  table :id => false do |t|
205
205
  t.string 'foo'
206
- t.timestamps
206
+ t.timestamps null: false
207
207
  end
208
208
  end
209
209
 
@@ -249,7 +249,7 @@ describe "a temporary ActiveRecord model created with with_model" do
249
249
  table do |t|
250
250
  t.string 'title'
251
251
  t.text 'content'
252
- t.timestamps
252
+ t.timestamps null: false
253
253
  end
254
254
  end
255
255
 
data/with_model.gemspec CHANGED
@@ -19,11 +19,9 @@ Gem::Specification.new do |spec|
19
19
 
20
20
  spec.required_ruby_version = '>= 1.9.3'
21
21
 
22
- spec.add_dependency 'activerecord', '>= 3.0', '< 4.2'
22
+ spec.add_dependency 'activerecord', '>= 3.0'
23
23
 
24
24
  spec.add_development_dependency 'bundler', '~> 1.3'
25
25
  spec.add_development_dependency 'rake'
26
- spec.add_development_dependency 'rspec', '>= 2.14', '< 4'
27
- spec.add_development_dependency 'rubysl' if RUBY_ENGINE == 'rbx'
28
- spec.add_development_dependency 'rubysl-test-unit' if RUBY_ENGINE == 'rbx'
26
+ spec.add_development_dependency 'rspec', '~> 3.0'
29
27
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: with_model
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Case Commons, LLC
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-06-18 00:00:00.000000000 Z
12
+ date: 2014-12-29 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activerecord
@@ -18,9 +18,6 @@ dependencies:
18
18
  - - ">="
19
19
  - !ruby/object:Gem::Version
20
20
  version: '3.0'
21
- - - "<"
22
- - !ruby/object:Gem::Version
23
- version: '4.2'
24
21
  type: :runtime
25
22
  prerelease: false
26
23
  version_requirements: !ruby/object:Gem::Requirement
@@ -28,9 +25,6 @@ dependencies:
28
25
  - - ">="
29
26
  - !ruby/object:Gem::Version
30
27
  version: '3.0'
31
- - - "<"
32
- - !ruby/object:Gem::Version
33
- version: '4.2'
34
28
  - !ruby/object:Gem::Dependency
35
29
  name: bundler
36
30
  requirement: !ruby/object:Gem::Requirement
@@ -63,22 +57,16 @@ dependencies:
63
57
  name: rspec
64
58
  requirement: !ruby/object:Gem::Requirement
65
59
  requirements:
66
- - - ">="
67
- - !ruby/object:Gem::Version
68
- version: '2.14'
69
- - - "<"
60
+ - - "~>"
70
61
  - !ruby/object:Gem::Version
71
- version: '4'
62
+ version: '3.0'
72
63
  type: :development
73
64
  prerelease: false
74
65
  version_requirements: !ruby/object:Gem::Requirement
75
66
  requirements:
76
- - - ">="
77
- - !ruby/object:Gem::Version
78
- version: '2.14'
79
- - - "<"
67
+ - - "~>"
80
68
  - !ruby/object:Gem::Version
81
- version: '4'
69
+ version: '3.0'
82
70
  description: Dynamically build a model within an RSpec context
83
71
  email:
84
72
  - casecommons-dev@googlegroups.com
@@ -128,7 +116,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
128
116
  version: '0'
129
117
  requirements: []
130
118
  rubyforge_project:
131
- rubygems_version: 2.3.0
119
+ rubygems_version: 2.4.4
132
120
  signing_key:
133
121
  specification_version: 4
134
122
  summary: Dynamically build a model within an RSpec context