diff options
author | Aleksey Kladov <[email protected]> | 2020-03-17 09:46:46 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2020-03-17 10:42:54 +0000 |
commit | de7662c852353febce09196199202ee7f6e8e6c3 (patch) | |
tree | ff98e8e779dfe2c7e2a3eebf84dca6020f5db1b2 /crates/ra_hir_def/src/nameres/tests/globs.rs | |
parent | 089c5547709bb8e7e60388c4f9a5e25c394c1f39 (diff) |
Check that no file contains trailing ws
rustfmt allows trailing spaces in string literals unfortunately.
Diffstat (limited to 'crates/ra_hir_def/src/nameres/tests/globs.rs')
-rw-r--r-- | crates/ra_hir_def/src/nameres/tests/globs.rs | 92 |
1 files changed, 46 insertions, 46 deletions
diff --git a/crates/ra_hir_def/src/nameres/tests/globs.rs b/crates/ra_hir_def/src/nameres/tests/globs.rs index 71fa0abe8..ee8df3a26 100644 --- a/crates/ra_hir_def/src/nameres/tests/globs.rs +++ b/crates/ra_hir_def/src/nameres/tests/globs.rs | |||
@@ -3,7 +3,7 @@ use super::*; | |||
3 | #[test] | 3 | #[test] |
4 | fn glob_1() { | 4 | fn glob_1() { |
5 | let map = def_map( | 5 | let map = def_map( |
6 | " | 6 | r" |
7 | //- /lib.rs | 7 | //- /lib.rs |
8 | mod foo; | 8 | mod foo; |
9 | use foo::*; | 9 | use foo::*; |
@@ -76,7 +76,7 @@ fn glob_2() { | |||
76 | #[test] | 76 | #[test] |
77 | fn glob_privacy_1() { | 77 | fn glob_privacy_1() { |
78 | let map = def_map( | 78 | let map = def_map( |
79 | " | 79 | r" |
80 | //- /lib.rs | 80 | //- /lib.rs |
81 | mod foo; | 81 | mod foo; |
82 | use foo::*; | 82 | use foo::*; |
@@ -93,21 +93,21 @@ fn glob_privacy_1() { | |||
93 | ", | 93 | ", |
94 | ); | 94 | ); |
95 | assert_snapshot!(map, @r###" | 95 | assert_snapshot!(map, @r###" |
96 | crate | 96 | ⋮crate |
97 | Baz: t v | 97 | ⋮Baz: t v |
98 | bar: t | 98 | ⋮bar: t |
99 | foo: t | 99 | ⋮foo: t |
100 | 100 | ⋮ | |
101 | crate::foo | 101 | ⋮crate::foo |
102 | Baz: t v | 102 | ⋮Baz: t v |
103 | PrivateStructFoo: t v | 103 | ⋮PrivateStructFoo: t v |
104 | bar: t | 104 | ⋮bar: t |
105 | 105 | ⋮ | |
106 | crate::foo::bar | 106 | ⋮crate::foo::bar |
107 | Baz: t v | 107 | ⋮Baz: t v |
108 | PrivateStructBar: t v | 108 | ⋮PrivateStructBar: t v |
109 | PrivateStructFoo: t v | 109 | ⋮PrivateStructFoo: t v |
110 | bar: t | 110 | ⋮bar: t |
111 | "### | 111 | "### |
112 | ); | 112 | ); |
113 | } | 113 | } |
@@ -115,7 +115,7 @@ fn glob_privacy_1() { | |||
115 | #[test] | 115 | #[test] |
116 | fn glob_privacy_2() { | 116 | fn glob_privacy_2() { |
117 | let map = def_map( | 117 | let map = def_map( |
118 | " | 118 | r" |
119 | //- /lib.rs | 119 | //- /lib.rs |
120 | mod foo; | 120 | mod foo; |
121 | use foo::*; | 121 | use foo::*; |
@@ -133,19 +133,19 @@ fn glob_privacy_2() { | |||
133 | ", | 133 | ", |
134 | ); | 134 | ); |
135 | assert_snapshot!(map, @r###" | 135 | assert_snapshot!(map, @r###" |
136 | crate | 136 | ⋮crate |
137 | Foo: t | 137 | ⋮Foo: t |
138 | PubCrateStruct: t v | 138 | ⋮PubCrateStruct: t v |
139 | foo: t | 139 | ⋮foo: t |
140 | 140 | ⋮ | |
141 | crate::foo | 141 | ⋮crate::foo |
142 | Foo: t v | 142 | ⋮Foo: t v |
143 | bar: t | 143 | ⋮bar: t |
144 | 144 | ⋮ | |
145 | crate::foo::bar | 145 | ⋮crate::foo::bar |
146 | PrivateBar: t v | 146 | ⋮PrivateBar: t v |
147 | PrivateBaz: t v | 147 | ⋮PrivateBaz: t v |
148 | PubCrateStruct: t v | 148 | ⋮PubCrateStruct: t v |
149 | "### | 149 | "### |
150 | ); | 150 | ); |
151 | } | 151 | } |
@@ -154,7 +154,7 @@ fn glob_privacy_2() { | |||
154 | fn glob_across_crates() { | 154 | fn glob_across_crates() { |
155 | covers!(glob_across_crates); | 155 | covers!(glob_across_crates); |
156 | let map = def_map( | 156 | let map = def_map( |
157 | " | 157 | r" |
158 | //- /main.rs crate:main deps:test_crate | 158 | //- /main.rs crate:main deps:test_crate |
159 | use test_crate::*; | 159 | use test_crate::*; |
160 | 160 | ||
@@ -163,8 +163,8 @@ fn glob_across_crates() { | |||
163 | ", | 163 | ", |
164 | ); | 164 | ); |
165 | assert_snapshot!(map, @r###" | 165 | assert_snapshot!(map, @r###" |
166 | ⋮crate | 166 | ⋮crate |
167 | ⋮Baz: t v | 167 | ⋮Baz: t v |
168 | "### | 168 | "### |
169 | ); | 169 | ); |
170 | } | 170 | } |
@@ -173,7 +173,7 @@ fn glob_across_crates() { | |||
173 | fn glob_privacy_across_crates() { | 173 | fn glob_privacy_across_crates() { |
174 | covers!(glob_across_crates); | 174 | covers!(glob_across_crates); |
175 | let map = def_map( | 175 | let map = def_map( |
176 | " | 176 | r" |
177 | //- /main.rs crate:main deps:test_crate | 177 | //- /main.rs crate:main deps:test_crate |
178 | use test_crate::*; | 178 | use test_crate::*; |
179 | 179 | ||
@@ -183,8 +183,8 @@ fn glob_privacy_across_crates() { | |||
183 | ", | 183 | ", |
184 | ); | 184 | ); |
185 | assert_snapshot!(map, @r###" | 185 | assert_snapshot!(map, @r###" |
186 | ⋮crate | 186 | ⋮crate |
187 | ⋮Baz: t v | 187 | ⋮Baz: t v |
188 | "### | 188 | "### |
189 | ); | 189 | ); |
190 | } | 190 | } |
@@ -202,10 +202,10 @@ fn glob_enum() { | |||
202 | ", | 202 | ", |
203 | ); | 203 | ); |
204 | assert_snapshot!(map, @r###" | 204 | assert_snapshot!(map, @r###" |
205 | ⋮crate | 205 | ⋮crate |
206 | ⋮Bar: t v | 206 | ⋮Bar: t v |
207 | ⋮Baz: t v | 207 | ⋮Baz: t v |
208 | ⋮Foo: t | 208 | ⋮Foo: t |
209 | "### | 209 | "### |
210 | ); | 210 | ); |
211 | } | 211 | } |
@@ -214,7 +214,7 @@ fn glob_enum() { | |||
214 | fn glob_enum_group() { | 214 | fn glob_enum_group() { |
215 | covers!(glob_enum_group); | 215 | covers!(glob_enum_group); |
216 | let map = def_map( | 216 | let map = def_map( |
217 | " | 217 | r" |
218 | //- /lib.rs | 218 | //- /lib.rs |
219 | enum Foo { | 219 | enum Foo { |
220 | Bar, Baz | 220 | Bar, Baz |
@@ -223,10 +223,10 @@ fn glob_enum_group() { | |||
223 | ", | 223 | ", |
224 | ); | 224 | ); |
225 | assert_snapshot!(map, @r###" | 225 | assert_snapshot!(map, @r###" |
226 | ⋮crate | 226 | ⋮crate |
227 | ⋮Bar: t v | 227 | ⋮Bar: t v |
228 | ⋮Baz: t v | 228 | ⋮Baz: t v |
229 | ⋮Foo: t | 229 | ⋮Foo: t |
230 | "### | 230 | "### |
231 | ); | 231 | ); |
232 | } | 232 | } |