Add trimLabels test cases.

Not sure if they meet expectations.