-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed conversation update activity handler failing with infinite loop #…
- Loading branch information
1 parent
e07a0cf
commit 3aad8b8
Showing
2 changed files
with
50 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package core | ||
|
||
import ( | ||
"context" | ||
|
||
"github.com/infracloudio/msbotbuilder-go/connector/auth" | ||
"github.com/infracloudio/msbotbuilder-go/schema" | ||
) | ||
|
||
// All the mocks and stubs for BotFrameworkAdapter goes here. | ||
|
||
// MockTokenValidator stub for bypassing the authentication | ||
type MockTokenValidator struct { | ||
} | ||
|
||
// AuthenticateRequest mock implementation for authentication | ||
func (jv *MockTokenValidator) AuthenticateRequest(ctx context.Context, activity schema.Activity, authHeader string, credentials auth.CredentialProvider, channelService string) (auth.ClaimsIdentity, error) { | ||
claims := map[string]interface{}{ | ||
"1": "1", | ||
} | ||
return auth.NewClaimIdentity(claims, true), nil | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters