chore: checkJs in
MODIFY
packages/lockdown/pre.js
packages/lockdown/pre.js
// pre.js - set up the default lockdown function
+// @ts-nocheck
/* global globalThis LOCKDOWN_OPTIONS process */
import 'ses';

MODIFY
packages/marshal/jsconfig.json
packages/marshal/jsconfig.json
-// This file can contain .js-specific Typescript compiler config.
{
"compilerOptions": {
"target": "esnext",
"module": "esnext",
-
+ "checkJs": true,
"noEmit": true,
-/*
- // The following flags are for creating .d.ts files:
- "noEmit": false,
- "declaration": true,
- "emitDeclarationOnly": true,
-*/
"downlevelIteration": true,
"strictNullChecks": true,
"moduleResolution": "node",
+ "types": [
+ "node"
+ ]
},
- "include": ["*.js", "*.ts", "src/**/*.js", "src/**/*.ts", "test/**/*.js"]
+ "include": [
+ "*.js",
+ "*.ts",
+ "src/**/*.js",
+ "src/**/*.ts",
+ "test/**/*.js"
+ ]
}

MODIFY
packages/marshal/test/prepare-test-env-ava.js
packages/marshal/test/prepare-test-env-ava.js
+// @ts-nocheck
import '@endo/init/debug.js';
import { wrapTest } from '@endo/ses-ava';

MODIFY
packages/marshal/test/test-dot-membrane.js
packages/marshal/test/test-dot-membrane.js
@@ -11,6 +11,7 @@ test('test dot-membrane basics', t => {
const yellow88 = [88];
const yellow99 = [99];
yellowSetState(yellow88);
+ assert(blueState);
t.is(blueState[0], 88);
t.not(blueState, yellow88);
revoke('Halt!');

MODIFY
packages/marshal/test/test-passStyleOf.js
packages/marshal/test/test-passStyleOf.js
@@ -62,6 +62,7 @@ test('some passStyleOf rejections', t => {
});
const prbad2 = Promise.resolve();
+ // @ts-expect-error unknown property
prbad2.extra = 'unexpected own property';
harden(prbad2);
t.throws(() => passStyleOf(prbad2), {
@@ -102,7 +103,7 @@ const makeTagishRecord = (tag = 'Remotable', proto = undefined) => {
};
test('passStyleOf testing tagged records', t => {
- const makeTagRecordVariant = (payload, proto = undefined) => {
+ const makeTagRecordVariant = (payload, proto) => {
const record = Object.create(
proto === undefined ? Object.prototype : proto,
{
@@ -304,7 +305,7 @@ test('passStyleOf testing remotables', t => {
message: 'Unexpected properties on Remotable Proto ["extra"]',
});
- passStyleOf(harden({ __proto__: Object.prototype }), 'copyRecord');
+ t.is(passStyleOf(harden({ __proto__: Object.prototype })), 'copyRecord');
const farObjC = harden({
__proto__: Object.prototype,

chore: checkJs in @endo/marshal