require 'spec_helper' require 'haml' describe 'pugin/components/_status.html.haml', type: :view do context 'without a status message' do it 'renders as expected' do render partial: 'pugin/components/status', locals: { status: nil } expect(response).to eq( <

This is a test website, so may be inaccurate or misleading - give feedback to help improve it. Return to current website.

DATA ) end end context 'with a status message' do it 'renders as expected' do render partial: 'pugin/components/status', locals: { status: "test" } expect(rendered).to eq( <

This is a test website, so may be inaccurate or misleading - give feedback to help improve it. Return to current website.

DATA ) end end end