Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
张重言
rails
提交
b6b13905
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,发现更多精彩内容 >>
提交
b6b13905
编写于
6月 02, 2015
作者:
S
Sean Griffin
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Skip test that fails from outdated sqlite3 on travis
上级
de412eed
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
9 addition
and
10 deletion
+9
-10
.travis.yml
.travis.yml
+0
-3
activerecord/test/cases/relation_test.rb
activerecord/test/cases/relation_test.rb
+9
-7
未找到文件。
.travis.yml
浏览文件 @
b6b13905
...
...
@@ -50,6 +50,3 @@ services:
-
rabbitmq
addons
:
postgresql
:
"
9.3"
apt
:
packages
:
-
sqlite3
activerecord/test/cases/relation_test.rb
浏览文件 @
b6b13905
...
...
@@ -243,7 +243,13 @@ def test_respond_to_for_non_selected_element
end
def
test_select_quotes_when_using_from_clause
ensure_sqlite3_version_doesnt_include_bug
if
sqlite3_version_includes_quoting_bug?
skip
<<-
ERROR
.
squish
You are using an outdated version of SQLite3 which has a bug in
quoted column names. Please update SQLite3 and rebuild the sqlite3
ruby gem
ERROR
end
quoted_join
=
ActiveRecord
::
Base
.
connection
.
quote_table_name
(
"join"
)
selected
=
Post
.
select
(
:join
).
from
(
Post
.
select
(
"id as
#{
quoted_join
}
"
)).
map
(
&
:join
)
assert_equal
Post
.
pluck
(
:id
),
selected
...
...
@@ -286,16 +292,12 @@ def test_update_all_goes_through_normal_type_casting
private
def
ensure_sqlite3_version_doesnt_include_bug
def
sqlite3_version_includes_quoting_bug?
if
current_adapter?
(
:SQLite3Adapter
)
selected_quoted_column_names
=
ActiveRecord
::
Base
.
connection
.
exec_query
(
'SELECT "join" FROM (SELECT id AS "join" FROM posts) subquery'
).
columns
assert_equal
[
"join"
],
selected_quoted_column_names
,
<<-
ERROR
.
squish
You are using an outdated version of SQLite3 which has a bug in
quoted column names. Please update SQLite3 and rebuild the sqlite3
ruby gem
ERROR
[
"join"
]
!=
selected_quoted_column_names
end
end
end
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录