Made tests compatible with browser also