Fix up namespace completion

* Complete even when test dir is missing
* Remove trailing parentheses
* Use only one invocation of awk