Skip to content
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

Add unit tests #837

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open

Conversation

hlibmurphy
Copy link

Added untreated unit tests.
Going to correct the code soon.

Copy link

@Rommelua Rommelua left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Java Cl checks failed. Before making a Pull Request (or a new commit to an already existing PR), you need to write the mvn clean package command in the terminal and make sure that all checks pass. After that, the mentor will be able to review the homework

image

@hlibmurphy hlibmurphy requested a review from Rommelua November 7, 2023 11:13
Copy link

@olekskov olekskov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Build is still failing due some tests

@hlibmurphy hlibmurphy requested a review from olekskov November 7, 2023 18:28
Copy link

@Rommelua Rommelua left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Before you create PR with your homework, you need to go through the checklist under the task and correct all the points described there. The mentor will not check the work until the checklist points are corrected

image

import org.junit.jupiter.api.TestInstance;

@TestInstance(TestInstance.Lifecycle.PER_CLASS)
public class FruitTransactionTest {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add OK-test

@TestInstance(TestInstance.Lifecycle.PER_CLASS)
public class FruitTransactionTest {
@Test
void fruitTransactionWithNegativeAmount_NotOk() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
void fruitTransactionWithNegativeAmount_NotOk() {
void of_NegativeAmount_NotOk() {

image

@hlibmurphy hlibmurphy requested a review from Rommelua November 9, 2023 14:12
Copy link

@olekskov olekskov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job overall, approved

For future: files required for testing should be in resources folder of test package, not in project root folder

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants