From 6ba53d1e324f3dd442b5e32032a243aeb9c561e1 Mon Sep 17 00:00:00 2001 From: Jordan Last Date: Tue, 16 Jul 2024 13:59:56 -0500 Subject: [PATCH 1/2] test a simpler version of link --- test/jest_link.ts | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/test/jest_link.ts b/test/jest_link.ts index fc349a5698..85d50ea653 100644 --- a/test/jest_link.ts +++ b/test/jest_link.ts @@ -13,14 +13,9 @@ export function linkAndInstallPatch(pathRelativeToAzle: string): void { process.env.AZLE_END_TO_END_TEST_LINK_AZLE ); - // TODO do we even need to do this on release? - execSync(`cd ${join(examplesDir, pathRelativeToAzle)} && npm install`); - if (process.env.AZLE_END_TO_END_TEST_LINK_AZLE !== 'false') { - // TODO remove logs once we are satisfied that the link doesn't happen during release candidate tests - console.log('--------------------------------------------------------'); - console.log("--- We're linking!!! -----------------------------------"); - console.log('--------------------------------------------------------'); + // TODO do we even need to do this on release? + execSync(`cd ${join(examplesDir, pathRelativeToAzle)} && npm install`); execSync( `cd ${join(examplesDir, pathRelativeToAzle)} && npm link azle` ); From 04ba4303f84dbbc8e9125005a0e953284d1cab09 Mon Sep 17 00:00:00 2001 From: Jordan Last Date: Tue, 16 Jul 2024 14:44:10 -0500 Subject: [PATCH 2/2] final cleanup of jest_link --- test/jest_link.ts | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/test/jest_link.ts b/test/jest_link.ts index 85d50ea653..9996fd9c3c 100644 --- a/test/jest_link.ts +++ b/test/jest_link.ts @@ -1,21 +1,14 @@ import { execSync } from 'child_process'; import { join, resolve } from 'path'; -// TODO remove install and link after https://github.com/demergent-labs/azle/issues/1807 is resolved +// TODO remove linkAndInstallPatch after https://github.com/demergent-labs/azle/issues/1807 is resolved export function linkAndInstallPatch(pathRelativeToAzle: string): void { const examplesDir = process.env.GITHUB_WORKSPACE ?? resolve(__dirname, '..'); - console.log('examplesDir', examplesDir); - - console.log( - 'process.env.AZLE_END_TO_END_TEST_LINK_AZLE', - process.env.AZLE_END_TO_END_TEST_LINK_AZLE - ); + execSync(`cd ${join(examplesDir, pathRelativeToAzle)} && npm install`); if (process.env.AZLE_END_TO_END_TEST_LINK_AZLE !== 'false') { - // TODO do we even need to do this on release? - execSync(`cd ${join(examplesDir, pathRelativeToAzle)} && npm install`); execSync( `cd ${join(examplesDir, pathRelativeToAzle)} && npm link azle` );