commits_controller_spec.rb 487 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
require 'spec_helper'

describe CommitsController do
  let(:project) { create(:project) }
  let(:user)    { create(:user) }

  before do
    sign_in(user)

    project.add_access(user, :read, :admin)
  end

  describe "GET show" do
    context "as atom feed" do
      it "should render as atom" do
16
        get :show, project_id: project.path, id: "master.atom"
17 18 19 20 21 22
        response.should be_success
        response.content_type.should == 'application/atom+xml'
      end
    end
  end
end