Esempio n. 1
0
        public void ValidateFundOfMandatesReturnsPositionVM()
        {
            IFundProcessor        fundsProcessor = new FundProcessor();
            string                filePath       = "..\\..\\..\\TestData\\FundsOfMandatesData.xml";
            List <FundOfMandates> Result         = fundsProcessor.ReadFundOfMandateFile(filePath);
            PortfolioVM           portfolioVM    = fundsProcessor.GetPortfolio();
            PositionVM            positionVM     = null;

            positionVM = fundsProcessor.GetCalculatedMandates(portfolioVM.Positions.ElementAt(1), Result.ElementAt(1));

            positionVM.Should().NotBeNull().And.BeOfType <PositionVM>();
        }
Esempio n. 2
0
        public void ReadAndValidateXMLFile()
        {
            IFundProcessor fundProcessor = new FundProcessor();
            string         filePath      = "..\\..\\..\\TestData\\FundsOfMandatesData.xml";

            var FundOfMandateFile = fundProcessor.ReadFundOfMandateFile(filePath);

            Assert.IsNotNull(FundOfMandateFile);
            Assert.IsInstanceOfType(FundOfMandateFile, typeof(List <FundOfMandates>));

            FundOfMandateFile.Should().NotBeNull();
            FundOfMandateFile.Should().BeAssignableTo(typeof(List <FundOfMandates>));
        }