From 7a06282d71d41508f30a9b7513eecfba998b9aa9 Mon Sep 17 00:00:00 2001 From: memoryruins Date: Thu, 28 Mar 2019 12:15:44 -0400 Subject: Add tests to ra_syntax for extern_crate_self --- .../ra_syntax/tests/data/parser/ok/0007_extern_crate.rs | 1 + .../tests/data/parser/ok/0007_extern_crate.txt | 17 ++++++++++++++++- 2 files changed, 17 insertions(+), 1 deletion(-) (limited to 'crates/ra_syntax/tests/data/parser') diff --git a/crates/ra_syntax/tests/data/parser/ok/0007_extern_crate.rs b/crates/ra_syntax/tests/data/parser/ok/0007_extern_crate.rs index 3ce336676..ab81a608c 100644 --- a/crates/ra_syntax/tests/data/parser/ok/0007_extern_crate.rs +++ b/crates/ra_syntax/tests/data/parser/ok/0007_extern_crate.rs @@ -1,2 +1,3 @@ extern crate foo; extern crate foo as bar; +extern crate self as baz; diff --git a/crates/ra_syntax/tests/data/parser/ok/0007_extern_crate.txt b/crates/ra_syntax/tests/data/parser/ok/0007_extern_crate.txt index 5558d952e..0176260c1 100644 --- a/crates/ra_syntax/tests/data/parser/ok/0007_extern_crate.txt +++ b/crates/ra_syntax/tests/data/parser/ok/0007_extern_crate.txt @@ -1,4 +1,4 @@ -SOURCE_FILE@[0; 43) +SOURCE_FILE@[0; 69) EXTERN_CRATE_ITEM@[0; 17) EXTERN_KW@[0; 6) WHITESPACE@[6; 7) @@ -23,3 +23,18 @@ SOURCE_FILE@[0; 43) IDENT@[38; 41) "bar" SEMI@[41; 42) WHITESPACE@[42; 43) + EXTERN_CRATE_ITEM@[43; 68) + EXTERN_KW@[43; 49) + WHITESPACE@[49; 50) + CRATE_KW@[50; 55) + WHITESPACE@[55; 56) + SELF_KW@[56; 60) + SELF_KW@[56; 60) + WHITESPACE@[60; 61) + ALIAS@[61; 67) + AS_KW@[61; 63) + WHITESPACE@[63; 64) + NAME@[64; 67) + IDENT@[64; 67) "baz" + SEMI@[67; 68) + WHITESPACE@[68; 69) -- cgit v1.2.3