angular_xss 0.3.0 → 0.4.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (100) hide show
  1. checksums.yaml +7 -0
  2. data/.github/workflows/test.yml +58 -0
  3. data/.rspec +1 -0
  4. data/.ruby-version +1 -0
  5. data/CHANGELOG.md +78 -0
  6. data/Gemfile +1 -0
  7. data/Gemfile.lock +1 -0
  8. data/Gemfile.rails-3.2 +9 -0
  9. data/Gemfile.rails-3.2.lock +91 -0
  10. data/Gemfile.rails-4.2.haml-4 +8 -0
  11. data/Gemfile.rails-4.2.haml-4.lock +88 -0
  12. data/Gemfile.rails-4.2.haml-5 +8 -0
  13. data/Gemfile.rails-4.2.haml-5.lock +90 -0
  14. data/Gemfile.rails-5.1.haml-4 +8 -0
  15. data/Gemfile.rails-5.1.haml-4.lock +85 -0
  16. data/Gemfile.rails-5.1.haml-5 +8 -0
  17. data/Gemfile.rails-5.1.haml-5.lock +87 -0
  18. data/Gemfile.rails-6.1.haml-5 +8 -0
  19. data/Gemfile.rails-6.1.haml-5.lock +90 -0
  20. data/Gemfile.rails-7.0.haml-5 +8 -0
  21. data/Gemfile.rails-7.0.haml-5.lock +86 -0
  22. data/README.md +2 -1
  23. data/Rakefile +3 -66
  24. data/angular_xss.gemspec +1 -0
  25. data/lib/angular_xss/action_view.rb +2 -1
  26. data/lib/angular_xss/erb.rb +2 -1
  27. data/lib/angular_xss/haml.rb +27 -10
  28. data/lib/angular_xss/safe_buffer.rb +31 -6
  29. data/lib/angular_xss/version.rb +1 -1
  30. data/spec/{shared/tests → angular_xss}/erb_spec.rb +1 -1
  31. data/spec/{shared/tests → angular_xss}/haml_spec.rb +1 -1
  32. data/spec/{shared/tests → angular_xss}/safe_buffer_spec.rb +0 -0
  33. data/spec/spec_helper.rb +37 -0
  34. data/spec/{shared/support → support}/engine_preventing_angular_xss.rb +14 -2
  35. data/spec/{shared/app_root/app/views/test → templates}/_test_erb.erb +0 -0
  36. data/spec/{shared/app_root/app/views/test → templates}/_test_haml.haml +5 -3
  37. metadata +82 -205
  38. data/.travis.yml +0 -15
  39. data/spec/rails-2.3/Gemfile +0 -12
  40. data/spec/rails-2.3/Gemfile.lock +0 -62
  41. data/spec/rails-2.3/Rakefile +0 -11
  42. data/spec/rails-2.3/app_root/config/boot.rb +0 -129
  43. data/spec/rails-2.3/app_root/config/database.yml +0 -4
  44. data/spec/rails-2.3/app_root/config/environment.rb +0 -14
  45. data/spec/rails-2.3/app_root/config/environments/test.rb +0 -28
  46. data/spec/rails-2.3/app_root/config/preinitializer.rb +0 -20
  47. data/spec/rails-2.3/app_root/config/routes.rb +0 -4
  48. data/spec/rails-2.3/app_root/lib/console_with_fixtures.rb +0 -4
  49. data/spec/rails-2.3/app_root/log/.gitignore +0 -1
  50. data/spec/rails-2.3/app_root/script/console +0 -7
  51. data/spec/rails-2.3/rcov.opts +0 -2
  52. data/spec/rails-2.3/spec/spec_helper.rb +0 -20
  53. data/spec/rails-2.3/spec.opts +0 -4
  54. data/spec/rails-3.2/.rspec +0 -2
  55. data/spec/rails-3.2/Gemfile +0 -10
  56. data/spec/rails-3.2/Gemfile.lock +0 -129
  57. data/spec/rails-3.2/Rakefile +0 -10
  58. data/spec/rails-3.2/app_root/.gitignore +0 -4
  59. data/spec/rails-3.2/app_root/config/application.rb +0 -32
  60. data/spec/rails-3.2/app_root/config/boot.rb +0 -13
  61. data/spec/rails-3.2/app_root/config/database.yml +0 -4
  62. data/spec/rails-3.2/app_root/config/environment.rb +0 -5
  63. data/spec/rails-3.2/app_root/config/environments/test.rb +0 -35
  64. data/spec/rails-3.2/app_root/config/initializers/backtrace_silencers.rb +0 -7
  65. data/spec/rails-3.2/app_root/config/initializers/inflections.rb +0 -10
  66. data/spec/rails-3.2/app_root/config/initializers/mime_types.rb +0 -5
  67. data/spec/rails-3.2/app_root/config/initializers/secret_token.rb +0 -7
  68. data/spec/rails-3.2/app_root/config/initializers/session_store.rb +0 -8
  69. data/spec/rails-3.2/app_root/config/routes.rb +0 -58
  70. data/spec/rails-3.2/app_root/lib/tasks/.gitkeep +0 -0
  71. data/spec/rails-3.2/app_root/log/.gitkeep +0 -0
  72. data/spec/rails-3.2/app_root/script/rails +0 -6
  73. data/spec/rails-3.2/rcov.opts +0 -2
  74. data/spec/rails-3.2/spec/spec_helper.rb +0 -20
  75. data/spec/rails-4.2/.rspec +0 -2
  76. data/spec/rails-4.2/Gemfile +0 -10
  77. data/spec/rails-4.2/Gemfile.lock +0 -157
  78. data/spec/rails-4.2/Rakefile +0 -10
  79. data/spec/rails-4.2/app_root/.gitignore +0 -4
  80. data/spec/rails-4.2/app_root/config/application.rb +0 -34
  81. data/spec/rails-4.2/app_root/config/boot.rb +0 -13
  82. data/spec/rails-4.2/app_root/config/database.yml +0 -4
  83. data/spec/rails-4.2/app_root/config/environment.rb +0 -5
  84. data/spec/rails-4.2/app_root/config/environments/test.rb +0 -35
  85. data/spec/rails-4.2/app_root/config/initializers/backtrace_silencers.rb +0 -7
  86. data/spec/rails-4.2/app_root/config/initializers/inflections.rb +0 -10
  87. data/spec/rails-4.2/app_root/config/initializers/mime_types.rb +0 -5
  88. data/spec/rails-4.2/app_root/config/initializers/secret_token.rb +0 -7
  89. data/spec/rails-4.2/app_root/config/initializers/session_store.rb +0 -8
  90. data/spec/rails-4.2/app_root/config/routes.rb +0 -3
  91. data/spec/rails-4.2/app_root/lib/tasks/.gitkeep +0 -0
  92. data/spec/rails-4.2/app_root/log/.gitkeep +0 -0
  93. data/spec/rails-4.2/app_root/script/rails +0 -6
  94. data/spec/rails-4.2/rcov.opts +0 -2
  95. data/spec/rails-4.2/spec/spec_helper.rb +0 -27
  96. data/spec/shared/app_root/app/controllers/application_controller.rb +0 -2
  97. data/spec/shared/app_root/app/helpers/application_helper.rb +0 -3
  98. data/spec/shared/app_root/app/models/.gitkeep +0 -0
  99. data/spec/shared/app_root/config/database.yml +0 -4
  100. data/spec/shared/app_root/db/migrate/.gitkeep +0 -0
