package com.example.javamavenjunithelloworld;
import org.junit.Test;
import java.io.ByteArrayOutputStream;
import java.io.OutputStream;
import java.io.PrintStream;
import static org.hamcrest.CoreMatchers.*;
import static org.junit.Assert.*;
/* This is to test eclipse
 chekcins into Github
*/


public class HelloTest {

    @Test
    public void testSayHello() {
        OutputStream os = new ByteArrayOutputStream();
        PrintStream stream = new PrintStream(os, true);

        Hello hi = new Hello();
        hi.sayHello(stream);

        assertThat(os.toString(), is(equalTo(Hello.HELLO + "\r\n")));
    }

    @Test
    public void testSayHelloAFewTimes() {
        OutputStream os = new ByteArrayOutputStream();
        PrintStream stream = new PrintStream(os, true);

        Hello hi = new Hello();
        hi.setTimes(3);
        hi.sayHello(stream);

        // Does it say "Hello!" three times?
        String goal = Hello.HELLO + "\r\n" + Hello.HELLO + "\r\n" + Hello.HELLO + "\r\n";
        assertThat(os.toString(), is(equalTo(goal)));
    }

    @Test(expected = IllegalArgumentException.class)
    public void testIllegalArgumentForHello21() {
        Hello hi = new Hello();
        hi.setTimes(Hello.MAXIMUM_AMOUNT_OF_TIMES + 1);
    }

    @Test(expected = IllegalArgumentException.class)
    public void testIllegalArgumentForHelloNegative() {
        Hello hi = new Hello();
        hi.setTimes(-1);
    }
}

@@ -593,18 +593,16 @@
 LO + %22%5Cr
-%5Cn
 %22)));%0A  
@@ -932,34 +932,32 @@
 ello.HELLO + %22%5Cr
-%5Cn
 %22 + Hello.HELLO 
@@ -961,18 +961,16 @@
 LO + %22%5Cr
-%5Cn
 %22 + Hell
@@ -986,10 +986,8 @@
  %22%5Cr
-%5Cn
 %22;%0A 

Update HelloTest.java