mirror of
https://github.com/spf13/cobra
synced 2025-04-27 17:17:20 +00:00
changed the tests
This commit is contained in:
parent
7fdb732a47
commit
eb22f6c157
1 changed files with 6 additions and 6 deletions
|
@ -132,12 +132,6 @@ func TestStringInSlice(t *testing.T) {
|
||||||
list: []string{"orange", "banana", "apple", "grape"},
|
list: []string{"orange", "banana", "apple", "grape"},
|
||||||
expected: false,
|
expected: false,
|
||||||
},
|
},
|
||||||
{
|
|
||||||
name: "String in slice (case-insensitive)",
|
|
||||||
a: "APPLE",
|
|
||||||
list: []string{"orange", "banana", "apple", "grape"},
|
|
||||||
expected: false,
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
name: "String not in slice (case-insensitive)",
|
name: "String not in slice (case-insensitive)",
|
||||||
a: "PEAR",
|
a: "PEAR",
|
||||||
|
@ -156,6 +150,12 @@ func TestStringInSlice(t *testing.T) {
|
||||||
list: []string{"orange", "banana", "apple", "grape"},
|
list: []string{"orange", "banana", "apple", "grape"},
|
||||||
expected: false,
|
expected: false,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "Empty strings match",
|
||||||
|
a: "",
|
||||||
|
list: []string{"orange", ""},
|
||||||
|
expected: true,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: "Empty string in empty slice",
|
name: "Empty string in empty slice",
|
||||||
a: "",
|
a: "",
|
||||||
|
|
Loading…
Add table
Reference in a new issue