mirror of
https://github.com/discourse/discourse.git
synced 2025-05-23 21:04:33 +08:00
Merge pull request #2372 from vikhyat/badge-system
Multiple grant badges
This commit is contained in:
@ -26,6 +26,14 @@ describe UserBadgesController do
|
||||
parsed = JSON.parse(response.body)
|
||||
parsed["user_badges"].length.should == 1
|
||||
end
|
||||
|
||||
it 'includes counts when passed the aggregate argument' do
|
||||
xhr :get, :index, username: user.username, aggregated: true
|
||||
|
||||
response.status.should == 200
|
||||
parsed = JSON.parse(response.body)
|
||||
parsed["user_badges"].first.has_key?('count').should be_true
|
||||
end
|
||||
end
|
||||
|
||||
context 'create' do
|
||||
|
Reference in New Issue
Block a user