-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
1 changed file
with
11 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,15 @@ | ||
import { setLibs, getLibs } from '../../acrobat/scripts/utils'; | ||
import * as sinon from 'sinon'; | ||
/* eslint-disable compat/compat */ | ||
import { expect } from '@esm-bundle/chai'; | ||
import { setLibs } from '../../acrobat/scripts/utils.js'; | ||
|
||
describe('Test utils.js', async () => { | ||
it('tests setLibs', async () => { | ||
const libs = setLibs('/lib'); | ||
expect(libs).to.equal('https://main--milo--adobecom.hlx.live/libs'); | ||
describe('Test utils.js', () => { | ||
it('tests setLibs with hlx domain', () => { | ||
const libs = setLibs('/lib', new URL('https://stage--dc--adobecom.hlx.live?milolibs=test')); | ||
expect(libs).to.equal('https://test--milo--adobecom.hlx.live/libs'); | ||
}); | ||
|
||
it('tests setLibs with aem domain', () => { | ||
const libs = setLibs('/lib', new URL('https://stage--dc--adobecom.aem.live?milolibs=test')); | ||
expect(libs).to.equal('https://test--milo--adobecom.aem.live/libs'); | ||
}); | ||
}); |