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

"Not enough comments" #607 patch #608

Closed
wants to merge 7 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions src/test/java/FizzBuzzTest.java
Original file line number Diff line number Diff line change
@@ -1,33 +1,52 @@
// FizzBuzzTest.java
// Tests for FizzBuzz

// imports org.junit.Assert.assertEquals
import static org.junit.Assert.assertEquals;

// imports java.io.BufferedOutputStream
import java.io.BufferedOutputStream;
// imports java.io.ByteArrayOutputStream
import java.io.ByteArrayOutputStream;
// imports java.io.IOException
import java.io.IOException;
// imports java.io.PrintStream
import java.io.PrintStream;

// imports org.junit.After
import org.junit.After;
// imports org.junit.Before
import org.junit.Before;
// imports org.junit.Test
import org.junit.Test;
// imports org.springframework.context.ApplicationContext
import org.springframework.context.ApplicationContext;
// imports org.springframework.context.ConfigurableApplicationContext
import org.springframework.context.ConfigurableApplicationContext;
// imports org.springframework.context.support.ClassPathXmlApplicationContext
import org.springframework.context.support.ClassPathXmlApplicationContext;

// imports com.seriouscompany.business.java.fizzbuzz.packagenamingpackage.interfaces.FizzBuzz
import com.seriouscompany.business.java.fizzbuzz.packagenamingpackage.interfaces.FizzBuzz;

/**
* Tests for FizzBuzz
*/
public class FizzBuzzTest {

// create a PrintStream called `out`
private PrintStream out;
// create a FizBuzz objecct called `fb`

Choose a reason for hiding this comment

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

I notice that you mis-spelled "object" in this comment. Not sure if it's critical to fix now but might be worth adding a comment or a TODO for the next developer.

Otherwise LGTM

Choose a reason for hiding this comment

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

"FizBuzz" was also misspelled by the way, this might cause some grammar & language checking tools to fail the status checks, so it's best to patch this ASAP

Copy link

@louwers louwers May 16, 2023

Choose a reason for hiding this comment

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

Can we create a GitHub issue for this and link it to a ticket on Jira so we can put it on our Sprint board?

Choose a reason for hiding this comment

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

We already patched this last sprint. I remember because we talked about if it should be capitalized or not in several of the standups. I have been looking for the jira ticket for the last half hour, but I can't find it... but I think I remember "object" being misspelt as "objct" last time and the issue was already supposedly corrected based on the jira being closed. But I can't seem to find where it got updated. Let me look through all my old Jira tickets to find it... Could it be possible the dev didn't commit it up or something along those lines? I recommend we have a meeting to figure out what happened to it. Someone create an invite for the whole team please.

private FizzBuzz fb;

/**
* @return void
*/
@Before
public void setUp() {
// create a constant for the ApplicationContext called `context` that uses test constant `SPRING_XML` from TestConstants
final ApplicationContext context = new ClassPathXmlApplicationContext(TestConstants.SPRING_XML);
// ...
this.fb = (FizzBuzz) context.getBean(TestConstants.STANDARD_FIZZ_BUZZ);
this.out = System.out;
((ConfigurableApplicationContext) context).close();
Expand Down