コード例 #1
0
        public void Setup()
        {
            _supplier = Substitute.For <IPerson>();
            _supplier.IsVatPayer.Returns(true);
            _supplier.Country.Returns("Lithuania");

            _customer = Substitute.For <IPerson>();

            _eUCountryRequester = Substitute.For <IEUCountryRequester>();
            _eUCountryChecker   = Substitute.For <IEUCountryChecker>();
            _vATReuester        = Substitute.For <IVATRequester>();
            _invoiceGenerator   = new InvoiceGenerator(_vATReuester, _eUCountryChecker);
        }
コード例 #2
0
 public InvoiceGenerator(IVATRequester vATRequester, IEUCountryChecker eUCountryChecker)
 {
     _vATRequester     = vATRequester ?? throw new ArgumentNullException(nameof(vATRequester));
     _eUCountryChecker = eUCountryChecker ?? throw new ArgumentNullException(nameof(eUCountryChecker));
 }
コード例 #3
0
 public void Setup()
 {
     _requestAgent = Substitute.For <IRequsetRestAgent>();
     _vATRequester = new VATRequester(_requestAgent);
 }