Skip to content

Commit

Permalink
Merge branch 'master' into no_std
Browse files Browse the repository at this point in the history
  • Loading branch information
lucacasonato authored Jul 14, 2023
2 parents b0bb942 + 86730f1 commit 047d334
Show file tree
Hide file tree
Showing 10 changed files with 573 additions and 335 deletions.
3 changes: 3 additions & 0 deletions data-url/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,6 @@ test = false
[[test]]
name = "wpt"
harness = false

[package.metadata.docs.rs]
rustdoc-args = ["--generate-link-to-definition"]
3 changes: 3 additions & 0 deletions data-url/src/forgiving_base64.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ impl fmt::Display for InvalidBase64 {
}
}

#[cfg(feature = "std")]
impl std::error::Error for InvalidBase64 {}

#[derive(Debug)]
enum InvalidBase64Details {
UnexpectedSymbol(u8),
Expand Down
3 changes: 3 additions & 0 deletions form_urlencoded/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,6 @@ alloc = ["percent-encoding/alloc"]

[dependencies]
percent-encoding = { version = "2.3.0", default-features = false, path = "../percent_encoding" }

[package.metadata.docs.rs]
rustdoc-args = ["--generate-link-to-definition"]
3 changes: 3 additions & 0 deletions idna/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,6 @@ unicode-normalization = { version = "0.1.22", default-features = false }
[[bench]]
name = "all"
harness = false

[package.metadata.docs.rs]
rustdoc-args = ["--generate-link-to-definition"]
3 changes: 3 additions & 0 deletions percent_encoding/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ rust-version = "1.51"
default = ["std"]
std = ["alloc"]
alloc = []

[package.metadata.docs.rs]
rustdoc-args = ["--generate-link-to-definition"]
7 changes: 7 additions & 0 deletions url/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ edition = "2018"
rust-version = "1.56"

[dev-dependencies]
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
bencher = "0.1"

Expand All @@ -41,13 +42,19 @@ no_std_net = ["no-std-net"]
# For no_std: Use errors_in_core and net_in_core
unstable = ["idna/unstable"]

[[test]]
name = "url_wpt"
path = "tests/wpt.rs"
harness = false

[[bench]]
name = "parse_url"
path = "benches/parse_url.rs"
harness = false

[package.metadata.docs.rs]
features = ["serde"]
rustdoc-args = ["--generate-link-to-definition"]

[package.metadata.playground]
features = ["serde"]
260 changes: 0 additions & 260 deletions url/tests/data.rs

This file was deleted.

37 changes: 37 additions & 0 deletions url/tests/expected_failures.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
</> against <file://h/C:/a/b>
<file:\\\\//> against <about:blank>
<file:\\\\\\\\> against <about:blank>
<file:\\\\\\\\?fox> against <about:blank>
<file:\\\\\\\\#guppy> against <about:blank>
<file://spider///> against <about:blank>
<file:\\\\localhost//> against <about:blank>
<file://\\/localhost//cat> against <about:blank>
<file://localhost//a//../..//> against <about:blank>
</////mouse> against <file:///elephant>
<\\/localhost//pig> against <file://lion/>
<//localhost//pig> against <file://lion/>
</..//localhost//pig> against <file://lion/>
<C|> against <file://host/dir/file>
<C|> against <file://host/D:/dir1/dir2/file>
<C|#> against <file://host/dir/file>
<C|?> against <file://host/dir/file>
<C|/> against <file://host/dir/file>
<C|\n/> against <file://host/dir/file>
<C|\\> against <file://host/dir/file>
</c:/foo/bar> against <file://host/path>
<file://example.net/C:/> against <about:blank>
<file://1.2.3.4/C:/> against <about:blank>
<file://[1::8]/C:/> against <about:blank>
<C|/> against <file://host/>
</C:/> against <file://host/>
<file:C:/> against <file://host/>
<file:/C:/> against <file://host/>
<file://localhost//a//../..//foo> against <about:blank>
<file://localhost////foo> against <about:blank>
<file:////foo> against <about:blank>
<file:////one/two> against <file:///>
<////one/two> against <file:///>
<file:///.//> against <file:////>
<file:.//p> against <about:blank>
<file:/.//p> against <about:blank>
<https://x/?#\u{0}y> against <about:blank>
Loading

0 comments on commit 047d334

Please sign in to comment.