add test for #81 . refine some codes . update size