Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
李少辉-开发者
gitlab-foss
提交
0f31acd0
G
gitlab-foss
项目概览
李少辉-开发者
/
gitlab-foss
通知
15
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
gitlab-foss
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
0f31acd0
编写于
4月 11, 2014
作者:
D
Dmitriy Zaporozhets
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #6753 from jvanbaarsen/split_tests
Proposal for split testing
上级
1942b97d
490ab228
变更
23
显示空白变更内容
内联
并排
Showing
23 changed file
with
49 addition
and
24 deletion
+49
-24
.travis.yml
.travis.yml
+4
-2
lib/tasks/spec.rake
lib/tasks/spec.rake
+23
-0
spec/features/gitlab_flavored_markdown_spec.rb
spec/features/gitlab_flavored_markdown_spec.rb
+1
-1
spec/models/assembla_service_spec.rb
spec/models/assembla_service_spec.rb
+1
-1
spec/requests/api/api_helpers_spec.rb
spec/requests/api/api_helpers_spec.rb
+2
-2
spec/requests/api/branches_spec.rb
spec/requests/api/branches_spec.rb
+1
-1
spec/requests/api/commits_spec.rb
spec/requests/api/commits_spec.rb
+1
-1
spec/requests/api/files_spec.rb
spec/requests/api/files_spec.rb
+1
-1
spec/requests/api/groups_spec.rb
spec/requests/api/groups_spec.rb
+1
-1
spec/requests/api/internal_spec.rb
spec/requests/api/internal_spec.rb
+1
-1
spec/requests/api/issues_spec.rb
spec/requests/api/issues_spec.rb
+1
-1
spec/requests/api/merge_requests_spec.rb
spec/requests/api/merge_requests_spec.rb
+1
-1
spec/requests/api/milestones_spec.rb
spec/requests/api/milestones_spec.rb
+1
-1
spec/requests/api/namespaces_spec.rb
spec/requests/api/namespaces_spec.rb
+1
-1
spec/requests/api/notes_spec.rb
spec/requests/api/notes_spec.rb
+1
-1
spec/requests/api/project_hooks_spec.rb
spec/requests/api/project_hooks_spec.rb
+1
-1
spec/requests/api/project_members_spec.rb
spec/requests/api/project_members_spec.rb
+1
-1
spec/requests/api/projects_spec.rb
spec/requests/api/projects_spec.rb
+1
-1
spec/requests/api/repositories_spec.rb
spec/requests/api/repositories_spec.rb
+1
-1
spec/requests/api/services_spec.rb
spec/requests/api/services_spec.rb
+1
-1
spec/requests/api/session_spec.rb
spec/requests/api/session_spec.rb
+1
-1
spec/requests/api/system_hooks_spec.rb
spec/requests/api/system_hooks_spec.rb
+1
-1
spec/requests/api/users_spec.rb
spec/requests/api/users_spec.rb
+1
-1
未找到文件。
.travis.yml
浏览文件 @
0f31acd0
...
@@ -4,10 +4,12 @@ env:
...
@@ -4,10 +4,12 @@ env:
-
TRAVIS=true
-
TRAVIS=true
matrix
:
matrix
:
-
TASK=spinach DB=mysql
-
TASK=spinach DB=mysql
-
TASK=spec DB=mysql
-
TASK=spec:api DB=mysql
-
TASK=spec:other DB=mysql
-
TASK=jasmine:ci DB=mysql
-
TASK=jasmine:ci DB=mysql
-
TASK=spinach DB=postgresql
-
TASK=spinach DB=postgresql
-
TASK=spec DB=postgresql
-
TASK=spec:api DB=mysql
-
TASK=spec:other DB=postgresql
-
TASK=jasmine:ci DB=postgresql
-
TASK=jasmine:ci DB=postgresql
before_install
:
before_install
:
-
sudo apt-get install libicu-dev -y
-
sudo apt-get install libicu-dev -y
...
...
lib/tasks/spec.rake
浏览文件 @
0f31acd0
Rake
::
Task
[
"spec"
].
clear
if
Rake
::
Task
.
task_defined?
(
'spec'
)
Rake
::
Task
[
"spec"
].
clear
if
Rake
::
Task
.
task_defined?
(
'spec'
)
namespace
:spec
do
desc
'GITLAB | Run feature specs'
task
:api
do
cmds
=
[
%W(rake gitlab:setup)
,
%W(rspec spec --tag @api)
]
run_commands
(
cmds
)
end
desc
'GITLAB | Run other specs'
task
:other
do
cmds
=
[
%W(rake gitlab:setup)
,
%W(rspec spec --tag ~@api)
]
run_commands
(
cmds
)
end
end
desc
"GITLAB | Run specs"
desc
"GITLAB | Run specs"
task
:spec
do
task
:spec
do
cmds
=
[
cmds
=
[
%W(rake gitlab:setup)
,
%W(rake gitlab:setup)
,
%W(rspec spec)
,
%W(rspec spec)
,
]
]
run_commands
(
cmds
)
end
def
run_commands
(
cmds
)
cmds
.
each
do
|
cmd
|
cmds
.
each
do
|
cmd
|
system
({
'RAILS_ENV'
=>
'test'
,
'force'
=>
'yes'
},
*
cmd
)
system
({
'RAILS_ENV'
=>
'test'
,
'force'
=>
'yes'
},
*
cmd
)
raise
"
#{
cmd
}
failed!"
unless
$?
.
exitstatus
.
zero?
raise
"
#{
cmd
}
failed!"
unless
$?
.
exitstatus
.
zero?
...
...
spec/features/gitlab_flavored_markdown_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
"GitLab Flavored Markdown"
do
describe
"GitLab Flavored Markdown"
,
features:
true
do
let
(
:project
)
{
create
(
:project
)
}
let
(
:project
)
{
create
(
:project
)
}
let
(
:issue
)
{
create
(
:issue
,
project:
project
)
}
let
(
:issue
)
{
create
(
:issue
,
project:
project
)
}
let
(
:merge_request
)
{
create
(
:merge_request
,
source_project:
project
,
target_project:
project
)
}
let
(
:merge_request
)
{
create
(
:merge_request
,
source_project:
project
,
target_project:
project
)
}
...
...
spec/models/assembla_service_spec.rb
浏览文件 @
0f31acd0
...
@@ -19,7 +19,7 @@
...
@@ -19,7 +19,7 @@
require
'spec_helper'
require
'spec_helper'
describe
AssemblaService
do
describe
AssemblaService
,
models:
true
do
describe
"Associations"
do
describe
"Associations"
do
it
{
should
belong_to
:project
}
it
{
should
belong_to
:project
}
it
{
should
have_one
:service_hook
}
it
{
should
have_one
:service_hook
}
...
...
spec/requests/api/api_helpers_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
do
describe
API
,
api:
true
do
include
API
::
APIHelpers
include
API
::
APIHelpers
include
ApiHelpers
include
ApiHelpers
let
(
:user
)
{
create
(
:user
)
}
let
(
:user
)
{
create
(
:user
)
}
...
...
spec/requests/api/branches_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
require
'mime/types'
require
'mime/types'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
enable_observers
}
before
(
:each
)
{
enable_observers
}
after
(
:each
)
{
disable_observers
}
after
(
:each
)
{
disable_observers
}
...
...
spec/requests/api/commits_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
require
'mime/types'
require
'mime/types'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
enable_observers
}
before
(
:each
)
{
enable_observers
}
after
(
:each
)
{
disable_observers
}
after
(
:each
)
{
disable_observers
}
...
...
spec/requests/api/files_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
...
...
spec/requests/api/groups_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
let
(
:user1
)
{
create
(
:user
)
}
let
(
:user1
)
{
create
(
:user
)
}
...
...
spec/requests/api/internal_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
...
...
spec/requests/api/issues_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
...
...
spec/requests/api/merge_requests_spec.rb
浏览文件 @
0f31acd0
require
"spec_helper"
require
"spec_helper"
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
...
...
spec/requests/api/milestones_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
enable_observers
}
before
(
:each
)
{
enable_observers
}
after
(
:each
)
{
disable_observers
}
after
(
:each
)
{
disable_observers
}
...
...
spec/requests/api/namespaces_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
...
...
spec/requests/api/notes_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
...
...
spec/requests/api/project_hooks_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
,
'ProjectHooks'
do
describe
API
::
API
,
'ProjectHooks'
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
enable_observers
}
before
(
:each
)
{
enable_observers
}
after
(
:each
)
{
disable_observers
}
after
(
:each
)
{
disable_observers
}
...
...
spec/requests/api/project_members_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
enable_observers
}
before
(
:each
)
{
enable_observers
}
after
(
:each
)
{
disable_observers
}
after
(
:each
)
{
disable_observers
}
...
...
spec/requests/api/projects_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
enable_observers
}
before
(
:each
)
{
enable_observers
}
after
(
:each
)
{
disable_observers
}
after
(
:each
)
{
disable_observers
}
...
...
spec/requests/api/repositories_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
require
'mime/types'
require
'mime/types'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
enable_observers
}
before
(
:each
)
{
enable_observers
}
after
(
:each
)
{
disable_observers
}
after
(
:each
)
{
disable_observers
}
...
...
spec/requests/api/services_spec.rb
浏览文件 @
0f31acd0
require
"spec_helper"
require
"spec_helper"
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
before
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
enable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
after
(
:each
)
{
ActiveRecord
::
Base
.
observers
.
disable
(
:user_observer
)
}
...
...
spec/requests/api/session_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
let
(
:user
)
{
create
(
:user
)
}
let
(
:user
)
{
create
(
:user
)
}
...
...
spec/requests/api/system_hooks_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
let
(
:user
)
{
create
(
:user
)
}
let
(
:user
)
{
create
(
:user
)
}
...
...
spec/requests/api/users_spec.rb
浏览文件 @
0f31acd0
require
'spec_helper'
require
'spec_helper'
describe
API
::
API
do
describe
API
::
API
,
api:
true
do
include
ApiHelpers
include
ApiHelpers
let
(
:user
)
{
create
(
:user
)
}
let
(
:user
)
{
create
(
:user
)
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录