BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
4a67699e
Commit
4a67699e
authored
Aug 17, 2017
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
spec updates
parent
d0d918c7
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
41 additions
and
81 deletions
+41
-81
boards_spec.rb
spec/features/boards/boards_spec.rb
+2
-0
active_tab_spec.rb
spec/features/dashboard/active_tab_spec.rb
+2
-3
issues_filter_spec.rb
spec/features/dashboard/issues_filter_spec.rb
+1
-1
group_name_toggle_spec.rb
spec/features/groups/group_name_toggle_spec.rb
+0
-51
group_settings_spec.rb
spec/features/groups/group_settings_spec.rb
+2
-2
issues_spec.rb
spec/features/issues_spec.rb
+25
-15
guest_navigation_menu_spec.rb
spec/features/projects/guest_navigation_menu_spec.rb
+1
-1
project_settings_spec.rb
spec/features/projects/project_settings_spec.rb
+7
-7
sub_group_issuables_spec.rb
spec/features/projects/sub_group_issuables_spec.rb
+1
-1
No files found.
spec/features/boards/boards_spec.rb
View file @
4a67699e
...
...
@@ -145,6 +145,8 @@ describe 'Issue Boards', js: true do
click_button
'Add list'
wait_for_requests
find
(
'.dropdown-menu-close'
).
click
page
.
within
(
find
(
'.board:nth-child(2)'
))
do
find
(
'.board-delete'
).
click
end
...
...
spec/features/dashboard/active_tab_spec.rb
View file @
4a67699e
...
...
@@ -7,9 +7,8 @@ RSpec.describe 'Dashboard Active Tab', js: true do
shared_examples
'page has active tab'
do
|
title
|
it
"
#{
title
}
tab"
do
find
(
'.global-dropdown-toggle'
).
trigger
(
'click'
)
expect
(
page
).
to
have_selector
(
'.global-dropdown-menu li.active'
,
count:
1
)
expect
(
find
(
'.global-dropdown-menu li.active'
)).
to
have_content
(
title
)
expect
(
page
).
to
have_selector
(
'.navbar-sub-nav li.active'
,
count:
1
)
expect
(
find
(
'.navbar-sub-nav li.active'
)).
to
have_content
(
title
)
end
end
...
...
spec/features/dashboard/issues_filter_spec.rb
View file @
4a67699e
...
...
@@ -50,7 +50,7 @@ feature 'Dashboard Issues filtering', :js do
it
'updates atom feed link'
do
visit_issues
(
milestone_title:
''
,
assignee_id:
user
.
id
)
link
=
find
(
'.
nav-control
s a[title="Subscribe"]'
)
link
=
find
(
'.
breadcrumb
s a[title="Subscribe"]'
)
params
=
CGI
.
parse
(
URI
.
parse
(
link
[
:href
]).
query
)
auto_discovery_link
=
find
(
'link[type="application/atom+xml"]'
,
visible:
false
)
auto_discovery_params
=
CGI
.
parse
(
URI
.
parse
(
auto_discovery_link
[
:href
]).
query
)
...
...
spec/features/groups/group_name_toggle_spec.rb
deleted
100644 → 0
View file @
d0d918c7
require
'spec_helper'
feature
'Group name toggle'
,
js:
true
do
let
(
:group
)
{
create
(
:group
)
}
let
(
:nested_group_1
)
{
create
(
:group
,
parent:
group
)
}
let
(
:nested_group_2
)
{
create
(
:group
,
parent:
nested_group_1
)
}
let
(
:nested_group_3
)
{
create
(
:group
,
parent:
nested_group_2
)
}
SMALL_SCREEN
=
300
before
do
sign_in
(
create
(
:user
))
end
it
'is not present if enough horizontal space'
do
visit
group_path
(
nested_group_3
)
container_width
=
page
.
evaluate_script
(
"$('.title-container')[0].offsetWidth"
)
title_width
=
page
.
evaluate_script
(
"$('.title')[0].offsetWidth"
)
expect
(
container_width
).
to
be
>
title_width
expect
(
page
).
not_to
have_css
(
'.group-name-toggle'
)
end
it
'is present if the title is longer than the container'
,
:nested_groups
do
visit
group_path
(
nested_group_3
)
title_width
=
page
.
evaluate_script
(
"$('.title')[0].offsetWidth"
)
page_height
=
page
.
current_window
.
size
[
1
]
page
.
current_window
.
resize_to
(
SMALL_SCREEN
,
page_height
)
find
(
'.group-name-toggle'
)
container_width
=
page
.
evaluate_script
(
"$('.title-container')[0].offsetWidth"
)
expect
(
title_width
).
to
be
>
container_width
end
it
'should show the full group namespace when toggled'
,
:nested_groups
do
page_height
=
page
.
current_window
.
size
[
1
]
page
.
current_window
.
resize_to
(
SMALL_SCREEN
,
page_height
)
visit
group_path
(
nested_group_3
)
expect
(
page
).
not_to
have_content
(
group
.
name
)
expect
(
page
).
to
have_css
(
'.group-path.hidable'
,
visible:
false
)
click_button
'...'
expect
(
page
).
to
have_content
(
group
.
name
)
expect
(
page
).
to
have_css
(
'.group-path.hidable'
,
visible:
true
)
end
end
spec/features/groups/group_settings_spec.rb
View file @
4a67699e
...
...
@@ -65,14 +65,14 @@ feature 'Edit group settings' do
update_path
(
new_group_path
)
visit
new_project_full_path
expect
(
current_path
).
to
eq
(
new_project_full_path
)
expect
(
find
(
'
h1.title
'
)).
to
have_content
(
project
.
path
)
expect
(
find
(
'
.breadcrumbs
'
)).
to
have_content
(
project
.
path
)
end
scenario
'the old project path redirects to the new path'
do
update_path
(
new_group_path
)
visit
old_project_full_path
expect
(
current_path
).
to
eq
(
new_project_full_path
)
expect
(
find
(
'
h1.title
'
)).
to
have_content
(
project
.
path
)
expect
(
find
(
'
.breadcrumbs
'
)).
to
have_content
(
project
.
path
)
end
end
end
...
...
spec/features/issues_spec.rb
View file @
4a67699e
...
...
@@ -271,17 +271,21 @@ describe 'Issues' do
it
'filters by none'
do
visit
project_issues_path
(
project
,
due_date:
Issue
::
NoDueDate
.
name
)
expect
(
page
).
not_to
have_content
(
'foo'
)
expect
(
page
).
not_to
have_content
(
'bar'
)
expect
(
page
).
to
have_content
(
'baz'
)
page
.
within
'.issues-holder'
do
expect
(
page
).
not_to
have_content
(
'foo'
)
expect
(
page
).
not_to
have_content
(
'bar'
)
expect
(
page
).
to
have_content
(
'baz'
)
end
end
it
'filters by any'
do
visit
project_issues_path
(
project
,
due_date:
Issue
::
AnyDueDate
.
name
)
expect
(
page
).
to
have_content
(
'foo'
)
expect
(
page
).
to
have_content
(
'bar'
)
expect
(
page
).
to
have_content
(
'baz'
)
page
.
within
'.issues-holder'
do
expect
(
page
).
to
have_content
(
'foo'
)
expect
(
page
).
to
have_content
(
'bar'
)
expect
(
page
).
to
have_content
(
'baz'
)
end
end
it
'filters by due this week'
do
...
...
@@ -291,9 +295,11 @@ describe 'Issues' do
visit
project_issues_path
(
project
,
due_date:
Issue
::
DueThisWeek
.
name
)
expect
(
page
).
to
have_content
(
'foo'
)
expect
(
page
).
to
have_content
(
'bar'
)
expect
(
page
).
not_to
have_content
(
'baz'
)
page
.
within
'.issues-holder'
do
expect
(
page
).
to
have_content
(
'foo'
)
expect
(
page
).
to
have_content
(
'bar'
)
expect
(
page
).
not_to
have_content
(
'baz'
)
end
end
it
'filters by due this month'
do
...
...
@@ -303,9 +309,11 @@ describe 'Issues' do
visit
project_issues_path
(
project
,
due_date:
Issue
::
DueThisMonth
.
name
)
expect
(
page
).
to
have_content
(
'foo'
)
expect
(
page
).
to
have_content
(
'bar'
)
expect
(
page
).
not_to
have_content
(
'baz'
)
page
.
within
'.issues-holder'
do
expect
(
page
).
to
have_content
(
'foo'
)
expect
(
page
).
to
have_content
(
'bar'
)
expect
(
page
).
not_to
have_content
(
'baz'
)
end
end
it
'filters by overdue'
do
...
...
@@ -315,9 +323,11 @@ describe 'Issues' do
visit
project_issues_path
(
project
,
due_date:
Issue
::
Overdue
.
name
)
expect
(
page
).
not_to
have_content
(
'foo'
)
expect
(
page
).
not_to
have_content
(
'bar'
)
expect
(
page
).
to
have_content
(
'baz'
)
page
.
within
'.issues-holder'
do
expect
(
page
).
not_to
have_content
(
'foo'
)
expect
(
page
).
not_to
have_content
(
'bar'
)
expect
(
page
).
to
have_content
(
'baz'
)
end
end
end
...
...
spec/features/projects/guest_navigation_menu_spec.rb
View file @
4a67699e
...
...
@@ -13,7 +13,7 @@ describe 'Guest navigation menu' do
it
'shows allowed tabs only'
do
visit
project_path
(
project
)
within
(
'.
layout-nav
'
)
do
within
(
'.
nav-sidebar
'
)
do
expect
(
page
).
to
have_content
'Project'
expect
(
page
).
to
have_content
'Issues'
expect
(
page
).
to
have_content
'Wiki'
...
...
spec/features/projects/project_settings_spec.rb
View file @
4a67699e
...
...
@@ -46,7 +46,7 @@ describe 'Edit Project Settings' do
context
'when changing project name'
do
it
'renames the repository'
do
rename_project
(
project
,
name:
'bar'
)
expect
(
find
(
'
h1.title
'
)).
to
have_content
(
project
.
name
)
expect
(
find
(
'
.breadcrumbs
'
)).
to
have_content
(
project
.
name
)
end
context
'with emojis'
do
...
...
@@ -74,7 +74,7 @@ describe 'Edit Project Settings' do
new_path
=
namespace_project_path
(
project
.
namespace
,
'bar'
)
visit
new_path
expect
(
current_path
).
to
eq
(
new_path
)
expect
(
find
(
'
h1.title
'
)).
to
have_content
(
project
.
name
)
expect
(
find
(
'
.breadcrumbs
'
)).
to
have_content
(
project
.
name
)
end
specify
'the project is accessible via a redirect from the old path'
do
...
...
@@ -83,7 +83,7 @@ describe 'Edit Project Settings' do
new_path
=
namespace_project_path
(
project
.
namespace
,
'bar'
)
visit
old_path
expect
(
current_path
).
to
eq
(
new_path
)
expect
(
find
(
'
h1.title
'
)).
to
have_content
(
project
.
name
)
expect
(
find
(
'
.breadcrumbs
'
)).
to
have_content
(
project
.
name
)
end
context
'and a new project is added with the same path'
do
...
...
@@ -93,7 +93,7 @@ describe 'Edit Project Settings' do
new_project
=
create
(
:project
,
namespace:
user
.
namespace
,
path:
'gitlabhq'
,
name:
'quz'
)
visit
old_path
expect
(
current_path
).
to
eq
(
old_path
)
expect
(
find
(
'
h1.title
'
)).
to
have_content
(
new_project
.
name
)
expect
(
find
(
'
.breadcrumbs
'
)).
to
have_content
(
new_project
.
name
)
end
end
end
...
...
@@ -120,7 +120,7 @@ describe 'Edit Project Settings' do
new_path
=
namespace_project_path
(
group
,
project
)
visit
new_path
expect
(
current_path
).
to
eq
(
new_path
)
expect
(
find
(
'
h1.title
'
)).
to
have_content
(
project
.
name
)
expect
(
find
(
'
.breadcrumbs
'
)).
to
have_content
(
project
.
name
)
end
specify
'the project is accessible via a redirect from the old path'
do
...
...
@@ -129,7 +129,7 @@ describe 'Edit Project Settings' do
new_path
=
namespace_project_path
(
group
,
project
)
visit
old_path
expect
(
current_path
).
to
eq
(
new_path
)
expect
(
find
(
'
h1.title
'
)).
to
have_content
(
project
.
name
)
expect
(
find
(
'
.breadcrumbs
'
)).
to
have_content
(
project
.
name
)
end
context
'and a new project is added with the same path'
do
...
...
@@ -139,7 +139,7 @@ describe 'Edit Project Settings' do
new_project
=
create
(
:project
,
namespace:
user
.
namespace
,
path:
'gitlabhq'
,
name:
'quz'
)
visit
old_path
expect
(
current_path
).
to
eq
(
old_path
)
expect
(
find
(
'
h1.title
'
)).
to
have_content
(
new_project
.
name
)
expect
(
find
(
'
.breadcrumbs
'
)).
to
have_content
(
new_project
.
name
)
end
end
end
...
...
spec/features/projects/sub_group_issuables_spec.rb
View file @
4a67699e
...
...
@@ -24,7 +24,7 @@ describe 'Subgroup Issuables', :js, :nested_groups do
end
def
expect_to_have_full_subgroup_title
title
=
find
(
'.
title-container
'
)
title
=
find
(
'.
breadcrumbs-links
'
)
expect
(
title
).
not_to
have_selector
'.initializing'
expect
(
title
).
to
have_content
'group / subgroup / project'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment