Skip to content

Commit 4383f1e

Browse files
committed
test against a specific action
1 parent 4c89036 commit 4383f1e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/plugins/test_importmagic_lint.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ def test_importmagic_actions(config):
5555

5656
try:
5757
name, doc = temp_document(DOC)
58-
action = importmagic_lint.pyls_code_actions(config, doc, context)[0]
58+
actions = importmagic_lint.pyls_code_actions(config, doc, context)
59+
action = [a for a in actions if a['title'] == 'Import "listdir" from "os"'][0]
5960
arguments = action['arguments']
6061

61-
assert action['title'] == 'Import "listdir" from "os"'
6262
assert action['command'] == 'importmagic.addimport'
6363
assert arguments['startLine'] == 1
6464
assert arguments['endLine'] == 1

0 commit comments

Comments
 (0)