Open source, privacy-first web analytics. Lightweight, cookie-free Google Analytics alternative. Self-hosted or cloud.
TypeScript analyticsanalytics-dashboardclickhouseelixirgoogle-analyticsmarketingopen-source-analyticsphoenixplausible-analyticspostgresqlprivacyprivacy-friendlyself-hostedsimple-analyticsstatisticstailwindcssweb-analyticswebsite-analyticswebsite-statswebsite-tracking
fix test (#4001)
RobertJoonas5163880968eb
diff --git a/test/plausible_web/controllers/api/stats_controller/suggestions_test.exs b/test/plausible_web/controllers/api/stats_controller/suggestions_test.exsindex 9f683cfdd6..07b931901c 100644--- a/test/plausible_web/controllers/api/stats_controller/suggestions_test.exs+++ b/test/plausible_web/controllers/api/stats_controller/suggestions_test.exs@@ -268,12 +268,15 @@ defmodule PlausibleWeb.Api.StatsController.SuggestionsTest do"/api/stats/#{site.domain}/suggestions/hostname?q=host")- assert json_response(conn, 200) ==- [- %{"label" => "host-alice.example.com", "value" => "host-alice.example.com"},- %{"label" => "host-carol.example.com", "value" => "host-carol.example.com"},- %{"label" => "host-bob.example.com", "value" => "host-bob.example.com"}- ]+ suggestions = json_response(conn, 200)++ assert length(suggestions) == 3++ assert %{"label" => "host-alice.example.com", "value" => "host-alice.example.com"} in suggestions++ assert %{"label" => "host-carol.example.com", "value" => "host-carol.example.com"} in suggestions++ assert %{"label" => "host-bob.example.com", "value" => "host-bob.example.com"} in suggestionsendtest "returns suggestions for referrers", %{conn: conn, site: site} do