metadata CHANGED
@@ -1,63 +1,71 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: angular_xss
3
- version: !ruby/object:Gem::Version
4
- hash: 19
5
- prerelease:
6
- segments:
7
- - 0
8
- - 3
9
- - 0
10
- version: 0.3.0
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.4.1
11
5
  platform: ruby
12
- authors:
6
+ authors:
13
7
  - Henning Koch
14
8
  autorequire:
15
9
  bindir: bin
16
10
  cert_chain: []
17
-
18
- date: 2017-07-31 00:00:00 Z
19
- dependencies:
20
- - !ruby/object:Gem::Dependency
11
+ date: 2022-03-16 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
21
14
  name: activesupport
22
- prerelease: false
23
- requirement: &id001 !ruby/object:Gem::Requirement
24
- none: false
25
- requirements:
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
26
17
  - - ">="
27
- - !ruby/object:Gem::Version
28
- hash: 3
29
- segments:
30
- - 0
31
- version: "0"
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
32
20
  type: :runtime
33
- version_requirements: *id001
34
- - !ruby/object:Gem::Dependency
35
- name: haml
36
21
  prerelease: false
37
- requirement: &id002 !ruby/object:Gem::Requirement
38
- none: false
39
- requirements:
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: haml
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
40
31
  - - ">="
