Skip to content

Commit

Permalink
refactor(zoe,base-zone): move prepare-revocable to base-zone helper l…
Browse files Browse the repository at this point in the history
…ib (#8965)

* refactor(zoe,base-zone): move prepare-revocable to base-zone helper lib

* fixup! deprecation notice
  • Loading branch information
erights authored Feb 24, 2024
1 parent be6d970 commit e5ee0b4
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 10 deletions.
3 changes: 3 additions & 0 deletions packages/base-zone/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
},
"exports": {
".": "./src/index.js",
"./zone-helpers.js": "./zone-helpers.js",
"./heap.js": "./heap.js",
"./tools/*": "./tools/*"
},
Expand All @@ -27,13 +28,15 @@
"license": "Apache-2.0",
"dependencies": {
"@agoric/store": "^0.9.2",
"@endo/common": "^1.1.0",
"@endo/exo": "^1.2.1",
"@endo/far": "^1.0.4",
"@endo/pass-style": "^1.2.0",
"@endo/patterns": "^1.2.0"
},
"devDependencies": {
"@endo/init": "^1.0.4",
"@endo/ses-ava": "^1.1.2",
"ava": "^5.3.0"
},
"publishConfig": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,9 @@ const { Fail, quote: q } = assert;

/**
* Make an exo class kit for wrapping an underlying exo class,
* where the wrapper is a revocable forwarder
* where the wrapper is a revocable forwarder.
*
* @deprecated Change to `prepareRevocableMakerKit` once #8977 happens
* @template {any} [U=any]
* @param {import('@agoric/base-zone').Zone} zone
* @param {string} uKindName
Expand Down
7 changes: 3 additions & 4 deletions packages/base-zone/test/prepare-test-env-ava.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
// eslint-disable-next-line import/no-extraneous-dependencies
import { wrapTest } from '@endo/ses-ava';
import rawTest from 'ava';

import test from 'ava';

export { test };
export const test = wrapTest(rawTest);
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
// Modeled on test-heap-classes.js

import { test } from '@agoric/swingset-vat/tools/prepare-test-env-ava.js';
import { test } from './prepare-test-env-ava.js';

// eslint-disable-next-line import/order
import { M } from '@endo/patterns';
import { makeHeapZone } from '@agoric/base-zone/heap.js';
import { prepareRevocableKit } from '../../../src/contractSupport/prepare-revocable.js';
import { makeHeapZone } from '../src/heap.js';
import { prepareRevocableKit } from '../src/prepare-revocable.js';

const UpCounterI = M.interface('UpCounter', {
incr: M.call()
Expand Down
1 change: 1 addition & 0 deletions packages/base-zone/zone-helpers.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './src/prepare-revocable.js';
1 change: 0 additions & 1 deletion packages/zoe/src/contractSupport/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ export {

export * from './durability.js';
export * from './prepare-ownable.js';
export * from './prepare-revocable.js';
export * from './priceAuthority.js';
export * from './priceQuote.js';
export * from './statistics.js';
Expand Down
2 changes: 1 addition & 1 deletion packages/zoe/src/contractSupport/prepare-ownable.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { M } from '@endo/patterns';
import { prepareRevocableKit } from '@agoric/base-zone/zone-helpers.js';
import { OfferHandlerI } from '../typeGuards.js';
import { prepareRevocableKit } from './prepare-revocable.js';

const TransferProposalShape = M.splitRecord({
give: {},
Expand Down

0 comments on commit e5ee0b4

Please sign in to comment.