New option to plsql-spec command to indicate when to capture the output #10
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The idea with this commit, is to provide a way to show the output when Thor runs the rspec command,
In this commit @rsim added the option to Capture the log, and there is no way to disable the option :(
8c76f47
The problem with :capture => true is that hide errors that are outside rspec, I ask about this option in the Google Group:
https://groups.google.com/forum/?fromgroups=#!topic/oracle-enhanced/SmkETvkc2i8
I added a new option "--capture" to "plsql-spec" in order to indicate when do you don't want to capture the errors:
If you don't provide the capture option, the default value is true (How it works today)
In this example I have an error in the test_spec.rb file, I'm requiring a non existing gem
Before my commit, this is the output
rake probar[ejemplo] executes internally the "plsql-spec" run command
It's very difficult to catch the error

After the commit, with plsql-spec run --capture=false this is the output
