Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
张重言
rails
提交
425a02ce
R
rails
项目概览
张重言
/
rails
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
rails
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
425a02ce
编写于
11月 04, 2009
作者:
J
Jeremy Kemper
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Ruby 1.9: resolve constant lookup issues
上级
0ff8f81a
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
19 addition
and
19 deletion
+19
-19
actionpack/test/controller/helper_test.rb
actionpack/test/controller/helper_test.rb
+6
-6
actionpack/test/controller/render_test.rb
actionpack/test/controller/render_test.rb
+1
-1
actionpack/test/controller/rescue_test.rb
actionpack/test/controller/rescue_test.rb
+3
-3
actionpack/test/controller/verification_test.rb
actionpack/test/controller/verification_test.rb
+1
-1
actionpack/test/dispatch/request/json_params_parsing_test.rb
actionpack/test/dispatch/request/json_params_parsing_test.rb
+1
-1
actionpack/test/dispatch/request/query_string_parsing_test.rb
...onpack/test/dispatch/request/query_string_parsing_test.rb
+2
-2
actionpack/test/dispatch/request/url_encoded_params_parsing_test.rb
.../test/dispatch/request/url_encoded_params_parsing_test.rb
+1
-1
actionpack/test/dispatch/request/xml_params_parsing_test.rb
actionpack/test/dispatch/request/xml_params_parsing_test.rb
+2
-2
actionpack/test/dispatch/session/cookie_store_test.rb
actionpack/test/dispatch/session/cookie_store_test.rb
+1
-1
actionpack/test/dispatch/session/mem_cache_store_test.rb
actionpack/test/dispatch/session/mem_cache_store_test.rb
+1
-1
未找到文件。
actionpack/test/controller/helper_test.rb
浏览文件 @
425a02ce
...
...
@@ -3,12 +3,6 @@
ActionController
::
Base
.
helpers_dir
=
File
.
dirname
(
__FILE__
)
+
'/../fixtures/helpers'
class
TestController
<
ActionController
::
Base
attr_accessor
:delegate_attr
def
delegate_method
()
end
def
rescue_action
(
e
)
raise
end
end
module
Fun
class
GamesController
<
ActionController
::
Base
def
render_hello_world
...
...
@@ -38,6 +32,12 @@ def c() end
end
class
HelperTest
<
Test
::
Unit
::
TestCase
class
TestController
<
ActionController
::
Base
attr_accessor
:delegate_attr
def
delegate_method
()
end
def
rescue_action
(
e
)
raise
end
end
def
setup
# Increment symbol counter.
@symbol
=
(
@@counter
||=
'A0'
).
succ!
.
dup
...
...
actionpack/test/controller/render_test.rb
浏览文件 @
425a02ce
...
...
@@ -860,7 +860,7 @@ def test_access_to_action_name_in_view
# :ported:
def
test_access_to_controller_name_in_view
get
:accessing_controller_name_in_template
assert_equal
"test"
,
@response
.
body
# name is explicitly set
to 'test' inside
the controller.
assert_equal
"test"
,
@response
.
body
# name is explicitly set
in
the controller.
end
# :ported:
...
...
actionpack/test/controller/rescue_test.rb
浏览文件 @
425a02ce
...
...
@@ -343,9 +343,9 @@ def show_errors(exception)
def
with_test_routing
with_routing
do
|
set
|
set
.
draw
do
|
map
|
match
'foo'
,
:to
=>
TestController
.
action
(
:foo
)
match
'invalid'
,
:to
=>
TestController
.
action
(
:invalid
)
match
'b00m'
,
:to
=>
TestController
.
action
(
:b00m
)
match
'foo'
,
:to
=>
::
RescueTest
::
TestController
.
action
(
:foo
)
match
'invalid'
,
:to
=>
::
RescueTest
::
TestController
.
action
(
:invalid
)
match
'b00m'
,
:to
=>
::
RescueTest
::
TestController
.
action
(
:b00m
)
end
yield
end
...
...
actionpack/test/controller/verification_test.rb
浏览文件 @
425a02ce
...
...
@@ -126,7 +126,7 @@ def test_no_deprecation_warning_for_named_route
with_routing
do
|
set
|
set
.
draw
do
|
map
|
match
'foo'
,
:to
=>
'test#foo'
,
:as
=>
:foo
match
'verification_test/:action'
,
:to
=>
TestController
match
'verification_test/:action'
,
:to
=>
::
VerificationTest
::
TestController
end
get
:guarded_one_for_named_route_test
,
:two
=>
"not one"
assert_redirected_to
'/foo'
...
...
actionpack/test/dispatch/request/json_params_parsing_test.rb
浏览文件 @
425a02ce
...
...
@@ -57,7 +57,7 @@ def assert_parses(expected, actual, headers = {})
def
with_test_routing
with_routing
do
|
set
|
set
.
draw
do
|
map
|
match
':action'
,
:to
=>
TestController
match
':action'
,
:to
=>
::
JsonParamsParsingTest
::
TestController
end
yield
end
...
...
actionpack/test/dispatch/request/query_string_parsing_test.rb
浏览文件 @
425a02ce
...
...
@@ -109,12 +109,12 @@ def teardown
def
assert_parses
(
expected
,
actual
)
with_routing
do
|
set
|
set
.
draw
do
|
map
|
match
':action'
,
:to
=>
TestController
match
':action'
,
:to
=>
::
QueryStringParsingTest
::
TestController
end
get
"/parse"
,
actual
assert_response
:ok
assert_equal
(
expected
,
TestController
.
last_query_parameters
)
assert_equal
(
expected
,
::
QueryStringParsingTest
::
TestController
.
last_query_parameters
)
end
end
end
actionpack/test/dispatch/request/url_encoded_params_parsing_test.rb
浏览文件 @
425a02ce
...
...
@@ -130,7 +130,7 @@ def teardown
def
with_test_routing
with_routing
do
|
set
|
set
.
draw
do
|
map
|
match
':action'
,
:to
=>
TestController
match
':action'
,
:to
=>
::
UrlEncodedParamsParsingTest
::
TestController
end
yield
end
...
...
actionpack/test/dispatch/request/xml_params_parsing_test.rb
浏览文件 @
425a02ce
...
...
@@ -84,7 +84,7 @@ def teardown
def
with_test_routing
with_routing
do
|
set
|
set
.
draw
do
|
map
|
match
':action'
,
:to
=>
TestController
match
':action'
,
:to
=>
::
XmlParamsParsingTest
::
TestController
end
yield
end
...
...
@@ -100,4 +100,4 @@ class LegacyXmlParamsParsingTest < XmlParamsParsingTest
def
default_headers
{
'HTTP_X_POST_DATA_FORMAT'
=>
'xml'
}
end
end
\ No newline at end of file
end
actionpack/test/dispatch/session/cookie_store_test.rb
浏览文件 @
425a02ce
...
...
@@ -219,7 +219,7 @@ def test_session_store_with_expire_after
def
with_test_route_set
(
options
=
{})
with_routing
do
|
set
|
set
.
draw
do
|
map
|
match
':action'
,
:to
=>
TestController
match
':action'
,
:to
=>
::
CookieStoreTest
::
TestController
end
options
=
{
:key
=>
SessionKey
,
:secret
=>
SessionSecret
}.
merge
(
options
)
@app
=
ActionDispatch
::
Session
::
CookieStore
.
new
(
set
,
options
)
...
...
actionpack/test/dispatch/session/mem_cache_store_test.rb
浏览文件 @
425a02ce
...
...
@@ -112,7 +112,7 @@ def test_prevents_session_fixation
def
with_test_route_set
with_routing
do
|
set
|
set
.
draw
do
|
map
|
match
':action'
,
:to
=>
TestController
match
':action'
,
:to
=>
::
MemCacheStoreTest
::
TestController
end
@app
=
ActionDispatch
::
Session
::
MemCacheStore
.
new
(
set
,
:key
=>
'_session_id'
)
yield
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录