-
Notifications
You must be signed in to change notification settings - Fork 1k
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
created first version fruit-shop-tests, there is a problem with coverage #797
base: main
Are you sure you want to change the base?
created first version fruit-shop-tests, there is a problem with coverage #797
Conversation
void createReport_createdCorrectReport_Ok() { | ||
Storage.STORAGE.put("banana", 152); | ||
Storage.STORAGE.put("apple", 90); | ||
String expected = "fruit,quantity" + System.lineSeparator() |
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.
let's use StrinhBuilder
} | ||
|
||
@Test | ||
void processing_successProcessedSupllyOperation_Ok() { |
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.
in this case, you don't need to test in this style. I think that one test with different types of operations is enough for you and expect that no error occurs
@Test | ||
void writeToFile_correctWrittenReport_Ok() { | ||
String pathToFile = "src/main/resources/report.csv"; | ||
String expected = "fruit,quantity" + System.lineSeparator() |
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.
let's use StringBuilder. Same in other cases
No description provided.