Skip to content

Commit

Permalink
Updated the unit test case for linkedin-conversion (#1785)
Browse files Browse the repository at this point in the history
Co-authored-by: Harsh Vardhan <[email protected]>
  • Loading branch information
hvardhan-unth and Harsh Vardhan authored Jan 3, 2024
1 parent a8a8631 commit c8d0130
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const testDestination = createTestIntegration(Destination)
const event = createTestEvent({
event: 'Example Event',
type: 'track',
timestamp: '1695884800000',
timestamp: `${Date.now()}`,
context: {
traits: {
email: '[email protected]',
Expand Down Expand Up @@ -41,7 +41,7 @@ const event = createTestEvent({
const settings = {}

describe('LinkedinConversions.streamConversion', () => {
xit('should successfully send the event', async () => {
it('should successfully send the event', async () => {
const associateCampignToConversion = {
campaign: 'urn:li:sponsoredCampaign:123456`',
conversion: 'urn:lla:llaPartnerConversion:789123'
Expand All @@ -54,7 +54,7 @@ describe('LinkedinConversions.streamConversion', () => {

const streamConversionEvent = {
conversion: `urn:lla:llaPartnerConversion:${payload.conversionId}`,
conversionHappenedAt: 1698764171467,
conversionHappenedAt: Date.now(),
user: {
userIds: [
{
Expand Down Expand Up @@ -136,11 +136,11 @@ describe('LinkedinConversions.streamConversion', () => {
).rejects.toThrowError('Timestamp should be within the past 90 days.')
})

xit('should throw an error if Either userIds array or userInfo with firstName and lastName is not present.', async () => {
it('should throw an error if Either userIds array or userInfo with firstName and lastName is not present.', async () => {
const event = createTestEvent({
event: 'Example Event',
type: 'track',
timestamp: '1695884800000',
timestamp: `${Date.now()}`,
context: {
traits: {
email: '[email protected]',
Expand Down

0 comments on commit c8d0130

Please sign in to comment.