Skip to content

Commit

Permalink
Fix LSP completion tests
Browse files Browse the repository at this point in the history
  • Loading branch information
crai0 committed Mar 6, 2025
1 parent efdb96e commit 8f2d668
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions tools/lsp/language/completion.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1183,7 +1183,7 @@ mod tests {
);
assert_eq!(
res.iter().find(|ci| ci.label == "the-callback").unwrap().insert_text,
Some("the-callback => {$1}".into())
Some("the-callback => $1".into())
);
}

Expand Down Expand Up @@ -1659,7 +1659,7 @@ mod tests {
// builtin callback don't have named argument yet
assert_eq!(
res.iter().find(|ci| ci.label == "accessible-action-set-value").unwrap().insert_text,
Some("accessible-action-set-value => {$1}".into())
Some("accessible-action-set-value => $1".into())
);
let source = r#"
import { StandardTableView } from "std-widgets.slint";
Expand All @@ -1681,19 +1681,19 @@ mod tests {
);
assert_eq!(
res.iter().find(|ci| ci.label == "clicked").unwrap().insert_text,
Some("clicked => {$1}".into())
Some("clicked => $1".into())
);
assert_eq!(
res.iter().find(|ci| ci.label == "cb1").unwrap().insert_text,
Some("cb1 => {$1}".into())
Some("cb1 => $1".into())
);
assert_eq!(
res.iter().find(|ci| ci.label == "cb2").unwrap().insert_text,
Some("cb2(foo, bar-bar) => {$1}".into())
);
assert_eq!(
res.iter().find(|ci| ci.label == "cb3").unwrap().insert_text,
Some("cb3 => {$1}".into())
Some("cb3 => $1".into())
);
}
}

0 comments on commit 8f2d668

Please sign in to comment.