From d9390244afe90ed318ac8c263c19328f16dc2562 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20Espino?= Date: Fri, 22 Jun 2018 11:15:19 +0200 Subject: MM-8810: Add CSV Compliance export (#8966) * MM-8810: Add CSV Compliance export * Only allowing to schedule actiances export throught the cli * De-duplicating some code * Fixes on texts * Fixes on translations --- cmd/mattermost/commands/message_export_test.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'cmd/mattermost/commands/message_export_test.go') diff --git a/cmd/mattermost/commands/message_export_test.go b/cmd/mattermost/commands/message_export_test.go index 7572d8b48..89ef45a6a 100644 --- a/cmd/mattermost/commands/message_export_test.go +++ b/cmd/mattermost/commands/message_export_test.go @@ -24,7 +24,7 @@ func TestMessageExportNotEnabled(t *testing.T) { defer os.RemoveAll(filepath.Dir(configPath)) // should fail fast because the feature isn't enabled - require.Error(t, RunCommand(t, "--config", configPath, "export")) + require.Error(t, RunCommand(t, "--config", configPath, "export", "schedule")) } func TestMessageExportInvalidFormat(t *testing.T) { @@ -32,7 +32,7 @@ func TestMessageExportInvalidFormat(t *testing.T) { defer os.RemoveAll(filepath.Dir(configPath)) // should fail fast because format isn't supported - require.Error(t, RunCommand(t, "--config", configPath, "--format", "not_actiance", "export")) + require.Error(t, RunCommand(t, "--config", configPath, "--format", "not_actiance", "export", "schedule")) } func TestMessageExportNegativeExportFrom(t *testing.T) { @@ -40,7 +40,7 @@ func TestMessageExportNegativeExportFrom(t *testing.T) { defer os.RemoveAll(filepath.Dir(configPath)) // should fail fast because export from must be a valid timestamp - require.Error(t, RunCommand(t, "--config", configPath, "--format", "actiance", "--exportFrom", "-1", "export")) + require.Error(t, RunCommand(t, "--config", configPath, "--format", "actiance", "--exportFrom", "-1", "export", "schedule")) } func TestMessageExportNegativeTimeoutSeconds(t *testing.T) { @@ -48,7 +48,7 @@ func TestMessageExportNegativeTimeoutSeconds(t *testing.T) { defer os.RemoveAll(filepath.Dir(configPath)) // should fail fast because timeout seconds must be a positive int - require.Error(t, RunCommand(t, "--config", configPath, "--format", "actiance", "--exportFrom", "0", "--timeoutSeconds", "-1", "export")) + require.Error(t, RunCommand(t, "--config", configPath, "--format", "actiance", "--exportFrom", "0", "--timeoutSeconds", "-1", "export", "schedule")) } func writeTempConfig(t *testing.T, isMessageExportEnabled bool) string { -- cgit v1.2.3-1-g7c22