public void SetValuesToSaleItem_ShouldSetObjectProperty_Name_Correctly(string _code, string _name, decimal _quantity, string _unitOfMeasure, decimal _netPrice, int _vatTaxValue, decimal _grossPrice, string expected) { SaleItemProcessor saleItemProcessor = new SaleItemProcessor(); ISaleItem item = saleItemProcessor.SetValuesToSaleItem(_code, _name, _quantity, _unitOfMeasure, _netPrice, _vatTaxValue, _grossPrice); Assert.EndsWith(item.Name, expected); }
public void SetValuesToSaleItem_ShouldReturnNullCauseOfEmptyInputData(string _code, string _name, decimal _quantity, string _unitOfMeasure, decimal _netPrice, int _vatTaxValue, decimal _grossPrice) { SaleItemProcessor saleItemProcessor = new SaleItemProcessor(); ISaleItem item = saleItemProcessor.SetValuesToSaleItem(_code, _name, _quantity, _unitOfMeasure, _netPrice, _vatTaxValue, _grossPrice); Assert.Null(item); }
public void SetValuesToSaleItem_ShouldCreateObject(string _code, string _name, decimal _quantity, string _unitOfMeasure, decimal _netPrice, int _vatTaxValue, decimal _grossPrice) { SaleItemProcessor saleItemProcessor = new SaleItemProcessor(); var actual = saleItemProcessor.SetValuesToSaleItem(_code, _name, _quantity, _unitOfMeasure, _netPrice, _vatTaxValue, _grossPrice); Assert.NotNull(actual); }