Skip to content

Commit

Permalink
fix: editing test caes
Browse files Browse the repository at this point in the history
  • Loading branch information
shrouti1507 committed Aug 20, 2024
1 parent 2cdc522 commit c0cb321
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 33 deletions.
6 changes: 2 additions & 4 deletions test/integrations/destinations/smartly/processor/track.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
const moment = require('moment');
import { verifyAdInteractionTime } from '../../../../../src/cdk/v2/destinations/smartly/utils';
import { destination } from '../commonConfig';

export const trackTestData = [
Expand All @@ -19,7 +17,7 @@ export const trackTestData = [
properties: {
platform: 'meta',
ad_unit_id: '228287',
ad_interaction_time: '1612137600',
ad_interaction_time: 1612137600,
email: '[email protected]',
},
type: 'track',
Expand Down Expand Up @@ -53,7 +51,7 @@ export const trackTestData = [
JSON: {
platform: 'meta',
ad_unit_id: '228287',
ad_interaction_time: '1612137600',
ad_interaction_time: 1612137600,
conversions: '1',
event_name: 'Add to cart',
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ export const validationFailures = [
properties: {
platform: 'snapchat',
ad_unit_id: '2653387',
ad_interaction_time: '1675094400',
ad_interaction_time: 1675094400,
},
anonymousId: 'anon_123',
integrations: {
Expand Down
56 changes: 28 additions & 28 deletions test/integrations/destinations/smartly/router/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ export const data = [
properties: {
platform: 'meta',
conversions: 1,
ad_unit_id: "221187",
ad_interaction_time: '1690867200',
ad_unit_id: '221187',
ad_interaction_time: 1690867200,
},
},
metadata: { jobId: 2, userId: 'u2' },
Expand All @@ -36,8 +36,8 @@ export const data = [
properties: {
conversions: 3,
platform: 'snapchat',
ad_unit_id: "77187",
ad_interaction_time: '1690867200',
ad_unit_id: '77187',
ad_interaction_time: 1690867200,
},
},
metadata: { jobId: 3, userId: 'u3' },
Expand All @@ -61,23 +61,23 @@ export const data = [
events: [
{
conversions: 1,
ad_unit_id: "221187",
ad_unit_id: '221187',
platform: 'meta',
ad_interaction_time: '1690867200',
ad_interaction_time: 1690867200,
event_name: 'event1',
},
{
conversions: 1,
ad_unit_id: "221187",
ad_unit_id: '221187',
platform: 'meta',
ad_interaction_time: '1690867200',
ad_interaction_time: 1690867200,
event_name: 'event2',
},
{
conversions: 3,
ad_unit_id: "77187",
ad_unit_id: '77187',
platform: 'snapchat',
ad_interaction_time: '1690867200',
ad_interaction_time: 1690867200,
event_name: 'add to cart',
},
],
Expand Down Expand Up @@ -136,8 +136,8 @@ export const data = [
properties: {
platform: 'meta',
conversions: 1,
ad_unit_id: "221187",
ad_interaction_time: '1690867200',
ad_unit_id: '221187',
ad_interaction_time: 1690867200,
},
},
metadata: { jobId: 11, userId: 'u1' },
Expand All @@ -152,8 +152,8 @@ export const data = [
properties: {
conversions: 3,
platform: 'snapchat',
ad_unit_id: "77187",
ad_interaction_time: '1690867200',
ad_unit_id: '77187',
ad_interaction_time: 1690867200,
},
},
metadata: { jobId: 13, userId: 'u1' },
Expand All @@ -167,8 +167,8 @@ export const data = [
properties: {
conversions: 3,
platform: 'snapchat',
ad_unit_id: "12387",
ad_interaction_time: '1690867200',
ad_unit_id: '12387',
ad_interaction_time: 1690867200,
},
},
metadata: { jobId: 14, userId: 'u1' },
Expand All @@ -182,8 +182,8 @@ export const data = [
integrations: { All: true },
properties: {
conversions: 3,
ad_unit_id: "77187",
ad_interaction_time: '1690867200',
ad_unit_id: '77187',
ad_interaction_time: 1690867200,
},
},
metadata: { jobId: 15, userId: 'u1' },
Expand All @@ -198,8 +198,8 @@ export const data = [
properties: {
conversions: 3,
platform: 'tiktok',
ad_unit_id: "789187",
ad_interaction_time: '1690867200',
ad_unit_id: '789187',
ad_interaction_time: 1690867200,
},
},
metadata: { jobId: 16, userId: 'u1' },
Expand Down Expand Up @@ -247,15 +247,15 @@ export const data = [
platform: 'meta',
conversions: 1,
event_name: 'event1',
ad_unit_id: "221187",
ad_interaction_time: '1690867200',
ad_unit_id: '221187',
ad_interaction_time: 1690867200,
},
{
platform: 'meta',
conversions: 1,
event_name: 'event2',
ad_unit_id: "221187",
ad_interaction_time: '1690867200',
ad_unit_id: '221187',
ad_interaction_time: 1690867200,
},
],
},
Expand Down Expand Up @@ -288,15 +288,15 @@ export const data = [
conversions: 3,
event_name: 'purchase',
platform: 'snapchat',
ad_unit_id: "77187",
ad_interaction_time: '1690867200',
ad_unit_id: '77187',
ad_interaction_time: 1690867200,
},
{
conversions: 3,
event_name: 'add to cart',
platform: 'tiktok',
ad_unit_id: "789187",
ad_interaction_time: '1690867200',
ad_unit_id: '789187',
ad_interaction_time: 1690867200,
},
],
},
Expand Down

0 comments on commit c0cb321

Please sign in to comment.