コード例 #1
0
        public void CurrencyExchangeTest(decimal source, decimal rate, decimal result)
        {
            BaseController baseController = new BaseController();

            Assert.Equals(source * rate, baseController.CurrencyExchange(source, 1, rate));
        }
コード例 #2
0
        public void CurrencyExchangeTest(decimal source, decimal rate, decimal result)
        {
            BaseController baseController = new BaseController();

            Assert.LessOrEqual(Math.Abs(source * rate - baseController.CurrencyExchange(source, 1, rate)), 0.05);
        }