Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
李少辉-开发者
gitlab-foss
提交
7dd7ffc1
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,发现更多精彩内容 >>
提交
7dd7ffc1
编写于
2月 17, 2017
作者:
C
Clement Ho
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'dynamic-project-title-fixture' into 'master'
Replace static fixture for project_title_spec.js See merge request !9175
上级
953c2547
6f1d8201
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
12 addition
and
31 deletion
+12
-31
changelogs/unreleased/dynamic-project-title-fixture.yml
changelogs/unreleased/dynamic-project-title-fixture.yml
+4
-0
spec/javascripts/fixtures/project_title.html.haml
spec/javascripts/fixtures/project_title.html.haml
+0
-20
spec/javascripts/project_title_spec.js
spec/javascripts/project_title_spec.js
+8
-11
未找到文件。
changelogs/unreleased/dynamic-project-title-fixture.yml
0 → 100644
浏览文件 @
7dd7ffc1
---
title
:
Replace static fixture for project_title_spec.js
merge_request
:
9175
author
:
winniehell
spec/javascripts/fixtures/project_title.html.haml
已删除
100644 → 0
浏览文件 @
953c2547
.header-content
%h1
.title
%a
GitLab Org
%a
.project-item-select-holder
{
href:
"/gitlab-org/gitlab-test"
}
GitLab Test
%i
.fa.chevron-down.dropdown-toggle-caret.js-projects-dropdown-toggle
{
"data-toggle"
=>
"dropdown"
,
"data-target"
=>
".header-content"
,
"data-order-by"
=>
"last_activity_at"
}
.js-dropdown-menu-projects
.dropdown-menu.dropdown-select.dropdown-menu-projects
.dropdown-title
%span
Go to a project
%button
.dropdown-title-button.dropdown-menu-close
{
"aria-label"
=>
"Close"
,
type:
"button"
}
%i
.fa.fa-times.dropdown-menu-close-icon
.dropdown-input
%input
.dropdown-input-field
{
id:
""
,
placeholder:
"Search your projects"
,
type:
"search"
,
value:
""
}
%i
.fa.fa-search.dropdown-input-search
%i
.fa.fa-times.dropdown-input-clear.js-dropdown-input-clear
{
role:
"button"
}
.dropdown-content
.dropdown-loading
%i
.fa.fa-spinner.fa-spin
spec/javascripts/project_title_spec.js
浏览文件 @
7dd7ffc1
...
...
@@ -10,11 +10,11 @@ require('~/project');
(
function
()
{
describe
(
'
Project Title
'
,
function
()
{
preloadFixtures
(
'
static/project_titl
e.html.raw
'
);
preloadFixtures
(
'
issues/open-issu
e.html.raw
'
);
loadJSONFixtures
(
'
projects.json
'
);
beforeEach
(
function
()
{
loadFixtures
(
'
static/project_titl
e.html.raw
'
);
loadFixtures
(
'
issues/open-issu
e.html.raw
'
);
window
.
gon
=
{};
window
.
gon
.
api_version
=
'
v3
'
;
...
...
@@ -38,15 +38,12 @@ require('~/project');
return
spyOn
(
jQuery
,
'
ajax
'
).
and
.
callFake
(
fakeAjaxResponse
.
bind
(
_this
));
};
})(
this
));
it
(
'
to show on toggle click
'
,
(
function
(
_this
)
{
return
function
()
{
$
(
'
.js-projects-dropdown-toggle
'
).
click
();
return
expect
(
$
(
'
.header-content
'
).
hasClass
(
'
open
'
)).
toBe
(
true
);
};
})(
this
));
return
it
(
'
hide dropdown
'
,
function
()
{
$
(
"
.dropdown-menu-close-icon
"
).
click
();
return
expect
(
$
(
'
.header-content
'
).
hasClass
(
'
open
'
)).
toBe
(
false
);
it
(
'
toggles dropdown
'
,
function
()
{
var
menu
=
$
(
'
.js-dropdown-menu-projects
'
);
$
(
'
.js-projects-dropdown-toggle
'
).
click
();
expect
(
menu
).
toHaveClass
(
'
open
'
);
menu
.
find
(
'
.dropdown-menu-close-icon
'
).
click
();
expect
(
menu
).
not
.
toHaveClass
(
'
open
'
);
});
});
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录