mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
grafana-cli: Upgrade to urfave/cli v2 (#22402)
* grafana-cli: Upgrade to urfave/cli v2
This commit is contained in:
@@ -9,6 +9,7 @@ import (
|
||||
"github.com/grafana/grafana/pkg/models"
|
||||
"github.com/grafana/grafana/pkg/services/sqlstore"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
||||
func TestPasswordMigrationCommand(t *testing.T) {
|
||||
@@ -45,7 +46,9 @@ func TestPasswordMigrationCommand(t *testing.T) {
|
||||
assert.Nil(t, err)
|
||||
|
||||
//run migration
|
||||
err = EncryptDatasourcePaswords(&commandstest.FakeCommandLine{}, sqlstore)
|
||||
c, err := commandstest.NewCliContext(map[string]string{})
|
||||
require.Nil(t, err)
|
||||
err = EncryptDatasourcePaswords(c, sqlstore)
|
||||
assert.Nil(t, err)
|
||||
|
||||
//verify that no datasources still have password or basic_auth
|
||||
|
||||
Reference in New Issue
Block a user