Add a IO mock in tests