mirror of
https://github.com/portainer/portainer.git
synced 2025-07-24 07:49:41 +02:00
Unit tests for enableFeaturesFromFlags
function (#6063)
* - exporting BoolPairs CLI func - added tests for enableFeaturesFromFlags function * Add a test that uses a feature flag to add change the outcome of code - and test persistence, as that's the current implementation Signed-off-by: Sven Dowideit <sven.dowideit@portainer.io> * Minor comment updates Co-authored-by: Sven Dowideit <sven.dowideit@portainer.io> Co-authored-by: Stéphane Busso <stephane.busso@gmail.com>
This commit is contained in:
parent
9e9a4ca4cc
commit
7d92aa1971
4 changed files with 117 additions and 3 deletions
|
@ -38,7 +38,7 @@ func (l *pairListBool) IsCumulative() bool {
|
|||
return true
|
||||
}
|
||||
|
||||
func boolPairs(s kingpin.Settings) (target *[]portainer.Pair) {
|
||||
func BoolPairs(s kingpin.Settings) (target *[]portainer.Pair) {
|
||||
target = new([]portainer.Pair)
|
||||
s.SetValue((*pairListBool)(target))
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue