diff options
author | David Tolnay <dtolnay@gmail.com> | 2019-04-20 13:36:18 -0700 |
---|---|---|
committer | David Tolnay <dtolnay@gmail.com> | 2019-04-20 13:36:18 -0700 |
commit | 637eef4264ee0e579b222dc6f31b3656fdbe90e1 (patch) | |
tree | 407fd096a3f7ae11117eb5ca9809c59c31880ec2 /tests/test.rs | |
parent | 5a2f730055113da243475b24752540ce61abccd3 (diff) | |
download | proc-macro2-637eef4264ee0e579b222dc6f31b3656fdbe90e1.tar.gz |
Rename private functions to match rename of Term to Ident
Diffstat (limited to 'tests/test.rs')
-rw-r--r-- | tests/test.rs | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/test.rs b/tests/test.rs index 426313a..f5660c0 100644 --- a/tests/test.rs +++ b/tests/test.rs @@ -5,7 +5,7 @@ use std::str::{self, FromStr}; use proc_macro2::{Ident, Literal, Spacing, Span, TokenStream, TokenTree}; #[test] -fn terms() { +fn idents() { assert_eq!( Ident::new("String", Span::call_site()).to_string(), "String" @@ -16,7 +16,7 @@ fn terms() { #[test] #[cfg(procmacro2_semver_exempt)] -fn raw_terms() { +fn raw_idents() { assert_eq!( Ident::new_raw("String", Span::call_site()).to_string(), "r#String" @@ -27,37 +27,37 @@ fn raw_terms() { #[test] #[should_panic(expected = "Ident is not allowed to be empty; use Option<Ident>")] -fn term_empty() { +fn ident_empty() { Ident::new("", Span::call_site()); } #[test] #[should_panic(expected = "Ident cannot be a number; use Literal instead")] -fn term_number() { +fn ident_number() { Ident::new("255", Span::call_site()); } #[test] #[should_panic(expected = "\"a#\" is not a valid Ident")] -fn term_invalid() { +fn ident_invalid() { Ident::new("a#", Span::call_site()); } #[test] #[should_panic(expected = "not a valid Ident")] -fn raw_term_empty() { +fn raw_ident_empty() { Ident::new("r#", Span::call_site()); } #[test] #[should_panic(expected = "not a valid Ident")] -fn raw_term_number() { +fn raw_ident_number() { Ident::new("r#255", Span::call_site()); } #[test] #[should_panic(expected = "\"r#a#\" is not a valid Ident")] -fn raw_term_invalid() { +fn raw_ident_invalid() { Ident::new("r#a#", Span::call_site()); } |