diff options
| author | deshevoy <[email protected]> | 2022-02-10 16:46:57 +0300 | 
|---|---|---|
| committer | Daniil Cherednik <[email protected]> | 2022-02-10 16:46:57 +0300 | 
| commit | 28148f76dbfcc644d96427d41c92f36cbf2fdc6e (patch) | |
| tree | b83306b6e37edeea782e9eed673d89286c4fef35 /util/system/shellcommand_ut.cpp | |
| parent | e988f30484abe5fdeedcc7a5d3c226c01a21800c (diff) | |
Restoring authorship annotation for <[email protected]>. Commit 2 of 2.
Diffstat (limited to 'util/system/shellcommand_ut.cpp')
| -rw-r--r-- | util/system/shellcommand_ut.cpp | 38 | 
1 files changed, 19 insertions, 19 deletions
diff --git a/util/system/shellcommand_ut.cpp b/util/system/shellcommand_ut.cpp index ca0fa88ef5c..9d849279d23 100644 --- a/util/system/shellcommand_ut.cpp +++ b/util/system/shellcommand_ut.cpp @@ -11,7 +11,7 @@  #include <util/folder/dirut.h>  #include <util/random/random.h> -#include <util/stream/file.h>  +#include <util/stream/file.h>  #include <util/stream/str.h>  #include <util/stream/mem.h>  #include <util/string/strip.h> @@ -418,24 +418,24 @@ Y_UNIT_TEST_SUITE(TShellCommandTest) {          UNIT_ASSERT_VALUES_EQUAL(stream.Str(), input + NL);      } -    Y_UNIT_TEST(TestPipeInput) {  -        TShellCommandOptions options;  -        options.SetAsync(true);  -        options.PipeInput();  -  -        TShellCommand cmd(catCommand, options);  -        cmd.Run();  -  -        {  -            TFile file(cmd.GetInputHandle().Release());  -            TUnbufferedFileOutput fo(file);  -            fo << "hello" << Endl;  -        }  -  -        cmd.Wait();  -        UNIT_ASSERT_VALUES_EQUAL(cmd.GetOutput(), "hello" NL);  -        UNIT_ASSERT_VALUES_EQUAL(cmd.GetError().size(), 0u);  -    }  +    Y_UNIT_TEST(TestPipeInput) { +        TShellCommandOptions options; +        options.SetAsync(true); +        options.PipeInput(); + +        TShellCommand cmd(catCommand, options); +        cmd.Run(); + +        { +            TFile file(cmd.GetInputHandle().Release()); +            TUnbufferedFileOutput fo(file); +            fo << "hello" << Endl; +        } + +        cmd.Wait(); +        UNIT_ASSERT_VALUES_EQUAL(cmd.GetOutput(), "hello" NL); +        UNIT_ASSERT_VALUES_EQUAL(cmd.GetError().size(), 0u); +    }      Y_UNIT_TEST(TestPipeOutput) {          TShellCommandOptions options;          options.SetAsync(true);  | 
