PHPUnit: Improve tests for admin_toolbar_tools

Created on 25 February 2025, 2 months ago

Problem/Motivation

Currently tests coverage is very limited for the admin_toolbar_tools module, see:
https://git.drupalcode.org/project/admin_toolbar/-/tree/3.x/admin_toolba...

None of the settings of the module are being tested.

Steps to reproduce

Run phpunit tests for the admin_toolbar_tools module.

Proposed resolution

Improve the tests in existing class 'AdminToolbarToolsSettingsFormTest':
https://git.drupalcode.org/project/admin_toolbar/-/blob/3.x/admin_toolba...

  • Test the default state: displaying all (20) bundles, hoverintent library and local tabs.
  • Set all the values of the form to enable all settings and display 3 items.
  • Submit the form and check there is no error.
  • Test all the values changed with the new settings.
📌 Task
Status

Active

Version

3.0

Component

Code

Created by

🇫🇷France dydave

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024