Testing | Figure out why shellspec Ignores all but First Line of function doc #58
Labels
enhancement
New feature or request
good first issue
Good for newcomers
help wanted
Extra attention is needed
Description
When a function that's being tested by shellspec returns it's doc, shellspec only sees the first line of the doc. This is the case regardless of what shell the test is run in. When one manually does the same thing the test does, the entire doc is returned. The command that's used to save the doc in a variable, the variable that's printed to std, is
cat
. shellspec is set to pass through cat commands so it's not that. The same behavior occurs regardless of if the CUT returns the doc withecho
orprintf
.High Level Solution Description
Determine how to fix this, either by contributing to the shellspec project, updating CUT, changing how the tests are run, or some other work around I haven't thought of. It's not nessirary to impliment the fix that's found, however, it does seem like a good idea to implement the fix in one place. That way it can be verified that the fix works both locally and in the pipeline.
Alternative Solution(s)
None.
Blocked By
Blocking
Related Issue(s)
checkRequiredOpts()
and Any Util Code #40Additional Context
At time of writing, there is at least one test that this affects. It's marked with this issue's ID, so finding it, and all others, should be easy.
The text was updated successfully, but these errors were encountered: