1
0
Fork 0
mirror of https://github.com/actix/actix-web.git synced 2024-07-04 04:55:48 +00:00

update cargo files

This commit is contained in:
Nikolay Kim 2019-03-26 12:50:51 -07:00
parent 50c0ddb3cd
commit 9451ba71f4
10 changed files with 48 additions and 41 deletions

View file

@ -107,7 +107,7 @@ openssl = { version="0.10", optional = true }
[dev-dependencies] [dev-dependencies]
actix-http = { path = "actix-http", features=["ssl"] } actix-http = { path = "actix-http", features=["ssl"] }
actix-http-test = { path = "actix-http/test-server", features=["ssl"] } actix-http-test = { path = "test-server", features=["ssl"] }
rand = "0.6" rand = "0.6"
env_logger = "0.6" env_logger = "0.6"
serde_derive = "1.0" serde_derive = "1.0"

View file

@ -1,13 +1,13 @@
[package] [package]
name = "actix-files" name = "actix-files"
version = "0.1.0" version = "0.1.0-alpha.1"
authors = ["Nikolay Kim <fafhrd91@gmail.com>"] authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
description = "Static files support for Actix web." description = "Static files support for Actix web."
readme = "README.md" readme = "README.md"
keywords = ["actix", "http", "async", "futures"] keywords = ["actix", "http", "async", "futures"]
homepage = "https://actix.rs" homepage = "https://actix.rs"
repository = "https://github.com/actix/actix-web.git" repository = "https://github.com/actix/actix-web.git"
documentation = "https://actix.rs/api/actix-web/stable/actix_web/" documentation = "https://docs.rs/actix-files/"
categories = ["asynchronous", "web-programming::http-server"] categories = ["asynchronous", "web-programming::http-server"]
license = "MIT/Apache-2.0" license = "MIT/Apache-2.0"
edition = "2018" edition = "2018"
@ -19,7 +19,7 @@ path = "src/lib.rs"
[dependencies] [dependencies]
actix-web = { path=".." } actix-web = { path=".." }
actix-http = { git = "https://github.com/actix/actix-http.git" } actix-http = { path="../actix-http" }
actix-service = "0.3.3" actix-service = "0.3.3"
bitflags = "1" bitflags = "1"

View file

@ -1,6 +1,6 @@
[package] [package]
name = "actix-http" name = "actix-http"
version = "0.1.0" version = "0.1.0-alpha.1"
authors = ["Nikolay Kim <fafhrd91@gmail.com>"] authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
description = "Actix http" description = "Actix http"
readme = "README.md" readme = "README.md"
@ -20,9 +20,8 @@ workspace = ".."
features = ["ssl", "fail", "cookie"] features = ["ssl", "fail", "cookie"]
[badges] [badges]
travis-ci = { repository = "actix/actix-http", branch = "master" } travis-ci = { repository = "actix/actix-web", branch = "master" }
# appveyor = { repository = "fafhrd91/actix-http-b1qsn" } codecov = { repository = "actix/actix-web", branch = "master", service = "github" }
codecov = { repository = "actix/actix-http", branch = "master", service = "github" }
[lib] [lib]
name = "actix_http" name = "actix_http"
@ -87,7 +86,7 @@ openssl = { version="0.10", optional = true }
actix-rt = "0.2.1" actix-rt = "0.2.1"
actix-server = { version = "0.4.0", features=["ssl"] } actix-server = { version = "0.4.0", features=["ssl"] }
actix-connect = { version = "0.1.0", features=["ssl"] } actix-connect = { version = "0.1.0", features=["ssl"] }
actix-http-test = { path="test-server", features=["ssl"] } actix-http-test = { path="../test-server", features=["ssl"] }
env_logger = "0.6" env_logger = "0.6"
serde_derive = "1.0" serde_derive = "1.0"

View file

