mirror of
https://github.com/mattermost/focalboard.git
synced 2025-01-08 15:06:08 +02:00
c8e729b6fe
* refactor: updated dependency for focalboard server * chore: more dependency fixes * refactor: removed the unless code * refactor: added ctx for login and removed unnessary code * refactor: bump up go version * refactor: removed the commented code * chore: upgraded golinter version * fix: linter issue * refactor: removed feature flg fix golinter * refactor: removed feature flag from code * revert: statistic and it's function * refactor: removed ProductLimit related code * refactor: removed isWithinViewsLimit implementation * refactor: moved function GetUsedCardsCount to statistics.go from cloud.go * refactor: removed insight code board * refactor: removed limit dialog * refactor: updated dependencies for linux * chore: golinter fix * chore: updated helper test function to use newLogger * fix: go test * refactor: db ping attempts from config * revert: feature in action * revert: feature flag in action * revert: boardsEditor setting --------- Co-authored-by: Rajat Dabade <rajat@Rajats-MacBook-Pro.local>
29 lines
816 B
Go
29 lines
816 B
Go
package app
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/mattermost/focalboard/server/services/config"
|
|
"github.com/stretchr/testify/require"
|
|
)
|
|
|
|
func TestGetClientConfig(t *testing.T) {
|
|
th, tearDown := SetupTestHelper(t)
|
|
defer tearDown()
|
|
|
|
t.Run("Test Get Client Config", func(t *testing.T) {
|
|
newConfiguration := config.Configuration{}
|
|
newConfiguration.Telemetry = true
|
|
newConfiguration.TelemetryID = "abcde"
|
|
newConfiguration.EnablePublicSharedBoards = true
|
|
newConfiguration.TeammateNameDisplay = "username"
|
|
th.App.SetConfig(&newConfiguration)
|
|
|
|
clientConfig := th.App.GetClientConfig()
|
|
require.True(t, clientConfig.EnablePublicSharedBoards)
|
|
require.True(t, clientConfig.Telemetry)
|
|
require.Equal(t, "abcde", clientConfig.TelemetryID)
|
|
require.Equal(t, "username", clientConfig.TeammateNameDisplay)
|
|
})
|
|
}
|