@fluidframework/test-utils 2.0.0-dev-rc.2.0.0.246488 → 2.0.0-dev-rc.3.0.0.250606
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/api-report/test-utils.api.md +3 -2
- package/dist/TestSummaryUtils.d.ts +2 -2
- package/dist/TestSummaryUtils.d.ts.map +1 -1
- package/dist/TestSummaryUtils.js +2 -2
- package/dist/TestSummaryUtils.js.map +1 -1
- package/dist/containerUtils.d.ts.map +1 -1
- package/dist/containerUtils.js.map +1 -1
- package/dist/interfaces.d.ts +2 -2
- package/dist/interfaces.d.ts.map +1 -1
- package/dist/interfaces.js.map +1 -1
- package/dist/loaderContainerTracker.d.ts.map +1 -1
- package/dist/loaderContainerTracker.js +1 -1
- package/dist/loaderContainerTracker.js.map +1 -1
- package/dist/localCodeLoader.d.ts +2 -2
- package/dist/localCodeLoader.d.ts.map +1 -1
- package/dist/localCodeLoader.js.map +1 -1
- package/dist/localLoader.d.ts +2 -2
- package/dist/localLoader.d.ts.map +1 -1
- package/dist/localLoader.js.map +1 -1
- package/dist/packageVersion.d.ts +1 -1
- package/dist/packageVersion.js +1 -1
- package/dist/packageVersion.js.map +1 -1
- package/dist/test-utils-untrimmed.d.ts +6 -2
- package/dist/testContainerRuntimeFactory.d.ts.map +1 -1
- package/dist/testContainerRuntimeFactory.js +1 -1
- package/dist/testContainerRuntimeFactory.js.map +1 -1
- package/dist/testFluidObject.d.ts +3 -3
- package/dist/testFluidObject.d.ts.map +1 -1
- package/dist/testFluidObject.js +1 -1
- package/dist/testFluidObject.js.map +1 -1
- package/dist/testObjectProvider.d.ts +9 -5
- package/dist/testObjectProvider.d.ts.map +1 -1
- package/dist/testObjectProvider.js +6 -3
- package/dist/testObjectProvider.js.map +1 -1
- package/lib/TestSummaryUtils.d.ts +2 -2
- package/lib/TestSummaryUtils.d.ts.map +1 -1
- package/lib/TestSummaryUtils.js +2 -2
- package/lib/TestSummaryUtils.js.map +1 -1
- package/lib/containerUtils.d.ts.map +1 -1
- package/lib/containerUtils.js.map +1 -1
- package/lib/interfaces.d.ts +2 -2
- package/lib/interfaces.d.ts.map +1 -1
- package/lib/interfaces.js.map +1 -1
- package/lib/loaderContainerTracker.d.ts.map +1 -1
- package/lib/loaderContainerTracker.js +1 -1
- package/lib/loaderContainerTracker.js.map +1 -1
- package/lib/localCodeLoader.d.ts +2 -2
- package/lib/localCodeLoader.d.ts.map +1 -1
- package/lib/localCodeLoader.js.map +1 -1
- package/lib/localLoader.d.ts +2 -2
- package/lib/localLoader.d.ts.map +1 -1
- package/lib/localLoader.js.map +1 -1
- package/lib/packageVersion.d.ts +1 -1
- package/lib/packageVersion.js +1 -1
- package/lib/packageVersion.js.map +1 -1
- package/lib/test-utils-untrimmed.d.ts +6 -2
- package/lib/testContainerRuntimeFactory.d.ts.map +1 -1
- package/lib/testContainerRuntimeFactory.js +1 -1
- package/lib/testContainerRuntimeFactory.js.map +1 -1
- package/lib/testFluidObject.d.ts +3 -3
- package/lib/testFluidObject.d.ts.map +1 -1
- package/lib/testFluidObject.js +1 -1
- package/lib/testFluidObject.js.map +1 -1
- package/lib/testObjectProvider.d.ts +9 -5
- package/lib/testObjectProvider.d.ts.map +1 -1
- package/lib/testObjectProvider.js +6 -3
- package/lib/testObjectProvider.js.map +1 -1
- package/package.json +29 -26
- package/src/TestSummaryUtils.ts +6 -6
- package/src/containerUtils.ts +1 -1
- package/src/interfaces.ts +2 -2
- package/src/loaderContainerTracker.ts +6 -6
- package/src/localCodeLoader.ts +5 -5
- package/src/localLoader.ts +3 -3
- package/src/packageVersion.ts +1 -1
- package/src/testContainerRuntimeFactory.ts +3 -3
- package/src/testFluidObject.ts +6 -6
- package/src/testObjectProvider.ts +18 -7
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluidframework/test-utils",
|
|
3
|
-
"version": "2.0.0-dev-rc.
|
|
3
|
+
"version": "2.0.0-dev-rc.3.0.0.250606",
|
|
4
4
|
"description": "Utilities for Fluid tests",
|
|
5
5
|
"homepage": "https://fluidframework.com",
|
|
6
6
|
"repository": {
|
|
@@ -77,26 +77,26 @@
|
|
|
77
77
|
"temp-directory": "nyc/.nyc_output"
|
|
78
78
|
},
|
|
79
79
|
"dependencies": {
|
|
80
|
-
"@fluidframework/aqueduct": "2.0.0-dev-rc.
|
|
81
|
-
"@fluidframework/container-definitions": "2.0.0-dev-rc.
|
|
82
|
-
"@fluidframework/container-loader": "2.0.0-dev-rc.
|
|
83
|
-
"@fluidframework/container-runtime": "2.0.0-dev-rc.
|
|
84
|
-
"@fluidframework/container-runtime-definitions": "2.0.0-dev-rc.
|
|
85
|
-
"@fluidframework/core-interfaces": "2.0.0-dev-rc.
|
|
86
|
-
"@fluidframework/core-utils": "2.0.0-dev-rc.
|
|
87
|
-
"@fluidframework/datastore": "2.0.0-dev-rc.
|
|
88
|
-
"@fluidframework/datastore-definitions": "2.0.0-dev-rc.
|
|
89
|
-
"@fluidframework/driver-definitions": "2.0.0-dev-rc.
|
|
90
|
-
"@fluidframework/driver-utils": "2.0.0-dev-rc.
|
|
91
|
-
"@fluidframework/local-driver": "2.0.0-dev-rc.
|
|
92
|
-
"@fluidframework/map": "2.0.0-dev-rc.
|
|
80
|
+
"@fluidframework/aqueduct": "2.0.0-dev-rc.3.0.0.250606",
|
|
81
|
+
"@fluidframework/container-definitions": "2.0.0-dev-rc.3.0.0.250606",
|
|
82
|
+
"@fluidframework/container-loader": "2.0.0-dev-rc.3.0.0.250606",
|
|
83
|
+
"@fluidframework/container-runtime": "2.0.0-dev-rc.3.0.0.250606",
|
|
84
|
+
"@fluidframework/container-runtime-definitions": "2.0.0-dev-rc.3.0.0.250606",
|
|
85
|
+
"@fluidframework/core-interfaces": "2.0.0-dev-rc.3.0.0.250606",
|
|
86
|
+
"@fluidframework/core-utils": "2.0.0-dev-rc.3.0.0.250606",
|
|
87
|
+
"@fluidframework/datastore": "2.0.0-dev-rc.3.0.0.250606",
|
|
88
|
+
"@fluidframework/datastore-definitions": "2.0.0-dev-rc.3.0.0.250606",
|
|
89
|
+
"@fluidframework/driver-definitions": "2.0.0-dev-rc.3.0.0.250606",
|
|
90
|
+
"@fluidframework/driver-utils": "2.0.0-dev-rc.3.0.0.250606",
|
|
91
|
+
"@fluidframework/local-driver": "2.0.0-dev-rc.3.0.0.250606",
|
|
92
|
+
"@fluidframework/map": "2.0.0-dev-rc.3.0.0.250606",
|
|
93
93
|
"@fluidframework/protocol-definitions": "^3.2.0",
|
|
94
|
-
"@fluidframework/request-handler": "2.0.0-dev-rc.
|
|
95
|
-
"@fluidframework/routerlicious-driver": "2.0.0-dev-rc.
|
|
96
|
-
"@fluidframework/runtime-definitions": "2.0.0-dev-rc.
|
|
97
|
-
"@fluidframework/runtime-utils": "2.0.0-dev-rc.
|
|
98
|
-
"@fluidframework/telemetry-utils": "2.0.0-dev-rc.
|
|
99
|
-
"@fluidframework/test-driver-definitions": "2.0.0-dev-rc.
|
|
94
|
+
"@fluidframework/request-handler": "2.0.0-dev-rc.3.0.0.250606",
|
|
95
|
+
"@fluidframework/routerlicious-driver": "2.0.0-dev-rc.3.0.0.250606",
|
|
96
|
+
"@fluidframework/runtime-definitions": "2.0.0-dev-rc.3.0.0.250606",
|
|
97
|
+
"@fluidframework/runtime-utils": "2.0.0-dev-rc.3.0.0.250606",
|
|
98
|
+
"@fluidframework/telemetry-utils": "2.0.0-dev-rc.3.0.0.250606",
|
|
99
|
+
"@fluidframework/test-driver-definitions": "2.0.0-dev-rc.3.0.0.250606",
|
|
100
100
|
"best-random": "^1.0.0",
|
|
101
101
|
"debug": "^4.3.4",
|
|
102
102
|
"mocha": "^10.2.0",
|
|
@@ -104,7 +104,8 @@
|
|
|
104
104
|
},
|
|
105
105
|
"devDependencies": {
|
|
106
106
|
"@arethetypeswrong/cli": "^0.13.3",
|
|
107
|
-
"@
|
|
107
|
+
"@biomejs/biome": "^1.6.2",
|
|
108
|
+
"@fluid-internal/mocha-test-setup": "2.0.0-dev-rc.3.0.0.250606",
|
|
108
109
|
"@fluid-tools/build-cli": "^0.34.0",
|
|
109
110
|
"@fluidframework/build-common": "^2.0.3",
|
|
110
111
|
"@fluidframework/build-tools": "^0.34.0",
|
|
@@ -175,16 +176,18 @@
|
|
|
175
176
|
"build:test:cjs": "fluid-tsc commonjs --project ./src/test/tsconfig.cjs.json",
|
|
176
177
|
"build:test:esm": "tsc --project ./src/test/tsconfig.json",
|
|
177
178
|
"check:are-the-types-wrong": "attw --pack . --entrypoints .",
|
|
179
|
+
"check:biome": "biome check .",
|
|
180
|
+
"check:prettier": "prettier --check . --cache --ignore-path ../../../.prettierignore",
|
|
178
181
|
"check:release-tags": "api-extractor run --local --config ./api-extractor-lint.json",
|
|
179
182
|
"ci:build:docs": "api-extractor run",
|
|
180
183
|
"clean": "rimraf --glob dist lib \"**/*.tsbuildinfo\" \"**/*.build.log\" _api-extractor-temp nyc",
|
|
181
184
|
"eslint": "eslint --format stylish src",
|
|
182
185
|
"eslint:fix": "eslint --format stylish src --fix --fix-type problem,suggestion,layout",
|
|
183
|
-
"format": "
|
|
184
|
-
"
|
|
185
|
-
"
|
|
186
|
-
"
|
|
187
|
-
"
|
|
186
|
+
"format": "fluid-build --task format .",
|
|
187
|
+
"format:biome": "biome check --apply .",
|
|
188
|
+
"format:prettier": "prettier --write . --cache --ignore-path ../../../.prettierignore",
|
|
189
|
+
"lint": "fluid-build . --task lint",
|
|
190
|
+
"lint:fix": "fluid-build . --task eslint:fix --task format",
|
|
188
191
|
"test": "npm run test:mocha",
|
|
189
192
|
"test:mocha": "npm run test:mocha:esm && echo skipping cjs to avoid overhead - npm run test:mocha:cjs",
|
|
190
193
|
"test:mocha:cjs": "mocha --recursive \"dist/test/**/*.spec.*js\" --exit",
|
package/src/TestSummaryUtils.ts
CHANGED
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
import { ContainerRuntimeFactoryWithDefaultDataStore } from "@fluidframework/aqueduct";
|
|
7
|
-
import { assert } from "@fluidframework/core-utils";
|
|
8
7
|
import { IContainer, IHostLoader, LoaderHeader } from "@fluidframework/container-definitions";
|
|
9
8
|
import {
|
|
10
9
|
IOnDemandSummarizeOptions,
|
|
@@ -12,22 +11,23 @@ import {
|
|
|
12
11
|
ISummaryRuntimeOptions,
|
|
13
12
|
} from "@fluidframework/container-runtime";
|
|
14
13
|
import {
|
|
15
|
-
ITelemetryBaseLogger,
|
|
16
|
-
IRequest,
|
|
17
14
|
IConfigProviderBase,
|
|
15
|
+
IRequest,
|
|
18
16
|
IResponse,
|
|
17
|
+
ITelemetryBaseLogger,
|
|
19
18
|
} from "@fluidframework/core-interfaces";
|
|
19
|
+
import { assert } from "@fluidframework/core-utils";
|
|
20
20
|
import { DriverHeader } from "@fluidframework/driver-definitions";
|
|
21
|
+
import { ISummaryTree } from "@fluidframework/protocol-definitions";
|
|
21
22
|
import {
|
|
22
23
|
IFluidDataStoreFactory,
|
|
23
24
|
NamedFluidDataStoreRegistryEntries,
|
|
24
25
|
} from "@fluidframework/runtime-definitions";
|
|
25
|
-
import { ISummaryTree } from "@fluidframework/protocol-definitions";
|
|
26
|
-
import { ITestContainerConfig, ITestObjectProvider } from "./testObjectProvider.js";
|
|
27
26
|
import { createTestConfigProvider } from "./TestConfigs.js";
|
|
28
27
|
import { waitForContainerConnection } from "./containerUtils.js";
|
|
29
|
-
import { timeoutAwait } from "./timeoutUtils.js";
|
|
30
28
|
import { createContainerRuntimeFactoryWithDefaultDataStore } from "./testContainerRuntimeFactoryWithDefaultDataStore.js";
|
|
29
|
+
import { ITestContainerConfig, ITestObjectProvider } from "./testObjectProvider.js";
|
|
30
|
+
import { timeoutAwait } from "./timeoutUtils.js";
|
|
31
31
|
|
|
32
32
|
const summarizerClientType = "summarizer";
|
|
33
33
|
|
package/src/containerUtils.ts
CHANGED
|
@@ -8,7 +8,7 @@ import { ConnectionState } from "@fluidframework/container-loader";
|
|
|
8
8
|
import { IResponse } from "@fluidframework/core-interfaces";
|
|
9
9
|
import { assert } from "@fluidframework/core-utils";
|
|
10
10
|
import { IDataStore } from "@fluidframework/runtime-definitions";
|
|
11
|
-
import { PromiseExecutor,
|
|
11
|
+
import { PromiseExecutor, TimeoutWithError, timeoutPromise } from "./timeoutUtils.js";
|
|
12
12
|
|
|
13
13
|
/**
|
|
14
14
|
* Utility function to wait for the specified Container to be in Connected state.
|
package/src/interfaces.ts
CHANGED
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
+
import { IFluidLoadable } from "@fluidframework/core-interfaces";
|
|
6
7
|
import { IFluidDataStoreRuntime } from "@fluidframework/datastore-definitions";
|
|
7
8
|
import { ISharedMap } from "@fluidframework/map";
|
|
8
9
|
import {
|
|
9
|
-
IFluidDataStoreContext,
|
|
10
10
|
IFluidDataStoreChannel,
|
|
11
|
+
IFluidDataStoreContext,
|
|
11
12
|
} from "@fluidframework/runtime-definitions";
|
|
12
|
-
import { IFluidLoadable } from "@fluidframework/core-interfaces";
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* @alpha
|
|
@@ -3,20 +3,20 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { assert } from "@fluidframework/core-utils";
|
|
7
6
|
import { IContainer, IDeltaQueue, IHostLoader } from "@fluidframework/container-definitions";
|
|
8
7
|
import { ConnectionState } from "@fluidframework/container-loader";
|
|
8
|
+
import {
|
|
9
|
+
IContainerCreateProps,
|
|
10
|
+
IContainerLoadProps,
|
|
11
|
+
// eslint-disable-next-line import/no-internal-modules
|
|
12
|
+
} from "@fluidframework/container-loader/test/container";
|
|
13
|
+
import { assert } from "@fluidframework/core-utils";
|
|
9
14
|
import { canBeCoalescedByService } from "@fluidframework/driver-utils";
|
|
10
15
|
import {
|
|
11
16
|
IDocumentMessage,
|
|
12
17
|
ISequencedDocumentMessage,
|
|
13
18
|
MessageType,
|
|
14
19
|
} from "@fluidframework/protocol-definitions";
|
|
15
|
-
import {
|
|
16
|
-
IContainerCreateProps,
|
|
17
|
-
IContainerLoadProps,
|
|
18
|
-
// eslint-disable-next-line import/no-internal-modules
|
|
19
|
-
} from "@fluidframework/container-loader/test/container";
|
|
20
20
|
import { waitForContainerConnection } from "./containerUtils.js";
|
|
21
21
|
import { debug } from "./debug.js";
|
|
22
22
|
import { IOpProcessingController } from "./testObjectProvider.js";
|
package/src/localCodeLoader.ts
CHANGED
|
@@ -6,19 +6,19 @@
|
|
|
6
6
|
import assert from "assert";
|
|
7
7
|
import { ContainerRuntimeFactoryWithDefaultDataStore } from "@fluidframework/aqueduct";
|
|
8
8
|
import {
|
|
9
|
-
IProvideRuntimeFactory,
|
|
10
|
-
IFluidModule,
|
|
11
|
-
IProvideFluidCodeDetailsComparer,
|
|
12
|
-
IFluidCodeDetails,
|
|
13
9
|
ICodeDetailsLoader,
|
|
10
|
+
IFluidCodeDetails,
|
|
11
|
+
IFluidModule,
|
|
14
12
|
IFluidModuleWithDetails,
|
|
13
|
+
IProvideFluidCodeDetailsComparer,
|
|
14
|
+
IProvideRuntimeFactory,
|
|
15
15
|
} from "@fluidframework/container-definitions";
|
|
16
|
+
import { IContainerRuntimeOptions } from "@fluidframework/container-runtime";
|
|
16
17
|
import {
|
|
17
18
|
IProvideFluidDataStoreFactory,
|
|
18
19
|
IProvideFluidDataStoreRegistry,
|
|
19
20
|
} from "@fluidframework/runtime-definitions";
|
|
20
21
|
import { createDataStoreFactory } from "@fluidframework/runtime-utils";
|
|
21
|
-
import { IContainerRuntimeOptions } from "@fluidframework/container-runtime";
|
|
22
22
|
|
|
23
23
|
/**
|
|
24
24
|
* @internal
|
package/src/localLoader.ts
CHANGED
|
@@ -6,14 +6,14 @@
|
|
|
6
6
|
import {
|
|
7
7
|
ICodeDetailsLoader,
|
|
8
8
|
IContainer,
|
|
9
|
+
IFluidCodeDetails,
|
|
9
10
|
IHostLoader,
|
|
10
11
|
ILoaderOptions,
|
|
11
|
-
IFluidCodeDetails,
|
|
12
12
|
} from "@fluidframework/container-definitions";
|
|
13
13
|
import { Loader } from "@fluidframework/container-loader";
|
|
14
|
-
import {
|
|
14
|
+
import { IRequest, ITelemetryBaseLogger } from "@fluidframework/core-interfaces";
|
|
15
15
|
import { IDocumentServiceFactory, IUrlResolver } from "@fluidframework/driver-definitions";
|
|
16
|
-
import {
|
|
16
|
+
import { LocalCodeLoader, fluidEntryPoint } from "./localCodeLoader.js";
|
|
17
17
|
|
|
18
18
|
/**
|
|
19
19
|
* Creates a loader with the given package entries and driver.
|
package/src/packageVersion.ts
CHANGED
|
@@ -3,12 +3,11 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { assert } from "@fluidframework/core-utils";
|
|
7
6
|
import { IContainerContext, IRuntime } from "@fluidframework/container-definitions";
|
|
8
7
|
import {
|
|
9
8
|
ContainerRuntime,
|
|
10
|
-
IContainerRuntimeOptions,
|
|
11
9
|
DefaultSummaryConfiguration,
|
|
10
|
+
IContainerRuntimeOptions,
|
|
12
11
|
} from "@fluidframework/container-runtime";
|
|
13
12
|
import { IContainerRuntime } from "@fluidframework/container-runtime-definitions";
|
|
14
13
|
import {
|
|
@@ -17,8 +16,9 @@ import {
|
|
|
17
16
|
IRequest,
|
|
18
17
|
IResponse,
|
|
19
18
|
} from "@fluidframework/core-interfaces";
|
|
19
|
+
import { assert } from "@fluidframework/core-utils";
|
|
20
20
|
// eslint-disable-next-line import/no-deprecated
|
|
21
|
-
import {
|
|
21
|
+
import { RuntimeRequestHandler, buildRuntimeRequestHandler } from "@fluidframework/request-handler";
|
|
22
22
|
import {
|
|
23
23
|
IFluidDataStoreFactory,
|
|
24
24
|
NamedFluidDataStoreRegistryEntries,
|
package/src/testFluidObject.ts
CHANGED
|
@@ -3,20 +3,20 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { IRequest, IResponse
|
|
6
|
+
import { IFluidHandle, IRequest, IResponse } from "@fluidframework/core-interfaces";
|
|
7
|
+
import { assert } from "@fluidframework/core-utils";
|
|
7
8
|
import {
|
|
8
|
-
FluidObjectHandle,
|
|
9
9
|
FluidDataStoreRuntime,
|
|
10
|
+
FluidObjectHandle,
|
|
10
11
|
mixinRequestHandler,
|
|
11
12
|
} from "@fluidframework/datastore";
|
|
12
|
-
import {
|
|
13
|
+
import { IChannelFactory, IFluidDataStoreRuntime } from "@fluidframework/datastore-definitions";
|
|
14
|
+
import { ISharedMap, SharedMap } from "@fluidframework/map";
|
|
13
15
|
import {
|
|
16
|
+
IFluidDataStoreChannel,
|
|
14
17
|
IFluidDataStoreContext,
|
|
15
18
|
IFluidDataStoreFactory,
|
|
16
|
-
IFluidDataStoreChannel,
|
|
17
19
|
} from "@fluidframework/runtime-definitions";
|
|
18
|
-
import { IFluidDataStoreRuntime, IChannelFactory } from "@fluidframework/datastore-definitions";
|
|
19
|
-
import { assert } from "@fluidframework/core-utils";
|
|
20
20
|
import { create404Response } from "@fluidframework/runtime-utils";
|
|
21
21
|
import { ITestFluidObject } from "./interfaces.js";
|
|
22
22
|
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
|
|
6
6
|
import {
|
|
7
7
|
IContainer,
|
|
8
|
-
IHostLoader,
|
|
9
8
|
IFluidCodeDetails,
|
|
9
|
+
IHostLoader,
|
|
10
10
|
ILoader,
|
|
11
11
|
} from "@fluidframework/container-definitions";
|
|
12
12
|
import {
|
|
@@ -16,24 +16,24 @@ import {
|
|
|
16
16
|
} from "@fluidframework/container-loader";
|
|
17
17
|
import { IContainerRuntimeOptions } from "@fluidframework/container-runtime";
|
|
18
18
|
import {
|
|
19
|
-
ITelemetryBaseLogger,
|
|
20
|
-
ITelemetryBaseEvent,
|
|
21
19
|
IRequestHeader,
|
|
20
|
+
ITelemetryBaseEvent,
|
|
21
|
+
ITelemetryBaseLogger,
|
|
22
22
|
} from "@fluidframework/core-interfaces";
|
|
23
23
|
import {
|
|
24
24
|
IDocumentServiceFactory,
|
|
25
25
|
IResolvedUrl,
|
|
26
26
|
IUrlResolver,
|
|
27
27
|
} from "@fluidframework/driver-definitions";
|
|
28
|
-
import { ITestDriver, TestDriverTypes } from "@fluidframework/test-driver-definitions";
|
|
29
|
-
import { v4 as uuid } from "uuid";
|
|
30
28
|
import {
|
|
29
|
+
type ITelemetryGenericEventExt,
|
|
31
30
|
createChildLogger,
|
|
32
31
|
createMultiSinkLogger,
|
|
33
|
-
type ITelemetryGenericEventExt,
|
|
34
32
|
} from "@fluidframework/telemetry-utils";
|
|
33
|
+
import { ITestDriver, TestDriverTypes } from "@fluidframework/test-driver-definitions";
|
|
34
|
+
import { v4 as uuid } from "uuid";
|
|
35
35
|
import { LoaderContainerTracker } from "./loaderContainerTracker.js";
|
|
36
|
-
import {
|
|
36
|
+
import { LocalCodeLoader, fluidEntryPoint } from "./localCodeLoader.js";
|
|
37
37
|
import { createAndAttachContainer } from "./localLoader.js";
|
|
38
38
|
import { ChannelFactoryRegistry } from "./testFluidObject.js";
|
|
39
39
|
|
|
@@ -108,10 +108,13 @@ export interface ITestObjectProvider {
|
|
|
108
108
|
* containerRuntime/dataRuntime used in fluidEntryPoint will be used as is from what is passed in.
|
|
109
109
|
*
|
|
110
110
|
* @param packageEntries - list of code details and fluidEntryPoint pairs.
|
|
111
|
+
* @param loaderProps - Optional loader properties
|
|
112
|
+
* @param forceUseCreateVersion - For Cross-Version compat testing, create a loader based on the create version
|
|
111
113
|
*/
|
|
112
114
|
createLoader(
|
|
113
115
|
packageEntries: Iterable<[IFluidCodeDetails, fluidEntryPoint]>,
|
|
114
116
|
loaderProps?: Partial<ILoaderProps>,
|
|
117
|
+
forceUseCreateVersion?: boolean,
|
|
115
118
|
): IHostLoader;
|
|
116
119
|
|
|
117
120
|
/**
|
|
@@ -221,6 +224,9 @@ export interface ITestContainerConfig {
|
|
|
221
224
|
/** Whether this runtime should be instantiated using a mixed-in attributor class */
|
|
222
225
|
enableAttribution?: boolean;
|
|
223
226
|
|
|
227
|
+
/** For Cross-Version compat testing, load using the create version (e.g. use this to get a Summarizer on the create version) */
|
|
228
|
+
forceUseCreateVersion?: true;
|
|
229
|
+
|
|
224
230
|
/** Loader options for the loader used to create containers */
|
|
225
231
|
loaderProps?: Partial<ILoaderProps>;
|
|
226
232
|
}
|
|
@@ -832,10 +838,14 @@ export class TestObjectProviderWithVersionedLoad implements ITestObjectProvider
|
|
|
832
838
|
public createLoader(
|
|
833
839
|
packageEntries: Iterable<[IFluidCodeDetails, fluidEntryPoint]>,
|
|
834
840
|
loaderProps?: Partial<ILoaderProps>,
|
|
841
|
+
forceUseCreateVersion = false,
|
|
835
842
|
) {
|
|
843
|
+
const useCreateVersion = forceUseCreateVersion === true || this.useCreateApi;
|
|
836
844
|
if (this.useCreateApi) {
|
|
837
845
|
// After we create the first loader, we can set this.useCreateApi to false.
|
|
838
846
|
this.useCreateApi = false;
|
|
847
|
+
}
|
|
848
|
+
if (useCreateVersion) {
|
|
839
849
|
return this.createLoaderForCreating(packageEntries, loaderProps);
|
|
840
850
|
}
|
|
841
851
|
return this.createLoaderForLoading(packageEntries, loaderProps);
|
|
@@ -925,6 +935,7 @@ export class TestObjectProviderWithVersionedLoad implements ITestObjectProvider
|
|
|
925
935
|
return this.createLoader(
|
|
926
936
|
[[defaultCodeDetails, this.createFluidEntryPoint(testContainerConfig)]],
|
|
927
937
|
testContainerConfig?.loaderProps,
|
|
938
|
+
testContainerConfig?.forceUseCreateVersion,
|
|
928
939
|
);
|
|
929
940
|
}
|
|
930
941
|
|