41
- - !ruby/object:Gem::Version
42
- hash: 9
43
- segments:
44
- - 3
45
- - 1
46
- - 5
32
+ - !ruby/object:Gem::Version
47
33
  version: 3.1.5
48
34
  type: :runtime
49
- version_requirements: *id002
50
- description: Patches rails_xss and Haml so AngularJS interpolations are auto-escaped in unsafe strings.
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: 3.1.5
41
+ description: Patches rails_xss and Haml so AngularJS interpolations are auto-escaped
42
+ in unsafe strings.
51
43
  email: henning.koch@makandra.de
52
44
  executables: []
53
-
54
45
  extensions: []
55
-
56
46
  extra_rdoc_files: []
57
-
58
- files:
59
- - .gitignore
60
- - .travis.yml
47
+ files:
48
+ - ".github/workflows/test.yml"
49
+ - ".gitignore"
50
+ - ".rspec"
51
+ - ".ruby-version"
52
+ - CHANGELOG.md
53
+ - Gemfile
54
+ - Gemfile.lock
55
+ - Gemfile.rails-3.2
56
+ - Gemfile.rails-3.2.lock
57
+ - Gemfile.rails-4.2.haml-4
58
+ - Gemfile.rails-4.2.haml-4.lock
59
+ - Gemfile.rails-4.2.haml-5
60
+ - Gemfile.rails-4.2.haml-5.lock
61
+ - Gemfile.rails-5.1.haml-4
62
+ - Gemfile.rails-5.1.haml-4.lock
63
+ - Gemfile.rails-5.1.haml-5
64
+ - Gemfile.rails-5.1.haml-5.lock
65
+ - Gemfile.rails-6.1.haml-5
66
+ - Gemfile.rails-6.1.haml-5.lock
67
+ - Gemfile.rails-7.0.haml-5
68
+ - Gemfile.rails-7.0.haml-5.lock
61
69
  - LICENSE
62
70
  - README.md
63
71
  - Rakefile
@@ -69,174 +77,43 @@ files:
69
77
  - lib/angular_xss/haml.rb
70
78
  - lib/angular_xss/safe_buffer.rb
71
79
  - lib/angular_xss/version.rb
