Updated to improve testing library behavior