Fix from_string for open babel.
 Add unittest for from_string.