- Issue created by @mstrelan
- Status changed to Needs review
7 months ago 5:50am 31 January 2024 - Status changed to RTBC
7 months ago 2:49pm 1 February 2024 - 🇺🇸United States smustgrave
Additional changes look fine to me. Just did the eye test
- 🇦🇺Australia mstrelan
To prove that this is the last of the strict type issues and we haven't missed any, see results from the latest rebase at https://git.drupalcode.org/issue/drupal-3399746/-/pipelines/86427/test_r...
- Status changed to Needs work
7 months ago 8:47am 5 February 2024 - 🇳🇿New Zealand quietone New Zealand
I read the MR and the changes look fine to me. I then applied the diff and ran this yucky grep.
$ grep --exclude-dir={node_modules,vendor} -r "assert" core | grep -vi assertsession | grep Functional | grep Formattable | awk -F: '{print $1}' | sort -u core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php core/modules/views/tests/src/Functional/Plugin/DisplayTest.php
DisplayTest does not need to be changed. But doesn't this need to be changed, https://git.drupalcode.org/project/drupal/-/blob/11.x/core/lib/Drupal/Co... ? Or is that in another issue. I did read the similar issues but I didn't see it.
- 🇦🇺Australia mstrelan
Interesting. The tests don't fail when adding strict types. Is this dead code? Will investigate tomorrow.
- 🇦🇺Australia mstrelan
Oh, this directory is not in any of the patterns we're matching. I dare say there are more issues to solve in the directory. Maybe we can leave that for another issue?
- Status changed to Needs review
7 months ago 10:02pm 5 February 2024 - 🇦🇺Australia mstrelan
I updated
FunctionalTestSetupTrait
because it's easier to do than debating whether to do it or not. That said, it won't get the strict_types treatment because theDrupal\Core\Test
namespace is kind of special. I don't know much about it, but it includes code that is reference by non-test code, so we need to be careful not to break anything. For example,\Drupal\Core\Test\HttpClientMiddleware\TestHttpClientMiddleware
is referenced by\Drupal\Core\CoreServiceProvider
, albeit in a function namedregisterTest
. I also don't understand whyAssertMailTrait
and other traits are in here and not inDrupal\Tests\Traits
. - 🇦🇺Australia mstrelan
Also found these:
📌 Document the purpose of code in Drupal\Core\Test Postponed
📌 move things from lib/Drupal/Core/Test to core/tests Active
📌 Create a new component for the test runner Active - Status changed to RTBC
7 months ago 3:02pm 9 February 2024 - 🇺🇸United States smustgrave
Changes in MR still appear fine.
Should a follow up be made to revisit Drupal\Core\Test
- 🇦🇺Australia mstrelan
> Should a follow up be made to revisit Drupal\Core\Test
I think 📌 move things from lib/Drupal/Core/Test to core/tests Active covers anything that will be moved to
core/tests
, and the remaining files inDrupal\Core\Test
can be handled when/if strict types is added to the rest of the runtime code. -
quietone →
committed aafb4a44 on 11.x
Issue #3418236 by mstrelan, smustgrave: Fix strict type errors: Convert...
-
quietone →
committed aafb4a44 on 11.x
-
quietone →
committed 5ccf44d2 on 10.2.x
Issue #3418236 by mstrelan, smustgrave: Fix strict type errors: Convert...
-
quietone →
committed 5ccf44d2 on 10.2.x
- Status changed to Fixed
7 months ago 2:43am 14 February 2024 - 🇳🇿New Zealand quietone New Zealand
Committed to 11.x and cherry-picked to 10.2.x
Thanks!
- 🇳🇿New Zealand quietone New Zealand
Forgot to comment that I agree that a follow up is not needed.
Automatically closed - issue fixed for 2 weeks with no activity.