Skip to content

Commit

Permalink
Fix test expectation
Browse files Browse the repository at this point in the history
  • Loading branch information
3link committed May 3, 2024
1 parent 4ebdfd9 commit 5224b3e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions test/spec/modules/liveIntentIdSystem_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,8 @@ describe('LiveIntentId', function() {
liveIntentIdSubmodule.getId({ params: defaultConfigParams });
liveIntentIdSubmodule.decode({}, { params: defaultConfigParams });
setTimeout(() => {
expect(server.requests.length).to.be.eq(1);
const requests = server.requests.filter((r) => r.url.match(/https:\/\/rp.liadm.com.*/));
expect(requests.length).to.be.eq(1);
done();
}, 300);
});
Expand Down Expand Up @@ -287,7 +288,7 @@ describe('LiveIntentId', function() {
let submoduleCallback = liveIntentIdSubmodule.getId({ params: defaultConfigParams }).callback;
submoduleCallback(callBackSpy);
let request = server.requests[0];
var expected = new RegExp('https:\/\/idx.liadm.com\/idex\/prebid\/89899\?.*duid=' + oldCookie + '.*&cd=.localhost.*&resolve=nonId.*');
const expected = new RegExp('https:\/\/idx.liadm.com\/idex\/prebid\/89899\?.*duid=' + oldCookie + '.*&cd=.localhost.*&resolve=nonId.*');
expect(request.url).to.match(expected);
request.respond(
200,
Expand All @@ -311,7 +312,7 @@ describe('LiveIntentId', function() {
let submoduleCallback = liveIntentIdSubmodule.getId(configParams).callback;
submoduleCallback(callBackSpy);
let request = server.requests[0];
var expected = new RegExp('https:\/\/idx.liadm.com\/idex\/prebid\/89899\?.*duid=' + oldCookie + '.*&cd=.localhost.*&_thirdPC=third-pc.*&resolve=nonId.*');
const expected = new RegExp('https:\/\/idx.liadm.com\/idex\/prebid\/89899\?.*duid=' + oldCookie + '.*&cd=.localhost.*&_thirdPC=third-pc.*&resolve=nonId.*');
expect(request.url).to.match(expected);
request.respond(
200,
Expand Down

0 comments on commit 5224b3e

Please sign in to comment.