Feature ? ? PR-4.4-dev Pending

User tests: Successful: Unsuccessful:

avatar rajputanuj31
rajputanuj31
2 Jun 2023

Added Cypress test for categories of banners , contacts and content.

avatar joomla-cms-bot joomla-cms-bot - change - 2 Jun 2023
Category JavaScript Unit Tests
avatar rajputanuj31 rajputanuj31 - open - 2 Jun 2023
avatar rajputanuj31 rajputanuj31 - change - 2 Jun 2023
Status New Pending
avatar laoneo
laoneo - comment - 3 Jun 2023

Thanks for the pr. Can you change the describe texts that they look the same as https://github.com/joomla/joomla-cms/blob/4.4-dev/tests/System/integration/api/com_newsfeed/Categories.cy.js#L1?

avatar rajputanuj31 rajputanuj31 - change - 3 Jun 2023
Labels Added: ? ? PR-4.4-dev
avatar rajputanuj31
rajputanuj31 - comment - 3 Jun 2023

Thanks for the pr. Can you change the describe texts that they look the same as https://github.com/joomla/joomla-cms/blob/4.4-dev/tests/System/integration/api/com_newsfeed/Categories.cy.js#L1?

Done.

avatar rajputanuj31
rajputanuj31 - comment - 6 Jun 2023

Hey @laoneo can you please check why one test is failing. it is running perfectly in my local system.

avatar laoneo
laoneo - comment - 6 Jun 2023

Run the install test first and then this one. You will figure out what the problem is then.

avatar laoneo laoneo - change - 14 Jun 2023
Labels Added: Feature
avatar laoneo
laoneo - comment - 16 Jun 2023

The problem was that there are default categories created during installation (with the title 'Uncategorized') where data[0] is returning that one instead the newly created one.

avatar laoneo laoneo - close - 16 Jun 2023
avatar laoneo laoneo - merge - 16 Jun 2023
avatar laoneo laoneo - change - 16 Jun 2023
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2023-06-16 07:23:03
Closed_By laoneo
avatar laoneo
laoneo - comment - 16 Jun 2023

Finally, thanks!

avatar rajputanuj31
rajputanuj31 - comment - 16 Jun 2023

The problem was that there are default categories created during installation (with the title 'Uncategorized') where data[0] is returning that one instead the newly created one.

Ok understood. I spent a lot of time to understand why test is failing but fail to get the reason.
Thanks a lot for this.

avatar laoneo
laoneo - comment - 16 Jun 2023

In cypress when you click on the actual request, then it prints the response to the browser console. Like that you can see quickly what comes back from the API:
image

Add a Comment

Login with GitHub to post a comment