Refresh TaskTree.Nodes when getting them

With the introduction of Change properties, Node attributes and their
subnodes may depend on the specific change properties they were created
for. In order to correct current over-caching behavior which results in
erroneous Node contents when more than one change is evaluated, refresh
a Node's attributes that may be dependent on that change anytime the
Node is returned by a parent Node. Throwing away subnodes from a Node
can be expensive since it results in all the Nodes' descendants also
being discarded. To reduce this cost, this change reuses subnodes with
the same key after a refresh.

Also enhance the test framework to have a test suite which evaluates a
second change's output to ensure that the output is updated
appropriately beyond the first change.

Despite much re-use, this change still results in an approximate 5x
performance degradation on our Gerrit 2.7 fork.

Change-Id: Ib598b4c3a8e4fdbef0f41027cb1e6c7be5abe0d8
2 files changed