aboutsummaryrefslogtreecommitdiff
path: root/Codeforces.Test/Tests.cs
blob: 38061d2dc914ca61f940a309010ebe9deef3e9d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
namespace Codeforces.Test;

public class Tests
{
	[Fact]
	public void TestIO()
	{
		IOTester.Start();
		
		string[] input = new string[]
		{
			"5",
			"256 42",
			"1000 1000",
			"-1000 1000",
			"-1000 1000",
			"20 22"
		};		
		IOTester.SetInput(input);

		Program.Main(new string[0]);

		string[] output = new string[]		
		{
			"298",
			"2000",
			"0",
			"0",
			"42"
		};
		
		string[] actualOutput = IOTester.GetOutputLines();
		Assert.Equal(output.Length, actualOutput.Length);
		for (int i = 0; i< output.Length; i++)		
		{
			Assert.Equal(output[i], actualOutput[i]);			
		}
	}
}