Added test for expandterms.