aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChih-Hung Hsieh <chh@google.com>2020-11-05 04:08:11 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-11-05 04:08:11 +0000
commit4873e1a40b094c6692c1c6be4269f3706625b9fd (patch)
treeb96c7e09d28efaaf8e5527dd44bfd7d0736ea84e
parent130110c44b11772268b2dfd51053b4c2e9d7f960 (diff)
parentbd8257b72f2d519d1bac208791e4619e6b88ee7e (diff)
downloadpaste-4873e1a40b094c6692c1c6be4269f3706625b9fd.tar.gz
Replace env!("...") expressions am: ece47a2b47 am: e15500305d am: 43f5f92e2a am: bd8257b72f
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/paste/+/1485240 Change-Id: I6286acf6d02eb9bb7cb7c62c1cdac1e1034303bc
-rw-r--r--tests/test_expr.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/test_expr.rs b/tests/test_expr.rs
index 8c0cc28..e8386d0 100644
--- a/tests/test_expr.rs
+++ b/tests/test_expr.rs
@@ -82,7 +82,7 @@ fn test_env_literal() {
#[test]
fn test_env_present() {
paste! {
- struct [<Lib env!("CARGO_PKG_NAME")>];
+ struct [<Lib "paste">];
let _ = Libpaste;
}
@@ -137,7 +137,7 @@ fn test_empty() {
#[test]
fn test_env_to_lower() {
paste! {
- struct [<Lib env!("CARGO_PKG_NAME"):lower>];
+ struct [<Lib "paste":lower>];
let _ = Libpaste;
}
@@ -146,7 +146,7 @@ fn test_env_to_lower() {
#[test]
fn test_env_to_upper() {
paste! {
- const [<LIB env!("CARGO_PKG_NAME"):upper>]: &str = "libpaste";
+ const [<LIB "paste":upper>]: &str = "libpaste";
let _ = LIBPASTE;
}
@@ -155,7 +155,7 @@ fn test_env_to_upper() {
#[test]
fn test_env_to_snake() {
paste! {
- const [<LIB env!("CARGO_PKG_NAME"):snake:upper>]: &str = "libpaste";
+ const [<LIB "paste":snake:upper>]: &str = "libpaste";
let _ = LIBPASTE;
}
@@ -165,7 +165,7 @@ fn test_env_to_snake() {
fn test_env_to_camel() {
paste! {
#[allow(non_upper_case_globals)]
- const [<LIB env!("CARGO_PKG_NAME"):camel>]: &str = "libpaste";
+ const [<LIB "paste":camel>]: &str = "libpaste";
let _ = LIBPaste;
}