Making private import methos in the app layer (#13758)

* Making private import methos in the app layer

* Making one more method private
Этот коммит содержится в:
Jesús Espino
2020-01-28 10:58:33 +01:00
коммит произвёл Miguel de la Cruz
родитель a76643116f
Коммит ae6f15b76f
4 изменённых файлов: 192 добавлений и 192 удалений

Просмотреть файл

@@ -81,42 +81,42 @@ func TestImportImportLine(t *testing.T) {
Type: "gibberish",
}
err := th.App.ImportLine(line, false)
err := th.App.importLine(line, false)
require.NotNil(t, err, "Expected an error when importing a line with invalid type.")
// Try import line with team type but nil team.
line.Type = "team"
err = th.App.ImportLine(line, false)
err = th.App.importLine(line, false)
require.NotNil(t, err, "Expected an error when importing a line of type team with a nil team.")
// Try import line with channel type but nil channel.
line.Type = "channel"
err = th.App.ImportLine(line, false)
err = th.App.importLine(line, false)
require.NotNil(t, err, "Expected an error when importing a line with type channel with a nil channel.")
// Try import line with user type but nil user.
line.Type = "user"
err = th.App.ImportLine(line, false)
err = th.App.importLine(line, false)
require.NotNil(t, err, "Expected an error when importing a line with type user with a nil user.")
// Try import line with post type but nil post.
line.Type = "post"
err = th.App.ImportLine(line, false)
err = th.App.importLine(line, false)
require.NotNil(t, err, "Expected an error when importing a line with type post with a nil post.")
// Try import line with direct_channel type but nil direct_channel.
line.Type = "direct_channel"
err = th.App.ImportLine(line, false)
err = th.App.importLine(line, false)
require.NotNil(t, err, "Expected an error when importing a line with type direct_channel with a nil direct_channel.")
// Try import line with direct_post type but nil direct_post.
line.Type = "direct_post"
err = th.App.ImportLine(line, false)
err = th.App.importLine(line, false)
require.NotNil(t, err, "Expected an error when importing a line with type direct_post with a nil direct_post.")
// Try import line with scheme type but nil scheme.
line.Type = "scheme"
err = th.App.ImportLine(line, false)
err = th.App.importLine(line, false)
require.NotNil(t, err, "Expected an error when importing a line with type scheme with a nil scheme.")
}