Beispiel #1
0
        public void GetTradeOrderByOrderIdExpected()
        {
            var oid = (string)this.TestContext.Properties["OrderId"];

            using (var client = new BitsoClient(this.TestingServerUrl, this.ApiKey, this.ApiSecret))
            {
                try
                {
                    var res = client.GetTradeOrderByOrderId(oid);

                    Assert.IsNotNull(res);
                    Assert.AreNotEqual <int>(0, res.Count);
                    Assert.AreNotEqual <decimal>(0M, res[0].Price);

                    var diff = res[0].CreatedAt - default(System.DateTime);
                    Assert.IsTrue(diff > System.TimeSpan.Zero);
                }
                catch (BitsoException ex)
                {
                    this.TestContext.WriteLine(ex.Header);
                    throw;
                }
            }
        }