@dereekb/firebase-server 13.43.0 → 14.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/calcom/index.esm.js +57 -96
- package/calcom/package.json +11 -11
- package/discord/index.esm.js +48 -74
- package/discord/package.json +11 -11
- package/index.esm.js +336 -583
- package/mailgun/index.esm.js +20 -32
- package/mailgun/package.json +9 -9
- package/mcp/index.esm.js +131 -185
- package/mcp/package.json +14 -14
- package/model/index.esm.js +699 -692
- package/model/package.json +14 -14
- package/model/src/lib/formspace/formspace.action.server.d.ts +79 -5
- package/model/src/lib/formspace/formspace.error.d.ts +21 -0
- package/model/src/lib/formspace/formspace.task.service.handler.d.ts +3 -2
- package/model/src/lib/storagefile/storagefile.task.service.handler.d.ts +3 -3
- package/oidc/index.esm.js +144 -251
- package/oidc/package.json +14 -14
- package/package.json +24 -24
- package/src/lib/function/type.d.ts +0 -9
- package/src/lib/nest/app.d.ts +0 -4
- package/src/lib/nest/development/development.app.function.d.ts +2 -2
- package/src/lib/nest/model/analytics.handler.d.ts +0 -8
- package/src/lib/nest/model/api.details.d.ts +0 -8
- package/src/lib/nest/nest.provider.d.ts +0 -8
- package/test/index.esm.js +239 -395
- package/test/package.json +17 -17
- package/test/src/lib/firebase/firebase.admin.auth.d.ts +4 -25
- package/test/src/lib/firebase/firebase.admin.nest.d.ts +0 -4
- package/test/src/lib/firebase/firebase.admin.nest.function.d.ts +7 -7
- package/test/src/lib/firebase/firebase.function.d.ts +20 -81
- package/test/src/lib/firebase/firebase.test.d.ts +0 -9
- package/twilio/index.esm.js +11 -14
- package/twilio/package.json +8 -8
- package/zoho/index.esm.js +72 -132
- package/zoho/package.json +12 -12
- package/zoho/src/lib/zoho.accounts.firebase.system.d.ts +0 -10
package/test/index.esm.js
CHANGED
|
@@ -6,7 +6,6 @@ import admin from 'firebase-admin';
|
|
|
6
6
|
import functions from 'firebase-functions-test';
|
|
7
7
|
import { makeTestingFirestoreDrivers, TestFirestoreInstance, TestFirestoreContextFixture, makeTestingFirebaseStorageDrivers, TestFirebaseStorageInstance, TestFirebaseStorageContextFixture, mockItemFirestoreCollection, testWithMockItemCollectionFixture, testWithMockItemStorageFixture } from '@dereekb/firebase/test';
|
|
8
8
|
import { googleCloudFirestoreDrivers, googleCloudFirebaseStorageDrivers, googleCloudStorageFromFirebaseAdminStorage, GlobalRoutePrefixConfig, buildNestServerRootModule } from '@dereekb/firebase-server';
|
|
9
|
-
export { FirebaseNestServerRootModule as FirebaseAdminNestRootModule } from '@dereekb/firebase-server';
|
|
10
9
|
import { Firestore } from '@google-cloud/firestore';
|
|
11
10
|
import { Storage } from '@google-cloud/storage';
|
|
12
11
|
import { Test } from '@nestjs/testing';
|
|
@@ -17,9 +16,7 @@ import { randomBytes, createHash } from 'node:crypto';
|
|
|
17
16
|
import { OidcClientService, JwksService, OidcAccountService } from '@dereekb/firebase-server/oidc';
|
|
18
17
|
|
|
19
18
|
function _assert_this_initialized$9(self) {
|
|
20
|
-
if (self === void 0)
|
|
21
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
22
|
-
}
|
|
19
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
23
20
|
return self;
|
|
24
21
|
}
|
|
25
22
|
function asyncGeneratorStep$a(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -30,11 +27,8 @@ function asyncGeneratorStep$a(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
30
27
|
reject(error);
|
|
31
28
|
return;
|
|
32
29
|
}
|
|
33
|
-
if (info.done)
|
|
34
|
-
|
|
35
|
-
} else {
|
|
36
|
-
Promise.resolve(value).then(_next, _throw);
|
|
37
|
-
}
|
|
30
|
+
if (info.done) resolve(value);
|
|
31
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
38
32
|
}
|
|
39
33
|
function _async_to_generator$a(fn) {
|
|
40
34
|
return function() {
|
|
@@ -56,9 +50,7 @@ function _call_super$9(_this, derived, args) {
|
|
|
56
50
|
return _possible_constructor_return$9(_this, _is_native_reflect_construct$9() ? Reflect.construct(derived, args || [], _get_prototype_of$9(_this).constructor) : derived.apply(_this, args));
|
|
57
51
|
}
|
|
58
52
|
function _class_call_check$9(instance, Constructor) {
|
|
59
|
-
if (!(instance instanceof Constructor))
|
|
60
|
-
throw new TypeError("Cannot call a class as a function");
|
|
61
|
-
}
|
|
53
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
62
54
|
}
|
|
63
55
|
function _defineProperties$6(target, props) {
|
|
64
56
|
for(var i = 0; i < props.length; i++){
|
|
@@ -81,9 +73,7 @@ function _define_property$9(obj, key, value) {
|
|
|
81
73
|
configurable: true,
|
|
82
74
|
writable: true
|
|
83
75
|
});
|
|
84
|
-
} else
|
|
85
|
-
obj[key] = value;
|
|
86
|
-
}
|
|
76
|
+
} else obj[key] = value;
|
|
87
77
|
return obj;
|
|
88
78
|
}
|
|
89
79
|
function _get_prototype_of$9(o) {
|
|
@@ -105,6 +95,14 @@ function _inherits$9(subClass, superClass) {
|
|
|
105
95
|
});
|
|
106
96
|
if (superClass) _set_prototype_of$9(subClass, superClass);
|
|
107
97
|
}
|
|
98
|
+
function _is_native_reflect_construct$9() {
|
|
99
|
+
try {
|
|
100
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
101
|
+
} catch (_) {}
|
|
102
|
+
return (_is_native_reflect_construct$9 = function() {
|
|
103
|
+
return !!result;
|
|
104
|
+
})();
|
|
105
|
+
}
|
|
108
106
|
function _object_spread$6(target) {
|
|
109
107
|
for(var i = 1; i < arguments.length; i++){
|
|
110
108
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
@@ -130,9 +128,8 @@ function ownKeys$3(object, enumerableOnly) {
|
|
|
130
128
|
}
|
|
131
129
|
function _object_spread_props$3(target, source) {
|
|
132
130
|
source = source != null ? source : {};
|
|
133
|
-
if (Object.getOwnPropertyDescriptors)
|
|
134
|
-
|
|
135
|
-
} else {
|
|
131
|
+
if (Object.getOwnPropertyDescriptors) Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
132
|
+
else {
|
|
136
133
|
ownKeys$3(Object(source)).forEach(function(key) {
|
|
137
134
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
138
135
|
});
|
|
@@ -140,9 +137,7 @@ function _object_spread_props$3(target, source) {
|
|
|
140
137
|
return target;
|
|
141
138
|
}
|
|
142
139
|
function _possible_constructor_return$9(self, call) {
|
|
143
|
-
if (call && (_type_of$9(call) === "object" || typeof call === "function"))
|
|
144
|
-
return call;
|
|
145
|
-
}
|
|
140
|
+
if (call && (_type_of$9(call) === "object" || typeof call === "function")) return call;
|
|
146
141
|
return _assert_this_initialized$9(self);
|
|
147
142
|
}
|
|
148
143
|
function _set_prototype_of$9(o, p) {
|
|
@@ -152,18 +147,6 @@ function _set_prototype_of$9(o, p) {
|
|
|
152
147
|
};
|
|
153
148
|
return _set_prototype_of$9(o, p);
|
|
154
149
|
}
|
|
155
|
-
function _type_of$9(obj) {
|
|
156
|
-
"@swc/helpers - typeof";
|
|
157
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
158
|
-
}
|
|
159
|
-
function _is_native_reflect_construct$9() {
|
|
160
|
-
try {
|
|
161
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
162
|
-
} catch (_) {}
|
|
163
|
-
return (_is_native_reflect_construct$9 = function() {
|
|
164
|
-
return !!result;
|
|
165
|
-
})();
|
|
166
|
-
}
|
|
167
150
|
function _ts_generator$a(thisArg, body) {
|
|
168
151
|
var f, y, t, _ = {
|
|
169
152
|
label: 0,
|
|
@@ -263,6 +246,10 @@ function _ts_generator$a(thisArg, body) {
|
|
|
263
246
|
};
|
|
264
247
|
}
|
|
265
248
|
}
|
|
249
|
+
function _type_of$9(obj) {
|
|
250
|
+
"@swc/helpers - typeof";
|
|
251
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
252
|
+
}
|
|
266
253
|
/**
|
|
267
254
|
* Fixture wrapper for {@link AuthorizedUserTestContextInstance} that delegates all
|
|
268
255
|
* {@link AuthorizedUserTestContext} operations to the underlying instance.
|
|
@@ -511,25 +498,6 @@ function _ts_generator$a(thisArg, body) {
|
|
|
511
498
|
});
|
|
512
499
|
return this.callCloudFunction(fn, event, skipJsonConversion);
|
|
513
500
|
}
|
|
514
|
-
},
|
|
515
|
-
{
|
|
516
|
-
/**
|
|
517
|
-
* @param fn
|
|
518
|
-
* @param params
|
|
519
|
-
* @param contextOptions
|
|
520
|
-
* @param skipJsonConversion
|
|
521
|
-
* @returns
|
|
522
|
-
*
|
|
523
|
-
* @deprecated gen 1
|
|
524
|
-
*/ // eslint-disable-next-line @typescript-eslint/max-params -- deprecated gen 1 signature kept for downstream compatibility
|
|
525
|
-
key: "callEventCloudFunction",
|
|
526
|
-
value: function callEventCloudFunction(fn, params, contextOptions) {
|
|
527
|
-
var skipJsonConversion = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : false;
|
|
528
|
-
var parsedParams = params == null || skipJsonConversion ? params : convertParamsToParsedJsonObjectAndBack(params);
|
|
529
|
-
return this.makeContextOptions().then(function(options) {
|
|
530
|
-
return fn(parsedParams, contextOptions ? _object_spread$6({}, contextOptions, options) : options);
|
|
531
|
-
});
|
|
532
|
-
}
|
|
533
501
|
}
|
|
534
502
|
]);
|
|
535
503
|
return AuthorizedUserTestContextInstance;
|
|
@@ -854,9 +822,7 @@ function _ts_generator$a(thisArg, body) {
|
|
|
854
822
|
}
|
|
855
823
|
|
|
856
824
|
function _assert_this_initialized$8(self) {
|
|
857
|
-
if (self === void 0)
|
|
858
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
859
|
-
}
|
|
825
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
860
826
|
return self;
|
|
861
827
|
}
|
|
862
828
|
function asyncGeneratorStep$9(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -867,11 +833,8 @@ function asyncGeneratorStep$9(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
867
833
|
reject(error);
|
|
868
834
|
return;
|
|
869
835
|
}
|
|
870
|
-
if (info.done)
|
|
871
|
-
|
|
872
|
-
} else {
|
|
873
|
-
Promise.resolve(value).then(_next, _throw);
|
|
874
|
-
}
|
|
836
|
+
if (info.done) resolve(value);
|
|
837
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
875
838
|
}
|
|
876
839
|
function _async_to_generator$9(fn) {
|
|
877
840
|
return function() {
|
|
@@ -893,9 +856,7 @@ function _call_super$8(_this, derived, args) {
|
|
|
893
856
|
return _possible_constructor_return$8(_this, _is_native_reflect_construct$8() ? Reflect.construct(derived, args || [], _get_prototype_of$8(_this).constructor) : derived.apply(_this, args));
|
|
894
857
|
}
|
|
895
858
|
function _class_call_check$8(instance, Constructor) {
|
|
896
|
-
if (!(instance instanceof Constructor))
|
|
897
|
-
throw new TypeError("Cannot call a class as a function");
|
|
898
|
-
}
|
|
859
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
899
860
|
}
|
|
900
861
|
function _defineProperties$5(target, props) {
|
|
901
862
|
for(var i = 0; i < props.length; i++){
|
|
@@ -918,9 +879,7 @@ function _define_property$8(obj, key, value) {
|
|
|
918
879
|
configurable: true,
|
|
919
880
|
writable: true
|
|
920
881
|
});
|
|
921
|
-
} else
|
|
922
|
-
obj[key] = value;
|
|
923
|
-
}
|
|
882
|
+
} else obj[key] = value;
|
|
924
883
|
return obj;
|
|
925
884
|
}
|
|
926
885
|
function _get_prototype_of$8(o) {
|
|
@@ -942,10 +901,16 @@ function _inherits$8(subClass, superClass) {
|
|
|
942
901
|
});
|
|
943
902
|
if (superClass) _set_prototype_of$8(subClass, superClass);
|
|
944
903
|
}
|
|
904
|
+
function _is_native_reflect_construct$8() {
|
|
905
|
+
try {
|
|
906
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
907
|
+
} catch (_) {}
|
|
908
|
+
return (_is_native_reflect_construct$8 = function() {
|
|
909
|
+
return !!result;
|
|
910
|
+
})();
|
|
911
|
+
}
|
|
945
912
|
function _possible_constructor_return$8(self, call) {
|
|
946
|
-
if (call && (_type_of$8(call) === "object" || typeof call === "function"))
|
|
947
|
-
return call;
|
|
948
|
-
}
|
|
913
|
+
if (call && (_type_of$8(call) === "object" || typeof call === "function")) return call;
|
|
949
914
|
return _assert_this_initialized$8(self);
|
|
950
915
|
}
|
|
951
916
|
function _set_prototype_of$8(o, p) {
|
|
@@ -955,18 +920,6 @@ function _set_prototype_of$8(o, p) {
|
|
|
955
920
|
};
|
|
956
921
|
return _set_prototype_of$8(o, p);
|
|
957
922
|
}
|
|
958
|
-
function _type_of$8(obj) {
|
|
959
|
-
"@swc/helpers - typeof";
|
|
960
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
961
|
-
}
|
|
962
|
-
function _is_native_reflect_construct$8() {
|
|
963
|
-
try {
|
|
964
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
965
|
-
} catch (_) {}
|
|
966
|
-
return (_is_native_reflect_construct$8 = function() {
|
|
967
|
-
return !!result;
|
|
968
|
-
})();
|
|
969
|
-
}
|
|
970
923
|
function _ts_generator$9(thisArg, body) {
|
|
971
924
|
var f, y, t, _ = {
|
|
972
925
|
label: 0,
|
|
@@ -1066,6 +1019,10 @@ function _ts_generator$9(thisArg, body) {
|
|
|
1066
1019
|
};
|
|
1067
1020
|
}
|
|
1068
1021
|
}
|
|
1022
|
+
function _type_of$8(obj) {
|
|
1023
|
+
"@swc/helpers - typeof";
|
|
1024
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
1025
|
+
}
|
|
1069
1026
|
/**
|
|
1070
1027
|
* Fixture wrapper for {@link ModelTestContextInstance} that delegates all
|
|
1071
1028
|
* {@link ModelTestContext} operations to the underlying instance.
|
|
@@ -1390,9 +1347,7 @@ var adminEnvironmentInitialized = false;
|
|
|
1390
1347
|
}
|
|
1391
1348
|
|
|
1392
1349
|
function _assert_this_initialized$7(self) {
|
|
1393
|
-
if (self === void 0)
|
|
1394
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1395
|
-
}
|
|
1350
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1396
1351
|
return self;
|
|
1397
1352
|
}
|
|
1398
1353
|
function asyncGeneratorStep$8(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -1403,11 +1358,8 @@ function asyncGeneratorStep$8(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
1403
1358
|
reject(error);
|
|
1404
1359
|
return;
|
|
1405
1360
|
}
|
|
1406
|
-
if (info.done)
|
|
1407
|
-
|
|
1408
|
-
} else {
|
|
1409
|
-
Promise.resolve(value).then(_next, _throw);
|
|
1410
|
-
}
|
|
1361
|
+
if (info.done) resolve(value);
|
|
1362
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
1411
1363
|
}
|
|
1412
1364
|
function _async_to_generator$8(fn) {
|
|
1413
1365
|
return function() {
|
|
@@ -1429,9 +1381,7 @@ function _call_super$7(_this, derived, args) {
|
|
|
1429
1381
|
return _possible_constructor_return$7(_this, _is_native_reflect_construct$7() ? Reflect.construct(derived, args || [], _get_prototype_of$7(_this).constructor) : derived.apply(_this, args));
|
|
1430
1382
|
}
|
|
1431
1383
|
function _class_call_check$7(instance, Constructor) {
|
|
1432
|
-
if (!(instance instanceof Constructor))
|
|
1433
|
-
throw new TypeError("Cannot call a class as a function");
|
|
1434
|
-
}
|
|
1384
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
1435
1385
|
}
|
|
1436
1386
|
function _get_prototype_of$7(o) {
|
|
1437
1387
|
_get_prototype_of$7 = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {
|
|
@@ -1452,10 +1402,16 @@ function _inherits$7(subClass, superClass) {
|
|
|
1452
1402
|
});
|
|
1453
1403
|
if (superClass) _set_prototype_of$7(subClass, superClass);
|
|
1454
1404
|
}
|
|
1405
|
+
function _is_native_reflect_construct$7() {
|
|
1406
|
+
try {
|
|
1407
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
1408
|
+
} catch (_) {}
|
|
1409
|
+
return (_is_native_reflect_construct$7 = function() {
|
|
1410
|
+
return !!result;
|
|
1411
|
+
})();
|
|
1412
|
+
}
|
|
1455
1413
|
function _possible_constructor_return$7(self, call) {
|
|
1456
|
-
if (call && (_type_of$7(call) === "object" || typeof call === "function"))
|
|
1457
|
-
return call;
|
|
1458
|
-
}
|
|
1414
|
+
if (call && (_type_of$7(call) === "object" || typeof call === "function")) return call;
|
|
1459
1415
|
return _assert_this_initialized$7(self);
|
|
1460
1416
|
}
|
|
1461
1417
|
function _set_prototype_of$7(o, p) {
|
|
@@ -1465,18 +1421,6 @@ function _set_prototype_of$7(o, p) {
|
|
|
1465
1421
|
};
|
|
1466
1422
|
return _set_prototype_of$7(o, p);
|
|
1467
1423
|
}
|
|
1468
|
-
function _type_of$7(obj) {
|
|
1469
|
-
"@swc/helpers - typeof";
|
|
1470
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
1471
|
-
}
|
|
1472
|
-
function _is_native_reflect_construct$7() {
|
|
1473
|
-
try {
|
|
1474
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
1475
|
-
} catch (_) {}
|
|
1476
|
-
return (_is_native_reflect_construct$7 = function() {
|
|
1477
|
-
return !!result;
|
|
1478
|
-
})();
|
|
1479
|
-
}
|
|
1480
1424
|
function _ts_generator$8(thisArg, body) {
|
|
1481
1425
|
var f, y, t, _ = {
|
|
1482
1426
|
label: 0,
|
|
@@ -1576,6 +1520,10 @@ function _ts_generator$8(thisArg, body) {
|
|
|
1576
1520
|
};
|
|
1577
1521
|
}
|
|
1578
1522
|
}
|
|
1523
|
+
function _type_of$7(obj) {
|
|
1524
|
+
"@swc/helpers - typeof";
|
|
1525
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
1526
|
+
}
|
|
1579
1527
|
/**
|
|
1580
1528
|
* Creates a {@link TestFirestoreContext} wired to a `@google-cloud/firestore` {@link Firestore} instance.
|
|
1581
1529
|
*
|
|
@@ -1679,9 +1627,7 @@ var COUNTER$1 = 0;
|
|
|
1679
1627
|
});
|
|
1680
1628
|
|
|
1681
1629
|
function _assert_this_initialized$6(self) {
|
|
1682
|
-
if (self === void 0)
|
|
1683
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1684
|
-
}
|
|
1630
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1685
1631
|
return self;
|
|
1686
1632
|
}
|
|
1687
1633
|
function asyncGeneratorStep$7(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -1692,11 +1638,8 @@ function asyncGeneratorStep$7(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
1692
1638
|
reject(error);
|
|
1693
1639
|
return;
|
|
1694
1640
|
}
|
|
1695
|
-
if (info.done)
|
|
1696
|
-
|
|
1697
|
-
} else {
|
|
1698
|
-
Promise.resolve(value).then(_next, _throw);
|
|
1699
|
-
}
|
|
1641
|
+
if (info.done) resolve(value);
|
|
1642
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
1700
1643
|
}
|
|
1701
1644
|
function _async_to_generator$7(fn) {
|
|
1702
1645
|
return function() {
|
|
@@ -1718,9 +1661,7 @@ function _call_super$6(_this, derived, args) {
|
|
|
1718
1661
|
return _possible_constructor_return$6(_this, _is_native_reflect_construct$6() ? Reflect.construct(derived, args || [], _get_prototype_of$6(_this).constructor) : derived.apply(_this, args));
|
|
1719
1662
|
}
|
|
1720
1663
|
function _class_call_check$6(instance, Constructor) {
|
|
1721
|
-
if (!(instance instanceof Constructor))
|
|
1722
|
-
throw new TypeError("Cannot call a class as a function");
|
|
1723
|
-
}
|
|
1664
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
1724
1665
|
}
|
|
1725
1666
|
function _get_prototype_of$6(o) {
|
|
1726
1667
|
_get_prototype_of$6 = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {
|
|
@@ -1741,10 +1682,16 @@ function _inherits$6(subClass, superClass) {
|
|
|
1741
1682
|
});
|
|
1742
1683
|
if (superClass) _set_prototype_of$6(subClass, superClass);
|
|
1743
1684
|
}
|
|
1685
|
+
function _is_native_reflect_construct$6() {
|
|
1686
|
+
try {
|
|
1687
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
1688
|
+
} catch (_) {}
|
|
1689
|
+
return (_is_native_reflect_construct$6 = function() {
|
|
1690
|
+
return !!result;
|
|
1691
|
+
})();
|
|
1692
|
+
}
|
|
1744
1693
|
function _possible_constructor_return$6(self, call) {
|
|
1745
|
-
if (call && (_type_of$6(call) === "object" || typeof call === "function"))
|
|
1746
|
-
return call;
|
|
1747
|
-
}
|
|
1694
|
+
if (call && (_type_of$6(call) === "object" || typeof call === "function")) return call;
|
|
1748
1695
|
return _assert_this_initialized$6(self);
|
|
1749
1696
|
}
|
|
1750
1697
|
function _set_prototype_of$6(o, p) {
|
|
@@ -1754,18 +1701,6 @@ function _set_prototype_of$6(o, p) {
|
|
|
1754
1701
|
};
|
|
1755
1702
|
return _set_prototype_of$6(o, p);
|
|
1756
1703
|
}
|
|
1757
|
-
function _type_of$6(obj) {
|
|
1758
|
-
"@swc/helpers - typeof";
|
|
1759
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
1760
|
-
}
|
|
1761
|
-
function _is_native_reflect_construct$6() {
|
|
1762
|
-
try {
|
|
1763
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
1764
|
-
} catch (_) {}
|
|
1765
|
-
return (_is_native_reflect_construct$6 = function() {
|
|
1766
|
-
return !!result;
|
|
1767
|
-
})();
|
|
1768
|
-
}
|
|
1769
1704
|
function _ts_generator$7(thisArg, body) {
|
|
1770
1705
|
var f, y, t, _ = {
|
|
1771
1706
|
label: 0,
|
|
@@ -1865,6 +1800,10 @@ function _ts_generator$7(thisArg, body) {
|
|
|
1865
1800
|
};
|
|
1866
1801
|
}
|
|
1867
1802
|
}
|
|
1803
|
+
function _type_of$6(obj) {
|
|
1804
|
+
"@swc/helpers - typeof";
|
|
1805
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
1806
|
+
}
|
|
1868
1807
|
/**
|
|
1869
1808
|
* Creates a {@link TestFirebaseStorageContext} wired to a `@google-cloud/storage` instance.
|
|
1870
1809
|
*
|
|
@@ -1964,9 +1903,7 @@ var COUNTER = 0;
|
|
|
1964
1903
|
});
|
|
1965
1904
|
|
|
1966
1905
|
function _assert_this_initialized$5(self) {
|
|
1967
|
-
if (self === void 0)
|
|
1968
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1969
|
-
}
|
|
1906
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
1970
1907
|
return self;
|
|
1971
1908
|
}
|
|
1972
1909
|
function asyncGeneratorStep$6(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -1977,11 +1914,8 @@ function asyncGeneratorStep$6(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
1977
1914
|
reject(error);
|
|
1978
1915
|
return;
|
|
1979
1916
|
}
|
|
1980
|
-
if (info.done)
|
|
1981
|
-
|
|
1982
|
-
} else {
|
|
1983
|
-
Promise.resolve(value).then(_next, _throw);
|
|
1984
|
-
}
|
|
1917
|
+
if (info.done) resolve(value);
|
|
1918
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
1985
1919
|
}
|
|
1986
1920
|
function _async_to_generator$6(fn) {
|
|
1987
1921
|
return function() {
|
|
@@ -2003,9 +1937,7 @@ function _call_super$5(_this, derived, args) {
|
|
|
2003
1937
|
return _possible_constructor_return$5(_this, _is_native_reflect_construct$5() ? Reflect.construct(derived, args || [], _get_prototype_of$5(_this).constructor) : derived.apply(_this, args));
|
|
2004
1938
|
}
|
|
2005
1939
|
function _class_call_check$5(instance, Constructor) {
|
|
2006
|
-
if (!(instance instanceof Constructor))
|
|
2007
|
-
throw new TypeError("Cannot call a class as a function");
|
|
2008
|
-
}
|
|
1940
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
2009
1941
|
}
|
|
2010
1942
|
function _defineProperties$4(target, props) {
|
|
2011
1943
|
for(var i = 0; i < props.length; i++){
|
|
@@ -2028,9 +1960,7 @@ function _define_property$7(obj, key, value) {
|
|
|
2028
1960
|
configurable: true,
|
|
2029
1961
|
writable: true
|
|
2030
1962
|
});
|
|
2031
|
-
} else
|
|
2032
|
-
obj[key] = value;
|
|
2033
|
-
}
|
|
1963
|
+
} else obj[key] = value;
|
|
2034
1964
|
return obj;
|
|
2035
1965
|
}
|
|
2036
1966
|
function _get_prototype_of$5(o) {
|
|
@@ -2052,6 +1982,14 @@ function _inherits$5(subClass, superClass) {
|
|
|
2052
1982
|
});
|
|
2053
1983
|
if (superClass) _set_prototype_of$5(subClass, superClass);
|
|
2054
1984
|
}
|
|
1985
|
+
function _is_native_reflect_construct$5() {
|
|
1986
|
+
try {
|
|
1987
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
1988
|
+
} catch (_) {}
|
|
1989
|
+
return (_is_native_reflect_construct$5 = function() {
|
|
1990
|
+
return !!result;
|
|
1991
|
+
})();
|
|
1992
|
+
}
|
|
2055
1993
|
function _object_spread$5(target) {
|
|
2056
1994
|
for(var i = 1; i < arguments.length; i++){
|
|
2057
1995
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
@@ -2068,9 +2006,7 @@ function _object_spread$5(target) {
|
|
|
2068
2006
|
return target;
|
|
2069
2007
|
}
|
|
2070
2008
|
function _possible_constructor_return$5(self, call) {
|
|
2071
|
-
if (call && (_type_of$5(call) === "object" || typeof call === "function"))
|
|
2072
|
-
return call;
|
|
2073
|
-
}
|
|
2009
|
+
if (call && (_type_of$5(call) === "object" || typeof call === "function")) return call;
|
|
2074
2010
|
return _assert_this_initialized$5(self);
|
|
2075
2011
|
}
|
|
2076
2012
|
function _set_prototype_of$5(o, p) {
|
|
@@ -2080,18 +2016,6 @@ function _set_prototype_of$5(o, p) {
|
|
|
2080
2016
|
};
|
|
2081
2017
|
return _set_prototype_of$5(o, p);
|
|
2082
2018
|
}
|
|
2083
|
-
function _type_of$5(obj) {
|
|
2084
|
-
"@swc/helpers - typeof";
|
|
2085
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
2086
|
-
}
|
|
2087
|
-
function _is_native_reflect_construct$5() {
|
|
2088
|
-
try {
|
|
2089
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
2090
|
-
} catch (_) {}
|
|
2091
|
-
return (_is_native_reflect_construct$5 = function() {
|
|
2092
|
-
return !!result;
|
|
2093
|
-
})();
|
|
2094
|
-
}
|
|
2095
2019
|
function _ts_generator$6(thisArg, body) {
|
|
2096
2020
|
var f, y, t, _ = {
|
|
2097
2021
|
label: 0,
|
|
@@ -2191,6 +2115,10 @@ function _ts_generator$6(thisArg, body) {
|
|
|
2191
2115
|
};
|
|
2192
2116
|
}
|
|
2193
2117
|
}
|
|
2118
|
+
function _type_of$5(obj) {
|
|
2119
|
+
"@swc/helpers - typeof";
|
|
2120
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
2121
|
+
}
|
|
2194
2122
|
/**
|
|
2195
2123
|
* Test fixture that implements {@link FirebaseAdminTestContext} by forwarding all property access
|
|
2196
2124
|
* to the underlying {@link FirebaseAdminTestContextInstance}.
|
|
@@ -2526,11 +2454,8 @@ function asyncGeneratorStep$5(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
2526
2454
|
reject(error);
|
|
2527
2455
|
return;
|
|
2528
2456
|
}
|
|
2529
|
-
if (info.done)
|
|
2530
|
-
|
|
2531
|
-
} else {
|
|
2532
|
-
Promise.resolve(value).then(_next, _throw);
|
|
2533
|
-
}
|
|
2457
|
+
if (info.done) resolve(value);
|
|
2458
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
2534
2459
|
}
|
|
2535
2460
|
function _async_to_generator$5(fn) {
|
|
2536
2461
|
return function() {
|
|
@@ -2555,9 +2480,7 @@ function _define_property$6(obj, key, value) {
|
|
|
2555
2480
|
configurable: true,
|
|
2556
2481
|
writable: true
|
|
2557
2482
|
});
|
|
2558
|
-
} else
|
|
2559
|
-
obj[key] = value;
|
|
2560
|
-
}
|
|
2483
|
+
} else obj[key] = value;
|
|
2561
2484
|
return obj;
|
|
2562
2485
|
}
|
|
2563
2486
|
function _object_spread$4(target) {
|
|
@@ -2585,9 +2508,8 @@ function ownKeys$2(object, enumerableOnly) {
|
|
|
2585
2508
|
}
|
|
2586
2509
|
function _object_spread_props$2(target, source) {
|
|
2587
2510
|
source = source != null ? source : {};
|
|
2588
|
-
if (Object.getOwnPropertyDescriptors)
|
|
2589
|
-
|
|
2590
|
-
} else {
|
|
2511
|
+
if (Object.getOwnPropertyDescriptors) Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
2512
|
+
else {
|
|
2591
2513
|
ownKeys$2(Object(source)).forEach(function(key) {
|
|
2592
2514
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
2593
2515
|
});
|
|
@@ -2696,12 +2618,12 @@ function _ts_generator$5(thisArg, body) {
|
|
|
2696
2618
|
/**
|
|
2697
2619
|
* Creates a {@link FirebaseAdminCloudFunctionWrapper} from a `firebase-functions-test` {@link FeaturesList} instance.
|
|
2698
2620
|
*
|
|
2699
|
-
* The returned wrapper provides methods to wrap gen
|
|
2700
|
-
*
|
|
2701
|
-
*
|
|
2621
|
+
* The returned wrapper provides methods to wrap gen 2 cloud functions, callable requests, and
|
|
2622
|
+
* blocking functions for use in integration tests. Each method delegates to the underlying
|
|
2623
|
+
* `FeaturesList.wrap()` with appropriate type coercion.
|
|
2702
2624
|
*
|
|
2703
2625
|
* @param instance - The initialized `firebase-functions-test` features list whose `wrap()` is delegated to.
|
|
2704
|
-
* @returns A wrapper object exposing typed `wrap*` helpers for gen
|
|
2626
|
+
* @returns A wrapper object exposing typed `wrap*` helpers for gen 2, callable, and blocking functions.
|
|
2705
2627
|
*
|
|
2706
2628
|
* @example
|
|
2707
2629
|
* ```ts
|
|
@@ -2711,9 +2633,6 @@ function _ts_generator$5(thisArg, body) {
|
|
|
2711
2633
|
* const result = await wrapped({ foo: 'bar' }, { auth: { uid: 'test-user' } });
|
|
2712
2634
|
* ```
|
|
2713
2635
|
*/ function firebaseAdminCloudFunctionWrapper(instance) {
|
|
2714
|
-
var wrapV1CloudFunction = function wrapV1CloudFunction(x) {
|
|
2715
|
-
return instance.wrap(x);
|
|
2716
|
-
};
|
|
2717
2636
|
var wrapV2CallableRequest = function wrapV2CallableRequest(x) {
|
|
2718
2637
|
var wrappedCloudFunction = instance.wrap(x);
|
|
2719
2638
|
// context is marked optional here to better match the gen 1 callable function signature
|
|
@@ -2745,7 +2664,6 @@ function _ts_generator$5(thisArg, body) {
|
|
|
2745
2664
|
return instance.wrap(x);
|
|
2746
2665
|
};
|
|
2747
2666
|
var wrapper = {
|
|
2748
|
-
wrapV1CloudFunction: wrapV1CloudFunction,
|
|
2749
2667
|
wrapV2CloudFunction: wrapV2CloudFunction,
|
|
2750
2668
|
wrapV2CallableRequest: wrapV2CallableRequest,
|
|
2751
2669
|
wrapCallableRequest: wrapV2CallableRequest,
|
|
@@ -2755,52 +2673,49 @@ function _ts_generator$5(thisArg, body) {
|
|
|
2755
2673
|
return wrapper;
|
|
2756
2674
|
}
|
|
2757
2675
|
/**
|
|
2758
|
-
* Creates a lazy getter that wraps a
|
|
2676
|
+
* Creates a lazy getter that wraps a cloud function for testing using the unified
|
|
2677
|
+
* {@link WrapCloudFunction} interface.
|
|
2759
2678
|
*
|
|
2760
|
-
*
|
|
2761
|
-
*
|
|
2679
|
+
* This is the most general wrapper — use it when you do not need to distinguish between
|
|
2680
|
+
* cloud functions and blocking functions in your test setup.
|
|
2762
2681
|
*
|
|
2763
|
-
* @param wrapper - The cloud function wrapper providing the `
|
|
2764
|
-
* @param getter - Lazy accessor for the
|
|
2765
|
-
* @returns A getter that, when invoked, returns a freshly wrapped
|
|
2682
|
+
* @param wrapper - The cloud function wrapper providing the unified `wrapCloudFunction` accessor.
|
|
2683
|
+
* @param getter - Lazy accessor for the cloud function under test; re-evaluated on every getter call.
|
|
2684
|
+
* @returns A getter that, when invoked, returns a freshly wrapped cloud function exposing the unified `WrappedCloudFunction` signature.
|
|
2766
2685
|
*
|
|
2767
2686
|
* @example
|
|
2768
2687
|
* ```ts
|
|
2769
|
-
* const getWrapped =
|
|
2770
|
-
* const result = await getWrapped()(
|
|
2688
|
+
* const getWrapped = wrapCloudFunctionTests(wrapper, () => myFunction);
|
|
2689
|
+
* const result = await getWrapped()(eventInput);
|
|
2771
2690
|
* ```
|
|
2772
|
-
*/ function
|
|
2691
|
+
*/ function wrapCloudFunctionTests(wrapper, getter) {
|
|
2773
2692
|
return function() {
|
|
2774
|
-
return wrapper.
|
|
2693
|
+
return wrapper.wrapCloudFunction(getter());
|
|
2775
2694
|
};
|
|
2776
2695
|
}
|
|
2777
2696
|
/**
|
|
2778
|
-
* Creates a lazy getter that wraps a
|
|
2779
|
-
*
|
|
2780
|
-
* The returned getter re-wraps on every invocation, so it always reflects the latest function
|
|
2781
|
-
* reference from the provided getter — useful when the function under test is re-created between tests.
|
|
2697
|
+
* Creates a lazy getter that wraps a {@link CallableHttpFunction} for testing each time it is called.
|
|
2782
2698
|
*
|
|
2783
|
-
*
|
|
2784
|
-
*
|
|
2785
|
-
* @returns A getter that, when invoked, returns a freshly wrapped gen 1 cloud function ready for invocation in tests.
|
|
2699
|
+
* The wrapped callable accepts raw data and {@link CallableContextOptions} (e.g., auth context),
|
|
2700
|
+
* simulating an incoming HTTP callable request without needing a running server.
|
|
2786
2701
|
*
|
|
2787
|
-
* @
|
|
2702
|
+
* @param wrapper - The cloud function wrapper providing the `wrapCallableRequest` accessor.
|
|
2703
|
+
* @param getter - Lazy accessor for the {@link CallableHttpFunction} under test; re-evaluated on every getter call.
|
|
2704
|
+
* @returns A getter that, when invoked, returns a freshly wrapped callable that accepts raw `data` and {@link CallableContextOptions}.
|
|
2788
2705
|
*
|
|
2789
2706
|
* @example
|
|
2790
2707
|
* ```ts
|
|
2791
|
-
* const getWrapped =
|
|
2792
|
-
* const result = await getWrapped()({
|
|
2708
|
+
* const getWrapped = wrapCallableRequestForTests(wrapper, () => myCallable);
|
|
2709
|
+
* const result = await getWrapped()({ input: 'value' }, { auth: { uid: 'user-1' } });
|
|
2793
2710
|
* ```
|
|
2794
|
-
*/ function
|
|
2711
|
+
*/ function wrapCallableRequestForTests(wrapper, getter) {
|
|
2795
2712
|
return function() {
|
|
2796
|
-
return wrapper.
|
|
2713
|
+
return wrapper.wrapCallableRequest(getter());
|
|
2797
2714
|
};
|
|
2798
2715
|
}
|
|
2799
2716
|
|
|
2800
2717
|
function _assert_this_initialized$4(self) {
|
|
2801
|
-
if (self === void 0)
|
|
2802
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
2803
|
-
}
|
|
2718
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
2804
2719
|
return self;
|
|
2805
2720
|
}
|
|
2806
2721
|
function asyncGeneratorStep$4(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -2811,11 +2726,8 @@ function asyncGeneratorStep$4(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
2811
2726
|
reject(error);
|
|
2812
2727
|
return;
|
|
2813
2728
|
}
|
|
2814
|
-
if (info.done)
|
|
2815
|
-
|
|
2816
|
-
} else {
|
|
2817
|
-
Promise.resolve(value).then(_next, _throw);
|
|
2818
|
-
}
|
|
2729
|
+
if (info.done) resolve(value);
|
|
2730
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
2819
2731
|
}
|
|
2820
2732
|
function _async_to_generator$4(fn) {
|
|
2821
2733
|
return function() {
|
|
@@ -2837,9 +2749,7 @@ function _call_super$4(_this, derived, args) {
|
|
|
2837
2749
|
return _possible_constructor_return$4(_this, _is_native_reflect_construct$4() ? Reflect.construct(derived, args || [], _get_prototype_of$4(_this).constructor) : derived.apply(_this, args));
|
|
2838
2750
|
}
|
|
2839
2751
|
function _class_call_check$4(instance, Constructor) {
|
|
2840
|
-
if (!(instance instanceof Constructor))
|
|
2841
|
-
throw new TypeError("Cannot call a class as a function");
|
|
2842
|
-
}
|
|
2752
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
2843
2753
|
}
|
|
2844
2754
|
function _defineProperties$3(target, props) {
|
|
2845
2755
|
for(var i = 0; i < props.length; i++){
|
|
@@ -2862,9 +2772,7 @@ function _define_property$5(obj, key, value) {
|
|
|
2862
2772
|
configurable: true,
|
|
2863
2773
|
writable: true
|
|
2864
2774
|
});
|
|
2865
|
-
} else
|
|
2866
|
-
obj[key] = value;
|
|
2867
|
-
}
|
|
2775
|
+
} else obj[key] = value;
|
|
2868
2776
|
return obj;
|
|
2869
2777
|
}
|
|
2870
2778
|
function _get_prototype_of$4(o) {
|
|
@@ -2890,9 +2798,15 @@ function _instanceof$1(left, right) {
|
|
|
2890
2798
|
"@swc/helpers - instanceof";
|
|
2891
2799
|
if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
|
|
2892
2800
|
return !!right[Symbol.hasInstance](left);
|
|
2893
|
-
} else
|
|
2894
|
-
|
|
2895
|
-
|
|
2801
|
+
} else return left instanceof right;
|
|
2802
|
+
}
|
|
2803
|
+
function _is_native_reflect_construct$4() {
|
|
2804
|
+
try {
|
|
2805
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
2806
|
+
} catch (_) {}
|
|
2807
|
+
return (_is_native_reflect_construct$4 = function() {
|
|
2808
|
+
return !!result;
|
|
2809
|
+
})();
|
|
2896
2810
|
}
|
|
2897
2811
|
function _object_spread$3(target) {
|
|
2898
2812
|
for(var i = 1; i < arguments.length; i++){
|
|
@@ -2919,9 +2833,8 @@ function ownKeys$1(object, enumerableOnly) {
|
|
|
2919
2833
|
}
|
|
2920
2834
|
function _object_spread_props$1(target, source) {
|
|
2921
2835
|
source = source != null ? source : {};
|
|
2922
|
-
if (Object.getOwnPropertyDescriptors)
|
|
2923
|
-
|
|
2924
|
-
} else {
|
|
2836
|
+
if (Object.getOwnPropertyDescriptors) Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
2837
|
+
else {
|
|
2925
2838
|
ownKeys$1(Object(source)).forEach(function(key) {
|
|
2926
2839
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
2927
2840
|
});
|
|
@@ -2929,9 +2842,7 @@ function _object_spread_props$1(target, source) {
|
|
|
2929
2842
|
return target;
|
|
2930
2843
|
}
|
|
2931
2844
|
function _possible_constructor_return$4(self, call) {
|
|
2932
|
-
if (call && (_type_of$4(call) === "object" || typeof call === "function"))
|
|
2933
|
-
return call;
|
|
2934
|
-
}
|
|
2845
|
+
if (call && (_type_of$4(call) === "object" || typeof call === "function")) return call;
|
|
2935
2846
|
return _assert_this_initialized$4(self);
|
|
2936
2847
|
}
|
|
2937
2848
|
function _set_prototype_of$4(o, p) {
|
|
@@ -2941,18 +2852,6 @@ function _set_prototype_of$4(o, p) {
|
|
|
2941
2852
|
};
|
|
2942
2853
|
return _set_prototype_of$4(o, p);
|
|
2943
2854
|
}
|
|
2944
|
-
function _type_of$4(obj) {
|
|
2945
|
-
"@swc/helpers - typeof";
|
|
2946
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
2947
|
-
}
|
|
2948
|
-
function _is_native_reflect_construct$4() {
|
|
2949
|
-
try {
|
|
2950
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
2951
|
-
} catch (_) {}
|
|
2952
|
-
return (_is_native_reflect_construct$4 = function() {
|
|
2953
|
-
return !!result;
|
|
2954
|
-
})();
|
|
2955
|
-
}
|
|
2956
2855
|
function _ts_generator$4(thisArg, body) {
|
|
2957
2856
|
var f, y, t, _ = {
|
|
2958
2857
|
label: 0,
|
|
@@ -3052,6 +2951,10 @@ function _ts_generator$4(thisArg, body) {
|
|
|
3052
2951
|
};
|
|
3053
2952
|
}
|
|
3054
2953
|
}
|
|
2954
|
+
function _type_of$4(obj) {
|
|
2955
|
+
"@swc/helpers - typeof";
|
|
2956
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
2957
|
+
}
|
|
3055
2958
|
// MARK: FirebaseAdminFunctionTestBuilder
|
|
3056
2959
|
var functionsInitialized = false;
|
|
3057
2960
|
/**
|
|
@@ -3377,9 +3280,7 @@ function _array_without_holes$1(arr) {
|
|
|
3377
3280
|
if (Array.isArray(arr)) return _array_like_to_array$1(arr);
|
|
3378
3281
|
}
|
|
3379
3282
|
function _assert_this_initialized$3(self) {
|
|
3380
|
-
if (self === void 0)
|
|
3381
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
3382
|
-
}
|
|
3283
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
3383
3284
|
return self;
|
|
3384
3285
|
}
|
|
3385
3286
|
function asyncGeneratorStep$3(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -3390,11 +3291,8 @@ function asyncGeneratorStep$3(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
3390
3291
|
reject(error);
|
|
3391
3292
|
return;
|
|
3392
3293
|
}
|
|
3393
|
-
if (info.done)
|
|
3394
|
-
|
|
3395
|
-
} else {
|
|
3396
|
-
Promise.resolve(value).then(_next, _throw);
|
|
3397
|
-
}
|
|
3294
|
+
if (info.done) resolve(value);
|
|
3295
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
3398
3296
|
}
|
|
3399
3297
|
function _async_to_generator$3(fn) {
|
|
3400
3298
|
return function() {
|
|
@@ -3416,9 +3314,7 @@ function _call_super$3(_this, derived, args) {
|
|
|
3416
3314
|
return _possible_constructor_return$3(_this, _is_native_reflect_construct$3() ? Reflect.construct(derived, args || [], _get_prototype_of$3(_this).constructor) : derived.apply(_this, args));
|
|
3417
3315
|
}
|
|
3418
3316
|
function _class_call_check$3(instance, Constructor) {
|
|
3419
|
-
if (!(instance instanceof Constructor))
|
|
3420
|
-
throw new TypeError("Cannot call a class as a function");
|
|
3421
|
-
}
|
|
3317
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
3422
3318
|
}
|
|
3423
3319
|
function _defineProperties$2(target, props) {
|
|
3424
3320
|
for(var i = 0; i < props.length; i++){
|
|
@@ -3441,9 +3337,7 @@ function _define_property$4(obj, key, value) {
|
|
|
3441
3337
|
configurable: true,
|
|
3442
3338
|
writable: true
|
|
3443
3339
|
});
|
|
3444
|
-
} else
|
|
3445
|
-
obj[key] = value;
|
|
3446
|
-
}
|
|
3340
|
+
} else obj[key] = value;
|
|
3447
3341
|
return obj;
|
|
3448
3342
|
}
|
|
3449
3343
|
function _get_prototype_of$3(o) {
|
|
@@ -3465,11 +3359,21 @@ function _inherits$3(subClass, superClass) {
|
|
|
3465
3359
|
});
|
|
3466
3360
|
if (superClass) _set_prototype_of$3(subClass, superClass);
|
|
3467
3361
|
}
|
|
3362
|
+
function _is_native_reflect_construct$3() {
|
|
3363
|
+
try {
|
|
3364
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
3365
|
+
} catch (_) {}
|
|
3366
|
+
return (_is_native_reflect_construct$3 = function() {
|
|
3367
|
+
return !!result;
|
|
3368
|
+
})();
|
|
3369
|
+
}
|
|
3468
3370
|
function _iterable_to_array$1(iter) {
|
|
3469
|
-
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
3371
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) {
|
|
3372
|
+
return Array.from(iter);
|
|
3373
|
+
}
|
|
3470
3374
|
}
|
|
3471
3375
|
function _non_iterable_spread$1() {
|
|
3472
|
-
throw new TypeError("Invalid attempt to spread non-iterable instance
|
|
3376
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
3473
3377
|
}
|
|
3474
3378
|
function _object_spread$2(target) {
|
|
3475
3379
|
for(var i = 1; i < arguments.length; i++){
|
|
@@ -3496,9 +3400,8 @@ function ownKeys(object, enumerableOnly) {
|
|
|
3496
3400
|
}
|
|
3497
3401
|
function _object_spread_props(target, source) {
|
|
3498
3402
|
source = source != null ? source : {};
|
|
3499
|
-
if (Object.getOwnPropertyDescriptors)
|
|
3500
|
-
|
|
3501
|
-
} else {
|
|
3403
|
+
if (Object.getOwnPropertyDescriptors) Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
3404
|
+
else {
|
|
3502
3405
|
ownKeys(Object(source)).forEach(function(key) {
|
|
3503
3406
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
3504
3407
|
});
|
|
@@ -3506,9 +3409,7 @@ function _object_spread_props(target, source) {
|
|
|
3506
3409
|
return target;
|
|
3507
3410
|
}
|
|
3508
3411
|
function _possible_constructor_return$3(self, call) {
|
|
3509
|
-
if (call && (_type_of$3(call) === "object" || typeof call === "function"))
|
|
3510
|
-
return call;
|
|
3511
|
-
}
|
|
3412
|
+
if (call && (_type_of$3(call) === "object" || typeof call === "function")) return call;
|
|
3512
3413
|
return _assert_this_initialized$3(self);
|
|
3513
3414
|
}
|
|
3514
3415
|
function _set_prototype_of$3(o, p) {
|
|
@@ -3521,26 +3422,6 @@ function _set_prototype_of$3(o, p) {
|
|
|
3521
3422
|
function _to_consumable_array$1(arr) {
|
|
3522
3423
|
return _array_without_holes$1(arr) || _iterable_to_array$1(arr) || _unsupported_iterable_to_array$1(arr) || _non_iterable_spread$1();
|
|
3523
3424
|
}
|
|
3524
|
-
function _type_of$3(obj) {
|
|
3525
|
-
"@swc/helpers - typeof";
|
|
3526
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
3527
|
-
}
|
|
3528
|
-
function _unsupported_iterable_to_array$1(o, minLen) {
|
|
3529
|
-
if (!o) return;
|
|
3530
|
-
if (typeof o === "string") return _array_like_to_array$1(o, minLen);
|
|
3531
|
-
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
3532
|
-
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
3533
|
-
if (n === "Map" || n === "Set") return Array.from(n);
|
|
3534
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array$1(o, minLen);
|
|
3535
|
-
}
|
|
3536
|
-
function _is_native_reflect_construct$3() {
|
|
3537
|
-
try {
|
|
3538
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
3539
|
-
} catch (_) {}
|
|
3540
|
-
return (_is_native_reflect_construct$3 = function() {
|
|
3541
|
-
return !!result;
|
|
3542
|
-
})();
|
|
3543
|
-
}
|
|
3544
3425
|
function _ts_generator$3(thisArg, body) {
|
|
3545
3426
|
var f, y, t, _ = {
|
|
3546
3427
|
label: 0,
|
|
@@ -3640,6 +3521,18 @@ function _ts_generator$3(thisArg, body) {
|
|
|
3640
3521
|
};
|
|
3641
3522
|
}
|
|
3642
3523
|
}
|
|
3524
|
+
function _type_of$3(obj) {
|
|
3525
|
+
"@swc/helpers - typeof";
|
|
3526
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
3527
|
+
}
|
|
3528
|
+
function _unsupported_iterable_to_array$1(o, minLen) {
|
|
3529
|
+
if (!o) return;
|
|
3530
|
+
if (typeof o === "string") return _array_like_to_array$1(o, minLen);
|
|
3531
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
3532
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
3533
|
+
if (n === "Map" || n === "Set") return Array.from(n);
|
|
3534
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array$1(o, minLen);
|
|
3535
|
+
}
|
|
3643
3536
|
/**
|
|
3644
3537
|
* NestJS injection token used to provide the {@link NestServerInstanceConfig} to the test's
|
|
3645
3538
|
* {@link TestingModule}. The instance is injected during nest application creation so that
|
|
@@ -3944,9 +3837,7 @@ function _ts_generator$3(thisArg, body) {
|
|
|
3944
3837
|
}
|
|
3945
3838
|
|
|
3946
3839
|
function _assert_this_initialized$2(self) {
|
|
3947
|
-
if (self === void 0)
|
|
3948
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
3949
|
-
}
|
|
3840
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
3950
3841
|
return self;
|
|
3951
3842
|
}
|
|
3952
3843
|
function _call_super$2(_this, derived, args) {
|
|
@@ -3954,9 +3845,7 @@ function _call_super$2(_this, derived, args) {
|
|
|
3954
3845
|
return _possible_constructor_return$2(_this, _is_native_reflect_construct$2() ? Reflect.construct(derived, args || [], _get_prototype_of$2(_this).constructor) : derived.apply(_this, args));
|
|
3955
3846
|
}
|
|
3956
3847
|
function _class_call_check$2(instance, Constructor) {
|
|
3957
|
-
if (!(instance instanceof Constructor))
|
|
3958
|
-
throw new TypeError("Cannot call a class as a function");
|
|
3959
|
-
}
|
|
3848
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
3960
3849
|
}
|
|
3961
3850
|
function _defineProperties$1(target, props) {
|
|
3962
3851
|
for(var i = 0; i < props.length; i++){
|
|
@@ -3979,9 +3868,7 @@ function _define_property$3(obj, key, value) {
|
|
|
3979
3868
|
configurable: true,
|
|
3980
3869
|
writable: true
|
|
3981
3870
|
});
|
|
3982
|
-
} else
|
|
3983
|
-
obj[key] = value;
|
|
3984
|
-
}
|
|
3871
|
+
} else obj[key] = value;
|
|
3985
3872
|
return obj;
|
|
3986
3873
|
}
|
|
3987
3874
|
function _get_prototype_of$2(o) {
|
|
@@ -4003,6 +3890,14 @@ function _inherits$2(subClass, superClass) {
|
|
|
4003
3890
|
});
|
|
4004
3891
|
if (superClass) _set_prototype_of$2(subClass, superClass);
|
|
4005
3892
|
}
|
|
3893
|
+
function _is_native_reflect_construct$2() {
|
|
3894
|
+
try {
|
|
3895
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
3896
|
+
} catch (_) {}
|
|
3897
|
+
return (_is_native_reflect_construct$2 = function() {
|
|
3898
|
+
return !!result;
|
|
3899
|
+
})();
|
|
3900
|
+
}
|
|
4006
3901
|
function _object_spread$1(target) {
|
|
4007
3902
|
for(var i = 1; i < arguments.length; i++){
|
|
4008
3903
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
@@ -4019,9 +3914,7 @@ function _object_spread$1(target) {
|
|
|
4019
3914
|
return target;
|
|
4020
3915
|
}
|
|
4021
3916
|
function _possible_constructor_return$2(self, call) {
|
|
4022
|
-
if (call && (_type_of$2(call) === "object" || typeof call === "function"))
|
|
4023
|
-
return call;
|
|
4024
|
-
}
|
|
3917
|
+
if (call && (_type_of$2(call) === "object" || typeof call === "function")) return call;
|
|
4025
3918
|
return _assert_this_initialized$2(self);
|
|
4026
3919
|
}
|
|
4027
3920
|
function _set_prototype_of$2(o, p) {
|
|
@@ -4035,25 +3928,17 @@ function _type_of$2(obj) {
|
|
|
4035
3928
|
"@swc/helpers - typeof";
|
|
4036
3929
|
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
4037
3930
|
}
|
|
4038
|
-
function _is_native_reflect_construct$2() {
|
|
4039
|
-
try {
|
|
4040
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
4041
|
-
} catch (_) {}
|
|
4042
|
-
return (_is_native_reflect_construct$2 = function() {
|
|
4043
|
-
return !!result;
|
|
4044
|
-
})();
|
|
4045
|
-
}
|
|
4046
3931
|
/**
|
|
4047
|
-
* Creates a lazy getter that wraps a NestJS-hosted Cloud Function
|
|
3932
|
+
* Creates a lazy getter that wraps a NestJS-hosted Cloud Function for testing.
|
|
4048
3933
|
*
|
|
4049
3934
|
* The returned getter defers wrapping until first invocation, so the NestJS application
|
|
4050
3935
|
* is resolved at call time rather than at setup time.
|
|
4051
3936
|
*
|
|
4052
3937
|
* @param wrapper - The test context providing the function wrapper and NestJS app promise.
|
|
4053
3938
|
* @param fn - The NestJS application function factory to wrap.
|
|
4054
|
-
* @returns A getter that produces a {@link
|
|
3939
|
+
* @returns A getter that produces a {@link WrappedCloudFunction} on each call.
|
|
4055
3940
|
*/ function wrapCloudFunctionForNestTestsGetter(wrapper, fn) {
|
|
4056
|
-
return
|
|
3941
|
+
return wrapCloudFunctionTests(wrapper.fnWrapper, function() {
|
|
4057
3942
|
return fn(wrapper.nestAppPromiseGetter);
|
|
4058
3943
|
});
|
|
4059
3944
|
}
|
|
@@ -4075,7 +3960,7 @@ function _is_native_reflect_construct$2() {
|
|
|
4075
3960
|
* Fixture that combines NestJS testing module access with Cloud Function wrapping capabilities.
|
|
4076
3961
|
*
|
|
4077
3962
|
* Extends {@link FirebaseAdminNestTestContextFixture} and adds convenience methods for wrapping
|
|
4078
|
-
* both
|
|
3963
|
+
* both cloud functions and gen-2 callable requests directly from the fixture, delegating
|
|
4079
3964
|
* to the standalone {@link wrapCloudFunctionForNestTestsGetter} and {@link wrapCallableRequestForNestTestsGetter} helpers.
|
|
4080
3965
|
*/ var FirebaseAdminFunctionNestTestContextFixture = /*#__PURE__*/ function(FirebaseAdminNestTestContextFixture) {
|
|
4081
3966
|
_inherits$2(FirebaseAdminFunctionNestTestContextFixture, FirebaseAdminNestTestContextFixture);
|
|
@@ -4298,11 +4183,8 @@ function asyncGeneratorStep$2(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
4298
4183
|
reject(error);
|
|
4299
4184
|
return;
|
|
4300
4185
|
}
|
|
4301
|
-
if (info.done)
|
|
4302
|
-
|
|
4303
|
-
} else {
|
|
4304
|
-
Promise.resolve(value).then(_next, _throw);
|
|
4305
|
-
}
|
|
4186
|
+
if (info.done) resolve(value);
|
|
4187
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
4306
4188
|
}
|
|
4307
4189
|
function _async_to_generator$2(fn) {
|
|
4308
4190
|
return function() {
|
|
@@ -4500,9 +4382,7 @@ function _ts_generator$2(thisArg, body) {
|
|
|
4500
4382
|
}
|
|
4501
4383
|
|
|
4502
4384
|
function _assert_this_initialized$1(self) {
|
|
4503
|
-
if (self === void 0)
|
|
4504
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
4505
|
-
}
|
|
4385
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
4506
4386
|
return self;
|
|
4507
4387
|
}
|
|
4508
4388
|
function _call_super$1(_this, derived, args) {
|
|
@@ -4510,9 +4390,7 @@ function _call_super$1(_this, derived, args) {
|
|
|
4510
4390
|
return _possible_constructor_return$1(_this, _is_native_reflect_construct$1() ? Reflect.construct(derived, args || [], _get_prototype_of$1(_this).constructor) : derived.apply(_this, args));
|
|
4511
4391
|
}
|
|
4512
4392
|
function _class_call_check$1(instance, Constructor) {
|
|
4513
|
-
if (!(instance instanceof Constructor))
|
|
4514
|
-
throw new TypeError("Cannot call a class as a function");
|
|
4515
|
-
}
|
|
4393
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
4516
4394
|
}
|
|
4517
4395
|
function _define_property$2(obj, key, value) {
|
|
4518
4396
|
if (key in obj) {
|
|
@@ -4522,9 +4400,7 @@ function _define_property$2(obj, key, value) {
|
|
|
4522
4400
|
configurable: true,
|
|
4523
4401
|
writable: true
|
|
4524
4402
|
});
|
|
4525
|
-
} else
|
|
4526
|
-
obj[key] = value;
|
|
4527
|
-
}
|
|
4403
|
+
} else obj[key] = value;
|
|
4528
4404
|
return obj;
|
|
4529
4405
|
}
|
|
4530
4406
|
function _get_prototype_of$1(o) {
|
|
@@ -4550,14 +4426,18 @@ function _instanceof(left, right) {
|
|
|
4550
4426
|
"@swc/helpers - instanceof";
|
|
4551
4427
|
if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
|
|
4552
4428
|
return !!right[Symbol.hasInstance](left);
|
|
4553
|
-
} else
|
|
4554
|
-
|
|
4555
|
-
|
|
4429
|
+
} else return left instanceof right;
|
|
4430
|
+
}
|
|
4431
|
+
function _is_native_reflect_construct$1() {
|
|
4432
|
+
try {
|
|
4433
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
4434
|
+
} catch (_) {}
|
|
4435
|
+
return (_is_native_reflect_construct$1 = function() {
|
|
4436
|
+
return !!result;
|
|
4437
|
+
})();
|
|
4556
4438
|
}
|
|
4557
4439
|
function _possible_constructor_return$1(self, call) {
|
|
4558
|
-
if (call && (_type_of$1(call) === "object" || typeof call === "function"))
|
|
4559
|
-
return call;
|
|
4560
|
-
}
|
|
4440
|
+
if (call && (_type_of$1(call) === "object" || typeof call === "function")) return call;
|
|
4561
4441
|
return _assert_this_initialized$1(self);
|
|
4562
4442
|
}
|
|
4563
4443
|
function _set_prototype_of$1(o, p) {
|
|
@@ -4571,14 +4451,6 @@ function _type_of$1(obj) {
|
|
|
4571
4451
|
"@swc/helpers - typeof";
|
|
4572
4452
|
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
4573
4453
|
}
|
|
4574
|
-
function _is_native_reflect_construct$1() {
|
|
4575
|
-
try {
|
|
4576
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
4577
|
-
} catch (_) {}
|
|
4578
|
-
return (_is_native_reflect_construct$1 = function() {
|
|
4579
|
-
return !!result;
|
|
4580
|
-
})();
|
|
4581
|
-
}
|
|
4582
4454
|
/**
|
|
4583
4455
|
* Error thrown when the error type was different than the expected type.
|
|
4584
4456
|
*/ var ExpectedHttpErrorWithSpecificServerErrorCode = /*#__PURE__*/ function(BaseError) {
|
|
@@ -4617,20 +4489,6 @@ function _is_native_reflect_construct$1() {
|
|
|
4617
4489
|
return true;
|
|
4618
4490
|
};
|
|
4619
4491
|
}
|
|
4620
|
-
// MARK: Compat
|
|
4621
|
-
/**
|
|
4622
|
-
* @deprecated Use ExpectedHttpErrorWithSpecificServerErrorCode from shared instead. This is kept for backwards compatibility.
|
|
4623
|
-
*/ var JestExpectedHttpErrorWithSpecificServerErrorCode = /*#__PURE__*/ function(ExpectedHttpErrorWithSpecificServerErrorCode) {
|
|
4624
|
-
_inherits$1(JestExpectedHttpErrorWithSpecificServerErrorCode, ExpectedHttpErrorWithSpecificServerErrorCode);
|
|
4625
|
-
function JestExpectedHttpErrorWithSpecificServerErrorCode() {
|
|
4626
|
-
_class_call_check$1(this, JestExpectedHttpErrorWithSpecificServerErrorCode);
|
|
4627
|
-
return _call_super$1(this, JestExpectedHttpErrorWithSpecificServerErrorCode, arguments);
|
|
4628
|
-
}
|
|
4629
|
-
return JestExpectedHttpErrorWithSpecificServerErrorCode;
|
|
4630
|
-
}(ExpectedHttpErrorWithSpecificServerErrorCode);
|
|
4631
|
-
/**
|
|
4632
|
-
* @deprecated Use expectFailAssertHttpErrorServerErrorCode from shared instead. This is kept for backwards compatibility.
|
|
4633
|
-
*/ var jestExpectFailAssertHttpErrorServerErrorCode = expectFailAssertHttpErrorServerErrorCode;
|
|
4634
4492
|
|
|
4635
4493
|
/**
|
|
4636
4494
|
* Default firestore admin factory.
|
|
@@ -4665,11 +4523,8 @@ function asyncGeneratorStep$1(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
4665
4523
|
reject(error);
|
|
4666
4524
|
return;
|
|
4667
4525
|
}
|
|
4668
|
-
if (info.done)
|
|
4669
|
-
|
|
4670
|
-
} else {
|
|
4671
|
-
Promise.resolve(value).then(_next, _throw);
|
|
4672
|
-
}
|
|
4526
|
+
if (info.done) resolve(value);
|
|
4527
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
4673
4528
|
}
|
|
4674
4529
|
function _async_to_generator$1(fn) {
|
|
4675
4530
|
return function() {
|
|
@@ -4694,13 +4549,13 @@ function _define_property$1(obj, key, value) {
|
|
|
4694
4549
|
configurable: true,
|
|
4695
4550
|
writable: true
|
|
4696
4551
|
});
|
|
4697
|
-
} else
|
|
4698
|
-
obj[key] = value;
|
|
4699
|
-
}
|
|
4552
|
+
} else obj[key] = value;
|
|
4700
4553
|
return obj;
|
|
4701
4554
|
}
|
|
4702
4555
|
function _iterable_to_array(iter) {
|
|
4703
|
-
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
4556
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) {
|
|
4557
|
+
return Array.from(iter);
|
|
4558
|
+
}
|
|
4704
4559
|
}
|
|
4705
4560
|
function _iterable_to_array_limit(arr, i) {
|
|
4706
4561
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
@@ -4727,10 +4582,10 @@ function _iterable_to_array_limit(arr, i) {
|
|
|
4727
4582
|
return _arr;
|
|
4728
4583
|
}
|
|
4729
4584
|
function _non_iterable_rest() {
|
|
4730
|
-
throw new TypeError("Invalid attempt to destructure non-iterable instance
|
|
4585
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
4731
4586
|
}
|
|
4732
4587
|
function _non_iterable_spread() {
|
|
4733
|
-
throw new TypeError("Invalid attempt to spread non-iterable instance
|
|
4588
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
4734
4589
|
}
|
|
4735
4590
|
function _object_spread(target) {
|
|
4736
4591
|
for(var i = 1; i < arguments.length; i++){
|
|
@@ -4753,14 +4608,6 @@ function _sliced_to_array(arr, i) {
|
|
|
4753
4608
|
function _to_consumable_array(arr) {
|
|
4754
4609
|
return _array_without_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_spread();
|
|
4755
4610
|
}
|
|
4756
|
-
function _unsupported_iterable_to_array(o, minLen) {
|
|
4757
|
-
if (!o) return;
|
|
4758
|
-
if (typeof o === "string") return _array_like_to_array(o, minLen);
|
|
4759
|
-
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
4760
|
-
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
4761
|
-
if (n === "Map" || n === "Set") return Array.from(n);
|
|
4762
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
4763
|
-
}
|
|
4764
4611
|
function _ts_generator$1(thisArg, body) {
|
|
4765
4612
|
var f, y, t, _ = {
|
|
4766
4613
|
label: 0,
|
|
@@ -4860,6 +4707,14 @@ function _ts_generator$1(thisArg, body) {
|
|
|
4860
4707
|
};
|
|
4861
4708
|
}
|
|
4862
4709
|
}
|
|
4710
|
+
function _unsupported_iterable_to_array(o, minLen) {
|
|
4711
|
+
if (!o) return;
|
|
4712
|
+
if (typeof o === "string") return _array_like_to_array(o, minLen);
|
|
4713
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
4714
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
4715
|
+
if (n === "Map" || n === "Set") return Array.from(n);
|
|
4716
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
4717
|
+
}
|
|
4863
4718
|
// MARK: Helpers
|
|
4864
4719
|
/**
|
|
4865
4720
|
* Creates a Firebase ID token for the given UID that the Auth emulator will accept.
|
|
@@ -5182,9 +5037,7 @@ function _ts_generator$1(thisArg, body) {
|
|
|
5182
5037
|
}
|
|
5183
5038
|
|
|
5184
5039
|
function _assert_this_initialized(self) {
|
|
5185
|
-
if (self === void 0)
|
|
5186
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
5187
|
-
}
|
|
5040
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
5188
5041
|
return self;
|
|
5189
5042
|
}
|
|
5190
5043
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -5195,11 +5048,8 @@ function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
5195
5048
|
reject(error);
|
|
5196
5049
|
return;
|
|
5197
5050
|
}
|
|
5198
|
-
if (info.done)
|
|
5199
|
-
|
|
5200
|
-
} else {
|
|
5201
|
-
Promise.resolve(value).then(_next, _throw);
|
|
5202
|
-
}
|
|
5051
|
+
if (info.done) resolve(value);
|
|
5052
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
5203
5053
|
}
|
|
5204
5054
|
function _async_to_generator(fn) {
|
|
5205
5055
|
return function() {
|
|
@@ -5221,9 +5071,7 @@ function _call_super(_this, derived, args) {
|
|
|
5221
5071
|
return _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
|
|
5222
5072
|
}
|
|
5223
5073
|
function _class_call_check(instance, Constructor) {
|
|
5224
|
-
if (!(instance instanceof Constructor))
|
|
5225
|
-
throw new TypeError("Cannot call a class as a function");
|
|
5226
|
-
}
|
|
5074
|
+
if (!(instance instanceof Constructor)) throw new TypeError("Cannot call a class as a function");
|
|
5227
5075
|
}
|
|
5228
5076
|
function _defineProperties(target, props) {
|
|
5229
5077
|
for(var i = 0; i < props.length; i++){
|
|
@@ -5246,9 +5094,7 @@ function _define_property(obj, key, value) {
|
|
|
5246
5094
|
configurable: true,
|
|
5247
5095
|
writable: true
|
|
5248
5096
|
});
|
|
5249
|
-
} else
|
|
5250
|
-
obj[key] = value;
|
|
5251
|
-
}
|
|
5097
|
+
} else obj[key] = value;
|
|
5252
5098
|
return obj;
|
|
5253
5099
|
}
|
|
5254
5100
|
function _get_prototype_of(o) {
|
|
@@ -5270,6 +5116,14 @@ function _inherits(subClass, superClass) {
|
|
|
5270
5116
|
});
|
|
5271
5117
|
if (superClass) _set_prototype_of(subClass, superClass);
|
|
5272
5118
|
}
|
|
5119
|
+
function _is_native_reflect_construct() {
|
|
5120
|
+
try {
|
|
5121
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
5122
|
+
} catch (_) {}
|
|
5123
|
+
return (_is_native_reflect_construct = function() {
|
|
5124
|
+
return !!result;
|
|
5125
|
+
})();
|
|
5126
|
+
}
|
|
5273
5127
|
function _object_without_properties(source, excluded) {
|
|
5274
5128
|
if (source == null) return {};
|
|
5275
5129
|
var target = {}, sourceKeys, key, i;
|
|
@@ -5307,9 +5161,7 @@ function _object_without_properties_loose(source, excluded) {
|
|
|
5307
5161
|
return target;
|
|
5308
5162
|
}
|
|
5309
5163
|
function _possible_constructor_return(self, call) {
|
|
5310
|
-
if (call && (_type_of(call) === "object" || typeof call === "function"))
|
|
5311
|
-
return call;
|
|
5312
|
-
}
|
|
5164
|
+
if (call && (_type_of(call) === "object" || typeof call === "function")) return call;
|
|
5313
5165
|
return _assert_this_initialized(self);
|
|
5314
5166
|
}
|
|
5315
5167
|
function _set_prototype_of(o, p) {
|
|
@@ -5319,18 +5171,6 @@ function _set_prototype_of(o, p) {
|
|
|
5319
5171
|
};
|
|
5320
5172
|
return _set_prototype_of(o, p);
|
|
5321
5173
|
}
|
|
5322
|
-
function _type_of(obj) {
|
|
5323
|
-
"@swc/helpers - typeof";
|
|
5324
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
5325
|
-
}
|
|
5326
|
-
function _is_native_reflect_construct() {
|
|
5327
|
-
try {
|
|
5328
|
-
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
5329
|
-
} catch (_) {}
|
|
5330
|
-
return (_is_native_reflect_construct = function() {
|
|
5331
|
-
return !!result;
|
|
5332
|
-
})();
|
|
5333
|
-
}
|
|
5334
5174
|
function _ts_generator(thisArg, body) {
|
|
5335
5175
|
var f, y, t, _ = {
|
|
5336
5176
|
label: 0,
|
|
@@ -5430,6 +5270,10 @@ function _ts_generator(thisArg, body) {
|
|
|
5430
5270
|
};
|
|
5431
5271
|
}
|
|
5432
5272
|
}
|
|
5273
|
+
function _type_of(obj) {
|
|
5274
|
+
"@swc/helpers - typeof";
|
|
5275
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
5276
|
+
}
|
|
5433
5277
|
// MARK: Instance
|
|
5434
5278
|
/**
|
|
5435
5279
|
* Instance holding authenticated OAuth state for a single test.
|
|
@@ -5640,4 +5484,4 @@ function _ts_generator(thisArg, body) {
|
|
|
5640
5484
|
* Uses @google-cloud/storage
|
|
5641
5485
|
*/ var dbxComponentsAdminTestWithMockItemStorage = testWithMockItemStorageFixture()(adminFirebaseStorageFactory);
|
|
5642
5486
|
|
|
5643
|
-
export { AUTHORIZED_USER_RANDOM_EMAIL_FACTORY, AUTHORIZED_USER_RANDOM_PHONE_NUMBER_FACTORY, AbstractFirebaseAdminTestContextInstanceChild, AuthorizedUserTestContextFixture, AuthorizedUserTestContextInstance, CallableRequestTestMultipleFixtureSuffix, DEFAULT_FIREBASE_ADMIN_FUNCTION_TEST_USE_FUNCTION_SINGLETON_CONTEXT, ExpectedHttpErrorWithSpecificServerErrorCode, FIREBASE_ADMIN_NEST_TEST_SERVER_INSTANCE_CONFIG_TOKEN, FirebaseAdminFunctionNestRootModule, FirebaseAdminFunctionNestTestContextFixture, FirebaseAdminFunctionNestTestContextInstance, FirebaseAdminFunctionTestContextFixture, FirebaseAdminFunctionTestContextInstance, FirebaseAdminNestTestContextFixture, FirebaseAdminNestTestContextInstance, FirebaseAdminTestContextFixture, FirebaseAdminTestContextInstance, GoogleCloudTestFirebaseStorageContextFixture, GoogleCloudTestFirebaseStorageInstance, GoogleCloudTestFirestoreContextFixture, GoogleCloudTestFirestoreInstance,
|
|
5487
|
+
export { AUTHORIZED_USER_RANDOM_EMAIL_FACTORY, AUTHORIZED_USER_RANDOM_PHONE_NUMBER_FACTORY, AbstractFirebaseAdminTestContextInstanceChild, AuthorizedUserTestContextFixture, AuthorizedUserTestContextInstance, CallableRequestTestMultipleFixtureSuffix, DEFAULT_FIREBASE_ADMIN_FUNCTION_TEST_USE_FUNCTION_SINGLETON_CONTEXT, ExpectedHttpErrorWithSpecificServerErrorCode, FIREBASE_ADMIN_NEST_TEST_SERVER_INSTANCE_CONFIG_TOKEN, FirebaseAdminFunctionNestRootModule, FirebaseAdminFunctionNestTestContextFixture, FirebaseAdminFunctionNestTestContextInstance, FirebaseAdminFunctionTestContextFixture, FirebaseAdminFunctionTestContextInstance, FirebaseAdminNestTestContextFixture, FirebaseAdminNestTestContextInstance, FirebaseAdminTestContextFixture, FirebaseAdminTestContextInstance, GoogleCloudTestFirebaseStorageContextFixture, GoogleCloudTestFirebaseStorageInstance, GoogleCloudTestFirestoreContextFixture, GoogleCloudTestFirestoreInstance, ModelTestContextFixture, ModelTestContextInstance, OAuthAuthorizedSuperTestFixture, OAuthAuthorizedSuperTestInstance, adminFirebaseStorageFactory, adminFirestoreFactory, applyFirebaseGCloudTestProjectIdToFirebaseConfigEnv, authorizedUserContext, authorizedUserContextFactory, callableRequestTest, cloudFunctionTest, createEncodedTestFirestoreTokenForUserRecord, createTestFirestoreTokenForUserRecord, createTestFunctionContextAuthData, createTestFunctionContextOptions, dbxComponentsAdminTestWithMockItemCollection, dbxComponentsAdminTestWithMockItemStorage, decodeEncodedCreateCustomTokenResult, describeCallableRequestTest, describeCloudFunctionTest, describeFirestoreTest, expectFailAssertHttpErrorServerErrorCode, firebaseAdminFirestoreContextFixture, firebaseAdminFirestoreContextWithFixture, firebaseAdminFunctionNestContextFactory, firebaseAdminFunctionNestContextFixture, firebaseAdminFunctionNestContextWithFixture, firebaseAdminFunctionTestBuilder, firebaseAdminFunctionTestContextFactory, firebaseAdminNestContextFactory, firebaseAdminNestContextFixture, firebaseAdminNestContextWithFixture, firebaseAdminTestBuilder, firebaseAdminTestContextFactory, generateNewProjectId, getGCloudProjectId, getGCloudTestProjectId, googleCloudTestFirebaseStorageBuilder, googleCloudTestFirestoreBuilder, initFirebaseAdminTestEnvironment, initFirebaseServerAdminTestEnvironment, isAdminEnvironmentInitialized, isCallableRequestTestSingleConfig, isCloudFunctionTestSingleConfig, makeGoogleFirebaseStorageContext, makeGoogleFirestoreContext, modelTestContextFactory, oAuthAuthorizedSuperTestContextFactory, performFullOAuthFlow, rerollFirebaseAdminFunctionTestSingleton, rollNewGCloudProjectEnvironmentVariable, setDefaultFirebaseAdminFunctionTestUseFunctionSingleton, setupAndPerformFullOAuthFlow, setupFirebaseAdminFunctionTestSingleton, testFirestoreClaimsFromUserRecord, testUidFactory, wrapCallableRequestForNestTestsGetter, wrapCloudFunctionForNestTestsGetter };
|