Fixed test.
This commit is contained in:
parent
0c221925a8
commit
3bd759e23f
1 changed files with 4 additions and 4 deletions
|
@ -80,8 +80,8 @@ class UserOrganizationControllerTest < ActionDispatch::IntegrationTest
|
|||
post '/api/v1/users', {}, @headers
|
||||
assert_response(422)
|
||||
result = JSON.parse(@response.body)
|
||||
assert(result['error'])
|
||||
assert_equal('Feature not enabled!', result['error'])
|
||||
assert(result['error_human'])
|
||||
assert_equal('Feature not enabled!', result['error_human'])
|
||||
|
||||
# already existing user with enabled feature
|
||||
Setting.set('user_create_account', true)
|
||||
|
@ -89,8 +89,8 @@ class UserOrganizationControllerTest < ActionDispatch::IntegrationTest
|
|||
post '/api/v1/users', params.to_json, @headers
|
||||
assert_response(422)
|
||||
result = JSON.parse(@response.body)
|
||||
assert(result['error'])
|
||||
assert_equal('User already exists!', result['error'])
|
||||
assert(result['error_human'])
|
||||
assert_equal('User already exists!', result['error_human'])
|
||||
|
||||
# create user with enabled feature
|
||||
params = { firstname: 'Me First', lastname: 'Me Last', email: 'new_here@example.com' }
|
||||
|
|
Loading…
Reference in a new issue