Sha256: 19e04732ba8a0c33604849278800be0c06b3744d4847f45af5096877cdcc633c
Contents?: true
Size: 1.07 KB
Versions: 4
Compression:
Stored size: 1.07 KB
Contents
require 'test_helper' module Workarea module Api module Storefront class AnalyticsIntegrationTest < Workarea::IntegrationTest def test_saving_category_view post storefront_api.analytics_category_view_path(category_id: 'foo') assert_equal(1, Metrics::CategoryByDay.first.views) end def test_saving_product_view post storefront_api.analytics_product_view_path(product_id: 'foo') assert_equal(1, Metrics::ProductByDay.first.views) end def test_saving_search post storefront_api.analytics_search_path, params: { q: 'foo', total_results: 5 } insights = Metrics::SearchByDay.first assert_equal(1, insights.searches) assert_equal(5, insights.total_results) end def test_saving_search_abandonment # Saving abandonment is deprecated, and this will be removed in v3.5 end def test_saving_filters # Saving filters is deprecated, and this will be removed in v3.5 end end end end end
Version data entries
4 entries across 4 versions & 2 rubygems