honkster-js-test-server 0.2.9 → 0.2.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/MIT.LICENSE ADDED
@@ -0,0 +1,20 @@
1
+ Copyright (c) 2010 Pivotal Labs
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -7,3 +7,5 @@ JsTestServer provides a command line runner and html suite file generation for y
7
7
 
8
8
  == Thanks To
9
9
  * Aman Gupta for advice and patch to the Remote Control
10
+
11
+ Copyright (c) 2010 Pivotal Labs. This software is licensed under the MIT License.
data/Rakefile CHANGED
@@ -28,11 +28,12 @@ def run_suite
28
28
  end
29
29
 
30
30
  PKG_NAME = "honkster-js-test-server"
31
- PKG_VERSION = "0.2.9"
31
+ PKG_VERSION = "0.2.10"
32
32
  PKG_FILES = FileList[
33
33
  '[A-Z]*',
34
34
  '*.rb',
35
35
  'lib/**/**',
36
+ 'public/**/**',
36
37
  'bin/**/**',
37
38
  'public/**/**',
38
39
  'spec/**/*.rb',
@@ -12,8 +12,8 @@ module JsTestServer
12
12
  end
13
13
  end
14
14
 
15
- attr_reader :host, :port, :spec_path, :root_path, :framework_path, :framework_name
16
- attr_writer :host, :port, :framework_path, :framework_name
15
+ attr_reader :host, :port, :spec_path, :root_path, :framework_path, :framework_name, :javascript_test_file_glob
16
+ attr_writer :host, :port, :framework_path, :framework_name, :javascript_test_file_glob
17
17
 
18
18
  def initialize(params={})
19
19
  params = Server::DEFAULTS.dup.merge(params)
@@ -23,6 +23,7 @@ module JsTestServer
23
23
  @port = params[:port]
24
24
  @framework_path = params[:framework_path]
25
25
  @framework_name = params[:framework_name]
26
+ @javascript_test_file_glob = params[:javascript_test_file_glob]
26
27
  end
27
28
 
28
29
  def suite_view_class
@@ -4,6 +4,7 @@ module JsTestServer::Server
4
4
  :port => 8080,
5
5
  :spec_path => File.expand_path("./spec/javascripts"),
6
6
  :root_path => File.expand_path("./public"),
7
+ :javascript_test_file_glob => "**/*_spec.js"
7
8
  }
8
9
  end
9
10
 
@@ -14,7 +14,7 @@ class JsTestServer::Server::Resources::SpecFile < JsTestServer::Server::Resource
14
14
  def do_get
15
15
  if ::File.exists?(absolute_path)
16
16
  if ::File.directory?(absolute_path)
17
- spec_files = ::Dir["#{absolute_path}/**/*.js"].map do |file|
17
+ spec_files = ::Dir["#{absolute_path}/#{JsTestServer.javascript_test_file_glob}"].map do |file|
18
18
  ["#{relative_path}#{file.gsub(absolute_path, "")}"]
19
19
  end
20
20
  get_generated_spec(absolute_path, spec_files)
@@ -44,6 +44,12 @@ class JsTestServer::Server::Runner
44
44
  :type => String,
45
45
  :default => ""
46
46
  )
47
+ opt(
48
+ :javascript_test_file_glob,
49
+ "The glob to find the javascript files",
50
+ :type => String,
51
+ :default => DEFAULTS[:javascript_test_file_glob]
52
+ )
47
53
  end
48
54
 
49
55
  JsTestServer.port = opts[:port]
@@ -51,6 +57,7 @@ class JsTestServer::Server::Runner
51
57
  JsTestServer.framework_path = opts[:framework_path]
52
58
  JsTestServer.spec_path = opts[:spec_path]
53
59
  JsTestServer.root_path = opts[:root_path]
60
+ JsTestServer.javascript_test_file_glob = opts[:javascript_test_file_glob]
54
61
  suite_view_class = JsTestServer::Configuration.instance.suite_view_class
55
62
  suite_view_class.project_js_files.push(*opts[:javascript_files].split(","))
56
63
  suite_view_class.project_css_files.push(*opts[:css_files].split(","))
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: honkster-js-test-server
3
3
  version: !ruby/object:Gem::Version
4
- hash: 5
4
+ hash: 3
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 2
9
- - 9
10
- version: 0.2.9
9
+ - 10
10
+ version: 0.2.10
11
11
  platform: ruby
12
12
  authors:
13
13
  - Brian Takita
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-11-29 00:00:00 -08:00
18
+ date: 2010-11-30 00:00:00 -08:00
19
19
  default_executable:
20
20
  dependencies: []
21
21
 
@@ -31,8 +31,9 @@ extensions: []
31
31
  extra_rdoc_files: []
32
32
 
33
33
  files:
34
- - README.markdown
34
+ - README.rdoc
35
35
  - Gemfile.lock
36
+ - MIT.LICENSE
36
37
  - Gemfile
37
38
  - CHANGES
38
39
  - Rakefile
@@ -64,14 +65,14 @@ files:
64
65
  - lib/js_test_server/server/views/dir.html.rb
65
66
  - lib/js_test_server/server/views/suite.html.rb
66
67
  - lib/js_test_server/server/app.rb
67
- - bin/js-test-client
68
- - bin/jasmine-server
69
- - bin/js-test-server
70
- - bin/screw-unit-server
71
68
  - public/js_test_server/screw_unit_driver.js
72
69
  - public/js_test_server/jasmine_driver.js
73
70
  - public/js_test_server/remote_control.js
74
71
  - public/js_test_server.js
72
+ - bin/js-test-client
73
+ - bin/jasmine-server
74
+ - bin/js-test-server
75
+ - bin/screw-unit-server
75
76
  - spec/unit_suite.rb
76
77
  - spec/spec_suite.rb
77
78
  - spec/functional/jasmine/jasmine_functional_spec.rb