Banking.AU.tests.Westpac.QuickSuperFile_Fixture.Read_stream C# (CSharp) Method

Read_stream() private method

private Read_stream ( ) : void
return void
        public void Read_stream()
        {
            // Arrange
            var io = new ContributionFileIO();
            var stream = new MemoryStream();
            new StreamWriter(stream) { AutoFlush = true }.Write(
            @"YourFileReference,YourFileDate,ContributionPeriodStartDate,ContributionPeriodEndDate,EmployerID,PayrollID,NameTitle,FamilyName,GivenName,OtherGivenName,NameSuffix,DateOfBirth,Gender,TaxFileNumber,PhoneNumber,MobileNumber,EmailAddress,AddressLine1,AddressLine2,AddressLine3,AddressLine4,Suburb,State,PostCode,Country,EmploymentStartDate,EmploymentEndDate,EmploymentEndReason,FundID,FundName,FundEmployerID,MemberID,EmployerSuperGuaranteeAmount,EmployerAdditionalAmount,MemberSalarySacrificeAmount,MemberAdditionalAmount,OtherContributorType,OtherContributorName,YourContributionReference
            ,,08-Jul-15,06-Sep-15,,,,Citizen,John,,,07-Aug-85,,,,,,,,,,,,,,,,,ABC123,,,,,,,,,,");
            stream.Position = 0;
            var reader = new StreamReader(stream);

            // Act
            var file = io.Read(reader);

            // Assert
            Assert.AreEqual(1, file.Records.Count);
            stream.Dispose();
        }