active_record_model_and_rspec_enhanced_templates 1.0.5 → 1.0.6

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: 306f4624e20cbd43aca2cd6013a39d34eff93ee1
4
- data.tar.gz: 35e57c8626cd571f5c35cb121b743899afe0a903
3
+ metadata.gz: 8541301cdf9f1e80fbb04d371092b33da54c74a9
4
+ data.tar.gz: 79874adf7c5d371e663df882b653c20788407b48
5
5
  SHA512:
6
- metadata.gz: b5307f86b374eb9f0f6474eb3bbe9c67690f2ca0a1a0851503ba639d971f30e6483ad8c0e129d57daf4c72013fc4c2301ca4d724dbc7fafedd4f7489b1fa94df
7
- data.tar.gz: 0855a238285021f79f080a3e2ebfcf33656157db3106f0b720b58aae913740e70980dfabc23b662beecf46e028e96069517f80bbf93d687976937ee6727c6a14
6
+ metadata.gz: eb987085fb3e138aa2840eaed56423318779e831b906f2b3bee87a321b3bb89099b581ca0f0e4f75bdddafed1e3d6e0c9232535697a062f7cec7b9cb61a5c970
7
+ data.tar.gz: e971eed383994e6b4d7f4e4a2431430375838f82c8eb3a90e641bc8028869274e3b9906c1fc46778498e28f09cd296908c13d51e35605ab4a1fec5e27adab025
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.5
1
+ 1.0.6
@@ -2,16 +2,16 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: active_record_model_and_rspec_enhanced_templates 1.0.5 ruby lib
5
+ # stub: active_record_model_and_rspec_enhanced_templates 1.0.6 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "active_record_model_and_rspec_enhanced_templates"
9
- s.version = "1.0.5"
9
+ s.version = "1.0.6"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib"]
13
13
  s.authors = ["Dmitri Koulikoff"]
14
- s.date = "2015-02-25"
14
+ s.date = "2015-06-15"
15
15
  s.description = "ActiveRecord generator and RSpec templates that add some basic functionality to the model and its spec"
16
16
  s.email = "dima@koulikoff.ru"
17
17
  s.extra_rdoc_files = [
@@ -35,7 +35,7 @@ Gem::Specification.new do |s|
35
35
  ]
36
36
  s.homepage = "http://github.com/dima4p/active_record_model_and_rspec_enhanced_templates"
37
37
  s.licenses = ["MIT"]
38
- s.rubygems_version = "2.4.5"
38
+ s.rubygems_version = "2.2.2"
39
39
  s.summary = "ActiveRecord generator and RSpec templates that add some basic functionality"
40
40
 
41
41
  if s.respond_to? :specification_version then
@@ -22,15 +22,19 @@ describe <%= class_name %>, type: :model do
22
22
 
23
23
  <% if attribute = attributes.detect{|a| a.name == 'position'} || attributes.detect{|a| a.name == 'name'} || attributes.detect{|a| a.name == 'title'} || attributes.first -%>
24
24
  describe :class do
25
- it 'should respond to :ordered' do
25
+ describe :scope do
26
+ describe '.ordered' do
27
+ it 'sort <%= class_name %> by :ordered' do
26
28
  <% if options[:fixture_replacement] == :factory_girl -%>
27
- create :<%= singular_name %>
28
- create :<%= singular_name %>
29
+ create :<%= singular_name %>
30
+ create :<%= singular_name %>
29
31
  <% else -%>
30
- <%= class_name %>.create @valid_attrs
31
- <%= class_name %>.create @valid_attrs
32
+ <%= class_name %>.create @valid_attrs
33
+ <%= class_name %>.create @valid_attrs
32
34
  <% end -%>
33
- expect(<%= class_name %>.ordered).to eq <%= class_name %>.order(:<%=attribute.name %>)
35
+ expect(<%= class_name %>.ordered).to eq <%= class_name %>.order(:<%=attribute.name %>)
36
+ end
37
+ end
34
38
  end
35
39
  end
36
40
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_record_model_and_rspec_enhanced_templates
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.5
4
+ version: 1.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dmitri Koulikoff
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-25 00:00:00.000000000 Z
11
+ date: 2015-06-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec
@@ -122,7 +122,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
122
122
  version: '0'
123
123
  requirements: []
124
124
  rubyforge_project:
125
- rubygems_version: 2.4.5
125
+ rubygems_version: 2.2.2
126
126
  signing_key:
127
127
  specification_version: 4
128
128
  summary: ActiveRecord generator and RSpec templates that add some basic functionality