mirror of
https://github.com/openSUSE/osem.git
synced 2026-08-13 19:54:02 +00:00
Merge pull request #555 from differentreality/mock_credentials
add username for mock credentials of openid in development
This commit is contained in:
commit
a52918c273
2 changed files with 7 additions and 3 deletions
|
|
@ -106,6 +106,7 @@ class User < ActiveRecord::Base
|
|||
if user.new_record?
|
||||
user.email = auth.info.email
|
||||
user.name = auth.info.name
|
||||
user.username = auth.info.username
|
||||
user.password = Devise.friendly_token[0, 20]
|
||||
user.skip_confirmation!
|
||||
end
|
||||
|
|
|
|||
|
|
@ -46,7 +46,8 @@ Osem::Application.configure do
|
|||
uid: 'facebook-test-uid-1',
|
||||
info: {
|
||||
name: 'admin admin',
|
||||
email: 'admin@email.com'
|
||||
email: 'admin@email.com',
|
||||
username: 'admin_admin'
|
||||
},
|
||||
credentials: {
|
||||
token: 'fb_mock_token',
|
||||
|
|
@ -60,7 +61,8 @@ Osem::Application.configure do
|
|||
uid: 'google-test-uid-1',
|
||||
info: {
|
||||
name: 'simple user',
|
||||
email: 'user0@email.com'
|
||||
email: 'user0@email.com',
|
||||
username: 'simple_user0'
|
||||
},
|
||||
credentials: {
|
||||
token: 'google_mock_token',
|
||||
|
|
@ -74,7 +76,8 @@ Osem::Application.configure do
|
|||
uid: 'suse-test-uid-1',
|
||||
info: {
|
||||
name: 'another user',
|
||||
email: 'user1@email.com'
|
||||
email: 'user1@email.com',
|
||||
username: 'another_user'
|
||||
},
|
||||
credentials: {
|
||||
token: 'suse_mock_token',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue