@@ -672,8 +672,8 @@ public void testComputedStyleAttr() {
672672 /*
673673 * attr() percentage invalid value type.
674674 */
675- elm .getOverrideStyle (null ).setCssText ("margin-left:attr(leftmargin % )" );
676- assertEquals ("margin-left: attr(leftmargin % ); " , elm .getOverrideStyle (null ).getCssText ());
675+ elm .getOverrideStyle (null ).setCssText ("margin-left:attr(leftmargin percentage )" );
676+ assertEquals ("margin-left: attr(leftmargin percentage ); " , elm .getOverrideStyle (null ).getCssText ());
677677 style = elm .getComputedStyle (null );
678678 marginLeft = (CSSTypedValue ) style .getPropertyCSSValue ("margin-left" );
679679 // Default fallback
@@ -685,7 +685,7 @@ public void testComputedStyleAttr() {
685685 /*
686686 * attr() percentage invalid value type, fallback.
687687 */
688- elm .getOverrideStyle (null ).setCssText ("margin-left:attr(leftmargin % , 1.2em)" );
688+ elm .getOverrideStyle (null ).setCssText ("margin-left:attr(leftmargin percentage , 1.2em)" );
689689 style = elm .getComputedStyle (null );
690690 marginLeft = (CSSTypedValue ) style .getPropertyCSSValue ("margin-left" );
691691 assertEquals (25.92f , marginLeft .getFloatValue (CSSUnit .CSS_PT ), 0.01f );
@@ -697,7 +697,7 @@ public void testComputedStyleAttr() {
697697 * attr() percentage value type.
698698 */
699699 elm .setAttribute ("leftmargin" , "2" );
700- elm .getOverrideStyle (null ).setCssText ("margin-left:attr(leftmargin % )" );
700+ elm .getOverrideStyle (null ).setCssText ("margin-left:attr(leftmargin percentage )" );
701701 style = elm .getComputedStyle (null );
702702 marginLeft = (CSSTypedValue ) style .getPropertyCSSValue ("margin-left" );
703703 assertEquals (2f , marginLeft .getFloatValue (CSSUnit .CSS_PERCENTAGE ), 0.01f );
@@ -708,7 +708,7 @@ public void testComputedStyleAttr() {
708708 * attr() percentage value type (II).
709709 */
710710 elm .setAttribute ("leftmargin" , "2%" );
711- elm .getOverrideStyle (null ).setCssText ("margin-left:attr(leftmargin % )" );
711+ elm .getOverrideStyle (null ).setCssText ("margin-left:attr(leftmargin percentage )" );
712712 style = elm .getComputedStyle (null );
713713 marginLeft = (CSSTypedValue ) style .getPropertyCSSValue ("margin-left" );
714714 assertEquals (2f , marginLeft .getFloatValue (CSSUnit .CSS_PERCENTAGE ), 0.01f );
0 commit comments