From 3248153d9f928710103073de0752145ffb95a631 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Sun, 11 Oct 2020 01:51:39 +0900 Subject: Add --preview-window=default for resetting the options --- src/options_test.go | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/options_test.go') diff --git a/src/options_test.go b/src/options_test.go index aae8eedc..78207275 100644 --- a/src/options_test.go +++ b/src/options_test.go @@ -417,6 +417,13 @@ func TestPreviewOpts(t *testing.T) { opts.Preview.size.size == 15) { t.Error(opts.Preview) } + opts = optsFor("--preview=foo", "--preview-window=up", "--preview-window=default:70%") + if !(opts.Preview.command == "foo" && + opts.Preview.position == posRight && + opts.Preview.size.percent == true && + opts.Preview.size.size == 70) { + t.Error(opts.Preview) + } } func TestAdditiveExpect(t *testing.T) { -- cgit v1.2.3