### Question:
DecimalDegrees extends Coordinates { @Override public String toShortLabelString() { return toShortLabelString(11, 6); } DecimalDegrees(Coordinates ang);  DecimalDegrees(double degrees); @Override DecimalDegrees clone(); @Override String getLongLabel(); @Override String getShortLabel(); @Override String toShortLabelString(); @Override String toShortLabelString(char positive, char negative); @Override String toShortLabelString(int width, int precision); @Override String toShortLabelString(int width, int precision, char positive, char negative); static final String DEGREES_LONG_LABEL; static final String DEGREES_SHORT_LABEL; }### Answer:
@Test public void testToShortLabelString() { Assert.assertEquals(" 34.545120\u00B0", new DecimalDegrees(34.54512).toShortLabelString()); Assert.assertEquals(" 134.545120\u00B0", new DecimalDegrees(134.54512).toShortLabelString()); Assert.assertEquals(" 134.545125\u00B0", new DecimalDegrees(134.545125).toShortLabelString()); Assert.assertEquals(" 134.545126\u00B0", new DecimalDegrees(134.5451255).toShortLabelString()); Assert.assertEquals("-34.545120\u00B0", new DecimalDegrees(-34.54512).toShortLabelString()); Assert.assertEquals("-134.545120\u00B0", new DecimalDegrees(-134.54512).toShortLabelString()); Assert.assertEquals(" -0.000000\u00B0", new DecimalDegrees(-0.0000004).toShortLabelString()); }
@Test public void testToShortLabelStringCharChar() { Assert.assertEquals(" 34.545120\u00B0N", new DecimalDegrees(34.54512).toShortLabelString('N', 'S')); Assert.assertEquals(" 134.545120\u00B0N", new DecimalDegrees(134.54512).toShortLabelString('N', 'S')); Assert.assertEquals(" 134.545125\u00B0N", new DecimalDegrees(134.545125).toShortLabelString('N', 'S')); Assert.assertEquals(" 134.545126\u00B0N", new DecimalDegrees(134.5451255).toShortLabelString('N', 'S')); Assert.assertEquals(" 34.545120\u00B0S", new DecimalDegrees(-34.54512).toShortLabelString('N', 'S')); Assert.assertEquals(" 134.545120\u00B0S", new DecimalDegrees(-134.54512).toShortLabelString('N', 'S')); Assert.assertEquals(" 0.000000\u00B0S", new DecimalDegrees(-0.).toShortLabelString('N', 'S')); }