Fix a couple of bugs in test tab completion.