diff --git a/apps/block_scout_web/test/block_scout_web/controllers/chain_controller_test.exs b/apps/block_scout_web/test/block_scout_web/controllers/chain_controller_test.exs index 7cd68c60a4..bc3a4a4e90 100644 --- a/apps/block_scout_web/test/block_scout_web/controllers/chain_controller_test.exs +++ b/apps/block_scout_web/test/block_scout_web/controllers/chain_controller_test.exs @@ -69,11 +69,21 @@ defmodule BlockScoutWeb.ChainControllerTest do describe "GET token_autocomplete/2" do test "finds matching tokens" do insert(:token, name: "MaGiC") + insert(:token, name: "Evil") conn = get(conn(), "/token_autocomplete?q=magic") assert Enum.count(json_response(conn, 200)) == 1 end + + test "finds two matching tokens" do + insert(:token, name: "MaGiC") + insert(:token, name: "magic") + + conn = get(conn(), "/token_autocomplete?q=magic") + + assert Enum.count(json_response(conn, 200)) == 2 + end end describe "GET search/2" do