Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding OAuthCard support for Streaming Extensions #1284

Merged
merged 9 commits into from
Oct 10, 2019
Merged

Adding OAuthCard support for Streaming Extensions #1284

merged 9 commits into from
Oct 10, 2019

Conversation

Jeffders
Copy link
Member

Description

This adds OAuthCard resolution to connections made with streaming extensions.

Specific Changes

Adds the polling mechanism to retrieve OAuth tokens when an OAuthCard is sent via streaming extensions. This was the approved design, so porting it to the JS bot builder.

Basically:
When an OAuthCard is sent on streaming connection, the BotAdapter begins to poll for that particular token until it is found. The service can override and terminate the polling if need be. Once the token is retrieved, it is sent back through the adapter.

Testing

Added new tests that match the C# implementation.

@coveralls
Copy link

coveralls commented Oct 10, 2019

Pull Request Test Coverage Report for Build 82770

  • 64 of 71 (90.14%) changed or added relevant lines in 6 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.07%) to 86.987%

Changes Missing Coverage Covered Lines Changed/Added Lines %
libraries/botbuilder/src/tokenResolver.ts 43 45 95.56%
libraries/botbuilder/src/botFrameworkAdapter.ts 9 14 64.29%
Totals Coverage Status
Change from base Build 82763: -0.07%
Covered Lines: 4743
Relevant Lines: 5240

💛 - Coveralls

@carlosscastro
Copy link
Member

carlosscastro commented Oct 10, 2019

This is a port from a c# PR that we iterated a lot on. Looks good feature wise. Might be good to have some of the folks that regularly work on js to do a pass.

@cleemullins
Copy link
Contributor

Please merge when ready.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants