### Question:
CSSNumberHelper { @Nullable public static CSSSimpleValueWithUnit getValueWithUnit (@Nullable final String sCSSValue) { return getValueWithUnit (sCSSValue, true); } private  CSSNumberHelper(); @Nullable static ECSSUnit getMatchingUnitInclPercentage(@Nonnull final String sCSSValue); @Nullable static ECSSUnit getMatchingUnitExclPercentage(@Nonnull final String sCSSValue); static boolean isNumberValue(@Nullable final String sCSSValue); static boolean isValueWithUnit(@Nullable final String sCSSValue); static boolean isValueWithUnit(@Nullable final String sCSSValue, final boolean bWithPerc); @Nullable static CSSSimpleValueWithUnit getValueWithUnit(@Nullable final String sCSSValue); @Nullable static CSSSimpleValueWithUnit getValueWithUnit(@Nullable final String sCSSValue, final boolean bWithPerc);  }### Answer:
@Test public void testGetValueWithUnit () { assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.PERCENTAGE), CSSNumberHelper.getValueWithUnit ("50%", true)); assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.LENGTH_MM), CSSNumberHelper.getValueWithUnit ("50mm", true)); assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.LENGTH_CM), CSSNumberHelper.getValueWithUnit ("50cm", true)); assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.EX), CSSNumberHelper.getValueWithUnit ("50ex", true)); assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.EX), CSSNumberHelper.getValueWithUnit (" 50ex ", true)); assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.EX), CSSNumberHelper.getValueWithUnit (" 50ex ", false)); assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.EX), CSSNumberHelper.getValueWithUnit (" 50 ex ", false)); assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.EX), CSSNumberHelper.getValueWithUnit (" 50 ex ", false)); assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.TIME_S), CSSNumberHelper.getValueWithUnit (" 50 s ", false)); assertEquals (new CSSSimpleValueWithUnit (50, ECSSUnit.TIME_MS), CSSNumberHelper.getValueWithUnit (" 50 ms ", false)); assertNull (CSSNumberHelper.getValueWithUnit (" 50 xs ", false)); assertNull (CSSNumberHelper.getValueWithUnit ("50%", false)); assertNull (CSSNumberHelper.getValueWithUnit ("", false)); assertNull (CSSNumberHelper.getValueWithUnit ("", true)); assertNull (CSSNumberHelper.getValueWithUnit (" ", false)); assertNull (CSSNumberHelper.getValueWithUnit (" ", true)); assertNull (CSSNumberHelper.getValueWithUnit (" mm ", true)); assertNull (CSSNumberHelper.getValueWithUnit (" % ", true)); assertNull (CSSNumberHelper.getValueWithUnit (" 50 xyz ", true)); assertNull (CSSNumberHelper.getValueWithUnit (" 50 gd ", true)); assertNull (CSSNumberHelper.getValueWithUnit ("50gd", true)); }