Fix some problems during testing