Problem/Motivation
drupal-check results on commit hash: e8eb2f872f2499e15566d47ca694e5f6d743c545
------ ---------------------------------------------------
Line src/Form/FieldsSettingsForm.php
------ ---------------------------------------------------
225 Call to deprecated function drupal_set_message().
490 Call to deprecated function drupal_set_message().
------ ---------------------------------------------------
------ -----------------------------------------------------------------------------------
Line src/Tests/DiffRevisionTest.php
------ -----------------------------------------------------------------------------------
16 Usage of deprecated trait Drupal\system\Tests\Menu\AssertBreadcrumbTrait in class
Drupal\diff\Tests\DiffRevisionTest.
------ -----------------------------------------------------------------------------------
------ ----------------------------------------------------------------
Line src/Tests/DiffViewsTest.php
------ ----------------------------------------------------------------
17 Class Drupal\diff\Tests\DiffViewsTest extends deprecated class
Drupal\views\Tests\ViewTestBase.
------ ----------------------------------------------------------------
[ERROR] Found 4 errors
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
| Comment | File | Size | Author |
|---|---|---|---|
| #26 | 3042675-26.patch | 5.87 KB | berdir |
| #23 | 3042675-23.patch | 380 bytes | sahana _n |
| #21 | 3042675-21.patch | 380 bytes | sahana _n |
| #18 | interdiff_15_18.txt | 604 bytes | jkswoods |
| #18 | 3042675-18.patch | 5.65 KB | jkswoods |
Comments
Comment #2
sergiu stici commentedHere is the patch, please review.
Comment #4
gun2dru commentedPlease review.
Thanks
Comment #5
gun2dru commentedComment #6
gun2dru commentedComment #7
katherinedComment #8
katherinedTrying this again. I get the same test failure with and without this patch, so I don't think it's the patch.
Comment #9
juampynr commentedHi everyone!
Patch looks good but there are test failures. @katherined, you said at Slack that they are not related, right? What puzzles me is that https://www.drupal.org/node/20492/qa states that the last time that the test suite ran for 8.x-1.x it passed.
Comment #10
miro_dietikerTriggered a rerun of the tests.
If head is broken plz first help create an issue to fix it.
What confuses me is there are no 8.8 head tests, so i guess we should update our head ci auto testbot config..
Comment #11
oknateIssue to update test configurations: #3088464: Test against PHP 7 only for Drupal 8
Comment #12
katherinedComment #13
phenaproximaThis looks great to me. The only thing still needed is to modify the info file to require the minimum version of Drupal core which implements these things (which is where I think we introduced ConfigurableInterface). See https://www.drupal.org/node/3070687 for guidance...
Comment #14
jkswoods commentedAdded core version requirement. Since it was introduced in 8.7.7, this makes it newer than the deprecations by about 3 minor versions and makes sense to use `^8 || ^9` as the constraint. Thoughts?
Also, is there a reason for reverting a change to remove deprecated code in #12? This prevents drupal-check from coming back clean:
```
------ -----------------------------------------------------------------------------------------------------------------------
Line src/Tests/DiffRevisionTest.php
------ -----------------------------------------------------------------------------------------------------------------------
16 Usage of deprecated trait Drupal\system\Tests\Menu\AssertBreadcrumbTrait in class Drupal\diff\Tests\DiffRevisionTest:
Scheduled for removal in Drupal 9.0.0.
Use \Drupal\Tests\system\Functional\Menu\AssertBreadcrumbTrait instead.
------ -----------------------------------------------------------------------------------------------------------------------
```
Comment #15
jkswoods commentedForgot to include the version constraint in composer.json.
Comment #16
berdirYeah, I'm also confused about #12, that trait is around since 8.4 and safe to use? Accidental revert maybe?
This change requires 8.7, so you could just as well make the jump to (only) defining core_version_requirement: ^8.7.7 || ^9 and same in composer.json
(that is still important because drupal composer facade can't yet translate core_version_requirement to a drupal/core requirement and composer might update sites with too old core versions to a new version of the module).
Comment #17
berdirAh, there is a good reason for the test change. There's a separate issue to properly convert the tests, this has incorrect base class changes without actually changing the namespace and moving them. So lets drop all test changes here and deal with that in #3089491: Convert all tests to PHPUnit.
Comment #18
jkswoods commentedAwesome, as per #16, the core_version_requirement has been changed to
^8.7.7 || ^9- composer.json has also been updated to reflect this change.Comment #19
berdirThe test changes still need to be reverted. So it doesn't conflict with the referenced issue.
Run all tests with both patches combined (and ignoring conflicts), I still get this warning that's relevant for this issue:
Comment #20
berdirAlso, tests/modules/diff_test/diff_test.info.yml needs to be updated too for the core: change.
Comment #21
sahana _n commentedPlease review the patch.
Comment #22
berdirSame here, you need to post complete patches, also this is missing the removal of the core key.
Comment #23
sahana _n commentedThanks for the review. Please review the patch. If mistakes found, please let me know.
Comment #24
sahana _n commentedComment #25
berdirAgain, when working on an issue with existing patches/work, you need to apply that first, add your changes on top of it and then provide an complete patch with all changes and an interdiff with the difference to the previous patch.
Didn't find a good documentation page but https://www.drupal.org/patch/reroll and https://www.drupal.org/documentation/git/interdiff are something you should read through. You're not really doing a reroll, but it's similar, except that there won't be conflicts.
Comment #26
berdirOk, the only thing left with this when running all tests is this:
And that isn't really going to be break in D9, just a consistency thing and requires 8.8, even if only in the test. So I think this is ready.
Comment #27
jkswoods commentedTests are passing locally and all good with the manual checks. drupal-check is returning a few deprecation notices in the test files but there is nothing that can't be followed up on in a separate issue. In my opinion, this is good to go.
Comment #28
berdirI'm not seeing anything with drupal-check, what are you seeing there exactly?
Comment #29
jkswoods commented@Berdir This is the output I'm seeing from drupal-check for the tests.
Comment #30
berdirAh, you're missing #3089491: Convert all tests to PHPUnit, tests were fixed over there. This no longer conflicts with it as all test-related changes have been removed as they're already done.
Comment #31
chr.fritschReady to go 👍
Comment #32
phenaproximaEDIT: Redacted. I had forgotten the difference between ^ and ~ in Composer-ese.
Comment #34
phenaproximaCommitted and pushed to 8.x-1.x. Thanks!