Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Method to set the input stream of a command #63

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

schischi
Copy link
Contributor

A lot of external programs are using stdin to pass data to the program
Expose a function setInput() to specify a custom string that is gonna be written to the process's standard input.
Test plan: added a new test and used the feature in one of my custom plugin.

A lot of external programs are using stdin to pass data to the program
Expose a function `setInput()` to specify a custom string that is gonna be written to the process's standard input.
Test plan: added a new test and used the feature in one of my custom plugin.
@google-cla google-cla bot added the cla: yes label Aug 11, 2020
@@ -83,4 +83,16 @@ public void getError_withMultipleGetOutputCalls_returnsExpect()
assertThat(executor.getError()).isEqualTo("1\n");
assertThat(executor.getError()).isEqualTo("1\n");
}

@Test
public void execute_writesInputIfSet()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use the format functionUnderTest_condition_expectedResult
e.g. something like execute_whenInputIsSet_writesInputToCommand

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants