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

Parsing string args correctly #59

Merged
merged 2 commits into from
Feb 20, 2016
Merged

Parsing string args correctly #59

merged 2 commits into from
Feb 20, 2016

Conversation

zabawaba99
Copy link
Collaborator

There was a bug in the code that cause commands that had quotes in them to not work as expected.
Commands are no longer split just on a whitespace. If an opening quote is found the split function
finds its ending quote and returns the entire chunk as one argument.

There was a bug in the code that cause commands that had quotes in them to not work as expected.
Commands are no longer split just on a whitespace. If an opening quote is found the split function
finds its ending quote and returns the entire chunk as one argument.
@@ -33,6 +33,35 @@ func TestNewBuilder(t *testing.T) {
assert.Equal(t, c.IgnoredItems, b.ignoredItems)
}

func TestNewBuilder_CmdWithQuotes(t *testing.T) {
c := config{
Build: []string{
Copy link
Owner

Choose a reason for hiding this comment

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

Just to cover our cases, can we add the same cases for the Runners

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Will do. I'll make this a table test to make it easier to add some cases

Tonkpils added a commit that referenced this pull request Feb 20, 2016
Parsing string args correctly
@Tonkpils Tonkpils merged commit 1a22c1d into master Feb 20, 2016
@Tonkpils Tonkpils deleted the string-parsing branch February 20, 2016 18:27
@Tonkpils
Copy link
Owner

👍

Tonkpils added a commit that referenced this pull request Feb 20, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants