Cleanups for import unittest/unittest2

This change was made mechanically using sed, except for some manual edits in
test_build_graph.py and test_thrift_util.py

(I realize this change will be pretty much a no-op after we drop python 2.6 support)

Testing Done:
CI is running @ https://travis-ci.org/pantsbuild/pants/builds/32971877

Bugs closed: 500

Reviewed at https://rbcommons.com/s/twitter/r/919/
Fix credentials fetching during publishing

Reviewed at https://rbcommons.com/s/twitter/r/901/
Make sure junit_run task only runs on targets that are junit compaible

Testing Done:
Two questions:

1. any suggestions on how to write a unit test for the code change? I didn't find unittest for this class.

2. how do I test the changes? Should I just create some dummy BUILD files and only put resources targets into it to make sure they're all filtered out and junit_run does an no-opt?

Thanks for bearing with me.

Bugs closed: 508

Reviewed at https://rbcommons.com/s/twitter/r/924/
Put back error message that shows path to missing BUILD files.

Regressed from  https://rbcommons.com/s/twitter/r/841/

Added a better unit test.

Testing Done:
ci passed https://travis-ci.org/pantsbuild/pants/builds/33185813

Bugs closed: 510

Reviewed at https://rbcommons.com/s/twitter/r/929/
Use target() alias in unit tests instead of dependencies()

This completely removes 'dependencies' from all the aliases in testing and
updates the unit test BUILD file mockups.

Testing Done:
ci.sh passes locally.

Bugs closed: 514

Reviewed at https://rbcommons.com/s/twitter/r/933/
Move some more default from pants.ini into the code

Part of a continuing effort to get pants to work with empty pants.ini

Testing Done:
ci passed.

Bugs closed: 511

Reviewed at https://rbcommons.com/s/twitter/r/941/
Add --print-stacktrace-exception argument to pants invocations in ci.sh

When the build fails in ci, the stacktrace is suppressed by default. This change tacks on the --print-exception-stacktrace to each invocation of pants. (except for during the building of the distribution - it doesn't work then.)

Testing Done:
CI is running at https://travis-ci.org/pantsbuild/pants/builds/33585119

Bugs closed: 524

Reviewed at https://rbcommons.com/s/twitter/r/942/
Code for protolib-test artifact pulled in from external repository to demonstrate protobuf-gen 'imports' feature

Followon to https://rbcommons.com/s/twitter/r/592 and https://rbcommons.com/s/twitter/r/720/

Code for protolib-test artifact pulled in from external repository to demonstrate protobuf-gen 'imports' feature

We had this code internally before, now that we have testprojects/maven_layout, there is a good place to put it.

Testing Done:
I deployed the new 1.0.1 version of the protolib-test artifact to nexus.

Manually ran pants goal bundle  examples/src/java/com/pants/examples/protobuf:protobuf-imports-example  and it worked, confirmed the ivy cache now contains the new artifact.

CI passed.

Bugs closed: 521

Reviewed at https://rbcommons.com/s/twitter/r/936/