mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-21 03:42:16 +00:00
fix(core): Fix OAuth1 callback token request (#14251)
This commit is contained in:
@@ -230,15 +230,11 @@ describe('OAuth1CredentialController', () => {
|
||||
});
|
||||
jest.spyOn(Csrf.prototype, 'verify').mockReturnValueOnce(true);
|
||||
nock('https://example.domain')
|
||||
.post('/oauth/access_token', {
|
||||
oauth_token: 'token',
|
||||
oauth_verifier: 'verifier',
|
||||
})
|
||||
.post('/oauth/access_token', 'oauth_token=token&oauth_verifier=verifier')
|
||||
.once()
|
||||
.reply(200, 'access_token=new_token');
|
||||
|
||||
await controller.handleCallback(req, res);
|
||||
|
||||
const dataCaptor = captor();
|
||||
expect(credentialsRepository.update).toHaveBeenCalledWith(
|
||||
'1',
|
||||
|
||||
Reference in New Issue
Block a user