WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
222198
[LayoutTests] Convert http/tests/loading convert PHP to Python
https://bugs.webkit.org/show_bug.cgi?id=222198
Summary
[LayoutTests] Convert http/tests/loading convert PHP to Python
Chris Gambrell
Reported
2021-02-19 14:02:51 PST
Replacing PHP with equivalent Python CGI scripts
Attachments
Patch
(73.87 KB, patch)
2021-02-23 14:19 PST
,
Chris Gambrell
no flags
Details
Formatted Diff
Diff
Patch
(60.80 KB, patch)
2021-02-23 15:01 PST
,
Chris Gambrell
no flags
Details
Formatted Diff
Diff
Patch
(118.83 KB, patch)
2021-02-24 08:04 PST
,
Chris Gambrell
no flags
Details
Formatted Diff
Diff
Patch
(102.54 KB, patch)
2021-02-24 10:01 PST
,
Chris Gambrell
no flags
Details
Formatted Diff
Diff
Patch
(104.04 KB, patch)
2021-03-01 09:39 PST
,
Chris Gambrell
no flags
Details
Formatted Diff
Diff
Patch
(102.57 KB, patch)
2021-03-01 10:34 PST
,
Chris Gambrell
no flags
Details
Formatted Diff
Diff
Patch
(17.07 KB, patch)
2021-03-31 19:25 PDT
,
Chris Gambrell
no flags
Details
Formatted Diff
Diff
Patch
(17.03 KB, patch)
2021-04-01 19:09 PDT
,
Chris Gambrell
no flags
Details
Formatted Diff
Diff
Patch
(17.14 KB, patch)
2021-04-02 12:14 PDT
,
Chris Gambrell
no flags
Details
Formatted Diff
Diff
Show Obsolete
(8)
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2021-02-19 14:03:11 PST
<
rdar://problem/74536576
>
Chris Gambrell
Comment 2
2021-02-23 14:19:18 PST
Created
attachment 421349
[details]
Patch
Chris Gambrell
Comment 3
2021-02-23 15:01:59 PST
Created
attachment 421355
[details]
Patch
Chris Gambrell
Comment 4
2021-02-24 08:04:11 PST
Created
attachment 421411
[details]
Patch
Chris Gambrell
Comment 5
2021-02-24 10:01:10 PST
Created
attachment 421419
[details]
Patch
Jonathan Bedard
Comment 6
2021-02-25 11:19:40 PST
Comment on
attachment 421419
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=421419&action=review
> LayoutTests/http/tests/loading/authentication-after-redirect-stores-wrong-credentials/resources/wrong-credential-1-redirect-to-auth.php:-3 > -// That is important, and the next page has to be loaded using 127.0.0.1.
I think you should retain this comment in the python code, even though it isn't in the request
> LayoutTests/http/tests/loading/resourceLoadStatistics/resources/set-cookie.php:-9 > -</script>
This file is being removed, but not replaced. Is it not used anywhere? If not, it's fine to remove it (it's a resource, so it is not itself a test)
> LayoutTests/http/tests/loading/resources/imported-stylesheet-varying-according-domain.css.py:10 > +color = ''
You can do this in a one-liner: color = 'green' if host == domain else 'red'
> LayoutTests/http/tests/loading/resources/imported-stylesheet-varying-according-domain.css.py:19 > + 'body {{ background-color: {};}}'.format(color)
You may actually consider putting the one-liner as the format argument
> LayoutTests/http/tests/loading/resources/post-in-iframe-with-back-navigation-page-1.py:6 > +today = time.time()
Nit: I'd call this variable "now" since it isn't just the day
> LayoutTests/http/tests/loading/resources/post-in-iframe-with-back-navigation-page-2.py:6 > +today = time.time()
Nit: I'd call this variable "now" since it isn't just the day
> LayoutTests/http/tests/loading/resources/post-in-iframe-with-back-navigation-page-3.py:6 > +today = time.time()
Nit: I'd call this variable "now" since it isn't just the day
Chris Gambrell
Comment 7
2021-03-01 09:39:34 PST
Created
attachment 421835
[details]
Patch
Chris Gambrell
Comment 8
2021-03-01 09:40:17 PST
(In reply to Jonathan Bedard from
comment #6
)
> Comment on
attachment 421419
[details]
> Patch > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=421419&action=review
> > > LayoutTests/http/tests/loading/authentication-after-redirect-stores-wrong-credentials/resources/wrong-credential-1-redirect-to-auth.php:-3 > > -// That is important, and the next page has to be loaded using 127.0.0.1. > > I think you should retain this comment in the python code, even though it > isn't in the request > > > LayoutTests/http/tests/loading/resourceLoadStatistics/resources/set-cookie.php:-9 > > -</script> > > This file is being removed, but not replaced. Is it not used anywhere? If > not, it's fine to remove it (it's a resource, so it is not itself a test) > > > LayoutTests/http/tests/loading/resources/imported-stylesheet-varying-according-domain.css.py:10 > > +color = '' > > You can do this in a one-liner: > > color = 'green' if host == domain else 'red' > > > LayoutTests/http/tests/loading/resources/imported-stylesheet-varying-according-domain.css.py:19 > > + 'body {{ background-color: {};}}'.format(color) > > You may actually consider putting the one-liner as the format argument > > > LayoutTests/http/tests/loading/resources/post-in-iframe-with-back-navigation-page-1.py:6 > > +today = time.time() > > Nit: I'd call this variable "now" since it isn't just the day > > > LayoutTests/http/tests/loading/resources/post-in-iframe-with-back-navigation-page-2.py:6 > > +today = time.time() > > Nit: I'd call this variable "now" since it isn't just the day > > > LayoutTests/http/tests/loading/resources/post-in-iframe-with-back-navigation-page-3.py:6 > > +today = time.time() > > Nit: I'd call this variable "now" since it isn't just the day
Fixed in
comment 7
Chris Gambrell
Comment 9
2021-03-01 10:34:53 PST
Created
attachment 421842
[details]
Patch
EWS
Comment 10
2021-03-01 13:16:25 PST
Committed
r273685
: <
https://commits.webkit.org/r273685
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 421842
[details]
.
Chris Gambrell
Comment 11
2021-03-31 19:08:59 PDT
Reopening for the second pass
Chris Gambrell
Comment 12
2021-03-31 19:25:39 PDT
Created
attachment 424865
[details]
Patch
Chris Gambrell
Comment 13
2021-04-01 19:09:09 PDT
Created
attachment 424974
[details]
Patch
Jonathan Bedard
Comment 14
2021-04-02 11:48:53 PDT
Comment on
attachment 424974
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=424974&action=review
> LayoutTests/http/tests/loading/resources/redirect-methods-result.py:24 > + header_cookies = os.environ['HTTP_COOKIE']
Any reason not to use get_cookies()?
Chris Gambrell
Comment 15
2021-04-02 12:14:09 PDT
Created
attachment 425038
[details]
Patch
EWS
Comment 16
2021-04-06 11:00:37 PDT
Committed
r275533
: <
https://commits.webkit.org/r275533
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 425038
[details]
.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug