public void TestPostAndSaveAfterwards() { string TestFile = CommonNUnitFunctions.rootPath + "/csharp/ICT/Testing/lib/MFinance/GiftForm/TestData/BatchImportTest.csv"; TFrmGiftBatch frmBatch = new TFrmGiftBatch(null); frmBatch.LedgerNumber = FLedgerNumber; frmBatch.Show(); ImportGiftBatch(TestFile); TabControlTester tabGiftBatch = new TabControlTester("tabGiftBatch"); tabGiftBatch.SelectTab(1); TextBoxTester txtDetailGiftTransactionAmount = new TextBoxTester("txtDetailGiftTransactionAmount"); Assert.AreEqual(Convert.ToDecimal(txtDetailGiftTransactionAmount.Properties.Text), 10000000000M); frmBatch.Close(); }
public void TestImportExportGiftBatch() { // create two test batches, with some strange figures, to test problem with double values // TODO export the 2 test batches, with summarize option // TODO compare the exported text file string TestFile = CommonNUnitFunctions.rootPath + "/csharp/ICT/Testing/lib/MFinance/GiftForm/TestData/BatchImportTest.csv"; TFrmGiftBatch frmBatch = new TFrmGiftBatch(null); frmBatch.LedgerNumber = FLedgerNumber; frmBatch.Show(); ImportGiftBatch(TestFile); TabControlTester tabGiftBatch = new TabControlTester("tabGiftBatch"); tabGiftBatch.SelectTab(1); TextBoxTester txtDetailGiftTransactionAmount = new TextBoxTester("txtDetailGiftTransactionAmount"); Assert.AreEqual(Convert.ToDecimal(txtDetailGiftTransactionAmount.Properties.Text), 10000000000M); frmBatch.Close(); }