js-test-server 0.2.1 → 0.2.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (36) hide show
  1. data/CHANGES +3 -2
  2. data/Rakefile +12 -5
  3. data/lib/js_test_server/configuration.rb +2 -2
  4. data/lib/js_test_server/server.rb +1 -1
  5. data/lib/js_test_server/server/resources/file.rb +1 -1
  6. data/lib/js_test_server/server/resources/not_found.rb +1 -1
  7. data/lib/js_test_server/server/resources/remote_control.rb +1 -1
  8. data/lib/js_test_server/server/resources/spec_file.rb +1 -1
  9. data/lib/js_test_server/server/runner.rb +15 -0
  10. data/lib/js_test_server/server/standalone.ru +1 -0
  11. data/lib/js_test_server/server/views.rb +12 -0
  12. data/lib/js_test_server/server/{representations → views}/dir.html.rb +1 -1
  13. data/lib/js_test_server/server/{representations → views}/frameworks.rb +0 -0
  14. data/lib/js_test_server/server/{representations → views}/not_found.html.rb +1 -1
  15. data/lib/js_test_server/server/{representations → views}/page.html.rb +1 -1
  16. data/lib/js_test_server/server/{representations → views}/remote_control_subscriber.rb +2 -2
  17. data/lib/js_test_server/server/{representations → views}/suite.html.rb +1 -1
  18. data/lib/js_test_server/server/{representations → views}/suites.rb +1 -1
  19. data/lib/js_test_server/server/{representations → views}/suites/jasmine.html.rb +2 -2
  20. data/lib/js_test_server/server/{representations → views}/suites/screw_unit.html.rb +6 -7
  21. data/public/js_test_server.js +568 -0
  22. data/public/js_test_server/jasmine_driver.js +62 -0
  23. data/public/js_test_server/remote_control.js +28 -0
  24. data/public/js_test_server/screw_unit_driver.js +31 -0
  25. data/spec/unit/js_test_core/resources/spec_file_spec.rb +4 -4
  26. data/spec/unit/js_test_core/server/server_spec.rb +38 -2
  27. data/vendor/lucky-luciano/lib/lucky_luciano.rb +5 -0
  28. data/vendor/lucky-luciano/lib/lucky_luciano/resource.rb +142 -0
  29. data/vendor/lucky-luciano/lib/lucky_luciano/resource/path.rb +24 -0
  30. data/vendor/lucky-luciano/lib/lucky_luciano/rspec.rb +4 -0
  31. data/vendor/lucky-luciano/lib/lucky_luciano/rspec/be_http.rb +32 -0
  32. data/vendor/lucky-luciano/spec/lucky_luciano/resource_spec.rb +276 -0
  33. data/vendor/lucky-luciano/spec/spec_helper.rb +48 -0
  34. data/vendor/lucky-luciano/spec/spec_suite.rb +4 -0
  35. metadata +60 -28
  36. data/lib/js_test_server/server/representations.rb +0 -12
@@ -0,0 +1,48 @@
1
+ require "rubygems"
2
+ require "spec"
3
+ require "spec/autorun"
4
+ require 'rack/test'
5
+ require "rr"
6
+ require "sinatra"
7
+
8
+ ARGV.push("-b")
9
+
10
+ dir = File.dirname(__FILE__)
11
+ $:.unshift File.expand_path("#{dir}/../lib")
12
+ require "lucky_luciano"
13
+ require "lucky_luciano/rspec"
14
+
15
+ set :environment, :test
16
+
17
+ class Spec::ExampleGroup
18
+ include BeHttp
19
+ class << self
20
+ def macro(name, &block)
21
+ eigen do
22
+ define_method(name, &block)
23
+ end
24
+ end
25
+
26
+ def eigen(&block)
27
+ eigen_class = (class << self; self; end)
28
+ eigen_class.class_eval(&block)
29
+ eigen_class
30
+ end
31
+ end
32
+
33
+ include Rack::Test::Methods
34
+
35
+ before do
36
+ app.routes.clear
37
+ Sinatra::Default.routes.clear
38
+ app.reset!
39
+ end
40
+
41
+ def app
42
+ Sinatra::Application
43
+ end
44
+ end
45
+
46
+ Spec::SeleniumSession.configure do |config|
47
+ config.mock_with :rr
48
+ end
@@ -0,0 +1,4 @@
1
+ dir = File.dirname(__FILE__)
2
+ Dir["#{dir}/**/*_spec.rb"].each do |file|
3
+ require file
4
+ end
metadata CHANGED
@@ -1,12 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: js-test-server
3
3
  version: !ruby/object:Gem::Version
4
+ hash: 27
4
5
  prerelease: false
5
6
  segments:
