require 'spec_helper'

describe UserInfoController do
  render_views
  let(:user) { FactoryGirl.create :user, admin: false }
  before { sign_in user }

  describe "GET 'dashboard'" do
    it "renders the dashboard info as json" do
      get :dashboard
      json = JSON.parse(response.body)
      expect(json.keys).to match_array %w(dashboard lite_papers card_thumbnails users)
    end
  end
end

require 'spec_helper'

describe UserInfoController do
  render_views
  let(:user) { FactoryGirl.create :user, admin: false }
  before { sign_in user }

  describe "GET 'dashboard'" do
    it "renders the dashboard info as json" do
      get :dashboard
      json = JSON.parse(response.body)
      expect(json.keys).to match_array %w(dashboard lite_papers card_thumbnails users affiliations)
    end
  end
end

Fix user info controller spec.
Fix user info controller spec.
