Unit tests for tab completion
Fixed a TODO error in tab completion