D3366: tests: port inline extension in test-http-bundle1.t to py3

2018-04-14 Thread durin42 (Augie Fackler)
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGe481d54f516d: tests: port inline extension in 
test-http-bundle1.t to py3 (authored by durin42, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D3366?vs=8243&id=8266

REVISION DETAIL
  https://phab.mercurial-scm.org/D3366

AFFECTED FILES
  tests/test-http-bundle1.t

CHANGE DETAILS

diff --git a/tests/test-http-bundle1.t b/tests/test-http-bundle1.t
--- a/tests/test-http-bundle1.t
+++ b/tests/test-http-bundle1.t
@@ -179,13 +179,13 @@
   > import base64
   > from mercurial.hgweb import common
   > def perform_authentication(hgweb, req, op):
-  > auth = req.headers.get('Authorization')
+  > auth = req.headers.get(b'Authorization')
   > if not auth:
-  > raise common.ErrorResponse(common.HTTP_UNAUTHORIZED, 'who',
-  > [('WWW-Authenticate', 'Basic Realm="mercurial"')])
+  > raise common.ErrorResponse(common.HTTP_UNAUTHORIZED, b'who',
+  > [(b'WWW-Authenticate', b'Basic Realm="mercurial"')])
   > if base64.b64decode(auth.split()[1]).split(b':', 1) != [b'user',
   > b'pass']:
-  > raise common.ErrorResponse(common.HTTP_FORBIDDEN, 'no')
+  > raise common.ErrorResponse(common.HTTP_FORBIDDEN, b'no')
   > def extsetup():
   > common.permhooks.insert(0, perform_authentication)
   > EOT



To: durin42, #hg-reviewers
Cc: mercurial-devel
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


D3366: tests: port inline extension in test-http-bundle1.t to py3

2018-04-13 Thread durin42 (Augie Fackler)
durin42 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  1. skip-blame just b prefixes

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D3366

AFFECTED FILES
  tests/test-http-bundle1.t

CHANGE DETAILS

diff --git a/tests/test-http-bundle1.t b/tests/test-http-bundle1.t
--- a/tests/test-http-bundle1.t
+++ b/tests/test-http-bundle1.t
@@ -179,13 +179,13 @@
   > import base64
   > from mercurial.hgweb import common
   > def perform_authentication(hgweb, req, op):
-  > auth = req.headers.get('Authorization')
+  > auth = req.headers.get(b'Authorization')
   > if not auth:
-  > raise common.ErrorResponse(common.HTTP_UNAUTHORIZED, 'who',
-  > [('WWW-Authenticate', 'Basic Realm="mercurial"')])
+  > raise common.ErrorResponse(common.HTTP_UNAUTHORIZED, b'who',
+  > [(b'WWW-Authenticate', b'Basic Realm="mercurial"')])
   > if base64.b64decode(auth.split()[1]).split(b':', 1) != [b'user',
   > b'pass']:
-  > raise common.ErrorResponse(common.HTTP_FORBIDDEN, 'no')
+  > raise common.ErrorResponse(common.HTTP_FORBIDDEN, b'no')
   > def extsetup():
   > common.permhooks.insert(0, perform_authentication)
   > EOT



To: durin42, #hg-reviewers
Cc: mercurial-devel
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel