feat(dragAndDrop.spec.ts): add tests for auto_login functionality

The `dragAndDrop.spec.ts` file was added to the `src/frontend/tests/onlyFront` directory. This file contains tests for the auto_login functionality. Two tests were added:

1. `auto_login sign in`: This test simulates signing in with auto_login. It routes requests from the "langflow.har" file to the appropriate API endpoints, navigates to the homepage, clicks on the "Community Examples" button, waits for the ".community-pages-flows-panel" selector to be present, and asserts that it has children.

2. `auto_login block_admin`: This test simulates accessing the admin section with auto_login. It routes requests from the "langflow.har" file to the appropriate API endpoints, navigates to the homepage, clicks on the "Community Examples" button, navigates to the login page, clicks on the "Community Examples" button again, navigates to the admin page, clicks on the "Community Examples" button again, navigates to the admin login page, and clicks on the "Community Examples" button.

These tests were added to ensure the proper functioning of the auto_login feature.
This commit is contained in:
anovazzi1 2023-10-17 20:36:13 -03:00 committed by anovazzi1
commit d68f2cbbab

View file

@ -1,8 +1,6 @@
import { expect, test } from "@playwright/test";
test.describe("Auto_login tests", () => {
test("auto_login sign in", async ({ page }) => {
await page.routeFromHAR("harFiles/langflow.har", {
url: "**/api/v1/**",