闭社主体 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.

21 lines
609 B

  1. # frozen_string_literal: true
  2. require 'rails_helper'
  3. describe 'about/_links.html.haml' do
  4. it 'does not show sign in link when signed in' do
  5. allow(view).to receive(:user_signed_in?).and_return(true)
  6. render
  7. expect(rendered).to have_content(I18n.t('about.get_started'))
  8. expect(rendered).not_to have_content(I18n.t('auth.login'))
  9. end
  10. it 'shows sign in link when signed out' do
  11. allow(view).to receive(:user_signed_in?).and_return(false)
  12. render
  13. expect(rendered).to have_content(I18n.t('about.get_started'))
  14. expect(rendered).to have_content(I18n.t('auth.login'))
  15. end
  16. end