added test for encloseAll method