Commit 1cbfc8d0af7dabb88da8628d5706f7e721ce90ce

Authored by Dmitriy Zaporozhets
1 parent 74c8a635

Fix tab tests. Prevent 500 if user.last_sign_in_at is nil

app/views/admin/users/show.html.haml
... ... @@ -46,7 +46,10 @@
46 46 %li
47 47 %span.light Last sign-in at:
48 48 %strong
49   - = @admin_user.last_sign_in_at.stamp("Nov 12, 2031")
  49 + - if @admin_user.last_sign_in_at
  50 + = @admin_user.last_sign_in_at.stamp("Nov 12, 2031")
  51 + - else
  52 + never
50 53  
51 54 - if @admin_user.ldap_user?
52 55 %li
... ...
features/steps/project/project_active_tab.rb
... ... @@ -45,7 +45,7 @@ class ProjectActiveTab < Spinach::FeatureSteps
45 45 # Sub Tabs: Home
46 46  
47 47 Given 'I click the "Team" tab' do
48   - click_link('Team')
  48 + click_link('Project Members')
49 49 end
50 50  
51 51 Given 'I click the "Attachments" tab' do
... ... @@ -61,7 +61,7 @@ class ProjectActiveTab < Spinach::FeatureSteps
61 61 end
62 62  
63 63 Given 'I click the "Hooks" tab' do
64   - click_link('Hooks')
  64 + click_link('Web Hooks')
65 65 end
66 66  
67 67 Given 'I click the "Deploy Keys" tab' do
... ... @@ -73,7 +73,7 @@ class ProjectActiveTab < Spinach::FeatureSteps
73 73 end
74 74  
75 75 Then 'the active sub tab should be Team' do
76   - ensure_active_sub_tab('Team')
  76 + ensure_active_sub_tab('Project Members')
77 77 end
78 78  
79 79 Then 'the active sub tab should be Attachments' do
... ... @@ -89,7 +89,7 @@ class ProjectActiveTab < Spinach::FeatureSteps
89 89 end
90 90  
91 91 Then 'the active sub tab should be Hooks' do
92   - ensure_active_sub_tab('Hooks')
  92 + ensure_active_sub_tab('Web Hooks')
93 93 end
94 94  
95 95 Then 'the active sub tab should be Deploy Keys' do
... ...