jubilee 1.0.2 → 1.1.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +1 -1
- data/CHANGELOG +17 -0
- data/Gemfile +19 -1
- data/Gemfile.lock +189 -31
- data/LICENSE.txt +20 -0
- data/README.md +44 -5
- data/ROADMAP +5 -0
- data/Rakefile +6 -5
- data/examples/chatapp/Gemfile +2 -1
- data/examples/chatapp/Gemfile.lock +8 -6
- data/examples/chatapp/README.md +5 -2
- data/examples/chatapp/app.rb +24 -0
- data/examples/chatapp/public/assets/javascripts/application.js +59 -6
- data/examples/chatapp/public/assets/stylesheets/application.css +25 -0
- data/examples/jubilee.conf.rb +0 -3
- data/jars/{hazelcast-2.6.jar → hazelcast-2.6.3.jar} +0 -0
- data/jars/{netty-all-4.0.4.Final.jar → netty-all-4.0.13.Final.jar} +0 -0
- data/jars/vertx-core-2.1M3-SNAPSHOT.jar +0 -0
- data/jars/vertx-hazelcast-2.1M3-SNAPSHOT.jar +0 -0
- data/java/src/jubilee/JubileeService.java +7 -7
- data/java/src/org/jruby/jubilee/Const.java +10 -35
- data/java/src/org/jruby/jubilee/RackApplication.java +77 -46
- data/java/src/org/jruby/jubilee/RackResponse.java +1 -3
- data/java/src/org/jruby/jubilee/RubyHttpServerResponse.java +88 -0
- data/java/src/org/jruby/jubilee/{Server.java → RubyServer.java} +17 -14
- data/java/src/org/jruby/jubilee/impl/RackEnvironment.java +157 -0
- data/java/src/org/jruby/jubilee/impl/RackEnvironmentHash.java +449 -0
- data/java/src/org/jruby/jubilee/impl/RubyIORackInput.java +5 -5
- data/java/src/org/jruby/jubilee/impl/{NullIO.java → RubyNullIO.java} +5 -9
- data/java/src/org/jruby/jubilee/utils/RubyHelper.java +37 -0
- data/jubilee.gemspec +101 -14
- data/lib/jubilee.rb +4 -3
- data/lib/jubilee/cli.rb +2 -1
- data/lib/jubilee/configuration.rb +4 -9
- data/lib/jubilee/const.rb +2 -2
- data/lib/jubilee/jubilee.jar +0 -0
- data/lib/jubilee/response.rb +9 -8
- data/lib/jubilee/server.rb +1 -1
- data/lib/jubilee/version.rb +8 -1
- data/lib/rack/chunked.rb +38 -0
- data/spec/apps/rack/basic/config.ru +50 -0
- data/spec/apps/rails4/basic/.gitignore +16 -0
- data/spec/apps/rails4/basic/Gemfile +41 -0
- data/spec/apps/rails4/basic/Gemfile.lock +127 -0
- data/spec/apps/rails4/basic/README.rdoc +28 -0
- data/spec/apps/rails4/basic/Rakefile +6 -0
- data/spec/apps/rails4/basic/app/assets/images/.keep +0 -0
- data/spec/apps/rails4/basic/app/assets/images/rails.png +0 -0
- data/spec/apps/rails4/basic/app/assets/javascripts/application.js +16 -0
- data/spec/apps/rails4/basic/app/assets/stylesheets/application.css +13 -0
- data/spec/apps/rails4/basic/app/controllers/application_controller.rb +5 -0
- data/spec/apps/rails4/basic/app/controllers/concerns/.keep +0 -0
- data/spec/apps/rails4/basic/app/controllers/reloader_controller.rb +11 -0
- data/spec/apps/rails4/basic/app/controllers/reloader_controller.rb.erb +11 -0
- data/spec/apps/rails4/basic/app/controllers/root_controller.rb +14 -0
- data/spec/apps/rails4/basic/app/helpers/application_helper.rb +2 -0
- data/spec/apps/rails4/basic/app/mailers/.keep +0 -0
- data/spec/apps/rails4/basic/app/models/.keep +0 -0
- data/spec/apps/rails4/basic/app/models/concerns/.keep +0 -0
- data/spec/apps/rails4/basic/app/views/layouts/application.html.erb +14 -0
- data/spec/apps/rails4/basic/app/views/reloader/index.html.erb +1 -0
- data/spec/apps/rails4/basic/app/views/root/index.html.erb +8 -0
- data/spec/apps/rails4/basic/app/views/root/streaming.html.erb +6 -0
- data/spec/apps/rails4/basic/bin/bundle +3 -0
- data/spec/apps/rails4/basic/bin/rails +4 -0
- data/spec/apps/rails4/basic/bin/rake +4 -0
- data/spec/apps/rails4/basic/config.ru +4 -0
- data/spec/apps/rails4/basic/config/application.rb +23 -0
- data/spec/apps/rails4/basic/config/boot.rb +4 -0
- data/spec/apps/rails4/basic/config/database.yml +20 -0
- data/spec/apps/rails4/basic/config/environment.rb +5 -0
- data/spec/apps/rails4/basic/config/environments/development.rb +29 -0
- data/spec/apps/rails4/basic/config/environments/production.rb +80 -0
- data/spec/apps/rails4/basic/config/environments/test.rb +36 -0
- data/spec/apps/rails4/basic/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/apps/rails4/basic/config/initializers/filter_parameter_logging.rb +4 -0
- data/spec/apps/rails4/basic/config/initializers/inflections.rb +16 -0
- data/spec/apps/rails4/basic/config/initializers/mime_types.rb +5 -0
- data/spec/apps/rails4/basic/config/initializers/secret_token.rb +12 -0
- data/spec/apps/rails4/basic/config/initializers/session_store.rb +2 -0
- data/spec/apps/rails4/basic/config/initializers/wrap_parameters.rb +14 -0
- data/spec/apps/rails4/basic/config/locales/en.yml +23 -0
- data/spec/apps/rails4/basic/config/routes.rb +5 -0
- data/spec/apps/rails4/basic/db/seeds.rb +7 -0
- data/spec/apps/rails4/basic/lib/assets/.keep +0 -0
- data/spec/apps/rails4/basic/lib/tasks/.keep +0 -0
- data/spec/apps/rails4/basic/public/404.html +58 -0
- data/spec/apps/rails4/basic/public/422.html +58 -0
- data/spec/apps/rails4/basic/public/500.html +57 -0
- data/spec/apps/rails4/basic/public/favicon.ico +0 -0
- data/spec/apps/rails4/basic/public/robots.txt +5 -0
- data/spec/apps/rails4/basic/public/some_page.html +7 -0
- data/spec/apps/rails4/basic/test/controllers/.keep +0 -0
- data/spec/apps/rails4/basic/test/fixtures/.keep +0 -0
- data/spec/apps/rails4/basic/test/helpers/.keep +0 -0
- data/spec/apps/rails4/basic/test/integration/.keep +0 -0
- data/spec/apps/rails4/basic/test/mailers/.keep +0 -0
- data/spec/apps/rails4/basic/test/models/.keep +0 -0
- data/spec/apps/rails4/basic/test/test_helper.rb +15 -0
- data/spec/apps/rails4/basic/vendor/assets/javascripts/.keep +0 -0
- data/spec/apps/rails4/basic/vendor/assets/stylesheets/.keep +0 -0
- data/spec/apps/sinatra/basic/Gemfile +4 -0
- data/spec/apps/sinatra/basic/Gemfile.lock +20 -0
- data/spec/apps/sinatra/basic/basic.rb +27 -0
- data/spec/apps/sinatra/basic/config.ru +7 -0
- data/spec/apps/sinatra/basic/public/some_page.html +7 -0
- data/spec/apps/sinatra/basic/views/index.erb +4 -0
- data/spec/apps/sinatra/basic/views/posted.haml +2 -0
- data/spec/apps/sinatra/basic/views/poster.haml +4 -0
- data/spec/apps/sinatra/basic/views/request_mapping.haml +4 -0
- data/spec/integration/basic_rack_spec.rb +89 -0
- data/spec/integration/basic_rails4_spec.rb +64 -0
- data/spec/integration/basic_sinatra_spec.rb +80 -0
- data/spec/spec_helper.rb +13 -0
- data/test/jubilee/test_cli.rb +1 -1
- data/test/jubilee/test_configuration.rb +18 -1
- data/test/jubilee/test_rack_server.rb +7 -7
- data/test/jubilee/test_response.rb +35 -36
- data/test/jubilee/test_server.rb +1 -1
- data/test/jubilee/test_upload.rb +14 -11
- data/test/test_helper.rb +1 -0
- metadata +97 -18
- data/VERSION +0 -1
- data/jars/vertx-core-2.1.0-SNAPSHOT.jar +0 -0
- data/java/src/org/jruby/jubilee/RackErrors.java +0 -44
- data/java/src/org/jruby/jubilee/impl/DefaultRackEnvironment.java +0 -99
- data/java/src/org/jruby/jubilee/impl/RubyIORackErrors.java +0 -68
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -0,0 +1,15 @@
|
|
1
|
+
ENV["RAILS_ENV"] ||= "test"
|
2
|
+
require File.expand_path('../../config/environment', __FILE__)
|
3
|
+
require 'rails/test_help'
|
4
|
+
|
5
|
+
class ActiveSupport::TestCase
|
6
|
+
ActiveRecord::Migration.check_pending!
|
7
|
+
|
8
|
+
# Setup all fixtures in test/fixtures/*.yml for all tests in alphabetical order.
|
9
|
+
#
|
10
|
+
# Note: You'll currently still have to declare fixtures explicitly in integration tests
|
11
|
+
# -- they do not yet inherit this setting
|
12
|
+
fixtures :all
|
13
|
+
|
14
|
+
# Add more helper methods to be used by all tests here...
|
15
|
+
end
|
File without changes
|
File without changes
|
@@ -0,0 +1,20 @@
|
|
1
|
+
GEM
|
2
|
+
remote: http://rubygems.org/
|
3
|
+
specs:
|
4
|
+
haml (4.0.4)
|
5
|
+
tilt
|
6
|
+
rack (1.5.2)
|
7
|
+
rack-protection (1.5.1)
|
8
|
+
rack
|
9
|
+
sinatra (1.4.4)
|
10
|
+
rack (~> 1.4)
|
11
|
+
rack-protection (~> 1.4)
|
12
|
+
tilt (~> 1.3, >= 1.3.4)
|
13
|
+
tilt (1.4.1)
|
14
|
+
|
15
|
+
PLATFORMS
|
16
|
+
java
|
17
|
+
|
18
|
+
DEPENDENCIES
|
19
|
+
haml
|
20
|
+
sinatra
|
@@ -0,0 +1,27 @@
|
|
1
|
+
|
2
|
+
require 'rubygems'
|
3
|
+
require 'sinatra'
|
4
|
+
|
5
|
+
disable :logging
|
6
|
+
|
7
|
+
options '/' do
|
8
|
+
response.headers['Access-Control-Allow-Origin'] = '*'
|
9
|
+
response.headers['Access-Control-Allow-Methods'] = 'POST'
|
10
|
+
end
|
11
|
+
|
12
|
+
get '/' do
|
13
|
+
headers 'Biscuit' => 'Gravy'
|
14
|
+
erb :index
|
15
|
+
end
|
16
|
+
|
17
|
+
get '/request-mapping' do
|
18
|
+
haml :request_mapping
|
19
|
+
end
|
20
|
+
|
21
|
+
get '/poster' do
|
22
|
+
haml :poster
|
23
|
+
end
|
24
|
+
|
25
|
+
post '/poster' do
|
26
|
+
haml :posted
|
27
|
+
end
|
@@ -0,0 +1,89 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
feature "basic rack at non-root context" do
|
4
|
+
|
5
|
+
before(:all) do
|
6
|
+
configurator = Jubilee::Configuration.new(chdir: "#{apps_dir}/rack/basic")
|
7
|
+
@server = Jubilee::Server.new(configurator.app, configurator.options)
|
8
|
+
@server.start
|
9
|
+
end
|
10
|
+
|
11
|
+
after(:all) do
|
12
|
+
@server.stop
|
13
|
+
end
|
14
|
+
|
15
|
+
it "should work for basic requests" do
|
16
|
+
visit "/basic-rack"
|
17
|
+
page.should have_content('it worked')
|
18
|
+
page.find("#success")[:class].strip.should == 'basic-rack'
|
19
|
+
page.find("#script_name").text.strip.should == ''
|
20
|
+
page.find("#path_info").text.strip.should == '/basic-rack'
|
21
|
+
page.find("#request_uri").text.strip.should == '/basic-rack'
|
22
|
+
end
|
23
|
+
|
24
|
+
it "should work for subcontext root with trailing slash" do
|
25
|
+
visit "/basic-rack/"
|
26
|
+
page.should have_content('it worked')
|
27
|
+
page.find("#success")[:class].strip.should == 'basic-rack'
|
28
|
+
page.find("#script_name").text.strip.should == ''
|
29
|
+
page.find("#path_info").text.strip.should == '/basic-rack/'
|
30
|
+
page.find("#request_uri").text.strip.should == '/basic-rack/'
|
31
|
+
end
|
32
|
+
|
33
|
+
it "should be running under the proper ruby version" do
|
34
|
+
visit "/basic-rack/"
|
35
|
+
page.find("#ruby-version").text.strip.should == RUBY_VERSION
|
36
|
+
end
|
37
|
+
|
38
|
+
it "should not have a vfs path for __FILE__" do
|
39
|
+
visit "/basic-rack/"
|
40
|
+
page.find("#path").text.strip.should_not match(/^vfs:/)
|
41
|
+
end
|
42
|
+
|
43
|
+
it "should not decode characters in URL" do
|
44
|
+
visit "/basic-rack/foo%23%2C"
|
45
|
+
page.find("#path_info").text.strip.should == '/basic-rack/foo%23%2C'
|
46
|
+
page.find("#request_uri").text.strip.should == '/basic-rack/foo%23%2C'
|
47
|
+
end
|
48
|
+
|
49
|
+
it "should contain correct request headers" do
|
50
|
+
uri = URI.parse("#{Capybara.app_host}/basic-rack/")
|
51
|
+
Net::HTTP.start(uri.host, uri.port) do |http|
|
52
|
+
accept = 'text/html;q=0.9,*/*;q=0.7'
|
53
|
+
response = http.get(uri.request_uri, {'Accept' => accept})
|
54
|
+
response.code.should == "200"
|
55
|
+
response.body.should include("<div id='accept_header'>#{accept}</div>")
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
it "should read post bodies via gets" do
|
60
|
+
uri = URI.parse("#{Capybara.app_host}/basic-rack/gets")
|
61
|
+
Net::HTTP.start(uri.host, uri.port) do |http|
|
62
|
+
request = Net::HTTP::Post.new(uri.request_uri)
|
63
|
+
request.form_data = {'field' => 'nothing'}
|
64
|
+
response = http.request(request)
|
65
|
+
response.body.should include("<div id='posted'>field=nothing</div>")
|
66
|
+
end
|
67
|
+
end
|
68
|
+
|
69
|
+
it "should read post bodies via read" do
|
70
|
+
uri = URI.parse("#{Capybara.app_host}/basic-rack/read")
|
71
|
+
Net::HTTP.start(uri.host, uri.port) do |http|
|
72
|
+
request = Net::HTTP::Post.new(uri.request_uri)
|
73
|
+
request.form_data = {'field' => 'nothing'}
|
74
|
+
response = http.request(request)
|
75
|
+
response.body.should include("<div id='posted'>field=nothing</div>")
|
76
|
+
end
|
77
|
+
end
|
78
|
+
|
79
|
+
it "should read post bodies via each" do
|
80
|
+
uri = URI.parse("#{Capybara.app_host}/basic-rack/each")
|
81
|
+
Net::HTTP.start(uri.host, uri.port) do |http|
|
82
|
+
request = Net::HTTP::Post.new(uri.request_uri)
|
83
|
+
request.form_data = {'field' => 'nothing'}
|
84
|
+
response = http.request(request)
|
85
|
+
response.body.should include("<div id='posted'>field=nothing</div>")
|
86
|
+
end
|
87
|
+
end
|
88
|
+
|
89
|
+
end
|
@@ -0,0 +1,64 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
feature 'basic rails4 test' do
|
4
|
+
|
5
|
+
before(:all) do
|
6
|
+
configurator = Jubilee::Configuration.new(chdir: "#{apps_dir}/rails4/basic")
|
7
|
+
@server = Jubilee::Server.new(configurator.app, configurator.options)
|
8
|
+
@server.start
|
9
|
+
sleep 0.1
|
10
|
+
end
|
11
|
+
|
12
|
+
after(:all) do
|
13
|
+
@server.stop
|
14
|
+
end
|
15
|
+
|
16
|
+
it 'should do a basic get' do
|
17
|
+
visit '/'
|
18
|
+
page.should have_content('It works')
|
19
|
+
page.find('#success')[:class].should == 'basic-rails4'
|
20
|
+
end
|
21
|
+
|
22
|
+
context 'streaming' do
|
23
|
+
it "should work for small responses" do
|
24
|
+
verify_streaming("/root/streaming?count=0")
|
25
|
+
end
|
26
|
+
|
27
|
+
it "should work for large responses" do
|
28
|
+
verify_streaming("/root/streaming?count=500")
|
29
|
+
end
|
30
|
+
|
31
|
+
def verify_streaming(url)
|
32
|
+
uri = URI.parse("#{Capybara.app_host}#{url}")
|
33
|
+
Net::HTTP.get_response(uri) do |response|
|
34
|
+
response.should be_chunked
|
35
|
+
response.header['transfer-encoding'].should == 'chunked'
|
36
|
+
chunk_count, body = 0, ""
|
37
|
+
response.read_body do |chunk|
|
38
|
+
chunk_count += 1
|
39
|
+
body += chunk
|
40
|
+
end
|
41
|
+
body.should include('It works')
|
42
|
+
body.each_line do |line|
|
43
|
+
line.should_not match(/^\d+\s*$/)
|
44
|
+
end
|
45
|
+
chunk_count.should be > 1
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
it 'should return a static page beneath default public dir' do
|
51
|
+
visit "/some_page.html"
|
52
|
+
element = page.find('#success')
|
53
|
+
element.should_not be_nil
|
54
|
+
element.text.should == 'static page'
|
55
|
+
end
|
56
|
+
|
57
|
+
it "should support setting multiple cookies" do
|
58
|
+
visit "/root/multiple_cookies"
|
59
|
+
page.driver.cookies['foo1'].value.should == 'bar1'
|
60
|
+
page.driver.cookies['foo2'].value.should == 'bar2'
|
61
|
+
page.driver.cookies['foo3'].value.should == 'bar3'
|
62
|
+
end
|
63
|
+
|
64
|
+
end
|
@@ -0,0 +1,80 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
feature "basic sinatra test" do
|
4
|
+
|
5
|
+
before(:all) do
|
6
|
+
configurator = Jubilee::Configuration.new(chdir: "#{apps_dir}/sinatra/basic")
|
7
|
+
@server = Jubilee::Server.new(configurator.app, configurator.options)
|
8
|
+
@server.start
|
9
|
+
end
|
10
|
+
|
11
|
+
after(:all) do
|
12
|
+
@server.stop
|
13
|
+
end
|
14
|
+
|
15
|
+
it "should work" do
|
16
|
+
visit ""
|
17
|
+
page.should have_content('it worked')
|
18
|
+
page.should have_selector('div.sinatra-basic')
|
19
|
+
find("#success").should have_content('it worked')
|
20
|
+
end
|
21
|
+
|
22
|
+
it "should return a valid request scheme" do
|
23
|
+
visit "/request-mapping"
|
24
|
+
find("#success #scheme").text.should eql("http")
|
25
|
+
end
|
26
|
+
|
27
|
+
it "should return a static page beneath default 'public' dir" do
|
28
|
+
visit "/some_page.html"
|
29
|
+
page.find('#success')[:class].should == 'default'
|
30
|
+
end
|
31
|
+
|
32
|
+
it "should return 304 for unmodified static assets" do
|
33
|
+
uri = URI.parse("#{Capybara.app_host}/some_page.html")
|
34
|
+
Net::HTTP.start(uri.host, uri.port) do |http|
|
35
|
+
request = Net::HTTP::Get.new(uri.request_uri)
|
36
|
+
request.add_field('If-Modified-Since', 'Sat, 31 Dec 2050 00:00:00 GMT')
|
37
|
+
response = http.request(request)
|
38
|
+
response.code.should == "304"
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
it "should post something" do
|
43
|
+
visit "/poster"
|
44
|
+
fill_in 'field', :with => 'something'
|
45
|
+
click_button 'submit'
|
46
|
+
find('#success').should have_content("you posted something")
|
47
|
+
end
|
48
|
+
|
49
|
+
|
50
|
+
it "should allow headers through" do
|
51
|
+
uri = URI.parse("#{Capybara.app_host}/")
|
52
|
+
response = Net::HTTP.get_response(uri)
|
53
|
+
response['Biscuit'].should == 'Gravy'
|
54
|
+
end
|
55
|
+
|
56
|
+
it "should allow OPTIONS requests" do
|
57
|
+
uri = URI.parse("#{Capybara.app_host}/")
|
58
|
+
Net::HTTP.start(uri.host, uri.port) do |http|
|
59
|
+
request = Net::HTTP::Options.new(uri.request_uri)
|
60
|
+
response = http.request(request)
|
61
|
+
response['access-control-allow-origin'].should == '*'
|
62
|
+
response['access-control-allow-methods'].should == 'POST'
|
63
|
+
end
|
64
|
+
|
65
|
+
end
|
66
|
+
|
67
|
+
it "should test Sir Postalot" do
|
68
|
+
uri = URI.parse("#{Capybara.app_host}/poster")
|
69
|
+
Net::HTTP.start(uri.host, uri.port) do |http|
|
70
|
+
100.times do |i|
|
71
|
+
http.request(Net::HTTP::Get.new(uri.request_uri))
|
72
|
+
request = Net::HTTP::Post.new(uri.request_uri)
|
73
|
+
request.form_data = {'field' => 'nothing'}
|
74
|
+
response = http.request(request)
|
75
|
+
response.body.should include("<div id='success'>you posted nothing</div>")
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
|
80
|
+
end
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,13 @@
|
|
1
|
+
require 'jubilee'
|
2
|
+
require 'capybara/poltergeist'
|
3
|
+
require 'capybara/rspec'
|
4
|
+
require 'ostruct'
|
5
|
+
require 'net/http'
|
6
|
+
|
7
|
+
Capybara.app_host = "http://localhost:8080"
|
8
|
+
Capybara.run_server = false
|
9
|
+
Capybara.default_driver = :poltergeist
|
10
|
+
|
11
|
+
def apps_dir
|
12
|
+
File.expand_path("../apps", __FILE__)
|
13
|
+
end
|
data/test/jubilee/test_cli.rb
CHANGED
@@ -4,11 +4,28 @@ require 'jubilee/configuration'
|
|
4
4
|
class TestConfig < MiniTest::Unit::TestCase
|
5
5
|
|
6
6
|
def setup
|
7
|
-
@config = Jubilee::Configuration.new({rackup: "config/app.rb"})
|
8
7
|
end
|
9
8
|
|
10
9
|
def test_load
|
10
|
+
@config = Jubilee::Configuration.new({rackup: "config/app.rb"})
|
11
11
|
resp = [200, {"Content-Type" => "text/plain"}, ["embeded app"]]
|
12
12
|
assert_equal resp, @config.app.call({})
|
13
13
|
end
|
14
|
+
|
15
|
+
def test_config_invalid
|
16
|
+
tmp = Tempfile.new("jubilee_config")
|
17
|
+
tmp.syswrite(%q(abcd "helloword"))
|
18
|
+
assert_raises(NoMethodError) do
|
19
|
+
Jubilee::Configuration.new(config_file: tmp.path)
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
23
|
+
def test_config_non_exist
|
24
|
+
tmp = Tempfile.new("jubilee_config")
|
25
|
+
path = tmp.path
|
26
|
+
tmp.close!
|
27
|
+
assert_raises(Errno::ENOENT) do
|
28
|
+
Jubilee::Configuration.new(config_file: path)
|
29
|
+
end
|
30
|
+
end
|
14
31
|
end
|