active-component 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (75) hide show
  1. checksums.yaml +7 -0
  2. data/MIT-LICENSE +20 -0
  3. data/Rakefile +32 -0
  4. data/lib/active_component/base.rb +55 -0
  5. data/lib/active_component/context.rb +39 -0
  6. data/lib/active_component/railtie.rb +13 -0
  7. data/lib/active_component/renderable.rb +20 -0
  8. data/lib/active_component/version.rb +3 -0
  9. data/lib/active_component.rb +7 -0
  10. data/lib/generators/component_generator.rb +11 -0
  11. data/lib/generators/templates/application_component.rb +5 -0
  12. data/lib/generators/templates/component.rb +6 -0
  13. data/lib/tasks/active_component_tasks.rake +4 -0
  14. data/test/active_component/base_test.rb +30 -0
  15. data/test/active_component/context_test.rb +10 -0
  16. data/test/active_component/railtie_test.rb +9 -0
  17. data/test/active_component/renderable_test.rb +9 -0
  18. data/test/active_component_test.rb +9 -0
  19. data/test/dummy/README.rdoc +28 -0
  20. data/test/dummy/Rakefile +6 -0
  21. data/test/dummy/app/assets/javascripts/application.js +13 -0
  22. data/test/dummy/app/assets/stylesheets/application.css +13 -0
  23. data/test/dummy/app/components/application_component.rb +5 -0
  24. data/test/dummy/app/components/dummy_component.rb +6 -0
  25. data/test/dummy/app/components/message_component.rb +10 -0
  26. data/test/dummy/app/controllers/application_controller.rb +5 -0
  27. data/test/dummy/app/helpers/application_helper.rb +2 -0
  28. data/test/dummy/app/templates/dummy_component.mustache +0 -0
  29. data/test/dummy/app/templates/message_component.mustache +1 -0
  30. data/test/dummy/app/views/layouts/application.html.erb +14 -0
  31. data/test/dummy/bin/bundle +3 -0
  32. data/test/dummy/bin/rails +4 -0
  33. data/test/dummy/bin/rake +4 -0
  34. data/test/dummy/config/application.rb +23 -0
  35. data/test/dummy/config/boot.rb +5 -0
  36. data/test/dummy/config/database.yml +25 -0
  37. data/test/dummy/config/environment.rb +5 -0
  38. data/test/dummy/config/environments/development.rb +29 -0
  39. data/test/dummy/config/environments/production.rb +80 -0
  40. data/test/dummy/config/environments/test.rb +36 -0
  41. data/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
  42. data/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
  43. data/test/dummy/config/initializers/inflections.rb +16 -0
  44. data/test/dummy/config/initializers/mime_types.rb +5 -0
  45. data/test/dummy/config/initializers/secret_token.rb +12 -0
  46. data/test/dummy/config/initializers/session_store.rb +3 -0
  47. data/test/dummy/config/initializers/wrap_parameters.rb +14 -0
  48. data/test/dummy/config/locales/en.yml +23 -0
  49. data/test/dummy/config/routes.rb +3 -0
  50. data/test/dummy/config.ru +4 -0
  51. data/test/dummy/db/development.sqlite3 +0 -0
  52. data/test/dummy/db/test.sqlite3 +0 -0
  53. data/test/dummy/log/development.log +726 -0
  54. data/test/dummy/log/test.log +360 -0
  55. data/test/dummy/public/404.html +58 -0
  56. data/test/dummy/public/422.html +58 -0
  57. data/test/dummy/public/500.html +57 -0
  58. data/test/dummy/public/favicon.ico +0 -0
  59. data/test/dummy/tmp/cache/assets/development/sprockets/13fe41fee1fe35b49d145bcc06610705 +0 -0
  60. data/test/dummy/tmp/cache/assets/development/sprockets/1c9faaf28d05409b88ad3113374d613c +0 -0
  61. data/test/dummy/tmp/cache/assets/development/sprockets/2822de3b22c28bd5e718c9bf500457b2 +0 -0
  62. data/test/dummy/tmp/cache/assets/development/sprockets/2f5173deea6c795b8fdde723bb4b63af +0 -0
  63. data/test/dummy/tmp/cache/assets/development/sprockets/357970feca3ac29060c1e3861e2c0953 +0 -0
  64. data/test/dummy/tmp/cache/assets/development/sprockets/40fc2f3d2a468a00e463f1d313cb1683 +0 -0
  65. data/test/dummy/tmp/cache/assets/development/sprockets/a9f028f7a492b5907ed80268be8f50f4 +0 -0
  66. data/test/dummy/tmp/cache/assets/development/sprockets/b878faf942403e313a5b103e5d80488e +0 -0
  67. data/test/dummy/tmp/cache/assets/development/sprockets/cffd775d018f68ce5dba1ee0d951a994 +0 -0
  68. data/test/dummy/tmp/cache/assets/development/sprockets/d771ace226fc8215a3572e0aa35bb0d6 +0 -0
  69. data/test/dummy/tmp/cache/assets/development/sprockets/edbef6e0d0a4742346cf479f2c522eb0 +0 -0
  70. data/test/dummy/tmp/cache/assets/development/sprockets/f7cbd26ba1d28d48de824f0e94586655 +0 -0
  71. data/test/generators/component_generator_test.rb +0 -0
  72. data/test/support/foo.rb +3 -0
  73. data/test/support/foo_controller.rb +4 -0
  74. data/test/test_helper.rb +17 -0
  75. metadata +251 -0
