BigW Consortium Gitlab

Commit 669fb299 by Phil Hughes

fixed up a bunch of specs

some caused by webkit prefixes
parent 331722c0
......@@ -8,10 +8,17 @@ header.navbar-gitlab-new {
border-bottom: 0;
.header-content {
display: -webkit-flex;
display: flex;
padding-left: 0;
.title-container {
display: -webkit-flex;
display: flex;
-webkit-align-items: stretch;
align-items: stretch;
-webkit-flex: 1 1 auto;
flex: 1 1 auto;
padding-top: 0;
overflow: visible;
}
......
......@@ -37,13 +37,13 @@
data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
= icon('tachometer fw')
%li
= link_to assigned_issues_dashboard_path, title: 'Issues', aria: { label: "Issues" }, data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
= link_to assigned_issues_dashboard_path, title: 'Issues', class: 'dashboard-shortcuts-issues', aria: { label: "Issues" }, data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
= custom_icon('issues')
- issues_count = assigned_issuables_count(:issues)
%span.badge.issues-count{ class: ('hidden' if issues_count.zero?) }
= number_with_delimiter(issues_count)
%li
= link_to assigned_mrs_dashboard_path, title: 'Merge requests', aria: { label: "Merge requests" }, data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
= link_to assigned_mrs_dashboard_path, title: 'Merge requests', class: 'dashboard-shortcuts-merge_requests', aria: { label: "Merge requests" }, data: {toggle: 'tooltip', placement: 'bottom', container: 'body'} do
= custom_icon('mr_bold')
- merge_requests_count = assigned_issuables_count(:merge_requests)
%span.badge.merge-requests-count{ class: ('hidden' if merge_requests_count.zero?) }
......
......@@ -7,15 +7,15 @@ RSpec.describe 'admin active tab' do
shared_examples 'page has active tab' do |title|
it "activates #{title} tab" do
expect(page).to have_selector('.layout-nav .nav-links > li.active', count: 1)
expect(page.find('.layout-nav li.active')).to have_content(title)
expect(page).to have_selector('.nav-sidebar .sidebar-top-level-items > li.active', count: 1)
expect(page.find('.nav-sidebar .sidebar-top-level-items > li.active')).to have_content(title)
end
end
shared_examples 'page has active sub tab' do |title|
it "activates #{title} sub tab" do
expect(page).to have_selector('.sub-nav li.active', count: 1)
expect(page.find('.sub-nav li.active')).to have_content(title)
expect(page).to have_selector('.sidebar-sub-level-items li.active', count: 1)
expect(page.find('.sidebar-sub-level-items li.active')).to have_content(title)
end
end
......
require 'spec_helper'
describe 'Admin::Hooks' do
describe 'Admin::Hooks', :js do
before do
@project = create(:project)
sign_in(create(:admin))
......@@ -12,7 +12,7 @@ describe 'Admin::Hooks' do
it 'is ok' do
visit admin_root_path
page.within '.layout-nav' do
page.within '.nav-sidebar' do
click_on 'Hooks'
end
......
......@@ -50,6 +50,6 @@ feature 'Dashboard shortcuts', :js do
end
def check_page_title(title)
expect(find('.header-content .title')).to have_content(title)
expect(find('.breadcrumbs-sub-title')).to have_content(title)
end
end
......@@ -43,14 +43,14 @@ feature 'Profile > Account' do
update_username(new_username)
visit new_project_path
expect(current_path).to eq(new_project_path)
expect(find('h1.title')).to have_content(project.path)
expect(find('.breadcrumbs-sub-title')).to have_content(project.path)
end
scenario 'the old project path redirects to the new path' do
update_username(new_username)
visit old_project_path
expect(current_path).to eq(new_project_path)
expect(find('h1.title')).to have_content(project.path)
expect(find('.breadcrumbs-sub-title')).to have_content(project.path)
end
end
end
......
......@@ -160,7 +160,7 @@ describe "Search" do
fill_in 'search', with: 'gitlab'
find('#search').native.send_keys(:enter)
page.within '.title' do
page.within '.breadcrumbs-sub-title' do
expect(page).to have_content 'Search'
end
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment