fixes for_each tests for JS server and drivers