@@ -0,0 +1,360 @@
1
+  (0.3ms) begin transaction
2
+ --------------------------------------------------------------------------------------------------------
3
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component/base_accepts_only_a_hash_of_arguments
4
+ --------------------------------------------------------------------------------------------------------
5
+  (0.1ms) rollback transaction
6
+  (0.1ms) begin transaction
7
+ -------------------------------------------------------------------------------------------------------------------------
8
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component_should_raise_an_error_if_the_given_value_is_not_a_hash
9
+ -------------------------------------------------------------------------------------------------------------------------
10
+  (0.0ms) rollback transaction
11
+  (0.0ms) begin transaction
12
+ ------------------------------------------------------------------------
13
+ ActiveComponent::BaseTest: test_assigns_the_values_to_instance_variables
14
+ ------------------------------------------------------------------------
15
+  (0.0ms) rollback transaction
16
+  (0.0ms) begin transaction
17
+ -------------------------------------------------------------------------
18
+ ActiveComponent::BaseTest: test_has_included_date_helper_from_action_view
19
+ -------------------------------------------------------------------------
20
+  (0.1ms) rollback transaction
21
+  (0.1ms) begin transaction
22
+ -------------------------------------------------------------------------
23
+ ActiveComponent::BaseTest: test_sets_controller_for_the_component_context
24
+ -------------------------------------------------------------------------
25
+  (0.0ms) rollback transaction
26
+  (0.0ms) begin transaction
27
+ --------------------------------------------------------------
28
+ ActiveComponent::ContextTest: test_has_a_get_controller_method
29
+ --------------------------------------------------------------
30
+  (0.1ms) rollback transaction
31
+  (0.1ms) begin transaction
32
+ ---------------------------------------------------------------
33
+ ActiveComponent::ContextTest: test_returns_a_cotroller_instance
34
+ ---------------------------------------------------------------
35
+  (0.0ms) rollback transaction
36
+  (0.0ms) begin transaction
37
+ -------------------------------------------------------------
38
+ ActiveComponent::RailtieTest: test_get_the_controller_context
39
+ -------------------------------------------------------------
40
+  (0.0ms) rollback transaction
41
+  (0.0ms) begin transaction
42
+ ---------------------------------------------------------
43
+ ActiveComponent::RenderableTest: test_renders_a_component
44
+ ---------------------------------------------------------
45
+  (0.0ms) rollback transaction
46
+  (0.2ms) begin transaction
47
+ --------------------------------------------------------------------------------------------------------
48
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component/base_accepts_only_a_hash_of_arguments
49
+ --------------------------------------------------------------------------------------------------------
50
+  (0.1ms) rollback transaction
51
+  (0.1ms) begin transaction
52
+ -------------------------------------------------------------------------------------------------------------------------
53
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component_should_raise_an_error_if_the_given_value_is_not_a_hash
54
+ -------------------------------------------------------------------------------------------------------------------------
55
+  (0.1ms) rollback transaction
56
+  (0.1ms) begin transaction
57
+ ------------------------------------------------------------------------
58
+ ActiveComponent::BaseTest: test_assigns_the_values_to_instance_variables
59
+ ------------------------------------------------------------------------
60
+  (0.1ms) rollback transaction
61
+  (0.1ms) begin transaction
62
+ -------------------------------------------------------------------------
63
+ ActiveComponent::BaseTest: test_has_included_date_helper_from_action_view
64
+ -------------------------------------------------------------------------
65
+  (0.1ms) rollback transaction
66
+  (0.1ms) begin transaction
67
+ -------------------------------------------------------------------------
68
+ ActiveComponent::BaseTest: test_sets_controller_for_the_component_context
69
+ -------------------------------------------------------------------------
70
+  (0.0ms) rollback transaction
71
+  (0.0ms) begin transaction
72
+ --------------------------------------------------------------
73
+ ActiveComponent::ContextTest: test_has_a_get_controller_method
74
+ --------------------------------------------------------------
75
+  (0.1ms) rollback transaction
76
+  (0.1ms) begin transaction
77
+ ---------------------------------------------------------------
78
+ ActiveComponent::ContextTest: test_returns_a_cotroller_instance
79
+ ---------------------------------------------------------------
80
+  (0.0ms) rollback transaction
81
+  (0.0ms) begin transaction
82
+ -------------------------------------------------------------
83
+ ActiveComponent::RailtieTest: test_get_the_controller_context
84
+ -------------------------------------------------------------
85
+  (0.1ms) rollback transaction
86
+  (0.1ms) begin transaction
87
+ ---------------------------------------------------------
88
+ ActiveComponent::RenderableTest: test_renders_a_component
89
+ ---------------------------------------------------------
90
+  (0.1ms) rollback transaction
91
+  (0.2ms) begin transaction
92
+ --------------------------------------------------------------------------------------------------------
93
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component/base_accepts_only_a_hash_of_arguments
94
+ --------------------------------------------------------------------------------------------------------
95
+  (0.1ms) rollback transaction
96
+  (0.1ms) begin transaction
97
+ -------------------------------------------------------------------------------------------------------------------------
98
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component_should_raise_an_error_if_the_given_value_is_not_a_hash
99
+ -------------------------------------------------------------------------------------------------------------------------
100
+  (0.0ms) rollback transaction
101
+  (0.1ms) begin transaction
102
+ ------------------------------------------------------------------------
103
+ ActiveComponent::BaseTest: test_assigns_the_values_to_instance_variables
104
+ ------------------------------------------------------------------------
105
+  (0.0ms) rollback transaction
106
+  (0.1ms) begin transaction
107
+ -------------------------------------------------------------------------
108
+ ActiveComponent::BaseTest: test_has_included_date_helper_from_action_view
109
+ -------------------------------------------------------------------------
110
+  (0.1ms) rollback transaction
111
+  (0.0ms) begin transaction
112
+ -------------------------------------------------------------------------
113
+ ActiveComponent::BaseTest: test_sets_controller_for_the_component_context
114
+ -------------------------------------------------------------------------
115
+  (0.0ms) rollback transaction
116
+  (0.0ms) begin transaction
117
+ ---------------------------------------------------------------
118
+ ActiveComponent::ContextTest: test_returns_a_cotroller_instance
119
+ ---------------------------------------------------------------
120
+  (0.1ms) rollback transaction
121
+  (0.0ms) begin transaction
122
+ -------------------------------------------------------------
123
+ ActiveComponent::RailtieTest: test_get_the_controller_context
124
+ -------------------------------------------------------------
125
+  (0.1ms) rollback transaction
126
+  (0.1ms) begin transaction
127
+ ---------------------------------------------------------
128
+ ActiveComponent::RenderableTest: test_renders_a_component
129
+ ---------------------------------------------------------
130
+  (0.1ms) rollback transaction
131
+  (0.1ms) begin transaction
132
+ -----------------------------------------------------
133
+ ActiveComponentTest: test_has_a_get_controller_method
134
+ -----------------------------------------------------
135
+  (0.1ms) rollback transaction
136
+  (0.3ms) begin transaction
137
+ --------------------------------------------------------------------------------------------------------
138
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component/base_accepts_only_a_hash_of_arguments
139
+ --------------------------------------------------------------------------------------------------------
140
+  (0.1ms) rollback transaction
141
+  (0.1ms) begin transaction
142
+ -------------------------------------------------------------------------------------------------------------------------
143
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component_should_raise_an_error_if_the_given_value_is_not_a_hash
144
+ -------------------------------------------------------------------------------------------------------------------------
145
+  (0.0ms) rollback transaction
146
+  (0.0ms) begin transaction
147
+ ------------------------------------------------------------------------
148
+ ActiveComponent::BaseTest: test_assigns_the_values_to_instance_variables
149
+ ------------------------------------------------------------------------
150
+  (0.0ms) rollback transaction
151
+  (0.0ms) begin transaction
152
+ -------------------------------------------------------------------------
153
+ ActiveComponent::BaseTest: test_has_included_date_helper_from_action_view
154
+ -------------------------------------------------------------------------
155
+  (0.2ms) rollback transaction
156
+  (0.1ms) begin transaction
157
+ -------------------------------------------------------------------------
158
+ ActiveComponent::BaseTest: test_sets_controller_for_the_component_context
159
+ -------------------------------------------------------------------------
160
+  (0.0ms) rollback transaction
161
+  (0.1ms) begin transaction
162
+ ---------------------------------------------------------------
163
+ ActiveComponent::ContextTest: test_returns_a_cotroller_instance
164
+ ---------------------------------------------------------------
165
+  (0.1ms) rollback transaction
166
+  (0.1ms) begin transaction
167
+ -------------------------------------------------------------
168
+ ActiveComponent::RailtieTest: test_get_the_controller_context
169
+ -------------------------------------------------------------
170
+  (0.1ms) rollback transaction
171
+  (0.0ms) begin transaction
172
+ ---------------------------------------------------------
173
+ ActiveComponent::RenderableTest: test_renders_a_component
174
+ ---------------------------------------------------------
175
+  (0.1ms) rollback transaction
176
+  (0.1ms) begin transaction
177
+ -----------------------------------------------------
178
+ ActiveComponentTest: test_has_a_get_controller_method
179
+ -----------------------------------------------------
180
+  (0.1ms) rollback transaction
181
+  (0.2ms) begin transaction
182
+ --------------------------------------------------------------------------------------------------------
183
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component/base_accepts_only_a_hash_of_arguments
184
+ --------------------------------------------------------------------------------------------------------
185
+  (0.1ms) rollback transaction
186
+  (0.1ms) begin transaction
187
+ -------------------------------------------------------------------------------------------------------------------------
188
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component_should_raise_an_error_if_the_given_value_is_not_a_hash
189
+ -------------------------------------------------------------------------------------------------------------------------
190
+  (0.0ms) rollback transaction
191
+  (0.1ms) begin transaction
192
+ ------------------------------------------------------------------------
193
+ ActiveComponent::BaseTest: test_assigns_the_values_to_instance_variables
194
+ ------------------------------------------------------------------------
195
+  (0.0ms) rollback transaction
196
+  (0.1ms) begin transaction
197
+ -------------------------------------------------------------------------
198
+ ActiveComponent::BaseTest: test_has_included_date_helper_from_action_view
199
+ -------------------------------------------------------------------------
200
+  (0.1ms) rollback transaction
201
+  (0.1ms) begin transaction
202
+ -------------------------------------------------------------------------
203
+ ActiveComponent::BaseTest: test_sets_controller_for_the_component_context
204
+ -------------------------------------------------------------------------
205
+  (0.0ms) rollback transaction
206
+  (0.0ms) begin transaction
207
+ ---------------------------------------------------------------
208
+ ActiveComponent::ContextTest: test_returns_a_cotroller_instance
209
+ ---------------------------------------------------------------
210
+  (0.1ms) rollback transaction
211
+  (0.0ms) begin transaction
212
+ -------------------------------------------------------------
213
+ ActiveComponent::RailtieTest: test_get_the_controller_context
214
+ -------------------------------------------------------------
215
+  (0.0ms) rollback transaction
216
+  (0.0ms) begin transaction
217
+ ---------------------------------------------------------
218
+ ActiveComponent::RenderableTest: test_renders_a_component
219
+ ---------------------------------------------------------
220
+  (0.0ms) rollback transaction
221
+  (0.0ms) begin transaction
222
+ -----------------------------------------------------
223
+ ActiveComponentTest: test_has_a_get_controller_method
224
+ -----------------------------------------------------
225
+  (0.0ms) rollback transaction
226
+  (0.3ms) begin transaction
227
+ --------------------------------------------------------------------------------------------------------
228
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component/base_accepts_only_a_hash_of_arguments
229
+ --------------------------------------------------------------------------------------------------------
230
+  (0.1ms) rollback transaction
231
+  (0.1ms) begin transaction
232
+ -------------------------------------------------------------------------------------------------------------------------
233
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component_should_raise_an_error_if_the_given_value_is_not_a_hash
234
+ -------------------------------------------------------------------------------------------------------------------------
235
+  (0.0ms) rollback transaction
236
+  (0.0ms) begin transaction
237
+ ------------------------------------------------------------------------
238
+ ActiveComponent::BaseTest: test_assigns_the_values_to_instance_variables
239
+ ------------------------------------------------------------------------
240
+  (0.0ms) rollback transaction
241
+  (0.0ms) begin transaction
242
+ -------------------------------------------------------------------------
243
+ ActiveComponent::BaseTest: test_has_included_date_helper_from_action_view
244
+ -------------------------------------------------------------------------
245
+  (0.1ms) rollback transaction
246
+  (0.0ms) begin transaction
247
+ -------------------------------------------------------------------------
248
+ ActiveComponent::BaseTest: test_sets_controller_for_the_component_context
249
+ -------------------------------------------------------------------------
250
+  (0.0ms) rollback transaction
251
+  (0.0ms) begin transaction
252
+ ---------------------------------------------------------------
253
+ ActiveComponent::ContextTest: test_returns_a_cotroller_instance
254
+ ---------------------------------------------------------------
255
+  (0.1ms) rollback transaction
256
+  (0.1ms) begin transaction
257
+ -------------------------------------------------------------
258
+ ActiveComponent::RailtieTest: test_get_the_controller_context
259
+ -------------------------------------------------------------
260
+  (0.1ms) rollback transaction
261
+  (0.0ms) begin transaction
262
+ ---------------------------------------------------------
263
+ ActiveComponent::RenderableTest: test_renders_a_component
264
+ ---------------------------------------------------------
265
+  (0.0ms) rollback transaction
266
+  (0.0ms) begin transaction
267
+ -----------------------------------------------------
268
+ ActiveComponentTest: test_has_a_get_controller_method
269
+ -----------------------------------------------------
270
+  (0.1ms) rollback transaction
271
+  (0.2ms) begin transaction
272
+ --------------------------------------------------------------------------------------------------------
273
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component/base_accepts_only_a_hash_of_arguments
274
+ --------------------------------------------------------------------------------------------------------
275
+  (0.1ms) rollback transaction
276
+  (0.1ms) begin transaction
277
+ -------------------------------------------------------------------------------------------------------------------------
278
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component_should_raise_an_error_if_the_given_value_is_not_a_hash
279
+ -------------------------------------------------------------------------------------------------------------------------
280
+  (0.0ms) rollback transaction
281
+  (0.0ms) begin transaction
282
+ ------------------------------------------------------------------------
283
+ ActiveComponent::BaseTest: test_assigns_the_values_to_instance_variables
284
+ ------------------------------------------------------------------------
285
+  (0.0ms) rollback transaction
286
+  (0.0ms) begin transaction
287
+ -------------------------------------------------------------------------
288
+ ActiveComponent::BaseTest: test_has_included_date_helper_from_action_view
289
+ -------------------------------------------------------------------------
290
+  (0.1ms) rollback transaction
291
+  (0.0ms) begin transaction
292
+ -------------------------------------------------------------------------
293
+ ActiveComponent::BaseTest: test_sets_controller_for_the_component_context
294
+ -------------------------------------------------------------------------
295
+  (0.0ms) rollback transaction
296
+  (0.0ms) begin transaction
297
+ ---------------------------------------------------------------
298
+ ActiveComponent::ContextTest: test_returns_a_cotroller_instance
299
+ ---------------------------------------------------------------
300
+  (0.1ms) rollback transaction
301
+  (0.0ms) begin transaction
302
+ -------------------------------------------------------------
303
+ ActiveComponent::RailtieTest: test_get_the_controller_context
304
+ -------------------------------------------------------------
305
+  (0.1ms) rollback transaction
306
+  (0.0ms) begin transaction
307
+ ---------------------------------------------------------
308
+ ActiveComponent::RenderableTest: test_renders_a_component
309
+ ---------------------------------------------------------
310
+  (0.1ms) rollback transaction
311
+  (0.1ms) begin transaction
312
+ -----------------------------------------------------
313
+ ActiveComponentTest: test_has_a_get_controller_method
314
+ -----------------------------------------------------
315
+  (0.1ms) rollback transaction
316
+  (0.4ms) begin transaction
317
+ --------------------------------------------------------------------------------------------------------
318
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component/base_accepts_only_a_hash_of_arguments
319
+ --------------------------------------------------------------------------------------------------------
320
+  (0.1ms) rollback transaction
321
+  (0.1ms) begin transaction
322
+ -------------------------------------------------------------------------------------------------------------------------
323
+ ActiveComponent::BaseTest: test_a_new_instance_of_active_component_should_raise_an_error_if_the_given_value_is_not_a_hash
324
+ -------------------------------------------------------------------------------------------------------------------------
325
+  (0.0ms) rollback transaction
326
+  (0.1ms) begin transaction
327
+ ------------------------------------------------------------------------
328
+ ActiveComponent::BaseTest: test_assigns_the_values_to_instance_variables
329
+ ------------------------------------------------------------------------
330
+  (0.0ms) rollback transaction
331
+  (0.1ms) begin transaction
332
+ -------------------------------------------------------------------------
333
+ ActiveComponent::BaseTest: test_has_included_date_helper_from_action_view
334
+ -------------------------------------------------------------------------
335
+  (0.1ms) rollback transaction
336
+  (0.0ms) begin transaction
337
+ -------------------------------------------------------------------------
338
+ ActiveComponent::BaseTest: test_sets_controller_for_the_component_context
339
+ -------------------------------------------------------------------------
340
+  (0.0ms) rollback transaction
341
+  (0.0ms) begin transaction
342
+ ---------------------------------------------------------------
343
+ ActiveComponent::ContextTest: test_returns_a_cotroller_instance
344
+ ---------------------------------------------------------------
345
+  (0.1ms) rollback transaction
346
+  (0.0ms) begin transaction
347
+ -------------------------------------------------------------
348
+ ActiveComponent::RailtieTest: test_get_the_controller_context
349
+ -------------------------------------------------------------
350
+  (0.1ms) rollback transaction
351
+  (0.0ms) begin transaction
352
+ ---------------------------------------------------------
353
+ ActiveComponent::RenderableTest: test_renders_a_component
354
+ ---------------------------------------------------------
355
+  (0.0ms) rollback transaction
356
+  (0.0ms) begin transaction
357
+ -----------------------------------------------------
358
+ ActiveComponentTest: test_has_a_get_controller_method
359
+ -----------------------------------------------------
360
+  (0.1ms) rollback transaction
@@ -0,0 +1,58 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>The page you were looking for doesn't exist (404)</title>
5
+ <style>
6
+ body {
7
+ background-color: #EFEFEF;
8
+ color: #2E2F30;
9
+ text-align: center;
10
+ font-family: arial, sans-serif;
11
+ }
12
+
13
+ div.dialog {
14
+ width: 25em;
15
+ margin: 4em auto 0 auto;
16
+ border: 1px solid #CCC;
17
+ border-right-color: #999;
18
+ border-left-color: #999;
19
+ border-bottom-color: #BBB;
20
+ border-top: #B00100 solid 4px;
21
+ border-top-left-radius: 9px;
22
+ border-top-right-radius: 9px;
23
+ background-color: white;
24
+ padding: 7px 4em 0 4em;
25
+ }
26
+
27
+ h1 {
28
+ font-size: 100%;
29
+ color: #730E15;
30
+ line-height: 1.5em;
31
+ }
32
+
33
+ body > p {
34
+ width: 33em;
35
+ margin: 0 auto 1em;
36
+ padding: 1em 0;
37
+ background-color: #F7F7F7;
38
+ border: 1px solid #CCC;
39
+ border-right-color: #999;
40
+ border-bottom-color: #999;
41
+ border-bottom-left-radius: 4px;
42
+ border-bottom-right-radius: 4px;
43
+ border-top-color: #DADADA;
44
+ color: #666;
45
+ box-shadow:0 3px 8px rgba(50, 50, 50, 0.17);
46
+ }
47
+ </style>
48
+ </head>
49
+
50
+ <body>
51
+ <!-- This file lives in public/404.html -->
52
+ <div class="dialog">
53
+ <h1>The page you were looking for doesn't exist.</h1>
54
+ <p>You may have mistyped the address or the page may have moved.</p>
55
+ </div>
56
+ <p>If you are the application owner check the logs for more information.</p>
57
+ </body>
58
+ </html>
@@ -0,0 +1,58 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>The change you wanted was rejected (422)</title>
5
+ <style>
6
+ body {
7
+ background-color: #EFEFEF;
8
+ color: #2E2F30;
9
+ text-align: center;
10
+ font-family: arial, sans-serif;
11
+ }
12
+
13
+ div.dialog {
14
+ width: 25em;
15
+ margin: 4em auto 0 auto;
16
+ border: 1px solid #CCC;
17
+ border-right-color: #999;
18
+ border-left-color: #999;
19
+ border-bottom-color: #BBB;
20
+ border-top: #B00100 solid 4px;
21
+ border-top-left-radius: 9px;
22
+ border-top-right-radius: 9px;
23
+ background-color: white;
24
+ padding: 7px 4em 0 4em;
25
+ }
26
+
27
+ h1 {
28
+ font-size: 100%;
29
+ color: #730E15;
30
+ line-height: 1.5em;
31
+ }
32
+
33
+ body > p {
34
+ width: 33em;
35
+ margin: 0 auto 1em;
36
+ padding: 1em 0;
37
+ background-color: #F7F7F7;
38
+ border: 1px solid #CCC;
39
+ border-right-color: #999;
40
+ border-bottom-color: #999;
41
+ border-bottom-left-radius: 4px;
42
+ border-bottom-right-radius: 4px;
43
+ border-top-color: #DADADA;
44
+ color: #666;
45
+ box-shadow:0 3px 8px rgba(50, 50, 50, 0.17);
46
+ }
47
+ </style>
48
+ </head>
49
+
50
+ <body>
51
+ <!-- This file lives in public/422.html -->
52
+ <div class="dialog">
53
+ <h1>The change you wanted was rejected.</h1>
54
+ <p>Maybe you tried to change something you didn't have access to.</p>
55
+ </div>
56
+ <p>If you are the application owner check the logs for more information.</p>
57
+ </body>
58
+ </html>
@@ -0,0 +1,57 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>We're sorry, but something went wrong (500)</title>
5
+ <style>
6
+ body {
7
+ background-color: #EFEFEF;
8
+ color: #2E2F30;
9
+ text-align: center;
10
+ font-family: arial, sans-serif;
11
+ }
12
+
13
+ div.dialog {
14
+ width: 25em;
15
+ margin: 4em auto 0 auto;
16
+ border: 1px solid #CCC;
17
+ border-right-color: #999;
18
+ border-left-color: #999;
19
+ border-bottom-color: #BBB;
20
+ border-top: #B00100 solid 4px;
21
+ border-top-left-radius: 9px;
22
+ border-top-right-radius: 9px;
23
+ background-color: white;
24
+ padding: 7px 4em 0 4em;
25
+ }
26
+
27
+ h1 {
28
+ font-size: 100%;
29
+ color: #730E15;
30
+ line-height: 1.5em;
31
+ }
32
+
33
+ body > p {
34
+ width: 33em;
35
+ margin: 0 auto 1em;
36
+ padding: 1em 0;
37
+ background-color: #F7F7F7;
38
+ border: 1px solid #CCC;
39
+ border-right-color: #999;
40
+ border-bottom-color: #999;
41
+ border-bottom-left-radius: 4px;
42
+ border-bottom-right-radius: 4px;
43
+ border-top-color: #DADADA;
44
+ color: #666;
45
+ box-shadow:0 3px 8px rgba(50, 50, 50, 0.17);
46
+ }
47
+ </style>
48
+ </head>
49
+
50
+ <body>
51
+ <!-- This file lives in public/500.html -->
52
+ <div class="dialog">
53
+ <h1>We're sorry, but something went wrong.</h1>
54
+ </div>
55
+ <p>If you are the application owner check the logs for more information.</p>
56
+ </body>
57
+ </html>
File without changes
File without changes
@@ -0,0 +1,3 @@
1
+ class Foo < ActiveComponent::Base
2
+ attr_accessor :bar
3
+ end
@@ -0,0 +1,4 @@
1
+ class FooController < ApplicationController
2
+ def index
3
+ end
4
+ end
@@ -0,0 +1,17 @@
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
+ require 'faker'
7
+ require 'pry'
8
+
9
+ Rails.backtrace_cleaner.remove_silencers!
10
+
11
+ # Load support files
12
+ Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
13
+
14
+ # Load fixtures from the engine
15
+ if ActiveSupport::TestCase.method_defined?(:fixture_path=)
16
+ ActiveSupport::TestCase.fixture_path = File.expand_path("../fixtures", __FILE__)
17
+ end