Commit graph

5418 commits

Author SHA1 Message Date
Martin Robinson
0b56bb2237 Reimplement scrolling to fragments
This reimplemntation of the feature uses ScrollRootIds to scroll
particular scrollable areas of the page.

Fixes #13736.
Fixes #10753.
2016-11-29 22:12:16 +01:00
bors-servo
7be32770b1 Auto merge of #14393 - dati91:fix, r=jdm
WriteValue should return undefined

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

<!-- 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

<!-- Either: -->
- [X] There are tests for these changes

<!-- 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/14393)
<!-- Reviewable:end -->
2016-11-29 06:11:06 -08:00
bors-servo
00f30d1b7e Auto merge of #14361 - nox:write, r=jdm
Implement document.write (fixes #3704)

<!-- 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/14361)
<!-- Reviewable:end -->
2016-11-29 04:18:43 -08:00
Xidorn Quan
599eb1c9f0 Move Arc<RwLock<_>> out from CssRules tuple 2016-11-29 22:15:13 +11:00
bors-servo
40917e7991 Auto merge of #14395 - servo:stylesheet-metadata, r=Manishearth
Use stylesheet’s base URL and ns prefixes in CSSOM insert/appendRule.

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

---
<!-- 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
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- 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/14395)
<!-- Reviewable:end -->
2016-11-29 01:28:06 -08:00
bors-servo
2c05bf3c42 Auto merge of #14387 - szeged:event-target, r=jdm
Add event target for bluetooth

<!-- Please describe your changes on the following line: -->
Add support for event listeners in webbluetooth.
---
<!-- 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] There are tests for these changes

<!-- 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/14387)
<!-- Reviewable:end -->
2016-11-28 22:13:31 -08:00
Anthony Ramine
4d93ee134c Implement document.write (fixes #3704)
This is a bit crude because of some missing utility methods on BufferQueue.
2016-11-28 23:05:56 +01:00
Attila Dusnoki
50a5639a8b WriteValue should return undefined 2016-11-28 17:14:11 +01:00
Simon Sapin
0714e2291c Add base_url and namespaces to style::Stylesheet 2016-11-28 16:18:04 +01:00
Attila Dusnoki
d9c7ffb5b3 Add event target for bluetooth 2016-11-28 10:49:49 +01:00
Anthony Ramine
dfb35db6d3 Move to Cargo workspaces 2016-11-28 09:44:20 +01:00
In-Ho Yi
25f0317a82 Add DateTime string attribute to Time
Also handle datetime content attribute when attribute is absent.

Rephrase terms used in the test: dateTime IDL property, datetime
attribute and datetime content attribute.

Remove failure expectations for time element.
2016-11-27 14:09:54 -08:00
bors-servo
1888ffdb42 Auto merge of #14375 - servo:error-info, r=nox
Don't return early from report_pending_exception() if the value is an unexpected object.

We will now dispatch the error event in this case as well.

<!-- 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/14375)
<!-- Reviewable:end -->
2016-11-27 01:37:41 -08:00
Ms2ger
154b16a25d Don't return early from report_pending_exception() if the value is an unexpected object.
We will now dispatch the error event in this case as well.
2016-11-27 10:27:11 +01:00
Ravi Shankar
f290a6f88c Fix the unit tests to use context 2016-11-27 08:49:28 +05:30
Anthony Ramine
708ebdceee Enable document.write tests 2016-11-27 01:27:30 +01:00
Anthony Ramine
c801327eab Rewrite how parser handles script scheduling 2016-11-26 22:58:20 +01:00
bors-servo
a0269027db Auto merge of #14365 - canaltinova:block-important, r=emilio
Property declaration block serialization should check for importance

<!-- Please describe your changes on the following line: -->
r? @emilio , @Manishearth

---
<!-- 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 fix #14329 (github issue number if applicable).

<!-- Either: -->
- [X] There are tests for these changes

<!-- 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/14365)
<!-- Reviewable:end -->
2016-11-26 05:09:55 -08:00
Nazım Can Altınova
d4c3035659 Property declaration block serialization should check for importance 2016-11-26 14:16:33 +03:00
Gregory
84e9277771 implement support for the width media query
failing test for correct to_css of "width"

separate test for mq and to_css

implement css serialization for Eq

remove PASS test expectation

remove FIXME

simplify serialization
2016-11-26 17:31:41 +08:00
bors-servo
bf92d0a27f Auto merge of #14335 - upsuper:stylo-unit-rerun-build, r=bholley
Add rerun-if-changed for bindings file

<!-- Please describe your changes on the following line: -->
check_bindings.py uses bindings.rs as input, so it should be rerun if that file gets changed.

---
<!-- 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
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

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

check_bindings.py uses bindings.rs as input, so it should be rerun if
that file gets changed.

<!-- 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/14335)
<!-- Reviewable:end -->
2016-11-25 10:01:16 -08:00
bors-servo
d98abaec20 Auto merge of #14300 - bholley:restyle_driven_traversal, r=emilio
stylo: Basic infrastructure for RestyleHint-driven traversal

Gecko Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=131701

(Don't review yet, will flag on the gecko bug when the time comes)

<!-- 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/14300)
<!-- Reviewable:end -->
2016-11-25 09:00:44 -08:00
bors-servo
beec035eb0 Auto merge of #13969 - bbansalWolfPack:master, r=jdm
html form validation initial steps with  test html file

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

Added code for initial steps in html form validation.
1. Added methods for trait validatable
2. implemented stub methods for  elements like HTMLInputElement, HTMLButtonElement, etc

<!-- 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
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- 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/13969)

