File tree Expand file tree Collapse file tree 1 file changed +5
-22
lines changed
compiler-core/src/language_server/tests Expand file tree Collapse file tree 1 file changed +5
-22
lines changed Original file line number Diff line number Diff line change @@ -10688,24 +10688,6 @@ pub fn main() -> Nil {
10688
10688
) ;
10689
10689
}
10690
10690
10691
- #[ test]
10692
- fn annotate_all_top_level_definitions_dont_affect_local_vars( ) {
10693
- assert_code_action ! (
10694
- ANNOTATE_TOP_LEVEL_DEFINITIONS ,
10695
- r#"
10696
- pub const answer = 42
10697
-
10698
- pub fn add_two(thing) {
10699
- thing + 2
10700
-
10701
- pub fn add_one(thing) {
10702
- let result = thing + 1
10703
- result
10704
- }
10705
- "# ,
10706
- find_position_of( "fn" ) . select_until( find_position_of( "(" ) ) ;
10707
- }
10708
-
10709
10691
#[ test]
10710
10692
fn annotate_all_top_level_definitions_constant ( ) {
10711
10693
assert_code_action ! (
@@ -10728,20 +10710,21 @@ pub fn add_one(thing) {
10728
10710
#[ test]
10729
10711
fn annotate_all_top_level_definitions_function ( ) {
10730
10712
assert_code_action ! (
10731
- ANNOTATE_TOP_LEVEL_TYPE_DEFINITIONS ,
10713
+ ANNOTATE_TOP_LEVEL_DEFINITIONS ,
10732
10714
r#"
10733
10715
pub fn add_two(thing) {
10734
- thing + 2
10716
+ thing + 2
10735
10717
}
10736
10718
10737
10719
pub fn add_one(thing) {
10738
- thing + 1
10720
+ thing + 1
10739
10721
}
10740
- "#,
10722
+ "# ,
10741
10723
find_position_of( "fn" ) . select_until( find_position_of( "(" ) )
10742
10724
) ;
10743
10725
}
10744
10726
10727
+ #[ test]
10745
10728
fn annotate_all_top_level_definitions_already_annotated ( ) {
10746
10729
assert_no_code_actions ! (
10747
10730
ANNOTATE_TOP_LEVEL_DEFINITIONS ,
You can’t perform that action at this time.
0 commit comments