Add 20 Pear/Bare platform modules replacing deprecated pear run.
Introduces hyper-bare-entry-runner, pear-runtime embed/link/config stack, and scaffold helpers for argv, storage, OTA, Electron, and headless UI. Co-authored-by: Cursor <[email protected]>
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
require('bare-process/global')
|
||||
const test = require('brittle')
|
||||
const { HyperPearLinkResolver, PROTOCOL } = require('../index.js')
|
||||
|
||||
test('parse and serialize', async (t) => {
|
||||
const l = new HyperPearLinkResolver()
|
||||
const p = l.parse('pear://abc123/sub/index.js')
|
||||
t.is(p.key, 'abc123')
|
||||
t.is(p.subpath, 'sub/index.js')
|
||||
t.is(l.serialize({ key: 'abc123', subpath: 'x' }), 'pear://abc123/x')
|
||||
await l.close()
|
||||
})
|
||||
Reference in New Issue
Block a user