From f33043433cf43f47c210b168e8d41697630b3cd6 Mon Sep 17 00:00:00 2001 From: Aliaksandr Kazlou Date: Fri, 3 Aug 2018 14:50:34 +0300 Subject: [PATCH] #72 Fix failing tests and cover append extra args case --- command/command_test.go | 3 ++- test/config/commands | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/command/command_test.go b/command/command_test.go index a71164c..784c82a 100644 --- a/command/command_test.go +++ b/command/command_test.go @@ -39,7 +39,8 @@ func TestGetCommandExtraArgs(t *testing.T) { followFlags := []string{"", "-f", "--follow"} commandsData := []map[string]string{ {"name": "logs-extra1", "extra": "rest.log", "command": "tail -f -n 10 logs/rest.log"}, - {"name": "logs-extra2", "extra": "5", "command": "tail -f -n 5 logs/app.log 5"}, + {"name": "logs-extra2", "extra": "5", "command": "tail -f -n 5 logs/app.log"}, + {"name": "logs-extra3", "extra": "append test", "command": "tail -f logs/app.log append test"}, } for _, followFlag := range followFlags { for _, commandData := range commandsData { diff --git a/test/config/commands b/test/config/commands index 2fd6511..95d31e7 100644 --- a/test/config/commands +++ b/test/config/commands @@ -20,3 +20,6 @@ command=tail -f -n 10 logs/%s [logs-extra2] command=tail -f -n %s logs/app.log + +[logs-extra3] +command=tail -f logs/app.log