Commit graph

3197 commits

Author SHA1 Message Date
bors-servo
5487ba35eb Auto merge of #9665 - glennw:fix-ref-tests-1, r=pcwalton
Fix a broken reftest.

The strong element has a different font weight by default. This means that the line height
is slightly different from the ref test. In normal Servo this doesn't matter due to how the
default snapping works.

However, in both WebRender and Firefox, this results in the reftests being one pixel different.

Setting the font weight to be normal makes the reftest pass in Servo, WebRender and FF.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9665)
<!-- Reviewable:end -->
2016-02-17 07:40:07 +05:30
Peter
e39e59ef18 #1716 The indicated part of the document.
Interactive test for fragid resolution.

    Added HTML tests for scrolling to fragid

    Applied algorithm from whatwg spec
    https://html.spec.whatwg.org/multipage/#the-indicated-part-of-the-document

    Changes following code review
2016-02-17 00:51:46 +00:00
bors-servo
184c7dbd47 Auto merge of #9659 - nox:test-typedarrays, r=Ms2ger
Enable typedarrays tests from web-platform-tests

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9659)
<!-- Reviewable:end -->
2016-02-17 06:01:29 +05:30
bors-servo
6c874c929f Auto merge of #9658 - nox:test-webidl, r=Ms2ger
Enable WebIDL tests from web-platform-tests

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9658)
<!-- Reviewable:end -->
2016-02-17 05:10:33 +05:30
Ben
1ccb642ee4 CORS Preflight Logic Fix
Fix check to set flag if any header is a simple header.
Fix failing tests to allow merge in advance of @nikkibee's changes
as per @jdm's direction via IRC
2016-02-16 15:42:07 -07:00
Glenn Watson
10a3fa7df6 Fix a broken reftest.
The <strong> element has a different font weight by default. This means that the line height
is slightly different from the ref test. In normal Servo this doesn't matter due to how the
default snapping works.

However, in both WebRender and Firefox, this results in the reftests being one pixel different.

Setting the font weight to be normal makes the reftest pass in Servo, WebRender and FF.
2016-02-17 07:55:11 +10:00
bors-servo
c388c83dcd Auto merge of #9625 - danlrobertson:i9547, r=KiChjang
Implement step 9 of XHR Open method

Implement step 9 of the [XMLHttpRequest Open](https://xhr.spec.whatwg.org/#dom-xmlhttprequest-open) method. Thanks to @KiChjang for all the help!

As always, comments and critiques are welcomed!

Fix: #9547

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9625)
<!-- Reviewable:end -->
2016-02-17 02:51:44 +05:30
Anthony Ramine
677728b623 Enable typedarrays tests from web-platform-tests 2016-02-16 17:50:22 +01:00
Anthony Ramine
3222a0ecd0 Enable WebIDL tests from web-platform-tests 2016-02-16 17:33:10 +01:00
bors-servo
3ef0bb4b37 Auto merge of #9648 - psdh:fixnodeiseual, r=Manishearth
fix Node-isEqualNode.html test failure

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9648)
<!-- Reviewable:end -->
2016-02-16 02:35:47 +05:30
Prabhjyot Singh Sodhi
ae80b9bcf0 fix Node-isEqualNode.html test failure 2016-02-16 00:24:35 +05:30
bors-servo
5ee5ce07ba Auto merge of #9621 - KiChjang:xhr-response-json, r=Ms2ger
Cache XHR JSON responses

Fixes #3919.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9621)
<!-- Reviewable:end -->
2016-02-15 21:52:49 +05:30
Anthony Ramine
ae72d1dfbe Fix the hasInstance hook of interface objects
Step 2 wasn't properly implemented.
2016-02-15 14:12:53 +01:00
Daniel Robertson
4d15b02dde Handle credentials in modify_request_headers
Handle credentials and set the apropriate header in
`modify_request_headers`.
2016-02-15 06:47:47 +00:00
Keith Yeung
6be5218d3c Cache XHR JSON responses 2016-02-14 23:55:43 -05:00
Daniel Robertson
0b0e1473cd Implement Blob response for XMLHttpRequest: #9623
In response to #9623 implement the Blob response for XML HttpRequest and
change the expected result for the script test.
2016-02-14 20:00:30 +00:00
Emilio Cobos Álvarez
dd503dfacb Refactor style to be completely backend-independent
This commit refactors the style crate to be completely independent of
the actual implementation and pseudo-elements supported.

This also adds a gecko backend which introduces parsing for the
anonymous box pseudo-elements[1], although there's still no way of
querying them.

https://mxr.mozilla.org/mozilla-central/source/layout/style/nsCSSAnonBoxList.h
2016-02-13 16:05:14 +01:00
Anthony Ramine
680c817d53 Bump url to 0.5.5 2016-02-13 00:08:12 +01:00
Anthony Ramine
899a5bbfa4 Bump selectors to 0.4.1 2016-02-13 00:08:11 +01:00
Anthony Ramine
874fa5595f Bump euclid to 0.6.2 2016-02-13 00:08:08 +01:00
Anthony Ramine
d0ab28a735 Bump cssparser to 0.5.3 2016-02-13 00:08:07 +01:00
Anthony Ramine
e2d9734609 Bump string_cache to 0.2.9 2016-02-13 00:08:06 +01:00
Anthony Ramine
2d6ac4da97 Bump app_units to 0.2.1 2016-02-13 00:08:05 +01:00
Anthony Ramine
c6262c368f Reorder dependencies in some Cargo.toml files 2016-02-13 00:08:04 +01:00
bors-servo
520ca258d4 Auto merge of #9618 - jongiddy:fix-mp4-size, r=jdm
Calculate correct mp4 header length.

The calculation of MP4 frame length is incorrect, shifting values by 1 bit instead of 8 bits.  It works for the test MP4 file because the length of the frame is less than 256 bytes, so the shifted values are all zero.

This PR changes the code to calculate the length correctly. It adds a test to check a fake long stream. Still not long enough to test completely, but at least detects the problem with the original code.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9618)
<!-- Reviewable:end -->
2016-02-13 01:20:58 +05:30
Jonathan Giddy
ec0ea465ec Calculate mp4 header length correctly. 2016-02-12 17:39:34 +00:00
bors-servo
a746522b58 Auto merge of #9606 - servo:bump-js, r=Ms2ger
Bump js to get fix from servo/rust-mozjs#237

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9606)
<!-- Reviewable:end -->
2016-02-12 21:45:51 +05:30
Anthony Ramine
71092e142d Bump js to get fix from servo/rust-mozjs#237 2016-02-12 17:15:09 +01:00
bors-servo
ee11a847dd Auto merge of #9605 - Ms2ger:update-wpt, r=Ms2ger
Update web-platform-tests to revision 95aad3bd9b82b5c65d84d53517b65ba084de9394

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9605)
<!-- Reviewable:end -->
2016-02-12 20:14:24 +05:30
Ms2ger
e8ed816728 Update web-platform-tests to revision 95aad3bd9b82b5c65d84d53517b65ba084de9394 2016-02-12 09:41:14 +01:00
bors-servo
faa349fb87 Auto merge of #9607 - mbrubeck:chaos, r=jgraham
Add a "mach test-wpt --chaos" mode for reproducing intermittent failures using rr

This adds a new `--chaos` flag to the `test-wpt` and `test-css` commands.  This will run a test repeatedly until it fails, recording it with the rr debugger in chaos mode. Requires a recent master build of rr.

```
./mach test-wpt --chaos test.html
```
is shorthand for:
```
./mach test-wpt --repeat-until-unexpected \
                --debugger rr \
                --debugger-args "record --chaos" \
                --include test.html
```
This PR currently includes changes to wptrunner which were also submitted upstream as w3c/wptrunner#170.  We should not merge this until that upstream PR is merged. CC @jgraham

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9607)
<!-- Reviewable:end -->
2016-02-12 03:34:47 +05:30
Matt Brubeck
6f55e949a1 Add --repeat-until-unexpected option to wptrunner 2016-02-11 10:01:04 -08:00
Josh Matthews
2796a4dfa8 Compile raw inline event handlers lazily. Resolves #8489. 2016-02-11 15:44:52 +01:00
Josh Matthews
c5fe8f7401 Add a test for panicking when reloading an iframe twice. 2016-02-10 09:20:07 -05:00
Josh Matthews
d6ea4b60a4 Make location_reload.html not trigger resource exhaustion. 2016-02-10 09:20:05 -05:00
Ms2ger
6ce5b7527a Ensure that base_multiple.html fails rather than times out in the typical failure case. 2016-02-10 09:20:04 -05:00
Ms2ger
0f383a50a1 Rewrite and clarify base_multiple.html. 2016-02-10 09:20:03 -05:00
Josh Matthews
fbae86281d Add test for unblocking onload when removing an iframe from the tree. 2016-02-10 09:20:01 -05:00
Josh Matthews
e9b98ad5fa Make iframes block the enclosing document's load event. Fixes #6663. 2016-02-10 09:20:00 -05:00
bors-servo
f1018b84a8 Auto merge of #9525 - nikkisquared:test_filtered_responses, r=asajeffrey
Test filtered responses and implement Cors Check Fetch step

