Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Type validate runtime definition packages #8313

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
200 changes: 200 additions & 0 deletions lerna-package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 12 additions & 1 deletion packages/runtime/container-runtime-definitions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,15 @@
"main": "dist/index.js",
"types": "dist/index.d.ts",
"scripts": {
"build": "concurrently npm:build:compile npm:lint && npm run build:docs",
"build": "npm run build:gen && concurrently npm:build:compile npm:lint && npm run build:docs",
"build:compile": "npm run tsc",
"build:docs": "api-extractor run --local --typescript-compiler-folder ../../../node_modules/typescript && copyfiles -u 1 ./_api-extractor-temp/doc-models/* ../../../_api-extractor-temp/",
"build:full": "npm run build",
"build:full:compile": "npm run build:compile",
"build:gen": "npm run build:gen:typetests",
"build:gen:bump": "npm run build:gen:typetests:prepare",
"build:gen:typetests": "fluid-type-validator -d .",
"build:gen:typetests:prepare": "fluid-type-validator -d . -p",
"ci:build:docs": "api-extractor run --typescript-compiler-folder ../../../node_modules/typescript && copyfiles -u 1 ./_api-extractor-temp/* ../../../_api-extractor-temp/",
"clean": "rimraf dist *.tsbuildinfo *.build.log",
"eslint": "eslint --format stylish src",
Expand All @@ -36,6 +40,8 @@
},
"devDependencies": {
"@fluidframework/build-common": "^0.23.0",
"@fluidframework/build-tools": "^0.2.43369",
"@fluidframework/container-runtime-definitions-0.51.1": "npm:@fluidframework/container-runtime-definitions@0.51.1",
"@fluidframework/eslint-config-fluid": "^0.24.0",
"@microsoft/api-extractor": "^7.16.1",
"@typescript-eslint/eslint-plugin": "~4.14.0",
Expand All @@ -52,5 +58,10 @@
"rimraf": "^2.6.2",
"typescript": "~4.1.3",
"typescript-formatter": "7.1.0"
},
"typeValidation": {
"version": "0.52.0",
"broken": {
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
/*!
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
* Licensed under the MIT License.
*/
/*
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
* Generated by fluid-type-validator in @fluidframework/build-tools.
*/
import * as old from "@fluidframework/container-runtime-definitions-0.51.1";
import * as current from "../../index";

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "VariableDeclaration_IContainerRuntime": {"forwardCompat": false}
*/
declare function get_old_VariableDeclaration_IContainerRuntime():
typeof old.IContainerRuntime;
declare function use_current_VariableDeclaration_IContainerRuntime(
use: typeof current.IContainerRuntime);
use_current_VariableDeclaration_IContainerRuntime(
get_old_VariableDeclaration_IContainerRuntime());

/*
* Validate back compat by using current type in place of old type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "VariableDeclaration_IContainerRuntime": {"backCompat": false}
*/
declare function get_current_VariableDeclaration_IContainerRuntime():
typeof current.IContainerRuntime;
declare function use_old_VariableDeclaration_IContainerRuntime(
use: typeof old.IContainerRuntime);
use_old_VariableDeclaration_IContainerRuntime(
get_current_VariableDeclaration_IContainerRuntime());

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "InterfaceDeclaration_IContainerRuntime": {"forwardCompat": false}
*/
declare function get_old_InterfaceDeclaration_IContainerRuntime():
old.IContainerRuntime;
declare function use_current_InterfaceDeclaration_IContainerRuntime(
use: current.IContainerRuntime);
use_current_InterfaceDeclaration_IContainerRuntime(
get_old_InterfaceDeclaration_IContainerRuntime());

/*
* Validate back compat by using current type in place of old type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "InterfaceDeclaration_IContainerRuntime": {"backCompat": false}
*/
declare function get_current_InterfaceDeclaration_IContainerRuntime():
current.IContainerRuntime;
declare function use_old_InterfaceDeclaration_IContainerRuntime(
use: old.IContainerRuntime);
use_old_InterfaceDeclaration_IContainerRuntime(
get_current_InterfaceDeclaration_IContainerRuntime());

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents": {"forwardCompat": false}
*/
declare function get_old_TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents():
old.IContainerRuntimeBaseWithCombinedEvents;
declare function use_current_TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents(
use: current.IContainerRuntimeBaseWithCombinedEvents);
use_current_TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents(
get_old_TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents());

/*
* Validate back compat by using current type in place of old type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents": {"backCompat": false}
*/
declare function get_current_TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents():
current.IContainerRuntimeBaseWithCombinedEvents;
declare function use_old_TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents(
use: old.IContainerRuntimeBaseWithCombinedEvents);
use_old_TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents(
get_current_TypeAliasDeclaration_IContainerRuntimeBaseWithCombinedEvents());

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "InterfaceDeclaration_IContainerRuntimeEvents": {"forwardCompat": false}
*/
declare function get_old_InterfaceDeclaration_IContainerRuntimeEvents():
old.IContainerRuntimeEvents;
declare function use_current_InterfaceDeclaration_IContainerRuntimeEvents(
use: current.IContainerRuntimeEvents);
use_current_InterfaceDeclaration_IContainerRuntimeEvents(
get_old_InterfaceDeclaration_IContainerRuntimeEvents());

/*
* Validate back compat by using current type in place of old type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "InterfaceDeclaration_IContainerRuntimeEvents": {"backCompat": false}
*/
declare function get_current_InterfaceDeclaration_IContainerRuntimeEvents():
current.IContainerRuntimeEvents;
declare function use_old_InterfaceDeclaration_IContainerRuntimeEvents(
use: old.IContainerRuntimeEvents);
use_old_InterfaceDeclaration_IContainerRuntimeEvents(
get_current_InterfaceDeclaration_IContainerRuntimeEvents());

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "InterfaceDeclaration_IProvideContainerRuntime": {"forwardCompat": false}
*/
declare function get_old_InterfaceDeclaration_IProvideContainerRuntime():
old.IProvideContainerRuntime;
declare function use_current_InterfaceDeclaration_IProvideContainerRuntime(
use: current.IProvideContainerRuntime);
use_current_InterfaceDeclaration_IProvideContainerRuntime(
get_old_InterfaceDeclaration_IProvideContainerRuntime());

/*
* Validate back compat by using current type in place of old type
* If breaking change required, add in package.json under typeValidation.broken.0.51.1:
* "InterfaceDeclaration_IProvideContainerRuntime": {"backCompat": false}
*/
declare function get_current_InterfaceDeclaration_IProvideContainerRuntime():
current.IProvideContainerRuntime;
declare function use_old_InterfaceDeclaration_IProvideContainerRuntime(
use: old.IProvideContainerRuntime);
use_old_InterfaceDeclaration_IProvideContainerRuntime(
get_current_InterfaceDeclaration_IProvideContainerRuntime());
Loading