<!-- Reviewable:end -->
2016-11-25 06:49:44 -08:00
Bobby Holley
900ad11238 Disable pseudo-elements-001.htm.ini for too many intermittent failures.
This seems to be failing more now on several distinct PRs.
2016-11-24 22:30:43 -08:00
Cameron McCormack
64ff6dc103 Implement StyleSheet.disabled. 2016-11-25 11:27:51 +08:00
Bobby Holley
992f7dddf4 Bug 1317016 - Basic infrastructure for RestyleHint-driven traversal.
MozReview-Commit-ID: 7wH5XcILVmX
2016-11-24 17:07:38 -08:00
Ms2ger
761524c01b Remove some unused arguments.
The change to the unit test is necessary because the resource thread is not
resilient against either of these Senders being dropped while the resource
thread is running. Before this change, it held clones of those senders itself
(public_setup_chan_clone, private_setup_chan_clone).
2016-11-24 11:46:33 +01:00
Ms2ger
7913f3adaf Remove the unused CancellationListener arguments in filemanager_thread. 2016-11-24 11:46:30 +01:00
Ms2ger
ce24edc2b3 Remove a test for the CoreResourceMsg::Cancel message. 2016-11-24 11:46:23 +01:00
bors-servo
5bfe1de10a Auto merge of #14315 - servo:fetch-unit-http, r=Manishearth
Rewrite and remove most unit tests for the legacy fetch stack.

<!-- 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/14315)
<!-- Reviewable:end -->
2016-11-24 00:42:43 -08:00
Bhavya Bansal
2a40877851 html form validation initial steps with test html file, added stub methods, added code to handle validations 2016-11-23 22:46:57 -08:00
bors-servo
61a225bab0 Auto merge of #14341 - stshine:where-is-the-top, r=mrobinson,emilio
script: Fix the scroll to top behavior

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

When finding the indicated fragment, do not use the document element to indicate
the top of the Document, and when scrolling to the frament and we do not find a
element, scrolling the top if the fragment is empty or equal to "top".

---
<!-- 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
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [X] These changes do not require tests because _____

<!-- 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/14341)
<!-- Reviewable:end -->
2016-11-23 21:51:20 -08:00
Ms2ger
2dc73d8789 Rewrite test_redirect_from_x_to_x_provides_x_with_cookie_from_first_response. 2016-11-23 22:35:33 +01:00
Ms2ger
f4f125852a Remove references to https from http_loader unit tests. 2016-11-23 22:34:39 +01:00
Ms2ger
adc78c7cbe Remove a test for view-source.
This scheme is not currently supported in fetch (#14308).
2016-11-23 22:34:38 +01:00
Ms2ger
621ca6190a Translate a test for ftp URLs to fetch. 2016-11-23 22:34:36 +01:00
Ms2ger
fc26aaf807 Translate a unit test for bogus schemes to fetch. 2016-11-23 22:34:34 +01:00
Ms2ger
ce89fcf335 Rewrite test_cookies_blocked. 2016-11-23 22:34:33 +01:00
Ms2ger
2fa032109f Rewrite test_content_blocked. 2016-11-23 22:34:32 +01:00
Ms2ger
b4178c7eaf Split test_content_blocked for readability. 2016-11-23 22:34:31 +01:00
Ms2ger
3da075ca73 Remove test for CustomResponseMediator.
The fetch stack does not yet support this at all (#14306).
2016-11-23 22:34:30 +01:00
Ms2ger
64d176d851 Remove referrer policy unit tests.
This code should be covered sufficiently by wpt tests.
2016-11-23 22:34:28 +01:00
Ms2ger
a8f7f3c1db Rewrite test_auth_ui_needs_www_auth. 2016-11-23 22:34:27 +01:00
Ms2ger
4c34e9aa89 Remove test_auth_ui_sets_header_on_401.
The fetch stack does not yet support asking the user for credentials (#14305).
2016-11-23 22:34:26 +01:00
Ms2ger
9f23949628 Rewrite test_if_auth_creds_not_in_url_but_in_cache_it_sets_it. 2016-11-23 22:34:25 +01:00
Ms2ger
27d90fb6a8 Rewrite test_load_follows_a_redirect. 2016-11-23 22:34:20 +01:00
bors-servo
210b1be1d0 Auto merge of #14347 - jcdyer:cdyer/len-parsing, r=Wafflespeanut
Only allow border-image-outset to use non-negative numbers.

Restricts border-image-outline to only allow positive values.

Fixes #14295

---
<!-- 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 fix #14295.

<!-- Either: -->
- [x] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- 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/14347)
<!-- Reviewable:end -->
2016-11-23 12:30:41 -08:00
bors-servo
996756687c Auto merge of #14241 - Manishearth:mut-cssom, r=SimonSapin
CSSOM: Whole ton of things

CSSOM is now starting to be useful!

Based on #14190. Only the <s>last commit</s> last two commits need review.

cc @xidorn . This doesn't change the style API, but adds useful methods.

part of #11420

This adds:
 - `insertRule()` and `deleteRule()` on `CSSStyleSheet`, `CSSGroupingRule`
 - `.style` getters on link and style elements
 - Keyframes-backed `CSSRules` and `CSSKeyframesRule.cssRules`
 - `CSSGroupingRule.cssRules`
 - `prefix` and `namespaceURI` attributes of `CSSNamespaceRule`
 - Fixups regarding parent stylesheets

r? @SimonSapin

<!-- 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/14241)
<!-- Reviewable:end -->
2016-11-23 10:27:49 -08:00
J. Cliff Dyer
46c4c9ce66 Only allow border-image-outset to use non-negative values. 2016-11-23 13:20:29 -05:00
Manish Goregaokar
18742e72fa Update test expectations 2016-11-23 09:32:48 -08:00