-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feat: Added and Updated Accounts #339
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesn't seem like you're grasping the difference between abstract classes and interfaces. I'll schedule some time to help troubleshoot where the misunderstanding might be.
* | ||
* @author vscode | ||
*/ | ||
public class BankAccountBase { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This base class should implement the BankAccount
interface.
import com.codedifferently.lesson13.bank.exceptions.AccountNotFoundException; | ||
import com.codedifferently.lesson13.bank.BankAccount; | ||
|
||
public class BusinessCheckingAccount extends Customer { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would expect this to extend BankAccountBase
or CheckingAccount
. A banking account is not a customer.
|
||
/** Represents a checking account. */ | ||
public class BankAccountBase implements BankAccount { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure what happened here.
@@ -23,8 +23,8 @@ void setUp() { | |||
classUnderTest = new BankAtm(); | |||
customer1 = new Customer(UUID.randomUUID(), "John Doe"); | |||
customer2 = new Customer(UUID.randomUUID(), "Jane Smith"); | |||
account1 = new CheckingAccount("123456789", Set.of(customer1), 100.0); | |||
account2 = new CheckingAccount("987654321", Set.of(customer1, customer2), 200.0); | |||
account1 = new BankAccount("123456789", Set.of(customer1), 100.0); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can't create an instance of an interface.
No description provided.