Skip to content

Conversation

@d4rk5eed
Copy link
Contributor

  • Created Email.Protocol.Pop3 for pop3 protocol
  • Created Email.Protocol.Pop3.Mock for testing

d4rk5eed and others added 2 commits January 30, 2018 22:48
- Created Email.Protocol.Pop3.Mock for testing
bot_params
Map.put(
bot_params, :private, %{
mail_fetcher_module: (Mix.env() == :test &&@pop3_mock || @pop3)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

&&@pop3_mock - это какой-то особый синтаксис? непонятно немного

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

&&@pop3_mock -> && @pop3_mock

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Какая-то императивная магия

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Вика поправила

end)
end

defp mail_options(%BotParams{
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Зачем этот метод вообще? Какой-то копипаст... Можно завернуть в provider_params.mail_params, или сделать Map.take...

mix.exs Outdated
{:credo, "~> 0.8", only: [:dev, :test]}
{:credo, "~> 0.8", only: [:dev, :test]},
{:pop3mail, "~> 1.3"},
{:erlpop, github: "nico-amsterdam/erlpop"}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 либы? зачем

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Разобрался, но хрень какая-то)

@Virviil
Copy link
Member

Virviil commented Feb 26, 2018

один из тестов сейчас падает

Victoria91 and others added 2 commits February 26, 2018 17:31
Merge pull request #2 from agalaframework/add-pop3-mailer
@Victoria91
Copy link
Member

Теперь тесты проходят

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants