Apply repository-wide ESLint auto-fix formatting pass
Co-Authored-By: Codex <codex@openai.com>
This commit is contained in:
@@ -3,72 +3,72 @@
|
||||
// Authors:
|
||||
// imacat.yang@dsp.im (imacat), 2026/03/05
|
||||
|
||||
import { loginWithFixtures } from '../support/intercept';
|
||||
import { loginWithFixtures } from "../support/intercept";
|
||||
|
||||
describe('File Operations', () => {
|
||||
describe("File Operations", () => {
|
||||
beforeEach(() => {
|
||||
loginWithFixtures();
|
||||
cy.visit('/files');
|
||||
cy.wait('@getFiles');
|
||||
cy.visit("/files");
|
||||
cy.wait("@getFiles");
|
||||
});
|
||||
|
||||
it('file list table has sortable columns', () => {
|
||||
it("file list table has sortable columns", () => {
|
||||
// Check that table headers exist with expected columns
|
||||
cy.get('table').within(() => {
|
||||
cy.contains('th', 'Name').should('exist');
|
||||
cy.contains('th', 'Dependency').should('exist');
|
||||
cy.contains('th', 'File Type').should('exist');
|
||||
cy.contains('th', 'Owner').should('exist');
|
||||
cy.contains('th', 'Last Update').should('exist');
|
||||
cy.get("table").within(() => {
|
||||
cy.contains("th", "Name").should("exist");
|
||||
cy.contains("th", "Dependency").should("exist");
|
||||
cy.contains("th", "File Type").should("exist");
|
||||
cy.contains("th", "Owner").should("exist");
|
||||
cy.contains("th", "Last Update").should("exist");
|
||||
});
|
||||
});
|
||||
|
||||
it('clicking column header sorts the table', () => {
|
||||
it("clicking column header sorts the table", () => {
|
||||
// Click "Name" header to sort
|
||||
cy.contains('th', 'Name').click();
|
||||
cy.contains("th", "Name").click();
|
||||
// After sorting, table should still have data
|
||||
cy.get('table tbody tr').should('have.length.greaterThan', 0);
|
||||
cy.get("table tbody tr").should("have.length.greaterThan", 0);
|
||||
});
|
||||
|
||||
it('table rows show file data from fixture', () => {
|
||||
cy.get('table tbody').within(() => {
|
||||
cy.contains('sample-process.xes').should('exist');
|
||||
cy.contains('filtered-sample').should('exist');
|
||||
cy.contains('production-log.csv').should('exist');
|
||||
it("table rows show file data from fixture", () => {
|
||||
cy.get("table tbody").within(() => {
|
||||
cy.contains("sample-process.xes").should("exist");
|
||||
cy.contains("filtered-sample").should("exist");
|
||||
cy.contains("production-log.csv").should("exist");
|
||||
});
|
||||
});
|
||||
|
||||
it('table shows owner names', () => {
|
||||
cy.get('table tbody').within(() => {
|
||||
cy.contains('Test Admin').should('exist');
|
||||
cy.contains('Alice Wang').should('exist');
|
||||
it("table shows owner names", () => {
|
||||
cy.get("table tbody").within(() => {
|
||||
cy.contains("Test Admin").should("exist");
|
||||
cy.contains("Alice Wang").should("exist");
|
||||
});
|
||||
});
|
||||
|
||||
it('table shows file types', () => {
|
||||
cy.get('table tbody').within(() => {
|
||||
cy.contains('log').should('exist');
|
||||
it("table shows file types", () => {
|
||||
cy.get("table tbody").within(() => {
|
||||
cy.contains("log").should("exist");
|
||||
});
|
||||
});
|
||||
|
||||
it('right-click on file row shows context menu', () => {
|
||||
it("right-click on file row shows context menu", () => {
|
||||
// PrimeVue DataTable with contextmenu
|
||||
cy.get('table tbody tr').first().rightclick();
|
||||
cy.get("table tbody tr").first().rightclick();
|
||||
// Context menu behavior depends on implementation
|
||||
// Just verify the right-click doesn't break anything
|
||||
cy.get('table tbody tr').should('have.length.greaterThan', 0);
|
||||
cy.get("table tbody tr").should("have.length.greaterThan", 0);
|
||||
});
|
||||
|
||||
it('grid view shows file cards', () => {
|
||||
it("grid view shows file cards", () => {
|
||||
// Switch to grid view
|
||||
cy.get('svg').parent('li.cursor-pointer').last().click();
|
||||
cy.get("svg").parent("li.cursor-pointer").last().click();
|
||||
// Grid cards should be visible
|
||||
cy.get('li[title]').should('have.length.greaterThan', 0);
|
||||
cy.get("li[title]").should("have.length.greaterThan", 0);
|
||||
});
|
||||
|
||||
it('Import button opens upload modal', () => {
|
||||
cy.get('#import_btn').click();
|
||||
it("Import button opens upload modal", () => {
|
||||
cy.get("#import_btn").click();
|
||||
// Upload modal should appear
|
||||
cy.get('#import_btn').should('exist');
|
||||
cy.get("#import_btn").should("exist");
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user