cruddler 1.0.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +8 -0
- data/Gemfile +29 -0
- data/Gemfile.lock +141 -0
- data/MIT-LICENSE +20 -0
- data/README.textile +173 -0
- data/Rakefile +40 -0
- data/cruddler.gemspec +23 -0
- data/lib/cruddler.rb +33 -0
- data/lib/cruddler/controller.rb +186 -0
- data/lib/cruddler/crud_actions.rb +118 -0
- data/lib/cruddler/engine.rb +28 -0
- data/lib/cruddler/path_helpers.rb +100 -0
- data/lib/cruddler/version.rb +26 -0
- data/lib/generators/cruddler/install/USAGE +8 -0
- data/lib/generators/cruddler/install/install_generator.rb +40 -0
- data/lib/generators/cruddler/install/templates/application/edit.html.erb +18 -0
- data/lib/generators/cruddler/install/templates/application/index.html.erb +13 -0
- data/lib/generators/cruddler/install/templates/application/new.html.erb +17 -0
- data/lib/generators/cruddler/install/templates/application/show.html.erb +17 -0
- data/lib/generators/cruddler/install/templates/cruddler.yml +21 -0
- data/lib/tasks/cruddler_tasks.rake +4 -0
- data/script/rails +8 -0
- data/test/cruddler_test.rb +7 -0
- data/test/dummy/README.rdoc +261 -0
- data/test/dummy/Rakefile +7 -0
- data/test/dummy/app/assets/javascripts/application.js +15 -0
- data/test/dummy/app/assets/javascripts/cats.js +2 -0
- data/test/dummy/app/assets/javascripts/dogs.js +2 -0
- data/test/dummy/app/assets/javascripts/houses.js +2 -0
- data/test/dummy/app/assets/javascripts/parasites.js +2 -0
- data/test/dummy/app/assets/stylesheets/application.css +13 -0
- data/test/dummy/app/assets/stylesheets/cats.css +4 -0
- data/test/dummy/app/assets/stylesheets/dogs.css +4 -0
- data/test/dummy/app/assets/stylesheets/houses.css +4 -0
- data/test/dummy/app/assets/stylesheets/parasites.css +4 -0
- data/test/dummy/app/assets/stylesheets/scaffold.css +56 -0
- data/test/dummy/app/controllers/application_controller.rb +3 -0
- data/test/dummy/app/controllers/cats_controller.rb +7 -0
- data/test/dummy/app/controllers/dogs_controller.rb +11 -0
- data/test/dummy/app/controllers/houses_controller.rb +6 -0
- data/test/dummy/app/controllers/parasites_controller.rb +8 -0
- data/test/dummy/app/helpers/application_helper.rb +2 -0
- data/test/dummy/app/helpers/cats_helper.rb +2 -0
- data/test/dummy/app/helpers/dogs_helper.rb +2 -0
- data/test/dummy/app/helpers/houses_helper.rb +2 -0
- data/test/dummy/app/helpers/parasites_helper.rb +2 -0
- data/test/dummy/app/mailers/.gitkeep +0 -0
- data/test/dummy/app/models/.gitkeep +0 -0
- data/test/dummy/app/models/cat.rb +4 -0
- data/test/dummy/app/models/dog.rb +3 -0
- data/test/dummy/app/models/house.rb +5 -0
- data/test/dummy/app/models/parasite.rb +3 -0
- data/test/dummy/app/views/application/edit.html.erb +18 -0
- data/test/dummy/app/views/application/index.html.erb +13 -0
- data/test/dummy/app/views/application/new.html.erb +17 -0
- data/test/dummy/app/views/application/show.html.erb +17 -0
- data/test/dummy/app/views/cats/_form.html.erb +15 -0
- data/test/dummy/app/views/cats/_listing.html.erb +23 -0
- data/test/dummy/app/views/cats/_show_cat.html.erb +10 -0
- data/test/dummy/app/views/dogs/_form.html.erb +21 -0
- data/test/dummy/app/views/dogs/_listing.html.erb +23 -0
- data/test/dummy/app/views/dogs/_show_dog.html.erb +10 -0
- data/test/dummy/app/views/houses/_form.html.erb +25 -0
- data/test/dummy/app/views/houses/_listing.html.erb +23 -0
- data/test/dummy/app/views/houses/_show_house.html.erb +11 -0
- data/test/dummy/app/views/layouts/application.html.erb +14 -0
- data/test/dummy/app/views/parasites/_form.html.erb +25 -0
- data/test/dummy/app/views/parasites/_listing.html.erb +27 -0
- data/test/dummy/app/views/parasites/_show_parasite.html.erb +19 -0
- data/test/dummy/bin/bundle +3 -0
- data/test/dummy/bin/rails +4 -0
- data/test/dummy/bin/rake +4 -0
- data/test/dummy/config.ru +4 -0
- data/test/dummy/config/application.rb +23 -0
- data/test/dummy/config/boot.rb +4 -0
- data/test/dummy/config/database.yml +25 -0
- data/test/dummy/config/environment.rb +5 -0
- data/test/dummy/config/environments/development.rb +29 -0
- data/test/dummy/config/environments/production.rb +80 -0
- data/test/dummy/config/environments/test.rb +36 -0
- data/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
- data/test/dummy/config/initializers/inflections.rb +16 -0
- data/test/dummy/config/initializers/mime_types.rb +5 -0
- data/test/dummy/config/initializers/secret_token.rb +12 -0
- data/test/dummy/config/initializers/session_store.rb +3 -0
- data/test/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/test/dummy/config/locales/en.yml +23 -0
- data/test/dummy/config/routes.rb +12 -0
- data/test/dummy/db/migrate/20120606105838_create_houses.rb +10 -0
- data/test/dummy/db/migrate/20120606110003_create_cats.rb +11 -0
- data/test/dummy/db/migrate/20120606110348_create_dogs.rb +13 -0
- data/test/dummy/db/migrate/20120606175547_create_parasites.rb +12 -0
- data/test/dummy/db/schema.rb +53 -0
- data/test/dummy/lib/assets/.gitkeep +0 -0
- data/test/dummy/log/.gitkeep +0 -0
- data/test/dummy/public/404.html +26 -0
- data/test/dummy/public/422.html +26 -0
- data/test/dummy/public/500.html +25 -0
- data/test/dummy/public/favicon.ico +0 -0
- data/test/dummy/script/rails +6 -0
- data/test/integration/cruddler_integration_test.rb +253 -0
- data/test/integration/navigation_test.rb +10 -0
- data/test/support/capybara.rb +29 -0
- data/test/test_helper.rb +15 -0
- metadata +253 -0
@@ -0,0 +1,29 @@
|
|
1
|
+
require 'capybara/rails'
|
2
|
+
require "selenium/webdriver"
|
3
|
+
require 'database_cleaner'
|
4
|
+
|
5
|
+
DatabaseCleaner.strategy = :truncation
|
6
|
+
|
7
|
+
class ActionDispatch::IntegrationTest
|
8
|
+
# Make the Capybara DSL available in all integration tests
|
9
|
+
include Capybara::DSL
|
10
|
+
|
11
|
+
# Stop ActiveRecord from wrapping tests in transactions
|
12
|
+
self.use_transactional_fixtures = false
|
13
|
+
|
14
|
+
# Capybara.register_driver :chrome do |app|
|
15
|
+
# profile = Selenium::WebDriver::Chrome::Profile.new
|
16
|
+
# profile["download.default_directory"] = Rails.root.join("tmp/downloads")
|
17
|
+
# Capybara::Selenium::Driver.new(app, :browser => :chrome, :profile => profile)
|
18
|
+
# end
|
19
|
+
|
20
|
+
# Capybara.default_driver = Capybara.javascript_driver = :chrome
|
21
|
+
# Capybara.default_driver = :webkit
|
22
|
+
|
23
|
+
|
24
|
+
teardown do
|
25
|
+
DatabaseCleaner.clean # Truncate the database
|
26
|
+
Capybara.reset_sessions! # Forget the (simulated) browser state
|
27
|
+
Capybara.use_default_driver # Revert Capybara.current_driver to Capybara.default_driver
|
28
|
+
end
|
29
|
+
end
|
data/test/test_helper.rb
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
# Configure Rails Environment
|
2
|
+
ENV["RAILS_ENV"] = "test"
|
3
|
+
|
4
|
+
require File.expand_path("../dummy/config/environment.rb", __FILE__)
|
5
|
+
require "rails/test_help"
|
6
|
+
|
7
|
+
Rails.backtrace_cleaner.remove_silencers!
|
8
|
+
|
9
|
+
# Load support files
|
10
|
+
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
|
11
|
+
|
12
|
+
# Load fixtures from the engine
|
13
|
+
if ActiveSupport::TestCase.method_defined?(:fixture_path=)
|
14
|
+
ActiveSupport::TestCase.fixture_path = File.expand_path("../fixtures", __FILE__)
|
15
|
+
end
|
metadata
ADDED
@@ -0,0 +1,253 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: cruddler
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.0.0.rc1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Peter Horn
|
8
|
+
- Rene Sprotte
|
9
|
+
autorequire:
|
10
|
+
bindir: bin
|
11
|
+
cert_chain: []
|
12
|
+
date: 2014-10-06 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: rails
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
|
+
requirements:
|
18
|
+
- - "~>"
|
19
|
+
- !ruby/object:Gem::Version
|
20
|
+
version: '4.0'
|
21
|
+
- - ">="
|
22
|
+
- !ruby/object:Gem::Version
|
23
|
+
version: 4.0.0
|
24
|
+
type: :runtime
|
25
|
+
prerelease: false
|
26
|
+
version_requirements: !ruby/object:Gem::Requirement
|
27
|
+
requirements:
|
28
|
+
- - "~>"
|
29
|
+
- !ruby/object:Gem::Version
|
30
|
+
version: '4.0'
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 4.0.0
|
34
|
+
description: CRUD Actions for Lazy Coders, with just the correct amount of cifugurability.
|
35
|
+
email: open-source@metaminded.com
|
36
|
+
executables: []
|
37
|
+
extensions: []
|
38
|
+
extra_rdoc_files: []
|
39
|
+
files:
|
40
|
+
- ".gitignore"
|
41
|
+
- Gemfile
|
42
|
+
- Gemfile.lock
|
43
|
+
- MIT-LICENSE
|
44
|
+
- README.textile
|
45
|
+
- Rakefile
|
46
|
+
- cruddler.gemspec
|
47
|
+
- lib/cruddler.rb
|
48
|
+
- lib/cruddler/controller.rb
|
49
|
+
- lib/cruddler/crud_actions.rb
|
50
|
+
- lib/cruddler/engine.rb
|
51
|
+
- lib/cruddler/path_helpers.rb
|
52
|
+
- lib/cruddler/version.rb
|
53
|
+
- lib/generators/cruddler/install/USAGE
|
54
|
+
- lib/generators/cruddler/install/install_generator.rb
|
55
|
+
- lib/generators/cruddler/install/templates/application/edit.html.erb
|
56
|
+
- lib/generators/cruddler/install/templates/application/index.html.erb
|
57
|
+
- lib/generators/cruddler/install/templates/application/new.html.erb
|
58
|
+
- lib/generators/cruddler/install/templates/application/show.html.erb
|
59
|
+
- lib/generators/cruddler/install/templates/cruddler.yml
|
60
|
+
- lib/tasks/cruddler_tasks.rake
|
61
|
+
- script/rails
|
62
|
+
- test/cruddler_test.rb
|
63
|
+
- test/dummy/README.rdoc
|
64
|
+
- test/dummy/Rakefile
|
65
|
+
- test/dummy/app/assets/javascripts/application.js
|
66
|
+
- test/dummy/app/assets/javascripts/cats.js
|
67
|
+
- test/dummy/app/assets/javascripts/dogs.js
|
68
|
+
- test/dummy/app/assets/javascripts/houses.js
|
69
|
+
- test/dummy/app/assets/javascripts/parasites.js
|
70
|
+
- test/dummy/app/assets/stylesheets/application.css
|
71
|
+
- test/dummy/app/assets/stylesheets/cats.css
|
72
|
+
- test/dummy/app/assets/stylesheets/dogs.css
|
73
|
+
- test/dummy/app/assets/stylesheets/houses.css
|
74
|
+
- test/dummy/app/assets/stylesheets/parasites.css
|
75
|
+
- test/dummy/app/assets/stylesheets/scaffold.css
|
76
|
+
- test/dummy/app/controllers/application_controller.rb
|
77
|
+
- test/dummy/app/controllers/cats_controller.rb
|
78
|
+
- test/dummy/app/controllers/dogs_controller.rb
|
79
|
+
- test/dummy/app/controllers/houses_controller.rb
|
80
|
+
- test/dummy/app/controllers/parasites_controller.rb
|
81
|
+
- test/dummy/app/helpers/application_helper.rb
|
82
|
+
- test/dummy/app/helpers/cats_helper.rb
|
83
|
+
- test/dummy/app/helpers/dogs_helper.rb
|
84
|
+
- test/dummy/app/helpers/houses_helper.rb
|
85
|
+
- test/dummy/app/helpers/parasites_helper.rb
|
86
|
+
- test/dummy/app/mailers/.gitkeep
|
87
|
+
- test/dummy/app/models/.gitkeep
|
88
|
+
- test/dummy/app/models/cat.rb
|
89
|
+
- test/dummy/app/models/dog.rb
|
90
|
+
- test/dummy/app/models/house.rb
|
91
|
+
- test/dummy/app/models/parasite.rb
|
92
|
+
- test/dummy/app/views/application/edit.html.erb
|
93
|
+
- test/dummy/app/views/application/index.html.erb
|
94
|
+
- test/dummy/app/views/application/new.html.erb
|
95
|
+
- test/dummy/app/views/application/show.html.erb
|
96
|
+
- test/dummy/app/views/cats/_form.html.erb
|
97
|
+
- test/dummy/app/views/cats/_listing.html.erb
|
98
|
+
- test/dummy/app/views/cats/_show_cat.html.erb
|
99
|
+
- test/dummy/app/views/dogs/_form.html.erb
|
100
|
+
- test/dummy/app/views/dogs/_listing.html.erb
|
101
|
+
- test/dummy/app/views/dogs/_show_dog.html.erb
|
102
|
+
- test/dummy/app/views/houses/_form.html.erb
|
103
|
+
- test/dummy/app/views/houses/_listing.html.erb
|
104
|
+
- test/dummy/app/views/houses/_show_house.html.erb
|
105
|
+
- test/dummy/app/views/layouts/application.html.erb
|
106
|
+
- test/dummy/app/views/parasites/_form.html.erb
|
107
|
+
- test/dummy/app/views/parasites/_listing.html.erb
|
108
|
+
- test/dummy/app/views/parasites/_show_parasite.html.erb
|
109
|
+
- test/dummy/bin/bundle
|
110
|
+
- test/dummy/bin/rails
|
111
|
+
- test/dummy/bin/rake
|
112
|
+
- test/dummy/config.ru
|
113
|
+
- test/dummy/config/application.rb
|
114
|
+
- test/dummy/config/boot.rb
|
115
|
+
- test/dummy/config/database.yml
|
116
|
+
- test/dummy/config/environment.rb
|
117
|
+
- test/dummy/config/environments/development.rb
|
118
|
+
- test/dummy/config/environments/production.rb
|
119
|
+
- test/dummy/config/environments/test.rb
|
120
|
+
- test/dummy/config/initializers/backtrace_silencers.rb
|
121
|
+
- test/dummy/config/initializers/filter_parameter_logging.rb
|
122
|
+
- test/dummy/config/initializers/inflections.rb
|
123
|
+
- test/dummy/config/initializers/mime_types.rb
|
124
|
+
- test/dummy/config/initializers/secret_token.rb
|
125
|
+
- test/dummy/config/initializers/session_store.rb
|
126
|
+
- test/dummy/config/initializers/wrap_parameters.rb
|
127
|
+
- test/dummy/config/locales/en.yml
|
128
|
+
- test/dummy/config/routes.rb
|
129
|
+
- test/dummy/db/migrate/20120606105838_create_houses.rb
|
130
|
+
- test/dummy/db/migrate/20120606110003_create_cats.rb
|
131
|
+
- test/dummy/db/migrate/20120606110348_create_dogs.rb
|
132
|
+
- test/dummy/db/migrate/20120606175547_create_parasites.rb
|
133
|
+
- test/dummy/db/schema.rb
|
134
|
+
- test/dummy/lib/assets/.gitkeep
|
135
|
+
- test/dummy/log/.gitkeep
|
136
|
+
- test/dummy/public/404.html
|
137
|
+
- test/dummy/public/422.html
|
138
|
+
- test/dummy/public/500.html
|
139
|
+
- test/dummy/public/favicon.ico
|
140
|
+
- test/dummy/script/rails
|
141
|
+
- test/integration/cruddler_integration_test.rb
|
142
|
+
- test/integration/navigation_test.rb
|
143
|
+
- test/support/capybara.rb
|
144
|
+
- test/test_helper.rb
|
145
|
+
homepage: http://github.com/metaminded/cruddler
|
146
|
+
licenses:
|
147
|
+
- MIT
|
148
|
+
metadata: {}
|
149
|
+
post_install_message:
|
150
|
+
rdoc_options:
|
151
|
+
- "--charset=UTF-8"
|
152
|
+
require_paths:
|
153
|
+
- lib
|
154
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
155
|
+
requirements:
|
156
|
+
- - ">="
|
157
|
+
- !ruby/object:Gem::Version
|
158
|
+
version: '0'
|
159
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
160
|
+
requirements:
|
161
|
+
- - ">"
|
162
|
+
- !ruby/object:Gem::Version
|
163
|
+
version: 1.3.1
|
164
|
+
requirements: []
|
165
|
+
rubyforge_project:
|
166
|
+
rubygems_version: 2.2.2
|
167
|
+
signing_key:
|
168
|
+
specification_version: 4
|
169
|
+
summary: CRUD Actions for Lazy Coders
|
170
|
+
test_files:
|
171
|
+
- test/cruddler_test.rb
|
172
|
+
- test/dummy/README.rdoc
|
173
|
+
- test/dummy/Rakefile
|
174
|
+
- test/dummy/app/assets/javascripts/application.js
|
175
|
+
- test/dummy/app/assets/javascripts/cats.js
|
176
|
+
- test/dummy/app/assets/javascripts/dogs.js
|
177
|
+
- test/dummy/app/assets/javascripts/houses.js
|
178
|
+
- test/dummy/app/assets/javascripts/parasites.js
|
179
|
+
- test/dummy/app/assets/stylesheets/application.css
|
180
|
+
- test/dummy/app/assets/stylesheets/cats.css
|
181
|
+
- test/dummy/app/assets/stylesheets/dogs.css
|
182
|
+
- test/dummy/app/assets/stylesheets/houses.css
|
183
|
+
- test/dummy/app/assets/stylesheets/parasites.css
|
184
|
+
- test/dummy/app/assets/stylesheets/scaffold.css
|
185
|
+
- test/dummy/app/controllers/application_controller.rb
|
186
|
+
- test/dummy/app/controllers/cats_controller.rb
|
187
|
+
- test/dummy/app/controllers/dogs_controller.rb
|
188
|
+
- test/dummy/app/controllers/houses_controller.rb
|
189
|
+
- test/dummy/app/controllers/parasites_controller.rb
|
190
|
+
- test/dummy/app/helpers/application_helper.rb
|
191
|
+
- test/dummy/app/helpers/cats_helper.rb
|
192
|
+
- test/dummy/app/helpers/dogs_helper.rb
|
193
|
+
- test/dummy/app/helpers/houses_helper.rb
|
194
|
+
- test/dummy/app/helpers/parasites_helper.rb
|
195
|
+
- test/dummy/app/mailers/.gitkeep
|
196
|
+
- test/dummy/app/models/.gitkeep
|
197
|
+
- test/dummy/app/models/cat.rb
|
198
|
+
- test/dummy/app/models/dog.rb
|
199
|
+
- test/dummy/app/models/house.rb
|
200
|
+
- test/dummy/app/models/parasite.rb
|
201
|
+
- test/dummy/app/views/application/edit.html.erb
|
202
|
+
- test/dummy/app/views/application/index.html.erb
|
203
|
+
- test/dummy/app/views/application/new.html.erb
|
204
|
+
- test/dummy/app/views/application/show.html.erb
|
205
|
+
- test/dummy/app/views/cats/_form.html.erb
|
206
|
+
- test/dummy/app/views/cats/_listing.html.erb
|
207
|
+
- test/dummy/app/views/cats/_show_cat.html.erb
|
208
|
+
- test/dummy/app/views/dogs/_form.html.erb
|
209
|
+
- test/dummy/app/views/dogs/_listing.html.erb
|
210
|
+
- test/dummy/app/views/dogs/_show_dog.html.erb
|
211
|
+
- test/dummy/app/views/houses/_form.html.erb
|
212
|
+
- test/dummy/app/views/houses/_listing.html.erb
|
213
|
+
- test/dummy/app/views/houses/_show_house.html.erb
|
214
|
+
- test/dummy/app/views/layouts/application.html.erb
|
215
|
+
- test/dummy/app/views/parasites/_form.html.erb
|
216
|
+
- test/dummy/app/views/parasites/_listing.html.erb
|
217
|
+
- test/dummy/app/views/parasites/_show_parasite.html.erb
|
218
|
+
- test/dummy/bin/bundle
|
219
|
+
- test/dummy/bin/rails
|
220
|
+
- test/dummy/bin/rake
|
221
|
+
- test/dummy/config.ru
|
222
|
+
- test/dummy/config/application.rb
|
223
|
+
- test/dummy/config/boot.rb
|
224
|
+
- test/dummy/config/database.yml
|
225
|
+
- test/dummy/config/environment.rb
|
226
|
+
- test/dummy/config/environments/development.rb
|
227
|
+
- test/dummy/config/environments/production.rb
|
228
|
+
- test/dummy/config/environments/test.rb
|
229
|
+
- test/dummy/config/initializers/backtrace_silencers.rb
|
230
|
+
- test/dummy/config/initializers/filter_parameter_logging.rb
|
231
|
+
- test/dummy/config/initializers/inflections.rb
|
232
|
+
- test/dummy/config/initializers/mime_types.rb
|
233
|
+
- test/dummy/config/initializers/secret_token.rb
|
234
|
+
- test/dummy/config/initializers/session_store.rb
|
235
|
+
- test/dummy/config/initializers/wrap_parameters.rb
|
236
|
+
- test/dummy/config/locales/en.yml
|
237
|
+
- test/dummy/config/routes.rb
|
238
|
+
- test/dummy/db/migrate/20120606105838_create_houses.rb
|
239
|
+
- test/dummy/db/migrate/20120606110003_create_cats.rb
|
240
|
+
- test/dummy/db/migrate/20120606110348_create_dogs.rb
|
241
|
+
- test/dummy/db/migrate/20120606175547_create_parasites.rb
|
242
|
+
- test/dummy/db/schema.rb
|
243
|
+
- test/dummy/lib/assets/.gitkeep
|
244
|
+
- test/dummy/log/.gitkeep
|
245
|
+
- test/dummy/public/404.html
|
246
|
+
- test/dummy/public/422.html
|
247
|
+
- test/dummy/public/500.html
|
248
|
+
- test/dummy/public/favicon.ico
|
249
|
+
- test/dummy/script/rails
|
250
|
+
- test/integration/cruddler_integration_test.rb
|
251
|
+
- test/integration/navigation_test.rb
|
252
|
+
- test/support/capybara.rb
|
253
|
+
- test/test_helper.rb
|