rspec_rails_scaffold_templates 1.0.7 → 1.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/lib/templates/rspec/integration/request_spec.rb +2 -0
- data/lib/templates/rspec/scaffold/controller_spec.rb +2 -0
- data/lib/templates/rspec/scaffold/edit_spec.rb +2 -0
- data/lib/templates/rspec/scaffold/index_spec.rb +3 -0
- data/lib/templates/rspec/scaffold/new_spec.rb +2 -0
- data/lib/templates/rspec/scaffold/show_spec.rb +2 -0
- data/rspec_rails_scaffold_templates.gemspec +4 -4
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ffb4fae5fdbaa457cb47a0332c2f3c86f678a46c
|
4
|
+
data.tar.gz: 65813cf867467749f143b7f62f0d2bec6015f446
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3f11b3cf92859d0825ffb866db3ae7897321448d91e11a637d24b853576937f897af626fb67c572d6d0c8bc9543c2c47ff3ebe869bc50adc2c405fba8e09ffc3
|
7
|
+
data.tar.gz: 0876d94af444e23c056d0c1159b7d626b0136b8525f65a1e2666c79789be6ca9a430fc0c9f5aa715f80203f18c4af0e3c1cf86f44ad0a676c0d937a47545b659
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.
|
1
|
+
1.0.8
|
@@ -5,10 +5,12 @@ require 'spec_helper'
|
|
5
5
|
<% end -%>
|
6
6
|
|
7
7
|
describe "<%= class_name.pluralize %>", type: :request do
|
8
|
+
<% if Rails.application.config.generators.options[:rails][:cancan] -%>
|
8
9
|
before :each do
|
9
10
|
allow_any_instance_of(<%= class_name.pluralize %>Controller).to receive(:current_user).and_return(current_user)
|
10
11
|
end
|
11
12
|
|
13
|
+
<% end -%>
|
12
14
|
describe "GET /<%= table_name %>" do
|
13
15
|
it "works! (now write some real specs)" do
|
14
16
|
get <%= index_helper %>_path
|
@@ -7,10 +7,12 @@ require 'spec_helper'
|
|
7
7
|
<% module_namespacing do -%>
|
8
8
|
describe <%= controller_class_name %>Controller, type: :controller do
|
9
9
|
|
10
|
+
<% if Rails.application.config.generators.options[:rails][:cancan] -%>
|
10
11
|
before :each do
|
11
12
|
allow(controller).to receive(:current_user).and_return(current_user)
|
12
13
|
end
|
13
14
|
|
15
|
+
<% end -%>
|
14
16
|
# This should return the minimal set of attributes required to create a valid
|
15
17
|
# <%= class_name %>. As you add validations to <%= class_name %>, be sure to
|
16
18
|
# adjust the attributes here as well. The list could not be empty.
|
@@ -7,7 +7,9 @@ require 'spec_helper'
|
|
7
7
|
<% output_attributes = attributes.reject{|attribute| [:datetime, :timestamp, :time, :date].index(attribute.type) } -%>
|
8
8
|
describe "<%= ns_table_name %>/edit", type: :view do
|
9
9
|
before(:each) do
|
10
|
+
<% if Rails.application.config.generators.options[:rails][:cancan] -%>
|
10
11
|
allow(controller).to receive(:can?).and_return(true)
|
12
|
+
<% end -%>
|
11
13
|
<% if Rails.application.config.generators.options[:rails][:fixture_replacement] == :factory_girl -%>
|
12
14
|
@<%= ns_file_name %> = assign(:<%= ns_file_name %>, create(:<%= ns_file_name %>))
|
13
15
|
<% else -%>
|
@@ -7,7 +7,9 @@ require 'spec_helper'
|
|
7
7
|
<% output_attributes = attributes.reject{|attribute| [:created_at, :deleted_at, :updated_at].index(attribute.name) or attribute.password_digest? } -%>
|
8
8
|
describe "<%= ns_table_name %>/index", type: :view do
|
9
9
|
before(:each) do
|
10
|
+
<% if Rails.application.config.generators.options[:rails][:cancan] -%>
|
10
11
|
allow(controller).to receive(:can?).and_return(true)
|
12
|
+
<% end -%>
|
11
13
|
<% if options[:fixture_replacement] == :factory_girl -%>
|
12
14
|
# options[:fixture_replacement] == :factory_girl
|
13
15
|
<% end -%>
|
@@ -16,6 +18,7 @@ describe "<%= ns_table_name %>/index", type: :view do
|
|
16
18
|
@<%= ns_file_name %> = create(:<%= ns_file_name %>)
|
17
19
|
<% if not defined? Wice::WiceGrid -%>
|
18
20
|
assign(:<%= table_name %>, [@<%= ns_file_name %>, @<%= ns_file_name %>])
|
21
|
+
<% size = 2 -%>
|
19
22
|
<% end -%>
|
20
23
|
<% else -%>
|
21
24
|
<% size = 2 -%>
|
@@ -7,7 +7,9 @@ require 'spec_helper'
|
|
7
7
|
<% output_attributes = attributes.reject{|attribute| [:datetime, :timestamp, :time, :date].index(attribute.type) } -%>
|
8
8
|
describe "<%= ns_table_name %>/new", type: :view do
|
9
9
|
before(:each) do
|
10
|
+
<% if Rails.application.config.generators.options[:rails][:cancan] -%>
|
10
11
|
allow(controller).to receive(:can?).and_return(true)
|
12
|
+
<% end -%>
|
11
13
|
<% if Rails.application.config.generators.options[:rails][:fixture_replacement] == :factory_girl -%>
|
12
14
|
@<%= ns_file_name %> = assign(:<%= ns_file_name %>, build(:<%= ns_file_name %>))
|
13
15
|
end
|
@@ -7,7 +7,9 @@ require 'spec_helper'
|
|
7
7
|
<% output_attributes = attributes.reject{|attribute| [:created_at, :deleted_at, :updated_at].index(attribute.name) or attribute.password_digest? } -%>
|
8
8
|
describe "<%= ns_table_name %>/show", type: :view do
|
9
9
|
before(:each) do
|
10
|
+
<% if Rails.application.config.generators.options[:rails][:cancan] -%>
|
10
11
|
allow(controller).to receive(:can?).and_return(true)
|
12
|
+
<% end -%>
|
11
13
|
<% if Rails.application.config.generators.options[:rails][:fixture_replacement] == :factory_girl -%>
|
12
14
|
@<%= ns_file_name %> = assign(:<%= ns_file_name %>, create(:<%= ns_file_name %>))
|
13
15
|
<% else -%>
|
@@ -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: rspec_rails_scaffold_templates 1.0.
|
5
|
+
# stub: rspec_rails_scaffold_templates 1.0.8 ruby lib
|
6
6
|
|
7
7
|
Gem::Specification.new do |s|
|
8
8
|
s.name = "rspec_rails_scaffold_templates"
|
9
|
-
s.version = "1.0.
|
9
|
+
s.version = "1.0.8"
|
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-
|
14
|
+
s.date = "2015-06-14"
|
15
15
|
s.description = "RSpec scaffold generator templates that use FactoryGirl and WiceGrid"
|
16
16
|
s.email = "dima@koulikoff.ru"
|
17
17
|
s.extra_rdoc_files = [
|
@@ -39,7 +39,7 @@ Gem::Specification.new do |s|
|
|
39
39
|
]
|
40
40
|
s.homepage = "http://github.com/dima4p/rspec_rails_scaffold_templates"
|
41
41
|
s.licenses = ["MIT"]
|
42
|
-
s.rubygems_version = "2.
|
42
|
+
s.rubygems_version = "2.2.2"
|
43
43
|
s.summary = "RSpec scaffold generator templates that use FactoryGirl and WiceGrid"
|
44
44
|
|
45
45
|
if s.respond_to? :specification_version then
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rspec_rails_scaffold_templates
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.8
|
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-
|
11
|
+
date: 2015-06-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|
@@ -125,7 +125,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
125
125
|
version: '0'
|
126
126
|
requirements: []
|
127
127
|
rubyforge_project:
|
128
|
-
rubygems_version: 2.
|
128
|
+
rubygems_version: 2.2.2
|
129
129
|
signing_key:
|
130
130
|
specification_version: 4
|
131
131
|
summary: RSpec scaffold generator templates that use FactoryGirl and WiceGrid
|