From 4622c4359fc02ecb652678b289f7067b02d03dd0 Mon Sep 17 00:00:00 2001 From: Mario Visic Date: Sun, 15 Jan 2012 15:05:31 +1100 Subject: [PATCH] Fixed up a failing test due to the i18n module, left a fixme note. --- app/models/locomotive/site.rb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/app/models/locomotive/site.rb b/app/models/locomotive/site.rb index abd8dad2..93abb1d9 100644 --- a/app/models/locomotive/site.rb +++ b/app/models/locomotive/site.rb @@ -56,12 +56,16 @@ module Locomotive protected + # FIXME: Currently there is no t/translate method on the I18n module + # Extensions::Site::I18n which is breaking the testing. The + # namespaced ::I18n should be changed to just I18n when the t() + # method is available def create_default_pages! %w{index 404}.each do |slug| self.pages.create({ :slug => slug, - :title => I18n.t("attributes.defaults.pages.#{slug}.title"), - :raw_template => I18n.t("attributes.defaults.pages.#{slug}.body"), + :title => ::I18n.t("attributes.defaults.pages.#{slug}.title"), + :raw_template => ::I18n.t("attributes.defaults.pages.#{slug}.body"), :published => true }) end