How to solve ActionView::Template::Error: Database missing time zone support for Etc/UTC in ReportsControllerTest Question
+2
−0
I ran tests (bin/rails test
) and got
Error:
ReportsControllerTest#test_every_route_should_work_for_moderators:
ActionView::Template::Error: Database missing time zone support for Etc/UTC - see https://github.com/ankane/groupdate#for-mysql
app/views/reports/users.html.erb:17:in `_app_views_reports_users_html_erb__3530160556563631482_308000'
test/controllers/reports_controller_test.rb:25:in `block (2 levels) in <class:ReportsControllerTest>'
test/controllers/reports_controller_test.rb:24:in `each'
test/controllers/reports_controller_test.rb:24:in `block in <class:ReportsControllerTest>'
Searching for the error message only gave a site in Japanese with the exact error message, but I couldn't read it. Is it a big problem?
1 answer
+2
−0
Your MySQL installation is missing timezone support for the groupdate gem that we use.
Run the following:
mysql_tzinfo_to_sql /usr/share/zoneinfo | sudo mysql -u root mysql
and you should be good to go.
0 comment threads