mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-05-07 07:14:29 -04:00
2
app/controllers/about_controller.rb
Normal file
2
app/controllers/about_controller.rb
Normal file
@@ -0,0 +1,2 @@
|
||||
class AboutController < ApplicationController
|
||||
end
|
||||
17
app/views/about/contact.html.haml
Normal file
17
app/views/about/contact.html.haml
Normal file
@@ -0,0 +1,17 @@
|
||||
-content_for :title, 'Contact'
|
||||
|
||||
%dl
|
||||
%dt General contact email
|
||||
%dd= link_to 'info@growstuff.org', 'mailto:info@growstuff.org'
|
||||
%dl
|
||||
%dt
|
||||
Support and accounts enquiries (not covered by the
|
||||
=succeed ")" do
|
||||
=link_to 'FAQ', url_for(:controller => '/support')
|
||||
%dd= link_to 'support@growstuff.org', 'mailto:support@growstuff.org'
|
||||
%dl
|
||||
%dt Media/Press enquiries
|
||||
%dd= link_to 'media@growstuff.org', 'mailto:media@growstuff.org'
|
||||
%dl
|
||||
%dt Twitter
|
||||
%dd= link_to '@Growstuff', 'http:/twitter.com/Growstuff'
|
||||
@@ -4,6 +4,7 @@
|
||||
.container
|
||||
%ul.nav
|
||||
%li= link_to "About", "http://wiki.growstuff.org"
|
||||
%li= link_to "Contact", url_for(:controller => '/about', :action => 'contact')
|
||||
%li= link_to "Terms of Service", url_for(:controller => '/policy', :action => 'tos')
|
||||
%li= link_to "Privacy Policy", url_for(:controller => %'/policy', :action => 'privacy')
|
||||
%li= link_to "Community Guidelines", url_for(:controller => '/policy', :action => 'community')
|
||||
|
||||
@@ -80,5 +80,7 @@ Growstuff::Application.routes.draw do
|
||||
match '/policy/:action' => 'policy#:action'
|
||||
match '/support' => 'support#index'
|
||||
match '/support/:action' => 'support#:action'
|
||||
match '/about' => 'about#index'
|
||||
match '/about/:action' => 'about#:action'
|
||||
|
||||
end
|
||||
|
||||
12
spec/views/about/contact_spec.rb
Normal file
12
spec/views/about/contact_spec.rb
Normal file
@@ -0,0 +1,12 @@
|
||||
require 'spec_helper'
|
||||
|
||||
describe 'about/contact.html.haml', :type => "view" do
|
||||
before(:each) do
|
||||
render
|
||||
end
|
||||
|
||||
it 'should show support faq' do
|
||||
render
|
||||
rendered.should contain 'General contact email'
|
||||
end
|
||||
end
|
||||
@@ -8,6 +8,7 @@ describe 'layouts/_footer.html.haml', :type => "view" do
|
||||
|
||||
it 'should have links in footer' do
|
||||
rendered.should contain 'About'
|
||||
rendered.should contain 'Contact'
|
||||
assert_select("a[href=/policy/tos]", 'Terms of Service')
|
||||
assert_select("a[href=/policy/privacy]", 'Privacy Policy')
|
||||
assert_select("a[href=/policy/community]", 'Community Guidelines')
|
||||
|
||||
Reference in New Issue
Block a user