public void ReceiptCreating_GetDateForReceipt_TodayDate() { //arrange List <string> linesOfText = new List <string>(); linesOfText.AddMany(fixture.Create <string>, 10); ReceiptMaking receiptCreating = new ReceiptMaking(ocr.Object, shopDetection.Object); //act //assert Assert.Equal(DateTime.Now.ToString("d"), receiptCreating.GetDateForReceipt(linesOfText).ToString()); }
public void ReceiptCreating_GetDateForReceipt_RandomDate() { //arrange var dateTime = fixture.Create <DateTime>(); List <string> linesOfText = new List <string> { dateTime.ToString() }; linesOfText.AddMany(fixture.Create <string>, 10); ReceiptMaking receiptCreating = new ReceiptMaking(ocr.Object, shopDetection.Object); //act //assert Assert.Equal(dateTime.ToString("d"), receiptCreating.GetDateForReceipt(linesOfText).ToString()); }