Beispiel #1
0
        public void CcyRef()
        {
            Account acc_ccy   = Init.CreateAccountCurrency1();
            bool    test1     = acc_ccy.CcyRef.Equals(Init.Ccy1());
            Account acc_asset = Init.CreateAccountAsset1();
            bool    test2     = acc_asset.CcyRef.Equals(Init.Asset1());

            Assert.IsTrue(test1 && test2);
        }
Beispiel #2
0
        public void GetSummary_AssetTest()
        {
            Account       acc  = Init.CreateAccountAsset1();
            SummaryReport summ = acc.GetSummary();

            Assert.IsTrue(
                summ.Count == 1 &&
                summ.Get(Init.Asset1()) == acc.Amount
                );
        }
Beispiel #3
0
        public void ModifyTotalCcy_AssetTest()
        {
            Account     acc   = Init.CreateAccountAsset1();
            FXMarket    fxMkt = Init.CreateFXMarket();
            AssetMarket aMkt  = Init.CreateAssetMarket(fxMkt);

            acc.ModifyTotalCcy(fxMkt, aMkt, fxMkt.CcyRef);
            Assert.IsTrue(
                acc.TotalCcy == fxMkt.CcyRef &&
                acc.TotalAmount == acc.Amount * aMkt.GetQuote(new AssetCcyPair(Init.Asset1(), Init.Ccy2()))
                );
        }