@ -1,13 +1,13 @@
[package] [package]
name = "actix-session" name = "actix-session"
version = "0.1.0" version = "0.1.0-alpha.1"
authors = ["Nikolay Kim <fafhrd91@gmail.com>"] authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
description = "Session for actix web framework." description = "Session for actix web framework."
readme = "README.md" readme = "README.md"
keywords = ["http", "web", "framework", "async", "futures"] keywords = ["http", "web", "framework", "async", "futures"]
homepage = "https://actix.rs" homepage = "https://actix.rs"
repository = "https://github.com/actix/actix-web.git" repository = "https://github.com/actix/actix-web.git"
documentation = "https://docs.rs/actix-web/" documentation = "https://docs.rs/actix-session/"
license = "MIT/Apache-2.0" license = "MIT/Apache-2.0"
exclude = [".gitignore", ".travis.yml", ".cargo/config", "appveyor.yml"] exclude = [".gitignore", ".travis.yml", ".cargo/config", "appveyor.yml"]
workspace = ".." workspace = ".."

View file

@ -1,6 +1,6 @@
[package] [package]
name = "actix-web-actors" name = "actix-web-actors"
version = "0.1.0" version = "0.1.0-alpha.1"
authors = ["Nikolay Kim <fafhrd91@gmail.com>"] authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
description = "Actix actors support for actix web framework." description = "Actix actors support for actix web framework."
readme = "README.md" readme = "README.md"
@ -20,12 +20,12 @@ path = "src/lib.rs"
[dependencies] [dependencies]
actix-web = { path=".." } actix-web = { path=".." }
actix = { git = "https://github.com/actix/actix.git" } actix = { git = "https://github.com/actix/actix.git" }
actix-http = { git = "https://github.com/actix/actix-http.git" } actix-http = { path = "../actix-http/" }
actix-codec = "0.1.1" actix-codec = "0.1.1"
bytes = "0.4" bytes = "0.4"
futures = "0.1" futures = "0.1"
[dev-dependencies] [dev-dependencies]
env_logger = "0.6" env_logger = "0.6"
actix-http = { git = "https://github.com/actix/actix-http.git", features=["ssl"] } actix-http = { path = "../actix-http/", features=["ssl"] }
actix-http-test = { git = "https://github.com/actix/actix-http.git", features=["ssl"] } actix-http-test = { path = "../test-server/", features=["ssl"] }

View file

@ -1,7 +1,7 @@
[package] [package]
name = "actix-web-codegen" name = "actix-web-codegen"
description = "Actix web codegen macros" description = "Actix web codegen macros"
version = "0.1.0" version = "0.1.0-alpha.1"
authors = ["Nikolay Kim <fafhrd91@gmail.com>"] authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
license = "MIT/Apache-2.0" license = "MIT/Apache-2.0"
edition = "2018" edition = "2018"
@ -16,5 +16,5 @@ syn = { version = "0.15", features = ["full", "parsing"] }
[dev-dependencies] [dev-dependencies]
actix-web = { path = ".." } actix-web = { path = ".." }
actix-http = { git = "https://github.com/actix/actix-http.git", features=["ssl"] } actix-http = { path = "../actix-http/", features=["ssl"] }
actix-http-test = { git = "https://github.com/actix/actix-http.git", features=["ssl"] } actix-http-test = { path = "../test-server/", features=["ssl"] }

View file

