Ejemplo n.º 1
0
 public CfBroadcastScheduleQueryResult QueryBroadcastSchedule(CfQueryBroadcastData queryBroadcastData)
 {
     return
         (BroadcastScheduleQueryResultMapper.FromSoapBroadcastScheduleQueryResult(
              BroadcastService.QueryBroadcastSchedule(
                  new QueryBroadcastSchedules(queryBroadcastData))));
 }
        public void FixtureSetup()
        {
            HttpClientMock = MockRepository.GenerateMock <IHttpClient>();
            Client         = new RestBroadcastClient(HttpClientMock);

            BroadcastId            = 1;
            QueryBroadcastSchedule = new CfQueryBroadcastData(100, 1, BroadcastId);

            CfDaysOfWeek[] daysOfWeek = { CfDaysOfWeek.Monday };
            BroadcastSchedule = new CfBroadcastSchedule(1, DateTime.Now, DateTime.Now, "timeZone", DateTime.Now, DateTime.Now, daysOfWeek);
            var broadcastSchedule = new CfBroadcastSchedule[1];

            broadcastSchedule[0]         = BroadcastSchedule;
            BroadcastScheduleQueryResult = new CfBroadcastScheduleQueryResult(1, broadcastSchedule);

            var broadcastScheduleQueryResult = BroadcastScheduleQueryResultMapper.ToSoapBroadcastScheduleQueryResult(BroadcastScheduleQueryResult);

            GenerateMock(broadcastScheduleQueryResult);
        }
Ejemplo n.º 3
0
        public void FixtureSetup()
        {
            BroadcastServiceMock = MockRepository.GenerateStub <IBroadcastServicePortTypeClient>();
            Client = new SoapBroadcastClient(BroadcastServiceMock);

            BroadcastId            = 1;
            QueryBroadcastSchedule = new CfQueryBroadcastData(100, 1, BroadcastId);

            CfDaysOfWeek[] daysOfWeek = { CfDaysOfWeek.Monday };
            BroadcastSchedule = new CfBroadcastSchedule(1, DateTime.Now, DateTime.Now, "timeZone", DateTime.Now, DateTime.Now, daysOfWeek);
            var broadcastSchedule = new CfBroadcastSchedule[1];

            broadcastSchedule[0]         = BroadcastSchedule;
            BroadcastScheduleQueryResult = new CfBroadcastScheduleQueryResult(1, broadcastSchedule);

            var broadcastScheduleQueryResult = BroadcastScheduleQueryResultMapper.ToSoapBroadcastScheduleQueryResult(BroadcastScheduleQueryResult);

            GenerateMock(BroadcastId, broadcastScheduleQueryResult);

            BroadcastId = 2;
            BroadcastScheduleQueryResult.BroadcastSchedule = null;
            broadcastScheduleQueryResult = BroadcastScheduleQueryResultMapper.ToSoapBroadcastScheduleQueryResult(BroadcastScheduleQueryResult);
            GenerateMock(BroadcastId, broadcastScheduleQueryResult);
        }