Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C# Unit Test Project (.NET Framework) Account Class needs to hold the debit,credit and transfer functions that the AccountTest class will call and test using

C# Unit Test Project (.NET Framework)

Account Class needs to hold the debit,credit and transfer functions that the AccountTest class will call and test using the [TestMethod] logic.

Write a class called Account.

This Account class represents a persons bank account for a bank. It should have a debit function that debits a given amount from the balance. If it will make the account go negative, it should throw an Insufficient funds Exception.

It should also have a credit function that adds a given amount to the balance. It should have a transfer function that takes an account and transfers a given amount to that account by calling the credit function.

Create an AccountTest class that tests the credit, debit and transfer functions.

There has to be two tests to test the functions(credit/debit).

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Concepts of Database Management

Authors: Philip J. Pratt, Joseph J. Adamski

7th edition

978-1111825911, 1111825912, 978-1133684374, 1133684378, 978-111182591

More Books

Students also viewed these Databases questions

Question

13. What is the purpose of block diagramming?

Answered: 1 week ago