Github user aledsage commented on the issue:
https://github.com/apache/brooklyn-server/pull/589
Thanks @neykov and @geomacy - interesting!
I'm now not sure what is intuitive to a user!
---
FYI, my specific use-case is to write a yaml-test using `TestSshCommand`
that checks for the presence of particular lines in a log file. The command I
execute will grep the log, and then I want to assert that a couple of lines are
present in the stdout (I use a a regex to try to match the pattern on each
line).
I also had in the back of my mind someone using `TestSshCommand` to execute
a command and assert the stdout, but because of the `.bashrc` or whatever they
get extra stdout lines that they weren't expecting.
However, a power-user might well have a more complex regex, where they are
trying to match across multi-line output. If we start messing with the defaults
of DOTALL then it might well surprise them.
---
Looking at
http://stackoverflow.com/questions/3651725/match-multiline-text-using-regular-expression/3652402#3652402,
I wonder if what I want (for my use-case at least) is something like
`containsMatch: foo.*bar`. This would call `matcher.find()`.
@geomacy @neykov what do you think - shall I drop these changes and instead
add support for `containsMatch: ...`?
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---