? ? Maintainers Checked Pending

User tests: Successful: Unsuccessful:

avatar wilsonge
wilsonge
19 Jun 2022

Summary of Changes

Fixes tests to run on PHP 8.1. Generally we shouldn't be mocking core PHP classes so this fixes:

  • Everywhere we mocked and then didn't even mock any values/return types etc. Just insert a real dummy instance
  • The one place we did test was mocking versions. Here however this covered up a bug because when turning to concrete tests it turned out we parsed the XML version in the XML doc type rather than the version of the feed being used :D This bug is fixed as part of this and one extra test case in atom added

Testing Instructions

Check Drone 8.1 tests

Actual result BEFORE applying this Pull Request

All tests related to feed do not pass

Expected result AFTER applying this Pull Request

All tests related to feed do pass (note session tests do fail - but that will be the subject of a different PR)

Documentation Changes Required

None

avatar wilsonge wilsonge - open - 19 Jun 2022
avatar wilsonge wilsonge - change - 19 Jun 2022
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 19 Jun 2022
Category Libraries Unit Tests
avatar wilsonge wilsonge - change - 19 Jun 2022
The description was changed
avatar wilsonge wilsonge - edited - 19 Jun 2022
avatar wilsonge
wilsonge - comment - 19 Jun 2022

Agreed but probably outside the scope of this PR

avatar HLeithner
HLeithner - comment - 19 Jun 2022

I mean a really test in an installed cms to merge this PR ;) not only codereview

avatar wilsonge
wilsonge - comment - 19 Jun 2022

Screenshot 2022-06-19 at 21 35 22

Screenshot 2022-06-19 at 21 35 17

Took a 3rd party one in too for good measure

avatar wilsonge wilsonge - change - 19 Jun 2022
Title
Remove mocking XMLReader as it's bad practice. Fix parsing version
[4.2] Remove mocking XMLReader as it's bad practice. Fix parsing version
avatar wilsonge wilsonge - edited - 19 Jun 2022
avatar fancyFranci fancyFranci - change - 22 Jun 2022
Labels Added: ? ? Maintainers Checked
avatar HLeithner HLeithner - change - 24 Jun 2022
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2022-06-24 09:47:07
Closed_By HLeithner
avatar HLeithner HLeithner - close - 24 Jun 2022
avatar HLeithner HLeithner - merge - 24 Jun 2022
avatar HLeithner
HLeithner - comment - 24 Jun 2022

Thanks

avatar wilsonge
wilsonge - comment - 24 Jun 2022

Thankyou!

Add a Comment

Login with GitHub to post a comment