@jaypie/testkit 1.2.7 → 1.2.11
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/dist/mock/dynamodb.d.ts +79 -14
- package/dist/mock/express.d.ts +2 -0
- package/dist/mock/index.d.ts +98 -31
- package/dist/mock/index.js +73 -161
- package/dist/mock/index.js.map +1 -1
- package/dist/mock/mock/dynamodb.d.ts +79 -14
- package/dist/mock/mock/express.d.ts +2 -0
- package/package.json +1 -1
package/dist/mock/index.js
CHANGED
|
@@ -6,15 +6,16 @@ import * as errors from '@jaypie/errors';
|
|
|
6
6
|
import { BadRequestError as BadRequestError$1, UnhandledError as UnhandledError$1 } from '@jaypie/errors';
|
|
7
7
|
import * as kit$1 from '@jaypie/kit';
|
|
8
8
|
import * as original$1 from '@jaypie/datadog';
|
|
9
|
-
import * as original$2 from '@jaypie/
|
|
10
|
-
import * as original$3 from '@jaypie/
|
|
9
|
+
import * as original$2 from '@jaypie/dynamodb';
|
|
10
|
+
import * as original$3 from '@jaypie/express';
|
|
11
|
+
import * as original$4 from '@jaypie/llm';
|
|
11
12
|
import { mongoose as mongoose$1 } from '@jaypie/mongoose';
|
|
12
13
|
export { mongoose } from '@jaypie/mongoose';
|
|
13
14
|
import { readFile } from 'fs/promises';
|
|
14
15
|
import { dirname, join } from 'path';
|
|
15
16
|
import { fileURLToPath } from 'url';
|
|
16
17
|
import { TextractDocument } from 'amazon-textract-response-parser';
|
|
17
|
-
import * as original$
|
|
18
|
+
import * as original$5 from '@jaypie/textract';
|
|
18
19
|
|
|
19
20
|
/* eslint-disable no-console */
|
|
20
21
|
/**
|
|
@@ -593,133 +594,24 @@ var datadog = /*#__PURE__*/Object.freeze({
|
|
|
593
594
|
submitMetricSet: submitMetricSet
|
|
594
595
|
});
|
|
595
596
|
|
|
596
|
-
// Primary markers
|
|
597
|
-
const APEX$1 = "@"; // Root-level marker (DynamoDB prohibits empty strings)
|
|
598
|
-
const SEPARATOR$1 = "#"; // Composite key separator
|
|
599
|
-
// GSI names
|
|
600
|
-
const INDEX_ALIAS$1 = "indexAlias";
|
|
601
|
-
const INDEX_CLASS$1 = "indexClass";
|
|
602
|
-
const INDEX_OU$1 = "indexOu";
|
|
603
|
-
const INDEX_TYPE$1 = "indexType";
|
|
604
|
-
const INDEX_XID$1 = "indexXid";
|
|
605
|
-
// Index suffixes for soft state
|
|
606
|
-
const ARCHIVED_SUFFIX$1 = "#archived";
|
|
607
|
-
const DELETED_SUFFIX$1 = "#deleted";
|
|
608
|
-
|
|
609
|
-
/**
|
|
610
|
-
* Build the indexOu key for hierarchical queries
|
|
611
|
-
* @param ou - The organizational unit (APEX or "{parent.model}#{parent.id}")
|
|
612
|
-
* @param model - The entity model name
|
|
613
|
-
* @returns Composite key: "{ou}#{model}"
|
|
614
|
-
*/
|
|
615
|
-
function buildIndexOu$1(ou, model) {
|
|
616
|
-
return `${ou}${SEPARATOR$1}${model}`;
|
|
617
|
-
}
|
|
618
|
-
/**
|
|
619
|
-
* Build the indexAlias key for human-friendly lookups
|
|
620
|
-
* @param ou - The organizational unit
|
|
621
|
-
* @param model - The entity model name
|
|
622
|
-
* @param alias - The human-friendly alias
|
|
623
|
-
* @returns Composite key: "{ou}#{model}#{alias}"
|
|
624
|
-
*/
|
|
625
|
-
function buildIndexAlias$1(ou, model, alias) {
|
|
626
|
-
return `${ou}${SEPARATOR$1}${model}${SEPARATOR$1}${alias}`;
|
|
627
|
-
}
|
|
628
|
-
/**
|
|
629
|
-
* Build the indexClass key for category filtering
|
|
630
|
-
* @param ou - The organizational unit
|
|
631
|
-
* @param model - The entity model name
|
|
632
|
-
* @param recordClass - The category classification
|
|
633
|
-
* @returns Composite key: "{ou}#{model}#{class}"
|
|
634
|
-
*/
|
|
635
|
-
function buildIndexClass$1(ou, model, recordClass) {
|
|
636
|
-
return `${ou}${SEPARATOR$1}${model}${SEPARATOR$1}${recordClass}`;
|
|
637
|
-
}
|
|
638
|
-
/**
|
|
639
|
-
* Build the indexType key for type filtering
|
|
640
|
-
* @param ou - The organizational unit
|
|
641
|
-
* @param model - The entity model name
|
|
642
|
-
* @param type - The type classification
|
|
643
|
-
* @returns Composite key: "{ou}#{model}#{type}"
|
|
644
|
-
*/
|
|
645
|
-
function buildIndexType$1(ou, model, type) {
|
|
646
|
-
return `${ou}${SEPARATOR$1}${model}${SEPARATOR$1}${type}`;
|
|
647
|
-
}
|
|
648
|
-
/**
|
|
649
|
-
* Build the indexXid key for external ID lookups
|
|
650
|
-
* @param ou - The organizational unit
|
|
651
|
-
* @param model - The entity model name
|
|
652
|
-
* @param xid - The external ID
|
|
653
|
-
* @returns Composite key: "{ou}#{model}#{xid}"
|
|
654
|
-
*/
|
|
655
|
-
function buildIndexXid$1(ou, model, xid) {
|
|
656
|
-
return `${ou}${SEPARATOR$1}${model}${SEPARATOR$1}${xid}`;
|
|
657
|
-
}
|
|
658
|
-
/**
|
|
659
|
-
* Calculate the organizational unit from a parent reference
|
|
660
|
-
* @param parent - Optional parent entity reference
|
|
661
|
-
* @returns APEX ("@") if no parent, otherwise "{parent.model}#{parent.id}"
|
|
662
|
-
*/
|
|
663
|
-
function calculateOu$1(parent) {
|
|
664
|
-
if (!parent) {
|
|
665
|
-
return APEX$1;
|
|
666
|
-
}
|
|
667
|
-
return `${parent.model}${SEPARATOR$1}${parent.id}`;
|
|
668
|
-
}
|
|
669
|
-
/**
|
|
670
|
-
* Auto-populate GSI index keys on an entity
|
|
671
|
-
* - indexOu is always populated from ou + model
|
|
672
|
-
* - indexAlias is populated only when alias is present
|
|
673
|
-
* - indexClass is populated only when class is present
|
|
674
|
-
* - indexType is populated only when type is present
|
|
675
|
-
* - indexXid is populated only when xid is present
|
|
676
|
-
*
|
|
677
|
-
* @param entity - The entity to populate index keys for
|
|
678
|
-
* @param suffix - Optional suffix to append to all index keys (e.g., "#deleted", "#archived")
|
|
679
|
-
* @returns The entity with populated index keys
|
|
680
|
-
*/
|
|
681
|
-
function indexEntity$1(entity, suffix = "") {
|
|
682
|
-
const result = { ...entity };
|
|
683
|
-
// indexOu is always set (from ou + model)
|
|
684
|
-
result.indexOu = buildIndexOu$1(entity.ou, entity.model) + suffix;
|
|
685
|
-
// Optional indexes - only set when the source field is present
|
|
686
|
-
if (entity.alias !== undefined) {
|
|
687
|
-
result.indexAlias =
|
|
688
|
-
buildIndexAlias$1(entity.ou, entity.model, entity.alias) + suffix;
|
|
689
|
-
}
|
|
690
|
-
if (entity.class !== undefined) {
|
|
691
|
-
result.indexClass =
|
|
692
|
-
buildIndexClass$1(entity.ou, entity.model, entity.class) + suffix;
|
|
693
|
-
}
|
|
694
|
-
if (entity.type !== undefined) {
|
|
695
|
-
result.indexType =
|
|
696
|
-
buildIndexType$1(entity.ou, entity.model, entity.type) + suffix;
|
|
697
|
-
}
|
|
698
|
-
if (entity.xid !== undefined) {
|
|
699
|
-
result.indexXid =
|
|
700
|
-
buildIndexXid$1(entity.ou, entity.model, entity.xid) + suffix;
|
|
701
|
-
}
|
|
702
|
-
return result;
|
|
703
|
-
}
|
|
704
|
-
|
|
705
597
|
// Re-export constants (no need to mock, just pass through)
|
|
706
|
-
const APEX = APEX
|
|
707
|
-
const ARCHIVED_SUFFIX = ARCHIVED_SUFFIX
|
|
708
|
-
const DELETED_SUFFIX = DELETED_SUFFIX
|
|
709
|
-
const INDEX_ALIAS = INDEX_ALIAS
|
|
710
|
-
const INDEX_CLASS = INDEX_CLASS
|
|
711
|
-
const INDEX_OU = INDEX_OU
|
|
712
|
-
const INDEX_TYPE = INDEX_TYPE
|
|
713
|
-
const INDEX_XID = INDEX_XID
|
|
714
|
-
const SEPARATOR = SEPARATOR
|
|
598
|
+
const APEX = original$2.APEX;
|
|
599
|
+
const ARCHIVED_SUFFIX = original$2.ARCHIVED_SUFFIX;
|
|
600
|
+
const DELETED_SUFFIX = original$2.DELETED_SUFFIX;
|
|
601
|
+
const INDEX_ALIAS = original$2.INDEX_ALIAS;
|
|
602
|
+
const INDEX_CLASS = original$2.INDEX_CLASS;
|
|
603
|
+
const INDEX_OU = original$2.INDEX_OU;
|
|
604
|
+
const INDEX_TYPE = original$2.INDEX_TYPE;
|
|
605
|
+
const INDEX_XID = original$2.INDEX_XID;
|
|
606
|
+
const SEPARATOR = original$2.SEPARATOR;
|
|
715
607
|
// Key builder functions - use createMockFunction with typed implementations
|
|
716
|
-
const buildIndexAlias = createMockFunction((ou, model, alias) => buildIndexAlias
|
|
717
|
-
const buildIndexClass = createMockFunction((ou, model, recordClass) => buildIndexClass
|
|
718
|
-
const buildIndexOu = createMockFunction((ou, model) => buildIndexOu
|
|
719
|
-
const buildIndexType = createMockFunction((ou, model, type) => buildIndexType
|
|
720
|
-
const buildIndexXid = createMockFunction((ou, model, xid) => buildIndexXid
|
|
721
|
-
const calculateOu = createMockFunction((parent) => calculateOu
|
|
722
|
-
const indexEntity = createMockFunction((entity, suffix) => indexEntity
|
|
608
|
+
const buildIndexAlias = createMockFunction((ou, model, alias) => original$2.buildIndexAlias(ou, model, alias));
|
|
609
|
+
const buildIndexClass = createMockFunction((ou, model, recordClass) => original$2.buildIndexClass(ou, model, recordClass));
|
|
610
|
+
const buildIndexOu = createMockFunction((ou, model) => original$2.buildIndexOu(ou, model));
|
|
611
|
+
const buildIndexType = createMockFunction((ou, model, type) => original$2.buildIndexType(ou, model, type));
|
|
612
|
+
const buildIndexXid = createMockFunction((ou, model, xid) => original$2.buildIndexXid(ou, model, xid));
|
|
613
|
+
const calculateOu = createMockFunction((parent) => original$2.calculateOu(parent));
|
|
614
|
+
const indexEntity = createMockFunction((entity, suffix) => original$2.indexEntity(entity, suffix));
|
|
723
615
|
// Client functions
|
|
724
616
|
const initClient = createMockFunction(() => {
|
|
725
617
|
// No-op in mock
|
|
@@ -732,17 +624,17 @@ const isInitialized = createMockFunction(() => true);
|
|
|
732
624
|
const resetClient = createMockFunction(() => {
|
|
733
625
|
// No-op in mock
|
|
734
626
|
});
|
|
735
|
-
// Entity operations -
|
|
627
|
+
// Entity operations - service handler pattern (callable with object params)
|
|
736
628
|
const getEntity = createMockFunction(async () => null);
|
|
737
|
-
const putEntity = createMockFunction(async (params) => indexEntity
|
|
629
|
+
const putEntity = createMockFunction(async (params) => original$2.indexEntity(params.entity));
|
|
738
630
|
const updateEntity = createMockFunction(async (params) => ({
|
|
739
|
-
...indexEntity
|
|
631
|
+
...original$2.indexEntity(params.entity),
|
|
740
632
|
updatedAt: new Date().toISOString(),
|
|
741
633
|
}));
|
|
742
634
|
const deleteEntity = createMockFunction(async () => true);
|
|
743
635
|
const archiveEntity = createMockFunction(async () => true);
|
|
744
636
|
const destroyEntity = createMockFunction(async () => true);
|
|
745
|
-
// Query functions -
|
|
637
|
+
// Query functions - service handler pattern (callable with object params)
|
|
746
638
|
const queryByOu = createMockFunction(async () => ({
|
|
747
639
|
items: [],
|
|
748
640
|
lastEvaluatedKey: undefined,
|
|
@@ -757,6 +649,18 @@ const queryByType = createMockFunction(async () => ({
|
|
|
757
649
|
lastEvaluatedKey: undefined,
|
|
758
650
|
}));
|
|
759
651
|
const queryByXid = createMockFunction(async () => null);
|
|
652
|
+
// Seed and export utilities
|
|
653
|
+
const seedEntityIfNotExists = createMockFunction(async () => true);
|
|
654
|
+
const seedEntities = createMockFunction(async () => ({
|
|
655
|
+
created: [],
|
|
656
|
+
errors: [],
|
|
657
|
+
skipped: [],
|
|
658
|
+
}));
|
|
659
|
+
const exportEntities = createMockFunction(async () => ({
|
|
660
|
+
count: 0,
|
|
661
|
+
entities: [],
|
|
662
|
+
}));
|
|
663
|
+
const exportEntitiesToJson = createMockFunction(async () => "[]");
|
|
760
664
|
|
|
761
665
|
var dynamodb = /*#__PURE__*/Object.freeze({
|
|
762
666
|
__proto__: null,
|
|
@@ -778,6 +682,8 @@ var dynamodb = /*#__PURE__*/Object.freeze({
|
|
|
778
682
|
calculateOu: calculateOu,
|
|
779
683
|
deleteEntity: deleteEntity,
|
|
780
684
|
destroyEntity: destroyEntity,
|
|
685
|
+
exportEntities: exportEntities,
|
|
686
|
+
exportEntitiesToJson: exportEntitiesToJson,
|
|
781
687
|
getDocClient: getDocClient,
|
|
782
688
|
getEntity: getEntity,
|
|
783
689
|
getTableName: getTableName,
|
|
@@ -791,6 +697,8 @@ var dynamodb = /*#__PURE__*/Object.freeze({
|
|
|
791
697
|
queryByType: queryByType,
|
|
792
698
|
queryByXid: queryByXid,
|
|
793
699
|
resetClient: resetClient,
|
|
700
|
+
seedEntities: seedEntities,
|
|
701
|
+
seedEntityIfNotExists: seedEntityIfNotExists,
|
|
794
702
|
updateEntity: updateEntity
|
|
795
703
|
});
|
|
796
704
|
|
|
@@ -800,25 +708,27 @@ const TAG$1 = "EXPRESS";
|
|
|
800
708
|
const HTTP = {
|
|
801
709
|
CODE: { OK: 200, CREATED: 201, NO_CONTENT: 204, INTERNAL_ERROR: 500 },
|
|
802
710
|
};
|
|
803
|
-
const EXPRESS = original$
|
|
711
|
+
const EXPRESS = original$3.EXPRESS;
|
|
804
712
|
// Add Express route functions
|
|
805
|
-
const badRequestRoute = createMockWrappedFunction(original$
|
|
806
|
-
const echoRoute = createMockWrappedFunction(original$
|
|
807
|
-
const forbiddenRoute = createMockWrappedFunction(original$
|
|
808
|
-
const goneRoute = createMockWrappedFunction(original$
|
|
713
|
+
const badRequestRoute = createMockWrappedFunction(original$3.badRequestRoute, { error: `_MOCK_BAD_REQUEST_ROUTE_[${TAG$1}]` });
|
|
714
|
+
const echoRoute = createMockWrappedFunction(original$3.echoRoute, (req) => req);
|
|
715
|
+
const forbiddenRoute = createMockWrappedFunction(original$3.forbiddenRoute, { error: `_MOCK_FORBIDDEN_ROUTE_[${TAG$1}]` });
|
|
716
|
+
const goneRoute = createMockWrappedFunction(original$3.goneRoute, {
|
|
809
717
|
error: `_MOCK_GONE_ROUTE_[${TAG$1}]`,
|
|
810
718
|
});
|
|
811
|
-
const methodNotAllowedRoute = createMockWrappedFunction(original$
|
|
812
|
-
const noContentRoute = createMockWrappedFunction(original$
|
|
813
|
-
const notFoundRoute = createMockWrappedFunction(original$
|
|
719
|
+
const methodNotAllowedRoute = createMockWrappedFunction(original$3.methodNotAllowedRoute, { error: `_MOCK_METHOD_NOT_ALLOWED_ROUTE_[${TAG$1}]` });
|
|
720
|
+
const noContentRoute = createMockWrappedFunction(original$3.noContentRoute, { status: 204 });
|
|
721
|
+
const notFoundRoute = createMockWrappedFunction(original$3.notFoundRoute, {
|
|
814
722
|
error: `_MOCK_NOT_FOUND_ROUTE_[${TAG$1}]`,
|
|
815
723
|
});
|
|
816
|
-
const notImplementedRoute = createMockWrappedFunction(original$
|
|
817
|
-
const expressHttpCodeHandler = createMockWrappedFunction(original$
|
|
724
|
+
const notImplementedRoute = createMockWrappedFunction(original$3.notImplementedRoute, { error: `_MOCK_NOT_IMPLEMENTED_ROUTE_[${TAG$1}]` });
|
|
725
|
+
const expressHttpCodeHandler = createMockWrappedFunction(original$3.expressHttpCodeHandler, (...args) => {
|
|
818
726
|
const [, res] = args;
|
|
819
727
|
return res.status(200).send();
|
|
820
728
|
});
|
|
821
|
-
const cors = createMockWrappedFunction(original$
|
|
729
|
+
const cors = createMockWrappedFunction(original$3.cors);
|
|
730
|
+
const createServer = createMockResolvedFunction({ port: 8080, server: { close: () => { } } });
|
|
731
|
+
const getCurrentInvokeUuid = createMockReturnedFunction("mock-invoke-uuid-12345678");
|
|
822
732
|
const expressStreamHandler = createMockFunction((handlerOrProps, propsOrHandler) => {
|
|
823
733
|
let handler;
|
|
824
734
|
let props;
|
|
@@ -995,11 +905,13 @@ var express = /*#__PURE__*/Object.freeze({
|
|
|
995
905
|
EXPRESS: EXPRESS,
|
|
996
906
|
badRequestRoute: badRequestRoute,
|
|
997
907
|
cors: cors,
|
|
908
|
+
createServer: createServer,
|
|
998
909
|
echoRoute: echoRoute,
|
|
999
910
|
expressHandler: expressHandler,
|
|
1000
911
|
expressHttpCodeHandler: expressHttpCodeHandler,
|
|
1001
912
|
expressStreamHandler: expressStreamHandler,
|
|
1002
913
|
forbiddenRoute: forbiddenRoute,
|
|
914
|
+
getCurrentInvokeUuid: getCurrentInvokeUuid,
|
|
1003
915
|
goneRoute: goneRoute,
|
|
1004
916
|
methodNotAllowedRoute: methodNotAllowedRoute,
|
|
1005
917
|
noContentRoute: noContentRoute,
|
|
@@ -1059,7 +971,7 @@ var lambda = /*#__PURE__*/Object.freeze({
|
|
|
1059
971
|
lambdaStreamHandler: lambdaStreamHandler
|
|
1060
972
|
});
|
|
1061
973
|
|
|
1062
|
-
const LLM = original$
|
|
974
|
+
const LLM = original$4.LLM;
|
|
1063
975
|
const mockOperate = createMockResolvedFunction({
|
|
1064
976
|
content: "_MOCK_OUTPUT_TEXT",
|
|
1065
977
|
history: [
|
|
@@ -1131,36 +1043,36 @@ const weather = createMockTool("weather", createMockResolvedFunction({
|
|
|
1131
1043
|
location: `_MOCK_WEATHER_LOCATION`,
|
|
1132
1044
|
forecast: [{ conditions: "good" }],
|
|
1133
1045
|
}));
|
|
1134
|
-
const Toolkit = createMockWrappedObject(original$
|
|
1046
|
+
const Toolkit = createMockWrappedObject(original$4.Toolkit, {
|
|
1135
1047
|
isClass: true,
|
|
1136
1048
|
});
|
|
1137
|
-
const JaypieToolkit = createMockWrappedObject(original$
|
|
1049
|
+
const JaypieToolkit = createMockWrappedObject(original$4.JaypieToolkit, {
|
|
1138
1050
|
isClass: true,
|
|
1139
1051
|
});
|
|
1140
|
-
const LlmMessageRole = createMockWrappedObject(original$
|
|
1052
|
+
const LlmMessageRole = createMockWrappedObject(original$4.LlmMessageRole, {
|
|
1141
1053
|
isClass: true,
|
|
1142
1054
|
});
|
|
1143
|
-
const LlmMessageType = createMockWrappedObject(original$
|
|
1055
|
+
const LlmMessageType = createMockWrappedObject(original$4.LlmMessageType, {
|
|
1144
1056
|
isClass: true,
|
|
1145
1057
|
});
|
|
1146
|
-
const LlmStreamChunkType = createMockWrappedObject(original$
|
|
1058
|
+
const LlmStreamChunkType = createMockWrappedObject(original$4.LlmStreamChunkType, {
|
|
1147
1059
|
isClass: true,
|
|
1148
1060
|
});
|
|
1149
1061
|
// Provider mocks
|
|
1150
|
-
const GeminiProvider = createMockWrappedObject(original$
|
|
1062
|
+
const GeminiProvider = createMockWrappedObject(original$4.GeminiProvider, {
|
|
1151
1063
|
isClass: true,
|
|
1152
1064
|
});
|
|
1153
|
-
const OpenRouterProvider = createMockWrappedObject(original$
|
|
1065
|
+
const OpenRouterProvider = createMockWrappedObject(original$4.OpenRouterProvider, {
|
|
1154
1066
|
isClass: true,
|
|
1155
1067
|
});
|
|
1156
1068
|
// Type guards and utilities - re-export from original (these are pure functions)
|
|
1157
|
-
const extractReasoning = original$
|
|
1158
|
-
const isLlmOperateInput = original$
|
|
1159
|
-
const isLlmOperateInputContent = original$
|
|
1160
|
-
const isLlmOperateInputFile = original$
|
|
1161
|
-
const isLlmOperateInputImage = original$
|
|
1069
|
+
const extractReasoning = original$4.extractReasoning;
|
|
1070
|
+
const isLlmOperateInput = original$4.isLlmOperateInput;
|
|
1071
|
+
const isLlmOperateInputContent = original$4.isLlmOperateInputContent;
|
|
1072
|
+
const isLlmOperateInputFile = original$4.isLlmOperateInputFile;
|
|
1073
|
+
const isLlmOperateInputImage = original$4.isLlmOperateInputImage;
|
|
1162
1074
|
// Tool collections
|
|
1163
|
-
const toolkit = new original$
|
|
1075
|
+
const toolkit = new original$4.JaypieToolkit([
|
|
1164
1076
|
random,
|
|
1165
1077
|
roll,
|
|
1166
1078
|
time,
|
|
@@ -1226,18 +1138,18 @@ beforeAll(async () => {
|
|
|
1226
1138
|
/**
|
|
1227
1139
|
* Mock for MarkdownPage class from @jaypie/textract
|
|
1228
1140
|
*/
|
|
1229
|
-
const MarkdownPage = createMockWrappedObject(original$
|
|
1141
|
+
const MarkdownPage = createMockWrappedObject(original$5.MarkdownPage, {
|
|
1230
1142
|
class: true,
|
|
1231
1143
|
fallback: () => {
|
|
1232
1144
|
const mockDocument = new TextractDocument(JSON.parse(mockTextractContents));
|
|
1233
1145
|
// Double type assertion needed to bridge incompatible types
|
|
1234
|
-
return new original$
|
|
1146
|
+
return new original$5.MarkdownPage(mockDocument.pageNumber(1));
|
|
1235
1147
|
},
|
|
1236
1148
|
});
|
|
1237
1149
|
/**
|
|
1238
1150
|
* Mock for textractJsonToMarkdown function from @jaypie/textract
|
|
1239
1151
|
*/
|
|
1240
|
-
const textractJsonToMarkdown = createMockWrappedFunction(original$
|
|
1152
|
+
const textractJsonToMarkdown = createMockWrappedFunction(original$5.textractJsonToMarkdown, `_MOCK_TEXTRACT_JSON_TO_MARKDOWN_[${TAG}]`);
|
|
1241
1153
|
// Export default for convenience
|
|
1242
1154
|
var textract = {
|
|
1243
1155
|
MarkdownPage,
|
|
@@ -1411,5 +1323,5 @@ const mock = {
|
|
|
1411
1323
|
...vocabulary,
|
|
1412
1324
|
};
|
|
1413
1325
|
|
|
1414
|
-
export { APEX, ARCHIVED_SUFFIX, BadGatewayError, BadRequestError, ConfigurationError, CorsError, DATADOG, DELETED_SUFFIX, EXPRESS, ForbiddenError, GatewayTimeoutError, GeminiProvider, GoneError, HTTP$1 as HTTP, INDEX_ALIAS, INDEX_CLASS, INDEX_OU, INDEX_TYPE, INDEX_XID, IllogicalError, InternalError, JAYPIE, JaypieError, JaypieStream, JaypieToolkit, LLM, Llm, LlmMessageRole, LlmMessageType, LlmStreamChunkType, MarkdownPage, MethodNotAllowedError, MultiError, NotFoundError, NotImplementedError, OpenRouterProvider, PROJECT, ProjectError, ProjectMultiError, RejectedError, SEPARATOR, STATUS_VALUES, StatusType, TeapotError, TooManyRequestsError, Toolkit, UnauthorizedError, UnavailableError, UnhandledError, UnreachableCodeError, archiveEntity, badRequestRoute, buildIndexAlias, buildIndexClass, buildIndexOu, buildIndexType, buildIndexXid, calculateOu, cloneDeep, connect, connectFromSecretEnv, cors, createExpressStream, createJaypieStream, createLambdaStream, createLlmTool, createLogger, mock as default, deleteEntity, destroyEntity, disconnect, echoRoute, envBoolean, envsKey, errorFromStatusCode, expressHandler, expressHttpCodeHandler, expressStreamHandler, extractReasoning, forbiddenRoute, force, formatError, formatSSE, getDocClient, getEntity, getEnvSecret, getHeaderFrom, getMessages, getObjectKeyCaseInsensitive, getS3FileBuffer, getSecret, getSingletonMessage, getTableName, getTextractJob, goneRoute, hasDatadogEnv, indexEntity, initClient, inputToJsonSchema, isClass, isInitialized, isJaypieError, isLlmOperateInput, isLlmOperateInputContent, isLlmOperateInputFile, isLlmOperateInputImage, isLocalEnv, isNodeTestEnv, isProductionEnv, isStatus, jaypieErrorFromStatus, jaypieHandler, lambdaHandler, lambdaServiceHandler, lambdaStreamHandler, loadEnvSecrets, methodNotAllowedRoute, noContentRoute, notFoundRoute, notImplementedRoute, placeholders, putEntity, queryByAlias, queryByClass, queryByOu, queryByType, queryByXid, registerMcpTool, resetClient, resolveValue, safeParseFloat, sendBatchMessages, sendMessage, sendTextractJob, sleep, streamToSSE, submitDistribution, submitMetric, submitMetricSet, textractJsonToMarkdown, toolkit, tools, updateEntity, uuid };
|
|
1326
|
+
export { APEX, ARCHIVED_SUFFIX, BadGatewayError, BadRequestError, ConfigurationError, CorsError, DATADOG, DELETED_SUFFIX, EXPRESS, ForbiddenError, GatewayTimeoutError, GeminiProvider, GoneError, HTTP$1 as HTTP, INDEX_ALIAS, INDEX_CLASS, INDEX_OU, INDEX_TYPE, INDEX_XID, IllogicalError, InternalError, JAYPIE, JaypieError, JaypieStream, JaypieToolkit, LLM, Llm, LlmMessageRole, LlmMessageType, LlmStreamChunkType, MarkdownPage, MethodNotAllowedError, MultiError, NotFoundError, NotImplementedError, OpenRouterProvider, PROJECT, ProjectError, ProjectMultiError, RejectedError, SEPARATOR, STATUS_VALUES, StatusType, TeapotError, TooManyRequestsError, Toolkit, UnauthorizedError, UnavailableError, UnhandledError, UnreachableCodeError, archiveEntity, badRequestRoute, buildIndexAlias, buildIndexClass, buildIndexOu, buildIndexType, buildIndexXid, calculateOu, cloneDeep, connect, connectFromSecretEnv, cors, createExpressStream, createJaypieStream, createLambdaStream, createLlmTool, createLogger, createServer, mock as default, deleteEntity, destroyEntity, disconnect, echoRoute, envBoolean, envsKey, errorFromStatusCode, exportEntities, exportEntitiesToJson, expressHandler, expressHttpCodeHandler, expressStreamHandler, extractReasoning, forbiddenRoute, force, formatError, formatSSE, getCurrentInvokeUuid, getDocClient, getEntity, getEnvSecret, getHeaderFrom, getMessages, getObjectKeyCaseInsensitive, getS3FileBuffer, getSecret, getSingletonMessage, getTableName, getTextractJob, goneRoute, hasDatadogEnv, indexEntity, initClient, inputToJsonSchema, isClass, isInitialized, isJaypieError, isLlmOperateInput, isLlmOperateInputContent, isLlmOperateInputFile, isLlmOperateInputImage, isLocalEnv, isNodeTestEnv, isProductionEnv, isStatus, jaypieErrorFromStatus, jaypieHandler, lambdaHandler, lambdaServiceHandler, lambdaStreamHandler, loadEnvSecrets, methodNotAllowedRoute, noContentRoute, notFoundRoute, notImplementedRoute, placeholders, putEntity, queryByAlias, queryByClass, queryByOu, queryByType, queryByXid, registerMcpTool, resetClient, resolveValue, safeParseFloat, seedEntities, seedEntityIfNotExists, sendBatchMessages, sendMessage, sendTextractJob, sleep, streamToSSE, submitDistribution, submitMetric, submitMetricSet, textractJsonToMarkdown, toolkit, tools, updateEntity, uuid };
|
|
1415
1327
|
//# sourceMappingURL=index.js.map
|