72
- - spec/rails-2.3/Gemfile
73
- - spec/rails-2.3/Gemfile.lock
74
- - spec/rails-2.3/Rakefile
75
- - spec/rails-2.3/app_root/config/boot.rb
76
- - spec/rails-2.3/app_root/config/database.yml
77
- - spec/rails-2.3/app_root/config/environment.rb
78
- - spec/rails-2.3/app_root/config/environments/test.rb
79
- - spec/rails-2.3/app_root/config/preinitializer.rb
80
- - spec/rails-2.3/app_root/config/routes.rb
81
- - spec/rails-2.3/app_root/lib/console_with_fixtures.rb
82
- - spec/rails-2.3/app_root/log/.gitignore
83
- - spec/rails-2.3/app_root/script/console
84
- - spec/rails-2.3/rcov.opts
85
- - spec/rails-2.3/spec.opts
86
- - spec/rails-2.3/spec/spec_helper.rb
87
- - spec/rails-3.2/.rspec
88
- - spec/rails-3.2/Gemfile
89
- - spec/rails-3.2/Gemfile.lock
90
- - spec/rails-3.2/Rakefile
91
- - spec/rails-3.2/app_root/.gitignore
92
- - spec/rails-3.2/app_root/config/application.rb
93
- - spec/rails-3.2/app_root/config/boot.rb
94
- - spec/rails-3.2/app_root/config/database.yml
95
- - spec/rails-3.2/app_root/config/environment.rb
96
- - spec/rails-3.2/app_root/config/environments/test.rb
97
- - spec/rails-3.2/app_root/config/initializers/backtrace_silencers.rb
98
- - spec/rails-3.2/app_root/config/initializers/inflections.rb
99
- - spec/rails-3.2/app_root/config/initializers/mime_types.rb
100
- - spec/rails-3.2/app_root/config/initializers/secret_token.rb
101
- - spec/rails-3.2/app_root/config/initializers/session_store.rb
102
- - spec/rails-3.2/app_root/config/routes.rb
103
- - spec/rails-3.2/app_root/lib/tasks/.gitkeep
104
- - spec/rails-3.2/app_root/log/.gitkeep
105
- - spec/rails-3.2/app_root/script/rails
106
- - spec/rails-3.2/rcov.opts
107
- - spec/rails-3.2/spec/spec_helper.rb
108
- - spec/rails-4.2/.rspec
109
- - spec/rails-4.2/Gemfile
110
- - spec/rails-4.2/Gemfile.lock
111
- - spec/rails-4.2/Rakefile
112
- - spec/rails-4.2/app_root/.gitignore
113
- - spec/rails-4.2/app_root/config/application.rb
114
- - spec/rails-4.2/app_root/config/boot.rb
115
- - spec/rails-4.2/app_root/config/database.yml
116
- - spec/rails-4.2/app_root/config/environment.rb
117
- - spec/rails-4.2/app_root/config/environments/test.rb
118
- - spec/rails-4.2/app_root/config/initializers/backtrace_silencers.rb
119
- - spec/rails-4.2/app_root/config/initializers/inflections.rb
120
- - spec/rails-4.2/app_root/config/initializers/mime_types.rb
121
- - spec/rails-4.2/app_root/config/initializers/secret_token.rb
122
- - spec/rails-4.2/app_root/config/initializers/session_store.rb
123
- - spec/rails-4.2/app_root/config/routes.rb
124
- - spec/rails-4.2/app_root/lib/tasks/.gitkeep
125
- - spec/rails-4.2/app_root/log/.gitkeep
126
- - spec/rails-4.2/app_root/script/rails
127
- - spec/rails-4.2/rcov.opts
128
- - spec/rails-4.2/spec/spec_helper.rb
129
- - spec/shared/app_root/app/controllers/application_controller.rb
130
- - spec/shared/app_root/app/helpers/application_helper.rb
131
- - spec/shared/app_root/app/models/.gitkeep
132
- - spec/shared/app_root/app/views/test/_test_erb.erb
133
- - spec/shared/app_root/app/views/test/_test_haml.haml
134
- - spec/shared/app_root/config/database.yml
135
- - spec/shared/app_root/db/migrate/.gitkeep
136
- - spec/shared/support/engine_preventing_angular_xss.rb
137
- - spec/shared/tests/erb_spec.rb
138
- - spec/shared/tests/haml_spec.rb
139
- - spec/shared/tests/safe_buffer_spec.rb
80
+ - spec/angular_xss/erb_spec.rb
81
+ - spec/angular_xss/haml_spec.rb
82
+ - spec/angular_xss/safe_buffer_spec.rb
83
+ - spec/spec_helper.rb
84
+ - spec/support/engine_preventing_angular_xss.rb
85
+ - spec/templates/_test_erb.erb
86
+ - spec/templates/_test_haml.haml
140
87
  homepage: https://github.com/makandra/angular_xss
141
- licenses:
88
+ licenses:
142
89
  - MIT
90
+ metadata:
91
+ rubygems_mfa_required: 'true'
143
92
  post_install_message:
144
93
  rdoc_options: []
145
-
146
- require_paths:
94
+ require_paths:
147
95
  - lib
148
- required_ruby_version: !ruby/object:Gem::Requirement
149
- none: false
150
- requirements:
96
+ required_ruby_version: !ruby/object:Gem::Requirement
97
+ requirements:
151
98
  - - ">="
152
- - !ruby/object:Gem::Version
153
- hash: 3
154
- segments:
155
- - 0
156
- version: "0"
157
- required_rubygems_version: !ruby/object:Gem::Requirement
158
- none: false
159
- requirements:
99
+ - !ruby/object:Gem::Version
100
+ version: '0'
101
+ required_rubygems_version: !ruby/object:Gem::Requirement
102
+ requirements:
160
103
  - - ">="
161
- - !ruby/object:Gem::Version
162
- hash: 3
163
- segments:
164
- - 0
165
- version: "0"
104
+ - !ruby/object:Gem::Version
105
+ version: '0'
166
106
  requirements: []
167
-
168
- rubyforge_project:
169
- rubygems_version: 1.8.30
107
+ rubygems_version: 3.3.9
170
108
  signing_key:
