[REF] Cleanup function for retrieving contact types.
This switches to using the apiv4 as part of trying to eliminate calls to executeQuery where the DAO is passed in
like
```
= CRM_Core_DAO::executeQuery(, [],
FALSE, 'CRM_Contact_DAO_ContactType'
);
```
Note that this file seems to be the only place this is done.
Also note that I added tests first & the changes to the test highlight what is changed in the PR in the output - namely
- stricter type casting (courtesy apiv4)
- same keys present for all types