2010-11-12 21:45:12 +01:00
|
|
|
# encoding: utf-8
|
|
|
|
require File.expand_path(File.dirname(__FILE__)) + '/../test_helper'
|
2008-12-30 20:43:29 +01:00
|
|
|
|
|
|
|
# This file is generated by the Ruby Holiday gem.
|
|
|
|
#
|
|
|
|
# Definitions loaded: data/mx.yaml, data/north_america_informal.yaml
|
|
|
|
class MxDefinitionTests < Test::Unit::TestCase # :nodoc:
|
|
|
|
|
|
|
|
def test_mx
|
|
|
|
{Date.civil(2007,1,1) => 'Año nuevo',
|
|
|
|
Date.civil(2007,2,5) => 'Día de la Constitución',
|
|
|
|
Date.civil(2007,5,1) => 'Día del Trabajo',
|
|
|
|
Date.civil(2007,5,5) => 'Cinco de Mayo',
|
|
|
|
Date.civil(2007,9,16) => 'Día de la Independencia',
|
|
|
|
Date.civil(2007,11,1) => 'Todos los Santos',
|
|
|
|
Date.civil(2007,11,2) => 'Los Fieles Difuntos',
|
|
|
|
Date.civil(2007,11,19) => 'Día de la Revolución',
|
|
|
|
Date.civil(2007,12,25) => 'Navidad'}.each do |date, name|
|
2010-04-28 15:13:56 +02:00
|
|
|
assert_equal name, (Holidays.on(date, :mx, :informal)[0] || {})[:name]
|
2008-12-30 20:43:29 +01:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|