diff options
author | Paul Holzinger <pholzing@redhat.com> | 2021-09-23 15:15:35 +0200 |
---|---|---|
committer | Paul Holzinger <pholzing@redhat.com> | 2021-09-23 15:15:35 +0200 |
commit | b6e5a4909a5070f3092f91a592e6d04c5d358e85 (patch) | |
tree | ae0070c07b82a6aed9ec96514a04647816d7e92f /test/system/600-completion.bats | |
parent | 3d34d3a186a782e48bdbd1245a7e067db850d9b0 (diff) | |
download | podman-b6e5a4909a5070f3092f91a592e6d04c5d358e85.tar.gz podman-b6e5a4909a5070f3092f91a592e6d04c5d358e85.tar.bz2 podman-b6e5a4909a5070f3092f91a592e6d04c5d358e85.zip |
shell completion: do not show images without tag
The shell completion should only suggest arguments that work. Using a
image without tag does not work in many cases. Having both the version
with and without tag also forces users to press one key more because
tab completion will always stop at the colon.
Fixes #11673
Signed-off-by: Paul Holzinger <pholzing@redhat.com>
Diffstat (limited to 'test/system/600-completion.bats')
-rw-r--r-- | test/system/600-completion.bats | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/test/system/600-completion.bats b/test/system/600-completion.bats index fbb0da231..5f4610e9e 100644 --- a/test/system/600-completion.bats +++ b/test/system/600-completion.bats @@ -110,12 +110,10 @@ function check_shell_completion() { is "$output" ".*localhost/$random_image_name:$random_image_tag${nl}" \ "$* $cmd: actual image listed in suggestions" - # check that we complete the image with and without tag after at least one char is typed + # check that we complete the image with tag after at least one char is typed run_completion "$@" $cmd "${extra_args[@]}" "${random_image_name:0:1}" is "$output" ".*$random_image_name:$random_image_tag${nl}" \ "$* $cmd: image name:tag included in suggestions" - is "$output" ".*$random_image_name${nl}" \ - "$* $cmd: image name(w/o tag) included in suggestions" # check that we complete the image id after at least two chars are typed run_completion "$@" $cmd "${extra_args[@]}" "${random_image_id:0:2}" |