simple_breadcrumbs 0.0.2 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.coveralls.yml +2 -0
- data/.travis.yml +3 -0
- data/README.md +4 -0
- data/lib/has_breadcrumb/version.rb +1 -1
- data/simple_breadcrumbs.gemspec +4 -3
- data/spec/has_breadcrumb/has_breadcrumb_spec.rb +1 -1
- data/spec/has_breadcrumb/show_breadcrumb_spec.rb +1 -1
- data/spec/spec_helper.rb +3 -6
- data/spec/support/{schema.rb → database.rb} +5 -0
- metadata +49 -36
- data/spec/support/adapters/active_record.rb +0 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2934bf580cbff087b338a0e8705664c92d8fd03e
|
4
|
+
data.tar.gz: 3009b1b431388c4e3570db89c0a7e2cdc0f20c11
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bb770c4af855df90ae4e3c2cce029faba205ce35c5b1a0dc687915b7868c9751383641a05490516c4f3e3501aed884f3ee001d417a2f6b9679dde4be01490767
|
7
|
+
data.tar.gz: 89ebb2fa4172cc5a9f9d26ed232acad039c483accedabd8e3a727497c6973b05e39586fb790ca896918133d00f52217d65eacc060115fbe7a358261746f5446b
|
data/.coveralls.yml
ADDED
data/.travis.yml
ADDED
data/README.md
CHANGED
@@ -1,5 +1,9 @@
|
|
1
1
|
# SimpleBreadcrumbs
|
2
2
|
|
3
|
+
[![Code Climate](https://codeclimate.com/github/sqm/simple_breadcrumbs.png)](https://codeclimate.com/github/sqm/simple_breadcrumbs)
|
4
|
+
[![Build Status](https://travis-ci.org/sqm/simple_breadcrumbs.png?branch=master)](https://travis-ci.org/sqm/simple_breadcrumbs)
|
5
|
+
[![Coverage Status](https://coveralls.io/repos/sqm/simple_breadcrumbs/badge.png?branch=master)](https://coveralls.io/r/sqm/simple_breadcrumbs)
|
6
|
+
|
3
7
|
This gem provides a simple and flexible way to create breadcrumbs with Rails active record
|
4
8
|
models. Setting `has_breadcrumb` on a model will enable a view method,
|
5
9
|
`breadcrumb()`, which will show the links to the page and its parents in
|
data/simple_breadcrumbs.gemspec
CHANGED
@@ -19,9 +19,10 @@ Gem::Specification.new do |gem|
|
|
19
19
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
20
20
|
gem.require_paths = ['lib']
|
21
21
|
|
22
|
-
gem.add_dependency 'activerecord', ['>= 3.0', '<
|
23
|
-
gem.add_dependency 'activesupport', ['>= 3.0', '<
|
22
|
+
gem.add_dependency 'activerecord', ['>= 3.0', '< 6']
|
23
|
+
gem.add_dependency 'activesupport', ['>= 3.0', '< 6']
|
24
24
|
|
25
|
-
gem.add_development_dependency 'rspec-rails'
|
25
|
+
gem.add_development_dependency 'rspec-rails'
|
26
26
|
gem.add_development_dependency 'sqlite3', '~> 1.3'
|
27
|
+
gem.add_development_dependency 'coveralls', '~> 0.7.0'
|
27
28
|
end
|
@@ -30,7 +30,7 @@ describe ShowBreadcrumb do
|
|
30
30
|
end
|
31
31
|
|
32
32
|
describe "#breadcrumbs" do
|
33
|
-
before { controller.
|
33
|
+
before { allow(controller).to receive_messages(url_for: "fake_url") }
|
34
34
|
|
35
35
|
context "when :forced_parent is passed" do
|
36
36
|
it "should link to the forced parent" do
|
data/spec/spec_helper.rb
CHANGED
@@ -9,6 +9,9 @@ require 'rails/all'
|
|
9
9
|
require 'rspec/rails'
|
10
10
|
require 'simple_breadcrumbs'
|
11
11
|
|
12
|
+
require 'coveralls'
|
13
|
+
Coveralls.wear!
|
14
|
+
|
12
15
|
ActiveSupport.on_load(:active_record) do
|
13
16
|
include HasBreadcrumb
|
14
17
|
end
|
@@ -24,13 +27,7 @@ I18n.enforce_available_locales = false
|
|
24
27
|
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
|
25
28
|
|
26
29
|
RSpec.configure do |config|
|
27
|
-
config.treat_symbols_as_metadata_keys_with_true_values = true
|
28
30
|
config.run_all_when_everything_filtered = true
|
29
31
|
config.filter_run :focus
|
30
|
-
|
31
|
-
# Run specs in random order to surface order dependencies. If you find an
|
32
|
-
# order dependency and want to debug it, you can fix the order by providing
|
33
|
-
# the seed, which is printed after each run.
|
34
|
-
# --seed 1234
|
35
32
|
config.order = 'random'
|
36
33
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: simple_breadcrumbs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tim Harvey
|
@@ -9,76 +9,90 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2018-04-02 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
|
+
name: activerecord
|
15
16
|
requirement: !ruby/object:Gem::Requirement
|
16
17
|
requirements:
|
17
|
-
- -
|
18
|
+
- - ">="
|
18
19
|
- !ruby/object:Gem::Version
|
19
20
|
version: '3.0'
|
20
|
-
- - <
|
21
|
+
- - "<"
|
21
22
|
- !ruby/object:Gem::Version
|
22
|
-
version: '
|
23
|
+
version: '6'
|
24
|
+
type: :runtime
|
23
25
|
prerelease: false
|
24
|
-
name: activerecord
|
25
26
|
version_requirements: !ruby/object:Gem::Requirement
|
26
27
|
requirements:
|
27
|
-
- -
|
28
|
+
- - ">="
|
28
29
|
- !ruby/object:Gem::Version
|
29
30
|
version: '3.0'
|
30
|
-
- - <
|
31
|
+
- - "<"
|
31
32
|
- !ruby/object:Gem::Version
|
32
|
-
version: '
|
33
|
-
type: :runtime
|
33
|
+
version: '6'
|
34
34
|
- !ruby/object:Gem::Dependency
|
35
|
+
name: activesupport
|
35
36
|
requirement: !ruby/object:Gem::Requirement
|
36
37
|
requirements:
|
37
|
-
- -
|
38
|
+
- - ">="
|
38
39
|
- !ruby/object:Gem::Version
|
39
40
|
version: '3.0'
|
40
|
-
- - <
|
41
|
+
- - "<"
|
41
42
|
- !ruby/object:Gem::Version
|
42
|
-
version: '
|
43
|
+
version: '6'
|
44
|
+
type: :runtime
|
43
45
|
prerelease: false
|
44
|
-
name: activesupport
|
45
46
|
version_requirements: !ruby/object:Gem::Requirement
|
46
47
|
requirements:
|
47
|
-
- -
|
48
|
+
- - ">="
|
48
49
|
- !ruby/object:Gem::Version
|
49
50
|
version: '3.0'
|
50
|
-
- - <
|
51
|
+
- - "<"
|
51
52
|
- !ruby/object:Gem::Version
|
52
|
-
version: '
|
53
|
-
type: :runtime
|
53
|
+
version: '6'
|
54
54
|
- !ruby/object:Gem::Dependency
|
55
|
+
name: rspec-rails
|
55
56
|
requirement: !ruby/object:Gem::Requirement
|
56
57
|
requirements:
|
57
|
-
- -
|
58
|
+
- - ">="
|
58
59
|
- !ruby/object:Gem::Version
|
59
|
-
version: '
|
60
|
+
version: '0'
|
61
|
+
type: :development
|
60
62
|
prerelease: false
|
61
|
-
name: rspec-rails
|
62
63
|
version_requirements: !ruby/object:Gem::Requirement
|
63
64
|
requirements:
|
64
|
-
- -
|
65
|
+
- - ">="
|
65
66
|
- !ruby/object:Gem::Version
|
66
|
-
version: '
|
67
|
-
type: :development
|
67
|
+
version: '0'
|
68
68
|
- !ruby/object:Gem::Dependency
|
69
|
+
name: sqlite3
|
69
70
|
requirement: !ruby/object:Gem::Requirement
|
70
71
|
requirements:
|
71
|
-
- - ~>
|
72
|
+
- - "~>"
|
72
73
|
- !ruby/object:Gem::Version
|
73
74
|
version: '1.3'
|
75
|
+
type: :development
|
74
76
|
prerelease: false
|
75
|
-
name: sqlite3
|
76
77
|
version_requirements: !ruby/object:Gem::Requirement
|
77
78
|
requirements:
|
78
|
-
- - ~>
|
79
|
+
- - "~>"
|
79
80
|
- !ruby/object:Gem::Version
|
80
81
|
version: '1.3'
|
82
|
+
- !ruby/object:Gem::Dependency
|
83
|
+
name: coveralls
|
84
|
+
requirement: !ruby/object:Gem::Requirement
|
85
|
+
requirements:
|
86
|
+
- - "~>"
|
87
|
+
- !ruby/object:Gem::Version
|
88
|
+
version: 0.7.0
|
81
89
|
type: :development
|
90
|
+
prerelease: false
|
91
|
+
version_requirements: !ruby/object:Gem::Requirement
|
92
|
+
requirements:
|
93
|
+
- - "~>"
|
94
|
+
- !ruby/object:Gem::Version
|
95
|
+
version: 0.7.0
|
82
96
|
description: Provides a simple and flexible way to create breadcrumbs with Rails active
|
83
97
|
record models.
|
84
98
|
email:
|
@@ -87,7 +101,9 @@ executables: []
|
|
87
101
|
extensions: []
|
88
102
|
extra_rdoc_files: []
|
89
103
|
files:
|
90
|
-
- .
|
104
|
+
- ".coveralls.yml"
|
105
|
+
- ".gitignore"
|
106
|
+
- ".travis.yml"
|
91
107
|
- Gemfile
|
92
108
|
- LICENSE
|
93
109
|
- README.md
|
@@ -101,12 +117,11 @@ files:
|
|
101
117
|
- spec/has_breadcrumb/has_breadcrumb_spec.rb
|
102
118
|
- spec/has_breadcrumb/show_breadcrumb_spec.rb
|
103
119
|
- spec/spec_helper.rb
|
104
|
-
- spec/support/
|
120
|
+
- spec/support/database.rb
|
105
121
|
- spec/support/models/admin.rb
|
106
122
|
- spec/support/models/intern.rb
|
107
123
|
- spec/support/models/manager.rb
|
108
124
|
- spec/support/models/user.rb
|
109
|
-
- spec/support/schema.rb
|
110
125
|
homepage: https://github.com/sqm/simple_breadcrumbs
|
111
126
|
licenses:
|
112
127
|
- MIT
|
@@ -117,17 +132,17 @@ require_paths:
|
|
117
132
|
- lib
|
118
133
|
required_ruby_version: !ruby/object:Gem::Requirement
|
119
134
|
requirements:
|
120
|
-
- -
|
135
|
+
- - ">="
|
121
136
|
- !ruby/object:Gem::Version
|
122
137
|
version: '0'
|
123
138
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
124
139
|
requirements:
|
125
|
-
- -
|
140
|
+
- - ">="
|
126
141
|
- !ruby/object:Gem::Version
|
127
142
|
version: '0'
|
128
143
|
requirements: []
|
129
144
|
rubyforge_project:
|
130
|
-
rubygems_version: 2.2
|
145
|
+
rubygems_version: 2.5.2
|
131
146
|
signing_key:
|
132
147
|
specification_version: 4
|
133
148
|
summary: Setting has_breadcrumb on a model will enable a view method, breadcrumb(),
|
@@ -136,10 +151,8 @@ test_files:
|
|
136
151
|
- spec/has_breadcrumb/has_breadcrumb_spec.rb
|
137
152
|
- spec/has_breadcrumb/show_breadcrumb_spec.rb
|
138
153
|
- spec/spec_helper.rb
|
139
|
-
- spec/support/
|
154
|
+
- spec/support/database.rb
|
140
155
|
- spec/support/models/admin.rb
|
141
156
|
- spec/support/models/intern.rb
|
142
157
|
- spec/support/models/manager.rb
|
143
158
|
- spec/support/models/user.rb
|
144
|
-
- spec/support/schema.rb
|
145
|
-
has_rdoc:
|