@ -1,6 +1,6 @@
use actix_http::HttpService; use actix_http::HttpService;
use actix_http_test::TestServer; use actix_http_test::TestServer;
use actix_web::{get, App, HttpResponse, Responder}; use actix_web::{get, http, App, HttpResponse, Responder};
#[get("/test")] #[get("/test")]
fn test() -> impl Responder { fn test() -> impl Responder {
@ -11,7 +11,7 @@ fn test() -> impl Responder {
fn test_body() { fn test_body() {
let mut srv = TestServer::new(|| HttpService::new(App::new().service(test))); let mut srv = TestServer::new(|| HttpService::new(App::new().service(test)));
let request = srv.get().uri(srv.url("/test")).finish().unwrap(); let request = srv.request(http::Method::GET, srv.url("/test"));
let response = srv.send_request(request).unwrap(); let response = srv.block_on(request.send()).unwrap();
assert!(response.status().is_success()); assert!(response.status().is_success());
} }

View file

@ -1,6 +1,6 @@
[package] [package]
name = "awc" name = "awc"
version = "0.1.0" version = "0.1.0-alpha.1"
authors = ["Nikolay Kim <fafhrd91@gmail.com>"] authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
description = "Actix web client." description = "Actix web client."
readme = "README.md" readme = "README.md"
@ -45,4 +45,4 @@ env_logger = "0.6"
mime = "0.3" mime = "0.3"
actix-rt = "0.2.1" actix-rt = "0.2.1"
actix-http = { path = "../actix-http/", features=["ssl"] } actix-http = { path = "../actix-http/", features=["ssl"] }
actix-http-test = { path = "../actix-http/test-server/", features=["ssl"] } actix-http-test = { path = "../test-server/", features=["ssl"] }

View file

@ -1,19 +1,20 @@
[package] [package]
name = "actix-http-test" name = "actix-http-test"
version = "0.1.0" version = "0.1.0-alpha.1"
authors = ["Nikolay Kim <fafhrd91@gmail.com>"] authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
description = "Actix http" description = "Actix http test server"
readme = "README.md" readme = "README.md"
keywords = ["http", "web", "framework", "async", "futures"] keywords = ["http", "web", "framework", "async", "futures"]
homepage = "https://actix.rs" homepage = "https://actix.rs"
repository = "https://github.com/actix/actix-web.git" repository = "https://github.com/actix/actix-web.git"
documentation = "https://actix.rs/api/actix-web/stable/actix_web/" documentation = "https://docs.rs/actix-http-test/"
categories = ["network-programming", "asynchronous", categories = ["network-programming", "asynchronous",
"web-programming::http-server", "web-programming::http-server",
"web-programming::websocket"] "web-programming::websocket"]
license = "MIT/Apache-2.0" license = "MIT/Apache-2.0"
exclude = [".gitignore", ".travis.yml", ".cargo/config", "appveyor.yml"] exclude = [".gitignore", ".travis.yml", ".cargo/config", "appveyor.yml"]
edition = "2018" edition = "2018"
workspace = ".."
[package.metadata.docs.rs] [package.metadata.docs.rs]
features = ["session"] features = ["session"]
@ -34,11 +35,11 @@ ssl = ["openssl", "actix-http/ssl", "actix-server/ssl", "awc/ssl"]
[dependencies] [dependencies]
actix-codec = "0.1.1" actix-codec = "0.1.1"
actix-rt = "0.2.1" actix-rt = "0.2.1"
actix-http = { path=".." } actix-http = { path="../actix-http" }
actix-service = "0.3.4" actix-service = "0.3.4"
actix-server = "0.4.0" actix-server = "0.4.0"
actix-utils = "0.3.4" actix-utils = "0.3.4"
awc = { path = "../../awc" } awc = { path = "../awc" }
base64 = "0.10" base64 = "0.10"
bytes = "0.4" bytes = "0.4"
@ -58,3 +59,6 @@ tokio-tcp = "0.1"
tokio-timer = "0.2" tokio-timer = "0.2"
openssl = { version="0.10", optional = true } openssl = { version="0.10", optional = true }
[dev-dependencies]
actix-web = { path=".." }

View file

@ -21,22 +21,26 @@ use net2::TcpBuilder;
/// # Examples /// # Examples
/// ///
/// ```rust /// ```rust
/// # extern crate actix_web; /// use actix_http::HttpService;
/// # use actix_web::*; /// use actix_http_test::TestServer;
/// use actix_web::{web, App, HttpResponse};
/// # /// #
/// # fn my_handler(req: &HttpRequest) -> HttpResponse { /// fn my_handler() -> HttpResponse {
/// # HttpResponse::Ok().into() /// HttpResponse::Ok().into()
/// # } /// }
/// #
/// # fn main() {
/// use actix_web::test::TestServer;
/// ///
/// let mut srv = TestServer::new(|app| app.handler(my_handler)); /// fn main() {
/// let mut srv = TestServer::new(
/// || HttpService::new(
/// App::new().service(
/// web::resource("/").to(my_handler))
/// )
/// );
/// ///
/// let req = srv.get().finish().unwrap(); /// let req = srv.get();
/// let response = srv.execute(req.send()).unwrap(); /// let response = srv.block_on(req.send()).unwrap();
/// assert!(response.status().is_success()); /// assert!(response.status().is_success());
/// # } /// }
/// ``` /// ```
pub struct TestServer; pub struct TestServer;