File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ import { FetchRequest } from '../../../src/common/util/FetchRequest';
44import cipher from 'node-forge/lib/cipher' ;
55import { MapExtend } from '../../../src/mapboxgl/core/MapExtend' ;
66import { decryptSources } from '../../../src/mapboxgl/core/decryptSource' ;
7+ import { EncryptRequest } from '../../../src/common/util/EncryptRequest' ;
78
89describe ( 'getServiceKey' , ( ) => {
910 let originalTimeout ;
@@ -170,6 +171,15 @@ describe('getServiceKey', () => {
170171 } ) ;
171172
172173 it ( 'getServiceKey' , async ( ) => {
174+ EncryptRequest . prototype . request = ( ) => {
175+ return {
176+ json : ( ) =>
177+ new Promise ( ( resolve ) => {
178+ resolve ( 'P8h08GonNjuCB4+CAykAGmLYwNsiv4G6H8KFrFi7Afk=' ) ;
179+ } )
180+ } ;
181+ } ;
182+
173183 try {
174184 const source = {
175185 tiles : [
You can’t perform that action at this time.
0 commit comments