acceptance/testall: support for inotifywait and inotifywatch
acceptance/testall: ensure $BASE_WORKDIR exists before executing inotify
Initialisation fix: cope with unrecognised binary operator.

If EvalClassExpression() got a Constraint whose ->lval wasn't one of
the known operations, it would have fallen through to the and/or/xor
and used an uninitialized value for logic, with potentially random
results.  If we were *lucky* it'd use an invalid value for it and
(after wasting a lot of time running round a loop computing values it
would subsequently not use) return false, like it should; but only if
we were lucky.
Break up EvalClassExpression() and fix some infelicities.

It was getting a bit long; and there were some minor glitches.
Also moved ValidClassName from bottom to top of the file.
Pass correct buffer size to snprintf().
Skip needless casts from void*.
Make variables more local.

The check for "anything after this wants a list" was after the
handling of select_class - which wants a list - so swapped their
order.  Broke out class selection, both deterministic and random,
into functions of their own - and made each a bit more robust.

The warning fix in the last commit could be better fixed by moving the
bool-combination code into a separate function; where it could be
simplified a bit, too.  Downside: the previously local enum is now at
file scope.
Improved Log()ging and fixed a leak in evalfunction's JSON wrappers.

Successful parse yielding a non-container was conflated with failed
parsing; separate the two.  In the process, fix the leak of the json
object when it's not a container; and report *what* failed when we
didn't even get that.  Use JsonParseFile() in the one place that we're
just duplicating it's workings.
Eliminate pointless intermediary in JsonParseFile()

We're going to write to the pointer we were passed in any case, so we
may as well pass that into the parser for it to write to, instead of
having our own local variable to passdown and then copy to the pointer
we received.
redmine6549: Tolerate unrecognised escape sequences.

We have no way to represent \u{hex digit} escapes for Unicode, which
are perfectly valid JSON; so we need to tolerate these in some form
rather than choking on them.  Given that the only sane way to do so is
to preserve them verbatim, we may as well do the same for any other
unrecognised escapes.  This eliminates the need for an error code to
represent unrecognised escape.

Log() a warning when handling an escape verbatim, though; which, in
turn, requires a #include <logging.h>
Add acceptance test for unicode escapes in JSON.
Switch to egrep. "grep -E" is not portable to Solaris grep.
Update test result status for Solaris 11.
Remove outdated test suppression for Windows.
Soft fail test in Solaris 11 chroot env, where it cannot pass.
Merge pull request #1997 from ediosyncratic/class-expr-cleanup

Class expression cleanup
Merge pull request #1995 from ediosyncratic/json-parsing-fix

RedMine 6549: deal with some problems with parsing JSON
Merge branch 'core/testall-inotify-support' of https://github.com/cdituri/core

Conflicts:
	tests/acceptance/testall
Test case for Redmine 6369

Shows that array data accumluates over multiple bundle
invocations.
Clear array data before calling bundle as method

This re-establishes the behavior from 3.5.3, where array
data within a sub-bundle does not accumulate accross
multiple bundle invokations via methods promises.

It maintains the behavior where such data does accumulate
accross multiple bundle invokations via bundlesequence.

One could argue that the behavior or data accumulating would
be consistent with the declarative nature of CFEngine, but
given that CFEngine provides no means to clear an array in a
controlled way, this would require a uniquely named array for
each bundle invocation, which would be unmaintainable and render
methods promises and bundles useless as a means for abstraction.

Fixes Redmine #6369, see ticket for more detailed discussion.
Disable caching for functions that populate array

The function populates an array, so skipping the function call
is not an option, as the cached return value is not sufficient.

A second call of the same method (2nd pass) would first clear
the array and then skip the function call, leaving an empty
array.