Skip to content

Commit

Permalink
Revert "CSV import e2e tests (#3467)" (#3474)
Browse files Browse the repository at this point in the history
This reverts commit 5e12d40.
  • Loading branch information
MatissJanis authored Sep 20, 2024
1 parent 25a4041 commit 4485a63
Show file tree
Hide file tree
Showing 11 changed files with 0 additions and 62 deletions.
42 changes: 0 additions & 42 deletions packages/desktop-client/e2e/accounts.test.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { join } from 'path';

import { test, expect } from '@playwright/test';

import { ConfigurationPage } from './page-models/configuration-page';
Expand Down Expand Up @@ -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);
});
});
});
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
9 changes: 0 additions & 9 deletions packages/desktop-client/e2e/data/test.csv

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -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();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,6 @@ export function CloseAccountModal({
close();
}}
style={{ color: theme.errorText }}
aria-label="Force close"
>
force close
</Link>{' '}
Expand Down
6 changes: 0 additions & 6 deletions upcoming-release-notes/3467.md

This file was deleted.

0 comments on commit 4485a63

Please sign in to comment.