Show More
@@ -89,7 +89,7 b' Create an extension to test bundle2 API' | |||||
89 | > p = p.split('=', 1) |
|
89 | > p = p.split('=', 1) | |
90 | > try: |
|
90 | > try: | |
91 | > bundler.addparam(*p) |
|
91 | > bundler.addparam(*p) | |
92 |
> except ValueError |
|
92 | > except ValueError as exc: | |
93 | > raise error.Abort('%s' % exc) |
|
93 | > raise error.Abort('%s' % exc) | |
94 | > |
|
94 | > | |
95 | > if opts['compress']: |
|
95 | > if opts['compress']: | |
@@ -164,7 +164,7 b' Create an extension to test bundle2 API' | |||||
164 | > try: |
|
164 | > try: | |
165 | > for chunk in bundler.getchunks(): |
|
165 | > for chunk in bundler.getchunks(): | |
166 | > file.write(chunk) |
|
166 | > file.write(chunk) | |
167 |
> except RuntimeError |
|
167 | > except RuntimeError as exc: | |
168 | > raise error.Abort(exc) |
|
168 | > raise error.Abort(exc) | |
169 | > finally: |
|
169 | > finally: | |
170 | > file.flush() |
|
170 | > file.flush() | |
@@ -180,9 +180,9 b' Create an extension to test bundle2 API' | |||||
180 | > unbundler = bundle2.getunbundler(ui, sys.stdin) |
|
180 | > unbundler = bundle2.getunbundler(ui, sys.stdin) | |
181 | > op = bundle2.processbundle(repo, unbundler, lambda: tr) |
|
181 | > op = bundle2.processbundle(repo, unbundler, lambda: tr) | |
182 | > tr.close() |
|
182 | > tr.close() | |
183 |
> except error.BundleValueError |
|
183 | > except error.BundleValueError as exc: | |
184 | > raise error.Abort('missing support for %s' % exc) |
|
184 | > raise error.Abort('missing support for %s' % exc) | |
185 |
> except error.PushRaced |
|
185 | > except error.PushRaced as exc: | |
186 | > raise error.Abort('push race: %s' % exc) |
|
186 | > raise error.Abort('push race: %s' % exc) | |
187 | > finally: |
|
187 | > finally: | |
188 | > if tr is not None: |
|
188 | > if tr is not None: | |
@@ -206,7 +206,7 b' Create an extension to test bundle2 API' | |||||
206 | > unbundler = bundle2.getunbundler(ui, sys.stdin) |
|
206 | > unbundler = bundle2.getunbundler(ui, sys.stdin) | |
207 | > try: |
|
207 | > try: | |
208 | > params = unbundler.params |
|
208 | > params = unbundler.params | |
209 |
> except error.BundleValueError |
|
209 | > except error.BundleValueError as exc: | |
210 | > raise error.Abort('unknown parameters: %s' % exc) |
|
210 | > raise error.Abort('unknown parameters: %s' % exc) | |
211 | > ui.write('options count: %i\n' % len(params)) |
|
211 | > ui.write('options count: %i\n' % len(params)) | |
212 | > for key in sorted(params): |
|
212 | > for key in sorted(params): |
General Comments 0
You need to be logged in to leave comments.
Login now