These changes add support for mocking the resource monitor to the NodeJS and Python SDKs. The proposed mock interface is a simplified version of the standard resource monitor that allows an end-user to replace the usual implementations of ReadResource/RegisterResource and Invoke with their own. This can be used in unit tests to allow for precise control of resource outputs and invoke results.
30 lines
1 KiB
TypeScript
30 lines
1 KiB
TypeScript
// Copyright 2016-2018, Pulumi Corporation.
|
|
//
|
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
// you may not use this file except in compliance with the License.
|
|
// You may obtain a copy of the License at
|
|
//
|
|
// http://www.apache.org/licenses/LICENSE-2.0
|
|
//
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
// See the License for the specific language governing permissions and
|
|
// limitations under the License.
|
|
|
|
export {
|
|
serializeFunctionAsync,
|
|
serializeFunction,
|
|
SerializedFunction,
|
|
SerializeFunctionArgs,
|
|
} from "./closure/serializeClosure";
|
|
|
|
export { CodePathOptions, computeCodePaths } from "./closure/codePaths";
|
|
export { Mocks, setMocks } from "./mocks";
|
|
|
|
export * from "./config";
|
|
export * from "./invoke";
|
|
export * from "./resource";
|
|
export * from "./rpc";
|
|
export * from "./settings";
|
|
export * from "./stack";
|