Ejemplo n.º 1
0
        /// <summary>
        /// The open.
        /// </summary>
        /// <param name="activity">
        /// The activity.
        /// </param>
        /// <param name="baseAddress">
        /// The base address.
        /// </param>
        /// <param name="timeout">
        /// The timeout.
        /// </param>
        /// <returns>
        /// An HttpWorkflowServiceTestHost
        /// </returns>
        public static HttpWorkflowServiceTestHost Open(
            Activity activity, Uri baseAddress, TimeSpan timeout)
        {
            var testhost =
                new HttpWorkflowServiceTestHost(
                    new HttpWorkflowServiceHost(activity, new[] { baseAddress }));

            testhost.ServiceHost.Open();
            testhost.TestTimeout = timeout;
            testhost.ServiceHost.WorkflowTimeout = timeout;
            return(testhost);
        }
 /// <summary>
 /// The open.
 /// </summary>
 /// <param name="activity">
 /// The activity.
 /// </param>
 /// <param name="baseAddress">
 /// The base address.
 /// </param>
 /// <param name="timeout">
 /// The timeout.
 /// </param>
 /// <returns>
 /// An HttpWorkflowServiceTestHost
 /// </returns>
 public static HttpWorkflowServiceTestHost Open(
     Activity activity, Uri baseAddress, TimeSpan timeout)
 {
     var testhost =
         new HttpWorkflowServiceTestHost(
             new HttpWorkflowServiceHost(activity, new[] { baseAddress }));
     testhost.ServiceHost.Open();
     testhost.TestTimeout = timeout;
     testhost.ServiceHost.WorkflowTimeout = timeout;
     return testhost;
 }