Integration tests: moves useful features of test_link's setup into a mixin class in common.
Integration tests: Rewrites test_build to use unittest framework.