Пример #1
0
        /// <summary>
        /// Returns DUT's media service address
        /// </summary>
        /// <returns>Replay service url</returns>
        protected string GetReplayServiceAddress()
        {
            string address = string.Empty;

            RunStep(() =>
            {
                Binding binding =
                    CreateBinding(false,
                                  new IChannelController[] { new SoapValidator(DeviceManagementSchemasSet.GetInstance()) });

                DeviceClient device = new DeviceClient(binding, new EndpointAddress(_cameraAddress));

                AttachSecurity(device.Endpoint);
                SetupChannel(device.InnerChannel);

                address = device.GetReplayServiceAddress(Features);

                device.Close();

                if (string.IsNullOrEmpty(address))
                {
                    throw new AssertException("The DUT did not return Replay service address");
                }
            }, "Get Replay Service address");
            DoRequestDelay();
            return(address);
        }
Пример #2
0
        protected override string GetServiceAddress()
        {
            string address = string.Empty;

            RunStep(() =>
            {
                DeviceClient device = DeviceClient;

                address = device.GetReplayServiceAddress(Features);

                if (string.IsNullOrEmpty(address))
                {
                    throw new AssertException("The DUT did not return Replay service address");
                }
            }, "Get Replay Service address");
            DoRequestDelay();
            return(address);
        }