public ResultSrv <BusinessDealerSrv> AddDealer() { try { var output = new ResultSrv <BusinessDealerSrv>(); var addDealerVo = AddDealerVo.ConcreteBuilder .SetServiceCallParameters(internalServiceCallVo) .SetDealerBizId(0) //.SetAllProductAllow(true) .Build(); DealingService.AddDealer(addDealerVo, response => Listener.GetResult(response, out output)); return(output); } catch (PodException podException) { Console.WriteLine( $"-- {podException.Code}-an error has occured : {Environment.NewLine}{podException.Message}"); throw; } catch (Exception exception) { Console.WriteLine(exception.Message); throw; } }
public void AddDealer_RequiredParameters() { var internalServiceCallVo = InternalServiceCallVo.ConcreteBuilder .SetToken("0469eba2ddf84cb49eff254fe353638d") .Build(); var output = new ResultSrv <BusinessDealerSrv>(); var addDealerVo = AddDealerVo.ConcreteBuilder .SetServiceCallParameters(internalServiceCallVo) .SetDealerBizId(13059) .Build(); DealingService.AddDealer(addDealerVo, response => Listener.GetResult(response, out output)); Assert.False(output.HasError); }