[build] Implement missing dependncy tracking
[build] Only include defaults for tests when testing
[build] Allow overriding comm layer in tests