mirror of
https://github.com/discourse/discourse.git
synced 2025-05-24 03:36:18 +08:00
Upgrade rspec to 3.4.0.
This commit is contained in:
@ -24,7 +24,7 @@ describe UserBadgesController do
|
||||
let!(:user_badge) { UserBadge.create(badge: badge, user: user, granted_by: Discourse.system_user, granted_at: Time.now) }
|
||||
|
||||
it 'requires username or badge_id to be specified' do
|
||||
expect { xhr :get, :index }.to raise_error
|
||||
expect { xhr :get, :index }.to raise_error(ActionController::ParameterMissing)
|
||||
end
|
||||
|
||||
it 'returns user_badges for a user' do
|
||||
@ -54,7 +54,7 @@ describe UserBadgesController do
|
||||
|
||||
context 'create' do
|
||||
it 'requires username to be specified' do
|
||||
expect { xhr :post, :create, badge_id: badge.id }.to raise_error
|
||||
expect { xhr :post, :create, badge_id: badge.id }.to raise_error(ActionController::ParameterMissing)
|
||||
end
|
||||
|
||||
it 'does not allow regular users to grant badges' do
|
||||
|
Reference in New Issue
Block a user