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
Adds application permission check on certain command groups / specific commands #5862
base: main
Are you sure you want to change the base?
Conversation
Thank you, we'll try to review it ASAP |
Could you fix the merge conflicts, please? |
b437ed1
to
da45f2e
Compare
@MathijsVerbeeck could you fix the merge conflicts again? |
da45f2e
to
6edce03
Compare
Could you resolve the merge conflicts @MathijsVerbeeck? |
6edce03
to
8f0ceed
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great start @MathijsVerbeeck, made a few comments while reviewing. Could you have a look at them, please?
A few comments apply to all tests.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's do some more changes. It seems like you missed some of my previous comments, or they were not clear enough. If the latter, sorry for that, you can always ask more context.
Another thing, currently we have a lot of files (pa, pp, flow, ...) where we stub the wrong function. Right now we do:
sinon.stub(accessToken, 'isAppOnlyAccessToken').returns(false);
auth.connection.accessTokens[auth.defaultResource] = {
expiresOn: 'abc',
accessToken: 'abc'
};
While in fact, we should just stub the assertDelegatedAccessToken
function.
Sorry for the inconvenience... I had some merge issues on my laptop and decided, instead of fixing them, to work on a clean branch on my desktop, which is why I must've messed up some of the comments you had already given. |
@@ -39,37 +49,39 @@ describe('PowerAppsCommand', () => { | |||
}); | |||
|
|||
it(`doesn't throw error when not connected`, () => { | |||
auth.connection.active = false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's undo this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We're getting there, let's do a few more changes to get it on point.
Closes #4054
Quite a big one, so a little summary below :-)
Command groups:
Specific commands
outlook message move
teams chat send