Fix tests + Add logging