Unit/System Tests PR-5.3-dev Pending

User tests: Successful: Unsuccessful:

avatar laoneo
laoneo
29 Apr 2025

Summary of Changes

Checks the error log file after each test if there is an entry written to it.

Testing Instructions

Place somewhere in the CMS code the following code snippet ( I added it for testing to administrator/components/com_actionlogs/src/Model/ActionlogsModel.php into the delete function)

error_log('test');

Run the system test ( was running tests/System/integration/administrator/components/com_actionlogs/Actionlogs.cy.js).

Actual result BEFORE applying this Pull Request

The test was running through.

Expected result AFTER applying this Pull Request

The test failed.

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:

  • No documentation changes for manual.joomla.org needed

avatar laoneo laoneo - open - 29 Apr 2025
avatar laoneo laoneo - change - 29 Apr 2025
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 29 Apr 2025
Category JavaScript Unit Tests Repository
b6dc5cb 29 Apr 2025 avatar laoneo order
avatar laoneo laoneo - change - 29 Apr 2025
Labels Added: Unit/System Tests PR-5.3-dev
avatar heelc29
heelc29 - comment - 29 Apr 2025

Works in my local test environment. Do some other test cases.

avatar laoneo laoneo - change - 30 Apr 2025
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2025-04-30 06:27:27
Closed_By laoneo
avatar laoneo laoneo - close - 30 Apr 2025
avatar laoneo laoneo - merge - 30 Apr 2025
avatar muhme
muhme - comment - 30 Apr 2025

✅ Tested successfully on MacBook Air M3 Sequoia 15.4.1, with local PHP 8.4.6, Apache 2.4.62, MariaDB 11.6.2 and with Docker container based PHP 8.4.3, Apache 2.4.62, MySQL 8.3
With fresh cloned software and Joomla installation. As the PR is meanwhile merged, I started without PR

git checkout 78d2b757a2

1. Overall System Test Time

  • As there is log file writing included with each test, I like to see if this could hurt
  • 148 specs with 572 tests
  • w/o the PR (git checkout 78d2b757a2)
    • 6:21 Testing HTTP npm run cypress:run
    • 11:02 Testing HTTPS (cd tests/System && docker compose down && docker compose up system-tests)
      • This long running time may be related to the fact that joomlaprojects/docker-images:cypress8.4 container is only x86_64 (amd64) and the Apple M3 MacBook Air (with arm64/v8) is emulating x86_64 (amd64) architecture using QEMU, which is slower
  • w/ PR (git checkout 5.3-dev)
    • 6:25 Testing HTTP npm run cypress:run with logFile: '/opt/homebrew/var/log/httpd/error_log' configured in cypress.config.mjs file
    • 11:19 Testing HTTPS (cd tests/System && docker compose down && docker compose up system-tests) with logFile=/var/log/apache2/error.log set in entrypoint.sh script
  • ✅ Apache log file reading and writing doesn't increase the test time

2. Functionality

  • w/ PR (git checkout 5.3-dev), Testing HTTP local with logFile: '/opt/homebrew/var/log/httpd/error_log' configured in cypress.config.mjs file
  • Added error_log('test'); into delete() function into administrator/components/com_actionlogs/src/Model/ActionlogsModel.phpfile
  • ✅ Running single test spec npx cypress run --spec tests/System/integration/administrator/components/com_actionlogs/Actionlogs.cy.js one test fails
  • ✅ Running npm run cypress:run one test fails
  • ✅ Running (cd tests/System && docker compose down && docker compose up system-tests) one test fails

Add a Comment

Login with GitHub to post a comment