mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 02:21:13 +00:00
test(YouTube Node): Add tests for YouTube Node (#14459)
Co-authored-by: Roman Davydchuk <roman.davydchuk@n8n.io>
This commit is contained in:
@@ -213,6 +213,25 @@ BQIDAQAB
|
||||
expires_in: 86400,
|
||||
},
|
||||
},
|
||||
youTubeOAuth2Api: {
|
||||
grantType: 'authorizationCode',
|
||||
authUrl: 'https://accounts.google.com/o/oauth2/v2/auth',
|
||||
accessTokenUrl: 'https://oauth2.googleapis.com/token',
|
||||
clientId: 'CLIENTID',
|
||||
clientSecret: 'CLIENTSECRET',
|
||||
scope:
|
||||
'https://www.googleapis.com/auth/youtube https://www.googleapis.com/auth/youtubepartner https://www.googleapis.com/auth/youtube.force-ssl https://www.googleapis.com/auth/youtube.upload https://www.googleapis.com/auth/youtubepartner-channel-audit',
|
||||
authQueryParameters: 'access_type=offline&prompt=consent',
|
||||
authentication: 'body',
|
||||
oauthTokenData: {
|
||||
access_token: 'ACCESSTOKEN',
|
||||
refresh_token: 'REFRESHTOKEN',
|
||||
scope:
|
||||
'https://www.googleapis.com/auth/youtube https://www.googleapis.com/auth/youtubepartner https://www.googleapis.com/auth/youtube.force-ssl https://www.googleapis.com/auth/youtube.upload https://www.googleapis.com/auth/youtubepartner-channel-audit',
|
||||
token_type: 'bearer',
|
||||
expires_in: 86400,
|
||||
},
|
||||
},
|
||||
notionApi: {
|
||||
apiKey: 'key123',
|
||||
},
|
||||
|
||||
@@ -98,7 +98,7 @@ export const equalityTest = async (testData: WorkflowTestData) => {
|
||||
}
|
||||
|
||||
// Convert errors to JSON so tests can compare
|
||||
if (json.error instanceof Error) {
|
||||
if (json?.error instanceof Error) {
|
||||
json.error = JSON.parse(
|
||||
JSON.stringify(json.error, ['message', 'name', 'description', 'context']),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user