Show More
@@ -152,21 +152,25 b' Check that extensions are loaded in phas' | |||||
152 | > from __future__ import print_function |
|
152 | > from __future__ import print_function | |
153 | > import os |
|
153 | > import os | |
154 | > from mercurial import exthelper |
|
154 | > from mercurial import exthelper | |
|
155 | > from mercurial.utils import procutil | |||
|
156 | > | |||
|
157 | > write = procutil.stdout.write | |||
155 | > name = os.path.basename(__file__).rsplit('.', 1)[0] |
|
158 | > name = os.path.basename(__file__).rsplit('.', 1)[0] | |
156 | > print("1) %s imported" % name, flush=True) |
|
159 | > bytesname = name.encode('utf-8') | |
|
160 | > write(b"1) %s imported\n" % bytesname) | |||
157 | > eh = exthelper.exthelper() |
|
161 | > eh = exthelper.exthelper() | |
158 | > @eh.uisetup |
|
162 | > @eh.uisetup | |
159 | > def _uisetup(ui): |
|
163 | > def _uisetup(ui): | |
160 |
> |
|
164 | > write(b"2) %s uisetup\n" % bytesname) | |
161 | > @eh.extsetup |
|
165 | > @eh.extsetup | |
162 | > def _extsetup(ui): |
|
166 | > def _extsetup(ui): | |
163 |
> |
|
167 | > write(b"3) %s extsetup\n" % bytesname) | |
164 | > @eh.uipopulate |
|
168 | > @eh.uipopulate | |
165 | > def _uipopulate(ui): |
|
169 | > def _uipopulate(ui): | |
166 |
> |
|
170 | > write(b"4) %s uipopulate\n" % bytesname) | |
167 | > @eh.reposetup |
|
171 | > @eh.reposetup | |
168 | > def _reposetup(ui, repo): |
|
172 | > def _reposetup(ui, repo): | |
169 |
> |
|
173 | > write(b"5) %s reposetup\n" % bytesname) | |
170 | > |
|
174 | > | |
171 | > extsetup = eh.finalextsetup |
|
175 | > extsetup = eh.finalextsetup | |
172 | > reposetup = eh.finalreposetup |
|
176 | > reposetup = eh.finalreposetup | |
@@ -174,7 +178,6 b' Check that extensions are loaded in phas' | |||||
174 | > uisetup = eh.finaluisetup |
|
178 | > uisetup = eh.finaluisetup | |
175 | > revsetpredicate = eh.revsetpredicate |
|
179 | > revsetpredicate = eh.revsetpredicate | |
176 | > |
|
180 | > | |
177 | > bytesname = name.encode('utf-8') |
|
|||
178 | > # custom predicate to check registration of functions at loading |
|
181 | > # custom predicate to check registration of functions at loading | |
179 | > from mercurial import ( |
|
182 | > from mercurial import ( | |
180 | > smartset, |
|
183 | > smartset, |
General Comments 0
You need to be logged in to leave comments.
Login now