Skip to content

Commit

Permalink
oops
Browse files Browse the repository at this point in the history
  • Loading branch information
masad-frost committed Dec 9, 2021
1 parent 5853330 commit 8083a16
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/plugins/test_yapf_format.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,23 +65,23 @@ def test_config_file(tmpdir, workspace):

def test_format_with_tab_size_option(workspace):
doc = Document(DOC_URI, workspace, FOUR_SPACE_DOC)
res = pyls_format_document(doc, { "tabSize": "8" })
res = pylsp_format_document(doc, { "tabSize": "8" })

assert len(res) == 1
assert res[0]['newText'] == FOUR_SPACE_DOC.replace(" ", " ")


def test_format_with_insert_spaces_option(workspace):
doc = Document(DOC_URI, workspace, FOUR_SPACE_DOC)
res = pyls_format_document(doc, { "insertSpaces": False })
res = pylsp_format_document(doc, { "insertSpaces": False })

assert len(res) == 1
assert res[0]['newText'] == FOUR_SPACE_DOC.replace(" ", "\t")


def test_format_with_yapf_specific_option(workspace):
doc = Document(DOC_URI, workspace, FOUR_SPACE_DOC)
res = pyls_format_document(doc, { "USE_TABS": True })
res = pylsp_format_document(doc, { "USE_TABS": True })

assert len(res) == 1
assert res[0]['newText'] == FOUR_SPACE_DOC.replace(" ", "\t")

0 comments on commit 8083a16

Please sign in to comment.