171
- specification_version: 3
172
- summary: Patches rails_xss and Haml so AngularJS interpolations are auto-escaped in unsafe strings.
173
- test_files:
174
- - spec/rails-2.3/Gemfile
175
- - spec/rails-2.3/Gemfile.lock
176
- - spec/rails-2.3/Rakefile
177
- - spec/rails-2.3/app_root/config/boot.rb
178
- - spec/rails-2.3/app_root/config/database.yml
179
- - spec/rails-2.3/app_root/config/environment.rb
180
- - spec/rails-2.3/app_root/config/environments/test.rb
181
- - spec/rails-2.3/app_root/config/preinitializer.rb
182
- - spec/rails-2.3/app_root/config/routes.rb
183
- - spec/rails-2.3/app_root/lib/console_with_fixtures.rb
184
- - spec/rails-2.3/app_root/log/.gitignore
185
- - spec/rails-2.3/app_root/script/console
186
- - spec/rails-2.3/rcov.opts
187
- - spec/rails-2.3/spec.opts
188
- - spec/rails-2.3/spec/spec_helper.rb
189
- - spec/rails-3.2/.rspec
190
- - spec/rails-3.2/Gemfile
191
- - spec/rails-3.2/Gemfile.lock
192
- - spec/rails-3.2/Rakefile
193
- - spec/rails-3.2/app_root/.gitignore
194
- - spec/rails-3.2/app_root/config/application.rb
195
- - spec/rails-3.2/app_root/config/boot.rb
196
- - spec/rails-3.2/app_root/config/database.yml
197
- - spec/rails-3.2/app_root/config/environment.rb
198
- - spec/rails-3.2/app_root/config/environments/test.rb
199
- - spec/rails-3.2/app_root/config/initializers/backtrace_silencers.rb
200
- - spec/rails-3.2/app_root/config/initializers/inflections.rb
201
- - spec/rails-3.2/app_root/config/initializers/mime_types.rb
202
- - spec/rails-3.2/app_root/config/initializers/secret_token.rb
203
- - spec/rails-3.2/app_root/config/initializers/session_store.rb
204
- - spec/rails-3.2/app_root/config/routes.rb
205
- - spec/rails-3.2/app_root/lib/tasks/.gitkeep
206
- - spec/rails-3.2/app_root/log/.gitkeep
207
- - spec/rails-3.2/app_root/script/rails
208
- - spec/rails-3.2/rcov.opts
209
- - spec/rails-3.2/spec/spec_helper.rb
210
- - spec/rails-4.2/.rspec
211
- - spec/rails-4.2/Gemfile
212
- - spec/rails-4.2/Gemfile.lock
213
- - spec/rails-4.2/Rakefile
214
- - spec/rails-4.2/app_root/.gitignore
215
- - spec/rails-4.2/app_root/config/application.rb
216
- - spec/rails-4.2/app_root/config/boot.rb
217
- - spec/rails-4.2/app_root/config/database.yml
218
- - spec/rails-4.2/app_root/config/environment.rb
219
- - spec/rails-4.2/app_root/config/environments/test.rb
220
- - spec/rails-4.2/app_root/config/initializers/backtrace_silencers.rb
221
- - spec/rails-4.2/app_root/config/initializers/inflections.rb
222
- - spec/rails-4.2/app_root/config/initializers/mime_types.rb
223
- - spec/rails-4.2/app_root/config/initializers/secret_token.rb
224
- - spec/rails-4.2/app_root/config/initializers/session_store.rb
225
- - spec/rails-4.2/app_root/config/routes.rb
226
- - spec/rails-4.2/app_root/lib/tasks/.gitkeep
227
- - spec/rails-4.2/app_root/log/.gitkeep
228
- - spec/rails-4.2/app_root/script/rails
229
- - spec/rails-4.2/rcov.opts
230
- - spec/rails-4.2/spec/spec_helper.rb
231
- - spec/shared/app_root/app/controllers/application_controller.rb
232
- - spec/shared/app_root/app/helpers/application_helper.rb
233
- - spec/shared/app_root/app/models/.gitkeep
234
- - spec/shared/app_root/app/views/test/_test_erb.erb
235
- - spec/shared/app_root/app/views/test/_test_haml.haml
236
- - spec/shared/app_root/config/database.yml
237
- - spec/shared/app_root/db/migrate/.gitkeep
238
- - spec/shared/support/engine_preventing_angular_xss.rb
239
- - spec/shared/tests/erb_spec.rb
240
- - spec/shared/tests/haml_spec.rb
241
- - spec/shared/tests/safe_buffer_spec.rb
242
- has_rdoc:
109
+ specification_version: 4
110
+ summary: Patches rails_xss and Haml so AngularJS interpolations are auto-escaped in
111
+ unsafe strings.
112
+ test_files:
113
+ - spec/angular_xss/erb_spec.rb
114
+ - spec/angular_xss/haml_spec.rb
115
+ - spec/angular_xss/safe_buffer_spec.rb
116
+ - spec/spec_helper.rb
117
+ - spec/support/engine_preventing_angular_xss.rb
118
+ - spec/templates/_test_erb.erb
119
+ - spec/templates/_test_haml.haml
data/.travis.yml DELETED
@@ -1,15 +0,0 @@
1
- language: ruby
2
- rvm:
3
- - "1.8.7"
4
- - "1.9.3"
5
- - "2.1.2"
6
- services:
7
- - mysql
8
- script: rake travis:run
9
- notifications:
10
- email:
11
- - fail@makandra.de
12
- branches:
13
- only:
14
- - master
15
-
@@ -1,12 +0,0 @@
1
- source 'http://rubygems.org'
2
-
3
- gem 'sqlite3'
4
- gem 'test-unit', '=1.2.3', :platforms => :ruby_19 # satisfy Travis CI
5
- gem 'hoe', '=2.8.0', :platforms => :ruby_19 # satisfy Travis CI
6
- gem 'rails', '~>2.3.10'
7
- gem 'rspec', '<2'
8
- gem 'rspec-rails', '<2'
9
- gem 'rspec_candy'
10
- gem 'haml', '=3.1.5'
11
- gem 'rails_xss'
12
- gem 'angular_xss', :path => '../..'
@@ -1,62 +0,0 @@
1
- PATH
2
- remote: ../..
3
- specs:
4
- angular_xss (0.3.0)
5
- activesupport
6
- haml (>= 3.1.5)
7
-
8
- GEM
9
- remote: http://rubygems.org/
10
- specs:
11
- actionmailer (2.3.18)
12
- actionpack (= 2.3.18)
13
- actionpack (2.3.18)
14
- activesupport (= 2.3.18)
15
- rack (~> 1.1.0)
16
- activerecord (2.3.18)
17
- activesupport (= 2.3.18)
18
- activeresource (2.3.18)
19
- activesupport (= 2.3.18)
20
- activesupport (2.3.18)
21
- erubis (2.7.0)
22
- haml (3.1.5)
23
- hoe (2.8.0)
24
- rake (>= 0.8.7)
25
- rack (1.1.6)
26
- rails (2.3.18)
27
- actionmailer (= 2.3.18)
28
- actionpack (= 2.3.18)
29
- activerecord (= 2.3.18)
30
- activeresource (= 2.3.18)
31
- activesupport (= 2.3.18)
32
- rake (>= 0.8.3)
33
- rails_xss (0.5.1)
34
- erubis (>= 2.6.5)
35
- rake (10.1.1)
36
- rspec (1.3.2)
37
- rspec-rails (1.3.4)
38
- rack (>= 1.0.0)
39
- rspec (~> 1.3.1)
40
- rspec_candy (0.3.1)
41
- rspec
42
- sneaky-save
43
- sneaky-save (0.0.2)
44
- activerecord (>= 2.3.2)
45
- sqlite3 (1.3.8)
46
- test-unit (1.2.3)
47
- hoe (>= 1.5.1)
48
-
49
- PLATFORMS
50
- ruby
51
-
52
- DEPENDENCIES
53
- angular_xss!
54
- haml (= 3.1.5)
55
- hoe (= 2.8.0)
56
- rails (~> 2.3.10)
57
- rails_xss
58
- rspec (< 2)
59
- rspec-rails (< 2)
60
- rspec_candy
61
- sqlite3
62
- test-unit (= 1.2.3)
@@ -1,11 +0,0 @@
1
- require 'rake'
2
- require 'spec/rake/spectask'
3
-
4
- desc 'Default: Run all specs for a specific rails version.'
5
- task :default => :spec
6
-
7
- desc "Run all specs for a specific rails version"
8
- Spec::Rake::SpecTask.new() do |t|
9
- t.spec_opts = ['--options', "\"spec.opts\""]
10
- t.spec_files = defined?(SPEC) ? SPEC : FileList['**/*_spec.rb', '../shared/**/*_spec.rb']
11
- end
@@ -1,129 +0,0 @@
1
- # Allow customization of the rails framework path
2
- RAILS_FRAMEWORK_ROOT = (ENV['RAILS_FRAMEWORK_ROOT'] || "#{File.dirname(__FILE__)}/../../../../../../vendor/rails") unless defined?(RAILS_FRAMEWORK_ROOT)
3
-
4
- # Don't change this file!
5
- # Configure your app in config/environment.rb and config/environments/*.rb
6
-
7
- RAILS_ROOT = "#{File.dirname(__FILE__)}/.." unless defined?(RAILS_ROOT)
8
-
9
- module Rails
10
- class << self
11
- def boot!
12
- unless booted?
13
- preinitialize
14
- pick_boot.run
15
- end
16
- end
17
-
18
- def booted?
19
- defined? Rails::Initializer
20
- end
21
-
22
- def pick_boot
23
- (vendor_rails? ? VendorBoot : GemBoot).new
24
- end
25
-
26
- def vendor_rails?
27
- File.exist?(RAILS_FRAMEWORK_ROOT)
28
- end
29
-
30
- def preinitialize
31
- load(preinitializer_path) if File.exist?(preinitializer_path)
32
- end
33
-
34
- def preinitializer_path
35
- "#{RAILS_ROOT}/config/preinitializer.rb"
36
- end
37
- end
38
-
39
- class Boot
40
- def run
41
- load_initializer
42
- Rails::Initializer.run(:set_load_path)
43
- end
44
- end
45
-
46
- class VendorBoot < Boot
47
- def load_initializer
48
- require "#{RAILS_FRAMEWORK_ROOT}/railties/lib/initializer"
49
- Rails::Initializer.run(:install_gem_spec_stubs)
50
- end
51
- end
52
-
53
- class GemBoot < Boot
54
- def load_initializer
55
- self.class.load_rubygems
56
- load_rails_gem
57
- require 'initializer'
58
- end
59
-
60
- def load_rails_gem
61
- if version = self.class.gem_version
62
- gem 'rails', version
63
- else
64
- gem 'rails'
65
- end
66
- rescue Gem::LoadError => load_error
67
- $stderr.puts %(Missing the Rails #{version} gem. Please `gem install -v=#{version} rails`, update your RAILS_GEM_VERSION setting in config/environment.rb for the Rails version you do have installed, or comment out RAILS_GEM_VERSION to use the latest version installed.)
68
- exit 1
69
- end
70
-
71
- class << self
72
- def rubygems_version
73
- Gem::RubyGemsVersion rescue nil
74
- end
75
-
76
- def gem_version
77
- if defined? RAILS_GEM_VERSION
78
- RAILS_GEM_VERSION
79
- elsif ENV.include?('RAILS_GEM_VERSION')
80
- ENV['RAILS_GEM_VERSION']
81
- else
82
- parse_gem_version(read_environment_rb)
83
- end
84
- end
85
-
86
- def load_rubygems
87
- require 'rubygems'
88
- min_version = '1.1.1'
89
- unless rubygems_version >= min_version
90
- $stderr.puts %Q(Rails requires RubyGems >= #{min_version} (you have #{rubygems_version}). Please `gem update --system` and try again.)
91
- exit 1
92
- end
93
-
94
- rescue LoadError
95
- $stderr.puts %Q(Rails requires RubyGems >= #{min_version}. Please install RubyGems and try again: http://rubygems.rubyforge.org)
96
- exit 1
97
- end
98
-
99
- def parse_gem_version(text)
100
- $1 if text =~ /^[^#]*RAILS_GEM_VERSION\s*=\s*["']([!~<>=]*\s*[\d.]+)["']/
101
- end
102
-
103
- private
104
- def read_environment_rb
105
- environment_rb = "#{RAILS_ROOT}/config/environment.rb"
106
- environment_rb = "#{HELPER_RAILS_ROOT}/config/environment.rb" unless File.exists?(environment_rb)
107
- File.read(environment_rb)
108
- end
109
- end
110
- end
111
- end
112
-
113
-
114
- class Rails::Boot
115
- def run
116
- load_initializer
117
-
118
- Rails::Initializer.class_eval do
119
- def load_gems
120
- @bundler_loaded ||= Bundler.require :default, Rails.env
121
- end
122
- end
123
-
124
- Rails::Initializer.run(:set_load_path)
125
- end
126
- end
127
-
128
- # All that for this:
129
- Rails.boot!
@@ -1,4 +0,0 @@
1
- test:
2
- adapter: sqlite3
3
- database: ":memory:"
4
- verbosity: quiet
@@ -1,14 +0,0 @@
1
- require File.join(File.dirname(__FILE__), 'boot')
2
-
3
- Rails::Initializer.run do |config|
4
- config.cache_classes = false
5
- config.whiny_nils = true
6
- config.action_controller.session = { :key => "_myapp_session", :secret => "gwirofjweroijger8924rt2zfwehfuiwehb1378rifowenfoqwphf23" }
7
- #config.plugin_locators.unshift(
8
- # Class.new(Rails::Plugin::Locator) do
9
- # def plugins
10
- # [Rails::Plugin.new(File.expand_path('.'))]
11
- # end
12
- # end
13
- #) unless defined?(PluginTestHelper::PluginLocator)
14
- end
@@ -1,28 +0,0 @@
1
- # Settings specified here will take precedence over those in config/environment.rb
2
-
3
- # The test environment is used exclusively to run your application's
4
- # test suite. You never need to work with it otherwise. Remember that
5
- # your test database is "scratch space" for the test suite and is wiped
6
- # and recreated between test runs. Don't rely on the data there!
7
- config.cache_classes = true
8
-
9
- # Log error messages when you accidentally call methods on nil.
10
- config.whiny_nils = true
11
-
12
- # Show full error reports and disable caching
13
- config.action_controller.consider_all_requests_local = true
14
- config.action_controller.perform_caching = false
15
- config.action_view.cache_template_loading = true
16
-
17
- # Disable request forgery protection in test environment
18
- config.action_controller.allow_forgery_protection = false
19
-
20
- # Tell Action Mailer not to deliver emails to the real world.
21
- # The :test delivery method accumulates sent emails in the
22
- # ActionMailer::Base.deliveries array.
23
- config.action_mailer.delivery_method = :test
24
-
25
- # Use SQL instead of Active Record's schema dumper when creating the test database.
26
- # This is necessary if your schema can't be completely dumped by the schema dumper,
27
- # like if you have constraints or database-specific column types
28
- # config.active_record.schema_format = :sql
@@ -1,20 +0,0 @@
1
- begin
2
- require "rubygems"
3
- require "bundler"
4
- rescue LoadError
5
- raise "Could not load the bundler gem. Install it with `gem install bundler`."
6
- end
7
-
8
- if Gem::Version.new(Bundler::VERSION) <= Gem::Version.new("0.9.24")
9
- raise RuntimeError, "Your bundler version is too old for Rails 2.3." +
10
- "Run `gem install bundler` to upgrade."
11
- end
12
-
13
- begin
14
- # Set up load paths for all bundled gems
15
- ENV["BUNDLE_GEMFILE"] = File.expand_path("../../Gemfile", __FILE__)
16
- Bundler.setup
17
- rescue Bundler::GemNotFound
18
- raise RuntimeError, "Bundler couldn't find some gems." +
19
- "Did you run `bundle install`?"
20
- end
@@ -1,4 +0,0 @@
1
- ActionController::Routing::Routes.draw do |map|
2
- map.connect ':controller/:action/:id'
3
- map.connect ':controller/:action/:id.:format'
4
- end
@@ -1,4 +0,0 @@
1
- # Loads fixtures into the database when running the test app via the console
2
- (ENV['FIXTURES'] ? ENV['FIXTURES'].split(/,/) : Dir.glob(File.join(Rails.root, '../fixtures/*.{yml,csv}'))).each do |fixture_file|
3
- Fixtures.create_fixtures(File.join(Rails.root, '../fixtures'), File.basename(fixture_file, '.*'))
4
- end
@@ -1 +0,0 @@
1
- *.log
@@ -1,7 +0,0 @@
1
- irb = RUBY_PLATFORM =~ /(:?mswin|mingw)/ ? 'irb.bat' : 'irb'
2
- libs = " -r irb/completion"
3
- libs << " -r test/test_helper"
4
- libs << " -r console_app"
5
- libs << " -r console_with_helpers"
6
- libs << " -r console_with_fixtures"
7
- exec "#{irb} #{libs} --simple-prompt"
@@ -1,2 +0,0 @@
1
- --exclude "spec/*,gems/*"
2
- --rails
@@ -1,20 +0,0 @@
1
- $: << File.join(File.dirname(__FILE__), "/../../lib" )
2
-
3
- ENV['RAILS_ENV'] = 'test'
4
- ENV['RAILS_ROOT'] = 'app_root'
5
-
6
- # Load the Rails environment and testing framework
7
- require "#{File.dirname(__FILE__)}/../app_root/config/environment"
8
- require 'spec/rails'
9
- Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
10
- require 'rspec_candy/all'
11
-
12
- # Run the migrations
13
- print "\033[30m" # dark gray text
14
- ActiveRecord::Migrator.migrate("#{Rails.root}/db/migrate")
15
- print "\033[0m"
16
-
17
- Spec::Runner.configure do |config|
18
- config.use_transactional_fixtures = true
19
- config.use_instantiated_fixtures = false
20
- end