Current section

Files

Jump to
holidefs priv calendars definitions pt.yaml
Raw

priv/calendars/definitions/pt.yaml

# Portugese holiday definitions for the Ruby Holiday gem.
#
# Updated: 2014-03-01.
# Sources:
# - http://thomasallen.home.sapo.pt/travel/hols.htm
# - http://en.wikipedia.org/wiki/Holidays_in_Portugal
# - http://www.kidlink.org/KIDPROJ/MCC/mcc0006.html
# - http://www.worldtravelguide.net/country/227/public_holidays/Europe/Portugal.html
# - http://en.wikipedia.org/wiki/Portugal_Day
# - http://www.timeanddate.com/calendar/custom.html?year=2008&country=15
# - http://en.wikipedia.org/wiki/Public_holidays_in_Portugal
#
# Changes 2017-05-31:
# - Add additional holidays for Porto (pt_po) and Lisbon (pt_li)
---
months:
0:
- name: Carnaval # same as Shrove Tuesday
regions: [pt]
function: easter(year)
function_modifier: -47
type: informal
- name: Sexta-feira Santa
regions: [pt]
function: easter(year)
function_modifier: -2
- name: Páscoa
regions: [pt]
function: easter(year)
- name: Corpo de Deus
regions: [pt]
function: easter(year)
function_modifier: 60
1:
- name: Ano Novo
regions: [pt]
mday: 1
4:
- name: Dia da Liberdade
regions: [pt]
mday: 25
5:
- name: Dia do Trabalhador
regions: [pt]
mday: 1
6:
- name: Dia de Portugal
regions: [pt]
mday: 10
- name: Dia de Santo António
regions: [pt_li]
mday: 13
- name: Dia de São João
regions: [pt_po]
mday: 24
8:
- name: Assunção de Nossa Senhora
regions: [pt]
mday: 15
10:
- name: Dia da República
regions: [pt]
mday: 5
11:
- name: Dia de Todos-os-Santos
regions: [pt]
mday: 1
12:
- name: Restauração da Independência
regions: [pt]
mday: 1
- name: Imaculada Conceição
regions: [pt]
mday: 8
- name: Natal
regions: [pt]
mday: 25
tests:
- given:
date: '2008-01-01'
regions: ["pt"]
options: ["informal"]
expect:
name: "Ano Novo"
- given:
date: '2005-02-08'
regions: ["pt"]
options: ["informal"]
expect:
name: "Carnaval"
- given:
date: '2006-02-28'
regions: ["pt"]
options: ["informal"]
expect:
name: "Carnaval"
- given:
date: '2007-02-20'
regions: ["pt"]
options: ["informal"]
expect:
name: "Carnaval"
- given:
date: '2008-02-05'
regions: ["pt"]
options: ["informal"]
expect:
name: "Carnaval"
- given:
date: '2008-03-21'
regions: ["pt"]
options: ["informal"]
expect:
name: "Sexta-feira Santa"
- given:
date: '2008-03-23'
regions: ["pt"]
options: ["informal"]
expect:
name: "Páscoa"
- given:
date: '2016-03-27'
regions: ["pt"]
options: ["informal"]
expect:
name: "Páscoa"
- given:
date: '2008-04-25'
regions: ["pt"]
options: ["informal"]
expect:
name: "Dia da Liberdade"
- given:
date: '2008-05-01'
regions: ["pt"]
options: ["informal"]
expect:
name: "Dia do Trabalhador"
- given:
date: '2016-05-26'
regions: ["pt"]
options: ["informal"]
expect:
name: "Corpo de Deus"
- given:
date: '2008-06-10'
regions: ["pt"]
options: ["informal"]
expect:
name: "Dia de Portugal"
- given:
date: '2008-08-15'
regions: ["pt"]
options: ["informal"]
expect:
name: "Assunção de Nossa Senhora"
- given:
date: '2008-10-05'
regions: ["pt"]
options: ["informal"]
expect:
name: "Dia da República"
- given:
date: '2008-11-01'
regions: ["pt"]
options: ["informal"]
expect:
name: "Dia de Todos-os-Santos"
- given:
date: '2008-12-01'
regions: ["pt"]
options: ["informal"]
expect:
name: "Restauração da Independência"
- given:
date: '2008-12-08'
regions: ["pt"]
options: ["informal"]
expect:
name: "Imaculada Conceição"
- given:
date: '2008-12-25'
regions: ["pt"]
options: ["informal"]
expect:
name: "Natal"