Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Webdriver browsing contexts not pipelines #16997

Merged

Conversation

@asajeffrey
Copy link
Member

asajeffrey commented May 22, 2017

At the moment, a webdriver session stores a pipeline_ids, which causes a mismatch with the spec, which asks a session to store a browsing context and a top-level browsing context. This PR fixes this mismatch.


  • ./mach build -d does not report any errors
  • ./mach test-tidy does not report any errors
  • These changes do not require tests because we are not testing webdriver

This change is Reviewable

@highfive
Copy link

highfive commented May 22, 2017

Heads up! This PR modifies the following files:

  • @jgraham: components/webdriver_server/lib.rs
  • @fitzgen: components/script/dom/htmliframeelement.rs, components/script/dom/document.rs, components/script/webdriver_handlers.rs, components/script/dom/history.rs, components/script/dom/windowproxy.rs and 10 more
  • @KiChjang: components/script/dom/htmliframeelement.rs, components/script/dom/document.rs, components/script/webdriver_handlers.rs, components/script/dom/history.rs, components/script/dom/windowproxy.rs and 10 more
@highfive
Copy link

highfive commented May 22, 2017

warning Warning warning

  • These commits modify script code, but no tests are modified. Please consider adding a test!
@asajeffrey
Copy link
Member Author

asajeffrey commented May 22, 2017

The first commit is from #16916.

@asajeffrey
Copy link
Member Author

asajeffrey commented May 22, 2017

@highfive highfive assigned jgraham and unassigned glennw May 22, 2017
@asajeffrey
Copy link
Member Author

asajeffrey commented May 22, 2017

This is part of the ongoing effort to introduce top-level browsing context ids, in order to support multiple windows (#13994). cc @jdm @cbrewster @paulrouget

@asajeffrey
Copy link
Member Author

asajeffrey commented May 22, 2017

IRC conversation with @jgraham: http://logs.glob.uno/?c=mozilla%23servo&s=22+May+2017&e=22+May+2017#c678807 and http://logs.glob.uno/?c=mozilla%23servo&s=22+May+2017&e=22+May+2017#c678945.

TL;DR: argh testing! (I ended up driving servo by hand with curl, got it to navigate, traverse and execute a script.)

@asajeffrey
Copy link
Member Author

asajeffrey commented May 24, 2017

#16916 has landed, so this PR is next in the queue.

@asajeffrey asajeffrey force-pushed the asajeffrey:webdriver-browsing-contexts-not-pipelines branch from c472ff8 to 79743b5 May 25, 2017
@asajeffrey
Copy link
Member Author

asajeffrey commented May 25, 2017

@jgraham are you OK reviewing this or should I find another victim?

@jgraham
Copy link
Contributor

jgraham commented May 26, 2017

I'm not an expert on all of this code, but the changes seem quite reasonable.


Reviewed 12 of 12 files at r1.
Review status: all files reviewed at latest revision, 3 unresolved discussions.


components/constellation/constellation.rs, line 906 at r1 (raw file):

            }
            // Handle a forward or back request
            // Handle a forward or back request

This seems to be duplicated.


components/script/dom/htmliframeelement.rs, line 501 at r1 (raw file):

        MozBrowserEvent::LocationChange(url, can_go_back, can_go_forward) => {
            BrowserElementLocationChangeEventDetail {
                url: Some(DOMString::from(url.as_str())),

Seems maybe unrelated?


components/webdriver_server/lib.rs, line 785 at r1 (raw file):

            Err(WebDriverError::new(ErrorStatus::UnsupportedOperation, "Failed to convert keycodes"))));

        // TODO: there's a race condition caused by these being two separate messages,

It's not quite clear what "these" means in this comment.


Comments from Reviewable

@asajeffrey
Copy link
Member Author

asajeffrey commented May 26, 2017

Thanks! I made changes based on your comments.


Review status: all files reviewed at latest revision, 3 unresolved discussions.


components/constellation/constellation.rs, line 906 at r1 (raw file):

Previously, jgraham wrote…

This seems to be duplicated.

Oops. Fixed.


components/script/dom/htmliframeelement.rs, line 501 at r1 (raw file):

Previously, jgraham wrote…

Seems maybe unrelated?

OK, I reverted this change.


components/webdriver_server/lib.rs, line 785 at r1 (raw file):

Previously, jgraham wrote…

It's not quite clear what "these" means in this comment.

Fixed.


Comments from Reviewable

@jgraham
Copy link
Contributor

jgraham commented May 26, 2017

Reviewed 4 of 4 files at r2.
Review status: all files reviewed at latest revision, all discussions resolved.


Comments from Reviewable

@jgraham
Copy link
Contributor

jgraham commented May 26, 2017

@bors-servo
Copy link
Contributor

bors-servo commented May 26, 2017

📌 Commit 3f761be has been approved by jgraham

@bors-servo
Copy link
Contributor

bors-servo commented May 26, 2017

Testing commit 3f761be with merge 0bc7e2f...

bors-servo added a commit that referenced this pull request May 26, 2017
…elines, r=jgraham

Webdriver browsing contexts not pipelines

<!-- Please describe your changes on the following line: -->

At the moment, a webdriver session stores a `pipeline_id`s, which causes a mismatch with the spec, which asks a session to store a browsing context and a top-level browsing context. This PR fixes this mismatch.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes do not require tests because we are not testing webdriver

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16997)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

bors-servo commented May 26, 2017

☀️ Test successful - android, arm32, arm64, linux-dev, linux-rel-css, linux-rel-wpt, mac-dev-unit, mac-rel-css, mac-rel-wpt1, mac-rel-wpt2, windows-msvc-dev
Approved by: jgraham
Pushing 0bc7e2f to master...

@bors-servo bors-servo merged commit 3f761be into servo:master May 26, 2017
3 checks passed
3 checks passed
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
homu Test successful
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

5 participants
You can’t perform that action at this time.