Example #1
0
        public void Verify_SqlStudent1098_TReportTestService_GetStudent1098_TReportTestReport_Returns_Data_Against_InValid_DbStudent()
        {
            IGetStudent1098TReportService student1098_TReport = new GetStudent1098TReportService();
            var student1098_T = student1098_TReport.GetStudent1098TPDF(TestConstants.InvalidUserId);

            Assert.IsNull(student1098_T.PdfData);
        }
Example #2
0
        public ActionResult Student1098TPDF()
        {
            try
            {
                IGetStudent1098TReportService reportService = new GetStudent1098TReportService();
                var    student1098TPdf = reportService.GetStudent1098TPDF(StudentNo);
                byte[] pdf             = student1098TPdf.PdfData;
                if (pdf != null)
                {
                    return(File(pdf, "application/pdf", "1098-T.pdf"));
                }
                else
                {
                    return(View("Student1098TPdf"));
                }
            }
            catch (Exception ex)
            {
                _logger.Error("Exception Occurred. StudentNo: " + StudentNo, ex);

                Response.Redirect(AppHelper.SharedUrl("Reply/Error"));

                return(null);
            }
        }
Example #3
0
        public void Verify_Student1098_TReportService_TestStudent1098_TReportRepository_GetStudent1098_TReportReport_Returns_Data_Against_TestStudent()
        {
            IGetStudent1098TReportService student1098_TReport = new GetStudent1098TReportService(new TestStudent1098TReportRepository());
            var student1098_T = student1098_TReport.GetStudent1098TPDF(TestConstants.DbStudentUserId);

            Assert.IsNotNull(student1098_T);
            Assert.IsNotNull(student1098_T.PdfData);
            Assert.IsNotNull(student1098_T.StudentNo);
        }