1
0
mirror of https://github.com/fafhrd91/actix-web synced 2024-11-27 17:52:56 +01:00

Merge pull request #1533 from JohnTitor/next-test-server

http-test: Bump up to 2.0.0-alpha.1
This commit is contained in:
Yuki Okushi 2020-05-23 15:22:40 +09:00 committed by GitHub
commit f57b5659da
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 7 additions and 6 deletions

View File

@ -33,5 +33,5 @@ log = "0.4"
[dev-dependencies] [dev-dependencies]
actix-server = "1.0.0" actix-server = "1.0.0"
actix-connect = { version = "2.0.0-alpha.2", features = ["openssl"] } actix-connect = { version = "2.0.0-alpha.2", features = ["openssl"] }
actix-http-test = { version = "1.0.0", features = ["openssl"] } actix-http-test = { version = "2.0.0-alpha.1", features = ["openssl"] }
actix-utils = "1.0.3" actix-utils = "1.0.3"

View File

@ -90,7 +90,7 @@ flate2 = { version = "1.0.13", optional = true }
[dev-dependencies] [dev-dependencies]
actix-server = "1.0.1" actix-server = "1.0.1"
actix-connect = { version = "2.0.0-alpha.2", features = ["openssl"] } actix-connect = { version = "2.0.0-alpha.2", features = ["openssl"] }
actix-http-test = { version = "1.0.0", features = ["openssl"] } actix-http-test = { version = "2.0.0-alpha.1", features = ["openssl"] }
actix-tls = { version = "2.0.0-alpha.1", features = ["openssl"] } actix-tls = { version = "2.0.0-alpha.1", features = ["openssl"] }
criterion = "0.3" criterion = "0.3"
env_logger = "0.7" env_logger = "0.7"

View File

@ -57,7 +57,7 @@ rust-tls = { version = "0.17.0", package = "rustls", optional = true, features =
actix-connect = { version = "2.0.0-alpha.2", features = ["openssl"] } actix-connect = { version = "2.0.0-alpha.2", features = ["openssl"] }
actix-web = { version = "3.0.0-alpha.3", features = ["openssl"] } actix-web = { version = "3.0.0-alpha.3", features = ["openssl"] }
actix-http = { version = "2.0.0-alpha.4", features = ["openssl"] } actix-http = { version = "2.0.0-alpha.4", features = ["openssl"] }
actix-http-test = { version = "1.0.0", features = ["openssl"] } actix-http-test = { version = "2.0.0-alpha.1", features = ["openssl"] }
actix-utils = "1.0.3" actix-utils = "1.0.3"
actix-server = "1.0.0" actix-server = "1.0.0"
actix-tls = { version = "2.0.0-alpha.1", features = ["openssl", "rustls"] } actix-tls = { version = "2.0.0-alpha.1", features = ["openssl", "rustls"] }

View File

@ -1,6 +1,6 @@
# Changes # Changes
## [Unreleased] - 2020-xx-xx ## [2.0.0-alpha.1] - 2020-05-23
* Update the `time` dependency to 0.2.7 * Update the `time` dependency to 0.2.7
* Update `actix-connect` dependency to 2.0.0-alpha.2 * Update `actix-connect` dependency to 2.0.0-alpha.2

View File

@ -1,6 +1,6 @@
[package] [package]
name = "actix-http-test" name = "actix-http-test"
version = "1.0.0" version = "2.0.0-alpha.1"
authors = ["Nikolay Kim <fafhrd91@gmail.com>"] authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
description = "Actix http test server" description = "Actix http test server"
readme = "README.md" readme = "README.md"

View File

@ -104,7 +104,8 @@ pub async fn test_server<F: ServiceFactory<TcpStream>>(factory: F) -> TestServer
/// Get first available unused address /// Get first available unused address
pub fn unused_addr() -> net::SocketAddr { pub fn unused_addr() -> net::SocketAddr {
let addr: net::SocketAddr = "127.0.0.1:0".parse().unwrap(); let addr: net::SocketAddr = "127.0.0.1:0".parse().unwrap();
let socket = Socket::new(Domain::ipv4(), Type::stream(), Some(Protocol::tcp())).unwrap(); let socket =
Socket::new(Domain::ipv4(), Type::stream(), Some(Protocol::tcp())).unwrap();
socket.bind(&addr.into()).unwrap(); socket.bind(&addr.into()).unwrap();
socket.set_reuse_address(true).unwrap(); socket.set_reuse_address(true).unwrap();
let tcp = socket.into_tcp_listener(); let tcp = socket.into_tcp_listener();