Opened 5 weeks ago
Closed 5 weeks ago
#65186 closed enhancement (fixed)
Tests: Add unit tests for _customizer_mobile_viewport_meta()
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Milestone: | 7.1 | Priority: | normal |
| Severity: | normal | Version: | |
| Component: | Administration | Keywords: | has-patch has-unit-tests |
| Focuses: | tests | Cc: |
Description (last modified by )
This ticket adds unit tests for the _customizer_mobile_viewport_meta() function in wp-admin/includes/misc.php. The tests will verify that the function correctly appends the mobile-specific viewport settings to the existing viewport meta string.
Change History (5)
#1
@
5 weeks ago
- Description modified (diff)
- Summary changed from Tests: Add unit tests for extract_from_markers() to Tests: Add unit tests for _customizer_mobile_viewport_meta()
This ticket was mentioned in PR #11743 on WordPress/wordpress-develop by @pbearne.
5 weeks ago
#2
- Keywords has-patch has-unit-tests added
Note: See
TracTickets for help on using
tickets.
Description:
This PR adds unit tests for the
_customizer_mobile_viewport_meta()function inwp-admin/includes/misc.php. These tests ensure that the function correctly appends Customizer-specific viewport settings (minimum-scale=0.5,maximum-scale=1.2) to an existing viewport meta string, while handling trailing commas and empty input.The tests cover:
Trac ticket: https://core.trac.wordpress.org/ticket/65186
AI Disclosure: