From 007cad80e16f81aee1b5ea99825466013291ba59 Mon Sep 17 00:00:00 2001 From: Jan Keith Darunday Date: Thu, 12 Sep 2024 12:04:51 +0800 Subject: [PATCH] Remove platformDir since we now have tests running with staged localdev --- test/05-commands.test.js | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/test/05-commands.test.js b/test/05-commands.test.js index ddf2af973..15793dafc 100644 --- a/test/05-commands.test.js +++ b/test/05-commands.test.js @@ -8,8 +8,7 @@ const minimal = path.join(Helper.root, 'test', 'fixtures', 'minimal') class Rig { setup = async ({ comment, timeout }) => { timeout(180000) - this.platformDir = path.join(Helper.root, 'pear') - const helper = new Helper({ platformDir: this.platformDir }) + const helper = new Helper() this.helper = helper comment('connecting local sidecar') await helper.ready() @@ -23,7 +22,7 @@ class Rig { const testId = Math.floor(Math.random() * 100000) const relativePath = path.relative(harness, minimal) const argvInit = ['stage', '--json', 'test-' + testId, ...(name ? ['--name', name] : []), relativePath] - const stager = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const stager = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) await stager.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argvInit)}) `, { returnByValue: false }) @@ -59,7 +58,7 @@ test('pear stage --json ', async function ({ plan, alik const argv = ['stage', '--json', 'test-' + testId, minimal] - const running = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const running = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) await running.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)}) @@ -120,7 +119,7 @@ test('pear seed ', async function ({ plan, is }) { plan(1) const { channel } = await rig.getOrCreateSeedInstance() - const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) const argv = ['seed', channel, minimal] await seeder.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)}) @@ -147,7 +146,7 @@ test('pear seed ', async function ({ plan, is }) { const { channel } = await rig.getOrCreateSeedInstance() const relativePath = path.relative(harness, minimal) - const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) const argv = ['seed', channel, relativePath] await seeder.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)}) @@ -174,7 +173,7 @@ test('pear seed --json ', async function ({ plan, is, a const { channel } = await rig.getOrCreateSeedInstance() const relativePath = path.relative(harness, minimal) - const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) const argv = ['seed', '--json', channel, relativePath] await seeder.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)}) @@ -208,7 +207,7 @@ test('pear seed --name ', async function ({ plan const { channel } = await rig.getOrCreateSeedInstance(name) const relativePath = path.relative(harness, minimal) - const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) const argv = ['seed', '--name', name, channel, relativePath] await seeder.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)}) @@ -236,7 +235,7 @@ test('pear seed --name --json ', async function const { channel } = await rig.getOrCreateSeedInstance(name) const relativePath = path.relative(harness, minimal) - const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) const argv = ['seed', '--name', name, '--json', channel, relativePath] await seeder.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)}) @@ -264,7 +263,7 @@ test('pear seed pear://', async function ({ plan, is }) { plan(1) const { link } = await rig.getOrCreateSeedInstance() - const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) const argv = ['seed', link] await seeder.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)}) @@ -290,7 +289,7 @@ test('pear seed --json pear://', async function ({ plan, is, alike }) { plan(1) const { link } = await rig.getOrCreateSeedInstance() - const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) const argv = ['seed', '--json', link] await seeder.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)}) @@ -323,7 +322,7 @@ test('pear seed --name pear://', async function ({ plan, is }) { const name = 'custom-name-' + Math.floor(Math.random() * 100000) const { link } = await rig.getOrCreateSeedInstance(name) - const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) const argv = ['seed', '--name', name, link] await seeder.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)}) @@ -350,7 +349,7 @@ test('pear seed --name --json pear://', async function ({ plan, is, const name = 'custom-name-' + Math.floor(Math.random() * 100000) const { link } = await rig.getOrCreateSeedInstance(name) - const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true, platformDir: rig.platformDir }) + const seeder = await Helper.open(harness, { tags: ['exit'] }, { lineout: true }) const argv = ['seed', '--name', name, '--json', link] await seeder.inspector.evaluate(` __PEAR_TEST__.command(${JSON.stringify(argv)})