? ? Pending

User tests: Successful: Unsuccessful:

avatar PhilETaylor
PhilETaylor
17 Mar 2021

Summary of Changes

A Joomla 4 version of the unit test to cover b/c and security fixes in 3.9.25/26

Regardless of that, its a working unit test of the current code in 4.0-dev and can be improved upon in the future.

NOTE

NOTE: These tests are designed for, and pass, with 4.0-dev as it is today. When the security fixes for Joomla 3.9.26 are rolled into 4.0-dev eventually (by @wilsonge) then these tests SHOULD start to fail and will need true/false tweaking so that those test cases that are fixed by the security patches in Joomla 3.9.26 are now returning false...

Testing Instructions

run

libraries/vendor/phpunit/phpunit/phpunit tests/Unit/Libraries/Cms/Form/Rule/FilePathRuleTest.php

at the command line.

Actual result BEFORE applying this Pull Request

No testing of this important validation rule that has been subjected to Security issues in Joomla 3

Expected result AFTER applying this Pull Request

Some working testing based on the current state of Joomla 4.0-dev.

PHPUnit 8.5.13 by Sebastian Bergmann and contributors.

..............                                                    14 / 14 (100%)

Time: 38 ms, Memory: 8.00 MB

OK (14 tests, 14 assertions)

Documentation Changes Required

none

// #32718 for context.

avatar PhilETaylor PhilETaylor - open - 17 Mar 2021
avatar PhilETaylor PhilETaylor - change - 17 Mar 2021
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 17 Mar 2021
Category Unit Tests
avatar PhilETaylor PhilETaylor - change - 17 Mar 2021
Title
Unittests
[4.0] Add passing unit test for FilePathRule
avatar PhilETaylor PhilETaylor - edited - 17 Mar 2021
avatar PhilETaylor PhilETaylor - change - 17 Mar 2021
Labels Added: ? ?
avatar PhilETaylor PhilETaylor - change - 17 Mar 2021
Labels Added: ?
Removed: ?
avatar PhilETaylor PhilETaylor - change - 17 Mar 2021
The description was changed
avatar PhilETaylor PhilETaylor - edited - 17 Mar 2021
avatar PhilETaylor PhilETaylor - change - 17 Mar 2021
The description was changed
avatar PhilETaylor PhilETaylor - edited - 17 Mar 2021
avatar richard67 richard67 - test_item - 17 Mar 2021 - Tested successfully
avatar richard67
richard67 - comment - 17 Mar 2021

I have tested this item successfully on c4fbfb9

Unit tests pass on Linux (drone) and Windows (appveyor).

I've verified that test cases are the same as in the corresponding PR #32723 for staging (but of course with different expected results for some due to 3.9.25).


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

avatar PhilETaylor PhilETaylor - change - 18 Mar 2021
The description was changed
avatar PhilETaylor PhilETaylor - edited - 18 Mar 2021
avatar PhilETaylor PhilETaylor - change - 18 Mar 2021
Labels Added: ?
Removed: ?
avatar rdeutz rdeutz - change - 22 Mar 2021
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2021-03-22 07:51:13
Closed_By rdeutz
Labels Added: ?
Removed: ?
avatar rdeutz rdeutz - close - 22 Mar 2021
avatar rdeutz rdeutz - merge - 22 Mar 2021

Add a Comment

Login with GitHub to post a comment