Mercurial > public > mercurial-scm > hg-stable
diff tests/test-context.py.out @ 23709:33e5431684c0
context: make unknown/ignored/clean of cached status empty for equivalence
Before this patch, "workingctx.status" caches the result of
"dirstate.status" directly into "self._status".
But "dirstate.status" is invoked with False "list*" arguments in
normal "self._status" accessing route, and this makes
"unknown"/"ignored"/"clean" of status empty.
This may cause unexpected result of code paths internally accessing to
them (accessors for external usage are already removed by previous patch).
This patch makes "unknown"/"ignored"/"clean" of cached status empty
for equivalence. Making them empty is executed only when at least one
of "unknown", "ignored" or "clean" has files, for efficiency.
author | FUJIWARA Katsunori <foozy@lares.dti.ne.jp> |
---|---|
date | Wed, 31 Dec 2014 17:55:43 +0900 |
parents | a4958cdb2202 |
children | 1e6fb8db666e |
line wrap: on
line diff
--- a/tests/test-context.py.out Wed Dec 31 13:48:55 2014 -0800 +++ b/tests/test-context.py.out Wed Dec 31 17:55:43 2014 +0900 @@ -14,7 +14,13 @@ = checking context.status(): == checking workingctx.status: wctx._status=<status modified=['bar-m'], added=['bar-a'], removed=['bar-r'], deleted=[], unknown=[], ignored=[], clean=[]> +=== with "pattern match": <status modified=['bar-m'], added=[], removed=[], deleted=[], unknown=[], ignored=[], clean=[]> wctx._status=<status modified=['bar-m'], added=['bar-a'], removed=['bar-r'], deleted=[], unknown=[], ignored=[], clean=[]> <status modified=[], added=['bar-m'], removed=[], deleted=[], unknown=[], ignored=[], clean=[]> wctx._status=<status modified=['bar-m'], added=['bar-a'], removed=['bar-r'], deleted=[], unknown=[], ignored=[], clean=[]> +=== with "always match" and "listclean=True": +<status modified=['bar-m'], added=['bar-a'], removed=['bar-r'], deleted=[], unknown=[], ignored=[], clean=['foo']> +wctx._status=<status modified=['bar-m'], added=['bar-a'], removed=['bar-r'], deleted=[], unknown=[], ignored=[], clean=[]> +<status modified=[], added=['bar-a', 'bar-m'], removed=[], deleted=[], unknown=[], ignored=[], clean=['foo']> +wctx._status=<status modified=['bar-m'], added=['bar-a'], removed=['bar-r'], deleted=[], unknown=[], ignored=[], clean=[]>