Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
tests: mirror presets that are actually used
  • Loading branch information
USERSATOSHI committed Sep 16, 2025
commit 3239c573c779931c13258d8310ae66821f949a80
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
/**
* WordPress dependencies
*/
import { __ } from '@wordpress/i18n';

/**
* Internal dependencies
*/
Expand Down Expand Up @@ -185,9 +190,9 @@ describe( 'mode', () => {

describe( 'getPresetValueFromCustomValue', () => {
const presets = [
{ name: 'None', slug: '0', size: '0' },
{ name: 'Small', slug: 'sm', size: '4px' },
{ name: 'Medium', slug: 'md', size: 'clamp(2px, 1vw, 8px)' },
{ name: __( 'None' ), slug: '0', size: 0 },
{ name: __( 'Small' ), slug: 'sm', size: '4px' },
{ name: __( 'Medium' ), slug: 'md', size: 'clamp(2px, 1vw, 8px)' },
];

it( 'should return "0" if value is "0"', () => {
Expand Down Expand Up @@ -225,9 +230,9 @@ describe( 'getPresetValueFromCustomValue', () => {

describe( 'getPresetValueFromControlValue', () => {
const presets = [
{ name: 'None', slug: '0', size: '0' },
{ name: 'Small', slug: 'sm', size: '4px' },
{ name: 'Medium', slug: 'md', size: 'clamp(2px, 1vw, 8px)' },
{ name: __( 'None' ), slug: '0', size: 0 },
{ name: __( 'Small' ), slug: 'sm', size: '4px' },
{ name: __( 'Medium' ), slug: 'md', size: 'clamp(2px, 1vw, 8px)' },
];

it( 'should return "0" if control value is 0 and not selectList', () => {
Expand Down
Loading