闭社主体 forked from https://github.com/tootsuite/mastodon
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
776 B

  1. require 'rails_helper'
  2. $LOAD_PATH << '../lib'
  3. require 'tag_manager'
  4. describe 'about/show.html.haml' do
  5. before do
  6. end
  7. it 'has valid open graph tags' do
  8. instance_presenter = double(:instance_presenter,
  9. site_description: 'something',
  10. open_registrations: false,
  11. closed_registrations_message: 'yes',
  12. )
  13. assign(:instance_presenter, instance_presenter)
  14. render
  15. header_tags = view.content_for(:header_tags)
  16. expect(header_tags).to match(%r{<meta content='.+' property='og:title'>})
  17. expect(header_tags).to match(%r{<meta content='website' property='og:type'>})
  18. expect(header_tags).to match(%r{<meta content='.+' property='og:image'>})
  19. expect(header_tags).to match(%r{<meta content='http://.+' property='og:url'>})
  20. end
  21. end