summaryrefslogblamecommitdiff
path: root/test/correction_plugin_test.exs
blob: 6999b9f803984be5c733a2b91857a4426d2df816 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12











                                                                           
defmodule LSG.IRC.CorrectionPluginTest do
  use ExUnit.Case

  test "works" do
    message = %{text: "s/pouet/prout", replyfun: fn(x) ->
                 assert x == "correction: <oof> prout les salopes"
               end, network: "test", channel: "#test"}
    hist = %{text: "pouet les salopes", sender: %{nick: "oof"}}
    LSG.IRC.CorrectionPlugin.correction(message, %{"test/#test" => [hist]})
  end

end