sbsm 1.5.4 → 1.5.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/History.txt +5 -1
- data/lib/sbsm/app.rb +2 -3
- data/lib/sbsm/version.rb +1 -1
- data/test/test_application.rb +6 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2eda12c46b1116c92dfe97027a53565f71715cd3
|
4
|
+
data.tar.gz: 709c375fec68690bbabffebe91886f34f1b61503
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5086f2d5dc29a833ecc655695deac70c6373aa0363a5fc82ae9b7e9fe1dbaa9a121f700d36d5bb152a217cf6a949c6844114fb18cb7fe2fe0a3afc2f4221cf6d
|
7
|
+
data.tar.gz: 3be17e83ef6c00f6a1b192000848fdeae6d95ce294aa13ab28df53ba223208fcf073484b696ea5dca320d8697408b3ac14b1868db8bd0ea916206b8919c69771
|
data/History.txt
CHANGED
data/lib/sbsm/app.rb
CHANGED
@@ -138,7 +138,7 @@ module SBSM
|
|
138
138
|
return [404, {}, []]
|
139
139
|
end
|
140
140
|
else
|
141
|
-
response.write res
|
141
|
+
response.write res unless request.request_method.eql?('HEAD')
|
142
142
|
response.headers['Content-Type'] ||= 'text/html; charset=utf-8'
|
143
143
|
response.headers.merge!(session.http_headers)
|
144
144
|
end
|
@@ -152,8 +152,7 @@ module SBSM
|
|
152
152
|
:path => "/",
|
153
153
|
:expires => (Time.now + (60 * 60 * 24 * 365 * 10))})
|
154
154
|
response.set_cookie(SESSION_ID, { :value => session_id, :path => '/' , :expires => (Time.now + (60 * 60 * 24 * 365 * 10)) })
|
155
|
-
|
156
|
-
session.rack_request = nil
|
155
|
+
# bad idea to reset rack_request if we need more page
|
157
156
|
@@last_session = session
|
158
157
|
if response.headers['Set-Cookie'].to_s.index(session_id)
|
159
158
|
SBSM.debug "finish session_id.1 #{session_id}: matches response.headers['Set-Cookie'] #{response.headers['Set-Cookie']}"
|
data/lib/sbsm/version.rb
CHANGED
data/test/test_application.rb
CHANGED
@@ -49,6 +49,12 @@ class AppVariantTest < Minitest::Test
|
|
49
49
|
assert_match ABOUT_HTML_CONTENT, last_response.body
|
50
50
|
assert_equal(first_session_id, second_session_id)
|
51
51
|
end
|
52
|
+
def test_request_head
|
53
|
+
head '/fr/page/about'
|
54
|
+
assert last_response.ok?
|
55
|
+
assert last_response.body.empty?
|
56
|
+
assert last_response.headers.keys.index('Content-Type')
|
57
|
+
end
|
52
58
|
end
|
53
59
|
|
54
60
|
class AppTestSimple < Minitest::Test
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sbsm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Masaomi Hatakeyama, Zeno R.R. Davatz
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-07-
|
11
|
+
date: 2017-07-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rack
|