6
7
  - 0
7
8
  - 2
8
- - 1
9
- version: 0.2.1
9
+ - 6
10
+ version: 0.2.6
10
11
  platform: ruby
11
12
  authors:
12
13
  - Brian Takita
@@ -14,106 +15,120 @@ autorequire:
14
15
  bindir: bin
15
16
  cert_chain: []
16
17
 
17
- date: 2010-05-13 00:00:00 -07:00
18
+ date: 2010-05-31 00:00:00 -07:00
18
19
  default_executable:
19
20
  dependencies:
20
21
  - !ruby/object:Gem::Dependency
21
22
  version_requirements: &id001 !ruby/object:Gem::Requirement
23
+ none: false
22
24
  requirements:
23
25
  - - "="
24
26
  - !ruby/object:Gem::Version
27
+ hash: 15
25
28
  segments:
26
29
  - 1
27
30
  - 0
28
31
  version: "1.0"
29
- prerelease: false
30
32
  requirement: *id001
31
- name: sinatra
33
+ prerelease: false
32
34
  type: :runtime
35
+ name: sinatra
33
36
  - !ruby/object:Gem::Dependency
34
37
  version_requirements: &id002 !ruby/object:Gem::Requirement
38
+ none: false
35
39
  requirements:
36
40
  - - "="
37
41
  - !ruby/object:Gem::Version
42
+ hash: 17
38
43
  segments:
39
44
  - 1
40
45
  - 2
41
46
  - 7
42
47
  version: 1.2.7
43
- prerelease: false
44
48
  requirement: *id002
45
- name: thin
49
+ prerelease: false
46
50
  type: :runtime
51
+ name: thin
47
52
  - !ruby/object:Gem::Dependency
48
53
  version_requirements: &id003 !ruby/object:Gem::Requirement
54
+ none: false
49
55
  requirements:
50
56
  - - "="
51
57
  - !ruby/object:Gem::Version
58
+ hash: 7
52
59
  segments:
53
60
  - 0
54
61
  - 7
55
62
  - 2
56
63
  version: 0.7.2
57
- prerelease: false
58
64
  requirement: *id003
59
- name: erector
65
+ prerelease: false
60
66
  type: :runtime
67
+ name: erector
61
68
  - !ruby/object:Gem::Dependency
62
69
  version_requirements: &id004 !ruby/object:Gem::Requirement
70
+ none: false
63
71
  requirements:
64
72
  - - "="
65
73
  - !ruby/object:Gem::Version
74
+ hash: 59
66
75
  segments:
67
76
  - 1
68
77
  - 2
69
78
  - 18
70
79
  version: 1.2.18
71
- prerelease: false
72
80
  requirement: *id004
73
- name: selenium-client
81
+ prerelease: false
74
82
  type: :runtime
83
+ name: selenium-client
75
84
  - !ruby/object:Gem::Dependency
76
85
  version_requirements: &id005 !ruby/object:Gem::Requirement
86
+ none: false
77
87
  requirements:
78
88
  - - "="
79
89
  - !ruby/object:Gem::Version
90
+ hash: 83
80
91
  segments:
81
92
  - 1
82
93
  - 16
83
94
  - 2
84
95
  version: 1.16.2
85
- prerelease: false
86
96
  requirement: *id005
87
- name: trollop
97
+ prerelease: false
88
98
  type: :runtime
99
+ name: trollop
89
100
  - !ruby/object:Gem::Dependency
90
101
  version_requirements: &id006 !ruby/object:Gem::Requirement
102
+ none: false
91
103
  requirements:
92
104
  - - "="
93
105
  - !ruby/object:Gem::Version
106
+ hash: 25
94
107
  segments:
95
108
  - 0
96
109
  - 1
97
110
  - 1
98
111
  version: 0.1.1
99
- prerelease: false
100
112
  requirement: *id006
101
- name: guid
113
+ prerelease: false
102
114
  type: :runtime
115
+ name: guid
103
116
  - !ruby/object:Gem::Dependency
104
117
  version_requirements: &id007 !ruby/object:Gem::Requirement
118
+ none: false
105
119
  requirements:
106
120
  - - "="
107
121
  - !ruby/object:Gem::Version
122
+ hash: 7
108
123
  segments:
109
124
  - 1
110
125
  - 4
111
126
  - 0
112
127
  version: 1.4.0
113
- prerelease: false
114
128
  requirement: *id007
115
- name: json
129
+ prerelease: false
116
130
  type: :runtime
131
+ name: json
117
132
  description: The JsTestServer library is the core javascript test server library used by several JS Test server libraries.
118
133
  email: brian.takita@gmail.com
119
134
  executables:
