From 8c9a1c1121581a0d2a7e99d4ddd0fc22d8be20ed Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Tue, 10 Aug 2021 09:33:19 +0200 Subject: [PATCH] main: push TestPrefixOArgs testcase struct into TestPrefixOArgs No need to have it declared globally. --- cli_args_test.go | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/cli_args_test.go b/cli_args_test.go index 8e5ae3d..eee3659 100644 --- a/cli_args_test.go +++ b/cli_args_test.go @@ -5,18 +5,16 @@ import ( "testing" ) -type testcase struct { - // i is the input - i []string - // o is the expected output - o []string - // Do we expect an error? - e bool -} - // TestPrefixOArgs checks that the "-o x,y,z" parsing works correctly. func TestPrefixOArgs(t *testing.T) { - testcases := []testcase{ + testcases := []struct { + // i is the input + i []string + // o is the expected output + o []string + // Do we expect an error? + e bool + }{ { i: nil, o: nil,