refactor: Prepare test_list_projects for pre-prov

This is part 1 of 2 commits that aim to move tests from only being
executed with the dynamic creds credential provider.

Part 1 does some initial refactoring and Part 2 will move the tests
and finish any other refactoring that's needed.

Change-Id: I0a77350bb0832f0ecf5c50de48b81a8bb9609d2d
1 file changed