tests error, but it seems to work, going to test in another context