Skip to content

Commit 1260c46

Browse files
committed
Bump deps
1 parent cbb18f5 commit 1260c46

File tree

2 files changed

+13
-12
lines changed

2 files changed

+13
-12
lines changed

Cargo.toml

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "http-cache-semantics"
3-
version = "1.0.2"
3+
version = "2.0.0"
44
description = "RFC 7234. Parses HTTP headers to correctly compute cacheability of responses, even in complex cases"
55
homepage = "https://lib.rs/http-cache-semantics"
66
repository = "https://github.com/kornelski/rusty-http-cache-semantics"
@@ -12,20 +12,21 @@ categories = ["caching", "web-programming::http-client"]
1212
keywords = ["http", "cache", "headers", "cache-control", "proxy"]
1313
include = ["Cargo.toml", "README.md", "src/*.rs", "LICENSE"]
1414
readme = "README.md"
15+
rust-version = "1.64"
1516

1617
[dependencies]
17-
http = "0.2.6"
18-
http-serde = { version = "1.1.0", optional = true }
19-
serde = { version = "1.0.136", optional = true, features = ["derive"] }
20-
reqwest = { version = "0.11.10", default-features = false, optional = true }
21-
time = { version = "0.3.9", features = ["parsing", "formatting"] }
18+
http = "1.0.0"
19+
http-serde = { version = "2.0.0", optional = true }
20+
serde = { version = "1.0.192", optional = true, features = ["derive"] }
21+
# reqwest = { version = "0.11.22", default-features = false, optional = true } # not upgraded yet
22+
time = { version = "0.3.30", features = ["parsing", "formatting"] }
2223

2324
[dev-dependencies]
24-
serde_json = "1.0.79"
25+
serde_json = "1.0.108"
2526

2627
[features]
27-
default = ["with_serde"]
28-
with_serde = ["dep:serde", "dep:http-serde"]
28+
default = ["serde"]
29+
serde = ["dep:serde", "dep:http-serde"]
2930

3031
[package.metadata.docs.rs]
3132
targets = ["x86_64-unknown-linux-gnu"]

tests/okhttp.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ fn test_max_age_preferred_over_higher_max_age() {
197197
let request = request_parts(Request::get("/"));
198198
let response = response_parts(
199199
Response::builder()
200-
.header(header::AGE, 3*60)
200+
.header(header::AGE, 3 * 60)
201201
.header(header::CACHE_CONTROL, "s-maxage=60, max-age=180"),
202202
);
203203
let policy = CachePolicy::new_options(&request, &response, now, options);
@@ -365,7 +365,7 @@ fn test_request_max_stale() {
365365
let response = response_parts(
366366
Response::builder()
367367
.header(header::CACHE_CONTROL, "max-age=120")
368-
.header(header::AGE, 4*60),
368+
.header(header::AGE, 4 * 60),
369369
);
370370

371371
let policy =
@@ -407,7 +407,7 @@ fn test_request_max_stale_not_honored_with_must_revalidate() {
407407
Response::builder()
408408
.header(header::CACHE_CONTROL, "max-age=120, must-revalidate")
409409
.header(header::DATE, format_date(15, 60))
410-
.header(header::AGE, 4*60),
410+
.header(header::AGE, 4 * 60),
411411
);
412412

413413
let policy =

0 commit comments

Comments
 (0)