From a3a7b2fa7792aa92021e0cf61d981a788266df07 Mon Sep 17 00:00:00 2001 From: vasapornchaiyakul <134899205+vasapornchaiyakul@users.noreply.github.com> Date: Wed, 31 Jan 2024 18:51:23 +0700 Subject: [PATCH] fix: path wasn't working --- .gitignore | 2 +- wallet-automation/typhon/credentials.ts | 2 +- wallet-automation/typhon/seed-phrase.ts | 2 +- wallet-automation/typhon/typhon-wallet-logout.spec.ts | 4 ++-- wallet-automation/typhon/typhon-wallet-registration.spec.ts | 4 ++-- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.gitignore b/.gitignore index e7539f5719..6f2474da24 100644 --- a/.gitignore +++ b/.gitignore @@ -123,4 +123,4 @@ local/* /playwright-report/* /blob-report/* /playwright/.cache/* -/wallet-automation/typhon/usrdatadir/* \ No newline at end of file +wallet-automation/typhon/usrdatadir/* \ No newline at end of file diff --git a/wallet-automation/typhon/credentials.ts b/wallet-automation/typhon/credentials.ts index 74d2750c78..d25382432b 100644 --- a/wallet-automation/typhon/credentials.ts +++ b/wallet-automation/typhon/credentials.ts @@ -2,7 +2,7 @@ import fs from 'fs'; import path from 'path'; // Construct the path to the .txt file -const txtPath = '../../catalyst-core/wallet-automation/typhon/typhon-wallet-storage.txt'; +const txtPath = '../../wallet-automation/typhon/typhon-wallet-storage.txt'; // Read the contents of the .txt file const txtContent = fs.readFileSync(path.resolve(txtPath), 'utf8'); diff --git a/wallet-automation/typhon/seed-phrase.ts b/wallet-automation/typhon/seed-phrase.ts index 3c00fda86f..4f9129464d 100644 --- a/wallet-automation/typhon/seed-phrase.ts +++ b/wallet-automation/typhon/seed-phrase.ts @@ -2,7 +2,7 @@ import fs from 'fs'; import path from 'path'; // Construct the path to the .txt file -const txtPath = '../../catalyst-core/wallet-automation/typhon/typhon-wallet-storage.txt'; +const txtPath = '../../wallet-automation/typhon/typhon-wallet-storage.txt'; // Read the contents of the .txt file const txtContent = fs.readFileSync(path.resolve(txtPath), 'utf8'); diff --git a/wallet-automation/typhon/typhon-wallet-logout.spec.ts b/wallet-automation/typhon/typhon-wallet-logout.spec.ts index 9849a6453d..9f33ad21bc 100644 --- a/wallet-automation/typhon/typhon-wallet-logout.spec.ts +++ b/wallet-automation/typhon/typhon-wallet-logout.spec.ts @@ -3,10 +3,10 @@ import { getWalletCredentials } from './credentials'; import { getSeedPhrase } from './seed-phrase'; test('Logout', async ({ }) => { - const extensionPath: string = '/Users/alicechaiyakul/typhon-wallet-registration/catalyst-core/wallet-automation/typhon/extensions'; + const extensionPath: string = '../../wallet-automation/typhon/extensions'; // const extensionId: string = 'kfdniefadaanbjodldohaedphafoffoh'; // Replace with your extension's ID // const extensionPage: string = 'tab.html'; // Replace with the specific page - const userDataDir = '/Users/alicechaiyakul/typhon-wallet-registration/catalyst-core/wallet-automation/typhon/seed-phrase.ts'; // Path to the user data directory + const userDataDir = '../../wallet-automation/typhon/usrdatadir'; // Path to the user data directory // Launch Chromium with the extension const browser = await chromium.launchPersistentContext(userDataDir, { diff --git a/wallet-automation/typhon/typhon-wallet-registration.spec.ts b/wallet-automation/typhon/typhon-wallet-registration.spec.ts index 1413db2058..4c31cd377e 100644 --- a/wallet-automation/typhon/typhon-wallet-registration.spec.ts +++ b/wallet-automation/typhon/typhon-wallet-registration.spec.ts @@ -3,10 +3,10 @@ import { getWalletCredentials } from './credentials'; import { getSeedPhrase } from './seed-phrase'; test('import wallet', async ({ }) => { - const extensionPath: string = '/Users/alicechaiyakul/typhon-wallet-registration/catalyst-core/wallet-automation/typhon/extensions'; + const extensionPath: string = '../../wallet-automation/typhon/extensions'; // const extensionId: string = 'kfdniefadaanbjodldohaedphafoffoh'; // Replace with your extension's ID // const extensionPage: string = 'tab.html'; // Replace with the specific page - const userDataDir = '/Users/alicechaiyakul/typhon-wallet-registration/catalyst-core/wallet-automation/typhon/seed-phrase.ts'; // Path to the user data directory + const userDataDir = '../../wallet-automation/typhon/usrdatadir'; // Path to the user data directory // Launch Chromium with the extension const browser = await chromium.launchPersistentContext(userDataDir, {