Skip to content
This repository has been archived by the owner on Mar 26, 2024. It is now read-only.

(#16429) Relpaths #122

Merged
merged 4 commits into from Jan 3, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 4 additions & 3 deletions app/views/shared/_node_manager_sidebar.html.haml
@@ -1,11 +1,12 @@
- add_body_class 'with-sidebar'

.group.delayed-job
%h3= link_to "Background Tasks", "/delayed_job_failures"
- failures_node = {:controller => "delayed_job_failures", :action => "index"}
%h3= link_to "Background Tasks", failures_node

- if DelayedJobFailure.unread.count > 0
%p.failure
= link_to "#{ pluralize DelayedJobFailure.unread.count, 'new failed task' }", "/delayed_job_failures"
= link_to "#{ pluralize DelayedJobFailure.unread.count, 'new failed task' }", failures_node
- if Delayed::Job.count > 0
%p.warning
%em= "#{ pluralize Delayed::Job.count, 'pending task' }"
Expand Down Expand Up @@ -50,7 +51,7 @@

.footer.actionbar
#radiator
= link_to "Radiator View", '/radiator'
= link_to "Radiator View", {:controller => "radiator", :action => "index"}
- unless SETTINGS.enable_read_only_mode || session['ACCESS_CONTROL_ROLE'] == 'READ_ONLY'
= link_to "Add node", new_node_path, :class => 'button'

Expand Down
6 changes: 3 additions & 3 deletions public/stylesheets/application.css
Expand Up @@ -629,11 +629,11 @@ body {
background-position: 0% 50%;
margin-bottom: .5em; }
body .delayed-job p.ok em {
background: transparent url(/images/icons/delayed-job-ok.png) no-repeat 0% 50%; }
background: transparent url(../images/icons/delayed-job-ok.png) no-repeat 0% 50%; }
body .delayed-job p.failure a {
background-image: url(/images/icons/delayed-job-failure.png); }
background-image: url(../images/icons/delayed-job-failure.png); }
body .delayed-job p.warning em {
background-image: url(/images/icons/delayed-job-warning.png); }
background-image: url(../images/icons/delayed-job-warning.png); }

a.autorefresh_link {
color: #aaa; }
6 changes: 3 additions & 3 deletions public/stylesheets/sass/application.scss
Expand Up @@ -808,17 +808,17 @@ body {
}
&.ok {
em {
background : transparent url( /images/icons/delayed-job-ok.png ) no-repeat 0% 50%;
background : transparent url( ../images/icons/delayed-job-ok.png ) no-repeat 0% 50%;
}
}
&.failure {
a {
background-image : url( /images/icons/delayed-job-failure.png );
background-image : url( ../images/icons/delayed-job-failure.png );
}
}
&.warning {
em {
background-image : url( /images/icons/delayed-job-warning.png );
background-image : url( ../images/icons/delayed-job-warning.png );
}
}
}
Expand Down
8 changes: 4 additions & 4 deletions public/stylesheets/tables.css
Expand Up @@ -137,17 +137,17 @@ table td.empty {
display: none;
}
.expandable-list .expandable-link.collapsed-link:before {
content: url('../../images/icons/bullet_toggle_plus.png');
content: url('../images/icons/bullet_toggle_plus.png');
}
.expandable-list .expandable-link:before {
content: url('../../images/icons/bullet_toggle_minus.png');
content: url('../images/icons/bullet_toggle_minus.png');
}

.expandable-list .non-expandable-bullet:before {
content: url('../../images/icons/bullet_green.png');
content: url('../images/icons/bullet_green.png');
}
.inspect-report .expandable-list .non-expandable-bullet:before {
content: url('../../images/icons/bullet_red.png');
content: url('../images/icons/bullet_red.png');
}

.expandable-list .expandable-link, .expandable-list .non-expandable-bullet {
Expand Down
30 changes: 30 additions & 0 deletions spec/views/pages/home.html.haml_spec.rb
@@ -0,0 +1,30 @@
require File.expand_path(File.join(File.dirname(__FILE__), *%w[.. .. spec_helper]))

describe '/pages/home.html.haml' do
describe "successful render" do
before :each do
assigns[:all_nodes] = @all_nodes = [Node.generate!]
assigns[:unreported_nodes] = []
assigns[:unresponsive_nodes] = []
assigns[:failed_nodes] = []
assigns[:pending_nodes] = []
assigns[:changed_nodes] = []
assigns[:unchanged_nodes] = []
end

specify do
render
response.should be_success
end

it "should have a correct delayed_job_failures link" do
render
should have_tag('a[href="/delayed_job_failures"]', 'Background Tasks')
end

it "should have a correct radiator link" do
render
should have_tag('a[href="/radiator"]', 'Radiator View')
end
end
end