mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-05-23 17:19:37 +02:00
Merge pull request #17009 from overleaf/ae-file-tree-classname
Remove duplicate className from Angular file tree GitOrigin-RevId: 238b1ad8631b5a861361113679a9f1f8a66da6ea
This commit is contained in:
@@ -13,5 +13,9 @@
|
||||
"rules": {
|
||||
// Do not allow importing of implicit dependencies.
|
||||
"import/no-extraneous-dependencies": "error"
|
||||
}
|
||||
},
|
||||
"overrides": [
|
||||
// Extra rules for Cypress tests
|
||||
{ "files": ["**/*.spec.ts"], "extends": ["plugin:cypress/recommended"] }
|
||||
]
|
||||
}
|
||||
|
||||
@@ -8,11 +8,10 @@ describe('Project creation and compilation', function () {
|
||||
// this is the first project created, the welcome screen is displayed instead of the project list
|
||||
createProject('test-project', { isFirstProject: true })
|
||||
cy.url().should('match', /\/project\/[a-fA-F0-9]{24}/)
|
||||
cy.findByText('\\maketitle')
|
||||
.parent()
|
||||
.click()
|
||||
.type('\n\\section{{}Test Section}')
|
||||
cy.findByText('\\maketitle').parent().click()
|
||||
cy.findByText('\\maketitle').parent().type('\n\\section{{}Test Section}')
|
||||
// Wait for the PDF compilation throttling
|
||||
// eslint-disable-next-line cypress/no-unnecessary-waiting
|
||||
cy.wait(3000)
|
||||
cy.findByText('Recompile').click()
|
||||
cy.get('.pdf-viewer').should('contain.text', 'Test Section')
|
||||
@@ -62,10 +61,7 @@ describe('Project creation and compilation', function () {
|
||||
cy.findByLabelText('Select a File').select('frog.jpg')
|
||||
cy.findByText('Create').click()
|
||||
})
|
||||
// FIXME: should be aria-labeled or data-test-id
|
||||
cy.get('.file-tree').first().within(() => {
|
||||
cy.findByText('frog.jpg').click()
|
||||
})
|
||||
cy.findByTestId('file-tree').findByText('frog.jpg').click()
|
||||
cy.findByText('Another project')
|
||||
.should('have.attr', 'href')
|
||||
.then(href => {
|
||||
@@ -121,9 +117,7 @@ describe('Project creation and compilation', function () {
|
||||
cy.url().should('include', targetProjectId)
|
||||
})
|
||||
|
||||
cy.get('.file-tree').first().within(() => {
|
||||
cy.findByText('frog.jpg').click()
|
||||
})
|
||||
cy.findByTestId('file-tree').findByText('frog.jpg').click()
|
||||
cy.findByText('Another project')
|
||||
.should('have.attr', 'href')
|
||||
.then(href => {
|
||||
|
||||
Reference in New Issue
Block a user