diff options
author | Joram Wilander <jwawilander@gmail.com> | 2017-12-07 17:03:11 -0500 |
---|---|---|
committer | Christopher Speller <crspeller@gmail.com> | 2017-12-07 14:03:11 -0800 |
commit | 4da0257bd52f20734d6d98c33ea5d824d98abbf5 (patch) | |
tree | 68bcb13f81703e4deca35bb3b28046f91dea503d /app/diagnostics_test.go | |
parent | ef597f6fe45cae8b3ba405ff89f5b20bfbf349e5 (diff) | |
download | chat-4da0257bd52f20734d6d98c33ea5d824d98abbf5.tar.gz chat-4da0257bd52f20734d6d98c33ea5d824d98abbf5.tar.bz2 chat-4da0257bd52f20734d6d98c33ea5d824d98abbf5.zip |
Add diagnostic for zoom plugin (#7958)
Diffstat (limited to 'app/diagnostics_test.go')
-rw-r--r-- | app/diagnostics_test.go | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/app/diagnostics_test.go b/app/diagnostics_test.go index 9b884fd43..0d1c7acd8 100644 --- a/app/diagnostics_test.go +++ b/app/diagnostics_test.go @@ -43,6 +43,20 @@ func TestPluginSetting(t *testing.T) { assert.Equal(t, "asd", pluginSetting(settings, "test", "qwe", "asd")) } +func TestPluginActivated(t *testing.T) { + states := map[string]*model.PluginState{ + "foo": &model.PluginState{ + Enable: true, + }, + "bar": &model.PluginState{ + Enable: false, + }, + } + assert.True(t, pluginActivated(states, "foo")) + assert.False(t, pluginActivated(states, "bar")) + assert.False(t, pluginActivated(states, "none")) +} + func TestDiagnostics(t *testing.T) { th := Setup().InitBasic() defer th.TearDown() |