Skip to content

Commit

Permalink
refactor(types): use types-ambient naming
Browse files Browse the repository at this point in the history
  • Loading branch information
turadg committed Sep 16, 2023
1 parent da94346 commit 4c25986
Show file tree
Hide file tree
Showing 16 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion packages/boot/index.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
// @ts-check
// Ambient types
import '@agoric/vats/src/core/types.js';
import '@agoric/vats/src/core/types-ambient.js';
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import { test } from '@agoric/zoe/tools/prepare-test-env-ava.js';

import { E } from '@endo/far';
import '@agoric/vats/src/core/types.js';
import '@agoric/vats/src/core/types-ambient.js';
import {
makeAgoricNamesAccess,
runModuleBehaviors,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import '@agoric/vats/src/core/types.js';
import '@agoric/vats/src/core/types-ambient.js';

import { test as anyTest } from '@agoric/zoe/tools/prepare-test-env-ava.js';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { test as anyTest } from '@agoric/zoe/tools/prepare-test-env-ava.js';

import { AmountMath, makeIssuerKit } from '@agoric/ertp';
import '@agoric/vats/src/core/types.js';
import '@agoric/vats/src/core/types-ambient.js';
import { eventLoopIteration } from '@agoric/internal/src/testing-utils.js';
import { E } from '@endo/far';
import { NonNullish } from '@agoric/assert';
Expand Down
2 changes: 1 addition & 1 deletion packages/smart-wallet/test/supports.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import {
makeBoard,
} from '@agoric/vats/src/core/basic-behaviors.js';
import { setupClientManager } from '@agoric/vats/src/core/chain-behaviors.js';
import '@agoric/vats/src/core/types.js';
import '@agoric/vats/src/core/types-ambient.js';
import { buildRootObject as boardRoot } from '@agoric/vats/src/vat-board.js';
import { buildRootObject as mintsRoot } from '@agoric/vats/src/vat-mints.js';
import { makeFakeBankKit } from '@agoric/vats/tools/bank-utils.js';
Expand Down
2 changes: 1 addition & 1 deletion packages/smart-wallet/test/test-startWalletFactory.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { E } from '@endo/far';
import path from 'path';
import { makeMockTestSpace } from './supports.js';

import '@agoric/vats/src/core/types.js';
import '@agoric/vats/src/core/types-ambient.js';

/** @type {import('ava').TestFn<Awaited<ReturnType<typeof makeTestContext>>>} */
const test = anyTest;
Expand Down
2 changes: 1 addition & 1 deletion packages/smart-wallet/test/test-walletFactory.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import {
topicPath,
} from './supports.js';

import '@agoric/vats/src/core/types.js';
import '@agoric/vats/src/core/types-ambient.js';

/** @type {import('ava').TestFn<Awaited<ReturnType<makeDefaultTestContext>>>} */
const test = anyTest;
Expand Down
2 changes: 1 addition & 1 deletion packages/vats/exported.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
import './src/core/types.js';
import './src/core/types-ambient.js';
2 changes: 1 addition & 1 deletion packages/vats/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// @ts-check
// Ambient types
import '@agoric/zoe/exported.js';
import './src/core/types.js';
import './src/core/types-ambient.js';

// eslint-disable-next-line import/export -- no named exports
export * from './src/types.js';
Expand Down
2 changes: 1 addition & 1 deletion packages/vats/src/bridge.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import { M } from '@agoric/store';
import '@agoric/store/exported.js';
import { E } from '@endo/far';
import './core/types.js';
import './core/types-ambient.js';

const { Fail, details: X } = assert;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ type ChainBootstrapSpaceT = {
*/
instancePrivateArgs: Map<Instance, unknown>;
namesByAddress: import('../types.js').NameHub;
namesByAddressAdmin: import('../types').NamesByAddressAdmin;
namesByAddressAdmin: import('../types.js').NamesByAddressAdmin;
pegasusConnections: import('@agoric/vats').NameHubKit;
pegasusConnectionsAdmin: import('@agoric/vats').NameAdmin;
priceAuthorityVat: Awaited<PriceAuthorityVat>;
Expand Down Expand Up @@ -370,7 +370,7 @@ type ChainBootstrapSpaceT = {
/** Used only for testing. Should not appear in any production proposals. */
testFirstAnchorKit: import('../vat-bank.js').AssetIssuerKit<'nat'>;
walletBridgeManager: import('../types.js').ScopedBridgeManager | undefined;
walletFactoryStartResult: import('./startWalletFactory').WalletFactoryStartResult;
walletFactoryStartResult: import('./startWalletFactory.js').WalletFactoryStartResult;
provisionPoolStartResult: unknown;
vatStore: import('./utils.js').VatStore;
zoe: ZoeService;
Expand Down Expand Up @@ -437,7 +437,7 @@ type RemoteIssuerKit = {
brand: Brand;
};
type AgoricNamesVat = ERef<
ReturnType<typeof import('../vat-agoricNames').buildRootObject>
ReturnType<typeof import('../vat-agoricNames.js').buildRootObject>
>;
type BankVat = ERef<
ReturnType<typeof import('../vat-bank.js').buildRootObject>
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion packages/zoe/exported.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// @jessie-check

import './src/contractFacet/types.js';
import './src/contractFacet/types-ambient.js';
import './src/zoeService/types.js';
import './src/contractSupport/types.js';
import './src/contracts/exported.js';
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion packages/zoe/src/contractFacet/zcfMint.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { addToAllocation, subtractFromAllocation } from './allocationMath.js';
import '../internal-types.js';
import { ZcfMintI } from '../typeGuards.js';
import './internal-types.js';
import './types.js';
import './types-ambient.js';

const { Fail } = assert;

Expand Down

0 comments on commit 4c25986

Please sign in to comment.