Adds several unittests for addrman to verify it works as expected. Makes small modifications to addrman to allow deterministic and targeted tests. Signed-off-by: Simon <simon@bitcartel.com>