package ru.job4j;

import org.junit.Test;
import java.io.ByteArrayOutputStream;
import java.io.PrintStream;
import static org.hamcrest.core.Is.is;
import static org.junit.Assert.assertThat;

/**
* Test.
* 
* @author Kucyh Vasily
* @version $Id$
* @since 0.1
*/
public class CalculateTest {

	/**
	* Test add.
	*/
	@Test
	public void whenAddOneToOneThenTwo() {

		ByteArrayOutputStream out = new ByteArrayOutputStream();
		
		System.setOut(new PrintStream(out));

		Calculate.main(null);

		assertThat(
			out.toString(), 
			is(
				String.format("Hello world%s", 
				System.getProperty("line.separator")
				)
			)
		);

	}

}

@@ -197,17 +197,16 @@
  Test.%0A*
- 
 %0A* @auth
@@ -220,16 +220,42 @@
 h Vasily
+ (mailto:basil135@mail.ru)
 %0A* @vers
@@ -438,18 +438,16 @@
 ream();%0A
-%09%09
 %0A%09%09Syste
@@ -536,17 +536,16 @@
 tring(),
- 
 %0A%09%09%09is(%0A
@@ -578,17 +578,16 @@
 orld%25s%22,
- 
 %0A%09%09%09%09Sys

Refactor CalculateTest.java