2023-08-09 09:42:50 +03:00
|
|
|
namespace Codeforces.Test;
|
|
|
|
|
|
|
|
public class Tests
|
|
|
|
{
|
|
|
|
[Fact]
|
|
|
|
public void TestIO()
|
|
|
|
{
|
|
|
|
IOTester.Start();
|
2023-08-09 17:06:42 +03:00
|
|
|
var lines = File.ReadLines(@"..\..\..\input.txt");
|
|
|
|
IOTester.SetInput(lines.ToArray());
|
2023-08-09 09:42:50 +03:00
|
|
|
|
2023-08-09 15:12:39 +03:00
|
|
|
Program.Main();
|
2023-08-09 09:42:50 +03:00
|
|
|
|
2023-08-09 17:06:42 +03:00
|
|
|
string[] expectedOutput = File.ReadLines(@"..\..\..\output.txt").ToArray();
|
2023-08-09 09:42:50 +03:00
|
|
|
string[] actualOutput = IOTester.GetOutputLines();
|
2023-08-09 17:06:42 +03:00
|
|
|
Assert.Equal(expectedOutput.Length, actualOutput.Length);
|
|
|
|
for (int i = 0; i < expectedOutput.Length; i++)
|
2023-08-09 09:42:50 +03:00
|
|
|
{
|
2023-08-09 17:06:42 +03:00
|
|
|
Assert.Equal(expectedOutput[i], actualOutput[i]);
|
2023-08-09 09:42:50 +03:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|