pkgs/build-support/cabal: add support for running specific tests only via 'testTarget'

The dns packages requires this feature, because it ships two test programs: one
of them requires network access (so we cannot run it), but the other test does
not. Setting testTarget appropriately allows us to run only one of the two
suites.
haskell-dns: run only the 'spec' test suite, the 'network' test suite won't succeed on Hydra