-
-
Notifications
You must be signed in to change notification settings - Fork 83
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added tests for recently-fixed Kotlin functionality. (#2668)
Added tests for #2642 ## Checklist - [x] I have added [tests](https://www.cursorless.org/docs/contributing/test-case-recorder/) - [x] I have updated the [docs](https://github.com/cursorless-dev/cursorless/tree/main/docs) and [cheatsheet](https://github.com/cursorless-dev/cursorless/tree/main/cursorless-talon/src/cheatsheet) - [x] I have not broken the cheatsheet
- Loading branch information
1 parent
e52a08c
commit 8970637
Showing
3 changed files
with
64 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
languageId: kotlin | ||
command: | ||
version: 7 | ||
spokenForm: change call | ||
action: | ||
name: clearAndSetSelection | ||
target: | ||
type: primitive | ||
modifiers: | ||
- type: containingScope | ||
scopeType: {type: functionCall} | ||
usePrePhraseSnapshot: true | ||
initialState: | ||
documentContents: |- | ||
fun main() { | ||
val s = "test" | ||
val l = with (s) { length } | ||
println(l) | ||
} | ||
selections: | ||
- anchor: {line: 2, character: 14} | ||
active: {line: 2, character: 14} | ||
marks: {} | ||
finalState: | ||
documentContents: |- | ||
fun main() { | ||
val s = "test" | ||
val l = | ||
println(l) | ||
} | ||
selections: | ||
- anchor: {line: 2, character: 12} | ||
active: {line: 2, character: 12} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
languageId: kotlin | ||
command: | ||
version: 7 | ||
spokenForm: change value | ||
action: | ||
name: clearAndSetSelection | ||
target: | ||
type: primitive | ||
modifiers: | ||
- type: containingScope | ||
scopeType: {type: value} | ||
usePrePhraseSnapshot: true | ||
initialState: | ||
documentContents: |- | ||
fun main() { | ||
val n = null | ||
println(n) | ||
} | ||
selections: | ||
- anchor: {line: 1, character: 8} | ||
active: {line: 1, character: 8} | ||
marks: {} | ||
finalState: | ||
documentContents: |- | ||
fun main() { | ||
val n = | ||
println(n) | ||
} | ||
selections: | ||
- anchor: {line: 1, character: 12} | ||
active: {line: 1, character: 12} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters