mirror of
https://github.com/ntex-rs/ntex.git
synced 2025-04-03 04:47:39 +03:00
fix runtime macros
This commit is contained in:
parent
2d8ce48456
commit
055bd730d4
17 changed files with 43 additions and 39 deletions
|
@ -1,5 +1,9 @@
|
|||
# Changes
|
||||
|
||||
## [0.1.2] - 2021-02-25
|
||||
|
||||
* Export runtime from ntex crate
|
||||
|
||||
## [0.1.1] - 2021-02-25
|
||||
|
||||
* Move `main` and `test` macros from rt macros
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[package]
|
||||
name = "ntex-macros"
|
||||
version = "0.1.1"
|
||||
version = "0.1.2"
|
||||
description = "ntex proc macros"
|
||||
readme = "README.md"
|
||||
authors = ["ntex contributors <team@ntex.rs>"]
|
||||
|
|
|
@ -216,7 +216,7 @@ pub fn rt_main(_: TokenStream, item: TokenStream) -> TokenStream {
|
|||
(quote! {
|
||||
#(#attrs)*
|
||||
#vis #sig {
|
||||
ntex_rt::System::new(stringify!(#name))
|
||||
ntex::rt::System::new(stringify!(#name))
|
||||
.block_on(async move { #body })
|
||||
}
|
||||
})
|
||||
|
@ -262,7 +262,7 @@ pub fn rt_test(_: TokenStream, item: TokenStream) -> TokenStream {
|
|||
quote! {
|
||||
#(#attrs)*
|
||||
fn #name() #ret {
|
||||
ntex_rt::System::new("test")
|
||||
ntex::rt::System::new("test")
|
||||
.block_on(async { #body })
|
||||
}
|
||||
}
|
||||
|
@ -271,7 +271,7 @@ pub fn rt_test(_: TokenStream, item: TokenStream) -> TokenStream {
|
|||
#[test]
|
||||
#(#attrs)*
|
||||
fn #name() #ret {
|
||||
ntex_rt::System::new("test")
|
||||
ntex::rt::System::new("test")
|
||||
.block_on(async { #body })
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue