PR-6.0-dev Pending

User tests: Successful: Unsuccessful:

avatar mahmoudmagdy1-1
mahmoudmagdy1-1
13 Jul 2025

Continuation of #45552

Summary of Changes

a fully Joomla stack : fresh joomla installation with phpmyadmin,xdebug,cypress
This PR adds the ability to test other PRs using GitHub Codespaces, or even use it as a full development environment.
you can access the database directly using phpmyadmin, and run tests using Cypress, you can find more details in the codespace-details.txt file after creating the codespace with this PR

Testing Instructions

  1. Create a new codespace from a branch that contains the .devcontainer files
  2. You can access and see the Joomla install / Cypress GUI in "ports" inside github.dev
  3. For credentials and more details you can see codespace-details.txt

Actual result BEFORE applying this Pull Request

N/A

Expected result AFTER applying this Pull Request

An easy way to test PRs on the cloud without setting everything up manually and on your local machine

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org: joomla/Manual#496

  • No documentation changes for manual.joomla.org needed

avatar mahmoudmagdy1-1 mahmoudmagdy1-1 - open - 13 Jul 2025
avatar mahmoudmagdy1-1 mahmoudmagdy1-1 - change - 13 Jul 2025
Status New Pending
avatar mahmoudmagdy1-1 mahmoudmagdy1-1 - change - 13 Jul 2025
Labels Added: PR-6.0-dev
avatar brianteeman
brianteeman - comment - 14 Jul 2025

Is it expected that at the end of the setup the terminal doesnt return to a prompt

image
avatar brianteeman
brianteeman - comment - 14 Jul 2025

It is not possible to run the cypress tests as Joomla wont install in this configuration see screenshot

image
avatar mahmoudmagdy1-1
mahmoudmagdy1-1 - comment - 14 Jul 2025

It is not possible to run the cypress tests as Joomla wont install in this configuration see screenshot

we don't need to run the installation script as Joomla is already installed automatically, you can access it when clicking on this after the github codespaces finishes building
image
other tests pass normally using this setup, for example:
image

avatar mahmoudmagdy1-1
mahmoudmagdy1-1 - comment - 14 Jul 2025

Is it expected that at the end of the setup the terminal doesnt return to a prompt
yes this is expected after building the container, but you can always start a new terminal

avatar mahmoudmagdy1-1
mahmoudmagdy1-1 - comment - 14 Jul 2025

Is it expected that at the end of the setup the terminal doesnt return to a prompt

yes this is expected after building the container, but you can always start a new terminal

avatar brianteeman
brianteeman - comment - 14 Jul 2025

Is it expected that at the end of the setup the terminal doesnt return to a prompt

yes this is expected after building the container, but you can always start a new terminal

thanks - was just checking

avatar brianteeman
brianteeman - comment - 14 Jul 2025

It is not possible to run the cypress tests as Joomla wont install in this configuration see screenshot

we don't need to run the installation script as Joomla is already installed automatically, you can access it when clicking on this after the github codespaces finishes building

Then I suggest a change in the text is required because it currently says

    echo "  Run interactive tests: npx cypress open"
    echo "  Run headless tests:   npx cypress run"

and that fails because the first test is installation and that will fail for the reasons above

avatar mahmoudmagdy1-1
mahmoudmagdy1-1 - comment - 15 Jul 2025

Then I suggest a change in the text is required because it currently says

    echo "  Run interactive tests: npx cypress open"
    echo "  Run headless tests:   npx cypress run"

and that fails because the first test is installation and that will fail for the reasons above

