Skip to content

Commit cc02dee

Browse files
committed
test(completion): update installation instructions to shtab --print-completion for bash/zsh/fish
1 parent ac0cc0e commit cc02dee

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

tests/test_completion_command.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ def test_completion_install_bash_explicit():
2121
cmd._install(args)
2222
out = _gather_print_output(mock_print)
2323
assert "Detected shell: bash" in out
24-
assert "register-python-argcomplete struct" in out
25-
assert "~/.bashrc" in out
24+
assert "struct --print-completion bash" in out
25+
assert "~/.local/share/bash-completion/completions/struct" in out
2626

2727

2828
def test_completion_install_zsh_explicit():
@@ -33,8 +33,8 @@ def test_completion_install_zsh_explicit():
3333
cmd._install(args)
3434
out = _gather_print_output(mock_print)
3535
assert "Detected shell: zsh" in out
36-
assert "register-python-argcomplete --shell zsh struct" in out
37-
assert "~/.zshrc" in out
36+
assert "struct --print-completion zsh" in out
37+
assert "~/.zfunc/_struct" in out
3838

3939

4040
def test_completion_install_fish_explicit():
@@ -45,7 +45,7 @@ def test_completion_install_fish_explicit():
4545
cmd._install(args)
4646
out = _gather_print_output(mock_print)
4747
assert "Detected shell: fish" in out
48-
assert "register-python-argcomplete --shell fish struct" in out
48+
assert "struct --print-completion fish" in out
4949
assert "~/.config/fish/completions/struct.fish" in out
5050

5151

@@ -58,4 +58,4 @@ def test_completion_install_auto_detect_zsh():
5858
cmd._install(args)
5959
out = _gather_print_output(mock_print)
6060
assert "Detected shell: zsh" in out
61-
assert "register-python-argcomplete --shell zsh struct" in out
61+
assert "struct --print-completion zsh" in out

0 commit comments

Comments
 (0)