<%= t("reports.trends.month") %>
<%= t("reports.trends.income") %>
<%= t("reports.trends.expenses") %>
diff --git a/test/controllers/reports_controller_test.rb b/test/controllers/reports_controller_test.rb
index a4524382d..afc81abd3 100644
--- a/test/controllers/reports_controller_test.rb
+++ b/test/controllers/reports_controller_test.rb
@@ -82,7 +82,9 @@ class ReportsControllerTest < ActionDispatch::IntegrationTest
get reports_path(period_type: :monthly)
assert_response :ok
assert_select "h2", text: I18n.t("reports.trends.title")
- assert_select "th", text: I18n.t("reports.trends.month")
+ assert_select '[role="columnheader"]' do
+ assert_select "div", text: I18n.t("reports.trends.month")
+ end
end
test "index handles invalid date parameters gracefully" do
@@ -236,6 +238,12 @@ class ReportsControllerTest < ActionDispatch::IntegrationTest
get reports_path(period_type: :monthly)
assert_response :ok
- assert_select "table.w-full"
+
+ # Parent category
+ assert_select "div[data-category='category-#{parent_category.id}']", text: /^Entertainment/
+
+ # Subcategories
+ assert_select "div[data-category='category-#{subcategory_movies.id}']", text: /^Movies/
+ assert_select "div[data-category='category-#{subcategory_games.id}']", text: /^Games/
end
end