Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[cypress] + com_cache #43633

Merged
merged 4 commits into from
Jun 20, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
describe('Test in backend that the cache', () => {
beforeEach(() => {
cy.doAdministratorLogin();
cy.visit('/administrator/index.php?option=com_cache&view=cache');
});

it('have a title', () => {
cy.get('h1.page-title').should('contain.text', 'Maintenance: Clear Cache');
});

it('can display message', () => {
cy.get('div.alert.alert-info').should('contain.text', 'Select the Clear Expired Cache button');
});

it('can display a list of chached items', () => {
cy.get('tr.row0').should('contain.text', '_media_version');
});

it('can clear expired cache', () => {
cy.get('#toolbar-delete2').click();
cy.on('window:confirm', () => true);
alikon marked this conversation as resolved.
Show resolved Hide resolved
cy.get('#system-message-container').contains('Expired cached items have been cleared').should('exist');
});

it('can delete all', () => {
cy.get('#toolbar-delete1').click();
cy.get('#system-message-container').contains('All cache group(s) have been cleared').should('exist');
});
});