require 'test_helper' class SitemapsControllerTest < ActionDispatch::IntegrationTest test 'should return a success code' do get '/sitemap.xml' assert_equal 200, status end test 'should return the right xml' do get '/sitemap.xml' assert_equal response.body, "\n\n\n \n http://www.example.com/pages-sitemap.xml\n 2016-09-22T18:11:05-03:00\n \n \n http://www.example.com/attachment-sitemap.xml\n 2016-09-22T18:11:05-03:00\n \n \n http://www.example.com/geo-sitemap.xml\n 2016-09-22T18:11:05-03:00\n \n\n" end end