mirror of
https://git.bsd.gay/fef/nyastodon.git
synced 2025-01-12 12:46:56 +01:00
Combine double subjects in application controller shared example (#28938)
This commit is contained in:
parent
6d35a77c92
commit
beaef4b672
1 changed files with 3 additions and 6 deletions
|
@ -22,13 +22,10 @@ describe ApplicationController do
|
||||||
end
|
end
|
||||||
|
|
||||||
shared_examples 'respond_with_error' do |code|
|
shared_examples 'respond_with_error' do |code|
|
||||||
it "returns http #{code} for http" do
|
it "returns http #{code} for http and renders template" do
|
||||||
subject
|
|
||||||
expect(response).to have_http_status(code)
|
|
||||||
end
|
|
||||||
|
|
||||||
it 'renders template for http' do
|
|
||||||
expect(subject).to render_template("errors/#{code}", layout: 'error')
|
expect(subject).to render_template("errors/#{code}", layout: 'error')
|
||||||
|
|
||||||
|
expect(response).to have_http_status(code)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue