A local-first personal finance app
Revert "CSV import e2e tests (#3467)" (#3474)
Matiss Janis Aboltins4485a631cded
diff --git a/packages/desktop-client/e2e/accounts.test.js b/packages/desktop-client/e2e/accounts.test.jsindex 69eac67dac..c7e0d02219 100644--- a/packages/desktop-client/e2e/accounts.test.js+++ b/packages/desktop-client/e2e/accounts.test.js@@ -1,5 +1,3 @@-import { join } from 'path';-import { test, expect } from '@playwright/test';import { ConfigurationPage } from './page-models/configuration-page';@@ -101,44 +99,4 @@ test.describe('Accounts', () => {await expect(transaction.account).toHaveText('Ally Savings');});});-- test.describe('Import Transactions', () => {- test.beforeEach(async () => {- accountPage = await navigation.createAccount({- name: 'CSV import',- offBudget: false,- balance: 0,- });- });-- test.afterEach(async () => {- const close = await accountPage.clickCloseAccount();- await close.selectTransferAccount('Vanguard 401k');- await close.forceCloseAccount();- });-- async function importCsv(screenshot = false) {- const fileChooserPromise = page.waitForEvent('filechooser');- await accountPage.page.getByRole('button', { name: 'Import' }).click();-- const fileChooser = await fileChooserPromise;- await fileChooser.setFiles(join(__dirname, 'data/test.csv'));-- if (screenshot) await expect(page).toMatchThemeScreenshots();-- await accountPage.page- .getByRole('button', { name: /Import \d+ transactions/ })- .click();- }-- test('imports transactions from a CSV file', async () => {- await importCsv(true);- });-- test('import csv file twice', async () => {- await importCsv(false);- await page.waitForTimeout(1000);- await importCsv(true);- });- });});diff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-1-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-1-chromium-linux.pngdeleted file mode 100644index c3349157f3..0000000000Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-1-chromium-linux.png and /dev/null differdiff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-2-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-2-chromium-linux.pngdeleted file mode 100644index d5155500fd..0000000000Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-2-chromium-linux.png and /dev/null differdiff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-3-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-3-chromium-linux.pngdeleted file mode 100644index aab5a9f277..0000000000Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-import-csv-file-twice-3-chromium-linux.png and /dev/null differdiff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-1-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-1-chromium-linux.pngdeleted file mode 100644index e0b56f46d6..0000000000Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-1-chromium-linux.png and /dev/null differdiff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-2-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-2-chromium-linux.pngdeleted file mode 100644index 8a9ec7068f..0000000000Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-2-chromium-linux.png and /dev/null differdiff --git a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-3-chromium-linux.png b/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-3-chromium-linux.pngdeleted file mode 100644index b421286bae..0000000000Binary files a/packages/desktop-client/e2e/accounts.test.js-snapshots/Accounts-Import-Transactions-imports-transactions-from-a-CSV-file-3-chromium-linux.png and /dev/null differdiff --git a/packages/desktop-client/e2e/data/test.csv b/packages/desktop-client/e2e/data/test.csvdeleted file mode 100644index 022d65f739..0000000000--- a/packages/desktop-client/e2e/data/test.csv+++ /dev/null@@ -1,9 +0,0 @@-Date,Payee,Notes,Category,Amount-2024-08-02,Deposit,test 1,Income,1787.76-2024-07-02,Deposit,test 2,Income,1787.76-2024-06-02,Deposit,test 3,Income,1787.76-2024-05-02,Deposit,test 4,Income,1787.76-2024-04-02,Deposit,test 5,Income,1787.76-2024-03-02,Deposit,test 6,Income,1787.76-2024-02-02,Deposit,test 7,Income,1787.76-2024-01-02,Starting Balance,test 8,Starting Balances,-330000diff --git a/packages/desktop-client/e2e/page-models/close-account-modal.js b/packages/desktop-client/e2e/page-models/close-account-modal.jsindex d25eebcdb4..7cd689732a 100644--- a/packages/desktop-client/e2e/page-models/close-account-modal.js+++ b/packages/desktop-client/e2e/page-models/close-account-modal.js@@ -12,8 +12,4 @@ export class CloseAccountModal {async closeAccount() {await this.page.getByRole('button', { name: 'Close account' }).click();}-- async forceCloseAccount() {- await this.page.getByLabel('Force close').click();- }}diff --git a/packages/desktop-client/src/components/modals/CloseAccountModal.tsx b/packages/desktop-client/src/components/modals/CloseAccountModal.tsxindex 64f072891e..0a9966d59d 100644--- a/packages/desktop-client/src/components/modals/CloseAccountModal.tsx+++ b/packages/desktop-client/src/components/modals/CloseAccountModal.tsx@@ -230,7 +230,6 @@ export function CloseAccountModal({close();}}style={{ color: theme.errorText }}- aria-label="Force close">force close</Link>{' '}diff --git a/upcoming-release-notes/3467.md b/upcoming-release-notes/3467.mddeleted file mode 100644index ef1ecb2648..0000000000--- a/upcoming-release-notes/3467.md+++ /dev/null@@ -1,6 +0,0 @@-----category: Maintenance-authors: [UnderKoen]------E2E tests for CSV import dialog