Test fixes (mostly)