Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(246)

Side by Side Diff: third_party/WebKit/LayoutTests/external/wpt/fetch/api/resources/authentication.py

Issue 2778753002: Import //fetch from Web Platform Tests. (Closed)
Patch Set: Baselines. Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 def main(request, response):
2 user = request.auth.username
3 password = request.auth.password
4
5 if user == "user" and password == "password":
6 return "Authentication done"
7
8 realm = "test"
9 if "realm" in request.GET:
10 realm = request.GET.first("realm")
11
12 return ((401, "Unauthorized"),
13 [("WWW-Authenticate", 'Basic realm="' + realm + '"')],
14 "Please login with credentials 'user' and 'password'")
15
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698