Skip to content

Commit

Permalink
chore: tc corrections
Browse files Browse the repository at this point in the history
  • Loading branch information
Chandra shekar Varkala committed Jan 11, 2024
1 parent fcad73e commit b4bdba2
Show file tree
Hide file tree
Showing 136 changed files with 53,802 additions and 65,159 deletions.
136 changes: 28 additions & 108 deletions test/integrations/destinations/active_campaign/router/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@ export const data = [
eventKey: 'f8a866fddc721350fdc2fbbd2e5c43a6dddaaa03',
},
},
metadata: {
jobId: 2,
},
metadata: { jobId: 2, userId: 'u1' },
message: {
channel: 'web',
context: {
Expand All @@ -30,21 +28,13 @@ export const data = [
namespace: 'com.rudderlabs.javascript',
version: '1.0.0',
},
library: {
name: 'RudderLabs JavaScript SDK',
version: '1.0.0',
},
library: { name: 'RudderLabs JavaScript SDK', version: '1.0.0' },
userAgent:
'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36',
locale: 'en-US',
ip: '0.0.0.0',
os: {
name: '',
version: '',
},
screen: {
density: 2,
},
os: { name: '', version: '' },
screen: { density: 2 },
},
messageId: '84e26acc-56a5-4835-8233-591137fca468',
session_id: '3049dc4c-5a95-4ccd-a3e7-d74a7e411f22',
Expand All @@ -66,18 +56,9 @@ export const data = [
Random: 'random',
},
lists: [
{
id: 2,
status: 'subscribe',
},
{
id: 3,
status: 'unsubscribe',
},
{
id: 3,
status: 'unsubscribexyz',
},
{ id: 2, status: 'subscribe' },
{ id: 3, status: 'unsubscribe' },
{ id: 3, status: 'unsubscribexyz' },
],
address: {
city: 'kolkata',
Expand All @@ -87,9 +68,7 @@ export const data = [
street: '',
},
},
integrations: {
All: true,
},
integrations: { All: true },
sentAt: '2019-10-14T09:03:22.563Z',
},
},
Expand Down Expand Up @@ -117,22 +96,10 @@ export const data = [
lastName: 'Doe',
phone: '92374162212',
fieldValues: [
{
field: '0',
value: 'Trastkiv',
},
{
field: '1',
value: 'Russia',
},
{
field: '3',
value: '||Potato||Onion||',
},
{
field: '4',
value: 'random',
},
{ field: '0', value: 'Trastkiv' },
{ field: '1', value: 'Russia' },
{ field: '3', value: '||Potato||Onion||' },
{ field: '4', value: 'random' },
],
},
},
Expand All @@ -141,18 +108,11 @@ export const data = [
files: {},
method: 'POST',
params: {},
headers: {
'Api-Token': 'dummyApiToken',
'Content-Type': 'application/json',
},
headers: { 'Api-Token': 'dummyApiToken', 'Content-Type': 'application/json' },
version: '1',
endpoint: 'https://active.campaigns.rudder.com/api/3/contact/sync',
},
metadata: [
{
jobId: 2,
},
],
metadata: [{ jobId: 2, userId: 'u1' }],
batched: false,
statusCode: 200,
destination: {
Expand Down Expand Up @@ -188,9 +148,7 @@ export const data = [
eventKey: 'f8a866fddc721350fdc2fbbd2e5c43a6dddaaa03',
},
},
metadata: {
jobId: 2,
},
metadata: { jobId: 2, userId: 'u1' },
message: {
channel: 'web',
context: {
Expand All @@ -200,24 +158,13 @@ export const data = [
namespace: 'com.rudderlabs.javascript',
version: '1.0.0',
},
traits: {
email: '[email protected]',
anonymousId: '12345',
},
library: {
name: 'RudderLabs JavaScript SDK',
version: '1.0.0',
},
traits: { email: '[email protected]', anonymousId: '12345' },
library: { name: 'RudderLabs JavaScript SDK', version: '1.0.0' },
userAgent:
'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36',
locale: 'en-US',
os: {
name: '',
version: '',
},
screen: {
density: 2,
},
os: { name: '', version: '' },
screen: { density: 2 },
},
request_ip: '1.1.1.1',
type: 'page',
Expand All @@ -234,9 +181,7 @@ export const data = [
title: 'Test Page',
url: 'https://www.rudderlabs.com',
},
integrations: {
All: true,
},
integrations: { All: true },
sentAt: '2019-10-14T11:15:53.296Z',
},
},
Expand All @@ -257,28 +202,17 @@ export const data = [
XML: {},
FORM: {},
JSON_ARRAY: {},
JSON: {
siteTrackingDomain: {
name: 'rudderlabs.com',
},
},
JSON: { siteTrackingDomain: { name: 'rudderlabs.com' } },
},
type: 'REST',
files: {},
method: 'POST',
params: {},
headers: {
'Api-Token': 'dummyApiToken',
'Content-Type': 'application/json',
},
headers: { 'Api-Token': 'dummyApiToken', 'Content-Type': 'application/json' },
version: '1',
endpoint: 'https://active.campaigns.rudder.com/api/3/siteTrackingDomains',
},
metadata: [
{
jobId: 2,
},
],
metadata: [{ jobId: 2, userId: 'u1' }],
batched: false,
statusCode: 200,
destination: {
Expand Down Expand Up @@ -312,10 +246,7 @@ export const data = [
sentAt: '2023-01-10T22:31:10.954Z',
channel: 'web',
context: {
os: {
name: '',
version: '',
},
os: { name: '', version: '' },
app: {
name: 'RudderLabs JavaScript SDK',
build: '1.0.0',
Expand All @@ -342,10 +273,7 @@ export const data = [
innerHeight: 782,
},
traits: {},
library: {
name: 'RudderLabs JavaScript SDK',
version: '2.20.0',
},
library: { name: 'RudderLabs JavaScript SDK', version: '2.20.0' },
campaign: {},
sessionId: 1673389635049,
userAgent:
Expand All @@ -369,9 +297,7 @@ export const data = [
receivedAt: '2023-01-10T22:31:11.612Z',
request_ip: '0.0.0.20',
anonymousId: '878e8f5f-9b6c-4aef-b5d3-1b970a13f17a',
integrations: {
All: true,
},
integrations: { All: true },
originalTimestamp: '2023-01-10T22:31:10.943Z',
},
destination: {
Expand All @@ -382,9 +308,7 @@ export const data = [
eventKey: 'f8a866fddc721350fdc2fbbd2e5c43a6dddaaa03',
},
},
metadata: {
jobId: 5,
},
metadata: { jobId: 5, userId: 'u1' },
},
],
destType: 'active_campaign',
Expand All @@ -408,11 +332,7 @@ export const data = [
module: 'destination',
},
statusCode: 400,
metadata: [
{
jobId: 5,
},
],
metadata: [{ jobId: 5, userId: 'u1' }],
batched: false,
destination: {
Config: {
Expand Down
49 changes: 25 additions & 24 deletions test/integrations/destinations/adj/processor/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2179,7 +2179,8 @@ export const data = [
status: 200,
body: [
{
error: 'App Token is not present. Please configure your app token from config dashbaord',
error:
'App Token is not present. Please configure your app token from config dashbaord',
statTags: {
destType: 'ADJ',
errorCategory: 'dataValidation',
Expand All @@ -2205,24 +2206,24 @@ export const data = [
body: [
{
message: {
"type": "track",
"event": "Application Installed",
"sentAt": "2022-09-28T20:14:44.995Z",
"userId": "sample_user_id",
"context": {
"device": {
"id": "sample_device_id",
"type": "android",
"advertisingId": "_sample"
type: 'track',
event: 'Application Installed',
sentAt: '2022-09-28T20:14:44.995Z',
userId: 'sample_user_id',
context: {
device: {
id: 'sample_device_id',
type: 'android',
advertisingId: '_sample',
},
traits: {
userId: '_sample_uid',
anonymousId: '_sample_anonid',
},
"traits": {
"userId": "_sample_uid",
"anonymousId": "_sample_anonid"
}
},
"timestamp": "2022-09-28T20:14:43.314Z",
"request_ip": "71.189.106.156",
"originalTimestamp": "2022-09-28T20:14:44.995Z"
},
timestamp: '2022-09-28T20:14:43.314Z',
request_ip: '71.189.106.156',
originalTimestamp: '2022-09-28T20:14:44.995Z',
},
destination: {
ID: '1i3Em7GMU9xVEiDlZUN8c88BMS9',
Expand All @@ -2245,8 +2246,7 @@ export const data = [
},
Config: {
appToken: 'testAppToken',
customMappings: [
{ from: 'Application Installed', to: '3fdmll' }],
customMappings: [{ from: 'Application Installed', to: '3fdmll' }],
partnerParamsKeys: [
{ from: 'key1', to: 'partnerParamKey-1' },
{ from: 'key2', to: 'partnerParamKey-2' },
Expand Down Expand Up @@ -2277,10 +2277,10 @@ export const data = [
endpoint: 'https://s2s.adjust.com/event',
headers: { Accept: '*/*' },
params: {
event_token: "3fdmll",
ip_address: "71.189.106.156",
event_token: '3fdmll',
ip_address: '71.189.106.156',
android_id: 'sample_device_id',
gps_adid: "_sample",
gps_adid: '_sample',
s2s: 1,
app_token: 'testAppToken',
environment: 'production',
Expand All @@ -2294,4 +2294,5 @@ export const data = [
],
},
},
},];
},
];
Loading

0 comments on commit b4bdba2

Please sign in to comment.