spec/angelo/static_spec.rb in angelo-0.1.2 vs spec/angelo/static_spec.rb in angelo-0.1.3

- old
+ new

@@ -52,8 +52,21 @@ it 'not modifieds when if-none-match matched etag' do get '/test.css', {}, {'If-None-Match' => test_css_etag} expect(last_response.status).to be(304) end + it 'serves proper content-types' do + { 'test.js' => 'application/javascript', + 'test.html' => 'text/html', + 'test.css' => 'text/css', + 'what.png' => 'image/png' }.each do |k,v| + + get "/#{k}" + expect(last_response.status).to be(200) + expect(last_response.headers['Content-Type']).to eq(v) + + end + end + end end