mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-25 20:45:15 +00:00
Add testing for Movement bug
This commit is contained in:
parent
6695310a64
commit
f2c584c631
|
@ -31,18 +31,17 @@ test('Trade', async ({ page }) => {
|
|||
await setLoginInfo(page);
|
||||
|
||||
await tradeMocks(page);
|
||||
|
||||
await page.goto('/trade');
|
||||
|
||||
// Wait for network requests
|
||||
// await page.waitForResponse('**/ping');
|
||||
await page.waitForResponse('**/status');
|
||||
// await page.waitForResponse('**/Profit');
|
||||
// await page.waitForResponse('**/Balance');
|
||||
// await page.waitForResponse('**/Trades');
|
||||
// await page.waitForResponse('**/Whitelist');
|
||||
// await page.waitForResponse('**/Blacklist');
|
||||
// await page.waitForResponse('**/Locks');
|
||||
await page.waitForResponse('**/profit');
|
||||
await page.waitForResponse('**/balance');
|
||||
// await page.waitForResponse('**/trades');
|
||||
await page.waitForResponse('**/whitelist');
|
||||
await page.waitForResponse('**/blacklist');
|
||||
await page.waitForResponse('**/locks');
|
||||
|
||||
// // Check visibility of elements
|
||||
await expect(page.locator('.drag-header', { hasText: 'Multi Pane' })).toBeInViewport();
|
||||
|
@ -68,8 +67,6 @@ test('Trade', async ({ page }) => {
|
|||
),
|
||||
).toBe(0);
|
||||
|
||||
// // Click on Stop Trading button
|
||||
|
||||
// await page.locator('.mt-1 > .mt-1').getByRole('button').getByTitle('Stop Trading').click();
|
||||
|
||||
// // Modal open
|
||||
|
@ -116,4 +113,24 @@ test('Trade', async ({ page }) => {
|
|||
|
||||
// // Click on Reload Config button
|
||||
// await page.locator('button[title*="Reload Config "]').click();
|
||||
|
||||
await page.locator('#avatar-drop').click();
|
||||
|
||||
await page.getByLabel('Lock layout').uncheck();
|
||||
|
||||
const chartHeader = await page.locator('.drag-header:has-text("Chart")');
|
||||
await expect(multiPane).toBeInViewport();
|
||||
await expect(chartHeader).toBeInViewport();
|
||||
|
||||
// Test drag and drop functionality
|
||||
const chartHeaderbb = await chartHeader.boundingBox();
|
||||
if (chartHeaderbb) {
|
||||
await chartHeader.hover();
|
||||
await page.mouse.down();
|
||||
|
||||
await page.mouse.move(chartHeaderbb?.x + chartHeaderbb.width / 2, chartHeaderbb?.y + 200);
|
||||
await page.mouse.up();
|
||||
await expect(multiPane).toBeInViewport();
|
||||
await expect(chartHeader).toBeInViewport();
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue
Block a user