I've been writing tests for creating filtered responses. So far I have three of the four types being made (namely, Basic, CORS, and Opaque), and just need to figure out how to make an OpaqueRedirect filtered response, since it's handled separately from the others. I will also add more tests to ensure the content of the filtered responses matches the limitations placed by the specification.

Along the way I implemented Cors Check, since it's required for the CORS filtered response. @jdm suggested I handle it in here, since it's such a small step, compared to other parts of Fetch.

Since all the tests currently pass, and I've spent a while adding the Cors Check and other pieces, I figured now would be a good time to start having it reviewed.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9525)
<!-- Reviewable:end -->
2016-02-10 03:11:22 +05:30
Nikki
e8665d47ea working on implementing Cors Check and Origin to Ascii serialisation 2016-02-09 13:51:35 -07:00
Ms2ger
68ad3920de Pass the product to the test updating code (fixes #9563). 2016-02-09 11:22:39 +01:00
bors-servo
3d63f09361 Auto merge of #9244 - paulrouget:securitychange, r=jdm
mozbrowsersecuritychange event

Fixes #8544

No test yet. Is there a way to mock a https connection?

Also, I wish I could use the `HTTPSState` enum instead of a `String` when calling `trigger_mozbrowser_event` (https://github.com/servo/servo/compare/master...paulrouget:securitychange?expand=1#diff-30a18e04d7e0b66aafdf192e416cad44R306) but that would require `constellation_msg.rs` to know about `HTTPSState`, which is defined in `document.rs`, which would add a dependency to `components/msg`. I could define `HTTPSState` somewhere else maybe? Or maybe it's fine to use a `String`. But then, should I use the HTTPSState strings (`"modern/deprecated/none"`) or the mozbrowser strings (`"secure/insecure/broken"`) (as it is now)

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9244)
<!-- Reviewable:end -->
2016-02-09 13:00:29 +05:30
Paul Rouget
63519c3574 mozbrowsersercuritychange event 2016-02-09 08:05:17 +01:00
Iszak Bryan
68d512c1ea Added test to verify parse error reporter is functioning 2016-02-07 18:46:41 +00:00
bors-servo
fb3fe3d784 Auto merge of #9522 - pcwalton:two-overflows, r=mbrubeck
layout: Separate out overflow-for-scrolling from overflow-for-paint.

Closes #9484.

r? @mbrubeck

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9522)
<!-- Reviewable:end -->
2016-02-05 10:58:50 +05:30
bors-servo
b35801bf29 Auto merge of #9521 - Manishearth:ws-worker, r=Ms2ger
Make websockets work in a worker scope

r? @jdm

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9521)
<!-- Reviewable:end -->
2016-02-05 08:21:37 +05:30
bors-servo
2a6707ce58 Auto merge of #9532 - nox:dedup-heapsize, r=Manishearth
Say farewell to in-tree HeapSizeOf

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9532)
<!-- Reviewable:end -->
2016-02-05 03:40:36 +05:30
Anthony Ramine
cb5cd8d881 Say farewell to in-tree HeapSizeOf 2016-02-04 22:03:32 +01:00
bors-servo
d574b78313 Auto merge of #9469 - fhahn:compiletest2, r=jdm
Integrate compiletest_rs

This PR integrates `compiletest_rs` as suggested in #5646. I created a new  `tests/compiletest` directory which contains separate crates for the tests.

Currently this PR includes `compile-fail` tests for some lints (acutally all except  inheritance_integrity, beacuse I'm not sure how to include the dom stuff in a way the `#[dom_struct]` works).

I gathered that there should be more crates for which compiletests make sense and would appreciate any pointers to relevant crates.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9469)
<!-- Reviewable:end -->
2016-02-04 21:00:21 +05:30