mirror of
https://github.com/discourse/discourse.git
synced 2025-09-06 10:50:21 +08:00
FIX: support connecting GitHub with existing accounts
This commit is contained in:
parent
c84b837d50
commit
502a0fe778
2 changed files with 6 additions and 0 deletions
|
@ -235,6 +235,8 @@ describe Auth::GithubAuthenticator do
|
|||
user1 = Fabricate(:user)
|
||||
user2 = Fabricate(:user)
|
||||
|
||||
expect(authenticator.can_connect_existing_user?).to eq(true)
|
||||
|
||||
GithubUserInfo.create!(user_id: user1.id, github_user_id: 100, screen_name: "boris")
|
||||
|
||||
result = authenticator.after_authenticate(data, existing_account: user2)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue