Problem/Motivation

In #540008: Add a container parameter that can remove the special behavior of UID#1 an approach was taken where we can simply flag tests that are failing if we turn off user 1's super user powers, so that they can be taken care of in a followup. This issue is to collect all of these followups.

The goal is to have no tests in Drupal core that rely on UID1's special privileges so that we:

  1. Know these tests are correctly assigning the necessary permissions to run
  2. Can turn off the super user access policy in D11, knowing it won't break core
  3. Can remove the super user access policy in D12, providing an admin account recovery tool to replace it

Steps to reproduce

Go into any of the tests flagged with:

  /**
   * {@inheritdoc}
   *
   * @todo Remove and fix test to not rely on super user.
   * @see https://www.drupal.org/project/drupal/issues/3437620
   */

And:

  1. Remove the code below that sets the usesSuperUserAccessPolicy to TRUE.
  2. Run the test to see which test methods are failing

Proposed resolution

Assign the right permissions to make the test go green without the super user access policy. Those few tests that specifically test said policy can obviously stay, but will be removed along with the policy in D12.

Remaining tasks

Fix #3515189: MigrateControllerTest requires root user, remove @todo

User interface changes

None

API changes

None

Data model changes

None

Release notes snippet

None

Comments

kristiaanvandeneynde created an issue. See original summary.

kristiaanvandeneynde’s picture

Issue summary: View changes
kristiaanvandeneynde’s picture

kristiaanvandeneynde’s picture

Issue summary: View changes

Perhaps we can group the list in the IS by module/subsystem, updated as such. This leaves 27 issues to be created rather than 71.

smustgrave’s picture

Issue summary: View changes

Put in bold at the top of the issue summary any follow ups should be novice

vensires’s picture

Issue tags: +GreeceSpringSprint2024
kristiaanvandeneynde’s picture

vensires’s picture

Issue tags: -GreeceSpringSprint2024

I have created all the different issues described as children-issues of this meta.

kristiaanvandeneynde’s picture

Issue summary: View changes

Awesome, thanks! Updated the IS.

kristiaanvandeneynde’s picture

Issue summary: View changes
kristiaanvandeneynde’s picture

Issue summary: View changes

Updated IS to shorten list of remaining tasks.

andypost’s picture

Only 7 issues left in child-list

kristiaanvandeneynde’s picture

Issue summary: View changes
kristiaanvandeneynde’s picture

Issue summary: View changes

Whoops, removed wrong one. Rectifying.

kristiaanvandeneynde’s picture

Issue summary: View changes

Sorry for the noise, colors changed after I updated. Seems we're down to 6 now!

pooja_sharma’s picture

Issue summary: View changes
pooja_sharma’s picture

Issue summary: View changes
pooja_sharma’s picture

Issue summary: View changes
quietone’s picture

Issue summary: View changes

One left to look into

quietone’s picture

Issue summary: View changes
kristiaanvandeneynde’s picture

Issue summary: View changes

Did you delete the MigrateControllerTest message by mistake?

I think that's the final one to open a child issue for, but it's probably a bit more complex to fix as I recall it involves changing JavaScript.

Edit: Never mind, found the one you created and will link it in the IS.

kristiaanvandeneynde’s picture

Issue summary: View changes
kristiaanvandeneynde’s picture

Issue summary: View changes
quietone’s picture

Status: Active » Fixed

The last child issue has been fixed.

A search,

 ag  https://www.drupal.org/project/drupal/issues/3437620 core

return nothing, so all the instances have been fixed.

Thanks to everyone here for getting this done!

kristiaanvandeneynde’s picture

🎉

Big thanks to everyone involved!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.