使用VisualStudio2005TeamSystem進行單元測試[6]

發表于:2010-05-12來源:作者:點擊數: 標簽:單元
使用VisualStudio2005TeamSystem進行 單元測試 [6] 軟件測試 public void Initialize() { } [TestCleanup()] public void Cleanup() { } [TestMethod()] public void ConstructorTest() { float currentBalance = 500; BankAccount target = new BankAccount

  使用VisualStudio2005TeamSystem進行單元測試[6]   軟件測試

  public void Initialize() {

  }

  [TestCleanup()]

  public void Cleanup() {

  }

  [TestMethod()]

  public void ConstructorTest() {

  float currentBalance = 500;

  BankAclearcase/" target="_blank" >ccount target = new BankAccount(currentBalance);

  Assert.AreEqual(currentBalance, target.CurrentBalance,

  "Balances are not equal upon creation");

  }

  [TestMethod()]

  public void DepositMoneyTest() {

  float currentBalance = 500;

  BankAccount target = new BankAccount(currentBalance);

  float depositAmount = 10;

  target.DepositMoney(depositAmount);

原文轉自:http://www.anti-gravitydesign.com

国产97人人超碰caoprom_尤物国产在线一区手机播放_精品国产一区二区三_色天使久久综合给合久久97