added test for result set (merges and clear functionality)