@@ -144,19 +159,24 @@ files:
144
159
  - lib/js_test_server/server/resources/spec_file.rb
145
160
  - lib/js_test_server/server/resources/remote_control.rb
146
161
  - lib/js_test_server/server/resources/web_root.rb
147
- - lib/js_test_server/server/representations/suite.html.rb
148
- - lib/js_test_server/server/representations/page.html.rb
149
- - lib/js_test_server/server/representations/frameworks.rb
150
- - lib/js_test_server/server/representations/suites/jasmine.html.rb
151
- - lib/js_test_server/server/representations/suites/screw_unit.html.rb
152
- - lib/js_test_server/server/representations/remote_control_subscriber.rb
153
- - lib/js_test_server/server/representations/dir.html.rb
154
- - lib/js_test_server/server/representations/not_found.html.rb
155
- - lib/js_test_server/server/representations/suites.rb
162
+ - lib/js_test_server/server/views.rb
163
+ - lib/js_test_server/server/standalone.ru
156
164
  - lib/js_test_server/server/app.rb
157
- - lib/js_test_server/server/representations.rb
165
+ - lib/js_test_server/server/views/suite.html.rb
166
+ - lib/js_test_server/server/views/page.html.rb
167
+ - lib/js_test_server/server/views/frameworks.rb
168
+ - lib/js_test_server/server/views/suites/jasmine.html.rb
169
+ - lib/js_test_server/server/views/suites/screw_unit.html.rb
170
+ - lib/js_test_server/server/views/remote_control_subscriber.rb
171
+ - lib/js_test_server/server/views/dir.html.rb
172
+ - lib/js_test_server/server/views/not_found.html.rb
173
+ - lib/js_test_server/server/views/suites.rb
158
174
  - lib/js_test_server/server/runner.rb
159
175
  - lib/js_test_server.rb
176
+ - public/js_test_server.js
177
+ - public/js_test_server/screw_unit_driver.js
178
+ - public/js_test_server/remote_control.js
179
+ - public/js_test_server/jasmine_driver.js
160
180
  - bin/jasmine-server
161
181
  - bin/screw-unit-server
162
182
  - bin/js-test-client
@@ -189,6 +209,14 @@ files:
189
209
  - spec/spec_helpers/show_test_exceptions.rb
190
210
  - spec/spec_helpers/fake_deferrable.rb
191
211
  - spec/spec_suite.rb
212
+ - vendor/lucky-luciano/spec/lucky_luciano/resource_spec.rb
213
+ - vendor/lucky-luciano/spec/spec_helper.rb
214
+ - vendor/lucky-luciano/spec/spec_suite.rb
215
+ - vendor/lucky-luciano/lib/lucky_luciano.rb
216
+ - vendor/lucky-luciano/lib/lucky_luciano/resource/path.rb
217
+ - vendor/lucky-luciano/lib/lucky_luciano/rspec/be_http.rb
218
+ - vendor/lucky-luciano/lib/lucky_luciano/resource.rb
219
+ - vendor/lucky-luciano/lib/lucky_luciano/rspec.rb
192
220
  has_rdoc: true
193
221
  homepage: http://pivotallabs.com
194
222
  licenses: []
@@ -199,23 +227,27 @@ rdoc_options: []
199
227
  require_paths:
200
228
  - lib
201
229
  required_ruby_version: !ruby/object:Gem::Requirement
230
+ none: false
202
231
  requirements:
203
232
  - - ">="
204
233
  - !ruby/object:Gem::Version
234
+ hash: 3
205
235
  segments:
206
236
  - 0
207
237
  version: "0"
208
238
  required_rubygems_version: !ruby/object:Gem::Requirement
239
+ none: false
209
240
  requirements:
210
241
  - - ">="
211
242
  - !ruby/object:Gem::Version
243
+ hash: 3
212
244
  segments:
213
245
  - 0
214
246
  version: "0"
215
247
  requirements: []
216
248
 
217
249
  rubyforge_project: pivotalrb
218
- rubygems_version: 1.3.6
250
+ rubygems_version: 1.3.7
219
251
  signing_key:
220
252
  specification_version: 3
221
253
  summary: The JsTestServer library is the core javascript test server library used by several JS Test server libraries.
@@ -1,12 +0,0 @@
1
- dir = File.dirname(__FILE__)
2
-
3
- module JsTestServer::Server::Representations
4
- end
5
-
6
- require "#{dir}/representations/page.html"
7
- require "#{dir}/representations/not_found.html"
8
- require "#{dir}/representations/suite.html"
9
- require "#{dir}/representations/dir.html"
10
- require "#{dir}/representations/frameworks"
11
- require "#{dir}/representations/suites"
12
- require "#{dir}/representations/remote_control_subscriber"