okay, what do you suggest i should change the text to? i want to also add that you can use npx cypress run --spec path/to/file.spec.js to run a specific spec and you don't have to run all specs at once
I think the current cypress tests are mainly focused on the ci pipeline (please correct me if i'm wrong), but at least with this setup if someone wants to test or add a spec they can

avatar mahmoudmagdy1-1
mahmoudmagdy1-1 - comment - 16 Jul 2025

I just edited some of the joomla config names to match Cypress config' default values, and got Cypress to run and pass all tests, except 2 test files that had 2 errors each
image
those are the files with the errors
image
the error is the same for all 4 failing tests:
image

I would love to hear some feedback about the setup and if someone can direct me on how fix the last errors, this exact error was mentioned in #44434 but had no actual solution

avatar alikon
alikon - comment - 4 Aug 2025

even it is a temporay fix , as it is already done in other plcaes, you can do the same where tests are failing

// @TODO: The following line is just a temporary fix. Remove it and uncomment the 2 lines after it when done.
expect(response.status).to.eq(200);
// expect(response.status).to.eq(301);
// expect(response.redirectedToUrl).to.match(new RegExp(`${url}$`));

avatar laoneo
laoneo - comment - 9 Aug 2025

This is great work, thanks. But we need also proper documentation so it will get attention and can be used for testing pr's.

avatar mahmoudmagdy1-1
mahmoudmagdy1-1 - comment - 9 Aug 2025

even it is a temporay fix , as it is already done in other plcaes, you can do the same where tests are failing

Okay sure

This is great work, thanks. But we need also proper documentation so it will get attention and can be used for testing pr's.

Thank you, Are we talking about documentation for the Joomla manual or where exactly? I'm willing to write a documentation for this feature

avatar softforge
softforge - comment - 11 Aug 2025

Hi @mahmoudmagdy1-1 would really like to get this in 6.0 but you only have days before the beta, can you write the documentation and just check through the comments and @Bodge-IT and I will try and get some tests
Thank you.

avatar brianteeman
brianteeman - comment - 11 Aug 2025

this pr doesnt include any production code so shouldnt be tied to the release of j6

avatar alikon
alikon - comment - 12 Aug 2025

imho should be backported to 5.3 / 5.4 as can help with the upcoming PBF

avatar alikon
alikon - comment - 12 Aug 2025

for 6.0 \define('JOOMLA_MINIMUM_PHP', '8.3.0');

avatar mahmoudmagdy1-1
mahmoudmagdy1-1 - comment - 12 Aug 2025

would really like to get this in 6.0 but you only have days before the beta

Hey @softforge, Like brian mentioned, it's not tied to the release of j6, it should work on all versions (5.3-dev, 5.4-dev) as well

can you write the documentation and just check through the comments and @Bodge-IT and I will try and get some tests Thank you.

Sure, I'm working on it right now, I think the best place for it, is : https://manual.joomla.org/docs/testing/manually

Thanks for the pr @alikon

avatar softforge
softforge - comment - 12 Aug 2025

Hey @softforge, Like Brian mentioned, it's not tied to the release of j6, it should work on all versions (5.3-dev, 5.4-dev) as well

Thank you for your work to date. I had just posted it back into maintainers to ask for the process and open the discussion there. I'll let you know as soon as I have an answer.

avatar mahmoudmagdy1-1 mahmoudmagdy1-1 - change - 12 Aug 2025
The description was changed
avatar mahmoudmagdy1-1 mahmoudmagdy1-1 - edited - 12 Aug 2025
avatar mahmoudmagdy1-1 mahmoudmagdy1-1 - change - 12 Aug 2025
The description was changed
avatar mahmoudmagdy1-1 mahmoudmagdy1-1 - edited - 12 Aug 2025
avatar mahmoudmagdy1-1 mahmoudmagdy1-1 - change - 12 Aug 2025
The description was changed
avatar mahmoudmagdy1-1 mahmoudmagdy1-1 - edited - 12 Aug 2025
avatar mahmoudmagdy1-1
mahmoudmagdy1-1 - comment - 12 Aug 2025

Thank you for your work to date. I had just posted it back into maintainers to ask for the process and open the discussion there. I'll let you know as soon as I have an answer.

Thanks, I've also just added the documentation for this feature and put the link of the docs in the pr description

avatar alikon alikon - test_item - 20 Aug 2025 - Tested successfully
avatar alikon
alikon - comment - 20 Aug 2025

I have tested this item ✅ successfully on 371e787


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45719.

avatar alikon
alikon - comment - 20 Aug 2025

it would be good to have this pr merged for the upcoming PBF

avatar rdeutz rdeutz - test_item - 20 Aug 2025 - Tested successfully
avatar rdeutz
rdeutz - comment - 20 Aug 2025

I have tested this item ✅ successfully on 7753b0d

Looks ok so far, tested login into Joomla and phpmyadmin. Let run the system tests. Control window doesn't fit 100%.
Setup takes some time but compared to setting it up locally much faster. Execution of the system tests fast enough.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45719.

avatar laoneo laoneo - change - 20 Aug 2025
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2025-08-20 15:15:53
Closed_By laoneo
avatar laoneo laoneo - close - 20 Aug 2025
avatar laoneo laoneo - merge - 20 Aug 2025
avatar laoneo
laoneo - comment - 20 Aug 2025

Thank you very much for all the work on this and the patience. Now it is time to spread the word.

Add a Comment

Login with GitHub to post a comment