Refactor Dmark and ImiMobile tests to share common HTTP RPC test helper.